Copies an existing template into new templates with the provided names and account IDs.
Security
basicAuth
- US Mailgunhttps://api.mailgun.net/v3/{domain_name}/templates/{template_name}/copy
- EU Mailgunhttps://api.eu.mailgun.net/v3/{domain_name}/templates/{template_name}/copy
curl -i -X PUT \
-u '<username>:<password>' \
'https://api.mailgun.net/v3/{domain_name}/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": [ { … }, { … } ] }