Header

Edit a server group

This method allows you to update a server group using the API.

URL

/projects/<permalink>/server_groups/<identifier>
  • Replace <permalink> with the permalink of the project.
  • Replace <identifier> with the identifier of the server group.

HTTP Method

PUT

Supported Parameters

  • branch - The branch you wish to deploy this server group from (required)
  • name - A description or name for the server group (required)
  • auto_deploy - Should auto deployments be enabled, either true or false (required)
  • email_notify_on - When do you want to receive email notifications, either never, failure or always (required)
  • notification_email - An email address to send notifications to
  • transfer_order - The transfer order for the server group, parallel or sequential (required)

Example cURL request

curl -H "Content-type: application/json" \
-H "Accept: application/json" \
--user adam@atechmedia.com:my-api-key \
-X PUT \
-d { \
    "server_group":{ \
      "name":"Created via the API (edited)", \
      "branch":"master", \
      "auto_deploy":true, \
      "email_notify_on":"failure", \
      "notification_email":"adamw@atech.media", \
      "transfer_order":"parallel" \
  } \
} \
https://atech.deployhq.com/projects/atomic-deployment-test/server_groups/983f6f1b-0d8b-4860-ad44-3cc4890a0097

Example response

{
  "identifier":"983f6f1b-0d8b-4860-ad44-3cc4890a0097",
  "name":"Created via the API (edited)",
  "servers":[],
  "preferred_branch":"master",
  "last_revision":null
}

Proudly powered by Katapult. Running on 100% renewable energy.