Tremendous

Gift cards and payouts platform

developers.tremendous.com ↗
Version
2
OpenAPI
3.0.2
Endpoints
36
Schemas
228
87
Quality
Updated
3 days ago
Payments payments gift-cards rewards
Use this API in your AI agent

Query structured spec data via REST or MCP. Get exactly what your agent needs.

Get API Key

Server URLs

https://testflight.tremendous.com/api/v2
https://www.tremendous.com/api/v2

Endpoints

Clear filters

Invoices 1 endpoints

POST /invoices

Creating an invoice is the way for your organization to fund your account’s balance.

  1. Create an invoice
  2. Pay the invoice
  3. Funds get added to your account’s balance

Request body

Property Type Description
po_number
string

Reference to the purchase order number within your organization

amount
number double

Amount of the invoice in USD

memo
string

A note to be included in the invoice. This is for your internal use and will not be visible to the recipient.

operationId: Invoices_createAndFundAccountBalance

Request Body

required

Invoice details

application/json
schema InvoicesCreateAndFundAccountBalanceRequest
Property Type Required
memo string optional
amount number required
po_number string optional

Responses

200

An invoice (to be overwritten in specific reponses)

400

The invoice couldn’t be created

401

Authorization error e.g. due to an invalid or missing API key.

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /invoices

Members 1 endpoints

POST /members

Each organization has one or more users that can access and manage that organization. These users are called members.

Members can take actions via the Tremendous web dashboard directly. These actions include adding funding sources to the organization, creating Campaigns, and more.

Permissions

Members can have one of two roles that determine their permissions within the organization:

  1. MEMBER: Limited permissions. Can view their own reward and order histories only.
  2. ADMIN: Update organization settings, invite other members to the organization, and view all member order and reward histories within their organization.

To create members of a sub-organizations create an API key for that organization first, then use the new API key in the create member request.

Inviting new members

After creating a member, an automatic invite is sent to the email address. If the user is not registered yet, that person will then need to sign up for a Tremendous account.

❗️ Automatic invitations are not available in the sandbox

You must manually use the returned invite_url field in the payload instead.

operationId: Members_createNewMember

Request Body

required

Member details

application/json
schema MembersCreateNewMemberRequest
Property Type Required
name string required
role string required
email string required

Responses

200

A member (to be overwritten in specific responses)

400

Validation error of the sent parameters or request body

401

Authorization error e.g. due to an invalid or missing API key.

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /members

Orders 3 endpoints

POST /orders

Every time you want to send out a reward through Tremendous you need to create an order for it.

📘 Getting started with your first order

Our step-by-step guide walks you through everything you need
to send your first gift card through the Tremendous API:

Check it out!

Request body

Property Type Description
external_id
string

Reference for this order, supplied by the customer.

When set, external_id makes order idempotent. All requests that use the same external_id after the initial order creation, will result in a response that returns the data of the initially created order. The response will have a 201 response code. These responses fail to create any further orders.

It also allows for retrieving by external_id instead of id only.

payment
object
Show object properties
Property Type Description
funding_source_id
string

Tremendous ID of the funding source that will be used to pay for the order. Use balance to use your Tremendous's balance.

</tr>
reward
object

A single reward, sent to a recipient. A reward is always part of an order.

Either products or campaign_id must be specified.

Show object properties
Property Type Description
id
string

Tremendous ID of the reward

order_id
string

Tremendous ID of the order this reward is part of.

created_at
string date-time

Date the reward was created

campaign_id
string

ID of the campaign in your account, that defines the available products (different gift cards, charity, etc.) that the recipient can choose from.

products
array string

List of IDs of product (different gift cards, charity, etc.) that will be available to the recipient to choose from.

Providing a products array will override the products made available by the campaign specified using the campaign_id property unless the products array is empty. It will not override other campaign attributes, like the message and customization of the look and feel.

value
object
Show object properties
Property Type Description
denomination
number double

Amount of the reward

currency_code
string

Currency of the reward

</tr>
recipient
object

Details of the recipient of the reward

Show object properties
Property Type Description
name
string

Name of the recipient

email
string

Email address of the recipient

phone
string

Phone number of the recipient. For non-US phone numbers, specify the country code (prefixed with +).

</tr>
deliver_at
string date

Timestamp of reward delivery within the next year. Note that if date-time is provided, the time values will be ignored.

custom_fields
array
Show array item type
Property Type Description
id
string

Tremendous ID of the custom field

value
string

Value of the custom field

label
string

Label of the custom field

</tr>
language
string

Set this to translate the redemption experience for this reward. Pass a 2-letter ISO-639-1 code for the desired language. Defaults to en.

delivery
object

Details on how the reward is delivered to the recipient.

Show object properties
Property Type Description
method
string

How to deliver the reward to the recipient.

Delivery Method Description
EMAIL Deliver the reward to the recipient by email
LINK

Deliver the reward to the recipient via a link.

The link can be retrieved on a successfully ordered reward via the /rewards or /rewards/{id} endpoint. That link must then be delivered to the recipient out-of-band.

PHONE Deliver the reward to the recipient by SMS
</tr> </tbody> </table> </tr> </tbody> </table> </div> ### Funding sources There are different ways to pay for gift cards and rewards on Tremendous. Every payment mechanism is called a "funding source". You can retrieve a list of all available funding sources by using the [Funding sources API endpoint](https://tremendous.readme.io/reference/core-funding-source-index). The Tremendous API sandbox environment comes with a single funding source that allows you to spend up to $5,000 in *fake money* to test the API. [Learn more about the sandbox environment](https://tremendous.readme.io/reference/sandbox). The HTTP status code `200` on the response will be used to indicate success. After processing successfully the reward gets queued to be delivered to it's recipient (for delivery method `EMAIL` and `PHONE`). Delivery will happen asynchronously, after the response has been sent. ### Idempotence Requests issued with the same external_id are idempotent. Submitting an order with an already existing `external_id`, will result in a `201` response code. In this case the response will return a representation of the already existing order in the response body.
operationId: Orders_createOrder

Request Body

required

Order to create

application/json
schema OrdersCreateOrderRequest
Property Type Required
reward object required
value object optional
denomination number required
currency_code string required
delivery object optional
method string optional
language string optional
products array optional
recipient object optional
name string optional
email string optional
phone string optional
deliver_at string optional
campaign_id string optional
custom_fields array optional
id string optional
label string optional
value string optional
payment object required
funding_source_id string required
external_id string optional

Responses

200

An order (to be overwritten in specific reponses)

201

An order (to be overwritten in specific reponses)

202

An order (to be overwritten in specific reponses)

400

Validation error of the sent parameters or request body

401

Authorization error e.g. due to an invalid or missing API key.

402

Not enough funds to carry out the request. Please top-up your account

422

Validation error of the sent parameters or request body

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /orders
POST /order_approvals/{id}/approve

Approves an order that is pending review, identified by the given id in the URL.

Approvals is a feature that requires orders to be approved by an organization admin
before they are sent out. To enable approvals for your organization, please enable
‘Allow approvals via API’ via the organization’’s ‘Order Approvals’ settings from the Tremendous dashboard.

operationId: Orders_approveOrderById

Parameters

Name In Required Type Description
id path required string

ID of the order that should be approved. In case the order has an external_id reference supplied by the customer on creation, it’s possible to use it instead.

Responses

200

An order (to be overwritten in specific reponses)

401

Authorization error e.g. due to an invalid or missing API key.

402

Not enough funds in your account. Please send another approval request after you have deposited sufficient funds into your balance.

403

API approvals are not enabled. Enable ‘Allow approvals via API’ in the organization’s settings on the Tremendous dashboard.

404

No resource could be found for the provided ID

422

Validation error of the sent parameters or request body

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /order_approvals/{id}/approve
POST /order_approvals/{id}/reject

Rejects an order that is pending review, identified by the given id in the URL.

Approvals is a feature that requires orders to be approved by an organization admin
before they are sent out. To enable approvals for your organization, please enable
‘Allow approvals via API’ via the organization’’s ‘Order Approvals’ settings from the Tremendous dashboard.

operationId: Orders_rejectById

Parameters

Name In Required Type Description
id path required string

ID of the order that should be rejected. In case the order has an external_id reference supplied by the customer on creation, it’s possible to use it instead.

Responses

200

An order (to be overwritten in specific reponses)

401

Authorization error e.g. due to an invalid or missing API key.

403

API approvals are not enabled for this organization. Enable “Allow approvals via API” via the organization’s order approval settings from the Tremendous dashboard.

404

No resource could be found for the provided ID

422

Validation error of the sent parameters or request body

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /order_approvals/{id}/reject

Organizations 2 endpoints

POST /organizations

Organizations are a way to separate different parts of your business within the same Tremendous account.

You can assign users in your Tremendous team as members to any organization. Users can be members of multiple organizations at once.

API keys belong to a single organization. The API key used in a request determines on behalf of which organization the request is carried out.

Important note: When creating an organization, you are required to either pass with_api_key or copy_settings[user] in the request body as true. This ensures that your new Organization can either be accessed via the API or the Dashboard.

operationId: Organizations_createNewOrganization

Request Body

required

Organization details

application/json
schema OrganizationsCreateNewOrganizationRequest
Property Type Required
name string required
phone string optional
website string required
with_api_key boolean optional
copy_settings object optional
users boolean optional
campaigns boolean optional
custom_fields boolean optional
order_approvals boolean optional
payment_methods boolean optional
fraud_prevention boolean optional
security_settings boolean optional

Responses

200

The created organization

400

Validation error of the sent parameters or request body

401

Authorization error e.g. due to an invalid or missing API key.

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /organizations
POST /organizations/create_api_key

Creates a new API key. The API key used to make the request will remain active.

Created API keys are generated randomly and returned in the response. You cannot retrieve them again.

operationId: Organizations_createApiKey

Responses

200

The created API key

401

Authorization error e.g. due to an invalid or missing API key.

404

No resource could be found for the provided ID

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /organizations/create_api_key

Rewards 3 endpoints

POST /rewards/{id}/generate_embed_token

Generate a temporary reward token identified by the id in the URL.
These tokens are needed to render a reward when using Tremendous Embed.
The token is valid for 24 hours.

operationId: Rewards_generateEmbedToken

Parameters

Name In Required Type Description
id path required string

ID of the reward

Responses

200

A redemption token for a reward

401

Authorization error e.g. due to an invalid or missing API key.

404

No resource could be found for the provided ID

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /rewards/{id}/generate_embed_token
POST /rewards/{id}/generate_link

Generate a redemption link for the reward identified by the id in the URL

operationId: Rewards_generateLink

Parameters

Name In Required Type Description
id path required string

ID of the reward

Responses

200

A redemption link for a reward

401

Authorization error e.g. due to an invalid or missing API key.

403

Operation not permitted; only rewards that are of type link support this operation

404

No resource could be found for the provided ID

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /rewards/{id}/generate_link
POST /rewards/{id}/resend

Resends a reward, identified by the given id in the URL, to its recipient.

operationId: Rewards_resendRewardById

Parameters

Name In Required Type Description
id path required string

ID of the reward that should be resent

Responses

200

Reward will be resent.

401

Authorization error e.g. due to an invalid or missing API key.

404

No resource could be found for the provided ID

422

Validation error of the sent parameters or request body

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /rewards/{id}/resend

Webhooks 2 endpoints

POST /webhooks

Tremendous uses webhooks as a notification system for various events that happen in your account.

📘 Learn more about Webhooks

Our guide explains everything you need to know about the Tremendous webhooks:
Read it here

Every organization can define a single webhook endpoint where we send requests to, whenever an event happens.

This endpoint allows you to setup that endpoint. The URL of the endpoint can be changed by making a request to this endpoint again with the new URL.

Request body

Property Type Description
url
string uri

URL the webhook will make requests to

operationId: Webhooks_createWebhook

Request Body

required

Webhook details

application/json
schema WebhooksCreateWebhookRequest
Property Type Required
url string required

Responses

200

A webhook (to be overwritten in specific responses)

400

Validation error of the sent parameters or request body

401

Authorization error e.g. due to an invalid or missing API key.

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /webhooks
POST /webhooks/{id}/simulate

Making a request to this endpoint will cause our system to trigger a webhook for the specified event. This can be very useful when testing the setup that processes webhooks on your end.

📘 Learn more about Webhooks

Our guide explains everything you need to know about the Tremendous webhooks:
Read it here

operationId: Webhooks_triggerEvent

Parameters

Name In Required Type Description
id path required string

ID of the webhook to test

Request Body

required

Webhook details

application/json
schema WebhooksTriggerEventRequest
Property Type Required
event string required

Responses

200

Webhook simulation triggered successfully

401

Authorization error e.g. due to an invalid or missing API key.

404

No resource could be found for the provided ID

422

Validation error of the sent parameters or request body

429

Rate limit exceeded, this request was not processed. Future requests may not be processed, until your account drops below the rate limit threshold, again.

500

The server encountered an unexpected error or couldn’t fulfill the request in time.

POST /webhooks/{id}/simulate

Schemas

object BalanceTransaction
{
  "type": "object",
  "properties": {
    "action": {
      "type": "string",
      "example": "Deposit",
      "description": "The action that was performed"
    },
    "amount": {
      "type": "number",
      "format": "double",
      "example": 50.35,
      "description": "Amount of the transaction in USD"
    },
    "balance": {
      "type": "number",
      "format": "double",
      "example": 92.48,
      "description": "The updated total after the transaction. Note that this running balance may be delayed and contain `null`."
    },
    "created_at": {
      "type": "string",
      "format": "date",
      "description": "Date that the transaction was created"
    },
    "description": {
      "type": "string",
      "description": "A brief description of the transaction"
    }
  },
  "description": "A balance transaction represents a specific movement or change in an account's balance.\n"
}
object BalanceTransactionsListAll401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object BalanceTransactionsListAll422Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Order failed: validation failure",
      "payload": {
        "some_field": {
          "some_sub_field": "Something went wrong with this parameter"
        }
      }
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object BalanceTransactionsListAll429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object BalanceTransactionsListAll500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object BalanceTransactionsListAllResponse
{
  "type": "object",
  "properties": {
    "invoices": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "action": {
            "type": "string",
            "example": "Deposit",
            "description": "The action that was performed"
          },
          "amount": {
            "type": "number",
            "format": "double",
            "example": 50.35,
            "description": "Amount of the transaction in USD"
          },
          "balance": {
            "type": "number",
            "format": "double",
            "example": 92.48,
            "description": "The updated total after the transaction. Note that this running balance may be delayed and contain `null`."
          },
          "created_at": {
            "type": "string",
            "format": "date",
            "description": "Date that the transaction was created"
          },
          "description": {
            "type": "string",
            "description": "A brief description of the transaction"
          }
        },
        "description": "A balance transaction represents a specific movement or change in an account's balance.\n"
      }
    }
  }
}
object Campaign
{
  "type": "object",
  "required": [
    "id",
    "name",
    "description",
    "products"
  ],
  "properties": {
    "id": {
      "type": "string",
      "example": "SOMEIDSOMEID",
      "pattern": "[A-Z0-9]{4,20}",
      "readOnly": true
    },
    "name": {
      "type": "string",
      "example": "My Default Campaign",
      "description": "Name of the campaign"
    },
    "products": {
      "type": "array",
      "items": {
        "type": "string",
        "example": "SOMEIDSOMEID",
        "pattern": "[A-Z0-9]{4,20}",
        "readOnly": true
      },
      "example": [
        "P3MR06THYM8R",
        "EFMULTF26PMR"
      ],
      "description": "List of IDs of products (different gift cards, charity, etc.) that are available in this campaign.\n"
    },
    "description": {
      "type": "string",
      "example": "A campaign I use as the default in Tremendous\"",
      "nullable": true,
      "description": "Description of the campaign"
    }
  },
  "description": "With a campaign you can define the look & feel of how rewards are sent out.\nIt also lets you set the available products (different gift cards, charity, etc.)\nrecipients can choose from.\n\n> Note: Campaigns must be created from the Tremendous dashboard.\n>\n> • [Production Dashboard](https://app.tremendous.com)\n> • [Sandbox Dashboard](https://app.testflight.tremendous.com/)\n"
}
object CampaignsGetAll401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetAll429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetAll500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetAllResponse
{
  "type": "object",
  "required": [
    "campaigns"
  ],
  "properties": {
    "campaigns": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "id",
          "name",
          "description",
          "products"
        ],
        "properties": {
          "id": {
            "type": "string",
            "example": "SOMEIDSOMEID",
            "pattern": "[A-Z0-9]{4,20}"
          },
          "name": {
            "type": "string",
            "example": "My Default Campaign",
            "description": "Name of the campaign"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "SOMEIDSOMEID",
              "pattern": "[A-Z0-9]{4,20}"
            },
            "example": [
              "P3MR06THYM8R",
              "EFMULTF26PMR"
            ],
            "description": "List of IDs of products (different gift cards, charity, etc.) that are available in this campaign.\n"
          },
          "description": {
            "type": "string",
            "example": "A campaign I use as the default in Tremendous\"",
            "nullable": true,
            "description": "Description of the campaign"
          }
        },
        "description": "With a campaign you can define the look & feel of how rewards are sent out.\nIt also lets you set the available products (different gift cards, charity, etc.)\nrecipients can choose from.\n\n> Note: Campaigns must be created from the Tremendous dashboard.\n>\n> • [Production Dashboard](https://app.tremendous.com)\n> • [Sandbox Dashboard](https://app.testflight.tremendous.com/)\n"
      }
    }
  }
}
object CampaignsGetById401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetById404Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetById429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetById500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object CampaignsGetByIdResponse
{
  "type": "object",
  "required": [
    "campaign"
  ],
  "properties": {
    "campaign": {
      "type": "object",
      "required": [
        "id",
        "name",
        "description",
        "products"
      ],
      "properties": {
        "id": {
          "type": "string",
          "example": "SOMEIDSOMEID",
          "pattern": "[A-Z0-9]{4,20}"
        },
        "name": {
          "type": "string",
          "example": "My Default Campaign",
          "description": "Name of the campaign"
        },
        "products": {
          "type": "array",
          "items": {
            "type": "string",
            "example": "SOMEIDSOMEID",
            "pattern": "[A-Z0-9]{4,20}"
          },
          "example": [
            "P3MR06THYM8R",
            "EFMULTF26PMR"
          ],
          "description": "List of IDs of products (different gift cards, charity, etc.) that are available in this campaign.\n"
        },
        "description": {
          "type": "string",
          "example": "A campaign I use as the default in Tremendous\"",
          "nullable": true,
          "description": "Description of the campaign"
        }
      },
      "description": "With a campaign you can define the look & feel of how rewards are sent out.\nIt also lets you set the available products (different gift cards, charity, etc.)\nrecipients can choose from.\n\n> Note: Campaigns must be created from the Tremendous dashboard.\n>\n> • [Production Dashboard](https://app.tremendous.com)\n> • [Sandbox Dashboard](https://app.testflight.tremendous.com/)\n"
    }
  }
}
object CreateInvoice
{
  "type": "object",
  "required": [
    "amount"
  ],
  "properties": {
    "memo": {
      "type": "string",
      "nullable": true,
      "description": "A note to be included in the invoice. This is for your internal use and will not be visible to the recipient.\n"
    },
    "amount": {
      "type": "number",
      "format": "double",
      "example": 50.35,
      "description": "Amount of the invoice in USD"
    },
    "po_number": {
      "type": "string",
      "example": "123-PO-EE",
      "nullable": true,
      "description": "Reference to the purchase order number within your organization"
    }
  }
}
object CreateMember
{
  "type": "object",
  "required": [
    "email",
    "name",
    "role"
  ],
  "properties": {
    "name": {
      "type": "string",
      "example": "Jane Doe",
      "description": "Full name of the member"
    },
    "role": {
      "enum": [
        "MEMBER",
        "ADMIN"
      ],
      "type": "string",
      "example": "MEMBER",
      "description": "Role of the member within the organization.\n\n<table>\n  <thead>\n    <tr>\n      <th>Role</th>\n      <th>Description</th>\n    </tr>\n  </thead>\n    <tr>\n      <td><code>MEMBER</code></td>\n      <td>Limited permissions. Can view their own reward and order histories only.</td>\n    </tr>\n    <tr>\n      <td><code>ADMIN</code></td>\n      <td>Update organization settings, invite other members to the organization, and view all member order and reward histories within their organization.</td>\n    </tr>\n  <tbody>\n</table>\n"
    },
    "email": {
      "type": "string",
      "format": "email",
      "example": "jane@example.com",
      "description": "Email address of the member"
    }
  }
}
object CreateOrganization
{
  "type": "object",
  "required": [
    "name",
    "website"
  ],
  "properties": {
    "name": {
      "type": "string",
      "example": "ACME Inc.",
      "description": "Name of the organization"
    },
    "phone": {
      "type": "string",
      "example": "123-456-7890",
      "description": "Phone number of the organization. For non-US phone numbers, specify the country code (prefixed with +)."
    },
    "website": {
      "type": "string",
      "format": "uri",
      "example": "https://www.example.com/some-org",
      "description": "URL of the website of that organization"
    },
    "with_api_key": {
      "type": "boolean",
      "example": true,
      "description": "Default value is `false`. Set to true to also generate an API key associated to the new organization."
    },
    "copy_settings": {
      "type": "object",
      "properties": {
        "users": {
          "type": "boolean",
          "default": false,
          "example": false,
          "description": "Copy over the users from the current organization to the new organization. Defaults to `false`."
        },
        "campaigns": {
          "type": "boolean",
          "default": false,
          "example": false,
          "description": "Copy over the campaigns from the current organization to the new organization. Defaults to `false`."
        },
        "custom_fields": {
          "type": "boolean",
          "default": false,
          "example": false,
          "description": "Copy over the custom fields from the current organization to the new organization. Defaults to `false`."
        },
        "order_approvals": {
          "type": "boolean",
          "default": false,
          "example": false,
          "description": "Copy over the order approvals settings from the current organization to the new organization. Defaults to `false`."
        },
        "payment_methods": {
          "type": "boolean",
          "default": false,
          "example": false,
          "description": "Copy over the payment methods from the current organization to the new organization. Defaults to `false`."
        },
        "fraud_prevention": {
          "type": "boolean",
          "default": false,
          "example": false,
          "description": "Copy over the fraud prevention settings and rules from the current organization to the new organization. Defaults to `false`."
        },
        "security_settings": {
          "type": "boolean",
          "default": true,
          "example": true,
          "description": "Copy over the security settings from the current organization to the new organization. Defaults to `true`."
        }
      },
      "description": "A list of the settings that you wish to copy over to the new organization."
    }
  }
}
string CurrencyCodes
{
  "enum": [
    "USD",
    "CAD",
    "EUR",
    "AED",
    "AFN",
    "ALL",
    "AMD",
    "ARS",
    "AUD",
    "AZN",
    "BAM",
    "BDT",
    "BGN",
    "BHD",
    "BIF",
    "BND",
    "BOB",
    "BRL",
    "BWP",
    "BYR",
    "BZD",
    "CDF",
    "CHF",
    "CLP",
    "CNY",
    "COP",
    "CRC",
    "CVE",
    "CZK",
    "DJF",
    "DKK",
    "DOP",
    "DZD",
    "EEK",
    "EGP",
    "ERN",
    "ETB",
    "GBP",
    "GEL",
    "GHS",
    "GNF",
    "GTQ",
    "HKD",
    "HNL",
    "HRK",
    "HUF",
    "IDR",
    "ILS",
    "INR",
    "IQD",
    "IRR",
    "ISK",
    "JMD",
    "JOD",
    "JPY",
    "KES",
    "KHR",
    "KRW",
    "KWD",
    "KZT",
    "LBP",
    "LKR",
    "LTL",
    "LVL",
    "MAD",
    "MDL",
    "MGA",
    "MKD",
    "MMK",
    "MOP",
    "MUR",
    "MXN",
    "MYR",
    "MZN",
    "NAD",
    "NGN",
    "NIO",
    "NOK",
    "NPR",
    "NZD",
    "OMR",
    "PAB",
    "PEN",
    "PHP",
    "PKR",
    "PLN",
    "PYG",
    "QAR",
    "RON",
    "RSD",
    "RUB",
    "RWF",
    "SAR",
    "SDG",
    "SEK",
    "SGD",
    "SOS",
    "SYP",
    "THB",
    "TND",
    "TOP",
    "TRY",
    "TTD",
    "TWD",
    "TZS",
    "UAH",
    "UGX",
    "UYU",
    "UZS",
    "VEF",
    "VND",
    "XAF",
    "XOF",
    "YER",
    "ZAR",
    "ZMK"
  ],
  "type": "string",
  "example": "USD"
}
object CustomField
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "example": "SOMEIDSOMEID",
      "pattern": "[A-Z0-9]{4,20}",
      "readOnly": false,
      "description": "Tremendous ID of the custom field"
    },
    "label": {
      "type": "string",
      "example": "harry_potter_house",
      "readOnly": false,
      "description": "Label of the custom field"
    },
    "value": {
      "type": "string",
      "example": "Hufflepuff",
      "nullable": true,
      "readOnly": false,
      "description": "Value of the custom field"
    }
  },
  "description": "Reward custom data for searching, tracking or copy (see [Adding custom fields to orders](https://developers.tremendous.com/reference/using-custom-fields-to-add-custom-data-to-rewards).)"
}
object DeliveryDetails
{
  "type": "object",
  "required": [
    "method",
    "status"
  ],
  "properties": {
    "method": {
      "enum": [
        "EMAIL",
        "LINK",
        "PHONE"
      ],
      "type": "string",
      "description": "How to deliver the reward to the recipient.\n\n<table>\n  <thead>\n    <tr>\n      <th>Delivery Method</th>\n      <th>Description</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>EMAIL</code></td>\n      <td>Deliver the reward to the recipient by email</td>\n    </tr>\n    <tr>\n      <td><code>LINK</code></td>\n      <td>\n        <p>Deliver the reward to the recipient via a link.</p>\n        <p>The link can be retrieved on a successfully ordered reward via the <code>/rewards</code> or <code>/rewards/{id}</code> endpoint. That link must then be  delivered to the recipient out-of-band.</p>\n      </td>\n    </tr>\n    <tr>\n      <td><code>PHONE</code></td>\n      <td>Deliver the reward to the recipient by SMS</td>\n    </tr>\n  </tbody>\n</table>\n"
    },
    "status": {
      "enum": [
        "SCHEDULED",
        "FAILED",
        "SUCCEEDED",
        "PENDING"
      ],
      "type": "string",
      "readOnly": true,
      "description": "Current status of the delivery of the reward:\n\n* `SCHEDULED` - Reward is scheduled for delivery and will be delivered soon.\n* `FAILED` - Delivery of reward failed (e.g. email bounced).\n* `SUCCEEDED` - Reward was successfully delivered (email or text message delivered or reward link opened).\n* `PENDING` - Delivery is pending but not yet scheduled.\n"
    }
  },
  "description": "Details on how the reward is delivered to the recipient.\n"
}
object DeliveryDetailsWithLink
{
  "type": "object",
  "required": [
    "method",
    "status"
  ],
  "properties": {
    "link": {
      "type": "string",
      "example": "https://testflight.tremendous.com/rewards/payout/z67jic92r",
      "readOnly": true,
      "description": "Link to redeem the reward at. You need to deliver this link to the recipient.\n\nOnly available for rewards for which the `method` for delivery is set to `LINK`.\n"
    },
    "method": {
      "enum": [
        "EMAIL",
        "LINK",
        "PHONE"
      ],
      "type": "string",
      "description": "How to deliver the reward to the recipient.\n\n<table>\n  <thead>\n    <tr>\n      <th>Delivery Method</th>\n      <th>Description</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>EMAIL</code></td>\n      <td>Deliver the reward to the recipient by email</td>\n    </tr>\n    <tr>\n      <td><code>LINK</code></td>\n      <td>\n        <p>Deliver the reward to the recipient via a link.</p>\n        <p>The link can be retrieved on a successfully ordered reward via the <code>/rewards</code> or <code>/rewards/{id}</code> endpoint. That link must then be  delivered to the recipient out-of-band.</p>\n      </td>\n    </tr>\n    <tr>\n      <td><code>PHONE</code></td>\n      <td>Deliver the reward to the recipient by SMS</td>\n    </tr>\n  </tbody>\n</table>\n"
    },
    "status": {
      "enum": [
        "SCHEDULED",
        "FAILED",
        "SUCCEEDED",
        "PENDING"
      ],
      "type": "string",
      "readOnly": true,
      "description": "Current status of the delivery of the reward:\n\n* `SCHEDULED` - Reward is scheduled for delivery and will be delivered soon.\n* `FAILED` - Delivery of reward failed (e.g. email bounced).\n* `SUCCEEDED` - Reward was successfully delivered (email or text message delivered or reward link opened).\n* `PENDING` - Delivery is pending but not yet scheduled.\n"
    }
  },
  "description": "Details on how the reward is delivered to the recipient.\n"
}
string DeliveryMethod
{
  "enum": [
    "EMAIL",
    "LINK",
    "PHONE"
  ],
  "type": "string",
  "description": "How to deliver the reward to the recipient.\n\n<table>\n  <thead>\n    <tr>\n      <th>Delivery Method</th>\n      <th>Description</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>EMAIL</code></td>\n      <td>Deliver the reward to the recipient by email</td>\n    </tr>\n    <tr>\n      <td><code>LINK</code></td>\n      <td>\n        <p>Deliver the reward to the recipient via a link.</p>\n        <p>The link can be retrieved on a successfully ordered reward via the <code>/rewards</code> or <code>/rewards/{id}</code> endpoint. That link must then be  delivered to the recipient out-of-band.</p>\n      </td>\n    </tr>\n    <tr>\n      <td><code>PHONE</code></td>\n      <td>Deliver the reward to the recipient by SMS</td>\n    </tr>\n  </tbody>\n</table>\n"
}
string DeliveryStatus
{
  "enum": [
    "SCHEDULED",
    "FAILED",
    "SUCCEEDED",
    "PENDING"
  ],
  "type": "string",
  "readOnly": true,
  "description": "Current status of the delivery of the reward:\n\n* `SCHEDULED` - Reward is scheduled for delivery and will be delivered soon.\n* `FAILED` - Delivery of reward failed (e.g. email bounced).\n* `SUCCEEDED` - Reward was successfully delivered (email or text message delivered or reward link opened).\n* `PENDING` - Delivery is pending but not yet scheduled.\n"
}
object ErrorModel
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object Field
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "example": "SOMEIDSOMEID",
      "pattern": "[A-Z0-9]{4,20}",
      "readOnly": true
    },
    "data": {
      "type": "object",
      "additionalProperties": true
    },
    "label": {
      "type": "string",
      "example": "recipient_name",
      "description": "Label of the field"
    },
    "scope": {
      "type": "string",
      "example": "REWARD",
      "description": "Type of objects this field gets associated with"
    },
    "required": {
      "type": "boolean",
      "example": true,
      "description": "Is this field required (true) or optional (false)"
    },
    "data_type": {
      "type": "string",
      "example": "Text",
      "description": "Type of the values of the field"
    }
  }
}
object FieldsGetCustomFields401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FieldsGetCustomFields429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FieldsGetCustomFields500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FieldsGetCustomFieldsResponse
{
  "type": "object",
  "properties": {
    "fields": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "example": "SOMEIDSOMEID",
            "pattern": "[A-Z0-9]{4,20}"
          },
          "data": {
            "type": "object",
            "additionalProperties": true
          },
          "label": {
            "type": "string",
            "example": "recipient_name",
            "description": "Label of the field"
          },
          "scope": {
            "type": "string",
            "example": "REWARD",
            "description": "Type of objects this field gets associated with"
          },
          "required": {
            "type": "boolean",
            "example": true,
            "description": "Is this field required (true) or optional (false)"
          },
          "data_type": {
            "type": "string",
            "example": "Text",
            "description": "Type of the values of the field"
          }
        }
      }
    }
  }
}
object FundingSource
{
  "type": "object",
  "required": [
    "id",
    "method",
    "meta"
  ],
  "properties": {
    "id": {
      "type": "string",
      "example": "SOMEIDSOMEID",
      "pattern": "[A-Z0-9]{4,20}",
      "readOnly": true
    },
    "meta": {
      "type": "object",
      "properties": {
        "last4": {
          "type": "string",
          "example": "1234",
          "pattern": "[0-9]{4}",
          "description": "**Only available when `method` is set to `credit_card`.**\n\nLast 4 digits of the credit card number\n"
        },
        "expired": {
          "type": "boolean",
          "example": false,
          "description": "**Only available when `method` is set to `credit_card`.**\n\nIs this credit card expired\n"
        },
        "network": {
          "enum": [
            "MasterCard",
            "Amex",
            "JCB",
            "Diner's Club",
            "visa",
            "discover",
            "laser",
            "elo",
            "maestro",
            "solo"
          ],
          "type": "string",
          "example": "Amex",
          "description": "**Only available when `method` is set to `credit_card`.**\n\nNetwork of the credit card\n"
        },
        "bank_name": {
          "type": "string",
          "example": "Bank of Fancyland",
          "nullable": true,
          "description": "**Only available when `method` is set to `bank_account`.**\n\nName of the bank\n"
        },
        "refundable": {
          "type": "boolean",
          "example": false,
          "description": "**Only available when `method` is set to `bank_account`.**\n\nCan refunds be deposited to this bank account\n"
        },
        "account_type": {
          "enum": [
            "checking",
            "savings"
          ],
          "type": "string",
          "example": "checking",
          "description": "**Only available when `method` is set to `bank_account`.**\n\nIs this a checking or savings account\n"
        },
        "pending_cents": {
          "type": "integer",
          "example": 25000,
          "description": "**Only available when `method` is set to `balance`.**\n\nFunds that are already registered on your Tremendous account but which have not yet been deposited in your account (e.g. unpaid invoices) (in Cents USD).\n"
        },
        "available_cents": {
          "type": "integer",
          "example": 50000,
          "description": "**Only available when `method` is set to `balance`.**\n\nAvailable amount for this funding source (in Cents USD)\n"
        },
        "accountholder_name": {
          "type": "string",
          "example": "Jane Doe",
          "description": "**Only available when `method` is set to `bank_account` or `credit_card`.**\n\nName of the holder of the bank account or credit_card\n"
        },
        "account_number_mask": {
          "type": "string",
          "example": "1234",
          "pattern": "[0-9]{4}",
          "description": "**Only available when `method` is set to `bank_account`.**\n\nLast 4 digits of the account number\n"
        },
        "account_routing_mask": {
          "type": "string",
          "example": "5678",
          "pattern": "[0-9]{4}",
          "description": "**Only available when `method` is set to `bank_account`.**\n\nLast 4 digits of the routing number\n"
        },
        "last_payment_failed_at": {
          "type": "string",
          "format": "date-time",
          "nullable": true,
          "description": "**Only available when `method` is set to `bank_account` or `credit_card`.**\n\nPoint in time when the last order failed using this bank account or credit card as a funding source.\n"
        }
      }
    },
    "type": {
      "enum": [
        "COMMERCIAL",
        "PRO_FORMA",
        "PREFUNDING_ONLY"
      ],
      "type": "string",
      "example": "COMMERCIAL",
      "description": "**Only available when `method` is set to `invoice`.**\n"
    },
    "method": {
      "enum": [
        "balance",
        "bank_account",
        "credit_card",
        "invoice"
      ],
      "type": "string",
      "example": "balance",
      "description": "You can pay for rewards using different payment methods on Tremendous:\n\n<table>\n  <thead>\n    <tr>\n      <th>Payment Method</th>\n      <th>Description</th>\n      </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>balance</code></td>\n      <td>Pre-funded balance in your Tremendous account to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>bank_account</code></td>\n      <td>Bank account to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>credit_card</code></td>\n      <td>Credit card to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>invoice</code></td>\n      <td>Send rewards to recipients and pay by invoice.</td>\n    </tr>\n\n  </tbody>\n</table>\n"
    }
  },
  "description": ""
}
object FundingSourcesGetAll401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetAll429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetAll500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetAllResponse
{
  "type": "object",
  "required": [
    "funding_sources"
  ],
  "properties": {
    "funding_sources": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "id",
          "method",
          "meta"
        ],
        "properties": {
          "id": {
            "type": "string",
            "example": "SOMEIDSOMEID",
            "pattern": "[A-Z0-9]{4,20}"
          },
          "meta": {
            "type": "object",
            "properties": {
              "last4": {
                "type": "string",
                "example": "1234",
                "pattern": "[0-9]{4}",
                "description": "**Only available when `method` is set to `credit_card`.**\n\nLast 4 digits of the credit card number\n"
              },
              "expired": {
                "type": "boolean",
                "example": false,
                "description": "**Only available when `method` is set to `credit_card`.**\n\nIs this credit card expired\n"
              },
              "network": {
                "enum": [
                  "MasterCard",
                  "Amex",
                  "JCB",
                  "Diner's Club",
                  "visa",
                  "discover",
                  "laser",
                  "elo",
                  "maestro",
                  "solo"
                ],
                "type": "string",
                "example": "Amex",
                "description": "**Only available when `method` is set to `credit_card`.**\n\nNetwork of the credit card\n"
              },
              "bank_name": {
                "type": "string",
                "example": "Bank of Fancyland",
                "nullable": true,
                "description": "**Only available when `method` is set to `bank_account`.**\n\nName of the bank\n"
              },
              "refundable": {
                "type": "boolean",
                "example": false,
                "description": "**Only available when `method` is set to `bank_account`.**\n\nCan refunds be deposited to this bank account\n"
              },
              "account_type": {
                "enum": [
                  "checking",
                  "savings"
                ],
                "type": "string",
                "example": "checking",
                "description": "**Only available when `method` is set to `bank_account`.**\n\nIs this a checking or savings account\n"
              },
              "pending_cents": {
                "type": "integer",
                "example": 25000,
                "description": "**Only available when `method` is set to `balance`.**\n\nFunds that are already registered on your Tremendous account but which have not yet been deposited in your account (e.g. unpaid invoices) (in Cents USD).\n"
              },
              "available_cents": {
                "type": "integer",
                "example": 50000,
                "description": "**Only available when `method` is set to `balance`.**\n\nAvailable amount for this funding source (in Cents USD)\n"
              },
              "accountholder_name": {
                "type": "string",
                "example": "Jane Doe",
                "description": "**Only available when `method` is set to `bank_account` or `credit_card`.**\n\nName of the holder of the bank account or credit_card\n"
              },
              "account_number_mask": {
                "type": "string",
                "example": "1234",
                "pattern": "[0-9]{4}",
                "description": "**Only available when `method` is set to `bank_account`.**\n\nLast 4 digits of the account number\n"
              },
              "account_routing_mask": {
                "type": "string",
                "example": "5678",
                "pattern": "[0-9]{4}",
                "description": "**Only available when `method` is set to `bank_account`.**\n\nLast 4 digits of the routing number\n"
              },
              "last_payment_failed_at": {
                "type": "string",
                "format": "date-time",
                "nullable": true,
                "description": "**Only available when `method` is set to `bank_account` or `credit_card`.**\n\nPoint in time when the last order failed using this bank account or credit card as a funding source.\n"
              }
            }
          },
          "type": {
            "enum": [
              "COMMERCIAL",
              "PRO_FORMA",
              "PREFUNDING_ONLY"
            ],
            "type": "string",
            "example": "COMMERCIAL",
            "description": "**Only available when `method` is set to `invoice`.**\n"
          },
          "method": {
            "enum": [
              "balance",
              "bank_account",
              "credit_card",
              "invoice"
            ],
            "type": "string",
            "example": "balance",
            "description": "You can pay for rewards using different payment methods on Tremendous:\n\n<table>\n  <thead>\n    <tr>\n      <th>Payment Method</th>\n      <th>Description</th>\n      </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>balance</code></td>\n      <td>Pre-funded balance in your Tremendous account to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>bank_account</code></td>\n      <td>Bank account to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>credit_card</code></td>\n      <td>Credit card to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>invoice</code></td>\n      <td>Send rewards to recipients and pay by invoice.</td>\n    </tr>\n\n  </tbody>\n</table>\n"
          }
        },
        "description": ""
      }
    }
  }
}
object FundingSourcesGetById401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetById404Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetById429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetById500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object FundingSourcesGetByIdResponse
{
  "type": "object",
  "required": [
    "funding_source"
  ],
  "properties": {
    "funding_source": {
      "type": "object",
      "required": [
        "id",
        "method",
        "meta"
      ],
      "properties": {
        "id": {
          "type": "string",
          "example": "SOMEIDSOMEID",
          "pattern": "[A-Z0-9]{4,20}"
        },
        "meta": {
          "type": "object",
          "properties": {
            "last4": {
              "type": "string",
              "example": "1234",
              "pattern": "[0-9]{4}",
              "description": "**Only available when `method` is set to `credit_card`.**\n\nLast 4 digits of the credit card number\n"
            },
            "expired": {
              "type": "boolean",
              "example": false,
              "description": "**Only available when `method` is set to `credit_card`.**\n\nIs this credit card expired\n"
            },
            "network": {
              "enum": [
                "MasterCard",
                "Amex",
                "JCB",
                "Diner's Club",
                "visa",
                "discover",
                "laser",
                "elo",
                "maestro",
                "solo"
              ],
              "type": "string",
              "example": "Amex",
              "description": "**Only available when `method` is set to `credit_card`.**\n\nNetwork of the credit card\n"
            },
            "bank_name": {
              "type": "string",
              "example": "Bank of Fancyland",
              "nullable": true,
              "description": "**Only available when `method` is set to `bank_account`.**\n\nName of the bank\n"
            },
            "refundable": {
              "type": "boolean",
              "example": false,
              "description": "**Only available when `method` is set to `bank_account`.**\n\nCan refunds be deposited to this bank account\n"
            },
            "account_type": {
              "enum": [
                "checking",
                "savings"
              ],
              "type": "string",
              "example": "checking",
              "description": "**Only available when `method` is set to `bank_account`.**\n\nIs this a checking or savings account\n"
            },
            "pending_cents": {
              "type": "integer",
              "example": 25000,
              "description": "**Only available when `method` is set to `balance`.**\n\nFunds that are already registered on your Tremendous account but which have not yet been deposited in your account (e.g. unpaid invoices) (in Cents USD).\n"
            },
            "available_cents": {
              "type": "integer",
              "example": 50000,
              "description": "**Only available when `method` is set to `balance`.**\n\nAvailable amount for this funding source (in Cents USD)\n"
            },
            "accountholder_name": {
              "type": "string",
              "example": "Jane Doe",
              "description": "**Only available when `method` is set to `bank_account` or `credit_card`.**\n\nName of the holder of the bank account or credit_card\n"
            },
            "account_number_mask": {
              "type": "string",
              "example": "1234",
              "pattern": "[0-9]{4}",
              "description": "**Only available when `method` is set to `bank_account`.**\n\nLast 4 digits of the account number\n"
            },
            "account_routing_mask": {
              "type": "string",
              "example": "5678",
              "pattern": "[0-9]{4}",
              "description": "**Only available when `method` is set to `bank_account`.**\n\nLast 4 digits of the routing number\n"
            },
            "last_payment_failed_at": {
              "type": "string",
              "format": "date-time",
              "nullable": true,
              "description": "**Only available when `method` is set to `bank_account` or `credit_card`.**\n\nPoint in time when the last order failed using this bank account or credit card as a funding source.\n"
            }
          }
        },
        "type": {
          "enum": [
            "COMMERCIAL",
            "PRO_FORMA",
            "PREFUNDING_ONLY"
          ],
          "type": "string",
          "example": "COMMERCIAL",
          "description": "**Only available when `method` is set to `invoice`.**\n"
        },
        "method": {
          "enum": [
            "balance",
            "bank_account",
            "credit_card",
            "invoice"
          ],
          "type": "string",
          "example": "balance",
          "description": "You can pay for rewards using different payment methods on Tremendous:\n\n<table>\n  <thead>\n    <tr>\n      <th>Payment Method</th>\n      <th>Description</th>\n      </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>balance</code></td>\n      <td>Pre-funded balance in your Tremendous account to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>bank_account</code></td>\n      <td>Bank account to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>credit_card</code></td>\n      <td>Credit card to draw funds from to send rewards to recipients.</td>\n    </tr>\n    <tr>\n      <td><code>invoice</code></td>\n      <td>Send rewards to recipients and pay by invoice.</td>\n    </tr>\n\n  </tbody>\n</table>\n"
        }
      },
      "description": ""
    }
  }
}
object Invoice
{
  "type": "object",
  "required": [
    "id",
    "amount",
    "status",
    "created_at",
    "paid_at"
  ],
  "properties": {
    "id": {
      "type": "string",
      "example": "PPS-26873",
      "description": "The invoice number"
    },
    "amount": {
      "type": "number",
      "format": "double",
      "example": 50.35,
      "description": "Amount of the invoice in USD"
    },
    "orders": {
      "type": "array",
      "items": {
        "type": "string",
        "example": "SOMEIDSOMEID",
        "pattern": "[A-Z0-9]{4,20}",
        "readOnly": true
      },
      "example": [
        "ABC123456789",
        "DEF123456789"
      ],
      "description": "List of orders related to the invoice (it doesn't apply to prefunding)"
    },
    "status": {
      "enum": [
        "DELETED",
        "PAID",
        "OPEN",
        "MARKED_AS_PAID"
      ],
      "type": "string",
      "example": "PAID",
      "description": "Status of this invoice\n\n<table>\n  <thead>\n    <tr>\n      <th>Status</th>\n      <th>Description</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>DELETED</code></td>\n      <td>Invoice has been deleted by your organization</td>\n    </tr>\n    <tr>\n      <td><code>PAID</code></td>\n      <td>Invoice has been paid by your organization</td>\n    </tr>\n    <tr>\n      <td><code>OPEN</code></td>\n      <td>Invoice has been created by your organization but has not been paid, yet</td>\n    </tr>\n  </tbody>\n</table>\n"
    },
    "paid_at": {
      "type": "string",
      "format": "date",
      "nullable": true,
      "description": "Timestamp of when the invoice has been paid.\n"
    },
    "rewards": {
      "type": "array",
      "items": {
        "type": "string",
        "example": "SOMEIDSOMEID",
        "pattern": "[A-Z0-9]{4,20}",
        "readOnly": true
      },
      "example": [
        "ABC123456789",
        "DEF123456789"
      ],
      "description": "List of rewards related to the invoice (it doesn't apply to prefunding)"
    },
    "po_number": {
      "type": "string",
      "example": "123-PO-EE",
      "nullable": true,
      "description": "Reference to the purchase order number within your organization"
    },
    "created_at": {
      "type": "string",
      "format": "date",
      "description": "Timestamp of when the invoice has been created.\n"
    }
  },
  "description": "Invoices are instruments to fund your Tremendous account's balance.\n\nInvoices can be created by your organization programatically.\nOnce we receive your payment, the invoice is marked as `PAID` and we add\nthe respective funds to your account's balance.\n"
}
object InvoicesCreateAndFundAccountBalance400Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object InvoicesCreateAndFundAccountBalance401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object InvoicesCreateAndFundAccountBalance429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object InvoicesCreateAndFundAccountBalance500Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object InvoicesCreateAndFundAccountBalanceRequest
{
  "type": "object",
  "required": [
    "amount"
  ],
  "properties": {
    "memo": {
      "type": "string",
      "nullable": true,
      "description": "A note to be included in the invoice. This is for your internal use and will not be visible to the recipient.\n"
    },
    "amount": {
      "type": "number",
      "format": "double",
      "example": 50.35,
      "description": "Amount of the invoice in USD"
    },
    "po_number": {
      "type": "string",
      "example": "123-PO-EE",
      "nullable": true,
      "description": "Reference to the purchase order number within your organization"
    }
  }
}
object InvoicesCreateAndFundAccountBalanceResponse
{
  "type": "object",
  "required": [
    "invoice"
  ],
  "properties": {
    "invoice": {
      "type": "object",
      "required": [
        "id",
        "amount",
        "status",
        "created_at",
        "paid_at"
      ],
      "properties": {
        "id": {
          "type": "string",
          "example": "PPS-26873",
          "description": "The invoice number"
        },
        "amount": {
          "type": "number",
          "format": "double",
          "example": 50.35,
          "description": "Amount of the invoice in USD"
        },
        "orders": {
          "type": "array",
          "items": {
            "type": "string",
            "example": "SOMEIDSOMEID",
            "pattern": "[A-Z0-9]{4,20}"
          },
          "example": [
            "ABC123456789",
            "DEF123456789"
          ],
          "description": "List of orders related to the invoice (it doesn't apply to prefunding)"
        },
        "status": {
          "enum": [
            "DELETED",
            "PAID",
            "OPEN",
            "MARKED_AS_PAID"
          ],
          "type": "string",
          "example": "PAID",
          "description": "Status of this invoice\n\n<table>\n  <thead>\n    <tr>\n      <th>Status</th>\n      <th>Description</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <td><code>DELETED</code></td>\n      <td>Invoice has been deleted by your organization</td>\n    </tr>\n    <tr>\n      <td><code>PAID</code></td>\n      <td>Invoice has been paid by your organization</td>\n    </tr>\n    <tr>\n      <td><code>OPEN</code></td>\n      <td>Invoice has been created by your organization but has not been paid, yet</td>\n    </tr>\n  </tbody>\n</table>\n"
        },
        "paid_at": {
          "type": "string",
          "format": "date",
          "nullable": true,
          "description": "Timestamp of when the invoice has been paid.\n"
        },
        "rewards": {
          "type": "array",
          "items": {
            "type": "string",
            "example": "SOMEIDSOMEID",
            "pattern": "[A-Z0-9]{4,20}"
          },
          "example": [
            "ABC123456789",
            "DEF123456789"
          ],
          "description": "List of rewards related to the invoice (it doesn't apply to prefunding)"
        },
        "po_number": {
          "type": "string",
          "example": "123-PO-EE",
          "nullable": true,
          "description": "Reference to the purchase order number within your organization"
        },
        "created_at": {
          "type": "string",
          "format": "date",
          "description": "Timestamp of when the invoice has been created.\n"
        }
      },
      "description": "Invoices are instruments to fund your Tremendous account's balance.\n\nInvoices can be created by your organization programatically.\nOnce we receive your payment, the invoice is marked as `PAID` and we add\nthe respective funds to your account's balance.\n"
    }
  }
}
object InvoicesGetAll401Response
{
  "type": "object",
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}
object InvoicesGetAll429Response
{
  "type": "object",
  "example": {
    "errors": {
      "message": "Too many requests",
      "payload": {}
    }
  },
  "required": [
    "errors"
  ],
  "properties": {
    "errors": {
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Error message"
        },
        "payload": {
          "type": "object",
          "example": {
            "rewards": {
              "catalog": "At least one valid product required"
            }
          },
          "description": "Mirrors the request parameters structure, filled only with the (nested) properties that caused an error."
        }
      }
    }
  }
}