Applies to: Sprinklr Asset Manager APIs
V2 API reference: Sprinklr Asset Manager
Use the Sprinklr Asset Manager APIs in this guide to create, read, update, and delete assets; import assets from URLs; check asynchronous import status; regenerate accessible media URLs; process secure media URLs in bulk; and create WhatsApp HSM templates.
📖 Related Knowledge Base Article: Sprinklr Asset Manager
You need an access token and API key to call these APIs. Use the environment-specific API host shown in each endpoint. If your token is associated with multiple workspaces, the Read Asset source notes that you should pass workspace_id in the request headers.
POST- Create AssetGET- Read AssetPUT- Update AssetPATCH- Update AssetDELETE- Delete AssetPOST- Asset Import via URLPOSTandGETAsset Import AsyncGET- Secure Media DownloadPOST- Secure Media Download - BulkPOST- Create WhatsApp HSM Template
All API calls are sent to the production endpoint:
https://api3.sprinklr.com/{env}/api/v3So the resource in production is:
https://api3.sprinklr.com/{env}/api/v3/samReplace {env} with your assigned environment identifier (prod0, prod2, prod11, and so on — see APIs | Sprinklr Developer Portal for the environment list).
API headers include the mandatory information you send along with the request URL and body. This information helps provide insights into request context and authorization credentials that, in turn, allows access to protected resources.
| Header | Value | Description |
|---|---|---|
Authorization | Bearer {token} | Authenticates the user with the server. |
Key | {api-key} | Authenticates the application with the server. |
Content-Type | application/json | Identifies the request-body media type. |
Accept | application/json | Identifies the expected response type. |
Using this API, you can create a media asset within Sprinklr. You can track and manage multiple versions of assets.
https://api3.sprinklr.com/{env}/api/v3/sam
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
name | Required | Name of the asset. | String |
description | Required | Description of the asset. | String |
assetType | Required | Type of asset being created. Example: PHOTO. | String / Enum |
status | Required | Initial status of the asset. Example: DRAFT. | String / Enum |
attachment | Required | Attachment details for the asset. | Object |
attachment.type | Required | Type of attachment. Example: IMAGE. | String / Enum |
attachment.url | Required | URL of the asset file. | String / URL |
attachment.previewUrl | Optional | URL used to preview the asset. | String / URL |
attachment.mimeType | Required | MIME type of the attachment. Example: image/jpeg. | String |
assetSource | Required | Source of the asset. Example: SPRINKLR. | String / Enum |
restricted | Required | Indicates whether the asset is restricted. | Boolean |
curl --location 'https://api3.sprinklr.com/{env}/api/v3/sam' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data '{
"name": "API Check Part 3",
"description": "Unique media test",
"assetType": "PHOTO",
"status": "DRAFT",
"attachment": {
"type": "IMAGE",
"url": "https://images.unsplash.com/photo-1519389950473-47ba0277781c",
"previewUrl": "https://images.unsplash.com/photo-1519389950473-47ba0277781c",
"mimeType": "image/jpeg"
},
"assetSource": "SPRINKLR",
"restricted": false
}'{
"data": {
"assetType": "PHOTO",
"attachment": {
"url": "https://images.unsplash.com/photo-1519389950473-47ba0277781c",
"previewUrl": "https://images.unsplash.com/photo-1519389950473-47ba0277781c",
"mimeType": "image/jpeg",
"type": "IMAGE"
},
"lastModifiedById": 66069496,
"reportingStats": {},
"id": "6a9adb355efb429a803a638a",
"name": "API Check Part 3",
"description": "Unique media test",
"status": "Draft",
"taxonomy": {},
"insights": {},
"validity": {
"expiryTime": 2208988800000,
"availableFrom": 1788480000000,
"neverExpire": false,
"visibleFrom": 1788480000000
},
"assetSource": "SPRINKLR",
"actionStats": {},
"shareConfigs": [],
"restricted": false,
"locked": false,
"createdTime": 1788533557064,
"modifiedTime": 1788533557064,
"langVsTranslatedFieldValues": {},
"createdByUser": 66069496,
"versionId": 0
},
"errors": []
}| Parameter | Description | Type |
|---|---|---|
data | Contains the asset details returned by the API. | Object |
data.assetType | Type of asset. Example: PHOTO. | String / Enum |
data.attachment | Contains details of the asset attachment. | Object |
data.attachment.url | URL of the asset file. | String / URL |
data.attachment.previewUrl | URL used to preview the asset. | String / URL |
data.attachment.mimeType | MIME type of the attachment. Example: image/jpeg. | String |
data.attachment.type | Type of attachment. Example: IMAGE. | String / Enum |
data.lastModifiedById | ID of the user who last modified the asset. | Integer |
data.reportingStats | Reporting statistics associated with the asset. | Object |
data.id | Unique identifier of the asset. | String |
data.name | Name of the asset. | String |
data.description | Description of the asset. | String |
data.status | Current status of the asset. Example: Draft. | String / Enum |
data.taxonomy | Taxonomy information associated with the asset. | Object |
data.insights | Insights associated with the asset. | Object |
data.validity | Contains the asset's availability and expiration details. | Object |
data.validity.expiryTime | Timestamp indicating when the asset expires. | Long / Timestamp |
data.validity.availableFrom | Timestamp indicating when the asset becomes available. | Long / Timestamp |
data.validity.neverExpire | Indicates whether the asset is configured to never expire. | Boolean |
data.validity.visibleFrom | Timestamp indicating when the asset becomes visible. | Long / Timestamp |
data.assetSource | Source from which the asset originated. Example: SPRINKLR. | String / Enum |
data.actionStats | Statistics related to actions performed on the asset. | Object |
data.shareConfigs | Sharing configuration details for the asset. | Array |
data.restricted | Indicates whether the asset is restricted. | Boolean |
data.locked | Indicates whether the asset is locked. | Boolean |
data.createdTime | Timestamp indicating when the asset was created. | Long / Timestamp |
data.modifiedTime | Timestamp indicating when the asset was last modified. | Long / Timestamp |
data.langVsTranslatedFieldValues | Contains language-specific translated field values. | Object |
data.createdByUser | ID of the user who created the asset. | Integer |
data.versionId | Version identifier of the asset. | Integer |
errors | Contains errors generated while processing the request. An empty array indicates that no errors occurred. | Array |
You can fetch details of an existing Sprinklr asset via this API call using the asset Id.
https://api3.sprinklr.com/{env}/api/v3/sam/{assetId}
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
| assetId | Required | Asset id of the existing Sprinklr asset.
Note: Ensure that the type of asset you want to read is supported. The following note lists the supported asset types. | String |
Developer notes:
The API supports reading the following asset types:
PRESENTATION, PHOTO, VIDEO, AUDIO, FLASH, HTML, PDF, DOC, DOCX, EXCEL, ZIP, PSD, SKETCH, FONT, SUBTITLE, TEMPLATE_ASSET, RAR, SVG, EML, MSG, EDB, ICS, EPS, INDD, LINK, POST, RICH_TEXT, TEXT, POLL, GEO_LOCATION
curl --location 'https://api3.sprinklr.com/{env}/api/v3/sam/{assetId}' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Accept: application/json' {
"data": {
"assetType": "PHOTO",
"attachment": {
"url": "https://images.unsplash.com/photo-1519389950473-47ba0277781c",
"previewUrl": "https://images.unsplash.com/photo-1519389950473-47ba0277781c",
"mimeType": "image/jpeg",
"type": "IMAGE"
},
"lastModifiedById": 66074279,
"reportingStats": {},
"id": "6a1fca5636bd1b12f5d17b49",
"name": "API Check Part 3",
"description": "Unique media test",
"status": "Draft",
"taxonomy": {
"partnerCustomProperties": {
"_c_68b198eca158dd05c42c740c": [],
"_c_65169c803884d32abe7e159c": [
"Value2"
],
"_c_65169c9c3884d32abe7e2079": [],
"_c_65169ced3884d32abe7e3db9": [
"Value2"
],
"_c_65169d083884d32abe7e466a": []
}
},
"insights": {},
"validity": {
"expiryTime": 2208988800000,
"availableFrom": 1780444800000,
"neverExpire": false,
"visibleFrom": 1780444800000
},
"assetSource": "SPRINKLR",
"actionStats": {},
"shareConfigs": [],
"restricted": false,
"locked": false,
"createdTime": 1780468310449,
"modifiedTime": 1787813692072,
"langVsTranslatedFieldValues": {},
"createdByUser": 66074279,
"versionId": 0
},
"errors": []
}Note: Developer notesIf your token is associated with multiple workspaces, kindly pass "workspace_id" in the headers to access the asset details.
You can update a Sprinklr asset via this API call.
https://api3.sprinklr.com/{env}/api/v3/sam
| Parameter | Sub Parameter | Required/Optional | Description | Type |
|---|---|---|---|---|
| id | Required | Id of the asset. | String | |
| name | Required | Name of the asset. | String | |
| description | Required | Description of asset. | String | |
| assetType | Required | The type of asset. ENUM:[PRESENTATION, PHOTO, VIDEO, AUDIO, FLASH, HTML, PDF, DOC, DOCX, EXCEL, ZIP, PSD, SKETCH, FONT] | String | |
| status | Required | Status of the asset. Supported Values: APPROVED, DRAFT, EXPIRED | String | |
| attachment | Required | Information about the attachment. | String | |
| type | Required | The type of attachment. ENUM:[Audio, Video] | String | |
| attachmentOptions | Optional | Array of attachment properties per channel and/or account. ChannelSpecificMediaProperties are given below in Attachment Option Table. | ||
| taxonomy | Required | Taxonomy related to an asset | ||
| campaignId | Required | Campaign identifier to associate the message to. | String | |
| clientCustomProperties | Optional | Client custom properties for the message. | String | |
| partnerCustomProperties | Optional | Partner custom properties for the message. | String | |
| tags | Optional | Tags to be added to the message. | String | |
| urlShortnerId | Optional | Url shortner identifier to apply to the message. | String | |
| insights | Optional | Collective insights of the posts on social channels. e.g. likes, comments, shares. | Double | |
| validity | Optional | Information regarding the validity of an asset. | ||
| expiryTime | Optional | Asset expiry time. This option is not valid if neverExpire is true. | Integer | |
| availableFrom | Optional | Asset is available from time. | Integer | |
| neverExpire | Optional | If True, asset will never expire. | Boolean | |
| parentId | Optional | Parent Asset Id. | String | |
| assetSource | Optional | Source of the Asset. e.g. SPRINKLR, GETTY, SHUTTERSTOCK. | String | |
| actionStats | Optional | Stats of the asset actions. e.g Download, Published. | Double | |
| shareConfigs | Optional | The shareConfigs parameter defines the visibility configuration of an asset in Asset Manager. It determines which clients, client groups, users, or user groups can access a specific asset. This parameter is used when updating an asset’s sharing and access settings. The following example shares an asset with:
"shareConfigs": [ { "type": "CLIENT", "ids": ["1000004509"] }, { "type": "CLIENT_GROUP", "ids": [] }, { "type": "USER", "ids": ["1000063395", "1000059523"] }, { "type": "USER_GROUP", "ids": ["66bf4770d6907b378599e534"] } ] Notes
| Array of Object | |
| type | Optional | Specifies the entity type to which the asset is shared. Supported Values:USER, USER_GROUP, GLOBAL, CLIENT, CLIENT_GROUP . | String | |
| id | Optional | A list of unique identifiers for the specified entity type. | String | |
| restricted | Optional | If True, asset is restricted from publishing. | Boolean |
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
| channelType | Required | ChannelType for media options. Enum:[ FACEBOOK, TWITTER ] | String |
| accountId | Optional | If the properties are specific to an account inaddition to channelType, accountId can be specified and the properties would then only be used for the given account. | Integer |
curl --location --request PUT 'https://api3.sprinklr.com/{env}/api/v3/sam' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data '{
"id": "6798dd077b60507fc0a5dd98",
"name": "API check part 2",
"description": "Asset is updated now-3",
"assetType": "PHOTO",
"status": "Draft",
"attachment": {
"url": "https://example-1-1w7sq03xb7.com/resource",
"previewUrl": "https://example-1-1w7sq03xb7.com/resource",
"mimeType": "image/jpeg",
"type": "IMAGE"
},
"assetSource": "SPRINKLR",
"restricted": false
}'{
"data": {
"assetType": "PHOTO",
"attachment": {
"url": "https://example-1-1w7sq03xb7.com/resource",
"previewUrl": "https://example-1-1w7sq03xb7.com/resource",
"mimeType": "image/jpeg",
"type": "IMAGE"
},
"id": "6798dd077b60507fc0a5dd98",
"name": "API check part 2",
"description": "Asset is updated now-3",
"status": "Draft",
"taxonomy": {},
"insights": {},
"validity": {
"expiryTime": 2208988800000,
"availableFrom": 1738022400000,
"neverExpire": false,
"visibleFrom": 1738022400000
},
"assetSource": "SPRINKLR",
"actionStats": {},
"shareConfigs": [],
"restricted": false,
"locked": false,
"createdTime": 1738071303688,
"modifiedTime": 1738075557706,
"langVsTranslatedFieldValues": {},
"createdByUser": 66014640,
"versionId": 1
},
"errors": []
}| Parameter | Sub-Parameter | Type | Description | |
|---|---|---|---|---|
| data | Object | Contains details about the updated asset. | ||
| assetType | String | The type of asset updated (e.g., PHOTO) ENUM:[PRESENTATION, PHOTO, VIDEO, AUDIO, FLASH, HTML, PDF, DOC, DOCX, EXCEL, ZIP, PSD, SKETCH, FONT] | ||
| attachment | Object | Details of the updated asset attachment. | ||
| url | String (URL) | The URL of the attached asset. | ||
| previewUrl | String (URL) | The URL of the preview version of the asset. | ||
| mimeType | String | The MIME type of the asset (e.g., image/jpeg). | ||
| type | String | The type of attachment (e.g., IMAGE). | ||
| id | String | The unique identifier of the updated asset. | ||
| name | String | The name of the updated asset. | ||
| description | String | A brief description of the updated asset. | ||
| status | String | The status of the updated asset (e.g., Draft). Supported Values: APPROVED, DRAFT, EXPIRED | ||
| taxonomy | Object | Reserved for taxonomy details. | ||
| insights | Object | Reserved for asset insights. | ||
| validity | Object | Contains details about the asset's validity. | ||
| expiryTime | Number (Epoch) | The time (in milliseconds) when the asset will expire. | ||
| availableFrom | Number (Epoch) | The time (in milliseconds) when the asset becomes available. | ||
| neverExpire | Boolean | Indicates whether the asset is set to never expire. | ||
| visibleFrom | Number (Epoch) | The time (in milliseconds) when the asset becomes visible. | ||
| assetSource | String | The source of the asset (e.g., SPRINKLR). | ||
| actionStats | Object | Reserved for action statistics (currently empty in the response). | ||
| shareConfigs | Array | Contains sharing configurations (currently empty in the response). | ||
| restricted | Boolean | Indicates if the asset is restricted (e.g., false). | ||
| locked | Boolean | Indicates if the asset is locked (e.g., false). | ||
| createdTime | Number (Epoch) | The time (in milliseconds) when the asset was created. | ||
| modifiedTime | Number (Epoch) | The time (in milliseconds) when the asset was last updated. | ||
| langVsTranslatedFieldValues | Object | Reserved for language-specific translated fields. | ||
| createdByUser | Number | The ID of the user who created the asset. | ||
| versionId | Number | The version ID of the asset (e.g., 1 for the updated version). | ||
| errors | Array | Contains a list of errors, if any occurred during the update process (e.g., empty array if no errors). |
You can update a Sprinklr asset via this API call.
https://api3.sprinklr.com/{env}/api/v3/sam
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
env | Required | Specifies the environment in which the API request is executed. | String |
SAM_ID | Required | Unique identifier of the SAM record to be updated. | String |
fieldName | Required | Unique identifier of the SAM field whose value needs to be updated. | String |
value | Required | Value to assign to the specified SAM field. | String |
op | Required | Specifies the operation to perform on the field. SET sets or replaces the field value with the provided value. | String |
curl --location --request PATCH 'https://api3.sprinklr.com/{env}/api/v3/sam/{SAM_ID}' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data '[
{
"fieldName": "_c_65169ced3884d32abe7e3db9",
"value": "Value2",
"op": "SET"
}
]'204 No ContentYou can delete a Sprinklr asset via this API call and you will get 204 (No Content) as Response after making the Request.
https://api3.sprinklr.com/{env}/api/v3/sam/{assetId}
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
| assetId | Required | Asset id of the existing Sprinklr asset, you want to delete. | String |
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
assetId | Required | Unique identifier of the SAM asset to delete. | String |
curl --location --request DELETE 'https://api3.sprinklr.com/{env}/api/v3/sam/{assetId}' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Accept: application/json' 204 No ContentUsing this API, you can import a media asset to the content store using the media URL. Kindly note that adding the asset to the content store doesn't imply that it is added to the Digital Asset Manager.
| Parameters | Sub-Params | Required/Optional | Definition | Type |
|---|---|---|---|---|
| url | Required | Specifies the URL of the image or content that needs to be imported into Sprinklr.<br><br>Example: https://example.com/image.jpg | String | |
| importType | Required | Specifies the type of content being imported.<br><br>Example: image indicates that an image is being imported. | String | |
| Optional | Specifies the associated with the API request.<br><br>Example: JSESSIONID={session-id} | String |
curl --location --request POST \
'https://api3.sprinklr.com/{env}/api/v3/sam/importUrl/async?url=https%3A%2F%2Fexample.com%2Fimage.jpg&importType=image' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Key: {Enter your API KEY}' \
--header 'Accept: application/json'{
"data": "6a8dd3d5a5a01c50b54bc173",
"errors": []
}| Parameters | Sub-Params | Required/Optional | Definition | Type |
|---|---|---|---|---|
| data | Required | Specifies the unique identifier of the content that was successfully imported. This identifier can be used to reference the imported content in subsequent API operations. | String | |
| errors | Required | Contains details of any errors encountered while processing the request.<br><br>An empty array indicates that no errors occurred. | Array |
The asset import async API helps you import an asset via URL. Here, the first step involves importing the asset, which will fetch the task Id in response. Using the task Id, you can use the status check API to fetch the uploaded content Id.
The two steps for asset import async involve:
Import via URL to get Task Id.
Check the status via Task Id.
Dev Notes: Things to know when using the Asset Import Async API:
There is no size limitation when using asset import async API.
The processing time for importing the asset depends on its size.
It is recommended to periodically check the status of the import.
The asset import API will continue running until the import is successful.
POST
https://api3.sprinklr.com/{env}/api/v3/sam/importUrl/async?importType={type}&url={valid_url_address}&uploadTrackerId={tracker_id}
The following table describes the Query Parameters in use.
| Query Parameter | Required | Type | Description |
|---|---|---|---|
| importType | Required | String | The file type of asset that you want to import. [ PRESENTATION, SUBTITLE, PHOTO, VIDEO, AUDIO, FLASH, HTML, |
| url | Required | String | The URL of the content that you want to import. |
| uploadTrackerId | Required | String | The unique id entered by user. |
curl --request POST \
'https://api3.sprinklr.com/{env}/api/v3/sam/importUrl/async?importType=IMAGE&url=https%3A%2F%2Fimages.unsplash.com%2Fphoto-1711476926632-53026474fe1a&uploadTrackerId=567783456782440' \
--header 'Authorization: Bearer {token}' \
--header 'Content-Type: application/json' \
--header 'key: {apikey}'{
"data": "66c8970682fba20e63411816",
"errors": []
}| Parameter | Type | Description |
|---|---|---|
| data | String | The data returned as response will serve as 'task ID'. This unique 'task ID' will be used to fetch the status of the asset. |
| error | String | This represents the error message, if any. |
We will use the Task ID from the above call response to check the upload status of the asset.
GET
https://api3.sprinklr.com/{env}/api/v3/sam/task/status/{taskId}
The following table describes the Path Parameters in use.
| Parameter | Required | Type | Description |
|---|---|---|---|
| taskId | Required | String | Refers to the task Id that you receive in the response of "Import via URL" API call. |
curl --location 'https://api3.sprinklr.com/{env}/api/v3/sam/task/status/{taskId}' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Accept: application/json'{
"data": {
"uploadTaskStatus": "Failed"
},
"errors": []
}| Parameters | Sub-Params | Required/Optional | Definition | Type |
|---|---|---|---|---|
| data | Required | Contains the status information for the requested upload task. | Object | |
| uploadTaskStatus | Required | Specifies the current status of the upload task.<br><br>Example: Failed indicates that the upload task was not completed successfully. | String | |
| errors | Required | Contains details of any errors encountered while processing the request.<br><br>An empty array indicates that no errors occurred. | Array |
Using this API, you can regenerate time-bound accessible URLs by passing expired URL in the path parameter.
https://api3.sprinklr.com/{env}/api/v3/secureContent?{secureUrl}
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
| secureUrl | Required | Refers to the secure url for Sprinklr media asset (image, video, audio, PDFs, etc.) Note: The url should be url-encoded | url |
curl --location 'https://api3.sprinklr.com/{env}/api/v3/secureContent?{secureUrl}' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Key: {Enter your API KEY}' \
--header 'Accept: application/json'{
"data": "https://example-6-q4db83n7xu.com/resource",
"errors": []
} | Parameters | Sub-Params | Required/Optional | Definition | Type |
|---|---|---|---|---|
| data | Required | Specifies the secure URL of the content generated or returned by the API. This URL can be used to access the corresponding content securely. | String | |
| errors | Required | Contains details of any errors encountered while processing the request.<br><br>An empty array indicates that no errors occurred. | Array |
Using this API, you can create accessible URLs from the given secure URLs. The use-case of this API is two-fold:
Going forward, all the secure URLs received in the API can be passed in the API to generate time-bound accessible URLs
The existing media URLs at your end that are no longer accessible can be passed in the API to generate the time-bound accessible URLs
https://api3.sprinklr.com/{env}/api/v3/secureContent/bulk
| Parameters | Sub-Params | Required/Optional | Definition | Type |
|---|---|---|---|---|
| urls | Required | Specifies the list of URLs for which secure content needs to be retrieved in bulk. The API processes each URL provided in the request and returns the corresponding secure content information. | Array[String] |
curl --location 'https://api3.sprinklr.com/{env}/api/v3/secureContent/bulk' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"urls": [
"https://example-4-zf76p9729k.com/resource",
"https://example-2-pzegrmsc4m.com/resource"
]
}' {
"data": {
"https://example-4-zf76p9729k.com/resource": "https://example-4-zf76p9729k.com/resource?X-Goog-Algorithm=GOOG4-RSA-SHA256&X-Goog-Credential=-gcs-sa%40gc-.iam.gserviceaccount.com%2F20260825%2Fauto%2Fstorage%2Fgoog4_request&X-Goog-Date=20260825T155839Z&X-Goog-Expires=5400&X-Goog-SignedHeaders=host&X-Goog-Signature=6676ba515171929c975bc2dd67cb688f41718b40ad810aca0296fecdf8fb954d40ff1f875458421c54f6603230c651c1e82f668c48d06a6b4da4b228bcfdbcbde5c28df53db2f6c2de32ff14078106f01bacc4fe4c4c0a4f3a4f33dd36ace0a8a70192059fc697830315313279be25d2210f34241c5d29589aa96ed82a76efccbae86566ace5ba4f51c1019be4db5ee07b66a8f22913dbcf245fb6832783a09c1e283c67c303478dd56dda738426b7646a063a7e65ffee9608aa2bd23eb28fd15a119b49dc1ff1a075f9a4c794d79ad22b4a823b5515295f7e157525f8e4bbd1e216cac1fee38fa46656c1373bd92f3c01f9d0de131ab2088744411bb6f9ca9c",
"https://example-2-pzegrmsc4m.com/resource": "https://example-2-pzegrmsc4m.com/resource?X-Goog-Algorithm=GOOG4-RSA-SHA256&X-Goog-Credential=-gcs-sa%40gc-.iam.gserviceaccount.com%2F20260825%2Fauto%2Fstorage%2Fgoog4_request&X-Goog-Date=20260825T155839Z&X-Goog-Expires=5400&X-Goog-SignedHeaders=host&X-Goog-Signature=8be9d6ef711563fd9f4b53546e9c5cee890d1cce5029007cc147e8d8072ea3197c5ae5692234a9f499e01b37c083b833d1b8d6ba0c81b209c1c723e87f1854c801c294f3045584ee23ab8eb771e742c2b69ea43c6531b10c57ad543af6f6e46737b9e5a6c061e95e8078faee8189d82d1b642ea9d7c7635f6be4e600ecd03f07d0fd4966c382fb192bf9183132c8eb5b02b8f62df1b5c5abafc76921bf29f43efe3ace066788c7d73c2dadbe07628e5ab4428fab0bedb4f9dd0ac8c57d5da664f5c21522e3679328c11ada9877b0d95c04afeeca15cd5a0cfc3aaeb307c88e6b6aca99cc7ca050126548977d4c69018fe473739ce219ff67488da59fa610b460"
},
"errors": []
}| Parameters | Sub-Params | Required/Optional | Definition | Type |
|---|---|---|---|---|
| data | Required | Contains the mapping between the original content URLs provided in the request and their corresponding secure, signed URLs generated by the API. | Object | |
| URL | Required | Specifies the original URL provided in the request. Each URL acts as a key in the data object. | String | |
| URL → Signed URL | Required | Specifies the secure, signed URL generated for the corresponding original URL. The signed URL can be used to access the content securely for a limited period of time. | String | |
| X-Goog-Algorithm | Specifies the signing algorithm used to generate the Google Cloud Storage signed URL.<br><br>Example: GOOG4-RSA-SHA256 | String | ||
| X-Goog-Credential | Specifies the Google Cloud service account credential used to generate the signed URL. | String | ||
| X-Goog-Date | Specifies the date and time when the signed URL was generated. | String | ||
| X-Goog-Expires | Specifies the validity duration of the signed URL in seconds.<br><br>Example: 5400 indicates that the URL is valid for 5400 seconds (90 minutes). | Integer | ||
| X-Goog-SignedHeaders | Specifies the HTTP headers included in the signature.<br><br>Example: host | String | ||
| X-Goog-Signature | Specifies the cryptographic signature used to authenticate and authorize access to the content. | String | ||
| errors | Required | Contains details of any errors encountered while processing the request.<br><br>An empty array indicates that no errors occurred. | Array |
This API allows you to create a WhatsApp HSM template using dynamic content and customizable headers. An HSM template message is a special message type that must be used for any business-initiated or re-engagement conversations via the WhatsApp channel.
HSM is mainly created for sending notifications to customers. Notifications are business-initiated templated messages that can be sent anytime. They enable you to:
Deliver important, timely messages during your customer’s path to purchase.
Send messages anytime without any 24 hours' time restriction.
Continue the conversation with the customers who respond to your notifications.
https://api3.sprinklr.com/{env}/api/v3/sam/template
| Parameter | Required/Optional | Description | Type |
|---|---|---|---|
name | Required | Name of the template asset. | String |
assetType | Required | Type of asset being created. Example: TEMPLATE_ASSET. | String / Enum |
status | Required | Initial status of the template asset. Example: DRAFT. | String / Enum |
templateAsset | Required | Configuration and details of the template asset. | Object |
templateAsset.name | Required | Name of the template. | String |
templateAsset.templateType | Required | Type of template. Example: HSM. | String / Enum |
templateAsset.channelType | Required | Communication channel. Example: WHATSAPP_BUSINESS. | String / Enum |
templateAsset.attachment | Required | WhatsApp template attachment and message configuration. | Object |
templateAsset.attachment.type | Required | Type of attachment. Example: HSM. | String / Enum |
templateAsset.attachment.wabaId | Required | WhatsApp Business Account ID associated with the template. | String |
templateAsset.attachment.namespace | Required | Namespace associated with the WhatsApp template. | String |
templateAsset.attachment.category | Required | Category of the WhatsApp template. Example: UTILITY. | String / Enum |
templateAsset.attachment.langCode | Required | Language code. Example: en_GB. | String |
templateAsset.attachment.elementName | Required | Unique name of the WhatsApp template element. | String |
templateAsset.attachment.message | Required | Template message content, including dynamic variables such as {{1}}. | String |
templateAsset.attachment.example | Required | Example values corresponding to variables in the message. | Array of strings |
Dev Notes: How to Add Dynamic URLs in Buttons?
Dynamic URLs can be added for "Call to Action" button types and Action "OPEN_URL".
You need to define the base domain along with a placeholder 1 within the "url" parameter.
Syntax Example: https://www.google.com/1For defining the value of 1, you need to pass the custom field details (custom field name, custom field asset class, display name, and custom field value) within the placeholder array.
curl --location 'https://api3.sprinklr.com/{env}/api/v3/sam/template' \
--header 'Authorization: Bearer {Enter your Access Token}' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data '{
"name": "Customer Welcome Template",
"assetType": "TEMPLATE_ASSET",
"status": "DRAFT",
"templateAsset": {
"name": "Customer Welcome Template",
"templateType": "HSM",
"channelType": "WHATSAPP_BUSINESS",
"attachment": {
"type": "HSM",
"wabaId": "384946199920777",
"namespace": "b9791533d_82c6_485b_83a08_7436ac8ad65e",
"category": "UTILITY",
"langCode": "en_GB",
"elementName": "customer_welcome_template_v1",
"message": "Hello {{1}}, welcome to our service. We are delighted to have you with us and look forward to assisting you whenever needed.",
"example": ["John"]
}
}
}'{
"data": {
"assetType": "TEMPLATE_ASSET",
"templateAsset": {
"channelType": "WHATSAPP_BUSINESS",
"templateType": "HSM",
"elementList": [],
"buttons": [],
"attachment": {
"wabaTemplateId": 1079822714573273,
"namespace": "4d7410c8_5208_4fc5_af91_59111a420022",
"wabaId": "384946199920777",
"elementName": "customer_welcome_template_v1",
"category": "UTILITY",
"langCode": "en_GB",
"buttons": [],
"wabaTemplateStatus": "PENDING",
"message": "Hello {{1}}, welcome to our service. We are delighted to have you with us and look forward to assisting you whenever needed.",
"placeholders": [],
"example": [
"John"
],
"carouselCards": [],
"type": "HSM"
}
},
"id": "6a900ed21e7106f7ceb6d6c3",
"name": "Customer Welcome Template",
"status": "Draft",
"taxonomy": {},
"insights": {},
"validity": {
"expiryTime": 2208988800000,
"availableFrom": 1787788800000,
"neverExpire": false,
"visibleFrom": 1787788800000
},
"actionStats": {},
"shareConfigs": [],
"restricted": false,
"locked": false,
"createdTime": 1787825878412,
"modifiedTime": 1787825878412,
"langVsTranslatedFieldValues": {},
"createdByUser": 66069496
},
"errors": []
}| Parameter | Description | Type |
|---|---|---|
data | Template asset details returned by the API. | Object |
data.assetType | Type of asset. Example: TEMPLATE_ASSET. | String / Enum |
data.templateAsset | Configuration and details of the template asset. | Object |
data.templateAsset.channelType | Communication channel. Example: WHATSAPP_BUSINESS. | String / Enum |
data.templateAsset.templateType | Type of template. Example: HSM. | String / Enum |
data.templateAsset.elementList | List of template elements. | Array |
data.templateAsset.buttons | List of configured buttons. | Array |
data.templateAsset.attachment | WhatsApp template attachment and message details. | Object |
data.templateAsset.attachment.wabaTemplateId | Template ID in the WhatsApp Business Account. | Long / Integer |
data.templateAsset.attachment.namespace | Namespace associated with the template. | String |
data.templateAsset.attachment.wabaId | WhatsApp Business Account ID. | String |
data.templateAsset.attachment.elementName | Unique name of the template element. | String |
data.templateAsset.attachment.category | Template category. Example: UTILITY. | String / Enum |
data.templateAsset.attachment.langCode | Template language code. Example: en_GB. | String |
data.templateAsset.attachment.buttons | Buttons configured within the attachment. | Array |
data.templateAsset.attachment.wabaTemplateStatus | Current WhatsApp Business template status. Example: PENDING. | String / Enum |
data.templateAsset.attachment.message | Message content, including dynamic variables. | String |
data.templateAsset.attachment.placeholders | Placeholders defined in the template. | Array |
data.templateAsset.attachment.example | Example values for message variables. | Array of strings |
data.templateAsset.attachment.carouselCards | Carousel cards configured for the template. | Array |
data.templateAsset.attachment.type | Attachment type. Example: HSM. | String / Enum |
data.id | Unique identifier of the template asset. | String |
data.name | Name of the template asset. | String |
data.status | Current template asset status. Example: Draft. | String / Enum |
data.taxonomy | Taxonomy information associated with the asset. | Object |
data.insights | Insights associated with the asset. | Object |
data.validity | Availability and expiration details. | Object |
data.validity.expiryTime | Timestamp indicating when the asset expires. | Long / Timestamp |
data.validity.availableFrom | Timestamp indicating when the asset becomes available. | Long / Timestamp |
data.validity.neverExpire | Indicates whether the asset never expires. | Boolean |
data.validity.visibleFrom | Timestamp indicating when the asset becomes visible. | Long / Timestamp |
data.actionStats | Statistics related to actions performed on the asset. | Object |
data.shareConfigs | Sharing configuration details. | Array |
data.restricted | Indicates whether the asset is restricted. | Boolean |
data.locked | Indicates whether the asset is locked. | Boolean |
data.createdTime | Timestamp indicating when the asset was created. | Long / Timestamp |
data.modifiedTime | Timestamp indicating when the asset was last modified. | Long / Timestamp |
data.langVsTranslatedFieldValues | Language-specific translated values. | Object |
data.createdByUser | ID of the user who created the asset. | Integer |
errors | Errors generated while processing the request. An empty array indicates no errors. | Array |
Once the template is created, you’ll get notified through the template created webhook. This will be a real-time notification.
| Language | Language Code |
|---|---|
| Afrikaans | af |
| Albanian | sq |
| Arabic | ar |
| Azerbaijani | az |
| Bengali | bn |
| Bulgarian | bg |
| Catalan | ca |
| Chinese (CHN) | zh_CN |
| Chinese (HKG) | zh_HK |
| Chinese (TAI) | zh_TW |
| Croatian | hr |
| Czech | cs |
| Danish | da |
| Dutch | nl |
| English | en |
| English (UK) | en_GB |
| English (US) | en_US |
| Estonian | et |
| Filipino | fil |
| Finnish | fi |
| French | fr |
| Georgian | ka |
| German | de |
| Greek | el |
| Gujarati | gu |
| Hausa | ha |
| Hebrew | he |
| Hindi | hi |
| Hungarian | hu |
| Indonesian | id |
| Irish | ga |
| Italian | it |
| Japanese | ja |
| Kannada | kn |
| Kazakh | kk |
| Kinyarwanda | rw_RW |
| Korean | ko |
| Kyrgyz (Kyrgyzstan) | ky_KG |
| Lao | lo |
| Latvian | lv |
| Lithuanian | lt |
| Macedonian | mk |
| Malay | ms |
| Malayalam | ml |
| Marathi | mr |
| Norwegian | nb |
| Persian | fa |
| Polish | pl |
| Portuguese (BR) | pt_BR |
| Portuguese (POR) | pt_PT |
| Punjabi | pa |
| Romanian | ro |
| Russian | ru |
| Serbian | sr |
| Slovak | sk |
| Slovenian | sl |
| Spanish | es |
| Spanish (ARG) | es_AR |
| Spanish (SPA) | es_ES |
| Spanish (MEX) | es_MX |
| Swahili | sw |
| Swedish | sv |
| Tamil | ta |
| Telugu | te |
| Thai | th |
| Turkish | tr |
| Ukrainian | uk |
| Urdu | ur |
| Uzbek | uz |
| Vietnamese | vi |
| Zulu | Zu |
Create media assets in Sprinklr by specifying details such as the asset name, description, type, status, attachment, source, and restriction setting. The API also supports tracking and managing multiple versions of assets.
Fetch an asset by its asset ID to retrieve its metadata and configuration. The documented Read Asset API supports asset types including photos, videos, audio, PDFs, documents, presentations, ZIP files, SVGs, links, posts, rich text, polls, and geolocations.
Use the PUT operation to modify an existing Sprinklr asset, including attributes such as its name, description, status, attachment details, asset source, and restriction setting.
Delete an existing asset by providing its unique asset ID. A successful deletion is documented as returning 204 No Content.