Funding your account

An overview of ways to pay.

To place an order via the API, you need to specify a funding source, which represents a way to fund that order.

There are four different funding sources, with differing levels of availability via API:

Funding sourceAvailability
Balance:white-check-mark:
Commercial invoicingEnterprise-only. Contact sales / account rep for details
Bank accountEnterprise-only. Contact sales / account rep for details
Credit card:x:

Funding sources

Balance

Your Tremendous balance gets debited for each order you place. This is the standard way to pay for orders via API.

You can look up the funds available in your balance by logging in via the UI, and going to Billing β†’ Account balance.

You can also do so programmatically by querying the funding sources endpoint:

curl --url 'https://testflight.tremendous.com/api/v2/funding_sources' \
     --header 'Authorization: Bearer YOUR-API-KEY'
{
  "funding_sources": [
    {
      "method": "balance",
      "id": "GCTHLCMFVYMD",
      "meta": {
        "available_cents": 600000,
        "pending_cents": 0
      }
    }
  ]
}

You can fund your balance with an ACH deposit, wire, or a credit card. Log into the Tremendous UI in order to make a deposit.

Commercial invoicing

With commercial invoicing, you'll be invoiced on a regular schedule for rewards sent. Commercial invoices can be auto-debited from a bank account via ACH.

πŸ“˜

Contact sales to discuss commercial invoicing

Commercial invoicing is only available in special situations. If you're interested in setting this up, please speak to our sales team. The option will only show up in your funding sources if it is enabled by a Tremendous admin.

Bank account

Bank accounts, by default, are not available for use in the API, and will not show up in Funding sources.

Individual bank accounts can be approved for use via the API. Please contact your account representative to discuss bank account funding.

Credit card

Credit cards are not available for use in the API, and will not show up in Funding sources.

Each order placed via API would result in a separate credit card charge. API integrations frequently create large numbers of orders, resulting in large numbers of charges. Unfortunately, credit card companies will typically flag and block these transactions.

Specifying a funding source

To change the funding source used in an order, query the Funding sources resource to find the ID of the funding source:

curl --url 'https://testflight.tremendous.com/api/v2/funding_sources' \
     --header 'Authorization: Bearer YOUR-API-KEY'
{
  "funding_sources": [
    {
      "method": "balance",
      "id": "GCTHLCMFVYMD",
      "meta": {
        "available_cents": 600000,
        "pending_cents": 0
      }
    },
    {
      "method": "invoice",
      "type": "COMMERCIAL",
      "id": "4G1IPSQINMMV"
    }
  ]
}

Then use that id as the funding_source_id in your API call to /api/v2/orders:

curl --url 'https://testflight.tremendous.com/api/v2/orders' \
     --header 'Authorization: Bearer YOUR-API-KEY' \
     --header 'Content-Type: application/json' \
     --data '
{
     "payment": {
          "funding_source_id": "YOUR-SELECTED-SOURCE-ID"
     },
     "rewards": [
          {
               "value": {
                    "denomination": 50.00
               },
               "delivery": {
                    "method": "EMAIL"
               },
               "recipient": {
                    "name": "Jane Doe",
                    "email": "[email protected]"
               },
               "products": [
                    "OKMHM2X2OHYV"
               ]
          }
     ]
}
'