Approve payment consent
curl --request POST \
--url https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--header 'X-Device-Fingerprint: <x-device-fingerprint>' \
--header 'X-Device-Type: <x-device-type>' \
--header 'X-Forwarded-For: <x-forwarded-for>' \
--header 'X-Forwarded-From: <x-forwarded-from>' \
--header 'X-Tenant-ID: <x-tenant-id>' \
--header 'deviceId: <deviceid>' \
--header 'platform: <platform>' \
--data '{}'import requests
url = "https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve"
payload = {}
headers = {
"X-Device-Fingerprint": "<x-device-fingerprint>",
"X-Device-Type": "<x-device-type>",
"X-Forwarded-For": "<x-forwarded-for>",
"X-Tenant-ID": "<x-tenant-id>",
"X-Forwarded-From": "<x-forwarded-from>",
"platform": "<platform>",
"deviceId": "<deviceid>",
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Device-Fingerprint': '<x-device-fingerprint>',
'X-Device-Type': '<x-device-type>',
'X-Forwarded-For': '<x-forwarded-for>',
'X-Tenant-ID': '<x-tenant-id>',
'X-Forwarded-From': '<x-forwarded-from>',
platform: '<platform>',
deviceId: '<deviceid>',
Authorization: '<authorization>',
'Content-Type': 'application/json'
},
body: JSON.stringify({})
};
fetch('https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve', 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/consents/{consentId}/approve",
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([
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json",
"X-Device-Fingerprint: <x-device-fingerprint>",
"X-Device-Type: <x-device-type>",
"X-Forwarded-For: <x-forwarded-for>",
"X-Forwarded-From: <x-forwarded-from>",
"X-Tenant-ID: <x-tenant-id>",
"deviceId: <deviceid>",
"platform: <platform>"
],
]);
$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/consents/{consentId}/approve"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Device-Fingerprint", "<x-device-fingerprint>")
req.Header.Add("X-Device-Type", "<x-device-type>")
req.Header.Add("X-Forwarded-For", "<x-forwarded-for>")
req.Header.Add("X-Tenant-ID", "<x-tenant-id>")
req.Header.Add("X-Forwarded-From", "<x-forwarded-from>")
req.Header.Add("platform", "<platform>")
req.Header.Add("deviceId", "<deviceid>")
req.Header.Add("Authorization", "<authorization>")
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/consents/{consentId}/approve")
.header("X-Device-Fingerprint", "<x-device-fingerprint>")
.header("X-Device-Type", "<x-device-type>")
.header("X-Forwarded-For", "<x-forwarded-for>")
.header("X-Tenant-ID", "<x-tenant-id>")
.header("X-Forwarded-From", "<x-forwarded-from>")
.header("platform", "<platform>")
.header("deviceId", "<deviceid>")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Device-Fingerprint"] = '<x-device-fingerprint>'
request["X-Device-Type"] = '<x-device-type>'
request["X-Forwarded-For"] = '<x-forwarded-for>'
request["X-Tenant-ID"] = '<x-tenant-id>'
request["X-Forwarded-From"] = '<x-forwarded-from>'
request["platform"] = '<platform>'
request["deviceId"] = '<deviceid>'
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_bodyFinancial Operations
Approve payment consent
Approves a consent via AML Gateway for payment order wizard step 7
POST
/
api
/
v2.1
/
consents
/
{consentId}
/
approve
Approve payment consent
curl --request POST \
--url https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--header 'X-Device-Fingerprint: <x-device-fingerprint>' \
--header 'X-Device-Type: <x-device-type>' \
--header 'X-Forwarded-For: <x-forwarded-for>' \
--header 'X-Forwarded-From: <x-forwarded-from>' \
--header 'X-Tenant-ID: <x-tenant-id>' \
--header 'deviceId: <deviceid>' \
--header 'platform: <platform>' \
--data '{}'import requests
url = "https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve"
payload = {}
headers = {
"X-Device-Fingerprint": "<x-device-fingerprint>",
"X-Device-Type": "<x-device-type>",
"X-Forwarded-For": "<x-forwarded-for>",
"X-Tenant-ID": "<x-tenant-id>",
"X-Forwarded-From": "<x-forwarded-from>",
"platform": "<platform>",
"deviceId": "<deviceid>",
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Device-Fingerprint': '<x-device-fingerprint>',
'X-Device-Type': '<x-device-type>',
'X-Forwarded-For': '<x-forwarded-for>',
'X-Tenant-ID': '<x-tenant-id>',
'X-Forwarded-From': '<x-forwarded-from>',
platform: '<platform>',
deviceId: '<deviceid>',
Authorization: '<authorization>',
'Content-Type': 'application/json'
},
body: JSON.stringify({})
};
fetch('https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve', 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/consents/{consentId}/approve",
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([
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json",
"X-Device-Fingerprint: <x-device-fingerprint>",
"X-Device-Type: <x-device-type>",
"X-Forwarded-For: <x-forwarded-for>",
"X-Forwarded-From: <x-forwarded-from>",
"X-Tenant-ID: <x-tenant-id>",
"deviceId: <deviceid>",
"platform: <platform>"
],
]);
$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/consents/{consentId}/approve"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Device-Fingerprint", "<x-device-fingerprint>")
req.Header.Add("X-Device-Type", "<x-device-type>")
req.Header.Add("X-Forwarded-For", "<x-forwarded-for>")
req.Header.Add("X-Tenant-ID", "<x-tenant-id>")
req.Header.Add("X-Forwarded-From", "<x-forwarded-from>")
req.Header.Add("platform", "<platform>")
req.Header.Add("deviceId", "<deviceid>")
req.Header.Add("Authorization", "<authorization>")
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/consents/{consentId}/approve")
.header("X-Device-Fingerprint", "<x-device-fingerprint>")
.header("X-Device-Type", "<x-device-type>")
.header("X-Forwarded-For", "<x-forwarded-for>")
.header("X-Tenant-ID", "<x-tenant-id>")
.header("X-Forwarded-From", "<x-forwarded-from>")
.header("platform", "<platform>")
.header("deviceId", "<deviceid>")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.finhub.cloud/api/v2.1/consents/{consentId}/approve")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Device-Fingerprint"] = '<x-device-fingerprint>'
request["X-Device-Type"] = '<x-device-type>'
request["X-Forwarded-For"] = '<x-forwarded-for>'
request["X-Tenant-ID"] = '<x-tenant-id>'
request["X-Forwarded-From"] = '<x-forwarded-from>'
request["platform"] = '<platform>'
request["deviceId"] = '<deviceid>'
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_bodyHeaders
Example:
"127.0.0.1"
Example:
"tenant-demo-001"
Client source identifier
Example:
"client-app"
Client platform
Example:
"mobile"
Device identifier
Example:
"device-demo-001"
Bearer JWT
Example:
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJkZW1vLXVzZXIifQ.demo-signature"
Path Parameters
Example:
"00000000-0000-0000-0000-000000000000"
Body
application/json
Response
200
OK
⌘I