Payments API (1.0)

Download OpenAPI specification:Download

The payments API allows you to initiate and manage payments and vendors from your Brex Cash accounts.

Vendors

Endpoints to manage vendors

Lists vendors

This endpoint lists all existing vendors for an account. Takes an optional parameter to match by vendor name.

Security
Request
query Parameters
cursor
string or null
limit
integer or null <int32>
name
string or null
Responses
200

listVendors 200 response

400

Bad request

401

Unauthorized

403

Forbidden

get/v1/vendors
Request samples
Response samples
application/json
{
  • "next_cursor": "string",
  • "items": [
    ]
}

Create vendor

This endpoint creates a new vendor.

Security
Request
header Parameters
Idempotency-Key
required
string
Request Body schema: application/json
company_name
required
string

Name for vendor. The name must be unique.

email
string or null <email>

Email for vendor.

phone
string or null

Phone number for vendor.

Array of objects or null (PaymentAccountRequest)

Payment accounts associated with the vendor.

Responses
200

createVendor 200 response

post/v1/vendors
Request samples
application/json
{
  • "company_name": "string",
  • "email": "user@example.com",
  • "phone": "string",
  • "payment_accounts": [
    ]
}
Response samples
application/json
{
  • "id": "string",
  • "company_name": "string",
  • "email": "string",
  • "phone": "string",
  • "payment_accounts": [
    ]
}

Get vendor

This endpoint gets a vendor by ID.

Security
Request
path Parameters
id
required
string
Responses
200

getVendorById 200 response

400

Bad request

401

Unauthorized

403

Forbidden

500

Internal server error

get/v1/vendors/{id}
Request samples
Response samples
application/json
{
  • "id": "string",
  • "company_name": "string",
  • "email": "string",
  • "phone": "string",
  • "payment_accounts": [
    ]
}

Update vendor

Updates an existing vendor by ID.
Security
Request
path Parameters
id
required
string
header Parameters
Idempotency-Key
string or null
Request Body schema: application/json
company_name
string or null

Name for vendor

email
string or null <email>

Email for vendor

phone
string or null

Phone number for vendor

Array of objects or null (PaymentAccountRequest)

To update payment instruments, we require the entire payload for each payment instrument that is being updated.

Responses
200

updateVendor 200 response

put/v1/vendors/{id}
Request samples
application/json
{
  • "company_name": "string",
  • "email": "user@example.com",
  • "phone": "string",
  • "payment_accounts": [
    ]
}
Response samples
application/json
{
  • "id": "string",
  • "company_name": "string",
  • "email": "string",
  • "phone": "string",
  • "payment_accounts": [
    ]
}

Delete vendor.

This endpoint deletes a vendor by ID.

Security
Request
path Parameters
id
required
string
Responses
200

deleteVendor 200 response

delete/v1/vendors/{id}
Request samples

Transfers

Endpoints to initiate transfers and view transfer statuses. Note that for all transfer endpoints, the 'money' field is positive or unsigned for outgoing transfers (debits), and negative for incoming transfers (credits).

Create incoming transfer

This endpoint creates a new incoming transfer. You may use use any eligible bank account connection to fund (ACH Debit) any active Brex cash account.

Reminder: You may not use the Brex API for any activity that requires a license or registration from any governmental authority without Brex's prior review and approval. This includes but is not limited to any money services business or money transmission activity.

Please review the Brex Access Agreement and contact us if you have any questions.

Security
Request
header Parameters
Idempotency-Key
required
string
Request Body schema: application/json
required
object (CounterPartyIncomingTransfer)

Counterparty Details for the transfer

required
object (ReceivingAccount)

Receiving account details for the transfer

required
object (Money)

Money fields can be signed or unsigned. Fields are signed (an unsigned value will be interpreted as positive). The amount of money will be represented in the smallest denomination of the currency indicated. For example, USD 7.00 will be represented in cents with an amount of 700.

description
required
string

Description of the transfer for internal use. Not exposed externally.

Responses
200

createIncomingTransfer 200 response

post/v1/incoming_transfers
Request samples
application/json
{
  • "counterparty": {
    },
  • "receiving_account": {
    },
  • "amount": {
    },
  • "description": "string"
}
Response samples
application/json
{
  • "id": "string",
  • "counterparty": {
    },
  • "description": "string",
  • "payment_type": "ACH",
  • "amount": {
    },
  • "process_date": "2019-08-24",
  • "originating_account": {
    },
  • "status": "PROCESSING",
  • "cancellation_reason": "USER_CANCELLED",
  • "estimated_delivery_date": "2019-08-24",
  • "creator_user_id": "string",
  • "created_at": "2019-08-24",
  • "display_name": "string",
  • "external_memo": "string"
}

Lists transfers

This endpoint lists existing transfers for an account.

Currently, the API can only return transfers for the following payment rails:

  • ACH
  • DOMESTIC_WIRE
  • CHEQUE
  • INTERNATIONAL_WIRE
Security
Request
query Parameters
cursor
string or null
limit
integer or null <int32>
Responses
200

listTransfers 200 response

400

Bad request

401

Unauthorized

403

Forbidden

500

Internal server error

get/v1/transfers
Request samples
Response samples
application/json
{
  • "next_cursor": "string",
  • "items": [
    ]
}

Create transfer

This endpoint creates a new transfer.

Currently, the API can only create transfers for the following payment rails:

  • ACH
  • DOMESTIC_WIRE
  • CHEQUE
  • INTERNATIONAL_WIRES (For vendors already created through dashboard. Rate limited to 100/day - Please reach out to developer-support@brex.com if you need to do more)

Transaction Descriptions

  • For outgoing check payments, a successful transfer will return a response containing a description value with a format of Check #<check number> to <recipient_name> - <external_memo>.
  • For book transfers (from one Brex Cash account to another), the recipient value will have a format of <customer_account.dba_name> - <external_memo> and the sender will have a format of <target customer account's dba name> - <external_memo>.
  • For other payment rails, the format will be <counterparty_name> - <external_memo>, where Counterparty name is payment_instrument.beneficiary_name or contact.name For vendors created from the Payments API, the counterparty_name will be the company_name field.

Reminder: You may not use the Brex API for any activity that requires a license or registration from any governmental authority without Brex's prior review and approval. This includes but is not limited to any money services business or money transmission activity.

Please review the Brex Access Agreement and contact us if you have any questions.

Security
Request
header Parameters
Idempotency-Key
required
string
Request Body schema: application/json
required
object (CounterParty)

Counterparty Details for the transfer

required
object (Money)

Money fields can be signed or unsigned. Fields are signed (an unsigned value will be interpreted as positive). The amount of money will be represented in the smallest denomination of the currency indicated. For example, USD 7.00 will be represented in cents with an amount of 700.

description
required
string

Description of the transfer for internal use. Not exposed externally.

external_memo
required
string <= 90 characters

External memo for the transfer. Payment Instructions for Wires and the Entry Description for ACH payments. Must be at most 90 characters for ACH and WIRE transactions and at most 40 characters for CHEQUES

required
object (OriginatingAccount)

Originating account details for the transfer

approval_type
string or null

Specifies the approval type for the transaction. MANUAL requires a cash admin to approve the transaction before disbursing funds. When not set, the default policy will apply.

Value: "MANUAL"
Responses
200

createTransfer 200 response

post/v1/transfers
Request samples
application/json
{
  • "counterparty": {
    },
  • "amount": {
    },
  • "description": "string",
  • "external_memo": "string",
  • "originating_account": {
    },
  • "approval_type": "MANUAL"
}
Response samples
application/json
{
  • "id": "string",
  • "counterparty": {
    },
  • "description": "string",
  • "payment_type": "ACH",
  • "amount": {
    },
  • "process_date": "2019-08-24",
  • "originating_account": {
    },
  • "status": "PROCESSING",
  • "cancellation_reason": "USER_CANCELLED",
  • "estimated_delivery_date": "2019-08-24",
  • "creator_user_id": "string",
  • "created_at": "2019-08-24",
  • "display_name": "string",
  • "external_memo": "string"
}

Get transfer

This endpoint gets a transfer by ID.

Security
Request
path Parameters
id
required
string
Responses
200

getTransfersById 200 response

400

Bad request

401

Unauthorized

403

Forbidden

500

Internal server error

get/v1/transfers/{id}
Request samples
Response samples
application/json
{
  • "id": "string",
  • "counterparty": {
    },
  • "description": "string",
  • "payment_type": "ACH",
  • "amount": {
    },
  • "process_date": "2019-08-24",
  • "originating_account": {
    },
  • "status": "PROCESSING",
  • "cancellation_reason": "USER_CANCELLED",
  • "estimated_delivery_date": "2019-08-24",
  • "creator_user_id": "string",
  • "created_at": "2019-08-24",
  • "display_name": "string",
  • "external_memo": "string"
}

Linked Accounts

Endpoint to view connected linked accounts

Lists linked accounts

This endpoint lists all bank connections that are eligible to make ACH transfers to Brex cash account

Security
Request
query Parameters
cursor
string or null
limit
integer or null <int32>
Responses
200

listLinkedAccounts 200 response

400

Bad request

401

Unauthorized

403

Forbidden

get/v1/linked_accounts
Request samples
Response samples
application/json
{
  • "next_cursor": "string",
  • "items": [
    ]
}
Copyright © Brex 2019–2022. All rights reserved.