Activating a card

How to activate a card

Activating a physical card

A physical card is always issued as inactive and must be activated before use.

To activate a card, use the POST /cards/{card_id}/activate operation.

An example of a request to activate a card is shown below.

curl --request POST \
     --url https://sandbox.bond.tech/api/v0.1/cards/c8940088-21e8-451c-987c-0a0398db3ee5/activate \
     --header 'Accept: application/json' \
     --header 'Authorization: YOUR-AUTHENTICATION' \
     --header 'Identity: YOUR-IDENTITY'
require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://sandbox.bond.tech/api/v0.1/cards/c8940088-21e8-451c-987c-0a0398db3ee5/activate")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Accept"] = 'application/json'
request["Identity"] = 'YOUR-IDENTITY'
request["Authorization"] = 'YOUR-AUTHENTICATION'

response = http.request(request)
puts response.read_body
const options = {
  method: 'POST',
  headers: {
    Accept: 'application/json',
    Identity: 'YOUR-IDENTITY',
    Authorization: 'YOUR-AUTHENTICATION'
  }
};

fetch('https://sandbox.bond.tech/api/v0.1/cards/c8940088-21e8-451c-987c-0a0398db3ee5/activate', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
import requests

url = "https://sandbox.bond.tech/api/v0.1/cards/c8940088-21e8-451c-987c-0a0398db3ee5/activate"

headers = {
    "Accept": "application/json",
    "Identity": "YOUR-IDENTITY",
    "Authorization": "YOUR-AUTHENTICATION"
}

response = requests.post(url, headers=headers)

print(response.text)
var client = new RestClient("https://sandbox.bond.tech/api/v0.1/cards/c8940088-21e8-451c-987c-0a0398db3ee5/activate");
var request = new RestRequest(Method.POST);
request.AddHeader("Accept", "application/json");
request.AddHeader("Identity", "YOUR-IDENTITY");
request.AddHeader("Authorization", "YOUR-AUTHENTICATION");
IRestResponse response = client.Execute(request);
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://sandbox.bond.tech/api/v0.1/cards/c8940088-21e8-451c-987c-0a0398db3ee5/activate")
  .post(null)
  .addHeader("Accept", "application/json")
  .addHeader("Identity", "YOUR-IDENTITY")
  .addHeader("Authorization", "YOUR-AUTHENTICATION")
  .build();

Response response = client.newCall(request).execute();

An example of a response to a successful request to activate a card is shown below.

{
  "card_id": "057c6074-a02d-4a5a-bad9-bbc64b047df7",
  "date_updated": "2020-08-16T19:39:34Z",
  "date_created": "2020-08-15T19:39:34Z",
  "customer_id": "c8940088-21e8-451c-987c-0a0398db3ee5",
  "account_id": "26bdeb70-157c-4c44-a04a-3727793b9779",
  "expiry_date": "tok_live_7g3eARzeEBJw89rJRCHqHv",
  "last_four": "6270",
  "card_number": "tok_live_c8940088-21e8-451c-987c-0a0398db3ee5",
  "cvv": "tok_live_26bdeb70-157c-4c44-a04a-3727793b9779",
  "status": "active",
  "card_design_id": "12"
}

For a complete specification and interactive examples, see Activating a card in the Bond API Reference.


Next Steps