/
Update a route
Updates a given route. All parameters are optional. This only updates the specified fields, leaving others unchanged.
Security
basicAuth
- US Mailgunhttps://api.mailgun.net/v3/routes/{id}
- EU Mailgunhttps://api.eu.mailgun.net/v3/routes/{id}
curl -i -X PUT \
-u '<username>:<password>' \
'https://api.mailgun.net/v3/routes/{id}' \
-H 'Content-Type: application/x-www-form-urlencoded' \
-d priority=0 \
-d 'description=Sample route' \
-d 'expression=match_recipient(".*@samples.mailgun.org")' \
-d 'action=["forward(\"http://myhost.com/messages/\")","stop()"]'Response
{ "message": "Route has been updated", "route": { "id": "4f3bad2335335426750048c6", "priority": 0, "description": "Sample route", "expression": "match_recipient(\".*@samples.mailgun.org\")", "actions": [ … ], "created_at": "Wed, 15 Feb 2012 13:03:31 GMT" } }