---
title: "Generate KYB form token"
method: POST
path: "/kyb/tokens/"
tags: ["KYB Token"]
---

# Generate KYB form token

`POST /kyb/tokens/`

## Request

- Base URL: `https://ivs.idenfy.com`
- URL: `https://ivs.idenfy.com/kyb/tokens/`
- Auth: HTTP basic
- TypeScript: <https://skmtc.dev/idenfy/apis/idenfy-ivs-core-api/docs/kyb/tokens/post.ts> (a function with typed inputs; its response is checked against the schema)

## Request body

- KybTokenRequest
  - `tokenType` 'FORM' | 'GOV1' | 'GOV2', required
  - `lifetime` integer: The duration in seconds of KYB token validity.
  - `clientId` string, required: A unique string identifying a client on your side.
  - `externalRef` string, nullable: Any additional value chosen by you.
  - `locale` 'en' | 'es' | 'fr' | 'ru' | 'de' | 'it' | 'pl' | 'lt' | 'lv' | 'et' | 'cs' | 'ro' | 'hu' | 'ja' | 'bg' | 'nl' | 'pt'
  - `flow` string, uuid, nullable: KYB flow's `id` to use for this KYB session.
  - `theme` string, uuid, nullable: KYB theme's `id` to use for this KYB session.
  - `questionnaire` string, nullable: 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.
  - `questionnaireRequired` boolean: If KYB session should have a questionnaire.
  - `tags` string[]: List of case-sensitive strings. Each tag can not be longer than 32 characters.
  - `scanRefs` string[], nullable

## Response `201`

- KybToken
  - `tokenType` 'FORM' | 'GOV1' | 'GOV2', required
  - `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: Indicates whether this token is not deactivated.
  - `isValid` boolean, required: Indicates whether this token is valid.
  - `companyId` string, nullable, required
  - `clientId` string, required: A unique string identifying a client on your side.
  - `externalRef` string, nullable: Any additional value chosen by you.
  - `locale` 'en' | 'es' | 'fr' | 'ru' | 'de' | 'it' | 'pl' | 'lt' | 'lv' | 'et' | 'cs' | 'ro' | 'hu' | 'ja' | 'bg' | 'nl' | 'pt'
  - `flow` string, uuid, nullable: KYB flow's `id` to use for this KYB session.
  - `theme` string, uuid, nullable: 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.
  - `scanRefs` string[], nullable

---

[API](https://skmtc.dev/idenfy/apis/idenfy-ivs-core-api.md) - [All operations](https://skmtc.dev/idenfy/apis/idenfy-ivs-core-api/llms.txt) - [OpenAPI document](https://skmtc.dev/idenfy/apis/idenfy-ivs-core-api/revisions/3540d9ee5506?raw)
