Accounts-accountId-products-productId-action:POST
From Hostway API Documentation
Revision as of 09:28, 20 February 2013 by Mike.robski (Talk | contribs)
POST /accounts/{accountId}/products/{productId}/action
Upgrades/downgrades existing product.
Contents |
Request
POST /accounts/{accountId}/products/{productId}/action
Parameters
- accountId - string
- The Id of the account.
- productId - string
- The Id of the product.
URI Parameters
None.
Request Headers
- Authorization - HTTP Authorization header [1]
- The Authentication credentials of the client application.
Request Body
{ "action": "change", "actionData": { "targetProductSpecification": "https://api.hostway.com/productSpecifications/{productSpecificationId}" } }
Parameters
- action - string
- The type of the requested action. Currently supported actions:
- change - change the product specification (upgrade/downgrade).
- actionData - dictionary
- Contains action-specific data.
- change action:
- targetProductSpecification - the URI of the new product specification.
- change action:
Response
Status Code
- 204 No Content
- The product update was successfully submitted.
- 400 Bad Request
- Request body is invalid.
- 401 Unauthorized
- The authorization credentials were not supplied or are invalid.
- 404 Not Found
- The account or product Ids were not found.
Response Body
None.
See also