Create a transaction
Last updated
Was this helpful?
Last updated
Was this helpful?
API for creating new payment requests, this API create .
POST
https://api.sensepass.com/api/transactions/init
This API creates new payment request based on the fields below.
Authentication Request Body fields
methodType
string
Transaction Type: 0. 'payment' = Regular Payment 1. 'tokenize' = Tokenization 2. 'authorize' = Authorization 3. 'credit' = Credit transaction (Refund transaction without a reference to original payment transaction)
amount*
number
The required amount for this transaction (Cents).
If products are a part of the transaction - they are all summed up & calculated via the following formula:
(amount + vat - discount) * quantity e.g. (10 + 1.7 - 1) * 2.
isCent
boolean
Determines if Amount represents in cents or not
timeOut
number
Time until the transaction will be timed out (seconds)
currency*
string
[ USD, CAD, ILS, EUR, RUB ]
maxInstallments
number
Installments Limit for this transaction - Valid only for credit card payment
returnURL
string
URL to redirect consumer after Success or Error (For E-Commerce Transactions)
cancelURL
string
URL to redirect consumer on cancel event from consumer (For E-Commerce Transactions)
callbackURL
string
URL to Callback/webhooks API - SensePass will call this API with full Transaction Entity for every status change about this transaction
posData
object
Any data (object/array/string/number etc...) to be received in the callback url or transaction's responses
clientPhoneNumber
string
SMS message will be sent to this consumer number for SMS payment
clientEmail
string
email message will be sent to this consumer email for remote payment
clientName
string
consumer name for the payment
reason
string
The reason for this payment - This field will be presented to the consumer
invoice
object
Used to present invoice for the consumer before the payment
receipt
object
Used for present receipt for the consumer after the payment
emailConfig.paymentRequest.language
string
[ en, he, ru ]
receiptNotifications
object
Receipt Notifications
products
object
Products information
metadata
object
billingAddress
object
shippingAddress
object
paymentDetails
object
Payment details Input
hideAmount
boolean
Determines whether the transaction amount is displayed on the payment page or not
additionalData
object
Basic request example to create a new transaction.
See our full examples for creating transactions on the left menu.
For delivery status - See "SMS" field in
See invoice object entity:
See receipt object entity:
entity:
See product object entity:
a unique array with a key-value pair for displaying information on SensePass Dashboard (backoffice)
Customer's billing address entity:
Customer's shipping address entity:
entity:
Any additional data that may be sent to the processor
See Transactions entity schema:
Full Transaction Entity schema: