card
, account
, phone
, qr
NGN
or USD
client
above does not exist in request.account
or client
true
or false
, defaults to false.{"status": "success","message": "Invoice created successfully.","data": {"id": 1,"company_id": "1","client_id": "1","reference_code": "j9CbiTN0oJe4vWhglyS2","payment_id": null,"fee_bearer": "client","mail_status": "unsent","status": "0","due_date": "1483056000","created_at": "2016-12-21 18:46:30","updated_at": "2016-12-21 18:46:30","deleted_at": null,"client": {"id": 1"company_id": 1,"name": "Albert Specialist Hospital","first_name": "Albert","last_name": "Jane","email": "jane@alberthospital.com","phone": "+2348012345678","website": "http://www.alberthospital.com","address": "Wase II","type": "Customer","settlement_bank": "","account_name": "","account_number": "","status": "1","created_at": "2016-12-21 17:19:10","updated_at": "2016-12-21 17:19:10","deleted_at": null},"items": [{"id": "1","company_id": "1","client_id": "1","name": "Website Design","description": "5 Pages Website plus 1 Year Web Hosting","quantity": "1","unit_cost": "50000.00","status": "0","due_date": "1483056000","created_at": "2016-12-21 17:19:10","updated_at": "2016-12-21 17:19:10","deleted_at": null}]}}
Parameters | Description |
company_name | String Client's company or full name |
first_name required | String Client's first name |
last_name required | String Client's last name |
email required | String Client's email address |
email_cc | String Comma separated emails to copy for invoices and payment receipts |
phone required | String Client's phone number |
address | String Client's address |
Parameter | Description |
item required | String Item's name |
description required | String Item's description |
unit_cost required | String Item's unit cost |
quantity required | String Item's quantity |
Heads up!
Please contact Payant Support for you to start tokenizing cards and accepting recurring payments.
Heads up!
Only one of client
or client_id
is required per invoice. The client
parameter will allow you to add a new customer while invoicing on the fly in case you don't have a client_id
. Client will not be added if already exist.
curl https://api.payant.ng/invoices \-H "Content-Type: application/json" \-H "Authorization: Bearer SECRET_KEY" \-d '{ "client": {"first_name": "Albert","last_name": "Jane","email": "jane@alberthospital.com","phone": "+2348012345678"},"due_date": "12/30/2016","fee_bearer": "client","items": ["item": "Website Design","description": "5 Pages Website plus 1 Year Web Hosting","unit_cost": "50000.00","quantity": "1"]}' \-X POST
{"status": "success","message": "Invoice created successfully.","data": {"id": 1,"company_id": "1","client_id": "1","reference_code": "j9CbiTN0oJe4vWhglyS2","payment_id": null,"fee_bearer": "client","mail_status": "unsent","status": "0","due_date": "1483056000","created_at": "2016-12-21 18:46:30","updated_at": "2016-12-21 18:46:30","deleted_at": null,"client": {"id": 1"company_id": 1,"name": "Albert Specialist Hospital","first_name": "Albert","last_name": "Jane","email": "jane@alberthospital.com","phone": "+2348012345678","website": "http://www.alberthospital.com","address": "Wase II","type": "Customer","settlement_bank": "","account_name": "","account_number": "","status": "1","created_at": "2016-12-21 17:19:10","updated_at": "2016-12-21 17:19:10","deleted_at": null},"items": [{"id": "1","company_id": "1","client_id": "1","name": "Website Design","description": "5 Pages Website plus 1 Year Web Hosting","quantity": "1","unit_cost": "50000.00","status": "0","due_date": "1483056000","created_at": "2016-12-21 17:19:10","updated_at": "2016-12-21 17:19:10","deleted_at": null}]}}