Customer Account Balance

Some payment providers allow customers to have Balances saved for a Token. If the token is associated with payment providers that support APMs, you can use ProcessOut APIs to check if the customer has any balance that can be used. Currently, the only supported balance method is vouchers. If the customer doesn’t have any, you can then bill using other registered payment methods.

The customer account balance can be fetched with the following:

curl -X GET https://api.processout.com/balances/tokens/tok_fKK4btSG7wd13ZZaevzhMcuNbpjcu1Zy \
    -u test-proj_gAO1Uu0ysZJvDuUpOGPkUBeE3pGalk3x:key_sandbox_mah31RDFqcDxmaS7MvhDbJfDJvjtsFTB
const ProcessOut = require("processout");
const client = new ProcessOut(
    "test-proj_gAO1Uu0ysZJvDuUpOGPkUBeE3pGalk3x",
    "key_sandbox_mah31RDFqcDxmaS7MvhDbJfDJvjtsFTB");

// ...

const balances = await client.newBalances().find("tok_fKK4btSG7wd13ZZaevzhMcuNbpjcu1Zy");
import processout
client = processout.ProcessOut(
    "test-proj_gAO1Uu0ysZJvDuUpOGPkUBeE3pGalk3x",
    "key_sandbox_mah31RDFqcDxmaS7MvhDbJfDJvjtsFTB")

# use customer payment token to retrieve any available balance
balances = client.new_balances().find("tok_fKK4btSG7wd13ZZaevzhMcuNbpjcu1Zy")
require "processout"
client = ProcessOut::Client.new(
    "test-proj_gAO1Uu0ysZJvDuUpOGPkUBeE3pGalk3x",
    "key_sandbox_mah31RDFqcDxmaS7MvhDbJfDJvjtsFTB")

# use customer payment token to retrieve any available balance
balances = client.balances.find("tok_fKK4btSG7wd13ZZaevzhMcuNbpjcu1Zy")
<?php
$client = new \ProcessOut\ProcessOut(
    "test-proj_gAO1Uu0ysZJvDuUpOGPkUBeE3pGalk3x",
    "key_sandbox_mah31RDFqcDxmaS7MvhDbJfDJvjtsFTB");

// use customer payment token to retrieve any available balance
$balances = $client->newBalances()->find("tok_fKK4btSG7wd13ZZaevzhMcuNbpjcu1Zy");
?>
import "github.com/processout/processout-go"

client := processout.New(
    "test-proj_gAO1Uu0ysZJvDuUpOGPkUBeE3pGalk3x",
    "key_sandbox_mah31RDFqcDxmaS7MvhDbJfDJvjtsFTB",
)

// use customer payment token to retrieve any available balance
balances, err := client.NewBalances().Find("tok_fKK4btSG7wd13ZZaevzhMcuNbpjcu1Zy")