Gravv
/Docs
Search docs or ask a question⌘K
DocsAgent
ChangelogTry sandbox
Recipes Card issuing Issue a business card

Issue a business card

In sandbox, issue a card printed with a business customer's name to one of its associated persons.

4 min read

Use this recipe in sandbox to issue a card printed with a business customer's name to one of the business's associated persons.

Who it is for. This recipe is for an expense platform whose client company wants its name printed on staff cards.

Status. Available in sandbox only. Not yet available in live. Contact support before you offer business cards.

Money example

The card shows the business name "Northwind Logistics".

1.
Jane, the finance lead, gets a card.
2.
You move 1,000 USD from the company account to the card.
3.
Jane pays a 240 USD software invoice. The card now holds 760 USD.

Before you start

KYB is KYC for a business, which checks the company and its people. See the Glossary.

PrerequisiteHow to check
A business customer with a business_nameGET /v1/customers/{customer_id} on the business shows type business
The business finished KYBThe business's basic KYC is completed
The cardholder is one of the business's associated persons and is verifiedThe person is in associated_persons[].id, and that person's basic KYC is completed
Your card accountSee the hosted-check recipe
The person has no card application yetGET /v1/cards?customer_id=… returns nothing

Find out what is required

GET /v1/customers/{customer_id} on the business returns the business name, its KYB status and its associated persons. If one of them is missing, the application call names it.

Steps

1. Open the business card application

cURLNodePython
curl --request POST \
--url https://api.gravv.xyz/v1/cards/applications/new \
--header 'Api-Key: <API_KEY>' \
--header 'Idempotency-Key: 19781350-fe75-4ff1-a062-47c62eb6352f' \
--header 'Content-Type: application/json' \
--data '
{
"type": "business",
"customer_id": "9e8d7c6b-5a49-4382-a1b0-c9d8e7f6a5b4",
"business_customer_id": "0d6c2f4e-6a1b-4f0e-9b8f-5c2a7d3e1f00",
"account_id": "9b40be8d-9d74-4d2a-8897-dea3ef80ad23",
"annual_remuneration": 60000,
"estimated_monthly_limit": 3000,
"ip_address": "203.0.113.24"
}
'
Response
{
"data": {
"message": "Card application request successful",
"status": true,
"id": "b25fd467-a44e-4495-8b79-5e0cab2a876c"
},
"error": null
}

Set customer_id to the person and business_customer_id to the business. estimated_monthly_limit must not be above annual_remuneration. ip_address is the cardholder's IP address.

2. Check approval

List the applications with GET /v1/cards/applications. The item with this id shows application_status approved. Sandbox approves applications at once.

3. Issue the card

cURLNodePython
curl --request POST \
--url https://api.gravv.xyz/v1/cards \
--header 'Api-Key: <API_KEY>' \
--header 'Idempotency-Key: 368f9b5b-3958-4de3-87c7-ea03e27a5165' \
--header 'Content-Type: application/json' \
--data '
{
"customer_id": "9e8d7c6b-5a49-4382-a1b0-c9d8e7f6a5b4",
"card_type": "virtual",
"card_limit": 500,
"name_on_card": "Jane Doe"
}
'

The first card's id is the application id. Next, top up the card.

What can go wrong

Response (HTTP 400)WhyFix
a business customer cannot hold a card; apply with type "business" for one of its associated personscustomer_id is the businessSend the person as customer_id and the business as business_customer_id
an associated person's card must be a business card; apply with type "business" and their business_customer_idThe request has no typeAdd "type": "business"
business_customer_id is required when type is "business"business_customer_id is missingSend it
the business must complete KYB before cards can be issued under itThe business is not verifiedFinish KYB
the business has no business_name to print on its cardsThe business has no business_nameUpdate the business
customer_id is not an associated person of this businessThe person is not linked to the businessAdd the person to the business
basic level kyc needs to be completed to create an applicationThe person is not verified. The API checks this firstVerify the person
estimated_monthly_limit must be lesser than annual_renumerationestimated_monthly_limit is above annual_remunerationLower estimated_monthly_limit
200 with an application that has no messageThe person already has a card application, and the API returns it unchangedUse a person with no application yet

Webhooks you will receive

Gravv sends no webhook when the application opens in sandbox. For funding and card events, see Top up a card.

Testing in sandbox

This recipe runs in sandbox. Sandbox completes the associated person's KYC about 3 minutes after their hosted check, so verify them first, and use a person with no card application.

Reference

Was this page helpful? Yes No