Link an Add-on to Plan
Applies To: Windows Azure Pack
Links an add-on to a plan.
Specify the Link Add-on to Plan request as follows: Replace <ServiceMgmt> with your Service Management API endpoint address. <PlanId> should be replaced with the plan identifier for the plan being retrieved.
Method | Request URI | HTTP Version |
|---|---|---|
POST | https://<ServiceMgmt>:30004/plans/<PlanId>/addons | HTTP/1.1 |
None.
The following table describes required and optional request headers.
Request header | Description |
|---|---|
Authorization: Bearer | Required. The authorization bearer token. |
x-ms-principal-id | Required. The principal identifier. |
x-ms-client-request-id | Optional. The client request identifier. |
x-ms-client-session-id | Optional. The client session identifier. |
x-ms-principal-liveid | Optional. The principal Live identifier. |
An object that represents an add-on. The following table describes the key elements of the request body:
Element | Description |
|---|---|
AddOnId | The Identifier of the add-on. |
AddOnInstanceId | The identifier of the add-on instance. |
AquisitionTime | The acquisition time of the add-on. |
The response includes an HTTP status code, a set of response headers, and a response body.
A successful operation returns status code 201 (CREATED).
For information about status codes, see Status and Error Codes (Windows Azure Pack Service Management).
The response for this operation includes standard HTTP headers. All standard headers conform to the HTTP/1.1 protocol specification.
The add-on that was linked to the plan. The following table describes the elements of the request body.
Response header | Description |
|---|---|
AddOnId | The identifier of the add-on. |
AddOnInstanceId | The identifier of the add-on instance. |
AquisitionTime | The acquisition time of the add-on. |
The following code example shows a Link Add-on to Plan request.
POST https://<Computer>:30004/plans/GoldPhihoq8oa/addons HTTP/1.1
Authorization: Bearer <Token>
x-ms-principal-id: <COMPUTER>\Administrator
Accept-Language: en-US
x-ms-principal-liveid: <COMPUTER>\Administrator
Content-Type: application/json; charset=utf-8
Host: <Computer>:30004
Content-Length: 81
Expect: 100-continue
{
"AddOnId": "SqlAOsgdgwe034j1vrdgw",
"AddOnInstanceId": null,
"AcquisitionTime": null
}