Create a payment intent

Create a payment intent

Recipes
Direct API + Payment flows
Open Recipe
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
string
required

The amount to charge. The field must have no more than 14 total digits and no more than 2 decimal places.

string
required

The currency of the amount represented by a string of alphabetic code from ISO 4217 Currency codes

string
enum

The type of the current intent which can be one of 'purchase', 'authorize' or 'capture'. Note that operation is required if flow_id is not provided.

  • purchase - purchase
  • authorize - authorize
  • PURCHASE - PURCHASE
  • AUTHORIZE - AUTHORIZE
Allowed:
uri
required
length ≤ 2000

A URL that the Moneyhash server will send a POST request to with payment data after payment.

billing_data
object

Customer billing data to pass them to the payment provider automatically to save the user time

shipping_data
object

Customer shipping data

fees
array of objects

An array of fee objects. Each object contains a multilingual title and a numeric value. The sum of all fee values must equal the total amount. Fee value can't be negative

fees
statement_descriptor
object

More info about your business so banks can help their customers to understand the transaction

string
string

MoneyHash flow ID to be used during payment. If provided, operation shouldn't be provided.

string | null

The ID of a specific payment provider method you want to directly return for the user. If not provided, the user will be presented with a list of payment providers to choose from.

product_items
array of objects
product_items
fraud_data
object

The data will be used to communicate with the fraud detection service

string

Key value pairs of any additional information you want to save with the payment.

custom_form_definition
object

A json object containing custom form object to be displayed to the user during payment

string

The ID of a card token you wish to process this payment with

card_token_data
object
string
boolean
string

The ID of a specific customer you wish to associate this payment with.

boolean

If set to true, the payment amount overview side panel will be hidden from the embed

boolean
boolean
boolean

if set to True, hides MoneyHash branding header from the returned embed

boolean

Only show the payment form to the user without other payment choices.

uri
length ≤ 2000

A URL that allows your customers to go back to your website at anytime during the payment.

boolean
Defaults to false

If you want to top up a customer wallet using a payment, set this to true. If set to true, customer is required to create payment intent.

boolean
Defaults to false

Use customer wallet to process the payment. If set to True, customer is required.

string
enum
  • incremental - incremental
  • final - final
  • INCREMENTAL - INCREMENTAL
  • FINAL - FINAL
Allowed:
threeds
object
boolean
Defaults to false

Will show a save card checkbox if it's applicable and the user can proceed without ticking the box

boolean
Defaults to false

Allowing non-embedded experience to control whether to save the card for future use

boolean
Defaults to false

Will show a save card checkbox if it's applicable and the user can NOT proceed without ticking the box

integer

The number of seconds after which the intent will expire

boolean
Defaults to false

Shows a countdown timer till intent expires, only valid in combination with expires_after_seconds

hidden_methods
array of strings

A list of payment methods to hide from the user

hidden_methods
boolean
Defaults to false

Use details in customer_details to create a new customer

string

Customer details to be used to create a new customer, required if create_customer is true

boolean
Defaults to false
boolean
Defaults to false
boolean
Defaults to false
uri
length ≤ 2000

A URL to redirect to after a successful payment transaction

uri
length ≤ 2000

A URL to redirect to after a payment transaction pending external action

uri
length ≤ 2000

A URL to redirect to after a failed payment transaction

uri
length ≤ 2000

A URL to redirect to after a payment intent is processed

uri
length ≤ 2000

A URL to redirect to after a payment intent is closed

uri
length ≤ 2000

A URL to redirect to after a payment intent is expired

boolean
Defaults to false

To use intent without any hosted pages. Note that your business has to be PCI compliant

string

User's IP address to be used inside Flows and Risk rules, used only when use_direct_api is true

string
enum

This must be specified for card payments where the cardholder is not present (i.e., recurring or mail order / telephone order)

  • regular - regular
  • recurring - recurring
  • moto - moto
  • installment - installment
  • unscheduled - unscheduled
  • REGULAR - REGULAR
  • RECURRING - RECURRING
  • MOTO - MOTO
  • INSTALLMENT - INSTALLMENT
  • UNSCHEDULED - UNSCHEDULED
string

MoneyHash transaction Id as UUID. Used to link the transaction to an existing series of transactions.

recurring_data
object
prev_cit_payload
object
string

Custom headers to be sent in the webhooks.

boolean
Defaults to false

If set to true, the payment is being made with a network token

boolean
Defaults to false

Flags the payment as a merchant-initiated transaction (MIT). It must be set to true for all MITs.

discount
object | null
boolean
Defaults to false
redirect_branding_data
object
boolean
Defaults to false
aft_data
object
string
enum
Defaults to default
  • sa - sa
  • default - default
Allowed:
device_info
object

Device information including user agent and optional additional details

date-time | null
date-time | null
string | null
string | null
enum
  • redirect_inside_embed - redirect_inside_embed
  • redirect_entire_window - redirect_entire_window
  • redirect_to_new_tab - redirect_to_new_tab
Allowed:
string | null
string
string | null
string
string | null
string | null
string | null
enum
  • NOT_SENT - NOT_SENT
  • SENDING - SENDING
  • SENT - SENT
Allowed:
string | null
boolean
boolean
boolean | null
boolean | null
boolean | null
string
string | null
enum
  • CASH_OUTLET - CASH_OUTLET
  • MOBILE_WALLET - MOBILE_WALLET
  • CARD - CARD
  • USSD - USSD
  • KNET - KNET
  • CASH_COLLECTION - CASH_COLLECTION
  • AMAN_MASARY - AMAN_MASARY
  • PAYPAL - PAYPAL
  • PAY_AT_FAWRY - PAY_AT_FAWRY
  • VALU - VALU
  • SHAHRY - SHAHRY
  • CASH_ON_DELIVERY - CASH_ON_DELIVERY
  • BANK_INSTALLMENTS - BANK_INSTALLMENTS
  • BANK_TRANSFERS - BANK_TRANSFERS
  • REFERENCE_NUMBER - REFERENCE_NUMBER
  • SELFSERVE_WALLET - SELFSERVE_WALLET
  • APPLE_PAY - APPLE_PAY
  • CLICK2PAY - CLICK2PAY
  • GOOGLE_PAY - GOOGLE_PAY
  • CAREEM_PAY - CAREEM_PAY
  • PAY_FLEX - PAY_FLEX
  • M_PESA - M_PESA
  • MOBILE_MONEY - MOBILE_MONEY
  • CRYPTO_WALLET - CRYPTO_WALLET
  • NAPS - NAPS
  • FORSA - FORSA
  • SYMPL - SYMPL
  • TABBY - TABBY
  • SOUHOOLA - SOUHOOLA
  • GETGO - GETGO
  • SAMSUNG_PAY - SAMSUNG_PAY
  • QPAY - QPAY
  • TAMARA - TAMARA
  • BENEFIT - BENEFIT
  • RAZER - RAZER
  • ININAL - ININAL
  • STC - STC
  • MOKAFAA - MOKAFAA
  • SADAD - SADAD
  • EFAWATEERCOM - EFAWATEERCOM
  • OMANNET - OMANNET
  • MADA - MADA
  • TAPTOPAY - TAPTOPAY
  • GRABPAY - GRABPAY
  • GRABPAYPAYLATER - GRABPAYPAYLATER
  • SHOPEEPAY - SHOPEEPAY
  • SHOPEEPAYPAYLATER - SHOPEEPAYPAYLATER
  • ATOME - ATOME
  • TOUCHNGO - TOUCHNGO
  • BOOST - BOOST
  • PAYNOW - PAYNOW
  • UPI - UPI
  • ZAINCASH - ZAINCASH
  • WALAONE - WALAONE
string
string
string
boolean | null
string | null
boolean | null
boolean | null
string | null
boolean | null
string
boolean | null
string
string
string
boolean | null
uri | null
string | null
Responses

Language
Credentials
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json