RCS Templates
The RCS Template API allows you to create, update, retrieve, list, and delete different types of RCS message templates.
Templates can contain dynamic variables such as {{1}}, {{2}}, etc., which can be replaced with actual values when sending messages.
Endpoint
https://api.azmarq.com/v1/rcs/templateHeaders
- Name
Content-Type- Type
- string
- Description
application/jsonfor JSON bodies.
- Name
apikey- Type
- string
- Description
Dashboard API key. See Authentication.
Basic Text Template
This endpoint is used to create a basic text-based RCS template. This type of template is suitable for simple messages such as OTPs, alerts, notifications, and other SMS-like communication.
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the template.
- Name
templateType- Type
- string
- Description
Use text for a text template.
- Name
isRichText- Type
- boolean
- Description
Set to false for a basic text template.
- Name
content.plainText- Type
- string
- Description
Text content of the template. Dynamic variables can be defined using
{{1}},{{2}}, etc.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Rich Text Template
This endpoint is used to create a rich text RCS template.
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the template.
- Name
templateType- Type
- string
- Description
Use text.
- Name
isRichText- Type
- boolean
- Description
Set to true for a rich text template.
- Name
content.plainText- Type
- string
- Description
Text content of the template. Dynamic variables can be defined using
{{1}},{{2}}, etc.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Text With Suggested Replies
This endpoint creates an RCS text template with suggested replies and an Open URL action.
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the template.
- Name
templateType- Type
- string
- Description
Use text.
- Name
isRichText- Type
- boolean
- Description
Set to true.
- Name
content.plainText- Type
- string
- Description
Main text displayed to the user.
- Name
content.suggestions- Type
- array
- Description
List of suggested replies or actions.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Dynamic Open URL
This endpoint creates an RCS template with a dynamic Open URL action.
Dynamic values can be supplied when the template is used.
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the template.
- Name
templateType- Type
- string
- Description
Use text.
- Name
isRichText- Type
- boolean
- Description
Set to true.
- Name
content.plainText- Type
- string
- Description
Message text containing dynamic variables.
- Name
openUrl.url- Type
- string
- Description
URL to be opened. This can contain a dynamic variable such as
{{2}}.
- Name
openUrl.isDynamic- Type
- boolean
- Description
Set to true when the URL is dynamically provided.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Standalone Rich Card
This endpoint creates a standalone RCS rich card containing an image, title, description, and interactive suggestions.
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the template.
- Name
templateType- Type
- string
- Description
Use standalone.
- Name
isRichText- Type
- boolean
- Description
Set to true.
- Name
mediaType- Type
- string
- Description
Media type used by the rich card, such as IMAGE.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Standalone Rich Card With Root Suggestions
This endpoint is used to create a standalone RCS rich card template. The template can contain a card title, description, media, and interactive suggestions.
Root-level suggestions are defined directly inside the content object and are displayed separately from the suggestions defined inside the rich card.
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the standalone rich card template.
- Name
templateType- Type
- string
- Description
Use standalone for a standalone rich card template.
- Name
isRichText- Type
- boolean
- Description
Defines whether the template supports rich content.
- Name
mediaType- Type
- string
- Description
Media type used by the rich card. For image cards, use IMAGE.
- Name
cardOrientation- Type
- string
- Description
Defines the orientation of the rich card. For example, VERTICAL.
- Name
cardTitle- Type
- string
- Description
Title displayed on the rich card.
- Name
cardDescription- Type
- string
- Description
Description displayed below the card title.
- Name
cardMedia- Type
- object
- Description
Contains the media configuration for the rich card, including media height and file URL.
Suggestions
Suggestions can be configured at two levels:
- Root-level suggestions — defined directly inside
content.suggestions. - Card-level suggestions — defined inside
richCardDetails.standalone.content.suggestions.
A suggestion can be a reply or an action such as opening a URL.
Root-level suggestion
In this example, the Stop offers reply is configured at the root level and can be used independently of the rich card.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Carousel Template with Per-Card Variables
This endpoint is used to create an RCS carousel template where each card can have its own dynamic title and description.
Each carousel card can contain:
- Dynamic title and description values
- Media such as images
- Reply or action suggestions
- Static or dynamic content using template variables
Required attributes
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateName- Type
- string
- Description
Unique name of the carousel template.
- Name
templateType- Type
- string
- Description
Use carousel for a carousel template.
- Name
isRichText- Type
- boolean
- Description
Defines whether the template supports rich content.
- Name
mediaType- Type
- string
- Description
Media type used by the carousel cards. For image cards, use IMAGE.
- Name
content.richCardDetails.carousel.cardWidth- Type
- string
- Description
Defines the width of the carousel cards. For example, MEDIUM_WIDTH.
- Name
content.richCardDetails.carousel.contents- Type
- array
- Description
List of cards included in the carousel. Each card can have its own title, description, media, and suggestions.
- Name
params- Type
- array
- Description
Provides the values used for dynamic variables in the corresponding card content.
Dynamic variables
Dynamic variables can be defined using {{1}}, {{2}}, etc.
The values for these variables are provided through the params array of each card.
For example:
- Name
{{1}}- Type
- string
- Description
Replaced with the corresponding title value from the card's params.
- Name
{{2}}- Type
- string
- Description
Replaced with the corresponding description value from the card's params.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Update Templates
Update Text Template
This endpoint is used to update an existing text template.
The templateType must match the existing template type. The template type cannot be changed while updating the template.
Required attributes
- Name
templateName- Type
- string
- Description
Unique identifier of the template that needs to be updated.
- Name
botId- Type
- array
- Description
Identifier of the RCS bot associated with the template.
- Name
templateType- Type
- string
- Description
Must match the existing template type.
- Name
isRichText- Type
- boolean
- Description
Defines whether the template uses rich text.
- Name
content.plainText- Type
- string
- Description
Updated text content. Dynamic variables such as
{{1}}and{{2}}can be used.
Request
curl --location --request PUT 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Update Text Template With Chips
This endpoint updates an existing text template containing suggested replies and URL actions.
The templateType must remain text.
Required attributes
- Name
templateName- Type
- string
- Description
Unique identifier of the existing template.
- Name
botId- Type
- array
- Description
Identifier of the RCS bot.
- Name
templateType- Type
- string
- Description
Must be text.
- Name
content- Type
- object
- Description
Updated template content including text and suggestions.
Request
curl --location --request PUT 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Update Standalone Template
This endpoint updates an existing standalone rich card template.
The templateType must remain standalone.
Required attributes
- Name
templateName- Type
- string
- Description
Unique identifier of the existing template.
- Name
botId- Type
- array
- Description
Identifier of the RCS bot.
- Name
templateType- Type
- string
- Description
Must be standalone.
- Name
mediaType- Type
- string
- Description
Media type used by the rich card.
- Name
content.richCardDetails- Type
- object
- Description
Updated standalone rich card configuration.
Request
curl --location --request PUT 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Update Carousel Template
This endpoint updates an existing carousel template.
The templateType must remain carousel.
Required attributes
- Name
templateName- Type
- string
- Description
Unique identifier of the existing carousel template.
- Name
botId- Type
- array
- Description
Identifier of the RCS bot.
- Name
templateType- Type
- string
- Description
Must be carousel.
- Name
mediaType- Type
- string
- Description
Media type used by the carousel.
- Name
content.richCardDetails.carousel- Type
- object
- Description
Updated carousel configuration and card contents.
Request
curl --location --request PUT 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Retrieve Templates
List All Templates
This endpoint retrieves all RCS templates associated with your account.
No request body or query parameters are required.
Headers
- Name
apikey- Type
- string
- Description
Your API authentication key.
Request
curl --location --request GET 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Get Template By Template Name
This endpoint retrieves a specific RCS template using its template name.
Required attributes
- Name
templateName- Type
- string
- Description
Name of the template to retrieve.
Request
curl --location --request POST 'https://api.azmarq.com/v1/rcs/template/get' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'Delete Template
Delete Template
This endpoint is used to delete an existing RCS template.
The template is identified using its template name.
Required attributes
- Name
templateName- Type
- string
- Description
Name of the template that needs to be deleted.
Warning: Deleting a template is a destructive operation. Make sure the template is no longer required before deleting it.
Request
curl --location --request DELETE 'https://api.azmarq.com/v1/rcs/template' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{}'