Submit Evidence

POST
/api/v1/customers/{customerId}/rfis/{rfiId}/requirements/{requirementId}/evidence

Submit the evidence an evidence requirement asks for, answers and documents in one request. A complete submission is stored and the requirement moves to submitted for Stables compliance to review; approving it releases the held payment once nothing else is outstanding. Until it is reviewed, a new submission replaces the current one; after Stables sends it back (rejection_reason), submit again. A body that does not fit the form is refused with 400; an incomplete submission, an answer the other answers do not ask for, or a file whose content is not what it claims is refused with 422 and nothing is stored. Answering a resolved RFI or approved evidence is refused with 409. Files travel as base64 data URLs; keep their decoded total under 6MB.

Authorization

headerX-Api-Key<token>

API key in format: sti_env_prefix_secret

Path Parameters

customerId*string

Customer UUID

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid
rfiId*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid
requirementId*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid

Header Parameters

idempotency-key*string

Required for mutating calls. Use a V4 UUID. The server stores the first result for 24h and returns it on subsequent retries with the same key.

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid

Request Body

The answers and documents the requirement's form asks for, keyed by fields[].key and documents[].wire_field. Files are base64 data URLs (data:<mime>;base64,...).

source_of_funds: funds_origin (one of the form's options), funds_origin_explanation, funds_received_on (YYYY-MM-DD), provider_name and provider_relationship when the origin is a gift, loan or inheritance, payer_is_customer (whether the payment came from the customer's own account), payer_name and payer_relationship when it did not (plus payer_relationship_detail when the relationship is OTHER), and supporting_documents (1 to 5 PDF, JPEG or PNG files). Requirements opened before the payer questions were added keep their original form, so read fields from GET …/evidence rather than assuming this list.

ad_hoc with answer_type text: { "answer": "..." } (up to 5000 characters). With answer_type document: { "document": ["data:application/pdf;base64,..."] } (one PDF, JPEG or PNG of at most 5MB).

Keys the form does not list are refused with 400.

application/json
  1. body

The answers and documents the requirement's form asks for, keyed by fields[].key and documents[].wire_field. Files are base64 data URLs (data:<mime>;base64,...).

source_of_funds: funds_origin (one of the form's options), funds_origin_explanation, funds_received_on (YYYY-MM-DD), provider_name and provider_relationship when the origin is a gift, loan or inheritance, payer_is_customer (whether the payment came from the customer's own account), payer_name and payer_relationship when it did not (plus payer_relationship_detail when the relationship is OTHER), and supporting_documents (1 to 5 PDF, JPEG or PNG files). Requirements opened before the payer questions were added keep their original form, so read fields from GET …/evidence rather than assuming this list.

ad_hoc with answer_type text: { "answer": "..." } (up to 5000 characters). With answer_type document: { "document": ["data:application/pdf;base64,..."] } (one PDF, JPEG or PNG of at most 5MB).

Keys the form does not list are refused with 400.

[key: string]?unknown

Response Body

Default Response

application/json
  1. response
rfi*

Request-for-information: what a customer must complete for a held subject

submission*
Example Request
curl -X POST 'https://api.sandbox.stables.money/api/v1/customers/497f6eca-6276-4993-bfeb-53cbbbba6f08/rfis/497f6eca-6276-4993-bfeb-53cbbbba6f08/requirements/497f6eca-6276-4993-bfeb-53cbbbba6f08/evidence' \  -H 'idempotency-key: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \  -H 'Content-Type: application/json' \  -d '{  "property1": null,  "property2": null}'
Example Response
{  "rfi": {    "rfi_id": "67dff3e5-8fe4-4fc3-bd34-9ccc65996247",    "type": "verification",    "status": "open",    "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",    "subject": "customer",    "kyc_level": "string",    "transaction_reference_id": "string",    "transaction_type": "transfer",    "transfer_id": "string",    "virtual_account_id": "string",    "reasons": [      {        "reason_code": "string",        "description": "string"      }    ],    "message": "string",    "billable": true,    "fee": {      "amount_minor": "string",      "currency": "string"    },    "requirements": [      {        "requirement_id": "6bcf6ec7-61c3-4af0-a310-59616a4dac61",        "type": "kyc_level",        "required_level": "string",        "status": "pending",        "action": {          "kind": "verification_link",          "verification_type": "string"        }      }    ],    "rejection_reason": "string",    "rejected_at": "2019-08-24T14:15:22Z",    "created_at": "2019-08-24T14:15:22Z",    "expires_at": "2019-08-24T14:15:22Z",    "resolved_at": "2019-08-24T14:15:22Z"  },  "submission": {    "submission_id": "945dfedc-ad7f-4af7-b20c-06082ffa3cb3",    "submitted_at": "2019-08-24T14:15:22Z",    "answers": {      "property1": null,      "property2": null    },    "documents": [      {        "document_id": "b792e8ae-2cb4-4209-85b9-32be4c2fcdd6",        "kind": "string",        "file_name": "string",        "content_type": "string",        "size_bytes": -9007199254740991      }    ]  }}