Feel free to reach techsupport@surepass.io for any technical support or guidance.
Authorization
header as Bearer TOKEN
.https://sandbox.surepass.io
https://kyc-api.surepass.io
Header | Required | Description |
---|---|---|
Authorization | Yes | Bearer token authentication using JWT token |
Content-Type | Yes | Must be set to multipart/form-data for file uploads |
Parameter | Type | Required | Description |
---|---|---|---|
file | File | Yes | The PDF document to be uploaded |
key | String | Yes | The unique key received from the Get Upload Link response |
AWSAccessKeyId | String | Yes | AWS access key ID received from the Get Upload Link response |
policy | String | Yes | Upload policy received from the Get Upload Link response |
signature | String | Yes | Signature for upload verification received from the Get Upload Link response |
x-amz-security-token | String | Yes | Security token received from the Get Upload Link response |
# This is a multipart/form-data request with the following form fields:
file: [Binary PDF file data]
key: "documents/user123/passport.pdf"
AWSAccessKeyId: "AKIAIOSFODNN7EXAMPLE"
policy: "eyJleHBpcmF0aW9uIjoiMjAyMy0xMi0zMVQwMDowMDowMFoiLCJjb..."
signature: "qKNkVRrZ+qPzxNYOtm+qHg9F4ck="
x-amz-security-token: "IQoJb3JpZ2luX2VjEHgaCXVzLWVhc3QtMSJHMEU..."
Parameter | Type | Description |
---|---|---|
status | String | Status of the upload operation (success/failure) |
message | String | Descriptive message about the upload result |
document_id | String | Unique identifier for the uploaded document |
timestamp | String | Timestamp of when the document was uploaded |
{
"status": "success",
"message": "Document uploaded successfully",
"document_id": "doc_12345abcde",
"timestamp": "2023-07-15T14:32:21Z"
}
{
"status": "error",
"error_code": "AUTH_FAILED",
"message": "Invalid or expired authentication token"
}
curl --location --request POST 'https://kyc-api.surepass.app/api/v1/esign/upload-pdf' \
--form 'x-amz-signature="{{signature}}"' \
--form 'x-amz-date="{{date}}"' \
--form 'x-amz-credential="{{credentials}}"' \
--form 'key="{{upload_key}}"' \
--form 'policy="{{policy}}"' \
--form 'x-amz-algorithmm="{{algorithm}}"' \
--form 'file=@""'
{}