---
updatedAt: 2025-06-02T20:45:53.000Z
agentTools:
  projectIndex: https://docs.aerocrs.com/v4.0/llms.txt
---

# makePayment

This method will allow you to pay a booking using a valid credit card number and details.

## Usage

You should use it when you wan to pay a booking with the end-customer / agency credit card and when you do not have any deposit on your account.

## Response

The method will response with a confirmation / rejection reason, you should ticketBooking once done with this method.

> 📘 Important
>
> Not all of AeroCRS hosted airlines support this feature.

> ❗️ Critical
>
> Calling the makePayment with a valid post, will charge the total summary of the booking on the system, there is no option to select the charge amount.

## Request parameters

<Table align={["left","left","left"]}>
  <thead>
    <tr>
      <th>
        Parameter
      </th>

      <th>
        Type
      </th>

      <th>
        Description
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        bookingid
      </td>

      <td>
        Number\*
      </td>

      <td>
        The bookingid you got from createBooking
      </td>
    </tr>

    <tr>
      <td>
        creditcardpayer
      </td>

      <td>
        String\*
      </td>

      <td>
        The credit card holder name and last name
      </td>
    </tr>

    <tr>
      <td>
        creditcardnumber
      </td>

      <td>
        Number\*
      </td>

      <td>
        The credit card number
      </td>
    </tr>

    <tr>
      <td>
        creditcardexpiry
      </td>

      <td>
        Number\*
      </td>

      <td>
        The credit card expiry in 4 digits MMYY
      </td>
    </tr>

    <tr>
      <td>
        creditcardcvv
      </td>

      <td>
        Number
      </td>

      <td>
        The credit card CVV
      </td>
    </tr>

    <tr>
      <td>
        currency
      </td>

      <td>
        String (Optional)
      </td>

      <td>
        Currency ISO format (Example - USD)
      </td>
    </tr>

    <tr>
      <td>
        transaction3ds
      </td>

      <td>
        Boolean
      </td>

      <td>
        true/false - 3DS transaction
      </td>
    </tr>

    <tr>
      <td>
        params3ds
      </td>

      <td>
        Object
      </td>

      <td>
        Contain the 3DS parameters
      </td>
    </tr>

    <tr>
      <td>
        eci
      </td>

      <td>
        String
      </td>

      <td>
        ECI - From 3DS Authentication
      </td>
    </tr>

    <tr>
      <td>
        xid
      </td>

      <td>
        String
      </td>

      <td>
        XID - From 3DS Authentication
      </td>
    </tr>

    <tr>
      <td>
        cavv
      </td>

      <td>
        String
      </td>

      <td>
        CAVV - From 3DS Authentication
      </td>
    </tr>

    <tr>
      <td>
        enrolled
      </td>

      <td>
        String
      </td>

      <td>
        Enrolled
      </td>
    </tr>

    <tr>
      <td>
        status\_3d
      </td>

      <td>
        String
      </td>

      <td>
        Status 3D
      </td>
    </tr>

    <tr>
      <td>
        version\_3d
      </td>

      <td>
        String
      </td>

      <td>
        Version 3D
      </td>
    </tr>

    <tr>
      <td>
        ismobilepayment
      </td>

      <td>
        Boolean
      </td>

      <td>
        true / false
      </td>
    </tr>

    <tr>
      <td>
        mobileaction
      </td>

      <td>
        String
      </td>

      <td>
        Mobile action options/charge
      </td>
    </tr>

    <tr>
      <td>
        mobile
      </td>

      <td>
        Object
      </td>

      <td>
        Contain the mobile parameters
      </td>
    </tr>

    <tr>
      <td>
        mobiletype
      </td>

      <td>
        String
      </td>

      <td>
        MNO - Mobile Network Operator
      </td>
    </tr>

    <tr>
      <td>
        mobilecountry
      </td>

      <td>
        String
      </td>

      <td>
        The country name of MNO
      </td>
    </tr>

    <tr>
      <td>
        phonenumber
      </td>

      <td>
        String
      </td>

      <td>
        The phone number of the customer
      </td>
    </tr>
  </tbody>
</Table>

> ❗️ \* Mandatory parameters

> 🚧 Testing
>
> For testing use this credit card number: 5326445577889977\
> You can only test "northair" test company

> 🚧 3DS Integration
>
> Please not that before using 3DS integration, contact AeroCRS support to verify which airlines supported.

## Mobile payments (AeroCRS Network)

Contact AeroCRS to provide payment notification URL for your integration in advance.\
[Mobile money payment notification](https://docs.aerocrs.com/v4.0/reference/mobile-money-payment-notification)

## Response

The method will response with a confirmation / rejection reason, you should ticketBooking once done with this method.

<Table align={["left","left","left"]}>
  <thead>
    <tr>
      <th>
        Parameter
      </th>

      <th>
        Type
      </th>

      <th>
        Description
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        bookingid
      </td>

      <td>
        Number
      </td>

      <td>
        The booking ID
      </td>
    </tr>

    <tr>
      <td>
        paymentstatus
      </td>

      <td>
        String
      </td>

      <td>
        The response:

        OK - Confirmed

        PN - Pending

        XX - Rejected
      </td>
    </tr>

    <tr>
      <td>
        paymentstatusexplanation
      </td>

      <td>
        String
      </td>

      <td>
        Free text of explanation
      </td>
    </tr>

    <tr>
      <td>
        paymentoptions
      </td>

      <td>
        Element
      </td>

      <td>
        Include the MNO details
      </td>
    </tr>

    <tr>
      <td>
        mobiletype
      </td>

      <td>
        String
      </td>

      <td>
        MNO - Mobile Network Operator
      </td>
    </tr>

    <tr>
      <td>
        mobilecountry
      </td>

      <td>
        String
      </td>

      <td>
        The country name of MNO
      </td>
    </tr>

    <tr>
      <td>
        instructions
      </td>

      <td>
        String
      </td>

      <td>
        Payment instructions
      </td>
    </tr>
  </tbody>
</Table>

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "aerocrs-payments",
    "version": "4.0"
  },
  "servers": [
    {
      "url": "https://secure.aerocrs.com/v4"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "in": "header",
        "name": "auth_id"
      },
      "sec1": {
        "type": "apiKey",
        "in": "header",
        "name": "auth_password"
      }
    }
  },
  "security": [
    {
      "sec0": [],
      "sec1": []
    }
  ],
  "paths": {
    "/makePayment": {
      "post": {
        "summary": "makePayment",
        "description": "This method will allow you to pay a booking using a valid credit card number and details.",
        "operationId": "makepayment",
        "parameters": [
          {
            "name": "auth_id",
            "in": "header",
            "description": "ID provided to you by AeroCRS",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "auth_password",
            "in": "header",
            "description": "Password provided to you by AeroCRS",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "RAW_BODY"
                ],
                "properties": {
                  "RAW_BODY": {
                    "type": "string",
                    "description": "The method accepts the XML / JSON input as POST, response format will be according to the sent format. You can try JSON, put the post in the following input and click \"Try It\"",
                    "format": "json"
                  }
                }
              },
              "examples": {
                "Request Example": {
                  "value": {
                    "aerocrs": {
                      "parms": {
                        "bookingid": 34148599,
                        "creditcardpayer": "test test",
                        "creditcardnumber": "5436886269848367",
                        "creditcardexpiry": "0220",
                        "creditcardcvv": "303"
                      }
                    }
                  }
                },
                "JSON - 3DS transaction": {
                  "value": {
                    "aerocrs": {
                      "parms": {
                        "bookingid": 34877322,
                        "creditcardpayer": "test test",
                        "creditcardnumber": "5436886269848367",
                        "creditcardexpiry": "0220",
                        "creditcardcvv": "303",
                        "transaction3ds": true,
                        "params3ds": {
                          "eci": "02",
                          "xid": "a209ca5d-dc23-494a-b043-c33fa906a018",
                          "cavv": "MTIzNDU2Nzg5MDA5ODc2NTQzMjE=",
                          "enrolled": "C",
                          "status_3d": "Y",
                          "version_3d": "2.1.0"
                        }
                      }
                    }
                  }
                },
                "JSON - Mobile payment options": {
                  "value": {
                    "aerocrs": {
                      "parms": {
                        "bookingid": 34877329,
                        "ismobilepayment": true,
                        "mobileaction": "options"
                      }
                    }
                  }
                },
                "JSON - Mobile payment instructions": {
                  "value": {
                    "aerocrs": {
                      "parms": {
                        "bookingid": 34877329,
                        "ismobilepayment": true,
                        "mobileaction": "charge",
                        "mobile": {
                          "mobiletype": "mpesa",
                          "mobilecountry": "Kenya",
                          "phonenumber": "012345678"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "JSON": {
                    "value": "{\n    \"aerocrs\": {\n      \t\"success\": true,\n        \"bookingid\": 34148599,\n        \"paymentstatus\": \"OK\",\n        \"paymentstatusexplanation\": \"Payment received\"\n    }\n}"
                  },
                  "JSON - Mobile payment options": {
                    "value": "{\n\t\"aerocrs\": {\n\t\t\"success\": true,\n\t\t\"bookingid\": 34877329,\n\t\t\"paymentstatus\": \"PN\",\n\t\t\"paymentstatusexplanation\": \"Mobile payment options\",\n\t\t\"paymentoptions\": [{\n\t\t\t\t\"mobiletype\": \"SafaricomSTKv2\",\n\t\t\t\t\"mobilecountry\": \"Kenya\"\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"mobiletype\": \"TIGOdebitMandate\",\n\t\t\t\t\"mobilecountry\": \"Tanzania\"\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"mobiletype\": \"MTNmobilemoney\",\n\t\t\t\t\"mobilecountry\": \"Uganda\"\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"mobiletype\": \"mpesa\",\n\t\t\t\t\"mobilecountry\": \"Kenya\"\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"mobiletype\": \"MTN\",\n\t\t\t\t\"mobilecountry\": \"Rwanda\"\n\t\t\t}\n\t\t]\n\t}\n}"
                  },
                  "JSON - Mobile payment instructions": {
                    "value": "{\n\t\"aerocrs\": {\n\t\t\"success\": true,\n\t\t\"bookingid\": 34877329,\n\t\t\"paymentstatus\": \"PN\",\n\t\t\"paymentstatusexplanation\": \"Mobile payment instructions\",\n\t\t\"instructions\": \"Dear Customer, <br> Shortly you will receive an M-PESA prompt on your phone requesting you to enter your M-PESA PIN to complete your payment. Please ensure your phone is on and unlocked to enable you to complete the process. Thank you. <br> <br> You can also pay using Lipa na MPESA by using the following instructions: <br> 1.Go to the M-PESA menu <br> 2. Select Lipa na M-PESA <br> 3. Select the Paybill option <br> 4. Enter business number 927633 <br> 5. Enter your account number 2257FB0D1 <br> 6. Enter the amount 1 <br> 7. Enter PIN and press OK to send <br> 8. You will receive a confirmation SMS with your payment reference number.\"\n\t}\n}"
                  }
                },
                "schema": {
                  "oneOf": [
                    {
                      "title": "JSON",
                      "type": "object",
                      "properties": {
                        "aerocrs": {
                          "type": "object",
                          "properties": {
                            "success": {
                              "type": "boolean",
                              "example": true,
                              "default": true
                            },
                            "bookingid": {
                              "type": "integer",
                              "example": 34148599,
                              "default": 0
                            },
                            "paymentstatus": {
                              "type": "string",
                              "example": "OK"
                            },
                            "paymentstatusexplanation": {
                              "type": "string",
                              "example": "Payment received"
                            }
                          }
                        }
                      }
                    },
                    {
                      "title": "JSON - Mobile payment options",
                      "type": "object",
                      "properties": {
                        "aerocrs": {
                          "type": "object",
                          "properties": {
                            "success": {
                              "type": "boolean",
                              "example": true,
                              "default": true
                            },
                            "bookingid": {
                              "type": "integer",
                              "example": 34877329,
                              "default": 0
                            },
                            "paymentstatus": {
                              "type": "string",
                              "example": "PN"
                            },
                            "paymentstatusexplanation": {
                              "type": "string",
                              "example": "Mobile payment options"
                            },
                            "paymentoptions": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "mobiletype": {
                                    "type": "string",
                                    "example": "SafaricomSTKv2"
                                  },
                                  "mobilecountry": {
                                    "type": "string",
                                    "example": "Kenya"
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    },
                    {
                      "title": "JSON - Mobile payment instructions",
                      "type": "object",
                      "properties": {
                        "aerocrs": {
                          "type": "object",
                          "properties": {
                            "success": {
                              "type": "boolean",
                              "example": true,
                              "default": true
                            },
                            "bookingid": {
                              "type": "integer",
                              "example": 34877329,
                              "default": 0
                            },
                            "paymentstatus": {
                              "type": "string",
                              "example": "PN"
                            },
                            "paymentstatusexplanation": {
                              "type": "string",
                              "example": "Mobile payment instructions"
                            },
                            "instructions": {
                              "type": "string",
                              "example": "Dear Customer, <br> Shortly you will receive an M-PESA prompt on your phone requesting you to enter your M-PESA PIN to complete your payment. Please ensure your phone is on and unlocked to enable you to complete the process. Thank you. <br> <br> You can also pay using Lipa na MPESA by using the following instructions: <br> 1.Go to the M-PESA menu <br> 2. Select Lipa na M-PESA <br> 3. Select the Paybill option <br> 4. Enter business number 927633 <br> 5. Enter your account number 2257FB0D1 <br> 6. Enter the amount 1 <br> 7. Enter PIN and press OK to send <br> 8. You will receive a confirmation SMS with your payment reference number."
                            }
                          }
                        }
                      }
                    }
                  ]
                }
              }
            }
          }
        },
        "deprecated": false,
        "security": []
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": false,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```