| fapi-2-implementation-advice | October 2026 | |
| Tonge | Standards Track | [Page] |
Financial-grade API (FAPI) 2.0 Implementation Advice is a document to provide practical guidance on the implementation and usage of the FAPI 2.0 family of standards.¶
The OpenID Foundation (OIDF) promotes, protects and nurtures the OpenID community and technologies. As a non-profit international standardizing body, it is comprised by over 160 participating entities (workgroup participant). The work of preparing implementer drafts and final international standards is carried out through OIDF workgroups in accordance with the OpenID Process. Participants interested in a subject for which a workgroup has been established have the right to be represented in that workgroup. International organizations, governmental and non-governmental, in liaison with OIDF, also take part in the work. OIDF collaborates closely with other standardizing bodies in the related fields.¶
Final drafts adopted by the Workgroup through consensus are circulated publicly for the public review for 60 days and for the OIDF members for voting. Publication as an OIDF Standard requires approval by at least 50% of the members casting a vote. There is a possibility that some of the elements of this document may be subject to patent rights. OIDF shall not be held responsible for identifying any or all such patent rights.¶
The Financial-grade API (FAPI) 2.0 family of standards provides security profiles and specifications to enable implementers to deploy highly secure, interoperable APIs. While we have attempted to minimize the optionality in FAPI 2.0, there are still many decisions that need to be made by implementers. This document aims to provide advice for implementers based on the experience of members of the OpenID Foundation's FAPI Working Group.¶
This document is not an OIDF International Standard. It is distributed for review and comment. It is subject to change without notice and may not be referred to as an International Standard.¶
Recipients of this draft are invited to submit, with their comments, notification of any relevant patent rights of which they are aware and to provide supporting documentation.¶
The keywords "shall", "shall not", "should", "should not", "may", and "can" in this document are to be interpreted as described in ISO Directive Part 2 [ISODIR2]. These keywords are not used as dictionary terms such that any occurrence of them shall be interpreted as keywords and are not to be interpreted with their natural language meanings.¶
The FAPI 2.0 Framework is comprised of several documents. At the time of writing, they are:¶
The foundation of the framework is the attacker model and security profile. All the other specifications build on the security profile.¶
Implementers may find the following http-headers useful:¶
This header can be used to enable Authorization Servers, Resource Servers and Clients to
better track and debug any issues between them. If an ecosystem adopts x-fapi-interaction-id then
the following clauses apply:¶
x-fapi-interaction-id request header, the value shall be a
UUID [RFC9562], e.g., x-fapi-interaction-id: c770aef3-6784-41f7-8e0e-ff5f97bddb3a;¶
x-fapi-interaction-id to the value received from the corresponding FAPI client request header if that value is a UUID [RFC9562], or otherwise to a new UUID [RFC9562] value to track the interaction, e.g., x-fapi-interaction-id: c770aef3-6784-41f7-8e0e-ff5f97bddb3a;¶
x-fapi-interaction-id in the log entry.¶
NOTE: Clients may reuse the same x-fapi-interaction-id value across related requests within
a single authorization code flow, including PAR requests, token requests, and immediate
API calls. This can help with tracing and troubleshooting related transactions. Due to the
nature of browser redirects, the authorization request itself typically cannot include HTTP
headers, so the x-fapi-interaction-id will not be present in those requests. Specific
guidance on when to reuse vs. generate new interaction IDs may be defined by individual
ecosystems.¶
Many ecosystems have different non-functional requirements depending on whether an end-user
is present or not. The x-fapi-end-user-present header indicates whether the request is
being made in the context of an interactive end-user session or as part of a
background/automated process. If an ecosystem adopts this header, the following clauses apply:¶
Clients shall send the x-fapi-end-user-present header with a value of true when
the request is made with an end-user actively present in the session, and false when the
request is part of a background process, batch operation, or automated task without active
user participation.¶
If the header is not present, servers should assume a default value of false
(i.e., no end-user is present).¶
The header value shall be a boolean: either true or false,
e.g., x-fapi-end-user-present: true.¶
The primary benefit of the x-fapi-end-user-present header is to support
ecosystem-specific requirements for different traffic patterns:¶
Many ecosystems implement different rate limits for end-user-present vs. background operations. User-present operations may have higher per-second limits but lower daily limits, while background operations might have the opposite pattern.¶
During high load situations, servers may prioritize user-present requests to maintain interactive performance while delaying background operations.¶
This header is not a security mechanism. Authorization Servers must trust that Clients are filling in this header correctly and cannot independently verify the presence of an end user.¶
This header replaces problematic approaches from previous specifications, such as:¶
Since Clients can set this value arbitrarily, ecosystem governance and monitoring are necessary to detect patterns of misuse, such as clients marking all API calls as user-present regardless of context.¶
NOTE: This header is only useful in ecosystems where recourse exists against clients that falsify its value.¶
Sender constraining access tokens is an important security measure that provides significant protections against token theft and misuse. FAPI 2.0 allows implementers to use either DPoP or MTLS to achieve this goal. Both approaches meet the security requirements, but each has different characteristics that may make one more suitable than the other depending on your ecosystem. This section outlines considerations to guide your choice.¶
MTLS implementations may encounter interoperability issues with certificate handling, including:¶
Both DPoP and MTLS are valid choices for sender constraining, and each has trade-offs.¶
MTLS may be more suitable when:¶
DPoP may be more suitable when:¶
Implementers should not use both DPoP and MTLS simultaneously for sender constraining.¶
Some ecosystems issue certificates to organizations rather than to individual clients, for example eIDAS certificates, and an organization can operate more than one client.¶
NOTE: One way to distinguish a client from the organization that operates it is for each client to register the certificates and keys it uses: the subject distinguished name of its TLS client certificate using the tls_client_auth_subject_dn client metadata parameter [RFC8705], and its signing keys at a jwks_uri [RFC7591].¶
A client should reject the response if it requests a JARM [JARM] response from an authorization server that advertises JARM support in its response_modes_supported metadata but receives the authorization response parameters, such as code and state, directly instead of in a response JWT.¶
An authorization server that also serves clients that do not use PKCE [RFC7636] can be subject to the PKCE downgrade attack described in Section 4.8 of [RFC9700]. Section 4.8.2 of [RFC9700] requires such an authorization server to reject a token request that contains a code_verifier if the authorization request did not contain a code_challenge.¶
When both the client and the authorization server provide native applications, the end-user can move between them without using a browser:¶
NOTE 1: On iOS, the universalLinksOnly option, and on Android 11 and later, the FLAG_ACTIVITY_REQUIRE_NON_BROWSER intent flag, open a URL only if an installed application claims it, so that the application can fall back to a browser.¶
NOTE 2: On Android 12 and later, an HTTPS URL that is not a verified Android App Link always opens in a browser, so the authorization endpoint URL and redirect URI need to be verified App Links. On earlier versions, the end-user can be offered another installed application that handles the same URL.¶
When OpenID Connect is used, a client that sends the end-user through authorization again, for example to extend an existing grant, can confirm that it is the same end-user by requesting the sub claim in the ID Token with the expected value using the claims parameter, as described in Section 5.5.1 of [OIDC]. The authorization server then only returns a successful response for that end-user.¶
Authorization servers should support the claims parameter and keep the sub value of an end-user stable, as described in Section 5.7 of [OIDC].¶
As key size grows and more elements are added to access tokens, it's possible for the HTTP Authorization header containing the access token plus other headers to cumulatively be larger than the allowed buffer size for HTTP requests in many web infrastructure components. It is important to watch this closely via logging and alerting to ensure that production traffic is not adversely affected and that adjustments to the allowed buffer size can be made in a timely manner.¶
Note: While OAuth 2.0 [RFC6749] leaves token size decisions to the authorization server, implementers should be aware that many standard web servers reject headers larger than 8KB by default.¶
Large access tokens can impact both security and performance:¶
Proper management of cryptographic keys is critical to the security of any FAPI 2.0 deployment. The compromise of private keys used for client authentication, token signing, or message signing can lead to severe security breaches, including unauthorized access to protected resources and impersonation attacks.¶
While detailed guidance on key management is out of scope for the FAPI specifications, implementers should ensure they have robust policies and procedures in place covering:¶
Implementers should refer to established guidance on cryptographic key management, such as NIST Special Publication 800-57 [NIST.SP.800-57pt1r5] and the OWASP Key Management Cheat Sheet [OWASP.KeyManagement].¶
NOTE: Hardware Security Modules (HSMs) or similar secure key storage mechanisms are strongly recommended for production deployments, particularly for high-value use cases.¶
Implementers should consider logging the header size in order to catch issues with large access tokens or other potentially large headers.¶
When access tokens are too large, implementers may encounter the following symptoms:¶
When the authorization server cannot return an error response to the client, for example because the redirect URI is invalid (Section 4.1.2.1 of [RFC6749]), it informs the end-user instead. The message should not be factually incorrect for either the end-user or the client's developer, for example by suggesting that trying again will help when the client's request was invalid. A generic message, such as "Something went wrong", may be used.¶
This document was developed by the OpenID FAPI Working Group.¶
Copyright (c) 2026 The OpenID Foundation.¶
The OpenID Foundation (OIDF) grants to any Contributor, developer, implementer, or other interested party a non-exclusive, royalty free, worldwide copyright license to reproduce, prepare derivative works from, distribute, perform and display, this Implementers Draft, Final Specification, or Final Specification Incorporating Errata Corrections solely for the purposes of (i) developing specifications, and (ii) implementing Implementers Drafts, Final Specifications, and Final Specification Incorporating Errata Corrections based on such documents, provided that attribution be made to the OIDF as the source of the material, but that such attribution does not indicate an endorsement by the OIDF.¶
The technology described in this specification was made available from contributions from various sources, including members of the OpenID Foundation and others. Although the OpenID Foundation has taken steps to help ensure that the technology is available for distribution, it takes no position regarding the validity or scope of any intellectual property or other rights that might be claimed to pertain to the implementation or use of the technology described in this specification or the extent to which any license under such rights might or might not be available; neither does it represent that it has made any independent effort to identify any such rights. The OpenID Foundation and the contributors to this specification make no (and hereby expressly disclaim any) warranties (express, implied, or otherwise), including implied warranties of merchantability, non-infringement, fitness for a particular purpose, or title, related to this specification, and the entire risk as to implementing this specification is assumed by the implementer. The OpenID Intellectual Property Rights policy requires contributors to offer a patent promise not to assert certain patent claims against other contributors and against implementers. The OpenID Foundation invites any interested party to bring to its attention any copyrights, patents, patent applications, or other proprietary rights that may cover technology that may be required to practice this specification.¶
[[ To be removed from the final specification ]]¶
-01¶
x-fapi-interaction-id values that are UUIDs¶