Authentication
Making API calls for your Merchants couldn't be easier. Let's review:
Almost every API call to Tilled requires the tilled-account
header. For actions that are on behalf of your partner account, you must pass your own partner account ID.
Account ID can be seen in the Tilled Console here (sandbox) or here (production))
Examples include:
- Creating merchant accounts
- Creating API keys
- Creating webhook endpoints
- Listing commission payouts
Most actions will be taken on behalf of a merchant account. Examples include:
- Creating customers
- Creating payment methods
- Creating/confirming payment intents
- Listing balance transactions
You can make API calls for your accounts server-side with the tilled-account
header and the associated account ID, per request. You must also pass the tilled-api-key
header.
For example, to list events
of type=charge.succeeded
for a given merchant account:
1$ curl https://api.tilled.com/v1/events?types=charge.succeeded \
2-H "tilled-api-key: {%raw%}{{SECRET_KEY}}{%endraw%}" \
3-H "tilled-account: {%raw%}{{MERCHANT_ACCOUNT_ID}}{%endraw%}"
To list your merchant accounts, you would pass your own account ID
1$ curl https://api.tilled.com/v1/accounts/connected \
2-H "tilled-api-key: {%raw%}{{SECRET_KEY}}{%endraw%}" \
3-H "tilled-account: {%raw%}{{PARTNER_ACCOUNT_ID}}{%endraw%}"