Decouple from marshmallow and add an adapter system to support different serialization/deserialization libraries (pr #690).
Add support for Pydantic models as data schemas (issue #519).
Fix subclassed MethodView resources cannot be added as URL rules (issue #618).
Add support for API key auth with APIKeyHeaderAuth, APIKeyCookieAuth, and APIKeyQueryAuth. Add support for runtime selection of authentication methods with MultiAuth. Deprecate the API key auth with HTTPTokenAuth (issue #604).
Only pass keyword arguments to the view function. The argument name
of the parsed data from app.input() will be {location}_data or the
value of arg_name (issue #427).
Add FileSchema to generate OpenAPI file response (issue #447).
Support using {} to represent not only empty body (204) but also empty schema.
Use {} or EmptySchema will not set the status code to 204 anymore.
Remove the previously deprecated code:
The tag parameter in @app.doc.
The role parameter in @app.auth_required.
The redoc_path parameter in apiflask.APIFlask and the /redoc path.
Support setting a complete response OpenAPI spec throught the app.doc(responses)
parameter (i.e. responses={400: {'description': '', 'content': ...}})
(issue #327).
Add scurity_scheme_name for HTTPBasicAuth and HTTPTokenAuth to define custom
OpenAPI security scheme name (issue #410).
Add config SPEC_PROCESSOR_PASS_OBJECT to control the argument type of
spec processor. The spec argument will be an apispec.APISpec object
when this config is True (issue #213).
Add content_type parameter to the output() decorator to customize the
response's content/media type.
Support to generate the OpenAPI servers field when the reqeust context is available. Add
the config AUTO_SERVERS to control this automation behavior (issue #377).
role in app.auth_required()/bp.auth_required(), use roles and always pass a list.
tag in app.doc()/bp.doc(), use tags and always pass a list.
Add a base class (apiflask.scaffold.APIScaffold) for common logic of APIFlask and
APIBlueprint, move route decorators and API-related decorators to this base class
to improve the IDE auto-completion (issue #231).
Support customizing OpenAPI securitySchemes and operation security, this makes it
possible to use any external authentication libraries (pull #232).
Improve the way to detect blueprint from view endpoint to support the endpoints that
contain dots (issue #211).
Fix the content type of form and files input locations.
Raise error if the user uses multiple body input locations ("files", "form", "json").
Add Form field and form_and_files location for better form upload support.
Rewrite the files to act like form_and_files, so that failed parsed file will
be included in the returned data.
Allow to use json_or_form location and fields (DelimitedList and DelimitedTuple)
from webargs (issue #254).
When creating a custom error processor, call it for generic HTTP errors even if the
json_errors is set to False when creating the app instance (issue #171).
Move standalone decorators (input, output, auth_required, doc) to APIFlask/APIBlueprint
classes. The old decorators are deprecated and will be removed in 1.0. (issue #187).
Support creating custom error classes based on HTTPError. The position argument status_code of
HTTPError is changed to a keyword argument, defaults to 500 (issue #172).
Support using add_url_rule method on view classes (issue #110).
Revoke the undocumented name changes on validates and validates_schema from marshmallow (issue #62).
Only expose marshmallow fields, validators, and Schema in APIFlask.
Remove the status_code field from the default error response (issue #124).
Add parameter extra_data to abort and HTTPError, it accepts a dict that will be added
to the error response (issue #125).
Support passing operation_id in the doc decorator. The auo-generating of operationId
can be enabled with config AUTO_OPERATION_ID, defaults to False (pull #131).
Support setting response links via @output(links=...) (issue #138).
Authentication error now calls app error processor function when APIFlask(json_errors=True).
The default HTTP reason phrase is used for auth errors.
Always pass an HTTPError instance to error processors. When you set a custom error
processor, now you need to accept an HTTPError instance as the argument. The detail and
headers attribute of the instance will be empty dict if not set.
Add an error_processor decorator for HTTPTokenAuth and HTTPBasicAuth, it can be used
to register a custom error processor for auth errors.
Support to config Redoc via the configuration variable REDOC_CONFIG (issue #121).
Automatically add a 404 response in OpenAPI spec for routes contains URL
variables (issue #78).
Rename the private method app.get_spec to app._get_spec, add new
parameter force_update. The app.spec property now will always return
the latest spec instead of the cached one (issue #79).
Support using doc(responses={<STATUS_CODE>: <DESCRIPTION>}) to overwrite
existing response descriptions.
Add configration variable INFO (and app.info attribute), it can be used
to set the following info fields: description, termsOfService, contact,
license (issue #98).
Rename the following configuration variables (issue #99):
Support using async error processor and async spec processor
(pull #57).
Fix auto-tag support for nesting blueprint (pull #58).
Support set the URL prefix of the OpenAPI blueprint with the
openapi_blueprint_url_prefix argument (pull #64).
Add a flask spec command to output the OpenAPI spec to stdout
or a file, also add new config LOCAL_SPEC_PATH and
LOCAL_SPEC_JSON_INDENT (issue #61).
Re-add the SPEC_FORMAT config. Remove the auto-detection of
the format from APIFlask(spec_path=...), now you have to set the
format explicitly with the SPEC_FORMAT config (issue #67).
Support to sync the local OpenAPI spec automatically. Add new config
SYNC_LOCAL_SPEC (issue #68).
Change the default value of config DOCS_FAVICON to
'https://apiflask.com/_assets/favicon.png', set to None to disable
the favicon.
OpenAPI UI templates are move to ui_templates.py.
Revert the renames on pre/post decorators from marshmallow (issue #62).
Allow returning a Response object in a view function decorated with the output
decorator. In this case, APIFlask will do nothing but return it directly
(pull #38).
Skip Flask's Blueprint object when generating the OpenAPI spec (pull #37).
Remove the support to generate info.description and tag description from module
docstring, and also remove the AUTO_DESCRIPTION config (pull #30).
Remove the configuration variable DOCS_HIDE_BLUEPRINTS, add APIBlueprint.enable_openapi
as a replacement.
Support class-based views, now the route decorator can be used on MethodView class.
Other decorators (i.e., @input, @output, etc.) can be used on view methods
(i.e., get(), post(), etc.) (pull #32).
No longer support to mix the use of flask.Bluerpint and apiflask.APIBluerpint.
Support to use the auth_required decorator on app-wide before_request functions
(pull #34).