SDK reference · Node SDK

prov.authorize.issuer.programs.createCardholderLink

prov.authorize.issuer.programs.createCardholderLink in Node SDK. A one-time link (15 minutes) for a cardholder to add one card; needs cardholder controls on.

Signature

prov.authorize.issuer.programs.createCardholderLink(id: string, params: CreateIssuerCardholderLinkParams): Promise<IssuerCardholderLink>

Parameters

idstringRequired
paramsCreateIssuerCardholderLinkParamsRequired

Request fields

idstringpathRequired
The program's ID (iprg_).
card_tokenstringRequired
The processor's card token (never the card number).
displayobjectRequired
What the person sees: the brand and last four.
Show child attributes
brandenumRequired
The card's brand. One of visa, mastercard, amex, discover, jcb, unionpay, diners, other.
last4stringRequired
The card's last four digits.
cardholderobject
Display only: the cardholder's name as you hold it ("Maya Chen"). Your card limit reads for this card return it as cardholder.name; it is shown only to you.
Show child attributes
namestring
One line of 1 to 100 characters.

Returns

Promise<IssuerCardholderLink> The link.

HTTP operation

POST /v1/authorize/issuer_programs/{id}/cardholder_links: Create a cardholder link

Errors

Example

const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/authorize/issuer_programs`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_ent_E7nT2vQ9bW4mK8sYd3cFjLh6gAe1pR5x", "Content-Type": "application/json" },
  body: JSON.stringify({ "name": "Fernhill agent cards", "processor": "lithic" }),
})).json();
const program = step1.id;
const step2 = await (await fetch(`${process.env.PROVENANCE_API}/v1/authorize/issuer_programs/${program}/cardholder_controls`, {
  method: "PUT",
  headers: { Authorization: "Bearer prv_test_ent_E7nT2vQ9bW4mK8sYd3cFjLh6gAe1pR5x", "Content-Type": "application/json" },
  body: JSON.stringify({ "enabled": true, "max_cap": 20000 }),
})).json();
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/authorize/issuer_programs/${program}/cardholder_links`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_ent_E7nT2vQ9bW4mK8sYd3cFjLh6gAe1pR5x", "Content-Type": "application/json" },
  body: JSON.stringify({
    "card_token": "card_tok_9f2c",
    "display": {
      "brand": "visa",
      "last4": "4242"
    },
    "cardholder": {
      "name": "Maya Chen"
    }
  }),
})).json();

Was this page helpful? Send us feedback

LLM? Read llms.txt.