Documentation ¶
Overview ¶
Package marketplacemetering provides the client and types for making API requests to AWSMarketplace Metering.
This reference provides descriptions of the low-level AWS Marketplace Metering Service API.
AWS Marketplace sellers can use this API to submit usage data for custom usage dimensions.
Submitting Metering Records
MeterUsage- Submits the metering record for a Marketplace product. MeterUsage is called from an EC2 instance.
BatchMeterUsage- Submits the metering record for a set of customers. BatchMeterUsage is called from a software-as-a-service (SaaS) application.
Accepting New Customers
- ResolveCustomer- 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 the browser. The Registration Token is resolved through this API to obtain a CustomerIdentifier and Product Code.
Entitlement and Metering for Paid Container Products
- Paid container software products sold through AWS Marketplace must integrate with the AWS Marketplace Metering Service and call the RegisterUsage operation for software entitlement and metering. Calling RegisterUsage from containers running outside of Amazon Elastic Container Service (Amazon ECR) isn't supported. Free and BYOL products for ECS aren't required to call RegisterUsage, but you can do so if you want to receive usage data in your seller reports. For more information on using the RegisterUsage operation, see Container-Based Products (https://docs.aws.amazon.com/latest/userguide/entitlement-and-metering-for-paid-products.html).
BatchMeterUsage API calls are captured by AWS CloudTrail. You can use Cloudtrail to verify that the SaaS metering records that you sent are accurate by searching for records with the eventName of BatchMeterUsage. You can also use CloudTrail to audit records over time. For more information, see the AWS CloudTrail User Guide (http://docs.aws.amazon.com/awscloudtrail/latest/userguide/cloudtrail-concepts.html).
See https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14 for more information on this service.
See marketplacemetering package documentation for more information. https://docs.aws.amazon.com/sdk-for-go/api/service/marketplacemetering/
Using the Client ¶
To AWSMarketplace Metering with the SDK use the New function to create a new service client. With that client you can make API requests to the service. These clients are safe to use concurrently.
See the SDK's documentation for more information on how to use the SDK. https://docs.aws.amazon.com/sdk-for-go/api/
See aws.Config documentation for more information on configuring SDK clients. https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config
See the AWSMarketplace Metering client MarketplaceMetering for more information on creating client for this service. https://docs.aws.amazon.com/sdk-for-go/api/service/marketplacemetering/#New
Index ¶
- Constants
- type BatchMeterUsageInput
- type BatchMeterUsageOutput
- type BatchMeterUsageRequest
- type MarketplaceMetering
- func (c *MarketplaceMetering) BatchMeterUsageRequest(input *BatchMeterUsageInput) BatchMeterUsageRequest
- func (c *MarketplaceMetering) MeterUsageRequest(input *MeterUsageInput) MeterUsageRequest
- func (c *MarketplaceMetering) RegisterUsageRequest(input *RegisterUsageInput) RegisterUsageRequest
- func (c *MarketplaceMetering) ResolveCustomerRequest(input *ResolveCustomerInput) ResolveCustomerRequest
- type MeterUsageInput
- type MeterUsageOutput
- type MeterUsageRequest
- type RegisterUsageInput
- type RegisterUsageOutput
- type RegisterUsageRequest
- type ResolveCustomerInput
- type ResolveCustomerOutput
- type ResolveCustomerRequest
- type UsageRecord
- type UsageRecordResult
- type UsageRecordResultStatus
Constants ¶
const ( // ErrCodeCustomerNotEntitledException for service response error code // "CustomerNotEntitledException". // // Exception thrown when the customer does not have a valid subscription for // the product. ErrCodeCustomerNotEntitledException = "CustomerNotEntitledException" // ErrCodeDisabledApiException for service response error code // "DisabledApiException". // // The API is disabled in the Region. ErrCodeDisabledApiException = "DisabledApiException" // ErrCodeDuplicateRequestException for service response error code // "DuplicateRequestException". // // A metering record has already been emitted by the same EC2 instance for the // given {usageDimension, timestamp} with a different usageQuantity. ErrCodeDuplicateRequestException = "DuplicateRequestException" // ErrCodeExpiredTokenException for service response error code // "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. ErrCodeExpiredTokenException = "ExpiredTokenException" // ErrCodeInternalServiceErrorException for service response error code // "InternalServiceErrorException". // // An internal error has occurred. Retry your request. If the problem persists, // post a message with details on the AWS forums. ErrCodeInternalServiceErrorException = "InternalServiceErrorException" // ErrCodeInvalidCustomerIdentifierException for service response error code // "InvalidCustomerIdentifierException". // // You have metered usage for a CustomerIdentifier that does not exist. ErrCodeInvalidCustomerIdentifierException = "InvalidCustomerIdentifierException" // ErrCodeInvalidEndpointRegionException for service response error code // "InvalidEndpointRegionException". // // The endpoint being called is in a Region different from your EC2 instance. // The Region of the Metering Service endpoint and the Region of the EC2 instance // must match. ErrCodeInvalidEndpointRegionException = "InvalidEndpointRegionException" // ErrCodeInvalidProductCodeException for service response error code // "InvalidProductCodeException". // // The product code passed does not match the product code used for publishing // the product. ErrCodeInvalidProductCodeException = "InvalidProductCodeException" // ErrCodeInvalidPublicKeyVersionException for service response error code // "InvalidPublicKeyVersionException". // // Public Key version is invalid. ErrCodeInvalidPublicKeyVersionException = "InvalidPublicKeyVersionException" // ErrCodeInvalidRegionException for service response error code // "InvalidRegionException". // // RegisterUsage must be called in the same AWS Region the ECS task was launched // in. This prevents a container from hardcoding a Region (e.g. withRegion(“us-east-1”) // when calling RegisterUsage. ErrCodeInvalidRegionException = "InvalidRegionException" // ErrCodeInvalidTokenException for service response error code // "InvalidTokenException". // // Registration token is invalid. ErrCodeInvalidTokenException = "InvalidTokenException" // ErrCodeInvalidUsageDimensionException for service response error code // "InvalidUsageDimensionException". // // The usage dimension does not match one of the UsageDimensions associated // with products. ErrCodeInvalidUsageDimensionException = "InvalidUsageDimensionException" // ErrCodePlatformNotSupportedException for service response error code // "PlatformNotSupportedException". // // AWS Marketplace does not support metering usage from the underlying platform. // Currently, only Amazon ECS is supported. ErrCodePlatformNotSupportedException = "PlatformNotSupportedException" // ErrCodeThrottlingException for service response error code // "ThrottlingException". // // The calls to the API are throttled. ErrCodeThrottlingException = "ThrottlingException" // ErrCodeTimestampOutOfBoundsException for service response error code // "TimestampOutOfBoundsException". // // The timestamp value passed in the meterUsage() is out of allowed range. ErrCodeTimestampOutOfBoundsException = "TimestampOutOfBoundsException" )
const ( ServiceName = "metering.marketplace" // Service endpoint prefix API calls made to. EndpointsID = ServiceName // Service ID for Regions and Endpoints metadata. )
Service information constants
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BatchMeterUsageInput ¶
type BatchMeterUsageInput struct { // Product code is used to uniquely identify a product in AWS Marketplace. The // product code should be the same as the one used during the publishing of // a new product. // // ProductCode is a required field ProductCode *string `min:"1" type:"string" required:"true"` // The set of UsageRecords to submit. BatchMeterUsage accepts up to 25 UsageRecords // at a time. // // UsageRecords is a required field UsageRecords []UsageRecord `type:"list" required:"true"` // contains filtered or unexported fields }
A BatchMeterUsageRequest contains UsageRecords, which indicate quantities of usage within your application. Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/BatchMeterUsageRequest
func (BatchMeterUsageInput) GoString ¶
func (s BatchMeterUsageInput) GoString() string
GoString returns the string representation
func (BatchMeterUsageInput) String ¶
func (s BatchMeterUsageInput) String() string
String returns the string representation
func (*BatchMeterUsageInput) Validate ¶
func (s *BatchMeterUsageInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type BatchMeterUsageOutput ¶
type BatchMeterUsageOutput struct { // Contains all UsageRecords processed by BatchMeterUsage. These records were // either honored by AWS Marketplace Metering Service or were invalid. Results []UsageRecordResult `type:"list"` // Contains all UsageRecords that were not processed by BatchMeterUsage. This // is a list of UsageRecords. You can retry the failed request by making another // BatchMeterUsage call with this list as input in the BatchMeterUsageRequest. UnprocessedRecords []UsageRecord `type:"list"` // contains filtered or unexported fields }
Contains the UsageRecords processed by BatchMeterUsage and any records that have failed due to transient error. Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/BatchMeterUsageResult
func (BatchMeterUsageOutput) GoString ¶
func (s BatchMeterUsageOutput) GoString() string
GoString returns the string representation
func (BatchMeterUsageOutput) SDKResponseMetadata ¶
func (s BatchMeterUsageOutput) SDKResponseMetadata() aws.Response
SDKResponseMetdata return sthe response metadata for the API.
func (BatchMeterUsageOutput) String ¶
func (s BatchMeterUsageOutput) String() string
String returns the string representation
type BatchMeterUsageRequest ¶
type BatchMeterUsageRequest struct { *aws.Request Input *BatchMeterUsageInput Copy func(*BatchMeterUsageInput) BatchMeterUsageRequest }
BatchMeterUsageRequest is a API request type for the BatchMeterUsage API operation.
func (BatchMeterUsageRequest) Send ¶
func (r BatchMeterUsageRequest) Send() (*BatchMeterUsageOutput, error)
Send marshals and sends the BatchMeterUsage API request.
type MarketplaceMetering ¶
MarketplaceMetering provides the API operation methods for making requests to AWSMarketplace Metering. See this package's package overview docs for details on the service.
MarketplaceMetering methods are safe to use concurrently. It is not safe to modify mutate any of the struct's properties though.
func New ¶
func New(config aws.Config) *MarketplaceMetering
New creates a new instance of the MarketplaceMetering client with a config.
Example:
// Create a MarketplaceMetering client from just a config. svc := marketplacemetering.New(myConfig)
func (*MarketplaceMetering) BatchMeterUsageRequest ¶
func (c *MarketplaceMetering) BatchMeterUsageRequest(input *BatchMeterUsageInput) BatchMeterUsageRequest
BatchMeterUsageRequest returns a request value for making API operation for AWSMarketplace Metering.
BatchMeterUsage is called from a SaaS application listed on the AWS Marketplace to post metering records for a set of customers.
For identical requests, the API is idempotent; requests can be retried with the same records or a subset of the input records.
Every request to BatchMeterUsage is for one product. If you need to meter usage for multiple products, you must make multiple calls to BatchMeterUsage.
BatchMeterUsage can process up to 25 UsageRecords at a time.
// Example sending a request using the BatchMeterUsageRequest method. req := client.BatchMeterUsageRequest(params) resp, err := req.Send() if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/BatchMeterUsage
func (*MarketplaceMetering) MeterUsageRequest ¶
func (c *MarketplaceMetering) MeterUsageRequest(input *MeterUsageInput) MeterUsageRequest
MeterUsageRequest returns a request value for making API operation for AWSMarketplace Metering.
API to emit metering records. For identical requests, the API is idempotent. It simply returns the metering record ID.
MeterUsage is authenticated on the buyer's AWS account, generally when running from an EC2 instance on the AWS Marketplace.
// Example sending a request using the MeterUsageRequest method. req := client.MeterUsageRequest(params) resp, err := req.Send() if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/MeterUsage
func (*MarketplaceMetering) RegisterUsageRequest ¶ added in v0.6.0
func (c *MarketplaceMetering) RegisterUsageRequest(input *RegisterUsageInput) RegisterUsageRequest
RegisterUsageRequest returns a request value for making API operation for AWSMarketplace Metering.
Paid container software products sold through AWS Marketplace must integrate with the AWS Marketplace Metering Service and call the RegisterUsage operation for software entitlement and metering. Calling RegisterUsage from containers running outside of ECS is not currently supported. Free and BYOL products for ECS aren't required to call RegisterUsage, but you may choose to do so if you would like to receive usage data in your seller reports. The sections below explain the behavior of RegisterUsage. RegisterUsage performs two primary functions: metering and entitlement.
Entitlement: RegisterUsage allows you to verify that the customer running your paid software is subscribed to your product on AWS Marketplace, enabling you to guard against unauthorized use. Your container image that integrates with RegisterUsage is only required to guard against unauthorized use at container startup, as such a CustomerNotSubscribedException/PlatformNotSupportedException will only be thrown on the initial call to RegisterUsage. Subsequent calls from the same Amazon ECS task instance (e.g. task-id) will not throw a CustomerNotSubscribedException, even if the customer unsubscribes while the Amazon ECS task is still running.
Metering: RegisterUsage meters software use per ECS task, per hour, with usage prorated to the second. A minimum of 1 minute of usage applies to tasks that are short lived. For example, if a customer has a 10 node ECS cluster and creates an ECS service configured as a Daemon Set, then ECS will launch a task on all 10 cluster nodes and the customer will be charged: (10 * hourly_rate). Metering for software use is automatically handled by the AWS Marketplace Metering Control Plane -- your software is not required to perform any metering specific actions, other than call RegisterUsage once for metering of software use to commence. The AWS Marketplace Metering Control Plane will also continue to bill customers for running ECS tasks, regardless of the customers subscription state, removing the need for your software to perform entitlement checks at runtime.
// Example sending a request using the RegisterUsageRequest method. req := client.RegisterUsageRequest(params) resp, err := req.Send() if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/RegisterUsage
func (*MarketplaceMetering) ResolveCustomerRequest ¶
func (c *MarketplaceMetering) ResolveCustomerRequest(input *ResolveCustomerInput) ResolveCustomerRequest
ResolveCustomerRequest returns a request value for making API operation for AWSMarketplace Metering.
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 and product code.
// Example sending a request using the ResolveCustomerRequest method. req := client.ResolveCustomerRequest(params) resp, err := req.Send() if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/ResolveCustomer
type MeterUsageInput ¶
type MeterUsageInput struct { // Checks whether you have the permissions required for the action, but does // not make the request. If you have the permissions, the request returns DryRunOperation; // otherwise, it returns UnauthorizedException. // // DryRun is a required field DryRun *bool `type:"boolean" required:"true"` // Product code is used to uniquely identify a product in AWS Marketplace. The // product code should be the same as the one used during the publishing of // a new product. // // ProductCode is a required field ProductCode *string `min:"1" type:"string" required:"true"` // Timestamp of the hour, recorded in UTC. The seconds and milliseconds portions // of the timestamp will be ignored. // // Timestamp is a required field Timestamp *time.Time `type:"timestamp" timestampFormat:"unix" required:"true"` // It will be one of the fcp dimension name provided during the publishing of // the product. // // UsageDimension is a required field UsageDimension *string `min:"1" type:"string" required:"true"` // Consumption value for the hour. // // UsageQuantity is a required field UsageQuantity *int64 `type:"integer" required:"true"` // contains filtered or unexported fields }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/MeterUsageRequest
func (MeterUsageInput) GoString ¶
func (s MeterUsageInput) GoString() string
GoString returns the string representation
func (MeterUsageInput) String ¶
func (s MeterUsageInput) String() string
String returns the string representation
func (*MeterUsageInput) Validate ¶
func (s *MeterUsageInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type MeterUsageOutput ¶
type MeterUsageOutput struct { // Metering record id. MeteringRecordId *string `type:"string"` // contains filtered or unexported fields }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/MeterUsageResult
func (MeterUsageOutput) GoString ¶
func (s MeterUsageOutput) GoString() string
GoString returns the string representation
func (MeterUsageOutput) SDKResponseMetadata ¶
func (s MeterUsageOutput) SDKResponseMetadata() aws.Response
SDKResponseMetdata return sthe response metadata for the API.
func (MeterUsageOutput) String ¶
func (s MeterUsageOutput) String() string
String returns the string representation
type MeterUsageRequest ¶
type MeterUsageRequest struct { *aws.Request Input *MeterUsageInput Copy func(*MeterUsageInput) MeterUsageRequest }
MeterUsageRequest is a API request type for the MeterUsage API operation.
func (MeterUsageRequest) Send ¶
func (r MeterUsageRequest) Send() (*MeterUsageOutput, error)
Send marshals and sends the MeterUsage API request.
type RegisterUsageInput ¶ added in v0.6.0
type RegisterUsageInput struct { // (Optional) To scope down the registration to a specific running software // instance and guard against replay attacks. Nonce *string `type:"string"` // Product code is used to uniquely identify a product in AWS Marketplace. The // product code should be the same as the one used during the publishing of // a new product. // // ProductCode is a required field ProductCode *string `min:"1" type:"string" required:"true"` // Public Key Version provided by AWS Marketplace // // PublicKeyVersion is a required field PublicKeyVersion *int64 `min:"1" type:"integer" required:"true"` // contains filtered or unexported fields }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/RegisterUsageRequest
func (RegisterUsageInput) GoString ¶ added in v0.6.0
func (s RegisterUsageInput) GoString() string
GoString returns the string representation
func (RegisterUsageInput) String ¶ added in v0.6.0
func (s RegisterUsageInput) String() string
String returns the string representation
func (*RegisterUsageInput) Validate ¶ added in v0.6.0
func (s *RegisterUsageInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type RegisterUsageOutput ¶ added in v0.6.0
type RegisterUsageOutput struct { // (Optional) Only included when public key version has expired PublicKeyRotationTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` // JWT Token Signature *string `type:"string"` // contains filtered or unexported fields }
Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/RegisterUsageResult
func (RegisterUsageOutput) GoString ¶ added in v0.6.0
func (s RegisterUsageOutput) GoString() string
GoString returns the string representation
func (RegisterUsageOutput) SDKResponseMetadata ¶ added in v0.6.0
func (s RegisterUsageOutput) SDKResponseMetadata() aws.Response
SDKResponseMetdata return sthe response metadata for the API.
func (RegisterUsageOutput) String ¶ added in v0.6.0
func (s RegisterUsageOutput) String() string
String returns the string representation
type RegisterUsageRequest ¶ added in v0.6.0
type RegisterUsageRequest struct { *aws.Request Input *RegisterUsageInput Copy func(*RegisterUsageInput) RegisterUsageRequest }
RegisterUsageRequest is a API request type for the RegisterUsage API operation.
func (RegisterUsageRequest) Send ¶ added in v0.6.0
func (r RegisterUsageRequest) Send() (*RegisterUsageOutput, error)
Send marshals and sends the RegisterUsage API request.
type ResolveCustomerInput ¶
type ResolveCustomerInput struct { // 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 and product code. // // RegistrationToken is a required field RegistrationToken *string `type:"string" required:"true"` // contains filtered or unexported fields }
Contains input to the ResolveCustomer operation. Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/ResolveCustomerRequest
func (ResolveCustomerInput) GoString ¶
func (s ResolveCustomerInput) GoString() string
GoString returns the string representation
func (ResolveCustomerInput) String ¶
func (s ResolveCustomerInput) String() string
String returns the string representation
func (*ResolveCustomerInput) Validate ¶
func (s *ResolveCustomerInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type ResolveCustomerOutput ¶
type ResolveCustomerOutput struct { // The CustomerIdentifier is used to identify an individual customer in your // application. Calls to BatchMeterUsage require CustomerIdentifiers for each // UsageRecord. CustomerIdentifier *string `min:"1" type:"string"` // 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. ProductCode *string `min:"1" type:"string"` // contains filtered or unexported fields }
The result of the ResolveCustomer operation. Contains the CustomerIdentifier and product code. Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/ResolveCustomerResult
func (ResolveCustomerOutput) GoString ¶
func (s ResolveCustomerOutput) GoString() string
GoString returns the string representation
func (ResolveCustomerOutput) SDKResponseMetadata ¶
func (s ResolveCustomerOutput) SDKResponseMetadata() aws.Response
SDKResponseMetdata return sthe response metadata for the API.
func (ResolveCustomerOutput) String ¶
func (s ResolveCustomerOutput) String() string
String returns the string representation
type ResolveCustomerRequest ¶
type ResolveCustomerRequest struct { *aws.Request Input *ResolveCustomerInput Copy func(*ResolveCustomerInput) ResolveCustomerRequest }
ResolveCustomerRequest is a API request type for the ResolveCustomer API operation.
func (ResolveCustomerRequest) Send ¶
func (r ResolveCustomerRequest) Send() (*ResolveCustomerOutput, error)
Send marshals and sends the ResolveCustomer API request.
type UsageRecord ¶
type UsageRecord struct { // The CustomerIdentifier is obtained through the ResolveCustomer operation // and represents an individual buyer in your application. // // CustomerIdentifier is a required field CustomerIdentifier *string `min:"1" type:"string" required:"true"` // During the process of registering a product on AWS Marketplace, up to eight // dimensions are specified. These represent different units of value in your // application. // // Dimension is a required field Dimension *string `min:"1" type:"string" required:"true"` // The quantity of usage consumed by the customer for the given dimension and // time. // // Quantity is a required field Quantity *int64 `type:"integer" required:"true"` // Timestamp of the hour, recorded in UTC. The seconds and milliseconds portions // of the timestamp will be ignored. // // Your application can meter usage for up to one hour in the past. // // Timestamp is a required field Timestamp *time.Time `type:"timestamp" timestampFormat:"unix" required:"true"` // contains filtered or unexported fields }
A UsageRecord indicates a quantity of usage for a given product, customer, dimension and time.
Multiple requests with the same UsageRecords as input will be deduplicated to prevent double charges. Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/UsageRecord
func (UsageRecord) GoString ¶
func (s UsageRecord) GoString() string
GoString returns the string representation
func (UsageRecord) String ¶
func (s UsageRecord) String() string
String returns the string representation
func (*UsageRecord) Validate ¶
func (s *UsageRecord) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type UsageRecordResult ¶
type UsageRecordResult struct { // The MeteringRecordId is a unique identifier for this metering event. MeteringRecordId *string `type:"string"` // The UsageRecordResult Status indicates the status of an individual UsageRecord // processed by BatchMeterUsage. // // * Success- The UsageRecord was accepted and honored by BatchMeterUsage. // // * CustomerNotSubscribed- The CustomerIdentifier specified is not subscribed // to your product. The UsageRecord was not honored. Future UsageRecords // for this customer will fail until the customer subscribes to your product. // // * DuplicateRecord- Indicates that the UsageRecord was invalid and not // honored. A previously metered UsageRecord had the same customer, dimension, // and time, but a different quantity. Status UsageRecordResultStatus `type:"string" enum:"true"` // The UsageRecord that was part of the BatchMeterUsage request. UsageRecord *UsageRecord `type:"structure"` // contains filtered or unexported fields }
A UsageRecordResult indicates the status of a given UsageRecord processed by BatchMeterUsage. Please also see https://docs.aws.amazon.com/goto/WebAPI/meteringmarketplace-2016-01-14/UsageRecordResult
func (UsageRecordResult) GoString ¶
func (s UsageRecordResult) GoString() string
GoString returns the string representation
func (UsageRecordResult) String ¶
func (s UsageRecordResult) String() string
String returns the string representation
type UsageRecordResultStatus ¶
type UsageRecordResultStatus string
const ( UsageRecordResultStatusSuccess UsageRecordResultStatus = "Success" UsageRecordResultStatusCustomerNotSubscribed UsageRecordResultStatus = "CustomerNotSubscribed" UsageRecordResultStatusDuplicateRecord UsageRecordResultStatus = "DuplicateRecord" )
Enum values for UsageRecordResultStatus
func (UsageRecordResultStatus) MarshalValue ¶ added in v0.3.0
func (enum UsageRecordResultStatus) MarshalValue() (string, error)
func (UsageRecordResultStatus) MarshalValueBuf ¶ added in v0.3.0
func (enum UsageRecordResultStatus) MarshalValueBuf(b []byte) ([]byte, error)
Directories ¶
Path | Synopsis |
---|---|
Package marketplacemeteringiface provides an interface to enable mocking the AWSMarketplace Metering service client for testing your code.
|
Package marketplacemeteringiface provides an interface to enable mocking the AWSMarketplace Metering service client for testing your code. |