Introduction
SendBetter API endpoints
SendBetter features an on-demand API to render templates designed in our image editor.
SendBetter API provides both authenticated and unauthenticated endpoints. The render endpoint can be used without authentication, while other endpoints require an API key.
Render Image
Render a template image with dynamic data
Validate Organization
Validate your organization’s API key
List Templates
Get a list of all your templates
Get Template Details
Get detailed information about a specific template
Authentication
SendBetter API supports two authentication methods:
- Render Link - No authentication required, perfect for public usage like email marketing or WhatsApp API
- API Key - Required for accessing organization-specific endpoints. Pass your API key in the
X-API-Key
header
Render Link
Render link is the most direct way to render a template.
Render link works based on query parameters to pass any dynamic data into a template. Modifications via query parameters will differ from template to template. To pass a dynamic content into a specific variable, make sure to you reference the variable with its name in the query parameters.
API Key Authentication
For endpoints that require authentication, you need to include your API key in the X-API-Key
header:
Dynamic Variables
Variables inside a render link will differ from template to template due to dynamic modifications. While designing a template in the SendBetter image editor, you can define variables, which can be dynamically modified during the API call. To pass a dynamic content into a specific variable, make sure to you reference the variable with its name in the query parameters. Here’s a breakdown of default behavior for passing in data to different types of variables.
Variable Type | Description |
---|---|
Text | Dynamically updates text content |
Image | Dynamically updates image path. Must be a path to a publicly accessible image file. Google Drive public links are supported. |
Example of dynamic modifications:
Note that variable names (text-variable-name etc.) are arbitrary and you need to use the corresponding names of variables in your template (you can name variables any way you want in our editor).
Rate limiting
Currently we do not rate limit our API. You can make as many requests as you want. However, we may change this in the future.
Time to render
An image take take between 2 to 10 seconds to render. Depending on the size of the image and the complexity of the template, the time to render may vary.