Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,059 of 9,059 pages
About the help in other languages
All help pages

Choosing credentials for an integration

The credentials Exponential accepts from other systems - OAuth 2.0 tokens, personal API keys, expservices tokens, HTTP basic authentication, session sign-in - what each is for, how it is limited, and how to store and…

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/help/integrators/choosing-credentials-for-an-integration.md

On this page

Choosing credentials for an integration

This page is for integration developers and administrators who must decide how another system proves who it is to Exponential. Every credential in Exponential stands for one user, and a request made with it can never do more than that user's roles allow. The choice is about who that user is, how long the credential lives and how it is revoked.

Contents

  1. The credentials
  2. Which one for which job
  3. Limits that always apply
  4. Storing and rotating credentials
  5. Checklist

The credentials

CredentialLooks likeSent asWorks forMade byEnds
OAuth 2.0 access token40 hexadecimal charactersAuthorization: Bearer <token> or Authorization: OAuth <token>REST API (/api/...)An app after the user allowed it at oauth/authorize; token from POST /api/auth/v1/oauth/tokenAfter rest.ini [OAuthSettings] TokenTTL (3600 seconds); renewed with the refresh token
Personal API keyexpk_ + 12 + _ + 40 charactersAuthorization: Bearer expk_... only (refused in the address)REST APIThe user at My account > API access (/apikey/list), with apikey/createRevoked, expired (MaxExpiryDays, default 365), or owner disabled
expservices tokenexpt_ + 48 hexadecimal charactersAuthorization: Bearer <token> or X-Exp-Token: <token>/ezjscore/call/exp... servicesThe user with expsession::tokenCreateRevoked (expsession::tokenRevoke), expired, or owner disabled
HTTP basic authenticationlogin and passwordAuthorization: Basic ...REST API when rest.ini [Authentication] AuthenticationStyle=ezpRestBasicAuthStyle; WebDAVThe user accountWhen the password changes
Session sign-insession cookie plus form tokenCookie and ezxform_tokenexpservices and ezjscore calls from a browser or a script that signs inuser/loginSession end

The REST layer resolves a personal API key in expApiKeyAuthFilter (kernel/private/rest/classes/auth/apikey_auth_filter.php) for both kernel authentication styles, so keys work whether the site uses OAuth or basic authentication.

Which one for which job

JobUseWhy
A script or server of your company that reads or publishes content through RESTA personal API key of a service accountOne key per program, scoped (read, publish, edit, remove), revocable on its own, audited
An app that lets many people sign in and act as themselvesAn OAuth applicationEach user allows the app; the token acts as that user
A script that calls expservices (caches, content jobs, users, ...)An expservices token of a service accountNo form token needed for writes; revocable
A browser page on the same siteThe sessionIt is already there; writes carry the form token
A desktop tool mounting content as a driveBasic authentication over HTTPS (WebDAV)WebDAV clients speak it
A legacy client that only knows basic authenticationBasic authentication over HTTPS, with a dedicated accountLast resort: the password opens every page the account may open

Note

A password is the widest credential: it signs in everywhere the account may go, and changing it breaks every program at once. Prefer a key or token whenever the surface accepts one (Personal API keys).

Limits that always apply

  • Never more than the user. Every REST read and write asks the user's policies through expRestContentPermission; every expservices service declares its access and checks it. A key's scope is checked again on each request against the owner's current policies.
  • Rate limit for keys. rest.ini [ApiKeySettings] RateLimitPerMinute=120 per key, counted in APCu; over the limit the answer is 429 with Retry-After.
  • Header only for keys. A key in oauth_token, access_token or api_key of the address or body is refused without a lookup.
  • HTTPS. rest.ini [Authentication] RequireHTTPS can refuse plain HTTP for the REST API; serve every API over HTTPS regardless.
  • Proxies. If a proxy or Apache with PHP-FPM drops the Authorization header, keys and tokens fail with 401. Pass the header (CGIPassAuth On), or use X-Exp-Token for expservices.

Storing and rotating credentials

DoDo not
Keep keys and tokens in the calling system's secret store or environment variablesPut them in Git, in a template, in a URL, or in a shared script
Make one credential per program and per environmentShare one key between test and production
Rotate by making the new key first, switching, checking Last used, then revoking the old oneRevoke first and fix the program afterwards
Teach your secret scanner the prefixes expk_ and expt_Paste keys into tickets or chats
Revoke at once when a credential may have been seenWait for it to expire

Every make, revoke, first use and refusal of a key is recorded in the audit trail as access.apikey.*; expservices tokens as access.expservices.token.*:

php bin/php/console exp:audit tail --channel=access --name='access.apikey.*' --lines=20 --allow-root-user

Checklist

  • To do: One service account per integration, with a narrow role (how).
  • To do: The credential type chosen per data flow and written into the interface specification.
  • To do: Scopes limited to what the flow needs (a reading integration gets read only).
  • To do: Expiry date set and a rotation date in the operations calendar.
  • To do: The credential stored outside Git; its location named in the runbook.
  • To do: The audit events checked after the first run.

Become an Exponential Partner

Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x