---
title: Upload
description: Upload a merchant logo for the merchant's assigned payment domain.
---

This API will update merchant's logo in merchant's assigned domain. We must pass image, airpay merchant id, secret key and image type in request. If the request has valid details, we will get a success response.

#### POST

```
https://kraken.airpay.co.in/airpay/ms/singlepager/api/upload
```

## Request Body

| Parameter | Type Value | Description | Value Like |
| --- | --- | --- | --- |
| image  required | File | File Input (length 2MB) | `image.png` |
| checksum  required | Alphanumeric  <br>(1-100) | Checksum | `91f5evhk72f56432ec8233b7r37562g2hps` |
| airpay_merchant_id  required | Numeric  <br>(1-11) | airpay Merchant Id | `1088` |
| airpay_secret_key  required | Alphanumeric  <br>(1-100) | airpay Secret Key | `91f5evhk72f56912508233b7r37562g2hps` |
| image_type  required | Alphanumeric  <br>(1-20) | Type of the image in png/jpeg/jpg format | `png` |

## Success 200

| Parameter | Type Value | Description | Value Like |
| --- | --- | --- | --- |
| Result  required | Text | Message<br>Success - 200 (The transaction is success)<br>Transaction in Process - 211 (The transaction is processing)<br>Failed - 400 (The transaction is failed)<br>Dropped - 401 (The transaction will not register properly)<br>Cancel - 402 (payment that has not yet been processed)<br>Incomplete - 403 (Not recieved any call back from bank)<br>Bounced - 405 (The transaction has bounced)<br>No Records - 503 (There are no records found) | `Success` |

## Request Example

```
curl --location --request POST 'https://kraken.airpay.co.in/airpay/ms/singlepager/api/upload' \
--header 'content-type: application/json' \
--header 'processor-key: 91f5evhk72f56432ec678sdfes685h42sd2t21k430912508233b7r37562g2hps' \
--form 'image=image.png' \
--form 'checksum=91f5evhk72f56432ec8233b7r37562g2hps' \
--form 'airpay_merchant_id=1088' \
--form 'airpay_secret_key=91f5evhk72f56912508233b7r37562g2hps' \
--form 'image_type=1-label'
```

```json
{
   array(1) {
               ["image"]=>
                            array(5) {
                                        ["name"]=> string(32) "Policy Renewal Screen Shot 1.png"
                                        ["type"]=> string(9) "image/png"
                                        ["tmp_name"]=> string(14) "/tmp/phpKtSD6g"
                                        ["error"]=> int(0)
                                        ["size"]=> int(123047)
                                     }
           }
}
```

### Success Response

```json
HTTP/1.1 200 OK
{
   "Result": "Success"
}
```

### Error Response

```json
{
    "SinglePager": {
        "Errors": {
            "11": "Checksum Can Not Be Empty",
            "12": "Wrong Checksum",
            "16": "A PHP extension stopped the file upload. PHP does not provide a way to ascertain which extension caused the file upload to stop; examining the list of loaded extensions with phpinfo() may help. Introduced in PHP 5.2.0.",
            "17": "No File Uploaded",
            "18": "The uploaded file exceeds the upload_max_filesize directive in php.ini.",
            "19": "The uploaded file exceeds the MAX_FILE_SIZE directive that was specified in the HTML form.",
            "20": "The uploaded file was only partially uploaded.",
            "21": "No file was uploaded.",
            "22": "Missing a temporary folder. Introduced in PHP 5.0.3.",
            "23": "Failed to write file to disk. Introduced in PHP 5.1.0.",
            "24": "A PHP extension stopped the file upload. PHP does not provide a way to ascertain which extension caused the file upload to stop; examining the list of loaded extensions with phpinfo() may help. Introduced in PHP 5.2.0.",
            "32": "File is not an image.",
            "34": "Invalid File Format.",
            "37": "There was an error uploading your file.",
            "40": "Image Type Can Not Be Empty",
            "41": "Invalid Image Type",
            "42": "Invalid Data Supplied",
            "00": "Header Aunthentication Failed, Invalid Content-Type",
            "01": "Header Aunthentication Failed, airpay-Key Can Not Be Empty",
            "02": "Header Aunthentication Failed, Invalid airpay-Key",
            "05": "airpay Merchant Id Can Not Be Empty",
            "08": "airpay Secret Key Can Not Be Empty",
            "04": "Subdomain Can Not Be Empty"
        }
    },
    "Result": "Fail"
}
```