Issue a card
curl --request POST \
--url https://api-sandbox.endl.io/api/v0/cards/{cardholderId} \
--header 'Api-Key: <api-key>' \
--header 'Api-Version: <api-version>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"displayName": "Travel",
"controls": {
"spendLimit": {
"amount": {
"amount": "500.00",
"currency": "USD"
},
"period": "month"
}
}
}
'import requests
url = "https://api-sandbox.endl.io/api/v0/cards/{cardholderId}"
payload = {
"displayName": "Travel",
"controls": { "spendLimit": {
"amount": {
"amount": "500.00",
"currency": "USD"
},
"period": "month"
} }
}
headers = {
"Api-Version": "<api-version>",
"Idempotency-Key": "<idempotency-key>",
"Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Api-Version': '<api-version>',
'Idempotency-Key': '<idempotency-key>',
'Api-Key': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
displayName: 'Travel',
controls: {spendLimit: {amount: {amount: '500.00', currency: 'USD'}, period: 'month'}}
})
};
fetch('https://api-sandbox.endl.io/api/v0/cards/{cardholderId}', 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.endl.io/api/v0/cards/{cardholderId}",
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([
'displayName' => 'Travel',
'controls' => [
'spendLimit' => [
'amount' => [
'amount' => '500.00',
'currency' => 'USD'
],
'period' => 'month'
]
]
]),
CURLOPT_HTTPHEADER => [
"Api-Key: <api-key>",
"Api-Version: <api-version>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-sandbox.endl.io/api/v0/cards/{cardholderId}"
payload := strings.NewReader("{\n \"displayName\": \"Travel\",\n \"controls\": {\n \"spendLimit\": {\n \"amount\": {\n \"amount\": \"500.00\",\n \"currency\": \"USD\"\n },\n \"period\": \"month\"\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Api-Version", "<api-version>")
req.Header.Add("Idempotency-Key", "<idempotency-key>")
req.Header.Add("Api-Key", "<api-key>")
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-sandbox.endl.io/api/v0/cards/{cardholderId}")
.header("Api-Version", "<api-version>")
.header("Idempotency-Key", "<idempotency-key>")
.header("Api-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"displayName\": \"Travel\",\n \"controls\": {\n \"spendLimit\": {\n \"amount\": {\n \"amount\": \"500.00\",\n \"currency\": \"USD\"\n },\n \"period\": \"month\"\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-sandbox.endl.io/api/v0/cards/{cardholderId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Api-Version"] = '<api-version>'
request["Idempotency-Key"] = '<idempotency-key>'
request["Api-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"displayName\": \"Travel\",\n \"controls\": {\n \"spendLimit\": {\n \"amount\": {\n \"amount\": \"500.00\",\n \"currency\": \"USD\"\n },\n \"period\": \"month\"\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"cardId": "crd_4fT9kQ2wE8rT5yU1iO7p",
"cardholderId": "cus_8Qw2mZ4pL7nR1tY6vB3x",
"businessId": "cus_1Xb7cV4bN7mQ0wE3rT5y",
"type": "virtual",
"kind": "standard",
"status": "active",
"closedReason": null,
"displayName": "Travel",
"last4": "4242",
"expiryMonth": "08",
"expiryYear": "2029",
"controls": {
"spendLimit": {
"amount": {
"amount": "500.00",
"currency": "USD"
},
"period": "month"
}
},
"usage": {
"spent": {
"amount": "0.00",
"currency": "USD"
},
"period": "month"
},
"singleUse": null,
"createdAt": "2026-11-02T09:12:03Z",
"updatedAt": "2026-11-02T09:12:03Z"
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}Issue a card
Issues a standard virtual card. It spends up to its spend limit, from the funding owner’s card balance, until you freeze or cancel it.
- The cardholder is an enrolled individual, or an active cardholder of an enrolled business. A business itself can’t hold cards (
400 ERRCRD_1016,field: "customerId"). - The response doesn’t include the card number. Call Get card details for that.
- Issuing a card may charge a card issuance fee to the card balance, so the balance can go below zero before the first deposit. See Get card balance.
Other fields are refused with 400 ERRCRD_1016.
POST
/
api
/
v0
/
cards
/
{cardholderId}
Issue a card
curl --request POST \
--url https://api-sandbox.endl.io/api/v0/cards/{cardholderId} \
--header 'Api-Key: <api-key>' \
--header 'Api-Version: <api-version>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"displayName": "Travel",
"controls": {
"spendLimit": {
"amount": {
"amount": "500.00",
"currency": "USD"
},
"period": "month"
}
}
}
'import requests
url = "https://api-sandbox.endl.io/api/v0/cards/{cardholderId}"
payload = {
"displayName": "Travel",
"controls": { "spendLimit": {
"amount": {
"amount": "500.00",
"currency": "USD"
},
"period": "month"
} }
}
headers = {
"Api-Version": "<api-version>",
"Idempotency-Key": "<idempotency-key>",
"Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Api-Version': '<api-version>',
'Idempotency-Key': '<idempotency-key>',
'Api-Key': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
displayName: 'Travel',
controls: {spendLimit: {amount: {amount: '500.00', currency: 'USD'}, period: 'month'}}
})
};
fetch('https://api-sandbox.endl.io/api/v0/cards/{cardholderId}', 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.endl.io/api/v0/cards/{cardholderId}",
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([
'displayName' => 'Travel',
'controls' => [
'spendLimit' => [
'amount' => [
'amount' => '500.00',
'currency' => 'USD'
],
'period' => 'month'
]
]
]),
CURLOPT_HTTPHEADER => [
"Api-Key: <api-key>",
"Api-Version: <api-version>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-sandbox.endl.io/api/v0/cards/{cardholderId}"
payload := strings.NewReader("{\n \"displayName\": \"Travel\",\n \"controls\": {\n \"spendLimit\": {\n \"amount\": {\n \"amount\": \"500.00\",\n \"currency\": \"USD\"\n },\n \"period\": \"month\"\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Api-Version", "<api-version>")
req.Header.Add("Idempotency-Key", "<idempotency-key>")
req.Header.Add("Api-Key", "<api-key>")
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-sandbox.endl.io/api/v0/cards/{cardholderId}")
.header("Api-Version", "<api-version>")
.header("Idempotency-Key", "<idempotency-key>")
.header("Api-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"displayName\": \"Travel\",\n \"controls\": {\n \"spendLimit\": {\n \"amount\": {\n \"amount\": \"500.00\",\n \"currency\": \"USD\"\n },\n \"period\": \"month\"\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-sandbox.endl.io/api/v0/cards/{cardholderId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Api-Version"] = '<api-version>'
request["Idempotency-Key"] = '<idempotency-key>'
request["Api-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"displayName\": \"Travel\",\n \"controls\": {\n \"spendLimit\": {\n \"amount\": {\n \"amount\": \"500.00\",\n \"currency\": \"USD\"\n },\n \"period\": \"month\"\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"cardId": "crd_4fT9kQ2wE8rT5yU1iO7p",
"cardholderId": "cus_8Qw2mZ4pL7nR1tY6vB3x",
"businessId": "cus_1Xb7cV4bN7mQ0wE3rT5y",
"type": "virtual",
"kind": "standard",
"status": "active",
"closedReason": null,
"displayName": "Travel",
"last4": "4242",
"expiryMonth": "08",
"expiryYear": "2029",
"controls": {
"spendLimit": {
"amount": {
"amount": "500.00",
"currency": "USD"
},
"period": "month"
}
},
"usage": {
"spent": {
"amount": "0.00",
"currency": "USD"
},
"period": "month"
},
"singleUse": null,
"createdAt": "2026-11-02T09:12:03Z",
"updatedAt": "2026-11-02T09:12:03Z"
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}{
"code": 123,
"message": "<string>",
"status": "ERROR",
"data": null,
"errors": [
{
"code": "<string>",
"message": "<string>",
"field": "<string>"
}
]
}Headers
The API version this request targets. 2026-09.1. See Versioning.
Pattern:
^\d{4}-\d{2}\.\d+$Path Parameters
Body
application/json
Response
The card. You receive card.created.