ResolveCustomer
ResolveCustomer
is called by a SaaS application during the registration
process. When a buyer visits your website during the registration process, the buyer
submits a registration token through their browser. The registration token is resolved
through this API to obtain a CustomerIdentifier
along with the
CustomerAWSAccountId
and ProductCode
.
Note
The API needs to called from the seller account id used to publish the SaaS application to successfully resolve the token.
For an example of using ResolveCustomer
, see ResolveCustomer code example in the
AWS Marketplace Seller
Guide.
Permission is required for this operation. Your IAM role or user performing this
operation requires a policy to allow the aws-marketplace:ResolveCustomer
action. For more information, see Actions, resources, and condition keys for AWS Marketplace Metering Service in
the Service Authorization Reference.
ResolveCustomer
is supported in the following AWS Regions:
- Commercial Regions
-
eu-north-1, me-south-1, ap-south-1, eu-west-3, ap-southeast-3, us-east-2, af-south-1, eu-west-1,me-central-1, eu-central-1, sa-east-1, ap-east-1, ap-south-2, us-east-1, ap-northeast-2, ap-northeast-3, eu-west-2, ap-southeast-4, eu-south-1, ap-northeast-1, us-west-2, us-west-1, ap-southeast-1, ap-southeast-2, il-central-1, ca-central-1, eu-south-2, eu-central-2
- China Regions
-
cn-northwest-1
Request Syntax
{
"RegistrationToken": "string
"
}
Request Parameters
The request accepts the following data in JSON format.
Note
In the following list, the required parameters are described first.
- RegistrationToken
-
When a buyer visits your website during the registration process, the buyer submits a registration token through the browser. The registration token is resolved to obtain a
CustomerIdentifier
along with theCustomerAWSAccountId
andProductCode
.Type: String
Pattern:
[\s\S]+
Required: Yes
Response Syntax
{
"CustomerAWSAccountId": "string",
"CustomerIdentifier": "string",
"ProductCode": "string"
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- CustomerAWSAccountId
-
The
CustomerAWSAccountId
provides the AWS account ID associated with theCustomerIdentifier
for the individual customer.Type: String
Length Constraints: Minimum length of 1. Maximum length of 255.
Pattern:
^[0-9]+$
- CustomerIdentifier
-
The
CustomerIdentifier
is used to identify an individual customer in your application. Calls toBatchMeterUsage
requireCustomerIdentifiers
for eachUsageRecord
.Type: String
Length Constraints: Minimum length of 1. Maximum length of 255.
Pattern:
[\s\S]+
- ProductCode
-
The product code is returned to confirm that the buyer is registering for your product. Subsequent
BatchMeterUsage
calls should be made using this product code.Type: String
Length Constraints: Minimum length of 1. Maximum length of 255.
Pattern:
^[-a-zA-Z0-9/=:_.@]*$
Errors
For information about the errors that are common to all actions, see Common Errors.
- DisabledApiException
-
The API is disabled in the Region.
HTTP Status Code: 400
- ExpiredTokenException
-
The submitted registration token has expired. This can happen if the buyer's browser takes too long to redirect to your page, the buyer has resubmitted the registration token, or your application has held on to the registration token for too long. Your SaaS registration website should redeem this token as soon as it is submitted by the buyer's browser.
HTTP Status Code: 400
- InternalServiceErrorException
-
An internal error has occurred. Retry your request. If the problem persists, post a message with details on the AWS forums.
HTTP Status Code: 500
- InvalidTokenException
-
Registration token is invalid.
HTTP Status Code: 400
- ThrottlingException
-
The calls to the API are throttled.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: