Flask API Design and Testing

Evaluate how well you can create,document,and test RESTful APIs using Flask.

1. Which decorator is used to define a route in a Flask application?
2. Which HTTP methods can be explicitly specified in the 'methods' parameter of Flask's @app.route decorator? (Select all that apply)
3. In Flask, the 'request' object is automatically available in all view functions without needing to import it.
4. What is the name of the Flask function that converts a Python dictionary to a JSON response with the correct 'application/json' Content-Type header?
5. Which HTTP status code should a Flask view function return when the requested resource cannot be found?
6. Which of the following tools are commonly used for testing Flask APIs? (Select all that apply)
7. Flask's 'jsonify' function returns a Response object with the 'Content-Type' header automatically set to 'application/json'.
8. What is the default port number used by the Flask development server when running with 'flask run' (without specifying --port)?
9. What is the primary purpose of Flask Blueprints?
10. Which environment variables are part of Flask's core configuration for running an application? (Select all that apply)
Answered 0 of 0 — 0 correct