---
agentTools:
  projectIndex: https://chimoney.readme.io/llms.txt
---

# Redeem airtime.

Redeems a Chimoney transaction as airtime by specifying the reference code `chiRef`, recipient's phone number, and the destination country.

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Chimoney API Docs",
    "version": "0.2.4",
    "description": "This is the latest version of the Chimoney API. For deprecated version routes, please refer to /v0.2/api-docs."
  },
  "security": [
    {
      "apiKeyAuth": []
    }
  ],
  "servers": [
    {
      "url": "https://api.chimoney.io/",
      "description": "Prod Server"
    },
    {
      "url": "https://api-v2-sandbox.chimoney.io",
      "description": "Sandbox API v2 (v0.2.4)"
    }
  ],
  "paths": {
    "/v0.2.4/redeem/airtime": {
      "post": {
        "summary": "Redeem airtime.",
        "tags": [
          "Redeem"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "subAccount": {
                    "type": "string",
                    "description": "Subaccount if any.",
                    "example": "1234567"
                  },
                  "chiRef": {
                    "type": "string",
                    "description": "Chi reference.",
                    "example": "1234567"
                  },
                  "phoneNumber": {
                    "type": "string",
                    "description": "Phone number.",
                    "example": "+2341234567"
                  },
                  "countryToSend": {
                    "type": "string",
                    "description": "Country to send to.",
                    "example": "Nigeria"
                  },
                  "meta": {
                    "type": "object",
                    "description": "Any data to be sent along with request.",
                    "properties": {
                      "test": {
                        "type": "boolean",
                        "example": true
                      }
                    }
                  }
                },
                "required": [
                  "chiRef",
                  "phoneNumber",
                  "countryToSend"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "example": "success"
                    },
                    "message": {
                      "type": "string",
                      "example": "Airtime redeemed successfully"
                    },
                    "data": {
                      "type": "object",
                      "properties": {
                        "payoutLink": {
                          "type": "string",
                          "example": "http://localhost:4000/pay/?issueID=eaabe2eb-e774-4f81-8ba9-ede2ea2d0058_10_1726494779981"
                        },
                        "data": {
                          "type": "object",
                          "properties": {
                            "id": {
                              "type": "string",
                              "example": "KGiwpulQZHnanhNnCEak"
                            },
                            "valueInUSD": {
                              "type": "number",
                              "example": 10
                            },
                            "chimoney": {
                              "type": "number",
                              "example": 10000
                            },
                            "issueID": {
                              "type": "string",
                              "example": "eaabe2eb-e774-4f81-8ba9-ede2ea2d0058_10_1726494779981"
                            },
                            "fee": {
                              "type": "number",
                              "example": 0
                            },
                            "type": {
                              "type": "string",
                              "example": "api-payment"
                            },
                            "subAccount": {
                              "type": "string",
                              "example": "eaabe2eb-e774-4f81-8ba9-ede2ea2d0058"
                            },
                            "issuer": {
                              "type": "string",
                              "example": "eaabe2eb-e774-4f81-8ba9-ede2ea2d0058"
                            },
                            "t_id": {
                              "type": "number",
                              "example": 89448
                            },
                            "chiRef": {
                              "type": "string",
                              "example": "e8bb27c9-7e6d-4734-b242-36efbd5f8f5c"
                            },
                            "meta": {
                              "type": "object",
                              "example": {}
                            },
                            "integration": {
                              "type": "object",
                              "properties": {
                                "appID": {
                                  "type": "string",
                                  "example": "TyGlLVepVqfOj3635qrC"
                                },
                                "isFromScrim": {
                                  "type": "boolean",
                                  "example": false
                                }
                              }
                            },
                            "turnOffNotification": {
                              "type": "boolean",
                              "example": false
                            },
                            "issueDate": {
                              "type": "string",
                              "example": "2024-09-16T13:53:00.806Z"
                            },
                            "payerEmail": {
                              "type": "string",
                              "example": "favour@chimoney.io"
                            },
                            "redirect_url": {
                              "type": "string",
                              "example": "https://test.com"
                            },
                            "redeemData": {
                              "type": "object",
                              "properties": {
                                "walletID": {
                                  "type": "string",
                                  "example": "6ShqiB470pYLLgFE1Duc"
                                }
                              }
                            },
                            "initiatedBy": {
                              "type": "string",
                              "example": "1d812de4-b5e3-474b-9572-19667eb985f3"
                            },
                            "fundsAvailableDate": {
                              "type": "string",
                              "nullable": true,
                              "example": null
                            },
                            "updatedDate": {
                              "type": "string",
                              "example": "2024-09-16T13:54:52.078Z"
                            },
                            "paymentDate": {
                              "type": "string",
                              "example": "2024-09-16T13:54:52.077Z"
                            },
                            "status": {
                              "type": "string",
                              "example": "paid"
                            }
                          }
                        },
                        "error": {
                          "type": "string",
                          "example": "None"
                        },
                        "payouts": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "amount": {
                                "type": "string",
                                "example": "NGN 15827.6000"
                              },
                              "discount": {
                                "type": "string",
                                "example": "NGN 316.5520"
                              },
                              "errorMessage": {
                                "type": "string",
                                "example": "None"
                              },
                              "phoneNumber": {
                                "type": "string",
                                "example": "+2348056849366"
                              },
                              "requestId": {
                                "type": "string",
                                "example": "ATQid_c6456457b765be56bf8d5a9d6c22a3ac"
                              },
                              "status": {
                                "type": "string",
                                "example": "Sent"
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/ValidationError"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/TransactionNotFoundError"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "apiKeyAuth": {
        "type": "apiKey",
        "in": "header",
        "name": "X-API-KEY"
      }
    },
    "responses": {
      "Forbidden": {
        "description": "Access to this resource is forbidden.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Forbidden"
            }
          }
        }
      },
      "Unauthorized": {
        "description": "Access to this resource is not available for unauthenticated users.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Unauthorized"
            }
          }
        }
      },
      "ServerError": {
        "description": "Indicates an internal server error.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ServerError"
            }
          }
        }
      },
      "ValidationError": {
        "description": "Validation error in the request.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ValidationError"
            }
          }
        }
      },
      "TransactionNotFoundError": {
        "description": "Error indicating that the transaction was not found.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/TransactionNotFoundError"
            }
          }
        }
      }
    },
    "schemas": {
      "Forbidden": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "description": "Status of the response.",
            "example": "error"
          },
          "error": {
            "type": "string",
            "description": "Error message indicating forbidden access.",
            "example": "API Access not enabled for account Test. Email support@chimoney.io"
          }
        }
      },
      "Unauthorized": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "description": "Status of the response.",
            "example": "error"
          },
          "error": {
            "type": "string",
            "description": "Error message indicating unauthorized access.",
            "example": "API key is not defined. Generate a new one from the developer portal."
          }
        }
      },
      "ServerError": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "description": "Status of the error.",
            "example": "error"
          },
          "type": {
            "type": "string",
            "description": "Type of server error.",
            "example": "server error"
          },
          "code": {
            "type": "string",
            "description": "Specific error code for server issues.",
            "example": "INTERNAL_SERVER_ERROR"
          },
          "message": {
            "type": "string",
            "description": "Detailed message explaining the issue.",
            "example": "An internal server error occurred."
          }
        }
      },
      "ValidationError": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "description": "Status of the validation error.",
            "example": "error"
          },
          "type": {
            "type": "string",
            "description": "Type of validation error.",
            "example": "Validation Error"
          },
          "code": {
            "type": "string",
            "description": "Error code indicating validation issue.",
            "example": "INVALID_REQUEST"
          },
          "message": {
            "type": "string",
            "description": "Detailed validation error message.",
            "example": "The request parameters are invalid."
          }
        }
      },
      "TransactionNotFoundError": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "description": "Status of the error.",
            "example": "error"
          },
          "type": {
            "type": "string",
            "description": "Type of error indicating transaction not found.",
            "example": "Resource Not Found"
          },
          "code": {
            "type": "string",
            "description": "Error code for transaction not found.",
            "example": "TRANSACTION_NOT_FOUND"
          },
          "message": {
            "type": "string",
            "description": "Detailed message explaining the transaction not found error.",
            "example": "The transaction with the provided ID could not be found."
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "Redeem",
      "description": "All redeem operations."
    }
  ],
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "_id": {
    "buffer": {
      "0": 102,
      "1": 208,
      "2": 243,
      "3": 240,
      "4": 73,
      "5": 214,
      "6": 34,
      "7": 0,
      "8": 37,
      "9": 190,
      "10": 200,
      "11": 166
    }
  }
}
```