MOBIP

API documentation

Version 2.0, 2022-06

End-points

 /api/2.0/mobip/get_token

 /api/2.0/mobip/send_payment_request

 /api/2.0/mobip/create_one_use_qr

 /api/2.0/mobip/is_valid

 /api/2.0/mobip/cancel_transaction

 /api/2.0/mobip/create_reusable_qr

 /api/2.0/mobip/get_stats

 /api/2.0/mobip/get_account_by_external_id

 /api/2.0/mobip/update_account

 /api/2.0/mobip/get_transaction

 /api/2.0/mobip/get_invoice

 /api/2.0/neosystems/set_mobip_transactions

 /api/2.0/neosystems/get_mobip_transactions

 /api/2.0/mobip/get_account

 /api/2.0/mobip/get_invoice_list

Return to app


Error codes

Error code Description
0 Execution was OK
1 Invalid API Key
2 Invalid connection token
3 Connexion token expired
4 Invalid argument : Input argument does not exist
5 Invalid argument : Wrong type
6 Invalid argument : a requiered argument is missing.
7 IP not in whitelist. Please contact support team
8 Caller's IP does not match token's IP
997 Warning message
998 FATAL_ERROR
999 Default generated method : This method is not implemented yet


All input parameters must be passed as 'multipart/form-data'

GET
/api/2.0/mobip/get_token
 (Public)

Description : Get a connection token to reuse at each call.

Inputs
Attribute Required Description Set a value
api_account_id as string Y API account id
api_secret_key as string Y API secret key of your account
Go to top

Returns

Default return format is : JSON

Attribute Description
access_token as string token id to reuse in each call. This token will be deleted after 1H on inactivity.
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code
return_message as string Only if error, will return a error message to explain return_code

end-point return here after




POST
/api/2.0/mobip/send_payment_request
 (Public)

Description : This call will send a payment request by email or SMS to the customer.

Inputs
Attribute Required Description Set a value
item_amount_in_cents as integer Y Price of your item to sale without taxes in cents of your account's currency.
tax_amount as integer Y Total of taxes to add on item price. In cents of account's currency
redirect_url as string Y URL where MOBIP's server will redirect the user after finishing a transaction. Should be a page on merchant's webiste. The expected url format is : [protocol]://[url] like https://mywebpage.html
call_back_url as string N URL callback who will receive transaction the asynchronous response of the transaction. Ex : https://myserver.com/my_callback.php?resp_code=PROCESSED. resp_code={PROCESSED, CANCELLED, ERROR} , Once processed, you have to use mobip/isvalid to get the status of the transaction who can be PAID, DENIED or CANCELLED
track_id as string N Optional : Your own transaction id or reference for tracking purpose This track_id is send on the callback message when the payment is done.
item_name as string Y Name or description of the product or service you are selling
media as string Y Will send the payment request by the selected Media, SMS our EMAIL values = {SMS,EMAIL}
access_token as string Y Connection token gave by connect/get_token
retry_period as string N number of days before MOBIP resend automatically the payment link. If not set, default value is 0
retry_attempts as string N Maximum number of attemtps to resend automatically a payment link. Default value is 3 if not set.
transaction_ttl as string N transaction time to live in days. Default value is 365 if not set.
language as string N Language used for payment request. EN is default. Languages availables : {EN,FR}
customer_email as string Y customer email to send receipt
customer_name as string N Customer name, use it in order to prefill payment form
customer_phone as string N Always put international prefix for phone numbers +1 for US +33 for France
Go to top

Returns

Default return format is : JSON

Attribute Description
return_message as string Only if error, will return a error message to explain return_code
url_checkout as string url to payment form
track_id as string Your track_id sent in your request
url_qr as string Url to the QR code associated with this transaction
raw_qr as string Binary string of the QR Code in a png format
trid as string Unique transaction id. Use this id with the isValid endpoint
return_code as string return code, 0 if OK. See error codes tab at the end.

end-point return here after




POST
/api/2.0/mobip/create_one_use_qr
 (Public)

Description :

Inputs
Attribute Required Description Set a value
item_name as string Y Name or description of the product or service you are selling
language as string N Language used for payment request. EN is default. Languages availables : {EN,FR}
track_id as string N Optional : Your own transaction id or reference for tracking purpose
tax_amount_in_cents as integer Y Total amount without taxes of transaction in cents of your account's currency. Means if your account is set in USD, this will be USD.
item_amount_in_cents as integer Y Item price without taxes
customer_name as string N Customer name, use it in order to prefill payment form
customer_email as string N customer email to send receipt
call_back_url as string Y URL callback who will receive transaction the asynchronous response of the transaction. Ex : https://myserver.com/my_callback.php?resp_code=PROCESSED. resp_code={PROCESSED, CANCELLED, ERROR} , Once processed, you have to use mobip/isvalid to get the status of the transaction who can be PAID, DENIED or CANCELLED
redirect_url as string Y URL where MOBIP's server will redirect the user after finishing a transaction. Should be a page on merchant's webiste. The expected url format is : [protocol]://[url] like https://mywebpage.html
transaction_ttl as string N transaction time to live in days. Default value is 365 if not set.
access_token as string Y Connection token gave by connect/get_token
customer_phone as string N Always put international prefix for phone numbers +1 for US +33 for France
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
url_qr as string url to the QR image on our server.
return_message as string Only if error, will return a error message to explain return_code
trid as string Unique transaction id. Use this id with the isValid endpoint
url_checkout as string url to payment form

end-point return here after




GET
/api/2.0/mobip/is_valid
 (Public)

Description :

Inputs
Attribute Required Description Set a value
access_token as string Y Connection token gave by connect/get_token
trid as string Y Transaction id.
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code
transaction_status as string Possible values ={ PAID, DENIED, PENDING, CANCELLED, ERROR}

end-point return here after




POST
/api/2.0/mobip/cancel_transaction
 (Public)

Description :

Inputs
Attribute Required Description Set a value
trid as string Y Transaction id.
access_token as string Y Connection token gave by connect/get_token
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code

end-point return here after




POST
/api/2.0/mobip/create_reusable_qr
 (Public)

Description :

Inputs
Attribute Required Description Set a value
access_token as string Y Connection token gave by connect/get_token
item_amount as integer Y Item price in cents of currency account. (EUR is default).
item_name as string Y Name or description of the product or service you are selling
tax_amount as integer Y Total of taxes to add to product amount.
item_photo as string Y url of picture discribing the item. The content will be uploaded on the platform.
item_video as string N url to video describing the product
item_message as string N Shot message to add on the pop up
item_reference as string N Item reference or external or internal system
item_category as string N Optional info, item category
item_brand as string N Optional info, Brand
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
qr_id as string id of reusable QR.
url_qr as string url to the QR image on our server.
url_checkout as string url to payment form
return_message as string Only if error, will return a error message to explain return_code

end-point return here after




GET
/api/2.0/mobip/get_stats
 (Public)

Description :

Inputs
Attribute Required Description Set a value
day as string Y format is YYYY-MM-DD, if empty, no file is generated
access_token as string Y Connection token gave by connect/get_token
month_period as string Y format is YYYY-MM, current month is used if empty
Go to top

Returns

Default return format is : JSON

Attribute Description
url as string URL vers le fichier de stat à récupérer. Le fichier reste présent pendant 24H
return_message as string Only if error, will return a error message to explain return_code
return_code as string return code, 0 if OK. See error codes tab at the end.

end-point return here after




GET
/api/2.0/mobip/get_account_by_external_id
 (Public)

Description :

Inputs
Attribute Required Description Set a value
access_token as string Y Connection token gave by connect/get_token
external_account_id as string Y external_account_id identifies the account to retrieve
document_only as boolean N if true return only the document data from document_list all other values are not return.
document_list as string N Optional, by default no document are returned.
Enter here the list of document you want to download. Each element is separated by a
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code
account_data as array List of all the account data : attribute_name, attribute_type, attribute_value, is_updatable ...

end-point return here after




POST
/api/2.0/mobip/update_account
 (Restricted)

Description :

Inputs
Attribute Required Description Set a value
access_token as string Y Connection token gave by connect/get_token
account_data as array Y array structured like this : ['account_attribute_name'] = value in JSON format. List of allowed parameters is :
External_AccountID,
Public_Payment_Provider_key,
Private_Payment_Provider_key,
Payment_Provider_login
uid as string Y user_id. Identifies the account to update.
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code

end-point return here after




GET
/api/2.0/mobip/get_transaction
 (Public)

Description :

Inputs
Attribute Required Description Set a value
access_token as string Y Connection token gave by connect/get_token
trid as string Y Transaction id.
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
transaction_data as array All data for transaction identified by trid
return_message as string Only if error, will return a error message to explain return_code

end-point return here after




GET
/api/2.0/mobip/get_invoice
 (Public)

Description :

Inputs
Attribute Required Description Set a value
invoice_id as string Y An invoice_id coming from get_invoices_list
access_token as string Y Connection token gave by connect/get_token
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code
invoice_data as array All invoice data for invoice_id

end-point return here after




POST
/api/2.0/neosystems/set_mobip_transactions
 (Restricted)

Description : Set a list of transactions as processed by neosystems. That means, remove these transactions from neosystems/get_mobip_transactions

Inputs
Attribute Required Description Set a value
trid_list as string Y List of mobip_trid to remove. each element must be separated by a pipe
access_token as string Y Connection token gave by connect/get_token
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
removed_transactions_list as array list of all removed transactions.

end-point return here after




GET
/api/2.0/neosystems/get_mobip_transactions
 (Restricted)

Description : Get list of mobip transactions to process by NEOSYSTEMS

Inputs
Attribute Required Description Set a value
limit as string N Set the maximum number of lines to retrieve. If nothing is set will send all the data
access_token as string Y Connection token gave by connect/get_token
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
transactions_list as array All transactions to process : id_flux, merchant_name, mobip_merchant_id, amount, fees, customer_name, customer_email ...

end-point return here after




GET
/api/2.0/mobip/get_account
 (Restricted)

Description :

Inputs
Attribute Required Description Set a value
document_only as boolean N if true return only the document data from document_list all other values are not return.
access_token as string Y Connection token gave by connect/get_token
uid as string Y user_id. Identifies the account to retrieve
document_list as string N Optional, by default no document are returned.
Enter here the list of document you want to download. Each element is separated by a
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
return_message as string Only if error, will return a error message to explain return_code
account_data as array List of all the account data : attribute_name, attribute_type, attribute_value, is_updatable ...

end-point return here after




GET
/api/2.0/mobip/get_invoice_list
 (Public)

Description :

Inputs
Attribute Required Description Set a value
uid as string Y user_id. Identifies the account to retrieve
access_token as string Y Connection token gave by connect/get_token
Go to top

Returns

Default return format is : JSON

Attribute Description
return_code as string return code, 0 if OK. See error codes tab at the end.
invoice_data as array List of all invoice_id, invoice_date, amount
return_message as string Only if error, will return a error message to explain return_code

end-point return here after