Upgrade (projects must change): config_api entries take auth instead of is_token (and the 16.9.0 is_api_key), in config_extend.py: "is_token": True → "auth": ["jwt"], "is_token": False → "auth": [], "is_api_key": True → add "api_key" (["jwt", "api_key"], or ["api_key"] for machines only). Startup names any entry still using the old keys. A client sending an API key as Authorization: ApiKey atk_... sends Authorization: Bearer atk_....
auth, one list per route: the credentials a route accepts, as OpenAPI's per-route security does:[]public,["jwt"]a JWT access token (people),["api_key"]an API key (machines),["jwt", "api_key"]either. It replaces the two flagsis_tokenandis_api_key, so no meaningless mix is possible and a machine-only route can refuse a person's login. A role, permission or user check needs a non-emptyauth(startup refuses it otherwise; before, it switched the token on silently). A credential the route does not list is 401 (jwt not allowed on this route,api_key not allowed on this route); none isauthorization missing.func_middleware_check_tokenis nowfunc_middleware_check_auth;/openapi.jsonaddsx-authper route.- API keys are sent as
Authorization: Bearer atk_..., the standard header (GitHub, Stripe, OpenAI); theatk_prefix tells a key from a JWT (which startseyJ). - API keys use the generic routes: list keys with
/my/object-read?table=api_keyand revoke them with/my/object-delete(or/admin/object-read,/admin/object-deletefor any user's);/my/api-key-read,/my/api-key-deleteand/admin/api-key-deletefrom 16.9.0 are gone, and/my/api-key-createis the only key route. The database refuses everyUPDATEofapi_key(table_row_update_disable), so a key is never edited, andlast_used_atis dropped (a key's requests are inlog_apiunder its owner).key_hashjoinsconfig_column_read_blocked. - Docs: the standard terms (API key, service account, scopes, revocation, rotation) and a partner system sending data through a project route with
"auth": ["api_key"](docs/auth.md).