curl -X DELETE "https://api.tracklysms.com/api/v2/creatives/101" \
-H "X-Api-Key: trk_your_api_key_here"
import requests
response = requests.delete(
"https://api.tracklysms.com/api/v2/creatives/101",
headers={"X-Api-Key": "trk_your_api_key_here"}
)
data = response.json()
if data["archived"]:
print("Creative archived successfully.")
const response = await fetch(
"https://api.tracklysms.com/api/v2/creatives/101",
{
method: "DELETE",
headers: {
"X-Api-Key": "trk_your_api_key_here",
},
}
);
const data = await response.json();
if (data.archived) {
console.log("Creative archived successfully.");
}
{
"success": true,
"archived": true
}
{
"error": "Creative not found",
"code": "not_found"
}
{
"error": "Invalid credentials",
"code": "invalid_credentials"
}
Creatives (v2)
Delete a Creative
Archive a creative (soft delete). The creative is not permanently removed.
DELETE
/
v2
/
creatives
/
{id}
curl -X DELETE "https://api.tracklysms.com/api/v2/creatives/101" \
-H "X-Api-Key: trk_your_api_key_here"
import requests
response = requests.delete(
"https://api.tracklysms.com/api/v2/creatives/101",
headers={"X-Api-Key": "trk_your_api_key_here"}
)
data = response.json()
if data["archived"]:
print("Creative archived successfully.")
const response = await fetch(
"https://api.tracklysms.com/api/v2/creatives/101",
{
method: "DELETE",
headers: {
"X-Api-Key": "trk_your_api_key_here",
},
}
);
const data = await response.json();
if (data.archived) {
console.log("Creative archived successfully.");
}
{
"success": true,
"archived": true
}
{
"error": "Creative not found",
"code": "not_found"
}
{
"error": "Invalid credentials",
"code": "invalid_credentials"
}
Archives a creative by setting its status to
archived. This is a soft delete — the creative is not permanently removed from the system and will no longer appear in default list queries.
Path Parameters
integer
required
The unique identifier of the creative to archive.
Response Fields
boolean
Indicates whether the creative was archived successfully.
boolean
Confirms the creative has been archived. Always
true on success.Examples
curl -X DELETE "https://api.tracklysms.com/api/v2/creatives/101" \
-H "X-Api-Key: trk_your_api_key_here"
import requests
response = requests.delete(
"https://api.tracklysms.com/api/v2/creatives/101",
headers={"X-Api-Key": "trk_your_api_key_here"}
)
data = response.json()
if data["archived"]:
print("Creative archived successfully.")
const response = await fetch(
"https://api.tracklysms.com/api/v2/creatives/101",
{
method: "DELETE",
headers: {
"X-Api-Key": "trk_your_api_key_here",
},
}
);
const data = await response.json();
if (data.archived) {
console.log("Creative archived successfully.");
}
{
"success": true,
"archived": true
}
{
"error": "Creative not found",
"code": "not_found"
}
{
"error": "Invalid credentials",
"code": "invalid_credentials"
}
Error Codes
| HTTP Status | Error Code | Description |
|---|---|---|
| 401 | invalid_credentials | API key is missing or invalid. |
| 403 | account_suspended | Your account is suspended. Resolve outstanding billing or contact support. |
| 404 | not_found | No creative exists with the given ID. |
Next Steps
Creative Templates
Manage your templates
Create Schedule
Schedule campaigns