What type of GetEntitlements Response is received when a customer cancels his or her subscription before the expiry of the contract.

0

I am trying to integrate our product with AWS Marketplace using SaaS Contract plan. I am trying to implement a scenario where a customer deliberately cancels his subscription from the portal. Once I receive the SNS notification and call the GetEntitlments, how can I identify from the response that the contract has been cancelled. Please suggest.

PD
asked 2 months ago38 views
1 Answer
1
Accepted Answer

There are two SNS topics available for use when it comes to SaaS products on AWS marketplace:

  1. aws-mp-entitlement-notification: This topic notifies you when buyers create a new contract, upgrade it, renew it, or it expires.
  2. aws-mp-subscription-notification: This topic notifies you when a buyer subscribes to or unsubscribes (cancels a subscription) from a product.

For your use-case scenario, you need to subscribe to the SNS topic "aws-mp-subscription-notification".

When a user does unsubscribe from a product, a notification will be published to the SNS topic and delivered to its subscription. The message structure will be as follows:

{
    "action": "<action-name>",
    "customer-identifier": " X01EXAMPLEX",
    "product-code": "n0123EXAMPLEXXXXXXXXXXXX",
    "offer-identifier": "offer-abcexample123",
    "isFreeTrialTermPresent":"true"
}

The JSON attribute "action" in the above message will contain the information you need. If a user unsubscribes, the "action" attribute will have the following values in two different notifications:

  1. "unsubscribe-pending": This action type message is sent first when a user unsubscribes. This indicates that the seller has a limited time to get final metering records sent before the buyer is cancelled completely.
  2. "unsubscribe-success": The unsubscribe-success message signals the completion of cancellation.

Therefore, as soon as you receive a "unsubscribe-pending" message over the SNS topic "aws-mp-subscription-notification", it is an indication of user unsubscribing from the product.

You do not have to call the GetEntitlement API call explicitly to get that information.

answered 2 months ago
  • Thanks for your detailed answer. As I am configuring a Contract Plan and i am not sending any metering records to AWS, in that case, does this 'unsubscribe-pending' still get received into this SNS? Also for a Contract plan, will this notification still be published into the Subscription - Notification queue?

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions

Relevant questions