curl --request GET \
--url https://api.sandbox.lead.bank/v0/cards/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sandbox.lead.bank/v0/cards/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sandbox.lead.bank/v0/cards/{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.sandbox.lead.bank/v0/cards/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.lead.bank/v0/cards/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.lead.bank/v0/cards/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.lead.bank/v0/cards/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "card_xyz123",
"client_card_id": "<string>",
"account_id": "account_xyz123",
"entity_id": "entity_xyz123",
"status": "active",
"status_reason": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"details": {
"card_product_name": "<string>",
"is_virtual": true,
"card_type": "hsa",
"expiry_date": "2023-12-25",
"last_four": "1234",
"replacement_for": "card_xyz123",
"closed_at": "2023-11-07T05:31:56Z"
},
"metadata": {}
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "rate_limit_exceeded",
"title": "You've reached the rate limit for this call, your request was not processed.",
"detail": "If you are continuously hitting rate limits please contact the Lead team.",
"invalid_parameters": []
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}Retrieve a Card
Beta: This endpoint is in beta and may change before general availability.
Retrieves a specific card by its ID. Accepts either the server-generated
Card ID (card_*) or the client_card_id of a card created via file
upload.
curl --request GET \
--url https://api.sandbox.lead.bank/v0/cards/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sandbox.lead.bank/v0/cards/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sandbox.lead.bank/v0/cards/{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.sandbox.lead.bank/v0/cards/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.lead.bank/v0/cards/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.lead.bank/v0/cards/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.lead.bank/v0/cards/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "card_xyz123",
"client_card_id": "<string>",
"account_id": "account_xyz123",
"entity_id": "entity_xyz123",
"status": "active",
"status_reason": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"details": {
"card_product_name": "<string>",
"is_virtual": true,
"card_type": "hsa",
"expiry_date": "2023-12-25",
"last_four": "1234",
"replacement_for": "card_xyz123",
"closed_at": "2023-11-07T05:31:56Z"
},
"metadata": {}
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}{
"code": "rate_limit_exceeded",
"title": "You've reached the rate limit for this call, your request was not processed.",
"detail": "If you are continuously hitting rate limits please contact the Lead team.",
"invalid_parameters": []
}{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"status": "<string>",
"invalid_parameters": [
{
"parameter": "transaction_type",
"reason": "<string>"
}
],
"instance": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The Card ID. Either the server-generated Card ID (card_*) or the
client_card_id assigned when the card was created via file upload.
Response
Card object retrieved successfully.
A card object
The server-generated ID of the Card object.
^card_\w+$"card_xyz123"
Client-provided identifier for the card. Optional: present only for cards created via file upload, and omitted for cards created through the API, which are identified solely by their server-generated ID.
The ID of the Account object.
^account_\w+$"account_xyz123"
The ID of your entity.
^entity_[^\s]{1,33}$"entity_xyz123"
Status is system-managed and cannot be set on create; status changes go through the status-transition endpoints.
active, inactive, closed The reason for the card's current status. Empty when the card is active; otherwise
populated. Set via the status-transition endpoints.
Creation timestamp.
Last update timestamp.
Physical and product attributes of the card.
Show child attributes
Show child attributes
A set of key-value pairs that can be used to store additional information related to this object.
Show child attributes
Show child attributes
Was this page helpful?

