开设银行账户
curl --request POST \
--url https://api.qbank.cl/platform/v1/banking/accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"currency": "USD",
"name": "Operating USD"
}
'import requests
url = "https://api.qbank.cl/platform/v1/banking/accounts"
payload = {
"currency": "USD",
"name": "Operating USD"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({currency: 'USD', name: 'Operating USD'})
};
fetch('https://api.qbank.cl/platform/v1/banking/accounts', 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.qbank.cl/platform/v1/banking/accounts",
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([
'currency' => 'USD',
'name' => 'Operating USD'
]),
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.qbank.cl/platform/v1/banking/accounts"
payload := strings.NewReader("{\n \"currency\": \"USD\",\n \"name\": \"Operating USD\"\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.qbank.cl/platform/v1/banking/accounts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"currency\": \"USD\",\n \"name\": \"Operating USD\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.qbank.cl/platform/v1/banking/accounts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"currency\": \"USD\",\n \"name\": \"Operating USD\"\n}"
response = http.request(request)
puts response.read_body{
"account_id": "c4d1e2f3-a4b5-c6d7-e8f9-a0b1c2d3e4f5",
"provider_id": "BNK-ACC-4471",
"status": "active",
"data": {
"currency": "USD",
"name": "Operating USD",
"accountNumber": "0532013000",
"routingNumber": 11000138
},
"banking_fee": "1.000000"
}{
"error": "unauthorized",
"message": "invalid or missing credentials"
}{
"error": "insufficient_funds",
"message": "account balance is not enough for this operation"
}{
"error": "no_banking_customer",
"message": "create your banking customer first (POST /v1/banking/customer)"
}{
"error": {
"code": "banking_request_failed",
"message": "request rejected"
}
}开设银行账户
为已通过审核的档案开设银行账户(按启用情况每种货币一个)。按固定 banking_account 费用计费;若通道拒绝则退款。data 携带收款详情(账号/IBAN、routing、银行)。
POST
/
v1
/
banking
/
accounts
开设银行账户
curl --request POST \
--url https://api.qbank.cl/platform/v1/banking/accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"currency": "USD",
"name": "Operating USD"
}
'import requests
url = "https://api.qbank.cl/platform/v1/banking/accounts"
payload = {
"currency": "USD",
"name": "Operating USD"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({currency: 'USD', name: 'Operating USD'})
};
fetch('https://api.qbank.cl/platform/v1/banking/accounts', 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.qbank.cl/platform/v1/banking/accounts",
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([
'currency' => 'USD',
'name' => 'Operating USD'
]),
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.qbank.cl/platform/v1/banking/accounts"
payload := strings.NewReader("{\n \"currency\": \"USD\",\n \"name\": \"Operating USD\"\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.qbank.cl/platform/v1/banking/accounts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"currency\": \"USD\",\n \"name\": \"Operating USD\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.qbank.cl/platform/v1/banking/accounts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"currency\": \"USD\",\n \"name\": \"Operating USD\"\n}"
response = http.request(request)
puts response.read_body{
"account_id": "c4d1e2f3-a4b5-c6d7-e8f9-a0b1c2d3e4f5",
"provider_id": "BNK-ACC-4471",
"status": "active",
"data": {
"currency": "USD",
"name": "Operating USD",
"accountNumber": "0532013000",
"routingNumber": 11000138
},
"banking_fee": "1.000000"
}{
"error": "unauthorized",
"message": "invalid or missing credentials"
}{
"error": "insufficient_funds",
"message": "account balance is not enough for this operation"
}{
"error": "no_banking_customer",
"message": "create your banking customer first (POST /v1/banking/customer)"
}{
"error": {
"code": "banking_request_failed",
"message": "request rejected"
}
}最后修改于 2026年7月19日
⌘I