Feel free to reach techsupport@surepass.io for any technical support or guidance.
Authorization header in the following format:Authorization: Bearer <YOUR_JWT_TOKEN>⚠️ Use separate tokens for the sandbox and production environments. Do not use a sandbox token against the production endpoint, or vice versa.
| Environment | Base URL |
|---|---|
| Sandbox | https://sandbox.surepass.app |
| Production | https://kyc-api.surepass.app |
| Header | Required | Description |
|---|---|---|
Authorization | Yes | Bearer token for authentication. Format: Bearer <YOUR_JWT_TOKEN> |
Content-Type | Yes | Must be multipart/form-data since the request body contains a file upload |
multipart/form-data.| Parameter | Type | Required | Description |
|---|---|---|---|
file | file | Yes | The GST certificate document file to be processed. Upload the image or scanned PDF of the GST certificate. |
📌 The filefield must reference a valid local file path. Ensure the file is a clear, legible image or document of the GST registration certificate for optimal OCR accuracy.
| Parameter | Type | Description |
|---|---|---|
data | object | The top-level data object containing OCR results. |
data.client_id | string | A unique identifier for the OCR request, generated by the Surepass system for tracking purposes. |
data.ocr_fields | array | An array of objects containing extracted OCR field data from the submitted document. |
data.ocr_fields[].document_type | string | The type of document identified by the OCR engine. For GST certificates, this will be "gst_reg". |
data.ocr_fields[].gstin | object | An object containing the extracted GSTIN value and its associated confidence score. |
data.ocr_fields[].gstin.value | string | The extracted GSTIN (GST Identification Number) from the document. |
data.ocr_fields[].gstin.confidence | integer | Confidence score (0–100) indicating the OCR engine's certainty in the extracted GSTIN value. Higher is better. |
data.ocr_fields[].standard_document | boolean | Indicates whether the submitted document matches a standard GST registration certificate format (true/false). |
status_code | integer | HTTP-equivalent status code for the API response. 200 indicates a successful operation. |
message_code | string | A machine-readable status code for the response. "success" indicates the request was processed successfully. |
message | string | null | A human-readable message describing the response. Returns null on success. |
success | boolean | Top-level flag indicating whether the API request was successful (true) or not (false). |
{
"data": {
"client_id": "ocr_gst_qpNcekMYzKlvIMenPCRM",
"ocr_fields": [
{
"document_type": "gst_reg",
"gstin": {
"value": "03AAMFB8673Q1ZP",
"confidence": 97
},
"standard_document": true
}
]
},
"status_code": 200,
"message_code": "success",
"message": null,
"success": true
}{
"data": null,
"status_code": 401,
"message_code": "unauthorized",
"message": "Authentication credentials were not provided or are invalid.",
"success": false
}Authorization header is missing, malformed, or contains an invalid/expired JWT token. Ensure you are using a valid Bearer token for the correct environment (sandbox or production).gstin.confidence score returned is below a threshold (e.g., below 85), consider prompting the user to re-upload a clearer image or routing the record for manual review.standard_document: false Gracefully: When the API returns standard_document: false, inform users that the document may not have been recognized as a standard GST certificate and request re-submission with the correct document.curl --location 'https://kyc-api.surepass.app/api/v1/ocr/gst' \
--header 'Authorization: Bearer <token>' \
--form 'file=@""'{
"data": {
"client_id": "ocr_gst_qpNcekMYzKlvIMenPCRM",
"ocr_fields": [
{
"document_type": "gst_reg",
"gstin": {
"value": "03AAMFB8673Q1ZP",
"confidence": 97
},
"standard_document": true
}
]
},
"status_code": 200,
"message_code": "success",
"message": null,
"success": true
}