Tabeo offers a synchronous API for third-party integrations. For fulfilment purposes, offers may be polled at certain intervals to observe status changes. These endpoints may be used to integrate Tabeo with a variety of shop and cart systems.
Endpoint to create a new Pay Over Time (finance) or Pay Now (card payments) offer.
A POST endpoint
https://demo.api.tabeo.co.uk/v1/merchant/integration-offers
The endpoint will respond with an offer object json. This will contain all pertinent information relating to the offer. You will notice that the offer object has a new field, countryCode, which indicates the ISO code of the country for the offer, e.g. gb, nl, etc.
curl -X POST \
https://demo.api.tabeo.co.uk/v1/merchant/integration-offers \
-H 'Authorization: Bearer [AUTHORIZATION TOKEN]' \
-H 'Content-Type: application/json' \
-d @- << EOF
{
"consumerFirstName": "Foo",
"consumerLastName": "Bar",
"price": 120000,
"consumerPhoneNumber": "07511223131",
"consumerEmail": "[email protected]",
"title": "Bridge",
"currency": "gbp",
"initialPaymentPlanOptions": [12,24],
"externalMetadata": {"guid":33983,"id":"TyaJHGA-1736"}
}
EOF"data": {
"offer": {
"bankAccountAttempts": 0,
"bankAccountID": null,
"bankAccountLastMissingMandateReminderSentAt": null,
"bankAccountRemovedAt": null,
"buyerCode": null,
"consumerEmail": "[email protected]",
"consumerFirstName": "Foo",
"consumerGender": null,
"consumerID": null,
"consumerLastName": "Bar",
"consumerMiddleName": null,
"consumerPhoneNumber": "07511223131",
"countryCode": "gb",
"createdAt": "2021-03-11T14:41:29.727533353Z",
"currency": "gbp",
"expiresAt": "2021-03-18T14:41:29.711714478Z",
"feeAmount": null,
"hardCheckStatus": null,
"id": 3019,
"lastStateTransitionedAt": "2021-03-11T14:41:29.711756579Z",
"legacyOfferID": null,
"loanAgreementID": null,
"loanID": null,
"merchantID": 291,
"merchantLateRefundFeeAmountToDate": null,
"merchantNetProceedsTransfers": [],
"merchantPayoutAt": null,
"merchantProceedsTransferredAt": null,
"metadata": {
"autoConfirmation": false,
"externalMetadata": {
"id": "25372-s",
"stuff": 33983,
"system": "u874YYns"
},
"overviewShortLink": "https://demo.m.tabeo.co.uk/r/eXFwR",
"patientName": "Foo Bar",
"publicShortLink": "https://demo.m.tabeo.co.uk/r/rnGLx",
"riskProfiles": [
{
"order": 0,
"name": "default",
"lenderCode": null,
"loanOptions": [
{
"numberOfMonths": 24,
"interestRate": 0.099,
"rebateDays": 0,
"isRegulated": true,
"isAvailableForInitialPaymentPlan": true
}
],
"fundingType": "default"
},
{
"order": 3,
"name": "profile_unfunded",
"lenderCode": "unfunded",
"loanOptions": [
{
"numberOfMonths": 12,
"interestRate": 0,
"rebateDays": 0,
"isRegulated": false,
"isAvailableForInitialPaymentPlan": false
}
],
"fundingType": "unfunded"
}
]
},
"numberOfPaymentDayChanges": 0,
"paymentAuthorization": null,
"paymentGateway": "",
"paymentSourceAttempts": 0,
"paymentSourceID": null,
"payoutGateway": "stripe_connect",
"price": 249900,
"publicAccessToken": "RxesHjzVjdiFbKcSNPItuRIPYJnWhHpAxLpXNfdMpGhxOByWKjRKKxtstLxqWGJr",
"reference": null,
"referralID": null,
"revisedPrice": null,
"revisedRequiredMerchantFeeAmount": null,
"revisedValueAtRisk": null,
"status": "new",
"title": "Bridge",
"totalMerchantRefundAmountToDate": null,
"type": "pay_over_time",
"updatedAt": "2021-03-11T14:41:29.751277725Z",
"uuid": "cb4a3da6-122a-5a24-9e0c-475ab61b9fb6",
"valueAtRisk": null
}
},
"status": "success",
"type": "response_ready"
}A GET endpoint
https://demo.api.tabeo.co.uk/v1/merchant/offers/:offerid?subResource=metadata
curl -X GET \ https://demo.api.tabeo.co.uk/v1/merchant/offers/:offerid?subResource=metadata \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]' \ -H 'Content-Type: application/json' \ -H 'cache-control: no-cache'
For indication of successful application and payment completion as a signal to fulfil product delivery, the status field of the offer object may be observed for any of the following: pay_now_payment_succeeded, first_payment_captured, subscribed, merchant_proceeds_transferred, merchant_payout_processed
For offers with transferred status, please see Getting referred offers below.
A GET endpoint
https://demo.api.tabeo.co.uk/v1/merchant/offers
To retrieve up to 6 offers with any of the following statuses: loan_agreement_accepted, pay_now_payment_authorization_succeeded, first_payment_capture_failed].
curl -X GET \ 'https://demo.api.tabeo.co.uk/v1/merchant/offers?order=updatedAt:desc&condition=status:[loan_agreement_accepted,pay_now_payment_authorization_succeeded,first_payment_capture_failed]&limit=6&offset=0' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
Without any status constraints and up to 100 offers ordered by updatedAt field:
curl -X GET \ 'https://demo.api.tabeo.co.uk/v1/merchant/offers?order=updatedAt:desc&limit=100&offset=0' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
If you want to limit it to say only ones with 'merchant_proceeds_transferred', then you'd do something like this:
curl -X GET \ 'https://demo.api.tabeo.co.uk/v1/merchant/offers?condition=status:[merchant_proceeds_transferred]&order=updatedAt:desc&limit=100&offset=0' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
Some offers may be transferred to another applicant in the case of the initial applicant failing checks. Such offers are identifiable with status: “transferred”.
A GET endpoint
https://api.tabeo.co.uk/v1/merchant/offers/:offerid?subResource=transferredOffer
When getting the offer, a transferredOffer sub resource may be applied on the old offer to get a sub resource with the new offer:
curl -X GET \ 'https://api.tabeo.co.uk/v1/merchant/offers/28599?subResource=transferredOffer' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
This will get transferredOffer id of 28756
You can then GET the new offer with id 28756 and monitor its status .
If required, legacyOffer sub resource id may be used on the new offer to get a sub resource with the old/legacy offer:
curl -X GET \ 'https://api.tabeo.co.uk/v1/merchant/offers/28756?subResource=legacyOffer' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
This will get a legacyOffer id of 28599.
The following is the currently specified list of possible statuses for the offer object.
In addition to the above discrete states, there is a simplified status that may be retrieved with the “simpleStatus” sub resource. It works with both single offer and collection requests.
curl -X GET \ 'https://api.tabeo.co.uk/v1/merchant/offers/28756?subResource=simpleStatus' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
curl -X GET \ 'https://demo.api.tabeo.co.uk/v1/merchant/offers?order=updatedAt:desc&limit=100&offset=0&subResource=simpleStatus' \ -H 'Authorization: Bearer [AUTHORIZATION TOKEN]'
The caveat is that sub resources do not have predicates, so you’ll still need to depend on the condition=status:[<state_1>,...,<state_n>] to get only offers that meet certain state conditions.
The current groupings of status as simpleStatus is as follows: