Collection/Purchase
Step 1 - Initiate
This API method is utilized to trigger a collection/purchase request, resulting in a JSON response being returned to you.
Headers
Name
Type
Description
{
"client": {
"email": "[email protected]",
"phone": "256751123456"
},
"purchase": {
"currency": "UGX",
"products": [
{
"name": "Example One",
"price": "500"
}
]
},
"reference": "Your unique transaction reference",
"skip_capture": false,
"brand_id": "{{BrandId}}",
"payment_method_whitelist": ["airtel", "mtnmomo"],
}{
"id": "5322be8e-af12-4afd-be2c-2a4bdd77c273",
"due": 1669137983,
"type": "purchase",
"client": {
"cc": [],
"bcc": [],
"city": "",
"email": "[email protected]",
"phone": "256700123123",
"state": "",
"country": "",
"zip_code": "",
"bank_code": "",
"full_name": "",
"brand_name": "",
"legal_name": "",
"tax_number": "",
"client_type": null,
"bank_account": "",
"personal_code": "",
"shipping_city": "",
"shipping_state": "",
"street_address": "",
"delivery_methods": [
{
"method": "email",
"options": {}
},
{
"method": "text_message",
"options": {
"custom_message": ""
}
}
],
"shipping_country": "",
"shipping_zip_code": "",
"registration_number": "",
"shipping_street_address": ""
},
"issued": "2022-11-22",
"status": "created",
"is_test": false,
"payment": null,
"product": "purchases",
"user_id": null,
"brand_id": "edd6c020-eac6-4b4e-9716-47928f3401de",
"order_id": null,
"platform": "api",
"purchase": {
"debt": 0,
"notes": "",
"total": 500,
"currency": "UGX",
"language": "en",
"products": [
{
"name": "PAYTOTA",
"price": 500,
"category": "",
"discount": 0,
"quantity": "1.0000",
"tax_percent": "0.00"
}
],
"timezone": "UTC",
"due_strict": false,
"email_message": "",
"total_override": null,
"shipping_options": [],
"subtotal_override": null,
"total_tax_override": null,
"payment_method_details": {},
"request_client_details": [],
"total_discount_override": null
},
"client_id": null,
"reference": "",
"viewed_on": null,
"company_id": "706d0675-b131-468c-940d-bc0ea3599e7f",
"created_on": 1669134383,
"event_type": "purchase.created",
"updated_on": 1669134383,
"invoice_url": null,
"checkout_url": "https://payments.paytota.com/p/5322be8e-af12-4afd-be2c-2a4bdd77c273/",
"send_receipt": false,
"skip_capture": false,
"creator_agent": "",
"issuer_details": {
"website": "https://paytota.com",
"brand_name": "PAYTOTA",
"legal_city": "Kamplaa",
"legal_name": "PAYTOTA",
"tax_number": "",
"bank_accounts": [
{
"bank_code": "EQBLUGKAXXX",
"bank_account": "1036201557307"
}
],
"legal_country": "UG",
"legal_zip_code": "23235",
"registration_number": "80020002500244",
"legal_street_address": "Venture Labs, Plot 23 Binayomba Road, Bugolobi"
},
"marked_as_paid": false,
"status_history": [
{
"status": "created",
"timestamp": 1669134383
}
],
"cancel_redirect": "",
"created_from_ip": "102.218.37.140",
"direct_post_url": null,
"force_recurring": false,
"recurring_token": null,
"failure_redirect": "",
"success_callback": "",
"success_redirect": "",
"transaction_data": {
"flow": "payform",
"extra": {},
"country": "",
"attempts": [],
"payment_method": ""
},
"refundable_amount": 0,
"is_recurring_token": false,
"billing_template_id": null,
"currency_conversion": null,
"reference_generated": "PT119",
"refund_availability": "none",
"payment_method_whitelist": null
}Step 2 - Execute
You have two methods to execute the transaction
Using the transaction ID received in Step 1, this method is then queried by sending a form-data request to initiate a PIN prompt on the subscriber handset.
Headers
Name
Type
Description
Request Body
Name
Type
Description
Check Collection/Purchase Status
This method is used to query the collections/purchases transaction status using the transaction ID. Please note that this API also requires authorization using the Secret Key.
Headers
Name
Type
Description
Last updated