Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
JavaScript Examples for Headless Identity APIs
| Available in: both Salesforce Classic (not available in all orgs) and Lightning Experience |
| Available in: Enterprise, Unlimited, and Developer Editions |
These examples are for demonstration only and aren’t meant to be used in production. Always test code before deploying it to a production environment.
Unlike the Postman examples, these examples use the Proof Key for Code Exchange (PKCE) extension, which improves security. We strongly recommend that you always use PKCE when configuring these flows with public clients.
The examples present a simplified overview of each headless flow for public clients. For in-depth descriptions of the flows for both public and private clients, see these resources in Salesforce Help.
- Headless Identity APIs for Customers and Partners
- Authorization Code and Credentials Flow for Public Clients
- Authorization Code and Credentials Flow for Private Clients
- Headless Registration Flow for Public Clients
- Headless Registration Flow for Private Clients
- Headless Forgot Password Flow—You can use this resource for public and private clients.