Identities

Detokenize field

Detokenize a single identity field with the TypeScript SDK.

GET/identities/{identity_id}/detokenize/{field}

Use blnk.Identity.detokenizeField to detokenize one identity field.

Call the method

const response = await blnk.Identity.detokenizeField(
  'idt_3b63c8da-af29-4cc3-ad38-df17d87456e6',
  'EmailAddress',
);
FieldTypeDescription
idstringIdentity ID.
fieldstringPascalCase field name to detokenize.

Use the plaintext value

Read response.data.value for the original field value. Handle it securely and avoid logging it.

Response

{
  "field": "EmailAddress",
  "value": "alice.smith@example.com"
}
FieldTypeDescription
fieldstringField you detokenized.
valuestringOriginal plaintext value.