Request PIN Control Access Token
Send a request to this endpoint to generate a PIN control access token for a specific card version. The requested scope determines which PIN operation the token authorises: VIEW_PIN, SET_PIN or CHANGE_PIN. If no sequenceNumber is provided, the latest card version is used.
For the SET_PIN scope, sequenceNumber is ignored and the latest card version is always used, because a PIN can only be set on the latest card version.
For multi-application cards, the SET_PIN and CHANGE_PIN scopes can only be requested for the main card, not for its card applications; requesting either scope for a card application returns 400.
A successful response returns the token id, a pinUrl for the mobile device webview and a pinFrameUrl for the desktop browser iframe. Both URLs are specific to the requested scope. The token is valid for 30 seconds.
For the mobile webview flow, the device sends another API request — a POST to the pinUrl, including the token id in a parameter named controlId.
For the desktop browser flow, open an iframe to the pinFrameUrl. After the iframe has loaded, the browser makes a window.postMessage() call to the iframe. The message object contains an operation field (view-pin for the VIEW_PIN scope, set-pin for the SET_PIN and CHANGE_PIN scopes) and a controlId field (the token id).
Note that you must use set-pin as the operation for the CHANGE_PIN scope as well.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Optional audit user header
Path Parameters
Unique identifier of the card for which you want to access the PIN.
Body
Describes the scope of the operation authorised by the user.
VIEW_PIN, SET_PIN, CHANGE_PIN "VIEW_PIN"
The sequence number of the card version, this value is also known as PSN (pan sequence number)
x >= 11
Response
Successful creation of the PIN control access token
The ID of this PIN Control access token.
"20218aae-b15e-406c-9e9f-23735cd86a48"
The URL that the cardholder's mobile device webview should browse to for accessing the PIN.
"https://api.tenant.sandbox.mycore.enfuce.com/issuer-web/pin/view"
The URL of the iframe for desktop browser based flows for accessing PIN.
"https://api.tenant.sandbox.mycore.enfuce.com/issuer-web/pin/view/frame"

