delphiAx / Bond APIs / Generate Plaid Link Token
Back to Collection Items
var
http: TChilkatHttp;
success: Integer;
sbResponseBody: TChilkatStringBuilder;
begin
// This example assumes the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.
http := TChilkatHttp.Create(Self);
http.SetRequestHeader('Identity','{{identity}}');
http.SetRequestHeader('Authorization','{{authorization}}');
sbResponseBody := TChilkatStringBuilder.Create(Self);
success := http.QuickGetSb('https://{{environment}}.bond.tech/api/v0/accounts/:account_id/external_accounts/plaid',sbResponseBody.ControlInterface);
if (success = 0) then
begin
Memo1.Lines.Add(http.LastErrorText);
Exit;
end;
Memo1.Lines.Add('Response status code = ' + IntToStr(http.LastStatus));
Memo1.Lines.Add(sbResponseBody.GetAsString());
Curl Command
curl -X GET
-H "Identity: {{identity}}"
-H "Authorization: {{authorization}}"
https://{{environment}}.bond.tech/api/v0/accounts/:account_id/external_accounts/plaid
Postman Collection Item JSON
{
"name": "Generate Plaid Link Token",
"protocolProfileBehavior": {
"disableBodyPruning": true
},
"request": {
"method": "GET",
"header": [
{
"key": "Identity",
"value": "{{identity}}",
"type": "text"
},
{
"key": "Authorization",
"value": "{{authorization}}",
"type": "text"
}
],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{environment}}.bond.tech/api/v0/accounts/:account_id/external_accounts/plaid",
"protocol": "https",
"host": [
"{{environment}}",
"bond",
"tech"
],
"path": [
"api",
"v0",
"accounts",
":account_id",
"external_accounts",
"plaid"
],
"variable": [
{
"key": "account_id",
"value": ""
}
]
}
},
"response": [
{
"name": "example",
"originalRequest": {
"method": "GET",
"header": [
{
"key": "Identity",
"value": "{{identity}}",
"type": "text"
},
{
"key": "Authorization",
"value": "{{authorization}}",
"type": "text"
}
],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://sandbox.bond.tech/api/v0/accounts/:account_id/external_accounts/plaid",
"protocol": "https",
"host": [
"sandbox",
"bond",
"tech"
],
"path": [
"api",
"v0",
"accounts",
":account_id",
"external_accounts",
"plaid"
],
"variable": [
{
"key": "account_id",
"value": ""
}
]
}
},
"_postman_previewlanguage": "json",
"header": null,
"cookie": [
],
"body": "{\n \"linked_account_id\": \"1a130d45-3dc3-4c58-b0d8-9784aae0d009\",\n \"status\": \"inactive\",\n \"link_token\": \"link-sandbox-09fa148c-497a-4a22-87c9-581a7dea46de\",\n \"expiration\": \"2021-01-27T23:29:06Z\"\n}"
}
]
}