v1

latestOpenAPI 3.1.02026-07-242325051.4 MB
AuthenticationToken

AuthenticationToken:Create

Creates a new authentication token under a merchant. You can also specify which authorisation groups needs to be linked to the token. You can also supply a merchantCode. If a merchantCode is supplied then you need to have access to that merchant. You need to authenticate with an AT-code as username and a token as password

post/v2/authenticationtokens

Request body

merchantCodestring

The merchant id of your company starting with M.

Example request

{
  "merchantCode": "M-1234-4321",
  "authenticationToken": {
    "description": "token1",
    "authorisation": "specified",
    "authorisationGroups": [
      "AG-1234-4321"
    ],
    "ipFilter": {
      "type": "DENY_FROM_ALL",
      "exceptionList": [
        "10.11.12.13"
      ]
    }
  }
}

Response

Created

codestring

The AT-code for an authentication token.

secretstring

A 40 character secret

namestring

The description of the token

authorisation'all' | 'specified'

Specify which kind of authorisation is applicable for the token all: all merchant rights specified: specify which authorisation groups should be enabled from the token. At least one authorisation group (in the authorisationGroups array) is mandatory

authorisationGroupsobject

The authorisation group codes

createdAtstring date-time nullable

The date and time at which this entity was created in ISO-8601 (ATOM) notation

createdBystring nullable

The reference to an account or token whom created the entity

modifiedAtstring date-time nullable

The date and time at which this entity was modified in ISO-8601 (ATOM) notation.

modifiedBystring nullable

The reference to an account or token whom modified this entity

deletedAtstring date-time nullable

The date and time at which this entity was deleted in ISO-8601 (ATOM) notation.

deletedBystring nullable

The reference to an account or token whom deleted the entity

Example response

{
  "code": "AT-1233-1322",
  "secret": "95c4ae0613c23435089dc0b480d98ce786a4e22a",
  "name": "The description of the token",
  "merchant": {
    "code": "M-1234-4321",
    "name": "GMS Demo Merchant",
    "status": "ACTIVE"
  },
  "authorisation": "specified",
  "ipFilter": {
    "type": "DENY_FROM_ALL"
  },
  "createdAt": "2024-06-04T08:15:00+01:00",
  "createdBy": "A-1234-4321",
  "modifiedAt": "2024-06-04T08:15:00+01:00",
  "modifiedBy": "A-1234-4321",
  "deletedAt": "A-1234-4321",
  "deletedBy": "A-1234-4321"
}