Skip to main content
POST
/
kyb
/
tokens
Generate KYB form token
curl --request POST \
  --url https://api.example.com/kyb/tokens/ \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "tokenType": "FORM",
  "clientId": "<string>",
  "lifetime": 3600,
  "externalRef": "<string>",
  "locale": "en",
  "flow": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "theme": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "questionnaire": "<string>",
  "questionnaireRequired": true,
  "tags": [],
  "scanRefs": [
    "<string>"
  ]
}
'
{
  "tokenType": "FORM",
  "tokenString": "<string>",
  "expiration": "2023-11-07T05:31:56Z",
  "isActive": true,
  "isValid": true,
  "companyId": "<string>",
  "clientId": "<string>",
  "externalRef": "<string>",
  "locale": "en",
  "flow": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "theme": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "tags": [],
  "scanRefs": [
    "<string>"
  ]
}

Authorizations

Authorization
string
header
required

The request must contain basic auth headers where username is API key and password is API secret.
In order for you to start using our API you will need an API key and API secret.
Both can be retrieved by contacting iDenfy's support or iDenfy's sales team.

Body

application/json
tokenType
enum<string>
required
Available options:
FORM,
GOV1,
GOV2
clientId
string
required

A unique string identifying a client on your side.

Required string length: 1 - 100
lifetime
integer
default:3600

The duration in seconds of KYB token validity.

Required range: 0 <= x <= 2592000
externalRef
string | null

Any additional value chosen by you.

Maximum string length: 40
locale
enum<string>

The default client's language. By default selected by a client's IP address.

Available options:
en,
es,
fr,
ru,
de,
it,
pl,
lt,
lv,
et,
cs,
ro,
hu,
ja,
bg,
nl,
pt
flow
string<uuid> | null

KYB flow's id to use for this KYB session.

theme
string<uuid> | null

KYB theme's id to use for this KYB session.

questionnaire
string | null

KYB questionnaire's key to use for this KYB session. null for no questionnaire. If not given, the default questionnaire (from your KYB settings) will be used. Ignored when KYB flow is used, then questionnaire is taken according to used flow.

Minimum string length: 1
questionnaireRequired
boolean
default:true

If KYB session should have a questionnaire.

tags
string[]

List of case-sensitive strings. Each tag can not be longer than 32 characters.

Maximum array length: 5
Required string length: 1 - 32
Pattern: ^[^,]+$
scanRefs
string[] | null
Required string length: 1 - 40
Pattern: ^[^,]+$

Response

201 - application/json
tokenType
enum<string>
required
Available options:
FORM,
GOV1,
GOV2
tokenString
string
required

Token string used for authentication.

expiration
string<date-time>
required

Date and time when this token will become expired.

isActive
boolean
required
deprecated

Indicates whether this token is not deactivated.

isValid
boolean
required

Indicates whether this token is valid.

companyId
string | null
required
clientId
string
required

A unique string identifying a client on your side.

Maximum string length: 100
externalRef
string | null

Any additional value chosen by you.

Maximum string length: 40
locale
enum<string>

The default client's language. By default selected by a client's IP address.

Available options:
en,
es,
fr,
ru,
de,
it,
pl,
lt,
lv,
et,
cs,
ro,
hu,
ja,
bg,
nl,
pt
flow
string<uuid> | null

KYB flow's id to use for this KYB session.

theme
string<uuid> | null

KYB theme's id to use for this KYB session.

tags
string[]

List of case-sensitive strings. Each tag can not be longer than 32 characters.

Maximum array length: 5
Maximum string length: 32
Pattern: ^[^,]+$
scanRefs
string[] | null
Maximum string length: 40
Pattern: ^[^,]+$