Triple Play Pay API: TRIPLE.JS
API KEY: Can either be in the HTTP Header Authorization: bearer testapikey
or included as a parameter "apikey" : "testapikey"
IFRAME SDK: API located here: triple.js
REST URL: https://tripleplaypay.com/api/<command>
SANDBOX: Sandbox API that simulates production: https://sandbox.tripleplaypay.com/api
WEBSOCKET: wss://tripleplaypay.com/ws/api
- example message {<api command>:{parameter1:value, parameter2:value...}}
WORDPRESS PLUGIN INSTALLATION: wordpress install guide
charge
post
Process payment or settle a previous charge. card* bank** terminal***
Parameter | Type | Description | |
---|---|---|---|
amount | string |
Required |
The total transaction amount. This is the amount of funds to move on the card |
id | string |
Transaction ID used to settle an authorized payment method (cc or bank info then not required) | |
token | string |
Use a saved payment token (cc or bank info then not required) | |
cc | string |
Required* |
Credit Card Number with or without dashes |
mm | string |
Required* |
2 digit month |
yy | string |
Required* |
2 digit year |
cvv | string |
Required* |
Card Verification Value found on the card (CVV2, CVC2, CID) |
zip / zipcode | string |
Postal code | |
accountNumber | string |
Required** |
Bank Account Number |
routingNumber | string |
Required** |
Bank Routing Number |
type | string |
** |
Options: checking, savings default : checking |
laneId | number |
Required*** |
Initiate a Credit Card Terminal transaction by its laneId (assigned during creation) |
ticket | string |
Ticket Number used by POS | |
items | list |
List of items for receipt and level3 data. |
|
meta | object |
Optional user defined object to be returned with future response |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "charge" }
authorize
post
Used to verify funds when the total amount of the purchase is unknown.
Parameter | Type | Description | |
---|---|---|---|
amount | string |
Required |
The total transaction amount. This is the amount of funds to move on the card |
cc | string |
Required |
Credit Card Number with or without dashes |
mm | string |
Required |
2 digit Month |
yy | string |
Required |
2 digit Year |
cvv | string |
Required |
Card Verification Value found on the card (CVV2, CVC2, CID) |
zip / zipcode | string |
Postal code | |
ticket | string |
Ticket Number used by POS | |
laneId | number |
Required*** |
Initiate a Credit Card Terminal authorization by its laneId (assigned during creation) |
meta | object |
Optional user defined object to be returned with future response |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "authorize" }
settle
post
Same as sending "id" to charge, this method will settle an outstanding Authorization.
Parameter | Type | Description | |
---|---|---|---|
id | string |
Required |
Transaction ID of charged event |
ticket | string |
Ticket Number used by POS | |
laneId | number |
Required*** |
Initiate a Credit Card Terminal settlement by its laneId |
meta | object |
Optional user defined object to be returned with future response |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "settle" }
refund
post
Void/Refund a customer for a previous transaction or Credit the account. void/refund* credit** terminal***
Parameter | Type | Description | |
---|---|---|---|
id | string |
Void/Refund a previous transaction by its ID | |
amount | string |
Required** |
Refund amount. Also used for partial voids. |
cc | string |
Required** |
Credit Card Number with or without dashes |
mm | string |
Required** |
2 digit month |
yy | string |
Required** |
2 digit year |
cvv | string |
Card Verification Value | |
zip / zipcode | string |
Postal code | |
ticket | string |
Ticket Number used by POS | |
laneId | number |
Required*** |
Initiate a Credit Card Terminal refund by its laneId (will try to void if possible) |
meta | object |
Optional user defined object to be returned with future response |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "refund" }
tokenize
post
Create a token for later use.
Parameter | Type | Description | |
---|---|---|---|
string |
Required |
Email to associate the account for future callback | |
cc | string |
Required |
Credit Card Number with or without dashes |
mm | string |
Required |
2 digit Month |
yy | string |
Required |
2 digit Year |
cvv | string |
Required |
Card Verification Value found on the card (CVV2, CVC2, CID) |
accountNumber | string |
Required** |
Bank Account Number |
routingNumber | string |
Required** |
Bank Routing Number |
type | string |
Required** |
Options: checking, savings default : checking |
Response JSON
{ "status": true or false, "id": "<tokenId>", "message": result (json) or error message (string), "method": "tokenize" }
terminal
post
Configure new Credit Card Terminal or get status of existing. Response <code>id</code> will be its laneId.
Parameter | Type | Description | |
---|---|---|---|
activationCode | string |
Activation Code on Terminal Screen | |
terminalId | string |
Name of Terminal | |
description | string |
Description |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "terminal" }
terminal
get
Get terminal(s) and their status.
Parameter | Type | Description | |
---|---|---|---|
name | string |
Search by terminalId, if no name all terminals will be retrieved |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "terminal" }
report
get
Get transaction detail history
Parameter | Type | Description | |
---|---|---|---|
start | string |
Start of date range YYYY-MM-DD * defaults to that month |
|
end | string |
End of date range YYYY-MM-DD | |
filter | object |
Filter results on any key value pair. ex: {"method":"charge"} or nested {"message":{"details": { "Batch": {"HostItemID": "12"}}}} |
|
timezone | string |
Convert to timezone. default : tz set in client preferences |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "report" }
subscription
get post
Setup a payment subscription or get details/history. Can also send to /api/charge
Parameter | Type | Description | |
---|---|---|---|
id | string |
GET specific subscription by id. AN empty call gets a list of all current subscriptions | |
cancelId | string |
Subscription ID you want to cancel | |
amount | string |
Required |
Amount charged per cycle. |
start | string |
Required |
Start of subscription YYYY-MM-DD |
end | string |
End of subscription. YYYY-MM-DD Empty means forever. |
|
cycles | string |
Set number of iterations. end will be calculated for you. |
|
interval | string |
Required |
daily, weekly, monthly, yearly |
frequency | number |
1 means every interval, 2 would mean every other interval * Every other week would be 2 |
|
string |
Required |
Subscribers email address | |
payment | object |
Required |
Same details as charge . (credit card only method supported currently) |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "subscription" }
receipt
get
Generate a digital receipt in PNG format of a previous transaction
Parameter | Type | Description | |
---|---|---|---|
id | string |
Required |
Ticket id returned by charge method |
image | string |
URL of image to embed in receipt header | |
text | string |
Text to embed in receipt header | |
width | string |
Set width of digital ticket | |
font | string |
Set font type to use instead of default for ticket. roboto, montserrat, redhat |
|
output | string |
Output either base64 (default) or a click to download link link, base64 |
Response JSON
{ "status": true or false, "id": "<transactionId>", "message": result (json) or error message (string), "method": "receipt" }