- Copy a template
Get account-level templates
Create an account-level template
Delete all account-level templates
Get all account-level template versions
Create an account-level template version
Get an account-level template
Update an account-level template
Delete an account-level template
Get an account-level template version
Update an account-level template version
Delete an account-level template version
Copy an account-level template version
Rename a template
Copy a template
Copies an existing template into new templates with the provided names and account IDs.
Security
basicAuth
- US Mailgunhttps://api.mailgun.net/v4/templates/{template_name}/copy
- EU Mailgunhttps://api.eu.mailgun.net/v4/templates/{template_name}/copy
curl -i -X PUT \
-u '<username>:<password>' \
'https://api.mailgun.net/v4/templates/{template_name}/copy' \
-H 'Content-Type: application/json' \
-d '{
"requests": [
{
"account_id": "account-id-1",
"name": "new-template-name-1"
},
{
"account_id": "account-id-2",
"name": "new-template-name-2",
"domain": "target-domain"
}
]
}'Response
{ "message": "Templates have been copied", "failed_copies": [ { … }, { … } ] }