| « PreviousNext » | |
![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
The ActivateHostedProduct action takes in an activation
key for the customer and the product token for your product
and responds with a persistent identifier (PID) and user
token for a customer. Whether your product uses one or both of these depends on
the type of product and its needs:
Amazon Simple Storage Service web products must use the user token (for more information, see Overall Authentication Process). They can optionally also use the PID (for more information, see Verification of the Customer's Subscription Status).
Amazon S3 desktop products can optionally use the PID (for more information, see Verification of the Customer's Subscription Status).
Amazon EC2 AMI products can optionally use the PID (for more information, see Verification of a Customer's Subscription Status).
Note
If you want to use query string authentication with your web product (for more
information, see Query String Authentication with Web Products), you
must have a user token returned by a call made to ActivateHostedProduct after
May 15, 2008. You can update any user token so that it works with query
string authentication by calling RefreshUserToken.
Activation succeeds regardless of whether the credit card the customer presents at sign-up time is valid. Even though activation succeeds, your product shouldn't send requests to Amazon S3 until the customer is actually subscribed (which depends on the credit card vetting or sign-up charge succeeding). For more information about how to confirm when a customer is actually subscribed, see Activation and Subscription Timing.
Requests for ActivateHostedProduct must be made over HTTPS and
authenticated by AWS. For more information, see Authentication of REST-Query Requests (for REST-Query) or Authentication of SOAP Requests (for SOAP).
| Name | Description | Required |
|---|---|---|
|
|
The License Service action to perform. Set this to
Type: String Default: None Condition: Required for REST-Query requests (for more information, see REST-Query Requests). For SOAP requests, the action is automatically indicated in the SOAP request's root element (for more information, see SOAP Requests). |
Conditional |
|
|
The activation key. For more information, see The Activation Key. Type: String with a maximum 30 characters; the length of this key could change in the future Default: None |
Yes |
|
|
Your Access Key ID. For more information, see Your AWS Access Credentials. Type: String Default: None Condition: Required for REST-Query requests. Not applicable to SOAP requests. |
Conditional |
|
|
The date and time at which the signature included in the request expires. Type: String in the format YYYY-MM-DDThh:mm:ssZ, as specified in the ISO 8601 standard. Default: None Condition: REST-Query requests must include either the
|
Conditional |
|
|
The product token for your product, which is obtained during product
registration. For more information about registration, see Registering Your Product. The product
token is prefixed with the literal string
Type: String Default: None |
Yes |
|
|
A request signature. For more information, see Calculating an HMAC-SHA1 Request Signature. Type: String Default: None Condition: Required for REST-Query requests. Not applicable to SOAP requests. |
Conditional |
|
|
A legacy parameter AWS requires. Set this value to
Type: String Default: None Condition: Required for REST-Query requests. Not applicable to SOAP requests. |
Conditional |
|
|
The date and time the request is signed. Type: String in the format YYYY-MM-DDThh:mm:ssZ, as specified in the ISO 8601 standard. Default: None Condition: Authenticated REST-Query requests must include either the
|
Conditional |
|
|
The amount of elapsed time (in seconds) before the user token returned by the service should expire. The user token never expires unless you use this optional parameter. Once the user token expires, the product must reactive itself, or the customer won't be able to use it. For more information, see Reactivating the Product. Type: xsd:duration (in seconds) Default: No expiration time |
No |
|
|
The version of the API to use. For example:
Type: String Default: Condition: Highly recommended for REST-Query requests. Not applicable to SOAP requests (the API version is indicated in the namespace). |
Conditional |
The response to this action contains the following elements in addition to the elements returned in all successful responses. For more information, see Structure of a Successful Response.
| Name | Description |
|---|---|
|
|
A static identifier of 53 to 64 characters for the customer, specifically used by developers who own either Amazon EC2 AMI products (for more information, see Verification of a Customer's Subscription Status) or Amazon S3 desktop products (for more information, see Verification of the Customer's Subscription Status). Type: String Ancestor: |
|
|
The user token, which is prefixed with the literal string
Each time you request Type: String Ancestor: |
The errors listed in the following table are returned in addition to the errors returned by all actions. For more information, see Errors.
Important
We might throttle requests to the License Service as necessary. When we throttle, we return a 503 (service unavailable) HTTP status code. Your system should be prepared to retry any request that receives a 503 code.
| Name | Description |
|---|---|
|
|
The activation key is expired. Activation keys expire one hour after creation. Action to take:
|
|
|
The activation key does not correspond to the product token. Each activation key is associated with a particular customer and a particular product. This error occurs if you provide an activation key for a DevPay product other than the one represented by the product token. Action to take: Follow the instructions listed for
|
|
|
The activation key is invalid or malformed. Action to take: Same action as for
|
|
|
The product token is invalid for the signer. Action to take: Make sure you have copied the product token correctly. You can view the product token for your product at any time by clicking View Product Details on your DevPay Activity page (at http://aws.amazon.com/devpayactivity). |
The following example REST-Query request gets the user token and PID for a customer.
https://ls.amazonaws.com/
?Action=ActivateHostedProduct
&ActivationKey=ADMAY7DVLJTWHJ76MMBMQEXAMPLE
&ProductToken={ProductToken}YLFRL3e4lOHTgGSQa8BOKA....[long encoded token]...
&Version=2008-04-28
&AWSAccessKeyId=AKIAIOSFODNN7EXAMPLE
&Timestamp=2008-05-19T12:00:00Z
&Signature=Dqlp3Sd6ljTUA9Uf6SGtEExwUQEEXAMPLE=
&SignatureVersion=1
<ActivateHostedProductResponse>
<ActivateHostedProductResult>
<UserToken>
{UserToken}AAAHVXNlclRrbgfOpSykBAXO7g/zG....[long encoded token]...
</UserToken>
<PersistentIdentifier>
PMNGLKRRYHLOXDQKEMKLEXAMPLE
</PersistentIdentifier>
<ActivateHostedProductResult>
<ResponseMetadata>
<RequestId>
cb919c0a-9bce-4afe-9b48-9bdf2412bb67
</RequestId>
</ResponseMetadata>
</ActivateHostedProductResponse>