JavaScript
import HenrySDK from '@henrylabs/sdk';
const client = new HenrySDK({
apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted
});
const card = await client.card.retrieve('card_live_abc123xyz');
console.log(card.data);curl --request GET \
--url https://api.henrylabs.ai/v1/card/{cardToken} \
--header 'x-api-key: <api-key>'import requests
url = "https://api.henrylabs.ai/v1/card/{cardToken}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.henrylabs.ai/v1/card/{cardToken}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.henrylabs.ai/v1/card/{cardToken}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.henrylabs.ai/v1/card/{cardToken}")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.henrylabs.ai/v1/card/{cardToken}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": true,
"status": "<string>",
"message": "<string>",
"data": {
"cardToken": "card_live_abc123xyz",
"cardBin": "424242",
"cardLast4": "4242",
"cardBrand": "visa",
"capCents": 5000,
"expiresAt": "2026-09-29T00:00:00.000Z",
"state": "OPEN",
"closedAt": "<string>",
"charge": {
"status": "ok",
"charged": true,
"approved": true,
"count": 4503599627370495,
"reason": "<string>"
}
}
}{
"success": true,
"status": "<string>",
"message": "<string>"
}{
"success": true,
"status": "<string>",
"message": "<string>"
}{
"success": true,
"status": "<string>",
"message": "<string>"
}Card
Card Get (Beta)
Beta. Card issuance is in beta and enabled per account. Contact support@henrylabs.ai to request access; until then this endpoint returns 403.
Read an issued card: its cap, expiry, live state at the issuer, and what has been charged to it so far. Only cards issued to your app via POST /card/issue are readable — a tokenized customer card 404s.
GET
/
card
/
{cardToken}
JavaScript
import HenrySDK from '@henrylabs/sdk';
const client = new HenrySDK({
apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted
});
const card = await client.card.retrieve('card_live_abc123xyz');
console.log(card.data);curl --request GET \
--url https://api.henrylabs.ai/v1/card/{cardToken} \
--header 'x-api-key: <api-key>'import requests
url = "https://api.henrylabs.ai/v1/card/{cardToken}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.henrylabs.ai/v1/card/{cardToken}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.henrylabs.ai/v1/card/{cardToken}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.henrylabs.ai/v1/card/{cardToken}")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.henrylabs.ai/v1/card/{cardToken}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": true,
"status": "<string>",
"message": "<string>",
"data": {
"cardToken": "card_live_abc123xyz",
"cardBin": "424242",
"cardLast4": "4242",
"cardBrand": "visa",
"capCents": 5000,
"expiresAt": "2026-09-29T00:00:00.000Z",
"state": "OPEN",
"closedAt": "<string>",
"charge": {
"status": "ok",
"charged": true,
"approved": true,
"count": 4503599627370495,
"reason": "<string>"
}
}
}{
"success": true,
"status": "<string>",
"message": "<string>"
}{
"success": true,
"status": "<string>",
"message": "<string>"
}{
"success": true,
"status": "<string>",
"message": "<string>"
}Was this page helpful?
⌘I