Skip to main content
POST
/
nonce
Generar Nonce
curl --request POST \
  --url https://auth.preprod.alignet.io/nonce \
  --header 'ALG-API-VERSION: <alg-api-version>' \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "action": "create.nonce",
  "audience": "https://api.preprod.alignet.io/",
  "client_id": "your_client_id",
  "scope": "post:charges"
}
'
{
  "action": "create.nonce",
  "success": true,
  "nonce": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.........",
  "scope": "post:charges",
  "expires_in": 30,
  "nonce_creation": {
    "meta": {
      "status": {
        "code": "00",
        "message_ilgn": [
          {
            "locale": "es_PE",
            "value": "Codigo Nonce creado"
          }
        ]
      }
    }
  }
}

Headers

ALG-API-VERSION
string
default:1709847567
required

Version del API a usar.

Authorization
string
required

Bearer Token vigente generado previamente desde /token.

Body

application/json
action
string
default:create.nonce
required

Accion a ejecutar.

Example:

"create.nonce"

audience
enum<string>
default:https://api.preprod.alignet.io/
required

URL base del API Orquestador segun el ambiente configurado.

Available options:
https://api.preprod.alignet.io/,
https://api.alignet.io/
Example:

"https://api.preprod.alignet.io/"

client_id
string
default:your_client_id
required

Identificacion del cliente.

Example:

"your_client_id"

scope
string
default:post:charges
required

Permisos a solicitar.

Example:

"post:charges"

Response

Nonce generado correctamente.

action
string
required

Accion ejecutada.

Example:

"create.nonce"

success
boolean
required

Indica si el proceso se realizo correctamente.

Example:

true

nonce_creation
object
required

Objeto que contiene metadatos del flujo ejecutado.

nonce
string

Token temporal a usar en la inicializacion de Pay-me Flex.

Example:

"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9..."

scope
string

Permisos solicitados.

Example:

"post:charges"

expires_in
integer

Tiempo de expiracion del nonce en segundos.

Example:

30