When a user opens your Core Extension, Nayax passes it a signed JWT token containing the user’s identity and permissions. Your app uses this token to make Nayax API calls on behalf of the logged-in user. You do not manage login or sessions: Nayax handles authentication and hands your app a ready-to-use token at load time. For Screen, Button with Popup, and Tab extensions, the token arrives viaDocumentation Index
Fetch the complete documentation index at: https://devzone.nayax.com/llms.txt
Use this file to discover all available pages before exploring further.
postMessage from the parent frame. If you are building a Fullscreen extension, contact Nayax to confirm the delivery method.
Receiving the token via postMessage
For Screen, Button with Popup, and Tab extensions, listen for amessage event on the window. Nayax posts an object containing the token, the Cortex base URL, and (for Button with Popup and Tab) the selection context.
selection object is only present for Button with Popup and Tab extensions. Screen extensions receive token and cortexUrl only. Nayax can also pass context via the URL hash (for example, /YourApp/index.html#machineId=12345).
Token payload
The token is signed with RS256. Here is an example payload:Token claims
| Claim | Description |
|---|---|
id | User ID |
name | Username with domain |
actor | Actor ID |
OperatorId | Operator ID |
DistributorId | Distributor ID |
IsAdmin | Admin flag |
ActorHierarchy | Actor hierarchy chain |
AppName | Application name |
realUserId | Real user ID |
email | User email |
nbf | Not before (Unix timestamp) |
exp | Expiration (Unix timestamp) |
iat | Issued at (Unix timestamp) |
iss | Issuer |
aud | Audience |
Validating the token
Validate the JWT signature using the RSA public key for your environment.- QA / Development
- Production
Use the QA key during sandbox development. Switch to the production key when you deploy to production.
Scopes
Scopes control which Nayax resources your app can access. Nayax injects them into the JWT token when your app is registered. There are two scope types:| Value | Type | Behavior |
|---|---|---|
scope | Limiting | Your app can only access resources within both the user’s permissions and the specified scopes. Use this to restrict access even when the user has broader permissions. |
appScope | Overriding | Your app receives the specified scopes regardless of the user’s normal permissions. Use this to grant your app access that users might not otherwise have. |
Next steps
Extension Types
See which display type is right for your app and how each one works.
Get Started
Walk through the full developer journey from sandbox to production.