Document & Evidence

A document is a request for supporting documentation. An evidence is the proof provided in response by the third party or an external source.

Definitions

πŸ“„

Document (Request)

Represents a document requested in a dossier.

  • documentId β€” Unique identifier
  • documentCode β€” Document type code
  • documentName β€” Document label
  • statusCode β€” Current status
  • present β€” Document provided or not
πŸ“Ž

Evidence (Proof)

The response provided by the third party or an external source.

  • id β€” Evidence identifier
  • responseId β€” ID for actions
  • uploadDate β€” Upload date
  • expirationDate β€” Expiration date
  • formdata β€” Form data

Evidence Types

An evidence can take two forms depending on the type of document requested:

TypeDescriptionSpecific Properties
Uploaded filePDF document, image or other file uploaded by the third partyfileUUID, fileName, fileSize
Completed formResponses to a structured questionnaireformdata[]
Generated PDF for forms

For completed forms, Aprovall automatically generates a PDF consolidating all third party responses, downloadable via the API.

List Documents in a Dossier

Retrieve all requested documents in a dossier with their status and evidence.

GET/api/v1/account/:accountId/dossiers/:dossierId/documents

Lists all documents in a dossier with their evidence.

Response Example

{
  "content": [
    {
      "documentId": 11078435,
      "dossierId": 1324073,
      "documentCode": "ATT_URSSAF",
      "documentName": "Attestation de vigilance URSSAF",
      "requestDate": "2025-01-15T10:00:00.000",
      "present": true,
      "statusCode": "VALID",
      "evidences": [
        {
          "id": 6876412,
          "responseId": 2238768,
          "uploadDate": "2025-01-20T14:30:00.000",
          "fileUUID": "a4d8acd5-8254-477c-9019-fa85aef8d224",
          "fileName": "attestation_urssaf.pdf",
          "fileSize": 128790,
          "expirationDate": "2025-07-20T23:59:59.999",
          "format": "ORIGINALNUMERIQUE",
          "issuer": "DO",
          "transmitter": "FOURNISSEUR"
        }
      ]
    },
    {
      "documentId": 11031065,
      "dossierId": 1324073,
      "documentCode": "KBIS",
      "documentName": "Extrait Kbis",
      "requestDate": "2025-01-15T10:00:00.000",
      "present": false,
      "statusCode": "MISSING",
      "evidences": []
    }
  ]
}

Document Details

Retrieve detailed information about a specific document.

GET/api/v1/account/:accountId/dossiers/:dossierId/documents/:documentId

Returns document details and its evidence.

Evidence Structure

Each evidence contains metadata about the provided proof:

PropertyTypeDescription
idnumberUnique evidence identifier
responseIdnumberResponse ID (used for approve/reject)
uploadDatedatetimeUpload date and time
fileUUIDstringStored file UUID
fileNamestringOriginal file name
fileSizenumberFile size in bytes
expirationDatedatetimeDocument expiration date
formdataarrayForm data (if applicable)
issuerstringIssuer (DO = Data Owner)
transmitterstringTransmitter (SUPPLIER, etc.)
metadataobjectVerification metadata (IBAN, etc.)

Forms: formdata Structure

For form-type documents, the formdata array contains structured responses:

{
  "formdata": [
    {
      "type": "string",
      "key": "f_158_nmr_0",
      "title": "Nom ou rΓ©fΓ©rence de l'opΓ©ration",
      "order": 0,
      "value": "Projet Alpha"
    },
    {
      "type": "date",
      "key": "f_158_dtd_2",
      "title": "Date de rΓ©alisation",
      "order": 2,
      "value": "15/01/2025"
    },
    {
      "type": "iban",
      "key": "f_49_bn_0",
      "title": "IBAN",
      "order": 0,
      "value": "FR76 0000 0000 0000 0000 0000 000"
    }
  ]
}

Field Types

TypeDescription
stringFree text
dateDate in DD/MM/YYYY format
ibanIBAN bank details
booleanYes / No
numberNumeric value

Download a File

Multiple methods to retrieve evidence files:

GET/api/v1/account/:accountId/dossiers/:dossierId/documents/:documentId/files/:fileId

Downloads the file in binary (PDF). The fileId corresponds to the evidence id.

GET/api/v1/account/:accountId/dossiers/:dossierId/documents/:documentId/files/:fileId/link

Generates a temporary signed URL for download.

GET/api/v1/account/:accountId/dossiers/:dossierId/files/download

Downloads all dossier files in a ZIP archive.

Document Actions

When a document is in ACTION_REQUIRED status, you can approve or reject it via the API.

responseId Identifier

Actions use the responseId present in the evidence object, not the documentId.

Approve a Document

POST/api/v1/account/:accountId/responses/:responseId/approve
curl -X POST https://edge.aprovall.com/api/v1/account/123/responses/2238768/approve \
  -H "Authorization: Bearer VOTRE_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "comment": "Document conforme"
  }'
ParameterRequiredDescription
commentNoOptional validation comment

Reject a Document

POST/api/v1/account/:accountId/responses/:responseId/reject
curl -X POST https://edge.aprovall.com/api/v1/account/123/responses/2238768/reject \
  -H "Authorization: Bearer VOTRE_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "comment": "Document expirΓ©",
    "shareRejectionReason": true
  }'
ParameterRequiredDescription
commentNoRejection reason
shareRejectionReasonYesIf true, the third party is notified by email of the rejection

Add a Required Document

You can add additional documents to an existing dossier (except for typed dossiers where the list is fixed).

POST/api/v1/account/:accountId/dossiers/:dossierId/requirements
curl -X POST https://edge.aprovall.com/api/v1/account/123/dossiers/456/requirements \
  -H "Authorization: Bearer VOTRE_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "newRequiredDocuments": ["JUSTIF_IMM", "ATT_FISC"]
  }'

Automatic Verifications

Some documents undergo automatic verifications by Aprovall. Results are available in the evidence metadata field.

Example: IBAN Verification

For IBAN documents, verification may include SEPAmail or Trustpair data:

{
  "metadata": {
    "verified": "true",
    "bank_data_bank": "CREDIT DU NORD",
    "bank_data_bic": "NORDXXXX",
    "bank_data_country": "FRANCE",
    "sepa_data_sct": "YES",
    "sepa_data_sdd": "YES",
    "date_verification": "15/01/2025"
  }
}

Next Steps