Update Card
curl --request POST \
--url https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update \
--header 'Content-Type: application/json' \
--header 'X-Forwarded-From: <x-forwarded-from>' \
--data '
{
"cardId": "<string>",
"merchantOrderNo": "<string>",
"remark": "<string>",
"noPinPaymentAmount": 123,
"spendingControls": [
{
"interval": "<string>",
"amount": 123,
"supportSetting": true
}
],
"riskControls": {
"allowedMcc": [
"<string>"
],
"blockedMcc": [
"<string>"
]
}
}
'import requests
url = "https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update"
payload = {
"cardId": "<string>",
"merchantOrderNo": "<string>",
"remark": "<string>",
"noPinPaymentAmount": 123,
"spendingControls": [
{
"interval": "<string>",
"amount": 123,
"supportSetting": True
}
],
"riskControls": {
"allowedMcc": ["<string>"],
"blockedMcc": ["<string>"]
}
}
headers = {
"X-Forwarded-From": "<x-forwarded-from>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-Forwarded-From': '<x-forwarded-from>', 'Content-Type': 'application/json'},
body: JSON.stringify({
cardId: '<string>',
merchantOrderNo: '<string>',
remark: '<string>',
noPinPaymentAmount: 123,
spendingControls: [{interval: '<string>', amount: 123, supportSetting: true}],
riskControls: {allowedMcc: ['<string>'], blockedMcc: ['<string>']}
})
};
fetch('https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update', 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://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'cardId' => '<string>',
'merchantOrderNo' => '<string>',
'remark' => '<string>',
'noPinPaymentAmount' => 123,
'spendingControls' => [
[
'interval' => '<string>',
'amount' => 123,
'supportSetting' => true
]
],
'riskControls' => [
'allowedMcc' => [
'<string>'
],
'blockedMcc' => [
'<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Forwarded-From: <x-forwarded-from>"
],
]);
$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://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update"
payload := strings.NewReader("{\n \"cardId\": \"<string>\",\n \"merchantOrderNo\": \"<string>\",\n \"remark\": \"<string>\",\n \"noPinPaymentAmount\": 123,\n \"spendingControls\": [\n {\n \"interval\": \"<string>\",\n \"amount\": 123,\n \"supportSetting\": true\n }\n ],\n \"riskControls\": {\n \"allowedMcc\": [\n \"<string>\"\n ],\n \"blockedMcc\": [\n \"<string>\"\n ]\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Forwarded-From", "<x-forwarded-from>")
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.post("https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update")
.header("X-Forwarded-From", "<x-forwarded-from>")
.header("Content-Type", "application/json")
.body("{\n \"cardId\": \"<string>\",\n \"merchantOrderNo\": \"<string>\",\n \"remark\": \"<string>\",\n \"noPinPaymentAmount\": 123,\n \"spendingControls\": [\n {\n \"interval\": \"<string>\",\n \"amount\": 123,\n \"supportSetting\": true\n }\n ],\n \"riskControls\": {\n \"allowedMcc\": [\n \"<string>\"\n ],\n \"blockedMcc\": [\n \"<string>\"\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Forwarded-From"] = '<x-forwarded-from>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"cardId\": \"<string>\",\n \"merchantOrderNo\": \"<string>\",\n \"remark\": \"<string>\",\n \"noPinPaymentAmount\": 123,\n \"spendingControls\": [\n {\n \"interval\": \"<string>\",\n \"amount\": 123,\n \"supportSetting\": true\n }\n ],\n \"riskControls\": {\n \"allowedMcc\": [\n \"<string>\"\n ],\n \"blockedMcc\": [\n \"<string>\"\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"code": 200,
"msg": "Success",
"data": {
"cardId": "card-12345678",
"operationType": "FREEZE",
"operationStatus": "COMPLETED",
"transactionId": "tx-12345678",
"operationTime": 1640995200000,
"newCardStatus": "FROZEN",
"previousCardStatus": "ACTIVE",
"reason": "Customer request"
}
}Cards
Update Card
Update card settings (spending controls, MCC, PIN-free amount)
POST
/
api
/
v2.1
/
fincard
/
virtual
/
card
/
v2
/
update
Update Card
curl --request POST \
--url https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update \
--header 'Content-Type: application/json' \
--header 'X-Forwarded-From: <x-forwarded-from>' \
--data '
{
"cardId": "<string>",
"merchantOrderNo": "<string>",
"remark": "<string>",
"noPinPaymentAmount": 123,
"spendingControls": [
{
"interval": "<string>",
"amount": 123,
"supportSetting": true
}
],
"riskControls": {
"allowedMcc": [
"<string>"
],
"blockedMcc": [
"<string>"
]
}
}
'import requests
url = "https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update"
payload = {
"cardId": "<string>",
"merchantOrderNo": "<string>",
"remark": "<string>",
"noPinPaymentAmount": 123,
"spendingControls": [
{
"interval": "<string>",
"amount": 123,
"supportSetting": True
}
],
"riskControls": {
"allowedMcc": ["<string>"],
"blockedMcc": ["<string>"]
}
}
headers = {
"X-Forwarded-From": "<x-forwarded-from>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-Forwarded-From': '<x-forwarded-from>', 'Content-Type': 'application/json'},
body: JSON.stringify({
cardId: '<string>',
merchantOrderNo: '<string>',
remark: '<string>',
noPinPaymentAmount: 123,
spendingControls: [{interval: '<string>', amount: 123, supportSetting: true}],
riskControls: {allowedMcc: ['<string>'], blockedMcc: ['<string>']}
})
};
fetch('https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update', 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://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'cardId' => '<string>',
'merchantOrderNo' => '<string>',
'remark' => '<string>',
'noPinPaymentAmount' => 123,
'spendingControls' => [
[
'interval' => '<string>',
'amount' => 123,
'supportSetting' => true
]
],
'riskControls' => [
'allowedMcc' => [
'<string>'
],
'blockedMcc' => [
'<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Forwarded-From: <x-forwarded-from>"
],
]);
$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://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update"
payload := strings.NewReader("{\n \"cardId\": \"<string>\",\n \"merchantOrderNo\": \"<string>\",\n \"remark\": \"<string>\",\n \"noPinPaymentAmount\": 123,\n \"spendingControls\": [\n {\n \"interval\": \"<string>\",\n \"amount\": 123,\n \"supportSetting\": true\n }\n ],\n \"riskControls\": {\n \"allowedMcc\": [\n \"<string>\"\n ],\n \"blockedMcc\": [\n \"<string>\"\n ]\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Forwarded-From", "<x-forwarded-from>")
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.post("https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update")
.header("X-Forwarded-From", "<x-forwarded-from>")
.header("Content-Type", "application/json")
.body("{\n \"cardId\": \"<string>\",\n \"merchantOrderNo\": \"<string>\",\n \"remark\": \"<string>\",\n \"noPinPaymentAmount\": 123,\n \"spendingControls\": [\n {\n \"interval\": \"<string>\",\n \"amount\": 123,\n \"supportSetting\": true\n }\n ],\n \"riskControls\": {\n \"allowedMcc\": [\n \"<string>\"\n ],\n \"blockedMcc\": [\n \"<string>\"\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.finhub.cloud/api/v2.1/fincard/virtual/card/v2/update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Forwarded-From"] = '<x-forwarded-from>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"cardId\": \"<string>\",\n \"merchantOrderNo\": \"<string>\",\n \"remark\": \"<string>\",\n \"noPinPaymentAmount\": 123,\n \"spendingControls\": [\n {\n \"interval\": \"<string>\",\n \"amount\": 123,\n \"supportSetting\": true\n }\n ],\n \"riskControls\": {\n \"allowedMcc\": [\n \"<string>\"\n ],\n \"blockedMcc\": [\n \"<string>\"\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"code": 200,
"msg": "Success",
"data": {
"cardId": "card-12345678",
"operationType": "FREEZE",
"operationStatus": "COMPLETED",
"transactionId": "tx-12345678",
"operationTime": 1640995200000,
"newCardStatus": "FROZEN",
"previousCardStatus": "ACTIVE",
"reason": "Customer request"
}
}Headers
User agent
Forwarded for
Client application identifier
Example:
"client-app"
Tenant ID
Device ID
Platform
Body
application/json
Card update request
Card update request
Card ID
Client transaction reference. length[15...65]
Remark. length[0...50]
Password-free payment amount limit (physical card)
Spending controls
Show child attributes
Show child attributes
Risk controls
Show child attributes
Show child attributes
⌘I