Lens Scripting API
    Preparing search index...

    Enumeration ResponseCodeWearable Only

    Defines the possible outcomes of a purchase attempt in a Lens

    Index

    Enumeration Members

    Error: number

    A general error occurred during the purchase process that doesn't fit into the other specific categories. This could be due to various reasons, such as unexpected system issues, network problems, or other unhandled exceptions during the transaction. You might need to check the debugMessage for more details.

    ItemAlreadyOwned: number

    The user attempted to purchase an item they already own. This usually applies to non-consumable products that are not meant to be purchased multiple times.

    ItemNotOwned: number

    Indicates that an attempt was made to consume or interact with an item that the user does not currently own. This can happen if an item was previously consumed, refunded, or never purchased in the first place.

    ItemUnavailable: number

    The requested item cannot be purchased at this time, possibly due to regional restrictions, being out of stock, or not being published.

    NetworkError: number

    An issue with the network connection prevented the operation from completing successfully. This could be due to a lost internet connection or other network-related problems. Users should verify their network settings and try again.

    PaymentUnavailable: number

    An error occurred with the user's payment method or during the payment processing stage. This could be due to insufficient funds, an invalid payment method, or issues with the payment provider. The user might need to check their payment details or try again with a different method.

    ServiceDisconnected: number

    The connection to the commerce service was unexpectedly lost during an operation. This may be due to network instability or the service becoming unavailable. You may need to attempt to re-establish the connection.

    ServiceUnavailable: number

    The commerce backend service is temporarily down or experiencing issues. This is usually a transient problem, and users should be advised to try again later.

    Success: number

    The transaction was completed without any issues.

    UserCanceled: number

    The user intentionally stopped the purchase process, typically by closing the payment interface or declining the transaction. No purchase was made.