curl --request PATCH \
--url https://api.synctera.com/v1/spend_controls/{spend_control_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"action_case": true,
"action_decline": true,
"amount_limit": 1,
"description": "<string>",
"geo_restrictions": {
"countries": [
"CA",
"GB",
"US"
],
"country_sources": [
"COUNTER_PARTY"
]
},
"is_active": true,
"merchant_category_codes": [
"5600–5699"
],
"name": "<string>",
"payment_sub_types": [],
"payment_types": [],
"time_range": {},
"transaction_count_limit": 1
}
'import requests
url = "https://api.synctera.com/v1/spend_controls/{spend_control_id}"
payload = {
"action_case": True,
"action_decline": True,
"amount_limit": 1,
"description": "<string>",
"geo_restrictions": {
"countries": ["CA", "GB", "US"],
"country_sources": ["COUNTER_PARTY"]
},
"is_active": True,
"merchant_category_codes": ["5600–5699"],
"name": "<string>",
"payment_sub_types": [],
"payment_types": [],
"time_range": {},
"transaction_count_limit": 1
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
action_case: true,
action_decline: true,
amount_limit: 1,
description: '<string>',
geo_restrictions: {countries: ['CA', 'GB', 'US'], country_sources: ['COUNTER_PARTY']},
is_active: true,
merchant_category_codes: ['5600–5699'],
name: '<string>',
payment_sub_types: [],
payment_types: [],
time_range: {},
transaction_count_limit: 1
})
};
fetch('https://api.synctera.com/v1/spend_controls/{spend_control_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.synctera.com/v1/spend_controls/{spend_control_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'action_case' => true,
'action_decline' => true,
'amount_limit' => 1,
'description' => '<string>',
'geo_restrictions' => [
'countries' => [
'CA',
'GB',
'US'
],
'country_sources' => [
'COUNTER_PARTY'
]
],
'is_active' => true,
'merchant_category_codes' => [
'5600–5699'
],
'name' => '<string>',
'payment_sub_types' => [
],
'payment_types' => [
],
'time_range' => [
],
'transaction_count_limit' => 1
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.synctera.com/v1/spend_controls/{spend_control_id}"
payload := strings.NewReader("{\n \"action_case\": true,\n \"action_decline\": true,\n \"amount_limit\": 1,\n \"description\": \"<string>\",\n \"geo_restrictions\": {\n \"countries\": [\n \"CA\",\n \"GB\",\n \"US\"\n ],\n \"country_sources\": [\n \"COUNTER_PARTY\"\n ]\n },\n \"is_active\": true,\n \"merchant_category_codes\": [\n \"5600–5699\"\n ],\n \"name\": \"<string>\",\n \"payment_sub_types\": [],\n \"payment_types\": [],\n \"time_range\": {},\n \"transaction_count_limit\": 1\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.synctera.com/v1/spend_controls/{spend_control_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"action_case\": true,\n \"action_decline\": true,\n \"amount_limit\": 1,\n \"description\": \"<string>\",\n \"geo_restrictions\": {\n \"countries\": [\n \"CA\",\n \"GB\",\n \"US\"\n ],\n \"country_sources\": [\n \"COUNTER_PARTY\"\n ]\n },\n \"is_active\": true,\n \"merchant_category_codes\": [\n \"5600–5699\"\n ],\n \"name\": \"<string>\",\n \"payment_sub_types\": [],\n \"payment_types\": [],\n \"time_range\": {},\n \"transaction_count_limit\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.synctera.com/v1/spend_controls/{spend_control_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"action_case\": true,\n \"action_decline\": true,\n \"amount_limit\": 1,\n \"description\": \"<string>\",\n \"geo_restrictions\": {\n \"countries\": [\n \"CA\",\n \"GB\",\n \"US\"\n ],\n \"country_sources\": [\n \"COUNTER_PARTY\"\n ]\n },\n \"is_active\": true,\n \"merchant_category_codes\": [\n \"5600–5699\"\n ],\n \"name\": \"<string>\",\n \"payment_sub_types\": [],\n \"payment_types\": [],\n \"time_range\": {},\n \"transaction_count_limit\": 1\n}"
response = http.request(request)
puts response.read_body{
"number_of_related_accounts": 1,
"number_of_related_cards": 1,
"number_of_related_customers": 1,
"tenant": "abcdef_ghijkl",
"action_case": true,
"action_decline": true,
"creation_time": "2010-05-06T12:23:34.321Z",
"direction": "ANY",
"id": "7d943c51-e4ff-4e57-9558-08cab6b963c7",
"is_active": true,
"last_modified_time": "2010-05-06T12:23:34.321Z",
"name": "<string>",
"time_range": {
"time_range_type": "FOREVER"
},
"aggregation_level": "ACCOUNT",
"amount_limit": 1,
"description": "<string>",
"geo_restrictions": {
"countries": [
"CA",
"GB",
"US"
],
"mode": "ALLOW_LIST",
"country_sources": [
"COUNTER_PARTY"
]
},
"managed_by": "BANK",
"merchant_category_codes": [
"5600–5699"
],
"payment_sub_types": [
"WIRE.BULK_DOMESTIC_OUTGOING"
],
"payment_subtype_map": {
"ACH": [
"ACH.INCOMING_CREDIT"
],
"CARD": [
"CARD.ATM_WITHDRAWAL"
],
"CASH": [
"CASH.CASH_ORDER"
],
"CHECK": [
"CHECK.MOBILE_DEPOSIT"
],
"EFT_CA": [
"EFT_CA.BULK_OUTGOING_CREDIT"
],
"EXTERNAL_CARD": [
"EXTERNAL_CARD.CARD_FUNDING"
],
"FEDNOW": [
"FEDNOW.FEDNOW_INCOMING"
],
"INTERNAL_TRANSFER": [
"INTERNAL_TRANSFER.ACCOUNT_BALANCE_ADJUSTMENT"
],
"SYNCTERA_PAY": [
"SYNCTERA_PAY.INCOMING_INTERAC_AUTODEPOSIT"
],
"WIRE": [
"WIRE.BULK_DOMESTIC_OUTGOING"
]
},
"payment_types": [
"ACH"
],
"scope": "ACCOUNT",
"transaction_count_limit": 1
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}Update Spend Control
Update spend control
curl --request PATCH \
--url https://api.synctera.com/v1/spend_controls/{spend_control_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"action_case": true,
"action_decline": true,
"amount_limit": 1,
"description": "<string>",
"geo_restrictions": {
"countries": [
"CA",
"GB",
"US"
],
"country_sources": [
"COUNTER_PARTY"
]
},
"is_active": true,
"merchant_category_codes": [
"5600–5699"
],
"name": "<string>",
"payment_sub_types": [],
"payment_types": [],
"time_range": {},
"transaction_count_limit": 1
}
'import requests
url = "https://api.synctera.com/v1/spend_controls/{spend_control_id}"
payload = {
"action_case": True,
"action_decline": True,
"amount_limit": 1,
"description": "<string>",
"geo_restrictions": {
"countries": ["CA", "GB", "US"],
"country_sources": ["COUNTER_PARTY"]
},
"is_active": True,
"merchant_category_codes": ["5600–5699"],
"name": "<string>",
"payment_sub_types": [],
"payment_types": [],
"time_range": {},
"transaction_count_limit": 1
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
action_case: true,
action_decline: true,
amount_limit: 1,
description: '<string>',
geo_restrictions: {countries: ['CA', 'GB', 'US'], country_sources: ['COUNTER_PARTY']},
is_active: true,
merchant_category_codes: ['5600–5699'],
name: '<string>',
payment_sub_types: [],
payment_types: [],
time_range: {},
transaction_count_limit: 1
})
};
fetch('https://api.synctera.com/v1/spend_controls/{spend_control_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.synctera.com/v1/spend_controls/{spend_control_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'action_case' => true,
'action_decline' => true,
'amount_limit' => 1,
'description' => '<string>',
'geo_restrictions' => [
'countries' => [
'CA',
'GB',
'US'
],
'country_sources' => [
'COUNTER_PARTY'
]
],
'is_active' => true,
'merchant_category_codes' => [
'5600–5699'
],
'name' => '<string>',
'payment_sub_types' => [
],
'payment_types' => [
],
'time_range' => [
],
'transaction_count_limit' => 1
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.synctera.com/v1/spend_controls/{spend_control_id}"
payload := strings.NewReader("{\n \"action_case\": true,\n \"action_decline\": true,\n \"amount_limit\": 1,\n \"description\": \"<string>\",\n \"geo_restrictions\": {\n \"countries\": [\n \"CA\",\n \"GB\",\n \"US\"\n ],\n \"country_sources\": [\n \"COUNTER_PARTY\"\n ]\n },\n \"is_active\": true,\n \"merchant_category_codes\": [\n \"5600–5699\"\n ],\n \"name\": \"<string>\",\n \"payment_sub_types\": [],\n \"payment_types\": [],\n \"time_range\": {},\n \"transaction_count_limit\": 1\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.synctera.com/v1/spend_controls/{spend_control_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"action_case\": true,\n \"action_decline\": true,\n \"amount_limit\": 1,\n \"description\": \"<string>\",\n \"geo_restrictions\": {\n \"countries\": [\n \"CA\",\n \"GB\",\n \"US\"\n ],\n \"country_sources\": [\n \"COUNTER_PARTY\"\n ]\n },\n \"is_active\": true,\n \"merchant_category_codes\": [\n \"5600–5699\"\n ],\n \"name\": \"<string>\",\n \"payment_sub_types\": [],\n \"payment_types\": [],\n \"time_range\": {},\n \"transaction_count_limit\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.synctera.com/v1/spend_controls/{spend_control_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"action_case\": true,\n \"action_decline\": true,\n \"amount_limit\": 1,\n \"description\": \"<string>\",\n \"geo_restrictions\": {\n \"countries\": [\n \"CA\",\n \"GB\",\n \"US\"\n ],\n \"country_sources\": [\n \"COUNTER_PARTY\"\n ]\n },\n \"is_active\": true,\n \"merchant_category_codes\": [\n \"5600–5699\"\n ],\n \"name\": \"<string>\",\n \"payment_sub_types\": [],\n \"payment_types\": [],\n \"time_range\": {},\n \"transaction_count_limit\": 1\n}"
response = http.request(request)
puts response.read_body{
"number_of_related_accounts": 1,
"number_of_related_cards": 1,
"number_of_related_customers": 1,
"tenant": "abcdef_ghijkl",
"action_case": true,
"action_decline": true,
"creation_time": "2010-05-06T12:23:34.321Z",
"direction": "ANY",
"id": "7d943c51-e4ff-4e57-9558-08cab6b963c7",
"is_active": true,
"last_modified_time": "2010-05-06T12:23:34.321Z",
"name": "<string>",
"time_range": {
"time_range_type": "FOREVER"
},
"aggregation_level": "ACCOUNT",
"amount_limit": 1,
"description": "<string>",
"geo_restrictions": {
"countries": [
"CA",
"GB",
"US"
],
"mode": "ALLOW_LIST",
"country_sources": [
"COUNTER_PARTY"
]
},
"managed_by": "BANK",
"merchant_category_codes": [
"5600–5699"
],
"payment_sub_types": [
"WIRE.BULK_DOMESTIC_OUTGOING"
],
"payment_subtype_map": {
"ACH": [
"ACH.INCOMING_CREDIT"
],
"CARD": [
"CARD.ATM_WITHDRAWAL"
],
"CASH": [
"CASH.CASH_ORDER"
],
"CHECK": [
"CHECK.MOBILE_DEPOSIT"
],
"EFT_CA": [
"EFT_CA.BULK_OUTGOING_CREDIT"
],
"EXTERNAL_CARD": [
"EXTERNAL_CARD.CARD_FUNDING"
],
"FEDNOW": [
"FEDNOW.FEDNOW_INCOMING"
],
"INTERNAL_TRANSFER": [
"INTERNAL_TRANSFER.ACCOUNT_BALANCE_ADJUSTMENT"
],
"SYNCTERA_PAY": [
"SYNCTERA_PAY.INCOMING_INTERAC_AUTODEPOSIT"
],
"WIRE": [
"WIRE.BULK_DOMESTIC_OUTGOING"
]
},
"payment_types": [
"ACH"
],
"scope": "ACCOUNT",
"transaction_count_limit": 1
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}{
"code": "BAD_REQUEST_BODY",
"detail": "Missing required fields: first_name, dob",
"status": 400
}Authorizations
Path Parameters
Body
Fields to update
Controls how spend is measured for enforcement:
ACCOUNT- Per-account: each account's spend is checked independently (default)CUSTOMER- Per-customer: spend is aggregated across all accounts owned by the customerCARDS- Per-card: spend is aggregated per specific card
ACCOUNT, CARDS, CUSTOMER The direction of funds flow to which a spend control applies. To limit the rate of funds flowing out of an account, use DEBITS. To limit the rate of funds flowing in to an account, use CREDITS. Use ANY to apply the spend control to both debits and credits. If this is not set, the spend control applies to debits (ie spending) only.
ANY, CREDITS, DEBITS A list of payment sub-types to which a spend control will apply, if set. If not set or the array is empty, then the spend control will apply to all sub-types. Values must use "PAYMENT_TYPE.SUBTYPE" dot notation (e.g. "CARD.ATM_WITHDRAWAL", "ACH.INCOMING_CREDIT"). If payment_types is also set, every entry here must belong to one of those payment types or a 422 AMBIGUOUS_PAYMENT_SUBTYPES error will be returned. See payment_subtype_map for the full list of valid values grouped by payment type.
A valid payment sub-type value for a spend control, expressed in "PAYMENT_TYPE.SUBTYPE" dot notation. See payment_subtype_map for valid values grouped by payment type.
WIRE.BULK_DOMESTIC_OUTGOING, WIRE.BULK_DOMESTIC_OUTGOING_REVERSAL, WIRE.DOMESTIC_INCOMING, WIRE.DOMESTIC_INCOMING_RETURN, WIRE.DOMESTIC_INCOMING_RETURN_REVERSAL, WIRE.DOMESTIC_INCOMING_REVERSAL, WIRE.DOMESTIC_OUTGOING, WIRE.DOMESTIC_OUTGOING_RETURN, WIRE.DOMESTIC_OUTGOING_RETURN_REVERSAL, WIRE.DOMESTIC_OUTGOING_REVERSAL, WIRE.INTERNATIONAL_INCOMING, WIRE.INTERNATIONAL_INCOMING_RETURN, WIRE.INTERNATIONAL_INCOMING_RETURN_REVERSAL, WIRE.INTERNATIONAL_INCOMING_REVERSAL, WIRE.INTERNATIONAL_OUTGOING, WIRE.INTERNATIONAL_OUTGOING_RETURN, WIRE.INTERNATIONAL_OUTGOING_RETURN_REVERSAL, WIRE.INTERNATIONAL_OUTGOING_REVERSAL A list of payment types to which a spend control will apply, if set. If not set or the array is empty, then the spend control will apply to all types of payments.
The type of payment to which a spend control applies. If this is not set, the spend control applies to all spending, regardless of payment type.
ACH, CARD, CASH, CHECK, EFT_CA, EXTERNAL_CARD, FEDNOW, INTERNAL_TRANSFER, SYNCTERA_PAY, WIRE Response
Spend control details
The direction of funds flow to which a spend control applies. To limit the rate of funds flowing out of an account, use DEBITS. To limit the rate of funds flowing in to an account, use CREDITS. Use ANY to apply the spend control to both debits and credits. If this is not set, the spend control applies to debits (ie spending) only.
ANY, CREDITS, DEBITS Controls how spend is measured for enforcement:
ACCOUNT- Per-account: each account's spend is checked independently (default)CUSTOMER- Per-customer: spend is aggregated across all accounts owned by the customerCARDS- Per-card: spend is aggregated per specific card
ACCOUNT, CARDS, CUSTOMER A list of payment sub-types to which a spend control will apply, if set. If not set or the array is empty, then the spend control will apply to all sub-types. Values must use "PAYMENT_TYPE.SUBTYPE" dot notation (e.g. "CARD.ATM_WITHDRAWAL", "ACH.INCOMING_CREDIT"). If payment_types is also set, every entry here must belong to one of those payment types or a 422 AMBIGUOUS_PAYMENT_SUBTYPES error will be returned. See payment_subtype_map for the full list of valid values grouped by payment type.
A valid payment sub-type value for a spend control, expressed in "PAYMENT_TYPE.SUBTYPE" dot notation. See payment_subtype_map for valid values grouped by payment type.
WIRE.BULK_DOMESTIC_OUTGOING, WIRE.BULK_DOMESTIC_OUTGOING_REVERSAL, WIRE.DOMESTIC_INCOMING, WIRE.DOMESTIC_INCOMING_RETURN, WIRE.DOMESTIC_INCOMING_RETURN_REVERSAL, WIRE.DOMESTIC_INCOMING_REVERSAL, WIRE.DOMESTIC_OUTGOING, WIRE.DOMESTIC_OUTGOING_RETURN, WIRE.DOMESTIC_OUTGOING_RETURN_REVERSAL, WIRE.DOMESTIC_OUTGOING_REVERSAL, WIRE.INTERNATIONAL_INCOMING, WIRE.INTERNATIONAL_INCOMING_RETURN, WIRE.INTERNATIONAL_INCOMING_RETURN_REVERSAL, WIRE.INTERNATIONAL_INCOMING_REVERSAL, WIRE.INTERNATIONAL_OUTGOING, WIRE.INTERNATIONAL_OUTGOING_RETURN, WIRE.INTERNATIONAL_OUTGOING_RETURN_REVERSAL, WIRE.INTERNATIONAL_OUTGOING_REVERSAL A list of payment types to which a spend control will apply, if set. If not set or the array is empty, then the spend control will apply to all types of payments.
The type of payment to which a spend control applies. If this is not set, the spend control applies to all spending, regardless of payment type.
ACH, CARD, CASH, CHECK, EFT_CA, EXTERNAL_CARD, FEDNOW, INTERNAL_TRANSFER, SYNCTERA_PAY, WIRE The scope determines which accounts this spend control applies to:
ACCOUNT- Applies only to accounts explicitly linked via account mappings (default)CUSTOMER- Applies only to customers explicitly linked via customer mappingsCARDS- Applies only to cards explicitly linked via card mappingsFINTECH- Automatically applies to all accounts under the fintech tenantBANK- Automatically applies to all accounts under the bank tenant
ACCOUNT, BANK, CARDS, CUSTOMER, FINTECH Was this page helpful?

