/document_types
List the document types for KYC supporting documentation
During the KYC onboarding process, it may be necessary to upload supporting documentation. This endpoint will list the document types.
The name
and identity_type
values retrieved here for a given document type should be used when uploading with /documents, and name
can be used as a search filter when listing uploaded documents with /list_documents.
Requests
The request body at this endpoint is the header_msg
JSON object.
Authorization / Authentication
Apps using Access Token Authorization
Use a valid access token in a Authorization: Bearer request header.
See Authenticating with an Access Token for more details.
Apps using ECDSA Authentication
Only the authsignature
header is required for this request.
See the section on ECDSA Authentication for more detail about ECDSA signature generation.
Pagination
This endpoint supports pagination via URL query parameters:
/document_types?page=1&per_page=20
- page: page number to retrieve. default: 1
- per_page: number of items per page. default: 20, max: 100
Default page size will not include all items
Please note that this endpoint currently returns 28 document types, which is in excess of the default
per_page
value of 20. If you wish to retrieve all items in one request, use the?per_page=100
query parameter.
POST /0.2/document_types HTTP/1.1
sandbox.silamoney.com
Content-Type: application/json
// if using OAuth2
Authorization: Bearer [GENERATED JWT TOKEN HERE]
// if using ECDSA
authsignature: [GENERATED AUTHSIGNATURE HEX STRING HERE]
{
"header": {
"created": 1234567890,
"auth_handle": "handle.silamoney.eth",
"version": "0.2",
"reference": "<your unique id>"
}
}
***
HTTP/1.1 200 OK
{
"success": true,
"status": "SUCCESS",
"response_time_ms": "171",
"reference": "<your unique id>",
"message": "Document type details returned.",
"document_types" : [
{
"name": "bank_statement",
"label": "Bank Statement",
"identity_type": "other"
},
{
"name": "doc_green_card",
"label": "Permanent Resident Card (or Green Card)",
"identity_type": "other"
},
{
"name": "doc_lease",
"label": "Lease agreement",
"identity_type": "contract"
},
{
"name": "doc_mortgage",
"label": "Mortgage agreement",
"identity_type": "contract"
},
{
"name": "doc_name_change",
"label": "Court Order for Name Change",
"identity_type": "other"
},
{
"name": "doc_paystub",
"label": "Pay Stub Documentation",
"identity_type": "other"
},
{
"name": "doc_ssa",
"label": "Social Security Administration documentation (includes 4029)",
"identity_type": "other"
},
{
"name": "doc_ss_card",
"label": "Social Security Card",
"identity_type": "other"
},
{
"name": "doc_tuition",
"label": "Tuition Statement",
"identity_type": "other"
},
{
"name": "doc_uo_benefits",
"label": "Unemployment Benefits Letter",
"identity_type": "other"
},
{
"name": "doc_utility",
"label": "Utility bill",
"identity_type": "utility"
},
{
"name": "id_drivers_license",
"label": "State-issued driver's license",
"identity_type": "license"
},
{
"name": "id_drivers_permit",
"label": "Driver's permit",
"identity_type": "license"
},
{
"name": "id_military",
"label": "Military ID",
"identity_type": "other"
},
{
"name": "id_military_dependent",
"label": "Military Dependent's ID Card",
"identity_type": "other"
},
{
"name": "id_nyc_id",
"label": "NYC ID Card",
"identity_type": "other"
},
{
"name": "id_passport",
"label": "Passport",
"identity_type": "passport"
},
{
"name": "id_passport_card",
"label": "US Passport Card",
"identity_type": "passport"
},
{
"name": "id_state",
"label": "State ID card",
"identity_type": "other"
},
{
"name": "other_doc",
"label": "Other Document",
"identity_type": "other"
},
{
"name": "other_id",
"label": "Other ID",
"identity_type": "other"
},
{
"name": "tax_1040",
"label": "1040 Tax Return",
"identity_type": "other"
},
{
"name": "tax_1095",
"label": "Tax Form 1095",
"identity_type": "other"
},
{
"name": "tax_1099",
"label": "Tax Form 1099",
"identity_type": "other"
},
{
"name": "tax_w2",
"label": "IRS form W2",
"identity_type": "other"
},
{
"name": "tax_W4",
"label": "W4 Withholding Allowance Certificate",
"identity_type": "other"
},
{
"name": "verification_letter",
"label": "Account Verification Letter",
"identity_type": "other"
},
{
"name": "vtl_birth_certificate",
"label": "Birth Certificate",
"identity_type": "other"
},
{
"name": "vtl_divorce",
"label": "Divorce Decree",
"identity_type": "other"
},
{
"name": "vtl_marriage",
"label": "Marriage Certificate",
"identity_type": "other"
}
],
"pagination": {
"returned_count": 31,
"total_count": 31,
"current_page": 1,
"total_pages": 1
}
}
// Pagination is optional
const pagination = {
page: 1,
perPage: 5,
};
const res = await sila.getDocumentTypes(pagination);
// Success Response Object
console.log(res.statusCode); // 2000
console.log(res.data.success); // true
console.log(res.data.status); // SUCCESS
console.log(res.data.message); // Document type details returned
console.log(res.data.document_types[0].name);
console.log(res.data.document_types[0].label);
console.log(res.data.document_types[0].identity_type);
console.log(res.data.pagination); // Pagination information (returned_count, total_count, current_page, total_pages)
response = silasdk.Documents.listSupportedDocuments(app, page, perPage)
# Success Response Object
{
"success": true,
"status": "SUCCESS",
"message": "Document type details returned.",
"document_types" : [
{
"name": "doc_green_card",
"label": "Permanent Resident Card (or Green Card)",
"identity_type": "other"
},
...
],
"pagination": {
"returned_count": 28,
"total_count": 28,
"current_page": 1,
"total_pages": 1
}
}
// With no pagination
ApiResponse response = api.getDocumentTypes();
// With pagination
PaginationMessage pagination = PaginationMessage.builder()
.page(1) // Optional. The page of the request
.perPage(40) // Optional. The amount of results per page
.build();
ApiResponse response = api.getDocumentTypes(pagination);
// Success response
System.out.println(response.getStatusCode()); // 200
DocumentTypesResponse parsedResponse = (DocumentTypesResponse)response.getData();
System.out.println(parsedResponse.getSuccess()); // true
System.out.println(parsedResponse.getStatus()); // SUCCESS
System.out.println(parsedResponse.getMessage()); // Document type details returned.
System.out.println(parsedResponse.getDocumentTypes()); // List of DocumentType
System.out.println(parsedResponse.getDocumentTypes().get(0).getName()); // Document type name
System.out.println(parsedResponse.getDocumentTypes().get(0).getLabel()); // Document type label
System.out.println(parsedResponse.getDocumentTypes().get(0).getIdentityType()); // Document type identity type
System.out.println(parsedResponse.getPagination().getCurrentPage());
System.out.println(parsedResponse.getPagination().getReturnedCount());
System.out.println(parsedResponse.getPagination().getTotalPages());
System.out.println(parsedResponse.getPagination().getTotalCount());
$page = 1; // Optional. The page number to get
$perPage = 5 // Optional. The number of document types per page. The default value is 20 and the maxium is 100.
$response = $client->getDocumentTypes($page, $perPage);
echo $response->getStatusCode(); // 200
echo $response->getData()->success; // TRUE
echo $response->getData()->status; // SUCCESS
echo $response->getData()->message; // Document type details returned.
echo $response->getData()->document_types; // An array of document types (name, label, identity_type)
echo $response->getData()->pagination; // Pagination details (returned_count, total_count, current_page, total_pages)
int page = 1; // Optional. The page number to get
int perPage = 20; // Optional. The number of entities pe
var response = api.GetDocumentTypes(page, perPage);
// Success response object
Console.WriteLine(response.StatusCode); // 200
var parsedResponse = (DocumentTypesResponse)response.Data;
Console.WriteLine(parsedResponse.Success);
Console.WriteLine(parsedResponse.Status);
Console.WriteLine(parsedResponse.Message);
Console.WriteLine(parsedResponse.DocumentTypes.Count);
Console.WriteLine(parsedResponse.DocumentTypes[0].Name);
Console.WriteLine(parsedResponse.DocumentTypes[0].Label);
Console.WriteLine(parsedResponse.DocumentTypes[0].IdentityType);
Console.WriteLine(parsedResponse.Pagination.CurrentPage);
Console.WriteLine(parsedResponse.Pagination.ReturnedCount);
Console.WriteLine(parsedResponse.Pagination.TotalCount);
Console.WriteLine(parsedResponse.Pagination.TotalPages);
Supported Document Types
Document Type long-form (label) | Document Type short‑form (name) | Identity Type |
---|---|---|
1040 Tax Return | tax_1040 | other |
Birth Certificate | vtl_birth_certificate | other |
Court Order for Name Change | doc_name_change | other |
Divorce Decree | vtl_divorce | other |
Driver's permit | id_drivers_permit | license |
IRS form W2 | tax_w2 | other |
Lease agreement | doc_lease | contract |
Marriage Certificate | vtl_marriage | other |
Military Dependent's ID Card | id_military_dependent | other |
Military ID | id_military | other |
Mortgage agreement | doc_mortgage | contract |
NYC ID Card | id_nyc_id | other |
Other Document | other_doc | other |
Other ID | other_id | other |
Passport | id_passport | passport |
Pay Stub Documentation | doc_paystub | other |
Permanent Resident Card (or Green Card) | doc_green_card | other |
Social Security Administration documentation (includes 4029) | doc_ssa | other |
Social Security Card | doc_ss_card | other |
State ID card | id_state | other |
State-issued driver's license | id_drivers_license | license |
Tax Form 1095 | tax_1095 | other |
Tax Form 1099 | tax_1099 | other |
Tuition Statement | doc_tuition | other |
Unemployment Benefits Letter | doc_uo_benefits | other |
US Passport Card | id_passport_card | passport |
Utility bill | doc_utility | utility |
W4 Withholding Allowance Certificate | tax_W4 | other |
Account Verification Letter | verification_letter | other |
Bank Statement | bank_statement | other |
Responses
Status Code | success | Description |
---|---|---|
200 | true | document_type details returned |
See Also:
Updated about 1 month ago