POST
/
v1
/
file-upload
File Upload
curl --request POST \
  --url https://api.eka.care/v1/file-upload \
  --header 'Authorization: Bearer <token>'
{
  "uploadData": {
    "url": "https://m-prod-ekascribe-batch.s3.amazonaws.com/",
    "fields": {
      "x-amz-meta-mode": "dictation",
      "key": "EC_173210496011417/txn_301/20250617_105524/${filename}",
      "x-amz-algorithm": "AWS4-HMAC-SHA256",
      "x-amz-credential": "ASIAYES5P2B2ZIB4II4R/20250617/ap-south-1/s3/aws4_request",
      "x-amz-date": "20250617T105524Z",
      "x-amz-security-token": "<string>",
      "policy": "<string>",
      "x-amz-signature": "<string>"
    }
  },
  "folderPath": "EC_173210496011417/txn_301/20250617_105524/",
  "txn_id": "txn_301"
}

Parameters

ParameterTypeRequiredDescription
txn_idstringYesSession ID for file upload
actionstringNoUpload action: ekascribe-v2

Response

{
    "uploadData": {
        "url": "https://m-prod-ekascribe-batch.s3.amazonaws.com/",
        "fields": {
            "x-amz-meta-mode": "dictation",
            "x-amz-meta-uhid": "unique_patient_id",
            "x-amz-meta-hfid": "unique_health_facility_id",
            "key": "EC_173210496011417/txn_301/20250617_105524/${filename}",
            "x-amz-algorithm": "AWS4-HMAC-SHA256",
            "x-amz-credential": "...",
            "x-amz-date": "...",
            "policy": "...",
            "x-amz-signature": "..."
        }
    },
    "folderPath": "EC_173210496011417/txn_301/20250617_105524/",
    "txn_id": "txn_301"
}

HTTP Status Codes

CodeDescription
200Presigned URL generated successfully
204File uploaded successfully
403Upload failed (expired policy)

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

txn_id
string
required

Session ID for file upload

Example:

"txn_301"

action
enum<string>
default:ekascribe-v2

Upload action type

Available options:
ekascribe-v2
Example:

"ekascribe-v2"

Response

200
application/json

Presigned URL generated successfully

The response is of type object.