HTTP Verb: PUT

Available statuses: 200 OK, 404 Not Found, 422 Unprocessable Entity

Object: SSHAction

Location: n/a

Formats: XML, JSON

Update a SSH action.

Params

To update a SSH action, a data body must be provided. Data can be provided in three formats: XML, JSON and query string. To specify data type of XML or JSON add the Content-type: application/(json|xml) header to request headers, if you want to provide query string simply skip the Content-type header.

All params should be sent in the ssh_action namespace, e.g.:

XML

<ssh_action>
  <name>name</name>
  ...
</ssh_action>

JSON

{"ssh_action":{"name":name,...}}

Query string

ssh_action[name]=name&...

Check the full list of available params on SSH Action object fields reference

Examples

Request XML, using cURL utility:

curl -i -H "Authorization: Bearer _token" -X PUT -d "ssh_action[name]=newname" https://api.assembla.com/v1/spaces/_space_id/ssh/actions/_id.xml

Response:

HTTP/1.1 200 OK
Date: Tue, 21 May 2013 17:54:13 GMT
Server: Apache
Status: 200
Vary: Accept-Encoding
Content-Length: 1
Content-Type: application/xml; charset=utf-8

Request JSON, using cURL utility:

curl -i -H "Authorization: Bearer _token" -X PUT -d "ssh_action[name]=newname" https://api.assembla.com/v1/spaces/_space_id/ssh/actions/_id.json

Response:

HTTP/1.1 200 OK
Date: Tue, 21 May 2013 17:54:39 GMT
Server: Apache
Status: 200
Content-Length: 2
Content-Type: application/json; charset=utf-8

{}

Description for each field: SSH Action object fields reference