Get KYC Document

Download one of the Customer's KYC documents

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Returns a link to download one of the documents listed in the Customer's documents (for example, the front of the ID or the selfie captured during the KYC).

🚧

Enabled per agreement

Lirium enables document sharing for your integration when your agreement covers it, separately for individual Customers (KYC) and business Customers (KYB). The Customer's type tells which one applies. Until then, documents is an empty list and this endpoint answers 404; after Lirium enables it, allow a few minutes before documents lists anything. Ask Lirium to enable document sharing and to add customer_document_read to your API key.

📘

Required scope

The API key must have customer_document_read. read alone is not enough: a key without it gets a 403 with error_code forbidden. Listing documents on the Customer needs no extra scope.

How to download a document

  1. Read the Customer with Customer Details. The Customer product changed and Customer requirement rejected webhooks carry the same documents, but they can be sent before the files are stored (see below).
  2. Pick the document from documents by its type, or by data_requirement_id to match an entry in data_requirements.
  3. Call this endpoint with its id, and download the file with a plain GET to url, without your Authorization header.

A document is listed once its file is stored, which can be after its requirement is approved, and no webhook announces it. In a KYC Lirium performs, the ID and the selfie usually arrive after the Customer product changed webhook that announces the approval. If a document you expect is missing, read the Customer again a few minutes later with Customer Details, and contact Lirium if it is still missing.

Response fields

FieldTypeRequiredDescription
idstringYesID of the document.
createdtimestampYesWhen the document was submitted.
typestringYesDocument type: id_front, id_back, proof_of_address, selfie, or an additional type enabled for your integration (see Upload KYC Document).
data_requirement_idstringNoID of the entry in data_requirements the document was submitted for. Omitted when it was not submitted for one.
urlstringYesLink to download the file.
⚠️

Do not store the link

url expires after a short time. Call this endpoint each time you need the file.

Daily limit

Each integration has a daily limit of calls to this endpoint; ask Lirium for yours. Every call that passes authentication and the scope check counts, including the ones answered with 404 or 429. Past the limit, you get a 429 with error_code too_many_requests and a Retry-After header with the seconds left until the limit resets at 00:00 UTC.

Error Responses

Error responses follow the format described in Errors and Error Codes.

StatusError CodeDescription
403forbiddenThe API key does not have the customer_document_read scope
404not_foundCustomer not found: the Customer does not exist or is not yours
404not_foundDocument not found: the document is not in the Customer's documents. For example, a wrong id, sharing not enabled for this Customer type (or just turned off), or a document replaced by a newer submission
429too_many_requestsThe daily limit was reached; retry after the seconds in Retry-After
Path Params
string
required

ID of the customer

string
required

ID of the document, as listed in the Customer's documents

Responses

Language
Credentials
Header
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json