docs.unity.cn
    Show / Hide Table of Contents

    Enum StoreSpecificPurchaseErrorCode

    The various reasons a purchase can fail. These codes are store-specific, so that developers can have access to to a wider range of debugging information.

    Namespace: UnityEngine.Purchasing
    Syntax
    public enum StoreSpecificPurchaseErrorCode

    Fields

    Name Description Value
    SKErrorUnknown

    Error code indicating that an unknown or unexpected error occurred. (Apple only)


    0
    SKErrorClientInvalid

    Error code indicating that the client is not allowed to perform the attempted action. (Apple only)


    1
    SKErrorPaymentCancelled

    Error code indicating that the user cancelled a payment request. (Apple only)


    2
    SKErrorPaymentInvalid

    Error code indicating that one of the payment parameters was not recognized by the App Store. (Apple only)


    3
    SKErrorPaymentNotAllowed

    Error code indicating that the user is not allowed to authorize payments. (Apple only)


    4
    SKErrorStoreProductNotAvailable

    Error code indicating that the requested product is not available in the store. (Apple only)


    5
    SKErrorCloudServicePermissionDenied

    Error code indicating that the user has not allowed access to Cloud service information. (Apple only)


    6
    SKErrorCloudServiceNetworkConnectionFailed

    Error code indicating that the device could not connect to the network. (Apple only)


    7
    SKErrorCloudServiceRevoked

    Error code indicating that the user has revoked permission to use this cloud service. (Apple only)


    8
    BILLING_RESPONSE_RESULT_OK

    Success. Note, this is technically not an error code, but is included for completeness. (Google Play only)


    9
    BILLING_RESPONSE_RESULT_USER_CANCELED

    User pressed back or canceled a dialog. (Google Play only)


    10
    BILLING_RESPONSE_RESULT_SERVICE_UNAVAILABLE

    Network connection is down. (Google Play only)


    11
    BILLING_RESPONSE_RESULT_BILLING_UNAVAILABLE

    Billing API version is not supported for the type requested. (Google Play only)


    12
    BILLING_RESPONSE_RESULT_ITEM_UNAVAILABLE

    Requested product is not available for purchase. (Google Play only)


    13
    BILLING_RESPONSE_RESULT_DEVELOPER_ERROR

    Invalid arguments provided to the API. This error can also indicate that the application was not correctly signed or properly set up for In-app Billing in Google Play, or does not have the necessary permissions in its manifest (Google Play only)


    14
    BILLING_RESPONSE_RESULT_ERROR

    Fatal error during the API action. (Google Play only)


    15
    BILLING_RESPONSE_RESULT_ITEM_ALREADY_OWNED

    Failure to purchase since item is already owned. (Google Play only)


    16
    BILLING_RESPONSE_RESULT_ITEM_NOT_OWNED

    Failure to consume since item is not owned. (Google Play only)


    17
    IABHELPER_ERROR_BASE

    In-App Billing helper base error. (GooglePlay only)


    18
    IABHELPER_REMOTE_EXCEPTION

    In-App Billing helper encountered a remote exception. (GooglePlay only)


    19
    IABHELPER_BAD_RESPONSE

    In-App Billing helper received a bad response. (GooglePlay only)


    20
    IABHELPER_VERIFICATION_FAILED

    In-App Billing helper had a failed verification. (GooglePlay only)


    21
    IABHELPER_SEND_INTENT_FAILED

    In-App Billing helper found a failed intent. (GooglePlay only)


    22
    IABHELPER_USER_CANCELLED

    In-App Billing helper encountered a user cancellation. (GooglePlay only)


    23
    IABHELPER_UNKNOWN_PURCHASE_RESPONSE

    In-App Billing helper receieved an unknown purchase response. (GooglePlay only)


    24
    IABHELPER_MISSING_TOKEN

    In-App Billing helper is missing a token. (GooglePlay only)


    25
    IABHELPER_UNKNOWN_ERROR

    In-App Billing helper encountered an unknown error. (GooglePlay only)


    26
    IABHELPER_SUBSCRIPTIONS_NOT_AVAILABLE

    In-App Billing helper has no subscriptions available. (GooglePlay only)


    27
    IABHELPER_INVALID_CONSUMPTION

    In-App Billing helper attempted to consume an invalid purchase. (GooglePlay only)


    28
    Amazon_ALREADY_PURCHASED

    Indicates that the customer already owns the provided SKU. (Amazon only)


    29
    Amazon_FAILED

    Indicates that the purchase failed. (Amazon only)


    30
    Amazon_INVALID_SKU

    Indicates that the SKU originally provided to the PurchasingService.purchase(String) method is not valid. (Amazon only)


    31
    Amazon_NOT_SUPPORTED

    Indicates this call is not supported. (Amazon only)


    32
    Unknown

    A catch-all for remaining purchase problems.


    33
    Back to top Copyright © 2023 Unity Technologies
    Generated by DocFX
    on Friday, April 14, 2023
    Terms of use