Skip to content

Commit 43e24af

Browse files
authored
Merge pull request #78470 from qianw211/webhook
webhook changes re-entered
2 parents 8550ba8 + d95e769 commit 43e24af

File tree

2 files changed

+53
-35
lines changed

2 files changed

+53
-35
lines changed

articles/marketplace/cloud-partner-portal/saas-app/cpp-saas-fulfillment-api-v2.md

Lines changed: 26 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,6 @@ The resolve endpoint enables the publisher to resolve a marketplace token to a p
105105

106106
| | |
107107
| --------------- | --------------- |
108-
| Content-Type | `application/json` |
109108
| x-ms-requestid | Unique string value for tracking the request from the client, preferably a GUID. If this value is not provided, one will be generated and provided in the response headers. |
110109
| x-ms-correlationid | Unique string value for operation on the client. This parameter correlates all events from client operation with events on the server side. If this value is not provided, one will be generated and provided in the response headers. |
111110
| authorization | [Get JSON web token (JWT) bearer token](https://docs.microsoft.com/azure/marketplace/cloud-partner-portal/saas-app/cpp-saas-registration#get-a-token-based-on-the-azure-ad-app) |
@@ -353,6 +352,7 @@ Internal Server Error<br>
353352

354353
| | |
355354
| --------------- | --------------- |
355+
| Content-Type | `application/json` |
356356
| ApiVersion | Version of the operation to use for this request |
357357
| subscriptionId | Unique identifier of the SaaS subscription that's obtained after resolving the token using the Resolve API |
358358

@@ -784,26 +784,35 @@ The publisher must implement a webhook in this SaaS service to proactively notif
784784

785785
```json
786786
{
787-
"operationId": "<guid>",
788-
"activityId": "<guid>",
789-
"subscriptionId":"<guid>",
790-
"offerId": "offer1",
791-
"publisherId": "contoso",
792-
"planId": "silver",
793-
"quantity": "20" ,
794-
"action": "Subscribe",
795-
"timeStamp": "2018-12-01T00:00:00"
787+
"id": "<this is a Guid operation id, you can call operations API with this to get status>",
788+
"activityId": "<this is a Guid correlation id>",
789+
"subscriptionId": "<Guid to uniquely identify this resource>",
790+
"publisherId": "<this is the publisher’s name>",
791+
"offerId": "<this is the offer name>",
792+
"planId": "<this is the plan id>",
793+
"quantity": "<the number of seats, will be null if not per-seat saas offer>",
794+
"timeStamp": "2019-04-15T20:17:31.7350641Z",
795+
"action": "Unsubscribe",
796+
"status": "NotStarted"
796797
}
797798
```
798799

799800
Where action can be one of these:
800-
- `Subscribe` (When the resource has been activated)
801-
- `Unsubscribe` (When the resource has been deleted)
802-
- `ChangePlan` (When the change plan operation has completed)
803-
- `ChangeQuantity` (When the change quantity operation has completed)
804-
- `Suspend` (When the resource has been suspended)
805-
- `Reinstate` (When resource has been reinstated after suspension)
806-
801+
- `Subscribe`, (When the resource has been activated)
802+
- `Unsubscribe`, (When the resource has been deleted)
803+
- `ChangePlan`, (When the change plan operation has completed)
804+
- `ChangeQuantity`, (When the change quantity operation has completed),
805+
- `Suspend`, (When resource has been suspended)
806+
- `Reinstate`, (When resource has been reinstated after suspension)
807+
808+
Where status can be one of these: <br>
809+
- NotStarted, <br>
810+
- InProgress, <br>
811+
- Succeeded, <br>
812+
- Failed, <br>
813+
- Conflict <br>
814+
815+
Actionable statuses are Succeeded and Failed in a webhook notification. An operation's lifecycle is from NotStarted to a terminal state like Succeeded/Failed/Conflict. If you receive Not started or in progress, please continue to request the status via GET operation API until the operation reaches a terminal state before taking any action.
807816

808817
## Mock API
809818

articles/marketplace/partner-center-portal/pc-saas-fulfillment-api-v2.md

Lines changed: 27 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -778,26 +778,35 @@ The publisher must implement a webhook in this SaaS service to proactively notif
778778

779779
```json
780780
{
781-
"operationId": "<guid>",
782-
"activityId": "<guid>",
783-
"subscriptionId":"<guid>",
784-
"offerId": "offer1",
785-
"publisherId": "contoso",
786-
"planId": "silver",
787-
"quantity": "20" ,
788-
"action": "Subscribe",
789-
"timeStamp": "2018-12-01T00:00:00"
781+
"id": "<this is a Guid operation id, you can call operations API with this to get status>",
782+
"activityId": "<this is a Guid correlation id>",
783+
"subscriptionId": "<Guid to uniquely identify this resource>",
784+
"publisherId": "<this is the publisher’s name>",
785+
"offerId": "<this is the offer name>",
786+
"planId": "<this is the plan id>",
787+
"quantity": "<the number of seats, will be null if not per-seat saas offer>",
788+
"timeStamp": "2019-04-15T20:17:31.7350641Z",
789+
"action": "Unsubscribe",
790+
"status": "NotStarted"
791+
790792
}
791793
```
792-
793-
Where action can be one of the following:
794-
- `Subscribe` (When the resource has been activated)
795-
- `Unsubscribe` (When the resource has been deleted)
796-
- `ChangePlan` (When the change plan operation has completed)
797-
- `ChangeQuantity` (When the change quantity operation has completed)
798-
- `Suspend` (When the resource has been suspended)
799-
- `Reinstate` (When resource has been reinstated after suspension)
800-
794+
Where action can be one of these:
795+
- `Subscribe`, (When the resource has been activated)
796+
- `Unsubscribe`, (When the resource has been deleted)
797+
- `ChangePlan`, (When the change plan operation has completed)
798+
- `ChangeQuantity`, (When the change quantity operation has completed),
799+
- `Suspend`, (When resource has been suspended)
800+
- `Reinstate`, (When resource has been reinstated after suspension)
801+
802+
Where status can be one of these: <br>
803+
- NotStarted, <br>
804+
- InProgress, <br>
805+
- Succeeded, <br>
806+
- Failed, <br>
807+
- Conflict <br>
808+
809+
Actionable statuses are Succeeded and Failed in a webhook notification. An operation's lifecycle is from NotStarted to a terminal state like Succeeded/Failed/Conflict. If you receive Not started or in progress, please continue to request the status via GET operation API until the operation reaches a terminal state before taking any action.
801810

802811
## Mock API
803812

0 commit comments

Comments
 (0)