# Cardholder Document Upload

### POST Cardholder Document Upload

POST /api/mastercard/holderPhotoUpload.html

Document upload status: 1 - Upload successful, 2 - Upload failed

> Request Body

```
```

```json
{
  "holderId": "1234567890",
  "photoData": "https://pic.rmb.bdstatic.com/bjh/down/55ae8d25de40edd2eef89fb7f64ed644.png",
  "photoType": "3",
  "randomStr": "abcdef12345ssss67890ssss"
}
```

#### Request Parameters

| Name      | Type    | Required | Base64 Encoding | Field Name    | Description                                                                               |
| --------- | ------- | -------- | --------------- | ------------- | ----------------------------------------------------------------------------------------- |
| holderId  | string  | true     | none            | Cardholder ID | The ID of the cardholder                                                                  |
| photoType | integer | true     | none            | Type          | 1 - ID card front, 2 - ID card back, 3 - Passport, 5 - Proof of address, 8 - Facial photo |
| photoData | string  | true     | Y               | Photo Data    | Photo data (base64-encoded string, maximum 1MB)                                           |
| randomStr | string  | true     | none            | Randomstr     | A random string of 32 characters                                                          |

> Example Response
>
> 200 Response

```
```

```json
{
  "errMsg": "string",
  "uploadStatus": 0
}
```

#### Response Fields

| Name         | Type    | Required | Constraints | Description                              |
| ------------ | ------- | -------- | ----------- | ---------------------------------------- |
| errMsg       | string  | true     | none        | Status description                       |
| uploadStatus | integer | true     | none        | 1 - Upload successful, 2 - Upload failed |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://prepaidify.gitbook.io/docs/physical-card/api-integration/cardholder-document-upload.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
