Test your knowledge

  1. Flask-RESTful uses which of the following as the main building block for a RESTful API?
    1. Resources built on top of Flask pluggable views
    2. Statuses built on top of Flask resource views.
    3. Resources built on top of Flask pluggable controllers.

  2. In order to be able to process an HTTP POST request on a resource, we must declare a method with the following name in a subclass of flask_restful.Resource.
    1. post_restful
    2. post_method
    3. post

  3. In order to be able to process an HTTP GET request on a resource, we must declare a method with the following name in a subclass of flask_restful.Resource.
    1. get_restful
    2. get_method
    3. get

  4. A subclass of flask_restful.Resource represents:
    1. A controller resource.
    2. A RESTful resource.
    3.  A single RESTful HTTP verb.

  5. If we use the @marshal_with decorator with message_fields as an argument, the decorator will:
    1. Apply the field filtering and output formatting specified in message_fields to the appropriate instance.
    2. Apply the field filtering specified in message_fields to the appropriate instance, without considering output formatting.
    3. Apply the output formatting specified in message_fields to the appropriate instance, without considering field filtering.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.189.23