Cashflows Gateway API

Our Gateway API provides a structured and consistent way for you to send requests to our payment gateway. It includes calls for creating payment jobs, refunds and other payment-related operations. The Gateway API handles extensive validation and conversion for each request. It provides added security with built-in authentication and authorisation checks.

Our API is REST-based. It accepts calls in JavaScript Object Notation (JSON). You can use different programming languages to create the JSON. Our API uses standard HTTP response codes and familiar verbs including:

  • GET - To retrieve a resource.

  • PUT - to update existing resources.

  • PATCH - To update existing resources.

  • DELETE - To delete existing resources.

Before you start

You need access to Cashflows Go. Cashflows Go is your online account with us where you can find the access credentials that you need to be able to communicate with the gateway.

When you first sign up with us, we send you a welcome email that includes the details that you need to sign into Cashflows Go.

For testing, you need an integration account. If you don’t have one you can request one by email to techsupport@cashflows.com.

Depending on your IP and Geolocation settings, you may need to whitelist Ireland and these IPs:

  • Integration Environment: 54.75.5.171 and 54.73.83.234

  • Production Environment: 54.74.58.255 and 52.215.48.101

Authentication

When we have set you up to use our gateway, we provide you with your:

Configuration ID

This is the unique identifier of your business account (also referred to as the merchant account). You need to include this in API messages so that we can recognise your business and match transactions to it.

API key

This is the key to use for hashing API messages that you send us.

These are available for you to collect in Cashflows Go. You need to include the configuration ID in the HTTP header of each call to the gateway. You also need to include a SHA512 hash in the header. This is to sign each API call.

Signing API calls

All messages that we send are signed with a SHA512 hash. You must use the same hashing technique that we do so that we can match our hash with yours. The hash assures message consistency and protects the payment request from being tampered with during transfer to our gateway (a man-in-the-middle attack).

To calculate the hash, append the message body to the API password, for example: . If the message body is empty, you only need to hash the password.

The calculated hash is then converted to a hex-string and sent in the header with Hash: xxxxxx. It’s possible for the gateway to have two passwords at one time. When you change a password, you need to first create a new second password. When all systems have migrated to the new password, you can remove the first password. This way you can change a password without any downtime.

HTTP header

As well as the hash, you must supply the configuration ID in the HTTP header of each call to the gateway. The configuration ID enables the gateway to identify your application and recognise the configuration settings for your business. The header must be in the format:

ConfigurationId: xxxxx

Hash:ExampleExampleExampleExampleExampleExampleExampleExampleExample ExampleExampleExampleExampleExampleExample

Sending us payment details

Payment requests need to be in the form of a HTTPS POST to either our integration or production environment:

Response codes

Our gateway uses the following standardised codes in the responses that you receive. These codes tell you if a request was successful or not. A code that starts with 2 indicates success. A code that starts with 4 indicates an issue.

Code

Meaning

200

Payment or payment job received or retrieved or cancelled successfully

201

Payment job created successfully

400

Request contains errors

401

Invalid token

403

Insufficient permissions

404

Configuration not found

406

Bad response

Testing

To enable you to test your integration before going live, we have an integration environment. Here you can simulate different payment scenarios without affecting any live data or interacting with any external finance or issuing networks. We also have some test cards that you can use.

If you need an integration account for testing purposes, send an email request to implementations@cashflows.com.

Going live

Important

You need different credentials for the integration and production environments.

Before you can connect to our production environment for going live, you need:

  • A production account

  • Sign-in credentials

We provide these when your account has been approved. If you have not received these, send an email to support@cashflows.com.

PaymentJobs parameters

To create a payment job, you must provide a payment job request that contains at least the mandatory required fields. To help you track payments, we recommend that you provide more than the mandatory fields in the payment job.

Parameters

Description

Type

type

Valid values: Payment, Credit

String

locale

The Locale enum specifies a unique entry for each supported culture, based on RFC 4646. The name is a combination of an ISO 639 two-letter lowercase (ISO 639-1) culture code associated with a language and an ISO 3166 two-letter uppercase (ISO 3166-1 alpha-2) subculture code associated with country or region.

String

timeZone

The time zone of the intented audience of the payment job.

String

order

The request object used to update an order.

Object

order.orderNumber

The order number.

String

order.note

Additional comments or requests.

String

order.customerReference

A reference to the customer used for default billing address, billing identity and shipping address details.

Integer

order.billingAddress

Object related to the billing address.

Object

billingAddress.title

A prefix or suffix added to someone’s name in certain contexts. For example Mr. or Ms./Mrs. for an adult man or woman. This value is used as is, regardless of the locale specified in the payment job.

String

billingAddress.firstName

The given name of the addressee.

String

billingAddress.middleName

The middle part of the name of the addressee. This is the portion of a personal name that is written between the person’s given name and their surname.

String

billingAddress.lastName

The last part of the name of the addressee. This usually is the person’s surname.

String

billingAddress.countryIso3166Alpha2

ISO country code.

String

billingAddress.addressLine1

Primary address information, such as street name and house number.

String

billingAddress.addressLine2

Additional address information, such as floor number or apartment number.

String

billingAddress.zipCode

The zip or postal code.

String

billingAddress.city

The name of the city.

String

billingAddress.stateProvince

The name of the state or province.

String

billingAddress.phoneNumber1

Primary telephone number of the addressee.

String

billingAddress.phoneNumber1Type

Type of phone number: Unknown Mobile ``Fixed

String

billingAddress.phoneNumber2

Secondary telephone number of the addressee.

String

billingAddress.phoneNumber2Type

Type of phone number: Unknown Mobile ``Fixed

String

billingAddress.organisation

Name of the company or organisation, if the address is a company or organisation.

String

billingAddress.department

Name of the department, if the address is a company or organisation.

String

order.billingIdentity

An object containing information, additional to the address object, such as an email address, gender, and government numbers.

Object

billingIdentity.debtorID

A reference, unique to the company, to the person this object relates to. This reference is supplied by the merchant.

String

billingIdentity.emailAddress

Email address of the person this object relates to.

String

billingIdentity.gender

Valid values: Female Male

String

billingIdentity.dateOfBirth

The date of birth of the person this object relates to.

String

billingIdentity.socialSecurityNumber

A number, unique to the specified country, identifying the person this object relates to. This property can for example be used for a nine-digit Social Security number (SSN) for U.S citizens or a burgerservicenummer (BSN) for Dutch citizens.

String

billingIdentity.chamberOfCommerceNumber

String

billingIdentity.vatNumber

A globally unique value added tax identification number of the person, organisation or company this object relates to

String

order.shippingAddress

Object related to the shipping address.

Object

shippingAddress.title

A prefix or suffix added to someone’s name in certain contexts. For example Mr. or Ms./Mrs. for an adult man or woman. This value is used as is, regardless of the locale specified in the payment job.

String

shippingAddress.firstName

The given name of the addressee.

String

shippingAddress.middleName

The middle part of the name of the addressee. This is the portion of a personal name that is written between the person’s given name and their surname.

String

shippingAddress.lastName

The last part of the name of the addressee. This usually is the person’s surname.

String

shippingAddress.countryIso3166Alpha2

ISO country code.

String

shippingAddress.addressLine1

Primary address information, such as street name and house number.

String

shippingAddress.addressLine2

Additional address information, such as floor number or apartment number.

String

shippingAddress.zipCode

The zip or postal code.

String

shippingAddress.city

The name of the city.

String

shippingAddress.stateProvince

The name of the state or province.

String

shippingAddress.phoneNumber1

Primary telephone number of the addressee.

String

shippingAddress.phoneNumber1Type

Type of phone number: Unknown Mobile ``Fixed

String

shippingAddress.phoneNumber2

Secondary telephone number of the addressee.

String

shippingAddress.phoneNumber2Type

Type of phone number: Unknown Mobile ``Fixed

String

shippingAddress.organisation

Name of the company or organisation, if the address is a company or organisation.

String

shippingAddress.department

Name of the department, if the address is a company or organisation.

String

order.orderLines

List of order lines that that contain the order line details.

Object

orderLines.lineNumber

A number, unique to an order, to determine the order of the order lines.

Integer

orderLines.type

Valid: PhysicalItem DigitalItem ShippingCost PaymentCost Discount GiftCard ShopCredit

String

orderLines.skuCode

A (unique) code that refers to a particular stock keeping unit.

String

orderLines.name

The name of the product or service.

String

orderLines.description

A description of the product or service.

String

orderLines.quantity

The ordered quantity.

Double

orderLines.unitPriceExclVat

Unit price excluding value-added tax (VAT), either one or both unit prices must be specified.

Double

orderLines.unitPriceInclVat

Unit price including value-added tax (VAT), either one or both unit prices must be specified.

Double

orderLines.vatPercentage

Applied VAT percentage.

Double

orderLines.vatPercentageLabel

VAT percentage to display.

String

orderLines.discountPercentageLabel

Discount percentage to display.

String

orderLines.totalLineAmount

Total order line amount. Including VAT if the unit price including VAT is specified, otherwise excluding VAT.

Double

orderLines.url

A URL that is shown in the portal to the receiver. This can be used to store a link to a product for easy navigation.

String

parentPaymentJobReference

A reference to the parent payment job.

Integer

paymentMethodsToUse

A list of payment methods (for example iDeal, PayPal, AfterPay) to enable for this request. If none are supplied, all configured and applicable payment methods will be used, valid values: PayPal CreditCard Creditcard DebitCard Debitcard Card

Array

parameters

Additional parameters, like AutoInvoice, and HostedNotCancelable to use when executing the request, as well as payment method specific parameters, like BIC for iDEAL, for use by one or more payment methods. Key options: OriginatingIpAddress, OriginHeader, UserAgent, ThreeDSecureChallengeAcceptHeader, ThreeDSecureV2ChallengeWindowSize, BrowserLanguage, BrowserTimeZoneOffset, BrowserJavaEnabled, BrowserJavaScriptEnabled, BrowserScreenHeight, BrowserScreenWidth, BrowserScreenColorDepth, ReturnUrlSuccess, ReturnUrlFailed, ReturnUrlCancelled, WebhookUrl, PaymentPageReference, SimulatedStatus, IdealBic, SelectedPaymentMethod, CardNumber, CardCvc, CardExpiryMonth, CardExpiryYear, CardHolderName, Mcc, RecipientDetails, PaRes, Md, RReq, CRes, ThreeDSSessionData, ThreeDSMethodData, ThreeDSecureXid, ThreeDSecureCavv, ThreeDSecureEci, ThreeDSecureVersion, ThreeDSecureDSTransId, Token, PayerId, GoogleAnalyticsClientId, AllowedParentFrameDomains, Descriptor, EWalletType, ApplePayTransactionIdentifier

Object

options

Additional options used to steer payment job related flows, valid values: IsRecurringPaymentJobParent IsMoto StoreCustomerInformation StoreCardDetails GenerateToken

Array

displayUrl

A URL that is shown in the portal to the receiver. This can be used to store a link to an order in the receiver’s order system for easy navigation

String

currency

Currency used for the transaction

String

amountToCollect

The amount to collect in this payment job. This amount is initially supplied by the instantiator of the payment request. The amount which is actually collected is the sum of the amount to collect and the surcharge amount together.

Double

expirationDateTimeUtc

The date and time the payment job expires and is no longer valid. If not supplied, the payment job will expire after six months after creation.

String

recurrenceCriteria

Specifics of the recurrence.

Object

recurrenceCriteria.recurrenceType

Valid values: Subscription Instalment Unscheduled CustomerInitiated

String

recurrenceCriteria.recurringExpiry

The date and time after which this recurrence is no longer valid.

String

recurrenceCriteria.recurringFrequency

The minimum set of days between transactions.

Integer

recurrenceCriteria.instalments

The amount of instalments.

Integer

PaymentJobs examples

Click to show a new payment job
import requests
import json

# Define the API endpoint
url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs"

# Define the payload (data to send with the request)
payload = json.dumps({
"amountToCollect": "15.50",
"currency": "GBP"
})

# Define the headers
headers = {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
}

# Send the POST request to the API
response = requests.post(url, headers=headers, data=payload)

# Print the response text (or handle it as needed)
if response.status_code == 200:
print("Request was successful!")
print("Response: ", response.json())  # Assuming the server returns JSON data
else:
print(f"Request failed with status code {response.status_code}")
print("Response Text: ", response.text)
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.http.HttpHeaders;
import java.util.HashMap;
import java.util.Map;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";

        String payload = "{ "amountToCollect": "15.50", "currency": "GBP" }";

        // Setting the headers
        Map headers = new HashMap<>();
        headers.put("Hash", "YOUR_SIGNATURE_HASH");
        headers.put("ConfigurationId",
        "YOUR_CONFIGURATION_ID");
        headers.put("Content-Type", "application/json");

        // Create HTTP client
        HttpClient client = HttpClient.newHttpClient();

        // Build the HTTP request
        HttpRequest request = HttpRequest.newBuilder()
        .uri(URI.create(url))
        .header("Hash", headers.get("Hash"))
        .header("ConfigurationId", headers.get("ConfigurationId"))
        .header("Content-Type", headers.get("Content-Type"))
        .POST(HttpRequest.BodyPublishers.ofString(payload))
        .build();

        // Send the request and get the response
        HttpResponse response = client.send(request, HttpResponse.BodyHandlers.ofString());

        // Print the response
        System.out.println(response.body());
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";
        var payload = "{"amountToCollect": "15.50", "currency": "GBP"}";;

        var client = new HttpClient();;

        // Setting the headers
        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");;

        var content = new StringContent(payload, Encoding.UTF8, "application/json");;

        // Sending the POST request
        var response = await client.PostAsync(url, content);;

        // Reading and printing the response
        var responseContent = await response.Content.ReadAsStringAsync();
        Console.WriteLine(responseContent);
    }
}
const axios = require('axios');

const url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
const payload = {
amountToCollect: "15.50",
currency: "GBP"
};

const headers = {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
};

axios.post(url, payload, { headers })
.then(response => {
    console.log(response.data);
})
.catch(error => {
    console.error('Error:', error.response ? error.response.data : error.message);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = array(
'amountToCollect' => '15.50',
'currency' => 'GBP'
);

// Convert data array to JSON
$jsonData = json_encode($data);

// Set headers
$headers = array(
'Hash: YOUR_SIGNATURE_HASH',
'ConfigurationId: YOUR_CONFIGURATION_ID',
'Content-Type: application/json'
);

// Initialize cURL session
$ch = curl_init($url);

// Set cURL options
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $jsonData);

// Execute the request
$response = curl_exec($ch);

// Check for errors
if(curl_errno($ch)) {
echo 'cURL Error: ' . curl_error($ch);
} else {
echo $response; // Print the response
}

// Close the cURL session
curl_close($ch);

?>
require 'net/http'
require 'json'
require 'uri'

# URL for the API endpoint
url = URI.parse('https://gateway-inta.cashflows.com/api/gateway/payment-jobs')

# Payload (data to be sent)
payload = {
amountToCollect: "15.50",
currency: "GBP"
}.to_json

# Headers
headers = {
'Hash' => 'YOUR_SIGNATURE_HASH',
'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
'Content-Type' => 'application/json'
}

# Create a new HTTP request
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url.path, headers)
request.body = payload

# Send the request and get the response
begin
response = http.request(request)

# Print the response body
puts response.body
rescue StandardError => e
# Print error message if request fails
puts "Error: #{e.message}"
end
Click to show a new payment job with an order update
import requests
import json

data = {
    "amountToCollect": "363",
    "currency": "GBP",
    "order": {
        "orderNumber": "ORDER_NUMBER",
        "note": "My order note",
        "billingAddress": {
        "title": "Mr.",
        "firstName": "John",
        "lastName": "Doe",
        "countryIso3166Alpha2": "GB",
        "addressLine1": "Addressline1",
        "addressLine2": "Addressline2",
        "zipCode": "XX21 5XX",
        "city": "Cambridge",
        "phoneNumber1": "+44 999 000000",
        "phoneNumber1Type": "Fixed",
        "phoneNumber2": "+44 888 123456",
        "phoneNumber2Type": "Unknown",
        "organisation": "TestCompany"
        },
        "billingIdentity": {
            "emailAddress": "sales@example.com",
            "gender": "Female",
            "dateOfBirth": "2010-03-17T00:00:00Z"
        },
        "shippingAddress": {
            "title": "Mr.",
            "firstName": "John",
            "middleName": "Van",
            "lastName": "Dijk",
            "countryIso3166Alpha2": "GB",
            "addressLine1": "Business Centre Road",
            "addressLine2": "Unit 7",
            "zipCode": "XX12 1XX",
            "city": "TestCity",
            "phoneNumber1": "+44 999 000000",
            "phoneNumber1Type": "Fixed",
            "phoneNumber2": "+44 888 123456",
            "phoneNumber2Type": "Unknown",
            "organisation": "Sample Business Ltd"
        },
        "orderLines": [
            {
                "lineNumber": "1",
                "type": "PhysicalItem",
                "skuCode": "1234567890123",
                "name": "Bike",
                "quantity": "1",
                "unitPriceExclVat": "100",
                "unitPriceInclVat": "121",
                "vatPercentage": "21",
                "vatPercentageLabel": "Vat 21%",
                "discountPercentageLabel": "discount 6%",
                "totalLineAmount": "121"
            },
            {
                "lineNumber": "2",
                "type": "PhysicalItem",
                "skuCode": "1234567890124",
                "name": "Bike 2",
                "quantity": "2",
                "unitPriceExclVat": "100",
                "unitPriceInclVat": "121",
                "vatPercentage": "21",
                "vatPercentageLabel": "Vat 21%",
                "discountPercentageLabel": "discount 6%",
                "totalLineAmount": "242"
            }
        ]
    }
}

headers = {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
}

response = requests.post('https://gateway-inta.cashflows.com/api/gateway/payment-jobs', headers=headers, json=data)
print(response.json())
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.OutputStream;
import java.io.InputStreamReader;
import java.io.BufferedReader;

public class Main {
public static void main(String[] args) {
    try {
        String data = "{"
            + ""amountToCollect":"363","
            + ""currency":"GBP","
            + ""order":{"
            + ""orderNumber":"ORDER_NUMBER","
            + ""note":"My order note","
            + ""billingAddress":{"
            + ""title":"Mr.","
            + ""firstName":"John","
            + ""lastName":"Doe","
            + ""countryIso3166Alpha2":"GB","
            + ""addressLine1":"Addressline1","
            + ""addressLine2":"Addressline2","
            + ""zipCode":"XX21 5XX","
            + ""city":"Cambridge","
            + ""phoneNumber1":"+44 999 000000","
            + ""phoneNumber1Type":"Fixed","
            + ""phoneNumber2":"+44 888 123456","
            + ""phoneNumber2Type":"Unknown","
            + ""organisation":"TestCompany""
            + "},"
            + ""billingIdentity":{"
            + ""emailAddress":"sales@example.com","
            + ""gender":"Female","
            + ""dateOfBirth":"2010-03-17T00:00:00Z""
            + "},"
            + ""shippingAddress":{"
            + ""title":"Mr.","
            + ""firstName":"John","
            + ""middleName":"Van","
            + ""lastName":"Dijk","
            + ""countryIso3166Alpha2":"GB","
            + ""addressLine1":"Business Centre Road","
            + ""addressLine2":"Unit 7","
            + ""zipCode":"XX12 1XX","
            + ""city":"TestCity","
            + ""phoneNumber1":"+44 999 000000","
            + ""phoneNumber1Type":"Fixed","
            + ""phoneNumber2":"+44 888 123456","
            + ""phoneNumber2Type":"Unknown","
            + ""organisation":"Sample Business Ltd""
            + "},"
            + ""orderLines":["
            + "{"
            + ""lineNumber":"1","
            + ""type":"PhysicalItem","
            + ""skuCode":"1234567890123","
            + ""name":"Bike","
            + ""quantity":"1","
            + ""unitPriceExclVat":"100","
            + ""unitPriceInclVat":"121","
            + ""vatPercentage":"21","
            + ""vatPercentageLabel":"Vat 21%","
            + ""discountPercentageLabel":"discount 6%","
            + ""totalLineAmount":"121""
            + "},"
            + "{"
            + ""lineNumber":"2","
            + ""type":"PhysicalItem","
            + ""skuCode":"1234567890124","
            + ""name":"Bike 2","
            + ""quantity":"2","
            + ""unitPriceExclVat":"100","
            + ""unitPriceInclVat":"121","
            + ""vatPercentage":"21","
            + ""vatPercentageLabel":"Vat 21%","
            + ""discountPercentageLabel":"discount 6%","
            + ""totalLineAmount":"242""
            + "}"
            + "]"
            + "}";

        URL url = new URL("https://gateway-inta.cashflows.com/api/gateway/payment-jobs");
        HttpURLConnection conn = (HttpURLConnection) url.openConnection();
        conn.setRequestMethod("POST");
        conn.setRequestProperty("Content-Type", "application/json");
        conn.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        conn.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        conn.setDoOutput(true);

        try (OutputStream os = conn.getOutputStream()) {
            byte[] input = data.getBytes("utf-8");
            os.write(input, 0, input.length);
        }

        try (BufferedReader br = new BufferedReader(new InputStreamReader(conn.getInputStream(), "utf-8"))) {
            StringBuilder response = new StringBuilder();
            String responseLine;
            while ((responseLine = br.readLine()) != null) {
                response.append(responseLine.trim());
            }
            System.out.println(response.toString());
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
static async Task Main(string[] args)
{
    using (HttpClient client = new HttpClient())
    {
        var data = new
        {
            amountToCollect = "363",
            currency = "GBP",
            order = new
            {
            orderNumber = "ORDER_NUMBER",
            note = "My order note",
            billingAddress = new
            {
                title = "Mr.",
                firstName = "John",
                lastName = "Doe",
                countryIso3166Alpha2 = "GB",
                addressLine1 = "Addressline1",
                addressLine2 = "Addressline2",
                zipCode = "XX21 5XX",
                city = "Cambridge",
                phoneNumber1 = "+44 999 000000",
                phoneNumber1Type = "Fixed",
                phoneNumber2 = "+44 888 123456",
                phoneNumber2Type = "Unknown",
                organisation = "TestCompany"
            },
            billingIdentity = new
            {
                emailAddress = "sales@example.com",
                gender = "Female",
                dateOfBirth = "2010-03-17T00:00:00Z"
            },
            shippingAddress = new
            {
                title = "Mr.",
                firstName = "John",
                middleName = "Van",
                lastName = "Dijk",
                countryIso3166Alpha2 = "GB",
                addressLine1 = "Business Centre Road",
                addressLine2 = "Unit 7",
                zipCode = "XX12 1XX",
                city = "TestCity",
                phoneNumber1 = "+44 999 000000",
                phoneNumber1Type = "Fixed",
                phoneNumber2 = "+44 888 123456",
                phoneNumber2Type = "Unknown",
                organisation = "Sample Business Ltd"
            },
            orderLines = new[]
            {
                new
                {
                lineNumber = "1",
                type = "PhysicalItem",
                skuCode = "1234567890123",
                name = "Bike",
                quantity = "1",
                unitPriceExclVat = "100",
                unitPriceInclVat = "121",
                vatPercentage = "21",
                vatPercentageLabel = "Vat 21%",
                discountPercentageLabel = "discount 6%",
                totalLineAmount = "121"
                },
                new
                {
                lineNumber = "2",
                type = "PhysicalItem",
                skuCode = "1234567890124",
                name = "Bike 2",
                quantity = "2",
                unitPriceExclVat = "100",
                unitPriceInclVat = "121",
                vatPercentage = "21",
                vatPercentageLabel = "Vat 21%",
                discountPercentageLabel = "discount 6%",
                totalLineAmount = "242"
                }
            }
            }
        };

        var jsonData = System.Text.Json.JsonSerializer.Serialize(data);
        var content = new StringContent(jsonData, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        var response = await client.PostAsync("https://gateway-inta.cashflows.com/api/gateway/payment-jobs", content);
        string result = await response.Content.ReadAsStringAsync();

        Console.WriteLine(result);
        }
    }
}
const axios = require('axios');
let data = JSON.stringify({
"amountToCollect": "363",
"currency": "GBP",
"order": {
"orderNumber": "ORDER_NUMBER",
"note": "My order note",
"billingAddress": {
"title": "Mr.",
"firstName": "John",
"lastName": "Doe",
"countryIso3166Alpha2": "GB",
"addressLine1": "Addressline1",
"addressLine2": "Addressline2",
"zipCode": "XX21 5XX",
"city": "Cambridge",
"phoneNumber1": "+44 999 000000",
"phoneNumber1Type": "Fixed",
"phoneNumber2": "+44 888 123456",
"phoneNumber2Type": "Unknown",
"organisation": "TestCompany"
},
"billingIdentity": {
"emailAddress": "sales@example.com",
"gender": "Female",
"dateOfBirth": "2010-03-17T00:00:00Z"
},
"shippingAddress": {
"title": "Mr.",
"firstName": "John",
"middleName": "Van",
"lastName": "Dijk",
"countryIso3166Alpha2": "GB",
"addressLine1": "Business Centre Road",
"addressLine2": "Unit 7",
"zipCode": "XX12 1XX",
"city": "TestCity",
"phoneNumber1": "+44 999 000000",
"phoneNumber1Type": "Fixed",
"phoneNumber2": "+44 888 123456",
"phoneNumber2Type": "Unknown",
"organisation": "Sample Business Ltd"
},
"orderLines": [
{
    "lineNumber": "1",
    "type": "PhysicalItem",
    "skuCode": "1234567890123",
    "name": "Bike",
    "quantity": "1",
    "unitPriceExclVat": "100",
    "unitPriceInclVat": "121",
    "vatPercentage": "21",
    "vatPercentageLabel": "Vat 21%",
    "discountPercentageLabel": "discount 6%",
    "totalLineAmount": "121"
},
{
    "lineNumber": "2",
    "type": "PhysicalItem",
    "skuCode": "1234567890124",
    "name": "Bike 2",
    "quantity": "2",
    "unitPriceExclVat": "100",
    "unitPriceInclVat": "121",
    "vatPercentage": "21",
    "vatPercentageLabel": "Vat 21%",
    "discountPercentageLabel": "discount 6%",
    "totalLineAmount": "242"
}
]
}
});

let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
headers: {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
},
data : data
};

axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = array(
    "amountToCollect" => "363",
    "currency" => "GBP",
    "order" => array(
        "orderNumber" => "ORDER_NUMBER",
        "note" => "My order note",
        "billingAddress" => array(
        "title" => "Mr.",
        "firstName" => "John",
        "lastName" => "Doe",
        "countryIso3166Alpha2" => "GB",
        "addressLine1" => "Addressline1",
        "addressLine2" => "Addressline2",
        "zipCode" => "XX21 5XX",
        "city" => "Cambridge",
        "phoneNumber1" => "+44 999 000000",
        "phoneNumber1Type" => "Fixed",
        "phoneNumber2" => "+44 888 123456",
        "phoneNumber2Type" => "Unknown",
        "organisation" => "TestCompany"
        ),
        "billingIdentity" => array(
        "emailAddress" => "sales@example.com",
        "gender" => "Female",
        "dateOfBirth" => "2010-03-17T00:00:00Z"
        ),
        "shippingAddress" => array(
        "title" => "Mr.",
        "firstName" => "John",
        "middleName" => "Van",
        "lastName" => "Dijk",
        "countryIso3166Alpha2" => "GB",
        "addressLine1" => "Business Centre Road",
        "addressLine2" => "Unit 7",
        "zipCode" => "XX12 1XX",
        "city" => "TestCity",
        "phoneNumber1" => "+44 999 000000",
        "phoneNumber1Type" => "Fixed",
        "phoneNumber2" => "+44 888 123456",
        "phoneNumber2Type" => "Unknown",
        "organisation" => "Sample Business Ltd"
        ),
        "orderLines" => array(
        array(
            "lineNumber" => "1",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890123",
            "name" => "Bike",
            "quantity" => "1",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "121"
        ),
        array(
            "lineNumber" => "2",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890124",
            "name" => "Bike 2",
            "quantity" => "2",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "242"
        )
        )
    )
);

$options = array(
    'http' => array(
        'method' => 'POST',
        'header' => "Content-Type: application/json\r\n" .
        "Hash: YOUR_SIGNATURE_HASH\r\n" .
        "ConfigurationId: YOUR_CONFIGURATION_ID\r\n",
        'content' => json_encode($data)
    )
);

$context = stream_context_create($options); $response = file_get_contents($url, false, $context); echo $response; ?>
require 'net/http'
require 'uri'
require 'json'

uri = URI.parse("https://gateway-inta.cashflows.com/api/gateway/payment-jobs")
http = Net::HTTP.new(uri.host, uri.port)

data = {
    "amountToCollect" => "363",
    "currency" => "GBP",
    "order" => {
    "orderNumber" => "ORDER_NUMBER",
    "note" => "My order note",
    "billingAddress" => {
    "title" => "Mr.",
    "firstName" => "John",
    "lastName" => "Doe",
    "countryIso3166Alpha2" => "GB",
    "addressLine1" => "Addressline1",
    "addressLine2" => "Addressline2",
    "zipCode" => "XX21 5XX",
    "city" => "Cambridge",
    "phoneNumber1" => "+44 999 000000",
    "phoneNumber1Type" => "Fixed",
    "phoneNumber2" => "+44 888 123456",
    "phoneNumber2Type" => "Unknown",
    "organisation" => "TestCompany"
    },
    "billingIdentity" => {
    "emailAddress" => "sales@example.com",
    "gender" => "Female",
    "dateOfBirth" => "2010-03-17T00:00:00Z"
    },
    "shippingAddress" => {
    "title" => "Mr.",
    "firstName" => "John",
    "middleName" => "Van",
    "lastName" => "Dijk",
    "countryIso3166Alpha2" => "GB",
    "addressLine1" => "Business Centre Road",
    "addressLine2" => "Unit 7",
    "zipCode" => "XX12 1XX",
    "city" => "TestCity",
    "phoneNumber1" => "+44 999 000000",
    "phoneNumber1Type" => "Fixed",
    "phoneNumber2" => "+44 888 123456",
    "phoneNumber2Type" => "Unknown",
    "organisation" => "Sample Business Ltd"
    },
    "orderLines" => [
        {
            "lineNumber" => "1",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890123",
            "name" => "Bike",
            "quantity" => "1",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "121"
        },
        {
            "lineNumber" => "2",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890124",
            "name" => "Bike 2",
            "quantity" => "2",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "242"
        }
        ]
    }
}

request = Net::HTTP::Post.new(uri.path, {
'Content-Type' => 'application/json',
'Hash' => 'YOUR_SIGNATURE_HASH',
'ConfigurationId' => 'YOUR_CONFIGURATION_ID'
})
request.body = data.to_json

response = http.request(request)
puts response.body
Click to show a new payment job for card payments
import requests
import json

url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs'

data = {
"amountToCollect": "10",
"currency": "GBP",
"paymentMethodsToUse": ["card"]
}

headers = {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
}

response = requests.post(url, headers=headers, data=json.dumps(data))

print(response.text)
import java.io.OutputStream;
import java.net.HttpURLConnection;
import java.net.URL;

public class PaymentJobRequest {
    public static void main(String[] args) throws Exception {
        url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";
        URL obj = new URL(url);
        HttpURLConnection con = (HttpURLConnection) obj.openConnection();

        con.setRequestMethod("POST");
        con.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        con.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        con.setRequestProperty("Content-Type", "application/json");
        con.setDoOutput(true);

        String jsonData = "{ "amountToCollect": "10", "currency": "GBP", "paymentMethodsToUse": ["card"] }";
        try (OutputStream os = con.getOutputStream()) {
        byte[] input = jsonData.getBytes("utf-8");
        os.write(input, 0, input.length);
        }

        int responseCode = con.getResponseCode();
        System.out.println("Response Code: " + responseCode);
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        using (HttpClient client = new HttpClient())
        {
        var data = new
        {
            amountToCollect = "10",
            currency = "GBP",
            paymentMethodsToUse = new[] { "card" }
        };

        var jsonData = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(jsonData, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        HttpResponseMessage response = await client.PostAsync("https://gateway-inta.cashflows.com/api/gateway/payment-jobs", content);
        string responseBody = await response.Content.ReadAsStringAsync();

        Console.WriteLine(responseBody);
        }
    }
}
const axios = require('axios');
let data = JSON.stringify({
"amountToCollect": "10",
"currency": "GBP",
"paymentMethodsToUse": [
    "card"
]
});

let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
headers: {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
},
data : data
};

axios.request(config)
.then((response) => {
    console.log(JSON.stringify(response.data));
})
.catch((error) => {
    console.log(error);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = array(
    'amountToCollect' => '10',
    'currency' => 'GBP',
    'paymentMethodsToUse' => array('card')
);
$data_json = json_encode($data);

$headers = array(
    'Hash: YOUR_SIGNATURE_HASH',
    'ConfigurationId: YOUR_CONFIGURATION_ID',
    'Content-Type: application/json'
);

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data_json);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'json'
require 'uri'

uri = URI('https://gateway-inta.cashflows.com/api/gateway/payment-jobs')

header = {
    'Content-Type' => 'application/json',
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID'
}

data = {
    "amountToCollect" => "10",
    "currency" => "GBP",
    "paymentMethodsToUse" => ["card"]
}

http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.path, header)
request.body = data.to_json

response = http.request(request)
puts response.body
Click to show a new payment job with token generation
import requests
import json

url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs"
headers = {
    "Content-Type": "application/json",
    "Hash": "YOUR_SIGNATURE_HASH",
    "ConfigurationId": "YOUR_CONFIGURATION_ID"
}

data = {
    "amountToCollect": "363",
    "currency": "GBP",
    "options": ["StoreCustomerInformation", "GenerateToken"],
    "order": {
        "orderNumber": "ORDER_NUMBER",
        "note": "My order note",
        "billingAddress": {
        "title": "Mr.",
        "firstName": "John",
        "lastName": "Doe",
        "countryIso3166Alpha2": "GB",
        "addressLine1": "Addressline1",
        "addressLine2": "Addressline2",
        "zipCode": "XX21 5XX",
        "city": "Cambridge",
        "phoneNumber1": "+44 999 000000",
        "phoneNumber1Type": "Fixed",
        "phoneNumber2": "+44 888 123456",
        "phoneNumber2Type": "Unknown",
        "organisation": "TestCompany"
        },
        "billingIdentity": {
        "emailAddress": "sales@example.com",
        "gender": "Female",
        "dateOfBirth": "2010-03-17T00:00:00Z"
        },
        "shippingAddress": {
        "title": "Mr.",
        "firstName": "John",
        "middleName": "Van",
        "lastName": "Dijk",
        "countryIso3166Alpha2": "GB",
        "addressLine1": "Business Centre Road",
        "addressLine2": "Unit 7",
        "zipCode": "XX12 1XX",
        "city": "TestCity",
        "phoneNumber1": "+44 999 123456",
        "phoneNumber1Type": "Fixed",
        "phoneNumber2": "+44 888 123456",
        "phoneNumber2Type": "Unknown",
        "organisation": "Sample Business Ltd"     },
        "orderLines": [
        {
            "lineNumber": "1",
            "type": "PhysicalItem",
            "skuCode": "1234567890123",
            "name": "Bike",
            "quantity": "1",
            "unitPriceExclVat": "100",
            "unitPriceInclVat": "121",
            "vatPercentage": "21",
            "vatPercentageLabel": "Vat 21%",
            "discountPercentageLabel": "discount 6%",
            "totalLineAmount": "121"
        },
        {
            "lineNumber": "2",
            "type": "PhysicalItem",
            "skuCode": "1234567890124",
            "name": "Bike 2",
            "quantity": "2",
            "unitPriceExclVat": "100",
            "unitPriceInclVat": "121",
            "vatPercentage": "21",
            "vatPercentageLabel": "Vat 21%",
            "discountPercentageLabel": "discount 6%",
            "totalLineAmount": "242"
        }
        ]
    }
}

response = requests.post(url, headers=headers, data=json.dumps(data))
print(response.text)
import java.io.*; import java.net.*; import javax.net.ssl.HttpsURLConnection;

public class Main {
    public static void main(String[] args) throws Exception {
        URL url = new URL("https://gateway-inta.cashflows.com/api/gateway/payment-jobs");
        HttpsURLConnection connection = (HttpsURLConnection) url.openConnection();

        connection.setRequestMethod("POST");
        connection.setRequestProperty("Content-Type", "application/json");
        connection.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        connection.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        connection.setDoOutput(true);

        String jsonInputString = "{\n" +
        "  "amountToCollect": "363",\n" +
        "  "currency": "GBP",\n" +
        "  "options": ["StoreCustomerInformation", "GenerateToken"],\n" +
        "  "order": {\n" +
        "    "orderNumber": "ORDER_NUMBER",\n" +
        "    "note": "My order note",\n" +
        "    "billingAddress": {\n" +
        "      "title": "Mr.",\n" +
        "      "firstName": "John",\n" +
        "      "lastName": "Doe",\n" +
        "      "countryIso3166Alpha2": "GB",\n" +
        "      "addressLine1": "Addressline1",\n" +
        "      "addressLine2": "Addressline2",\n" +
        "      "zipCode": "XX21 5XX",\n" +
        "      "city": "Cambridge",\n" +
        "      "phoneNumber1": "+44 999 000000",\n" +
        "      "phoneNumber1Type": "Fixed",\n" +
        "      "phoneNumber2": "+44 888 123456",\n" +
        "      "phoneNumber2Type": "Unknown",\n" +
        "      "organisation": "TestCompany"\n" +
        "    },\n" +
        "    "billingIdentity": {\n" +
        "      "emailAddress": "sales@example.com",\n" +
        "      "gender": "Female",\n" +
        "      "dateOfBirth": "2010-03-17T00:00:00Z"\n" +
        "    },\n" +
        "    "shippingAddress": {\n" +
        "      "title": "Mr.",\n" +
        "      "firstName": "John",\n" +
        "      "middleName": "Van",\n" +
        "      "lastName": "Dijk",\n" +
        "      "countryIso3166Alpha2": "GB",\n" +
        "      "addressLine1": "Business Centre Road",\n" +
        "      "addressLine2": "Unit 7",\n" +
        "      "zipCode": "XX12 1XX",\n" +
        "      "city": "TestCity",\n" +
        "      "phoneNumber1": "+44 999 123456",\n" +
        "      "phoneNumber1Type": "Fixed",\n" +
        "      "phoneNumber2": "+44 888 123456",\n" +
        "      "phoneNumber2Type": "Unknown",\n" +
        "      "organisation": "Sample Business Ltd"\n" +
        "    },\n" +
        "    "orderLines": [\n" +
        "      {\n" +
        "        "lineNumber": "1",\n" +
        "        "type": "PhysicalItem",\n" +
        "        "skuCode": "1234567890123",\n" +
        "        "name": "Bike",\n" +
        "        "quantity": "1",\n" +
        "        "unitPriceExclVat": "100",\n" +
        "        "unitPriceInclVat": "121",\n" +
        "        "vatPercentage": "21",\n" +
        "        "vatPercentageLabel": "Vat 21%",\n" +
        "        "discountPercentageLabel": "discount 6%",\n" +
        "        "totalLineAmount": "121"\n" +
        "      },\n" +
        "      {\n" +
        "        "lineNumber": "2",\n" +
        "        "type": "PhysicalItem",\n" +
        "        "skuCode": "1234567890124",\n" +
        "        "name": "Bike 2",\n" +
        "        "quantity": "2",\n" +
        "        "unitPriceExclVat": "100",\n" +
        "        "unitPriceInclVat": "121",\n" +
        "        "vatPercentage": "21",\n" +
        "        "vatPercentageLabel": "Vat 21%",\n" +
        "        "discountPercentageLabel": "discount 6%",\n" +
        "        "totalLineAmount": "242"\n" +
        "      }\n" +
        "    ]\n" +
        "  }\n" +
        "}";

        try (OutputStream os = connection.getOutputStream()) {
        byte[] input = jsonInputString.getBytes("utf-8");
        os.write(input, 0, input.length);
        }

        try (BufferedReader br = new BufferedReader(new InputStreamReader(connection.getInputStream(), "utf-8"))) {
        StringBuilder response = new StringBuilder();
        String responseLine;
        while ((responseLine = br.readLine()) != null) {
            response.append(responseLine.trim());
        }
        System.out.println(response.toString());
        }
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main()
    {
        using (var client = new HttpClient())
        {
        var data = new
        {
            amountToCollect = "363",
            currency = "GBP",
            options = new[] { "StoreCustomerInformation", "GenerateToken" },
            order = new
            {
            orderNumber = "ORDER_NUMBER",
            note = "My order note",
            billingAddress = new
            {
                title = "Mr.",
                firstName = "John",
                lastName = "Doe",
                countryIso3166Alpha2 = "GB",
                addressLine1 = "Addressline1",
                addressLine2 = "Addressline2",
                zipCode = "XX21 5XX",
                city = "Cambridge",
                phoneNumber1 = "+44 999 000000",
                phoneNumber1Type = "Fixed",
                phoneNumber2 = "+44 888 123456",
                phoneNumber2Type = "Unknown",
                organisation = "TestCompany"
            },
            billingIdentity = new
            {
                emailAddress = "sales@example.com",
                gender = "Female",
                dateOfBirth = "2010-03-17T00:00:00Z"
            },
            shippingAddress = new
            {
                title = "Mr.",
                firstName = "John",
                middleName = "Van",
                lastName = "Dijk",
                countryIso3166Alpha2 = "GB",
                addressLine1 = "Business Centre Road",
                addressLine2 = "Unit 7",
                zipCode = "XX12 1XX",
                city = "TestCity",
                phoneNumber1 = "+44 999 123456",
                phoneNumber1Type = "Fixed",
                phoneNumber2 = "+44 888 123456",
                phoneNumber2Type = "Unknown",
                organisation = "Sample Business Ltd"
            },
            orderLines = new[]
            {
                new
                {
                    lineNumber = "1",
                    type = "PhysicalItem",
                    skuCode = "1234567890123",
                    name = "Bike",
                    quantity = "1",
                    unitPriceExclVat = "100",
                    unitPriceInclVat = "121",
                    vatPercentage = "21",
                    vatPercentageLabel = "Vat 21%",
                    discountPercentageLabel = "discount 6%",
                    totalLineAmount = "121"
                    },
                    new
                    {
                    lineNumber = "2",
                    type = "PhysicalItem",
                    skuCode = "1234567890124",
                    name = "Bike 2",
                    quantity = "2",
                    unitPriceExclVat = "100",
                    unitPriceInclVat = "121",
                    vatPercentage = "21",
                    vatPercentageLabel = "Vat 21%",
                    discountPercentageLabel = "discount 6%",
                    totalLineAmount = "242"
                    }
                }
            }
        };

        var json = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(json, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        var response = await client.PostAsync("https://gateway-inta.cashflows.com/api/gateway/payment-jobs", content);
        var result = await response.Content.ReadAsStringAsync();
        Console.WriteLine(result);
        }
    }
}
const axios = require('axios');

let data = JSON.stringify({
"amountToCollect": "363",
"currency": "GBP",
"options": [
    "StoreCustomerInformation",
    "GenerateToken"
],
"order": {
    "orderNumber": "ORDER_NUMBER",
    "note": "My order note",
    "billingAddress": {
        "title": "Mr.",
        "firstName": "John",
        "lastName": "Doe",
        "countryIso3166Alpha2": "GB",
        "addressLine1": "Addressline1",
        "addressLine2": "Addressline2",
        "zipCode": "XX21 5XX",
        "city": "Cambridge",
        "phoneNumber1": "+44 999 000000",
        "phoneNumber1Type": "Fixed",
        "phoneNumber2": "+44 888 123456",
        "phoneNumber2Type": "Unknown",
        "organisation": "TestCompany"
        },
        "billingIdentity": {
            "emailAddress": "sales@example.com",
            "gender": "Female",
            "dateOfBirth": "2010-03-17T00:00:00Z"
        },
        "shippingAddress": {
            "title": "Mr.",
            "firstName": "John",
            "middleName": "Van",
            "lastName": "Dijk",
            "countryIso3166Alpha2": "GB",
            "addressLine1": "Business Centre Road",
            "addressLine2": "Unit 7",
            "zipCode": "XX12 1XX",
            "city": "TestCity",
            "phoneNumber1": "+44 999 123456",
            "phoneNumber1Type": "Fixed",
            "phoneNumber2": "+44 888 123456",
            "phoneNumber2Type": "Unknown",
            "organisation": "Sample Business Ltd"
        },
        "orderLines": [
        {
            "lineNumber": "1",
            "type": "PhysicalItem",
            "skuCode": "1234567890123",
            "name": "Bike",
            "quantity": "1",
            "unitPriceExclVat": "100",
            "unitPriceInclVat": "121",
            "vatPercentage": "21",
            "vatPercentageLabel": "Vat 21%",
            "discountPercentageLabel": "discount 6%",
            "totalLineAmount": "121"
        },
        {
            "lineNumber": "2",
            "type": "PhysicalItem",
            "skuCode": "1234567890124",
            "name": "Bike 2",
            "quantity": "2",
            "unitPriceExclVat": "100",
            "unitPriceInclVat": "121",
            "vatPercentage": "21",
            "vatPercentageLabel": "Vat 21%",
            "discountPercentageLabel": "discount 6%",
            "totalLineAmount": "242"
        }
        ]
    }
});

let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
headers: {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
},
    data : data
};

axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
<?php

$data = json_encode([
"amountToCollect" => "363",
"currency" => "GBP",
"options" => ["StoreCustomerInformation", "GenerateToken"],
"order" => [
    "orderNumber" => "ORDER_NUMBER",
    "note" => "My order note",
    "billingAddress" => [
        "title" => "Mr.",
        "firstName" => "John",
        "lastName" => "Doe",
        "countryIso3166Alpha2" => "GB",
        "addressLine1" => "Addressline1",
        "addressLine2" => "Addressline2",
        "zipCode" => "XX21 5XX",
        "city" => "Cambridge",
        "phoneNumber1" => "+44 999 000000",
        "phoneNumber1Type" => "Fixed",
        "phoneNumber2" => "+44 888 123456",
        "phoneNumber2Type" => "Unknown",
        "organisation" => "TestCompany"
    ],
    "billingIdentity" => [
        "emailAddress" => "sales@example.com",
        "gender" => "Female",
        "dateOfBirth" => "2010-03-17T00:00:00Z"
    ],
    "shippingAddress" => [
        "title" => "Mr.",
        "firstName" => "John",
        "middleName" => "Van",
        "lastName" => "Dijk",
        "countryIso3166Alpha2" => "GB",
        "addressLine1" => "Business Centre Road",
        "addressLine2" => "Unit 7",
        "zipCode" => "XX12 1XX",
        "city" => "TestCity",
        "phoneNumber1" => "+44 999 123456",
        "phoneNumber1Type" => "Fixed",
        "phoneNumber2" => "+44 888 123456",
        "phoneNumber2Type" => "Unknown",
        "organisation" => "Sample Business Ltd"
        ],
    "orderLines" => [
        [
            "lineNumber" => "1",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890123",
            "name" => "Bike",
            "quantity" => "1",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "121"
        ],
        [
            "lineNumber" => "2",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890124",
            "name" => "Bike 2",
            "quantity" => "2",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "242"
        ]
    ]
]
]);

$ch = curl_init('https://gateway-inta.cashflows.com/api/gateway/payment-jobs');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'Content-Type: application/json',
    'Hash: YOUR_SIGNATURE_HASH',
    'ConfigurationId: YOUR_CONFIGURATION_ID'
]);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'json'
require 'uri'

uri = URI('https://gateway-inta.cashflows.com/api/gateway/payment-jobs')

header = {
    'Content-Type' => 'application/json',
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID'
}

data = {
    "amountToCollect" => "363",
    "currency" => "GBP",
    "options" => ["StoreCustomerInformation", "GenerateToken"],
    "order" => {
    "orderNumber" => "ORDER_NUMBER",
    "note" => "My order note",
    "billingAddress" => {
        "title" => "Mr.",
        "firstName" => "John",
        "lastName" => "Doe",
        "countryIso3166Alpha2" => "GB",
        "addressLine1" => "Addressline1",
        "addressLine2" => "Addressline2",
        "zipCode" => "XX21 5XX",
        "city" => "Cambridge",
        "phoneNumber1" => "+44 999 000000",
        "phoneNumber1Type" => "Fixed",
        "phoneNumber2" => "+44 888 123456",
        "phoneNumber2Type" => "Unknown",
        "organisation" => "TestCompany"
    },
    "billingIdentity" => {
        "emailAddress" => "sales@example.com",
        "gender" => "Female",
        "dateOfBirth" => "2010-03-17T00:00:00Z"
    },
    "shippingAddress" => {
        "title" => "Mr.",
        "firstName" => "John",
        "middleName" => "Van",
        "lastName" => "Dijk",
        "countryIso3166Alpha2" => "GB",
        "addressLine1" => "Business Centre Road",
        "addressLine2" => "Unit 7",
        "zipCode" => "XX12 1XX",
        "city" => "TestCity",
        "phoneNumber1" => "+44 999 123456",
        "phoneNumber1Type" => "Fixed",
        "phoneNumber2" => "+44 888 123456",
        "phoneNumber2Type" => "Unknown",
        "organisation" => "Sample Business Ltd"
    },
    "orderLines" => [
        {
            "lineNumber" => "1",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890123",
            "name" => "Bike",
            "quantity" => "1",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "121"
        },
        {
            "lineNumber" => "2",
            "type" => "PhysicalItem",
            "skuCode" => "1234567890124",
            "name" => "Bike 2",
            "quantity" => "2",
            "unitPriceExclVat" => "100",
            "unitPriceInclVat" => "121",
            "vatPercentage" => "21",
            "vatPercentageLabel" => "Vat 21%",
            "discountPercentageLabel" => "discount 6%",
            "totalLineAmount" => "242"
        }
    ]
    }
}

http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.path, header)
request.body = data.to_json

response = http.request(request)
puts response.body
Click to show a new ApplePay payment job
import requests
import json

url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs"
data = {
    "amountToCollect": "16",
    "currency": "GBP",
    "parameters": {
        "CardNumber": "4510400400099005",
        "CardHolderName": "Han Solo",
        "CardExpiryYear": "27",
        "CardExpiryMonth": "01",
        "CardCvc": "123",
        "ThreeDSecureVersion": "2.2.0",
        "ThreeDSecureCavv": "5dc4a6a39b6730a360e42c3b5f+=",
        "ThreeDSecureEci": "05",
        "ThreeDSecureDSTransId": "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
        "ReturnUrlCancelled": "https://example.com?result=canceled",
        "ReturnUrlFailed": "https://example.com?result=failed",
        "ReturnUrlSuccess": "https://example.com?result=success",
        "EWalletType": "1"
    },
    "payme  ntMethodsToUse": ["card"]
}

headers = {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
}

response = requests.post(url, headers=headers, json=data)
print(response.text)
import java.io.OutputStream;
import java.net.HttpURLConnection;
import java.net.URL;

public class Main {
    public static void main(String[] args) {
        try {
        URL url = new URL("https://gateway-inta.cashflows.com/api/gateway/payment-jobs");
        HttpURLConnection connection = (HttpURLConnection) url.openConnection();
        connection.setRequestMethod("POST");
        connection.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        connection.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        connection.setRequestProperty("Content-Type", "application/json");
        connection.setDoOutput(true);

        String data = "{\n" +
            ""amountToCollect": "16",\n" +
            ""currency": "GBP",\n" +
            ""parameters": {\n" +
            ""CardNumber": "4510400400099005",\n" +
            ""CardHolderName": "Han Solo",\n" +
            ""CardExpiryYear": "27",\n" +
            ""CardExpiryMonth": "01",\n" +
            ""CardCvc": "123",\n" +
            ""ThreeDSecureVersion": "2.2.0",\n" +
            ""ThreeDSecureCavv": "5dc4a6a39b6730a360e42c3b5f+=",\n" +
            ""ThreeDSecureEci": "05",\n" +
            ""ThreeDSecureDSTransId": "c5b808e7-1de1-4069-a17b-f70d3b3b1645",\n" +
            ""ReturnUrlCancelled": "https://example.com?result=canceled",\n" +
            ""ReturnUrlFailed": "https://example.com?result=failed",\n" +
            ""ReturnUrlSuccess": "https://example.com?result=success",\n" +
            ""EWalletType": "1"\n" +
            "},\n" +
            ""paymentMethodsToUse": [\n" +
            ""card"\n" +
            "]\n" +
            "}";

        try (OutputStream os = connection.getOutputStream()) {
            byte[] input = data.getBytes("utf-8");
            os.write(input, 0, input.length);
        }

        connection.getResponseCode();  // Make the request

        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main()
    {
        using (HttpClient client = new HttpClient())
        {
        var data = new
        {
            amountToCollect = "16",
            currency = "GBP",
            parameters = new
            {
            CardNumber = "4510400400099005",
            CardHolderName = "Han Solo",
            CardExpiryYear = "27",
            CardExpiryMonth = "01",
            CardCvc = "123",
            ThreeDSecureVersion = "2.2.0",
            ThreeDSecureCavv = "5dc4a6a39b6730a360e42c3b5f+=",
            ThreeDSecureEci = "05",
            ThreeDSecureDSTransId = "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
            ReturnUrlCancelled = "https://example.com?result=canceled",
            ReturnUrlFailed = "https://example.com?result=failed",
            ReturnUrlSuccess = "https://example.com?result=success",
            EWalletType = "1"
            },
            paymentMethodsToUse = new[] { "card" }
        };

        string json = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(json, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        HttpResponseMessage response = await client.PostAsync("https://gateway-inta.cashflows.com/api/gateway/payment-jobs", content);

        string responseData = await response.Content.ReadAsStringAsync();
        Console.WriteLine(responseData);

        }
    }
}
const axios = require('axios');
let data = JSON.stringify({
    "amountToCollect": "16",
    "currency": "GBP",
    "parameters": {
    "CardNumber": "4510400400099005",
    "CardHolderName": "Han Solo",
    "CardExpiryYear": "27",
    "CardExpiryMonth": "01",
    "CardCvc": "123",
    "ThreeDSecureVersion": "2.2.0",
    "ThreeDSecureCavv": "5dc4a6a39b6730a360e42c3b5f+=",
    "ThreeDSecureEci": "05",
    "ThreeDSecureDSTransId": "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
    "ReturnUrlCancelled": "https://example.com?result=canceled",
    "ReturnUrlFailed": "https://example.com?result=failed",
    "ReturnUrlSuccess": "https://example.com?result=success",
    "EWalletType": "1"
},
"paymentMethodsToUse": [
    "card"
]
});

let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
headers: {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
},
    data : data
};

axios.request(config)
.then((response) => {
    console.log(JSON.stringify(response.data));
})
.catch((error) => {
    console.log(error);
});
<?php
$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = [
    "amountToCollect" => "16",
    "currency" => "GBP",
    "parameters" => [
        "CardNumber" => "4510400400099005",
        "CardHolderName" => "Han Solo",
        "CardExpiryYear" => "27",
        "CardExpiryMonth" => "01",
        "CardCvc" => "123",
        "ThreeDSecureVersion" => "2.2.0",
        "ThreeDSecureCavv" => "5dc4a6a39b6730a360e42c3b5f+=",
        "ThreeDSecureEci" => "05",
        "ThreeDSecureDSTransId" => "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
        "ReturnUrlCancelled" => "https://example.com?result=canceled",
        "ReturnUrlFailed" => "https://example.com?result=failed",
        "ReturnUrlSuccess" => "https://example.com?result=success",
        "EWalletType" => "1"
    ],
    "paymentMethodsToUse" => ["card"]
];

$headers = [
'Hash: YOUR_SIGNATURE_HASH',
'ConfigurationId: YOUR_CONFIGURATION_ID',
'Content-Type: application/json'
];

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

uri = URI.parse("https://gateway-inta.cashflows.com/api/gateway/payment-jobs")
http = Net::HTTP.new(uri.host, uri.port)

request = Net::HTTP::Post.new(uri.path, {
    'Content-Type' => 'application/json',
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID'
})

data = {
    "amountToCollect" => "16",
    "currency" => "GBP",
    "parameters" => {
    "CardNumber" => "4510400400099005",
    "CardHolderName" => "Han Solo",
    "CardExpiryYear" => "27",
    "CardExpiryMonth" => "01",
    "CardCvc" => "123",
    "ThreeDSecureVersion" => "2.2.0",
    "ThreeDSecureCavv" => "5dc4a6a39b6730a360e42c3b5f+=",
    "ThreeDSecureEci" => "05",
    "ThreeDSecureDSTransId" => "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
    "ReturnUrlCancelled" => "https://example.com?result=canceled",
    "ReturnUrlFailed" => "https://example.com?result=failed",
    "ReturnUrlSuccess" => "https://example.com?result=success",
    "EWalletType" => "1"
},
"paymentMethodsToUse" => ["card"]
}

request.body = data.to_json

response = http.request(request)
puts response.body
Click to show a new GooglePay payment job
import requests
import json

url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs"
data = {
    "amountToCollect": "10",
    "currency": "GBP",
    "parameters": {
        "CardNumber": "4510400400099005",
        "CardHolderName": "Han Solo",
        "CardExpiryYear": "26",
        "CardExpiryMonth": "12",
        "CardCvc": "123",
        "ThreeDSecureVersion": "2.2.0",
        "ThreeDSecureCavv": "5dc4a6a39b6730a360e42c3b5f+=",
        "ThreeDSecureEci": "05",
        "ThreeDSecureDSTransId": "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
        "ReturnUrlCancelled": "https://example.com?result=canceled",
        "ReturnUrlFailed": "https://example.com?result=failed",
        "ReturnUrlSuccess": "https://example.com?result=success",
        "EWalletType": "2"
    },
    "paymentMethodsToUse": ["card"]
}

headers = {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
}

response = requests.post(url, headers=headers, json=data)
print(response.text)
import java.io.OutputStream;
import java.net.HttpURLConnection;
import java.net.URL;

public class Main {
    public static void main(String[] args) {
        try {
        URL url = new URL("https://gateway-inta.cashflows.com/api/gateway/payment-jobs");
        HttpURLConnection connection = (HttpURLConnection) url.openConnection();
        connection.setRequestMethod("POST");
        connection.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        connection.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        connection.setRequestProperty("Content-Type", "application/json");
        connection.setDoOutput(true);

        String data = "{\n" +
                    ""amountToCollect": "10",\n" +
            ""currency": "GBP",\n" +
            ""parameters": {\n" +
            ""CardNumber": "4510400400099005",\n" +
            ""CardHolderName": "Han Solo",\n" +
            ""CardExpiryYear": "26",\n" +
            ""CardExpiryMonth": "12",\n" +
            ""CardCvc": "123",\n" +
            ""ThreeDSecureVersion": "2.2.0",\n" +
            ""ThreeDSecureCavv": "5dc4a6a39b6730a360e42c3b5f+=",\n" +
            ""ThreeDSecureEci": "05",\n" +
            ""ThreeDSecureDSTransId": "c5b808e7-1de1-4069-a17b-f70d3b3b1645",\n" +
            ""ReturnUrlCancelled": "https://example.com?result=canceled",\n" +
            ""ReturnUrlFailed": "https://example.com?result=failed",\n" +
            ""ReturnUrlSuccess": "https://example.com?result=success",\n" +
            ""EWalletType": "2"\n" +
            "},\n" +
            ""paymentMethodsToUse": [\n" +
            ""card"\n" +
            "]\n" +
            "}";

        try (OutputStream os = connection.getOutputStream()) {
            byte[] input = data.getBytes("utf-8");
            os.write(input, 0, input.length);
        }

        connection.getResponseCode();  // Make the request

        } catch (Exception e) {
        e.printStackTrace();
        }
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main()
    {
        using (HttpClient client = new HttpClient())
        {
        var data = new
            {
            amountToCollect = "10",
            currency = "GBP",
            parameters = new
            {
            CardNumber = "4510400400099005",
            CardHolderName = "Han Solo",
            CardExpiryYear = "26",
            CardExpiryMonth = "12",
            CardCvc = "123",
            ThreeDSecureVersion = "2.2.0",
            ThreeDSecureCavv = "5dc4a6a39b6730a360e42c3b5f+=",
            ThreeDSecureEci = "05",
            ThreeDSecureDSTransId = "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
            ReturnUrlCancelled = "https://example.com?result=canceled",
            ReturnUrlFailed = "https://example.com?result=failed",
            ReturnUrlSuccess = "https://example.com?result=success",
            EWalletType = "2"
            },
            paymentMethodsToUse = new[] { "card" }
        };

        string json = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(json, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        HttpResponseMessage response = await client.PostAsync("https://gateway-inta.cashflows.com/api/gateway/payment-jobs", content);

        string responseData = await response.Content.ReadAsStringAsync();
        Console.WriteLine(responseData);
        }
    }
}
const axios = require('axios');
let data = JSON.stringify({
    "amountToCollect": "10",
    "currency": "GBP",
    "parameters": {
    "CardNumber": "4510400400099005",
    "CardHolderName": "Han Solo",
    "CardExpiryYear": "26",
    "CardExpiryMonth": "12",
    "CardCvc": "123",
    "ThreeDSecureVersion": "2.2.0",
    "ThreeDSecureCavv": "5dc4a6a39b6730a360e42c3b5f+=",
    "ThreeDSecureEci": "05",
    "ThreeDSecureDSTransId": "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
    "ReturnUrlCancelled": "https://example.com?result=canceled",
    "ReturnUrlFailed": "https://example.com?result=failed",
    "ReturnUrlSuccess": "https://example.com?result=success",
    "EWalletType": "2"
    },
    "paymentMethodsToUse": [
        "card"
    ]
});

let config = {
    method: 'post',
    maxBodyLength: Infinity,
    url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
    headers: {
        'Hash': 'YOUR_SIGNATURE_HASH',
        'ConfigurationId': 'YOUR_CONFIGURATION_ID',
        'Content-Type': 'application/json'
    },
    data : data
};

axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
    console.log(error);
});
<?php
$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = [
    "amountToCollect" => "10",
    "currency" => "GBP",
    "parameters" => [
        "CardNumber" => "4510400400099005",
        "CardHolderName" => "Han Solo",
        "CardExpiryYear" => "26",
        "CardExpiryMonth" => "12",
        "CardCvc" => "123",
        "ThreeDSecureVersion" => "2.2.0",
        "ThreeDSecureCavv" => "5dc4a6a39b6730a360e42c3b5f+=",
        "ThreeDSecureEci" => "05",
        "ThreeDSecureDSTransId" => "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
        "ReturnUrlCancelled" => "https://example.com?result=canceled",
        "ReturnUrlFailed" => "https://example.com?result=failed",
        "ReturnUrlSuccess" => "https://example.com?result=success",
        "EWalletType" => "2"
    ],
    "paymentMethodsToUse" => ["card"]
];

$headers = [
    'Hash: YOUR_SIGNATURE_HASH',
    'ConfigurationId: YOUR_CONFIGURATION_ID',
    'Content-Type: application/json'
];

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

uri = URI.parse("https://gateway-inta.cashflows.com/api/gateway/payment-jobs")
http = Net::HTTP.new(uri.host, uri.port)

request = Net::HTTP::Post.new(uri.path, {
    'Content-Type' => 'application/json',
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID'
})

data = {
    "amountToCollect" => "10",
    "currency" => "GBP",
    "parameters" => {
        "CardNumber" => "4510400400099005",
        "CardHolderName" => "Han Solo",
        "CardExpiryYear" => "26",
        "CardExpiryMonth" => "12",
        "CardCvc" => "123",
        "ThreeDSecureVersion" => "2.2.0",
        "ThreeDSecureCavv" => "5dc4a6a39b6730a360e42c3b5f+=",
        "ThreeDSecureEci" => "05",
        "ThreeDSecureDSTransId" => "c5b808e7-1de1-4069-a17b-f70d3b3b1645",
        "ReturnUrlCancelled" => "https://example.com?result=canceled",
        "ReturnUrlFailed" => "https://example.com?result=failed",
        "ReturnUrlSuccess" => "https://example.com?result=success",
        "EWalletType" => "2"
    },
    "paymentMethodsToUse" => ["card"]
}

request.body = data.to_json

response = http.request(request)
puts response.body
Click to show a recurring payment
import requests import json

url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs'
data = {
    'amountToCollect': '10',
    'currency': 'GBP',
    'options': ['IsRecurringPaymentJobParent'],
    'paymentMethodsToUse': ['card'],
    'recurrenceCriteria': {
        'recurrenceType': 'Subscription',
        'recurringExpiry': '2022-02-16T13:07:33.92Z',
        'recurringFrequency': '28'
    }
}

headers = {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
import java.io.*;
import java.net.*;
import javax.net.ssl.HttpsURLConnection;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";
        String data = "{\n" +
        "\"amountToCollect\": \"10\",\n" +
        "\"currency\": \"GBP\",\n" +
        "\"options\": [\"IsRecurringPaymentJobParent\"],\n" +
        "\"paymentMethodsToUse\": [\"card\"],\n" +
        "\"recurrenceCriteria\": {\n" +
        "\"recurrenceType\": \"Subscription\",\n" +
        "\"recurringExpiry\": \"2022-02-16T13:07:33.92Z\",\n" +
        "\"recurringFrequency\": \"28\"\n" +
        "}\n" +
        "}";

        URL obj = new URL(url);
        HttpsURLConnection con = (HttpsURLConnection) obj.openConnection();

        con.setRequestMethod("POST");
        con.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        con.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        con.setRequestProperty("Content-Type", "application/json");
        con.setDoOutput(true);

        try (OutputStream os = con.getOutputStream()) {
        byte[] input = data.getBytes("utf-8");
        os.write(input, 0, input.length);
        }

        int responseCode = con.getResponseCode();
        System.out.println("Response Code: " + responseCode);

        BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));
        String inputLine;
        StringBuilder response = new StringBuilder();

        while ((inputLine = in.readLine()) != null) {
        response.append(inputLine);
        }
        in.close();

        System.out.println(response.toString());
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var client = new HttpClient();
        var url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";

        var data = new
        {
            amountToCollect = "10",
            currency = "GBP",
            options = new string[] { "IsRecurringPaymentJobParent" },
            paymentMethodsToUse = new string[] { "card" },
            recurrenceCriteria = new
            {
                recurrenceType = "Subscription",
                recurringExpiry = "2022-02-16T13:07:33.92Z",
                recurringFrequency = "28"
            }
        };

        var jsonData = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(jsonData, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID"

        var response = await client.PostAsync(url, content);
        var responseString = await response.Content.ReadAsStringAsync();

        Console.WriteLine(responseString);
    }
}
const axios = require('axios');
let data = JSON.stringify({
    'amountToCollect': '10',
    'currency': 'GBP',
    'options': [
        'IsRecurringPaymentJobParent'
    ],
    'paymentMethodsToUse': [
        'card'
    ],
    'recurrenceCriteria': {
        'recurrenceType': 'Subscription',
        'recurringExpiry': '2022-02-16T13:07:33.92Z',
        'recurringFrequency': '28'
    }
});

let config = {
    method: 'post',
    maxBodyLength: Infinity,
    url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
    headers: {
        'Hash': 'YOUR_SIGNATURE_HASH',
        'ConfigurationId': 'YOUR_CONFIGURATION_ID',
        'Content-Type': 'application/json'
    },
    data : data
};

axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
<?php
$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = json_encode([
    'amountToCollect' => '10',
    'currency' => 'GBP',
    'options' => ['IsRecurringPaymentJobParent'],
    'paymentMethodsToUse' => ['card'],
    'recurrenceCriteria' => [
        'recurrenceType' => 'Subscription',
        'recurringExpiry' => '2022-02-16T13:07:33.92Z',
        'recurringFrequency' => '28'
    ]
]);

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'Hash: YOUR_SIGNATURE_HASH',
    'ConfigurationId: YOUR_CONFIGURATION_ID',
    'Content-Type: application/json'
]);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

url = URI.parse('https://gateway-inta.cashflows.com/api/gateway/payment-jobs')
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url.path,
{
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
    'Content-Type' => 'application/json'
})
request.body = {
    'amountToCollect' => '10',
    'currency' => 'GBP',
    'options' => ['IsRecurringPaymentJobParent'],
    'paymentMethodsToUse' => ['card'],
    'recurrenceCriteria' => {
        'recurrenceType' => 'Subscription',
        'recurringExpiry' => '2022-02-16T13:07:33.92Z',
        'recurringFrequency' => '28'
    }
}.to_json

response = http.request(request)
puts response.body
Click to show a recurring payment on a parent payment
import requests
import json

url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs'
data = {
    'amountToCollect': '10',
    'currency': 'GBP',
    'parentPaymentJobReference': 'PARENT_PAYMENT_JOB_REFERENCE'
}

headers = {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
import java.io.*;
import java.net.*;
import javax.net.ssl.HttpsURLConnection;

public class Main {
public static void main(String[] args) throws Exception {
    String url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";
    String data = "{\n" +
        "\"amountToCollect\": \"10\",\n" +
        "\"currency\": \"GBP\",\n" +
        "\"parentPaymentJobReference\": \"PARENT_PAYMENT_JOB_REFERENCE\"\n" +
    "}";

    URL obj = new URL(url);
    HttpsURLConnection con = (HttpsURLConnection) obj.openConnection();

    con.setRequestMethod("POST");
    con.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
    con.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
    con.setRequestProperty("Content-Type", "application/json");
    con.setDoOutput(true);

    try (OutputStream os = con.getOutputStream()) {
        byte[] input = data.getBytes("utf-8");
        os.write(input, 0, input.length);
    }

    int responseCode = con.getResponseCode();
    System.out.println("Response Code: " + responseCode);

    BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));
    String inputLine;
    StringBuilder response = new StringBuilder();

    while ((inputLine = in.readLine()) != null) {
        response.append(inputLine);
    }
    in.close();

    System.out.println(response.toString());
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var client = new HttpClient();
        var url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";

        var data = new
        {
        amountToCollect = "10",
        currency = "GBP",
        parentPaymentJobReference = "PARENT_PAYMENT_JOB_REFERENCE"
        };

        var jsonData = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(jsonData, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        var response = await client.PostAsync(url, content);
        var responseString = await response.Content.ReadAsStringAsync();

        Console.WriteLine(responseString);
    }
}
const axios = require('axios');

let data = JSON.stringify({
    'amountToCollect': '10',
    'currency': 'GBP',
    'parentPaymentJobReference': 'PARENT_PAYMENT_JOB_REFERENCE'
});

let config = {
    method: 'post',
    maxBodyLength: Infinity,
    url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
    headers: {
        'Hash': 'YOUR_SIGNATURE_HASH',
        'ConfigurationId': 'YOUR_CONFIGURATION_ID',
        'Content-Type': 'application/json'
    },
    data : data
};

axios.request(config)
.then((response) => {
    console.log(JSON.stringify(response.data));
})
.catch((error) => {
    console.log(error);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = json_encode([
    'amountToCollect' => '10',
    'currency' => 'GBP',
    'parentPaymentJobReference' => 'PARENT_PAYMENT_JOB_REFERENCE'
]);

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'Hash: YOUR_SIGNATURE_HASH',
    'ConfigurationId: YOUR_CONFIGURATION_ID',
    'Content-Type: application/json'
]);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

url = URI.parse('https://gateway-inta.cashflows.com/api/gateway/payment-jobs')
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url.path,
{
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
    'Content-Type' => 'application/json'
})
request.body = {
    'amountToCollect' => '10',
    'currency' => 'GBP',
    'parentPaymentJobReference' => 'PARENT_PAYMENT_JOB_REFERENCE'
}.to_json

response = http.request(request)
puts response.body

Retrieves a payment job

To retrieve a specific payment job add the paymentJobReference to the end of a GET request.

Click to show a recurring payment on a parent payment
import requests

url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250221021651001344'
headers = {
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Hash': 'YOUR_SIGNATURE_HASH'
}

response = requests.get(url, headers=headers)

if response.status_code == 200:
print(response.json())
else:
print(f"Request failed with status code {response.status_code}")
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250221021651001344";

        HttpClient client = HttpClient.newHttpClient();

        HttpRequest request = HttpRequest.newBuilder()
        .uri(URI.create(url))
        .header("ConfigurationId", "YOUR_CONFIGURATION_ID")
        .header("Hash", "YOUR_SIGNATURE_HASH")
        .GET()
        .build();

        HttpResponse response = client.send(request, HttpResponse.BodyHandlers.ofString());

        if (response.statusCode() == 200) {
        System.out.println(response.body());
        } else {
        System.out.println("Request failed with status code " + response.statusCode());
        }
    }
}
using System;
using System.Net.Http;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250221021651001344";

        var client = new HttpClient();
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");
        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");

        var response = await client.GetAsync(url);

        if (response.IsSuccessStatusCode)
        {
            string responseData = await response.Content.ReadAsStringAsync();
            Console.WriteLine(responseData);
        }
        else
        {
          Console.WriteLine($"Request failed with status code {response.StatusCode}");
        }
    }
}
const axios = require('axios');
 let data = '';

 let config = {
     method: 'get',
     maxBodyLength: Infinity,
     url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250221021651001344',
     headers: {
         'ConfigurationId': 'YOUR_CONFIGURATION_ID',
         'Hash': 'YOUR_SIGNATURE_HASH'
     },
     data: data
 };

 axios.request(config)
 .then((response) => {
    console.log(JSON.stringify(response.data));
 })
 .catch((error) => {
     console.log(error);
 });
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250221021651001344';
$headers = [
    'ConfigurationId: YOUR_CONFIGURATION_ID',
    'Hash: YOUR_SIGNATURE_HASH'
];

$ch = curl_init($url);

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');

$response = curl_exec($ch);

if (curl_errno($ch)) {
 echo 'Error:' . curl_error($ch);
} else {
  echo $response;
}

curl_close($ch);

?>
require 'net/http'
require 'uri'
require 'json'

uri = URI('https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250221021651001344')

# Set headers
headers = {
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
    'Hash' => 'YOUR_SIGNATURE_HASH'
}

# Make GET request
http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Get.new(uri.path, headers)

response = http.request(request)

if response.code.to_i == 200
puts JSON.parse(response.body)
else
puts "Request failed with status code #{response.code}"
end

Cancel a payment job

To cancel a specific payment job add {paymentJobReference}/cancel to the end of a PATCH request.

Click to show a recurring payment on a parent payment
import requests
import json

url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250321000184549388/cancel'
data = {
    "amountToCollect": "10",
    "currency": "GBP"
}

headers = {
    'Hash': 'YOUR_SIGNATURE_HASH',
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Content-Type': 'application/json'
}

response = requests.patch(url, json=data, headers=headers)
print(response.json())
import java.io.*;
import java.net.*;
import javax.net.ssl.HttpsURLConnection;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs";
        String data = "{\n" +
        "\"amountToCollect\": \"10\",\n" +
        "\"currency\": \"GBP\",\n" +
        "\"parentPaymentJobReference\": \"PARENT_PAYMENT_JOB_REFERENCE\"\n" +
        "}";

        URL obj = new URL(url);
        HttpsURLConnection con = (HttpsURLConnection) obj.openConnection();

        con.setRequestMethod("POST");
        con.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        con.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        con.setRequestProperty("Content-Type", "application/json");
        con.setDoOutput(true);

        try (OutputStream os = con.getOutputStream()) {
            byte[] input = data.getBytes("utf-8");
            os.write(input, 0, input.length);
        }

        int responseCode = con.getResponseCode();
        System.out.println("Response Code: " + responseCode);

        BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));
        String inputLine;
        StringBuilder response = new StringBuilder();

        while ((inputLine = in.readLine()) != null) {
        response.append(inputLine);
    }
    in.close();

    System.out.println(response.toString());
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var client = new HttpClient();     var url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250321000184549388/cancel";

        var data = new
        {
        amountToCollect = "10",
        currency = "GBP"
        };

        var jsonData = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(jsonData, Encoding.UTF8, "application/json");

        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        var response = await client.PatchAsync(url, content);
        var responseString = await response.Content.ReadAsStringAsync();

        Console.WriteLine(responseString);
    }
}
const axios = require('axios');

let data = JSON.stringify({
    "amountToCollect": "10",
    "currency": "GBP"
});

let config = {
    method: 'patch',
    maxBodyLength: Infinity,
    url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250321000184549388/cancel',
    headers: {
        'Hash': 'YOUR_SIGNATURE_HASH',
        'ConfigurationId': 'YOUR_CONFIGURATION_ID',
        'Content-Type': 'application/json'
    },
    data : data
};

axios.request(config)
.then((response) => {
 console.log(JSON.stringify(response.data));
})
    .catch((error) => {
    console.log(error);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250321000184549388/cancel';
$data = json_encode([
    'amountToCollect' => '10',
    'currency' => 'GBP'
]);

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PATCH');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'Hash: YOUR_SIGNATURE_HASH',
'ConfigurationId: YOUR_CONFIGURATION_ID',
'Content-Type: application/json'
]);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

url = URI.parse('https://gateway-inta.cashflows.com/api/gateway/payment-jobs/250321000184549388/cancel')
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url.path,
{
    'Hash' => 'YOUR_SIGNATURE_HASH',
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
    'Content-Type' => 'application/json'
}) request.body = {
    "amountToCollect" => "10",
    "currency" => "GBP"
}.to_json

response = http.request(request)
puts response.body

Retrieve a payment

To retrieve a specific payment add {paymentJobReference}/payments/{paymentReference} to the end of a GET request.

Cancel a payment

To cancel a specific payment add {paymentJobReference}/payments/{paymentReference}/cancel to the end of a PATCH request.

Capture a payment

To capture a specific payment add {paymentJobReference}/payments/{paymentReference}/captures to the end of a PATCH request.

Refund a payment

To refund a specific payment add {paymentJobReference}/payments/{paymentReference}/refunds to the end of a PATCH request.

CardTokenisations

Parameter

Description

Mandatory/Optional

locale

Valid values: nl_NL en_US en_GB es_ES el_GR

Optional

cardNumber

The card number to be tokenised.

Mandatory

cardHolderName

Cardholder’s Name

Mandatory

cardExpiryYear

Year in 2 digit format YY.

Mandatory

cardExpiryMonth

Month in format MM {01-12}.

Mandatory

cardCvc

Security code of the card.

Mandatory

CardTokenisation examples

Click to show a new card tokenisation
import requests
import json

url = 'https://gateway-int.cashflows.com/api/gateway/card-tokenisation'

payload = json.dumps({
'cardNumber': '4000000000000002',
'cardHolderName': 'J. Snow',
'cardExpiryYear': '22',
'cardExpiryMonth': '12',
'cardCvc': '123'
})

headers = {
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Hash': 'YOUR_SIGNATURE_HASH',
'Content-Type': 'application/json'
}

response = requests.post(url, headers=headers, json=data)

if response.status_code == 200:
print(response.json())
else:
print(f"Request failed with status code {response.status_code}")
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.nio.charset.StandardCharsets;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://gateway-inta.cashflows.com/api/gateway/card-tokenisation";

        String json = "{"cardNumber": "4000000000000002", "cardHolderName": "J. Snow", "cardExpiryYear": "26", "cardExpiryMonth": "12", "cardCvc": "123"}";

        HttpClient client = HttpClient.newHttpClient();

        HttpRequest request = HttpRequest.newBuilder()
        .uri(URI.create(url))
        .header("ConfigurationId", "YOUR_CONFIGURATION_ID")
        .header("Hash", "YOUR_SIGNATURE_HASH")
        .header("Content-Type", "application/json")
        .POST(HttpRequest.BodyPublishers.ofString(json, StandardCharsets.UTF_8))
        .build();

        HttpResponse response = client.send(request, HttpResponse.BodyHandlers.ofString());

        if (response.statusCode() == 200) {
        System.out.println(response.body());
        } else {
        System.out.println("Request failed with status code " + response.statusCode());
        }
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var url = "https://gateway-inta.cashflows.com/api/gateway/card-tokenisation";

        var data = "{"cardNumber": "4000000000000002", "cardHolderName": "J. Snow", "cardExpiryYear": "26", "cardExpiryMonth": "12", "cardCvc": "123"}";

        var client = new HttpClient();

        // Set headers
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");
        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");

        // Send the POST request with JSON payload
        var content = new StringContent(data, Encoding.UTF8, "application/json");

        var response = await client.PostAsync(url, content);

        if (response.IsSuccessStatusCode)
        {
            string responseData = await response.Content.ReadAsStringAsync();
            Console.WriteLine(responseData);
        }
        else
        {
            Console.WriteLine($"Request failed with status code {response.StatusCode}");
        }
    }
}
const axios = require('axios');
let data = JSON.stringify({
"cardNumber": "4000000000000002",
"cardHolderName": "J. Snow",
"cardExpiryYear": "26",
"cardExpiryMonth": "12",
"cardCvc": "123"
});

let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://gateway-inta.cashflows.com/api/gateway/card-tokenisation',
headers: {
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Hash': 'YOUR_SIGNATURE_HASH',
&  nbsp; 'Content-Type': 'application/json'
},
data: data
};

axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/card-tokenisation';

$data = json_encode([
"cardNumber" => "4000000000000002",
"cardHolderName" => "J. Snow",
"cardExpiryYear" => "26",
"cardExpiryMonth" => "12",
"cardCvc" => "123"
]);

$headers = [
'ConfigurationId: YOUR_CONFIGURATION_ID',
'Hash: YOUR_SIGNATURE_HASH',
'Content-Type: application/json'
];

$ch = curl_init($url);

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);

$response = curl_exec($ch);

if(curl_errno($ch)) {
echo 'Error:' . curl_error($ch);
} else {
echo $response;
}

curl_close($ch);

?>
require 'net/http'

require 'uri'
require 'json'

uri = URI('https://gateway-inta.cashflows.com/api/gateway/card-tokenisation')

# Set headers
headers = {
'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
'Hash' => 'YOUR_SIGNATURE_HASH',
'Content-Type' => 'application/json'
}

# Data to send in POST request
data = {
'cardNumber' => '4000000000000002',
'cardHolderName' => 'J. Snow',
'cardExpiryYear' => '26',
'cardExpiryMonth' => '12',
'cardCvc' => '123'
}.to_json

# Make POST request
http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.path, headers)
request.body = data

response = http.request(request)

if response.code.to_i == 200
puts JSON.parse(response.body)
else
puts "Request failed with status code #{response. code}"
end
Click to show a new payment job with token
import requests
import json

url = "https://gateway-inta.cashflows.com/api/gateway/payment-jobs"
data = {
"amountToCollect": "10",
"currency": "GBP",
"parameters": {
    "Token": "1000000000030419",
    "CardHolderName": "Han Solo",
    "CardExpiryYear": "27",
    "CardExpiryMonth": "12",
    "Cardcvc": "123",
    "ReturnUrlCancelled": "https://example.com?result=canceled",
    "ReturnUrlFailed": "https://example.com?result=failed",
    "ReturnUrlSuccess": "https://example.com?result=success"
},
"paymentMethodsToUse": ["card"]
}

headers = {
"Hash": "YOUR_SIGNATURE_HASH",
"ConfigurationId": "YOUR_CONFIGURATION_ID",
"Content-Type": "application/json"
}

response = requests.post(url, headers=headers, json=data)
print(response.text)
import java.io.OutputStream;
import java.net.HttpURLConnection;
import java.net.URL;

public class Main {
    public static void main(String[] args) {
        try {
        URL url = new URL("https://gateway-inta.cashflows.com/api/gateway/payment-jobs");
        HttpURLConnection connection = (HttpURLConnection) url.openConnection();
        connection.setRequestMethod("POST");
        connection.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");
        connection.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        connection.setRequestProperty("Content-Type", "application/json");
        connection.setDoOutput(true);

        String data = "{\n" +
            ""amountToCollect": "10",\n" +
            ""currency": "GBP",\n" +
            ""parameters": {\n" +
            ""Token": "1000000000030419",\n" +
            ""CardHolderName": "Han Solo",\n" +
            ""CardExpiryYear": "27",\n" +
            ""CardExpiryMonth": "12",\n" +
            ""Cardcvc": "123",\n" +
            ""ReturnUrlCancelled": "https://example.com?result=canceled",\n" +
            ""ReturnUrlFailed": "https://example.com?result=failed",\n" +
            ""ReturnUrlSuccess": "https://example.com?result=success"\n" +
            "},\n" +
            ""paymentMethodsToUse": [\n" +
            ""card"\n" +
            "]\n" +
            "}";

        try (OutputStream os = connection.getOutputStream()) {
            byte[] input = data.getBytes("utf-8");
            os.write(input, 0, input.length);
        }

        connection.getResponseCode();  // Make the request

        } catch (Exception e) {
        e.printStackTrace();
        }
    }
}
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main()
    {
        using (HttpClient client = new HttpClient())
        {
        var data = new
        {
            amountToCollect = "10",
            currency = "GBP",
            parameters = new
            {
            Token = "1000000000030419",
            CardHolderName = "Han Solo",
            CardExpiryYear = "27",
            CardExpiryMonth = "12",
            Cardcvc = "123",
            ReturnUrlCancelled = "https://example.com?result=canceled",
            ReturnUrlFailed = "https://example.com?result=failed",
            ReturnUrlSuccess = "https://example.com?result=success"
            },
            paymentMethodsToUse = new[] { "card" }
        };

        string json = Newtonsoft.Json.JsonConvert.SerializeObject(data);
        var content = new StringContent(json, Encoding.UTF8, "application/json");
        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");

        HttpResponseMessage response = await client.PostAsync("https://gateway-inta.cashflows.com/api/gateway/payment-jobs", content);

        string responseData = await response.Content.ReadAsStringAsync();
        Console.WriteLine(responseData);
        }
    }
}
const axios = require('axios');
let data = JSON.stringify({
"amountToCollect": "10",
"currency": "GBP",
"parameters": {
"Token": "1000000000030419",
"CardHolderName": "Han Solo",
"CardExpiryYear": "27",
"CardExpiryMonth": "12",
"Cardcvc": "123",
"ReturnUrlCancelled": "https://example.com?result=canceled",
"ReturnUrlFailed": "https://example.com?result=failed",
"ReturnUrlSuccess": "https://example.com?result=success"
},
"paymentMethodsToUse": [
"card"
]
});

let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs',
headers: {
'Hash': 'YOUR_SIGNATURE_HASH',
'ConfigurationId': 'YOUR_CONFIGURATION_ID',
'Content-Type': 'application/json'
},
data : data
};

axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
<?php
$url = 'https://gateway-inta.cashflows.com/api/gateway/payment-jobs';
$data = [
"amountToCollect" => "10",
"currency" => "GBP",
"parameters" => [
    "Token" => "1000000000030419",
    "CardHolderName" => "Han Solo",
    "CardExpiryYear" => "27",
    "CardExpiryMonth" => "12",
    "Cardcvc" => "123",
    "ReturnUrlCancelled" => "https://example.com?result=canceled",
    "ReturnUrlFailed" => "https://example.com?result=failed",
    "ReturnUrlSuccess" => "https://example.com?result=success"
],
"paymentMethodsToUse" => ["card"]
];

$headers = [
'Hash: YOUR_SIGNATURE_HASH',
'ConfigurationId: YOUR_CONFIGURATION_ID',
'Content-Type: application/json'
];

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

uri = URI.parse("https://gateway-inta.cashflows.com/api/gateway/payment-jobs")
http = Net::HTTP.new(uri.host, uri.port)

request = Net::HTTP::Post.new(uri.path, {
'Content-Type' => 'application/json',
'Hash' => 'YOUR_SIGNATURE_HASH',
'ConfigurationId' => 'YOUR_CONFIGURATION_ID'
})

data = {
"amountToCollect" => "10",
"currency" => "GBP",
"parameters" => {
"Token" => "1000000000030419",
"CardHolderName" => "Han Solo",
"CardExpiryYear" => "27",
"CardExpiryMonth" => "12",
"Cardcvc" => "123",
"ReturnUrlCancelled" => "https://example.com?result=canceled",
"ReturnUrlFailed" => "https://example.com?result=failed",
"ReturnUrlSuccess" => "https://example.com?result=success"
},
"paymentMethodsToUse" => ["card"]
}

request.body = data.to_json

response = http.request(request)
puts response.body

SupportedPaymentMethods

To retrieve your supported payment methods submit a GET request to /supported-payment-methods.

Click to show a new payment job with token
import requests

url = 'https://gateway-inta.cashflows.com/api/gateway/supported-payment-methods?subscription-key=YOUR_SUBSCRIPTION_KEY'

headers = {
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Hash': 'YOUR_SIGNATURE_HASH'
}

response = requests.get(url, headers=headers)
print(response.json())
import java.io.*;
import java.net.*;
import javax.net.ssl.HttpsURLConnection;

public class Main {
    public static void main(String[] args) throws Exception {
        String url = "https://gateway-inta.cashflows.com/api/gateway/supported-payment-methods?subscription-key=YOUR_SUBSCRIPTION_KEY";

        URL obj = new URL(url);
        HttpsURLConnection con = (HttpsURLConnection) obj.openConnection();

        con.setRequestMethod("GET");
        con.setRequestProperty("ConfigurationId", "YOUR_CONFIGURATION_ID");
        con.setRequestProperty("Hash", "YOUR_SIGNATURE_HASH");

        int responseCode = con.getResponseCode();
        System.out.println("Response Code: " + responseCode);

        BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));
        String inputLine;
        StringBuilder response = new StringBuilder();

        while ((inputLine = in.readLine()) != null) {
        response.append(inputLine);
        }
        in.close();

        System.out.println(response.toString());
    }
}
using System; using System.Net.Http; using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        var client = new HttpClient();
        var url = "https://gateway-inta.cashflows.com/api/gateway/supported-payment-methods?subscription-key=YOUR_SUBSCRIPTION_KEY";
        client.DefaultRequestHeaders.Add("ConfigurationId", "YOUR_CONFIGURATION_ID");
        client.DefaultRequestHeaders.Add("Hash", "YOUR_SIGNATURE_HASH");

        var response = await client.GetAsync(url);
        var responseString = await response.Content.ReadAsStringAsync();

        Console.WriteLine(responseString);
    }
}
const axios = require('axios');

let config = {
    method: 'get',
    maxBodyLength: Infinity,
    url: 'https://gateway-inta.cashflows.com/api/gateway/supported-payment-methods?subscription-key=YOUR_SUBSCRIPTION_KEY',
    headers: {
    'ConfigurationId': 'YOUR_CONFIGURATION_ID',
    'Hash': 'YOUR_SIGNATURE_HASH'
    }
};

axios.request(config)
.then((response) => {
    console.log(JSON.stringify(response.data));
})
.catch((error) => {
    console.log(error);
});
<?php

$url = 'https://gateway-inta.cashflows.com/api/gateway/supported-payment-methods?subscription-key=YOUR_SUBSCRIPTION_KEY';

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'ConfigurationId: YOUR_CONFIGURATION_ID',
    'Hash: YOUR_SIGNATURE_HASH'
]);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
require 'net/http'
require 'uri'
require 'json'

url = URI.parse('https://gateway-inta.cashflows.com/api/gateway/supported-payment-methods?subscription-key=YOUR_SUBSCRIPTION_KEY')
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url.path + "?" + url.query,
{
    'ConfigurationId' => 'YOUR_CONFIGURATION_ID',
    'Hash' => 'YOUR_SIGNATURE_HASH'
})

response = http.request(request)
puts response.body

PaymentIntents

Creates a new payments intent.

Parameters

Description

Type

type

Valid values: Payment, Credit

String

locale

The Locale enum specifies a unique entry for each supported culture, based on RFC 4646. The name is a combination of an ISO 639 two-letter lowercase (ISO 639-1) culture code associated with a language and an ISO 3166 two-letter uppercase (ISO 3166-1 alpha-2) subculture code associated with country or region.

String

timeZone

The time zone of the intented audience of the payment job.

String

order

The request object used to update an order.

Object

order.orderNumber

The order number.

String

order.note

Additional comments or requests.

String

order.customerReference

A reference to the customer used for default billing address, billing identity and shipping address details.

Integer

order.billingAddress

Object related to the billing address.

Object

billingAddress.title

A prefix or suffix added to someone’s name in certain contexts. For example Mr. or Ms./Mrs. for an adult man or woman. This value is used as is, regardless of the locale specified in the payment job.

String

billingAddress.firstName

The given name of the addressee.

String

billingAddress.middleName

The middle part of the name of the addressee. This is the portion of a personal name that is written between the person’s given name and their surname.

String

billingAddress.lastName

The last part of the name of the addressee. This usually is the person’s surname.

String

billingAddress.countryIso3166Alpha2

ISO country code.

String

billingAddress.addressLine1

Primary address information, such as street name and house number.

String

billingAddress.addressLine2

Additional address information, such as floor number or apartment number.

String

billingAddress.zipCode

The zip or postal code.

String

billingAddress.city

The name of the city.

String

billingAddress.stateProvince

The name of the state or province.

String

billingAddress.phoneNumber1

Primary telephone number of the addressee.

String

billingAddress.phoneNumber1Type

Type of phone number: Unknown Mobile ``Fixed

String

billingAddress.phoneNumber2

Secondary telephone number of the addressee.

String

billingAddress.phoneNumber2Type

Type of phone number: Unknown Mobile ``Fixed

String

billingAddress.organisation

Name of the company or organisation, if the address is a company or organisation.

String

billingAddress.department

Name of the department, if the address is a company or organisation.

String

order.billingIdentity

An object containing information, additional to the address object, such as an email address, gender, and government numbers.

Object

billingIdentity.debtorID

A reference, unique to the company, to the person this object relates to. This reference is supplied by the merchant.

String

billingIdentity.emailAddress

Email address of the person this object relates to.

String

billingIdentity.gender

Valid values: Female Male

String

billingIdentity.dateOfBirth

The date of birth of the person this object relates to.

String

billingIdentity.socialSecurityNumber

A number, unique to the specified country, identifying the person this object relates to. This property can for example be used for a nine-digit Social Security number (SSN) for U.S citizens or a burgerservicenummer (BSN) for Dutch citizens.

String

billingIdentity.chamberOfCommerceNumber

String

billingIdentity.vatNumber

A globally unique value added tax identification number of the person, organisation or company this object relates to

String

order.shippingAddress

Object related to the shipping address.

Object

shippingAddress.title

A prefix or suffix added to someone’s name in certain contexts. For example Mr. or Ms./Mrs. for an adult man or woman. This value is used as is, regardless of the locale specified in the payment job.

String

shippingAddress.firstName

The given name of the addressee.

String

shippingAddress.middleName

The middle part of the name of the addressee. This is the portion of a personal name that is written between the person’s given name and their surname.

String

shippingAddress.lastName

The last part of the name of the addressee. This usually is the person’s surname.

String

shippingAddress.countryIso3166Alpha2

ISO country code.

String

shippingAddress.addressLine1

Primary address information, such as street name and house number.

String

shippingAddress.addressLine2

Additional address information, such as floor number or apartment number.

String

shippingAddress.zipCode

The zip or postal code.

String

shippingAddress.city

The name of the city.

String

shippingAddress.stateProvince

The name of the state or province.

String

shippingAddress.phoneNumber1

Primary telephone number of the addressee.

String

shippingAddress.phoneNumber1Type

Type of phone number: Unknown Mobile ``Fixed

String

shippingAddress.phoneNumber2

Secondary telephone number of the addressee.

String

shippingAddress.phoneNumber2Type

Type of phone number: Unknown Mobile ``Fixed

String

shippingAddress.organisation

Name of the company or organisation, if the address is a company or organisation.

String

shippingAddress.department

Name of the department, if the address is a company or organisation.

String

order.orderLines

List of order lines that that contain the order line details.

Object

orderLines.lineNumber

A number, unique to an order, to determine the order of the order lines.

Integer

orderLines.type

Valid: PhysicalItem DigitalItem ShippingCost PaymentCost Discount GiftCard ShopCredit

String

orderLines.skuCode

A (unique) code that refers to a particular stock keeping unit.

String

orderLines.name

The name of the product or service.

String

orderLines.description

A description of the product or service.

String

orderLines.quantity

The ordered quantity.

Double

orderLines.unitPriceExclVat

Unit price excluding value-added tax (VAT), either one or both unit prices must be specified.

Double

orderLines.unitPriceInclVat

Unit price including value-added tax (VAT), either one or both unit prices must be specified.

Double

orderLines.vatPercentage

Applied VAT percentage.

Double

orderLines.vatPercentageLabel

VAT percentage to display.

String

orderLines.discountPercentageLabel

Discount percentage to display.

String

orderLines.totalLineAmount

Total order line amount. Including VAT if the unit price including VAT is specified, otherwise excluding VAT.

Double

orderLines.url

A URL that is shown in the portal to the receiver. This can be used to store a link to a product for easy navigation.

String

parentPaymentJobReference

A reference to the parent payment job.

Integer

paymentMethodsToUse

A list of payment methods (for example iDeal, PayPal, AfterPay) to enable for this request. If none are supplied, all configured and applicable payment methods will be used, valid values: PayPal CreditCard Creditcard DebitCard Debitcard Card

Array

parameters

Additional parameters, like AutoInvoice, and HostedNotCancelable to use when executing the request, as well as payment method specific parameters, like BIC for iDEAL, for use by one or more payment methods. Key options: OriginatingIpAddress, OriginHeader, UserAgent, ThreeDSecureChallengeAcceptHeader, ThreeDSecureV2ChallengeWindowSize, BrowserLanguage, BrowserTimeZoneOffset, BrowserJavaEnabled, BrowserJavaScriptEnabled, BrowserScreenHeight, BrowserScreenWidth, BrowserScreenColorDepth, ReturnUrlSuccess, ReturnUrlFailed, ReturnUrlCancelled, WebhookUrl, PaymentPageReference, SimulatedStatus, IdealBic, SelectedPaymentMethod, CardNumber, CardCvc, CardExpiryMonth, CardExpiryYear, CardHolderName, Mcc, RecipientDetails, PaRes, Md, RReq, CRes, ThreeDSSessionData, ThreeDSMethodData, ThreeDSecureXid, ThreeDSecureCavv, ThreeDSecureEci, ThreeDSecureVersion, ThreeDSecureDSTransId, Token, PayerId, GoogleAnalyticsClientId, AllowedParentFrameDomains, Descriptor, EWalletType, ApplePayTransactionIdentifier

Object

options

Additional options used to steer payment job related flows, valid values: IsRecurringPaymentJobParent IsMoto StoreCustomerInformation StoreCardDetails GenerateToken

Array

displayUrl

A URL that is shown in the portal to the receiver. This can be used to store a link to an order in the receiver’s order system for easy navigation

String

currency

Currency used for the transaction

String

amountToCollect

The amount to collect in this payment job. This amount is initially supplied by the instantiator of the payment request. The amount which is actually collected is the sum of the amount to collect and the surcharge amount together.

Double

expirationDateTimeUtc

The date and time the payment job expires and is no longer valid. If not supplied, the payment job will expire after six months after creation.

String

recurrenceCriteria

Specifics of the recurrence.

Object

recurrenceCriteria.recurrenceType

Valid values: Subscription Instalment Unscheduled CustomerInitiated

String

recurrenceCriteria.recurringExpiry

The date and time after which this recurrence is no longer valid.

String

recurrenceCriteria.recurringFrequency

The minimum set of days between transactions.

Integer

recurrenceCriteria.instalments

The amount of instalments.

Integer