Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge v385 #18073

Merged
merged 17 commits into from
Dec 23, 2024
Merged

Merge v385 #18073

merged 17 commits into from
Dec 23, 2024

Conversation

minggo
Copy link
Contributor

@minggo minggo commented Dec 23, 2024

Re: #

Changelog


Continuous Integration

This pull request:

  • needs automatic test cases check.

    Manual trigger with @cocos-robot run test cases afterward.

  • does not change any runtime related code or build configuration

    If any reviewer thinks the CI checks are needed, please uncheck this option, then close and reopen the issue.


Compatibility Check

This pull request:

  • changes public API, and have ensured backward compatibility with deprecated features.
  • affects platform compatibility, e.g. system version, browser version, platform sdk version, platform toolchain, language version, hardware compatibility etc.
  • affects file structure of the build package or build configuration which requires user project upgrade.
  • introduces breaking changes, please list all changes, affected features and the scope of violation.

knoxHuang and others added 17 commits December 11, 2024 10:29
* fix: skeleton & skin inspect panel display

* refine code
…ont (cocos#18015)

* fixed cocos#17016: wrong assertion if label is empty and uses BitmapFont
…l interface (cocos#18010)

The google play billing interface is consistent with google's original interface

---------

Co-authored-by: qiuguohua <[email protected]>
Co-authored-by: James Chen <[email protected]>
…e used instead of ccenum to generate reverse key. (cocos#18031)

* fixed #3d-tasks/18679: Invoke toLowerCase of undefined. Enum should be used instead of ccenum to generate reverse key.

* Add a comment for  PrimitiveType.
…t the generated wasm is not merged into external repo. (cocos#18032)
…sue in HarmonyOS Next (cocos#18041)

* 1.Fix the problem of incorrect rotation direction of openharmony screen
2.Remove redundant files

# Conflicts:
#	templates/harmonyos-next/entry/src/main/ets/cocos/jsb-adapter/sys-ability-polyfill.js

* Fix the issue of JSVM running crash

---------

Co-authored-by: qiuguohua <[email protected]>
* Optimizing google play implementation

* Initializing member variables

* Remove redundant code

---------

Co-authored-by: qiuguohua <[email protected]>
…to native. (cocos#18048)

Unit Tests only run on web platform, I forgot to change node.jsb.ts.

Previous PR: cocos#17141
…ipt (cocos#18062)

* Fix HarmonyOS Next platform interface for calling arkts using JavaScript

* Optimized interface implementation

* Improve annotations

* Improve the annotation.

---------

Co-authored-by: qiuguohua <[email protected]>
@minggo minggo requested a review from dumganhar December 23, 2024 02:36
Copy link

⚠️ Package size ⤴ 15 bytes, old: 5441652, new: 5441667

Interface Check Report

! WARNING this pull request has changed these public interfaces:

@@ -35199,12 +35199,33 @@
              * https://docs.cocos.com/creator/manual/zh/advanced-topics/java-reflection.html
              * @en call Objective-C/Java static methods
              * @zh 调用 Objective-C/Java 静态方法
              *
-             * @param className : @en the class name of the Objective-C/Java class @zh Objective-C/Java 类的类名
-             * @param methodName : @en the method name of the Objective-C/Java class @zh Objective-C/Java 类的方法名
-             * @param methodSignature : @en the method signature of the Objective-C/Java class @zh Objective-C/Java 方法签名
-             * @param parameters : @en the parameters of the Objective-C/Java class to translate @zh 传递至该 Objective-C/Java 方法的参数
+             * @param className : @en the class name of the Objective-C/Java/ArkTs class @zh Objective-C/Java/ArkTs 类的类名
+             * @param methodName : @en the method name of the Objective-C/Java/ArkT class @zh Objective-C/Java/ArkT 类的方法名
+             * @param methodSignature :
+             *        @en
+             *          - On the Android platform: Represents the method signature of the Java class.
+             *          - On the Mac/iOS platform: Represents the first parameter of the Objective-C method.
+             *          - On the HarmonyOS Next platform: Represents all parameters of the ArkTs method.
+             *            If multiple parameters are required, can be converted into a JSON string.
+             *        @zh
+             *          - 在 Android 平台:表示 Java 方法的签名。
+             *          - 在 Mac 或 iOS 平台:表示 Objective-C 方法的第一个参数。
+             *          - 在 HarmonyOS Next 平台:表示 ArkTs 方法的所有参数。如果需要传入多个参数,可以将它们转换为 JSON 字符串。
+             *
+             * @param parameters :
+             *        @en
+             *          - On the Android platform: Represents the parameters passed to the Java method.
+             *          - On the Mac/iOS platform: Represents the second or subsequent parameters of the Objective-C method.
+             *          - On the HarmonyOS Next platform: Indicates whether the ArkTs method is synchronous or asynchronous.
+             *            The default is `true`, meaning the ArkTs method is called synchronously.
+             *            Note that calling asynchronous ArkTs methods may block while waiting for results.
+             *        @zh
+             *          - 在 Android 平台:传递到 Java 方法的参数。
+             *          - 在 Mac 或 iOS 平台:传递到 Objective-C 方法的第二个或更多参数。
+             *          - 在 HarmonyOS Next 平台:表示调用 ArkTs 方法是同步还是异步。
+             *            默认值为 `true`,表示调用ArkTs的同步方法。注意,调用异步方法可能会阻塞以等待结果。
              */
             function callStaticMethod(className: string, methodName: string, methodSignature: string, ...parameters: any): any;
         }
         /**
@@ -58464,501 +58485,119 @@
     export class UIReorderComponent {
         constructor();
     }
     export namespace google {
-        /**
-         * @en Google Play Billing event type
-         * @zh Google Play Billing事件类型
-         */
-        export enum BillingEventType {
-            /**
-             * @en
-             * Called to notify that setup is complete.
-             *
-             * @zh
-             * 当安装已经完成时触发。
-             */
-            BILLING_SETUP_FINISHED = "billing_setup_finished",
-            /**
-             * @en
-             * Called to notify that the connection to the billing service was lost.
-             *
-             * @zh
-             * 当Billing服务连接断开时触发。
-             */
-            BILLING_SERVICE_DISCONNECTED = "billing_service_disconnected",
-            /**
-             * @en
-             * Listen to this event to get notifications of purchase updates.
-             *
-             * @zh
-             * 监听这个事件可以获取购买更新。
-             */
-            PURCHASES_UPDATED = "purchases_updated",
-            /**
-             * @en
-             * Called to notify that query product details operation has finished.
-             *
-             * @zh
-             * 查询产品详细信息操作完成时触发。
-             */
-            PRODUCT_DETAILS_RESPONSE = "product_details_response",
-            /**
-             * @en
-             * Called to notify that the query purchases operation has finished.
-             *
-             * @zh
-             * 查询购买操作完成时触发。
-             */
-            QUERY_PURCHASES_RESPONSE = "query_purchases_response",
-            /**
-             * @en
-             * Called to notify that a consume operation has finished.
-             *
-             * @zh
-             * 消费操作完成时触发。
-             */
-            CONSUME_RESPONSE = "consume_response",
-            /**
-             * @en
-             * Called to notify that an acknowledge purchase operation has finished.
-             *
-             * @zh
-             * 确认购买操作完成时触发。
-             */
-            ACKNOWLEDGE_PURCHASES_RESPONSE = "acknowledge_purchases_response",
-            /**
-             * @en
-             * Called to notify when the get billing config flow has finished.
-             *
-             * @zh
-             * 获取Billing配置流程完成时触发。
-             */
-            BILLING_CONFIG_RESPONSE = "billing_config_response",
-            /**
-             * @en
-             * Called to receive the results from createAlternativeBillingOnlyReportingDetailsAsync when it is finished.
-             *
-             * @zh
-             * 当调用createAlternativeBillingOnlyReportingDetailsAsync接口完成时触发,可以接收调用结果。
-             */
-            ALTERNATIVE_BILLING_ONLY_TOKEN_RESPONSE = "alternative_billing_only_token_response",
-            /**
-             * @en
-             * Called to receive the results from createExternalOfferReportingDetailsAsync when it is finished.
-             *
-             * @zh
-             * 当调用createExternalOfferReportingDetailsAsync接口完成时触发,可以接收调用结果。
-             */
-            EXTERNAL_OFFER_REPORTING_DETAILS_RESPONSE = "external_offer_reporting_details_response",
-            /**
-             * @en
-             * Called to receive the results from BillingClient#isAlternativeBillingOnlyAvailableAsync when it is finished.
-             *
-             * @zh
-             * 当调用BillingClient#isAlternativeBillingOnlyAvailableAsync接口完成时触发,可以接收调用结果。
-             */
-            ALTERNATIVE_BILLING_ONLY_AVAILABILITY_RESPONSE = "alternative_billing_only_availability_response",
-            /**
-             * @en
-             * Called to receive the results from BillingClient#isExternalOfferAvailableAsync when it is finished.
-             *
-             * @zh
-             * 当调用BillingClient#isExternalOfferAvailableAsync接口完成时触发,可以接收调用结果。
-             */
-            EXTERNAL_OFFER_AVAILABILITY_RESPONSE = "external_offer_availability_response",
-            /**
-             * @en
-             * Called to notify that the alternative billing only dialog flow is finished.
-             *
-             * @zh
-             * 当仅替代Billing对话流程已完成时触发。
-             */
-            ALTERNATIVE_BILLING_ONLY_INFORMATION_DIALOG_RESPONSE = "alternative_billing_only_information_dialog_response",
-            /**
-             * @en
-             * Called to notify that the external offer information dialog flow is finished.
-             *
-             * @zh
-             * 当外部报价信息对话流程已完成时触发。
-             */
-            EXTERNAL_OFFER_INFORMATION_DIALOG_RESPONSE = "external_offer_information_dialog_response",
-            /**
-             * @en
-             * Called to notify when the in-app messaging flow has finished.
-             *
-             * @zh
-             * 当应用内消息流程完成时触发。
-             */
-            IN_APP_MESSAGE_RESPONSE = "in_app_message_response"
+        export namespace billing {
+            export const BillingClient: typeof __private.__types_jsb__jsb.BillingClient;
+            export type BillingClient = __private.__types_jsb__jsb.BillingClient;
+            export namespace BillingClient {
+                export type Builder = __private.__types_jsb__jsb.BillingClientBuilder;
+                export type ConnectionState = __private.__types_jsb__jsb.ConnectionState;
+                export type BillingResponseCode = __private.__types_jsb__jsb.BillingResponseCode;
+                export type FeatureType = __private.__types_jsb__jsb.FeatureType;
+                export type ProductType = __private.__types_jsb__jsb.ProductType;
+            }
+            export const BillingResult: typeof __private.__types_jsb__jsb.BillingResult;
+            export type BillingResult = __private.__types_jsb__jsb.BillingResult;
+            export namespace BillingResult {
+                export type Builder = __private.__types_jsb__jsb.BillingResultBuilder;
+            }
+            export const InAppMessageResult: typeof __private.__types_jsb__jsb.InAppMessageResult;
+            export type InAppMessageResult = __private.__types_jsb__jsb.InAppMessageResult;
+            export namespace InAppMessageResult {
+                export type InAppMessageResponseCode = __private.__types_jsb__jsb.InAppMessageResponseCode;
+            }
+            export const ProductDetails: typeof __private.__types_jsb__jsb.ProductDetails;
+            export type ProductDetails = __private.__types_jsb__jsb.ProductDetails;
+            export namespace ProductDetails {
+                export type RecurrenceMode = __private.__types_jsb__jsb.RecurrenceMode;
+                export type OneTimePurchaseOfferDetails = __private.__types_jsb__jsb.OneTimePurchaseOfferDetails;
+                export type InstallmentPlanDetails = __private.__types_jsb__jsb.InstallmentPlanDetails;
+                export type PricingPhase = __private.__types_jsb__jsb.PricingPhase;
+                export type PricingPhases = __private.__types_jsb__jsb.PricingPhases;
+                export type SubscriptionOfferDetails = __private.__types_jsb__jsb.SubscriptionOfferDetails;
+            }
+            export const Purchase: typeof __private.__types_jsb__jsb.Purchase;
+            export type Purchase = __private.__types_jsb__jsb.Purchase;
+            export namespace Purchase {
+                export type PurchaseState = __private.__types_jsb__jsb.PurchaseState;
+            }
+            export const PendingPurchasesParams: typeof __private.__types_jsb__jsb.PendingPurchasesParams;
+            export type PendingPurchasesParams = __private.__types_jsb__jsb.PendingPurchasesParams;
+            export namespace PendingPurchasesParams {
+                export type Builder = __private.__types_jsb__jsb.PendingPurchasesParamsBuilder;
+            }
+            export const QueryProductDetailsParams: typeof __private.__types_jsb__jsb.QueryProductDetailsParams;
+            export type QueryProductDetailsParams = __private.__types_jsb__jsb.QueryProductDetailsParams;
+            export namespace QueryProductDetailsParams {
+                export type Builder = __private.__types_jsb__jsb.QueryProductDetailsParamsBuilder;
+                export type Product = __private.__types_jsb__jsb.QueryProductDetailsParamsProduct;
+                export namespace Product {
+                    export type Builder = __private.__types_jsb__jsb.QueryProductDetailsParamsProductBuilder;
+                }
+            }
+            export const BillingFlowParams: typeof __private.__types_jsb__jsb.BillingFlowParams;
+            export type BillingFlowParams = __private.__types_jsb__jsb.BillingFlowParams;
+            export namespace BillingFlowParams {
+                export type Builder = __private.__types_jsb__jsb.BillingFlowParamsBuilder;
+                export type SubscriptionUpdateParams = __private.__types_jsb__jsb.SubscriptionUpdateParams;
+                export namespace SubscriptionUpdateParams {
+                    export type Builder = __private.__types_jsb__jsb.SubscriptionUpdateParamsBuilder;
+                    export type ReplacementMode = __private.__types_jsb__jsb.ReplacementMode;
+                }
+                export type ProductDetailsParams = __private.__types_jsb__jsb.ProductDetailsParams;
+                export namespace ProductDetailsParams {
+                    export type Builder = __private.__types_jsb__jsb.ProductDetailsParamsBuilder;
+                }
+            }
+            export const ConsumeParams: typeof __private.__types_jsb__jsb.ConsumeParams;
+            export type ConsumeParams = __private.__types_jsb__jsb.ConsumeParams;
+            export namespace ConsumeParams {
+                export type Builder = __private.__types_jsb__jsb.ConsumeParamsBuilder;
+            }
+            export const AcknowledgePurchaseParams: typeof __private.__types_jsb__jsb.AcknowledgePurchaseParams;
+            export type AcknowledgePurchaseParams = __private.__types_jsb__jsb.AcknowledgePurchaseParams;
+            export namespace AcknowledgePurchaseParams {
+                export type Builder = __private.__types_jsb__jsb.AcknowledgePurchaseParamsBuilder;
+            }
+            export const QueryPurchasesParams: typeof __private.__types_jsb__jsb.QueryPurchasesParams;
+            export type QueryPurchasesParams = __private.__types_jsb__jsb.QueryPurchasesParams;
+            export namespace QueryPurchasesParams {
+                export type Builder = __private.__types_jsb__jsb.QueryPurchasesParamsBuilder;
+            }
+            export const GetBillingConfigParams: typeof __private.__types_jsb__jsb.GetBillingConfigParams;
+            export type GetBillingConfigParams = __private.__types_jsb__jsb.GetBillingConfigParams;
+            export namespace GetBillingConfigParams {
+                export type Builder = __private.__types_jsb__jsb.GetBillingConfigParams;
+            }
+            export const InAppMessageParams: typeof __private.__types_jsb__jsb.InAppMessageParams;
+            export type InAppMessageParams = __private.__types_jsb__jsb.InAppMessageParams;
+            export namespace InAppMessageParams {
+                export type Builder = __private.__types_jsb__jsb.InAppMessageParamsBuilder;
+                export type InAppMessageCategoryId = __private.__types_jsb__jsb.InAppMessageCategoryId;
+            }
+            export type AcknowledgePurchaseResponseListener = __private.__types_jsb__jsb.AcknowledgePurchaseResponseListener;
+            export type AlternativeBillingOnlyAvailabilityListener = __private.__types_jsb__jsb.AlternativeBillingOnlyAvailabilityListener;
+            export type AlternativeBillingOnlyInformationDialogListener = __private.__types_jsb__jsb.AlternativeBillingOnlyInformationDialogListener;
+            export type AlternativeBillingOnlyReportingDetailsListener = __private.__types_jsb__jsb.AlternativeBillingOnlyReportingDetailsListener;
+            export type BillingConfigResponseListener = __private.__types_jsb__jsb.BillingConfigResponseListener;
+            export type ConsumeResponseListener = __private.__types_jsb__jsb.ConsumeResponseListener;
+            export type ExternalOfferAvailabilityListener = __private.__types_jsb__jsb.ExternalOfferAvailabilityListener;
+            export type ExternalOfferInformationDialogListener = __private.__types_jsb__jsb.ExternalOfferInformationDialogListener;
+            export type ExternalOfferReportingDetailsListener = __private.__types_jsb__jsb.ExternalOfferReportingDetailsListener;
+            export type InAppMessageResponseListener = __private.__types_jsb__jsb.InAppMessageResponseListener;
+            export type ProductDetailsResponseListener = __private.__types_jsb__jsb.ProductDetailsResponseListener;
+            export type PurchasesResponseListener = __private.__types_jsb__jsb.PurchasesResponseListener;
+            export type PurchasesUpdatedListener = __private.__types_jsb__jsb.PurchasesUpdatedListener;
+            export type UserChoiceBillingListener = __private.__types_jsb__jsb.UserChoiceBillingListener;
+            export type BillingClientStateListener = __private.__types_jsb__jsb.BillingClientStateListener;
+            export type UserChoiceDetails = __private.__types_jsb__jsb.UserChoiceDetails;
+            export type AccountIdentifiers = __private.__types_jsb__jsb.AccountIdentifiers;
+            export type PendingPurchaseUpdate = __private.__types_jsb__jsb.PendingPurchaseUpdate;
+            export type BillingConfig = __private.__types_jsb__jsb.BillingConfig;
+            export type AlternativeBillingOnlyReportingDetails = __private.__types_jsb__jsb.AlternativeBillingOnlyReportingDetails;
+            export type ExternalOfferReportingDetails = __private.__types_jsb__jsb.ExternalOfferReportingDetails;
         }
-        /**
-         * @en
-         * Supported Product types.
-         *
-         * @zh
-         * 支持的产品类型。
-         */
-        export enum ProductType {
-            /**
-             * @en
-             * A Product type for Android apps in-app products.
-             *
-             * @zh
-             * Android 应用内产品的产品类型。
-             */
-            INAPP = "inapp",
-            /**
-             * @en
-             * A Product type for Android apps subscriptions.
-             *
-             * @zh
-             * Android 应用程序订阅的产品类型。
-             */
-            SUBS = "subs"
-        }
-        /**
-         * @en
-         * Possible response codes.
-         *
-         * @zh
-         * 可能的响应代码。
-         */
-        export enum BillingResponseCode {
-            /**
-             * @en
-             * This field is deprecated.
-             * See SERVICE_UNAVAILABLE which will be used instead of this code.
-             *
-             * @zh
-             * 这个字段已经废弃。
-             * 看看SERVICE_UNAVAILABLE将使用哪一个来代替此代码。
-             */
-            SERVICE_TIMEOUT = "Bad expression <-3>",
-            /**
-             * @en
-             * The requested feature is not supported by the Play Store on the current device.
-             *
-             * @zh
-             * 当前设备上的 Play Store 不支持所请求的功能。
-             */
-            FEATURE_NOT_SUPPORTED = "Bad expression <-2>",
-            /**
-             * @en
-             * The app is not connected to the Play Store service via the Google Play Billing Library.
-             *
-             * @zh
-             * 该应用未通过 Google Play Billing库连接到 Play Store 服务。
-             */
-            SERVICE_DISCONNECTED = "Bad expression <-1>",
-            /**
-             * @en
-             * Success.
-             *
-             * @zh
-             * 成功。
-             */
-            OK = 0,
-            /**
-             * @en
-             * Transaction was canceled by the user.
-             *
-             * @zh
-             * 交易已被用户取消。
-             */
-            USER_CANCELED = 1,
-            /**
-             * @en
-             * The service is currently unavailable.
-             *
-             * @zh
-             * 当前设备上的 Play Store 不支持所请求的功能。
-             */
-            SERVICE_UNAVAILABLE = 2,
-            /**
-             * @en
-             * A user billing error occurred during processing.
-             *
-             * @zh
-             * 处理过程中出现用户billing错误。
-             */
-            BILLING_UNAVAILABLE = 3,
-            /**
-             * @en
-             * The requested product is not available for purchase.
-             *
-             * @zh
-             * 所请求的产品无法购买。
-             */
-            ITEM_UNAVAILABLE = 4,
-            /**
-             * @en
-             * Error resulting from incorrect usage of the API.
-             *
-             * @zh
-             * 由于错误使用 API 而导致的错误。
-             */
-            DEVELOPER_ERROR = 5,
-            /**
-             * @en
-             * Fatal error during the API action.
-             *
-             * @zh
-             * API 操作期间发生致命错误。
-             */
-            ERROR = 6,
-            /**
-             * @en
-             * The purchase failed because the item is already owned.
-             *
-             * @zh
-             * 购买失败,因为该物品已被拥有。
-             */
-            ITEM_ALREADY_OWNED = 7,
-            /**
-             * @en
-             * Requested action on the item failed since it is not owned by the user.
-             *
-             * @zh
-             * 由于该项目不属于用户,因此对该项目请求的操作失败。
-             */
-            ITEM_NOT_OWNED = 8,
-            /**
-             * @en
-             * A network error occurred during the operation.
-             *
-             * @zh
-             * 操作期间发生网络错误。
-             */
-            NETWORK_ERROR = 12
-        }
-        /**
-         * @en
-         * Recurrence mode of the pricing phase.
-         *
-         * @zh
-         * 定价阶段的复现模式。
-         */
-        export enum RecurrenceMode {
-            /**
-             * @en
-             * The billing plan payment recurs for infinite billing periods unless cancelled.
-             *
-             * @zh
-             * 除非取消,否则billing计划付款将无限期地重复。
-             */
-            INFINITE_RECURRING = 1,
-            /**
-             * @en
-             * The billing plan payment recurs for a fixed number of billing period set in billingCycleCount.
-             *
-             * @zh
-             * Billing计划付款将在 billingCycleCount 中设置的固定计费周期内重复发生。
-             */
-            FINITE_RECURRING = 2,
-            /**
-             * @en
-             * The billing plan payment is a one time charge that does not repeat.
-             *
-             * @zh
-             * Billing计划付款是一次性费用,不会重复。
-             */
-            NON_RECURRING = 3
-        }
-        /**
-         * @en
-         * Connection state of billing client.
-         *
-         * @zh
-         * Billing client的连接状态
-         */
-        export enum ConnectionState {
-            /**
-             * @en
-             * This client was not yet connected to billing service or was already closed.
-             *
-             * @zh
-             * 此客户端尚未连接到Billing服务或已关闭。
-             */
-            DISCONNECTED = 0,
-            /**
-             * @en
-             * This client is currently in process of connecting to billing service.
-             *
-             * @zh
-             * 此客户端目前正在连接到Billing服务。
-             */
-            CONNECTING = 1,
-            /**
-             * @en
-             * This client is currently connected to billing service.
-             *
-             * @zh
-             * 此客户端当前已连接到Billing服务。
-             */
-            CONNECTED = 2,
-            /**
-             * @en
-             * This client was already closed and shouldn't be used again.
-             *
-             * @zh
-             * 该客户端已关闭,不应再次使用。
-             */
-            CLOSED = 3
-        }
-        /**
-         * @en
-         * Features/capabilities supported by isFeatureSupported.
-         *
-         * @zh
-         * 支持的特性/能力isFeatureSupported。
-         */
-        export enum FeatureType {
-            /**
-             * @en
-             * Alternative billing only.
-             *
-             * @zh
-             * 仅限替代Billing。
-             */
-            ALTERNATIVE_BILLING_ONLY = "jjj",
-            /**
-             * @en
-             * Get billing config.
-             *
-             * @zh
-             * 获取计费配置。
-             */
-            BILLING_CONFIG = "ggg",
-            /**
-             * @en
-             * Play billing library support for external offer.
-             *
-             * @zh
-             * Play billing库支持外部报价。
-             */
-            EXTERNAL_OFFER = "kkk",
-            /**
-             * @en
-             * Show in-app messages.
-             *
-             * @zh
-             * 显示应用内消息。
-             */
-            IN_APP_MESSAGING = "bbb",
-            /**
-             * @en
-             * Launch a price change confirmation flow.
-             *
-             * @zh
-             * 启动价格变动确认流程。
-             */
-            PRICE_CHANGE_CONFIRMATION = "priceChangeConfirmation",
-            /**
-             * @en
-             * Play billing library support for querying and purchasing.
-             *
-             * @zh
-             * Play Billing库支持查询、购买。
-             */
-            PRODUCT_DETAILS = "fff",
-            /**
-             * @en
-             * Purchase/query for subscriptions.
-             *
-             * @zh
-             * 购买/查询订阅。
-             */
-            SUBSCRIPTIONS = "subscriptions",
-            /**
-             * @en
-             * Subscriptions update/replace.
-             *
-             * @zh
-             * 订阅更新/替换。
-             */
-            UBSCRIPTIONS_UPDATE = "subscriptionsUpdate"
-        }
-        /**
-         * @en
-         * Possible purchase states.
-         *
-         * @zh
-         * 可能的购买状态。
-         */
-        export enum PurchaseState {
-            /**
-             * @en
-             * Purchase is pending and not yet completed to be processed by your app.
-             *
-             * @zh
-             * 购买处于待处理状态且尚未完成,无法由您的应用程序处理。
-             */
-            PENDING = 2,
-            /**
-             * @en
-             * Purchase is completed..
-             *
-             * @zh
-             * 购买完成。
-             */
-            PURCHASED = 1,
-            /**
-             * @en
-             * Purchase with unknown state.
-             *
-             * @zh
-             * 未知状态
-             */
-            UNSPECIFIED_STATE = 0
-        }
-        /**
-         * @en
-         * Possible response codes.
-         *
-         * @zh
-         * InAppMessage可能的影响代码。
-         */
-        export enum InAppMessageResponseCode {
-            /**
-             * @en
-             * The flow has finished and there is no action needed from developers.
-             *
-             * @zh
-             * 流程已完成,开发人员无需采取任何行动。
-             */
-            NO_ACTION_NEEDED = 0,
-            /**
-             * @en
-             * The subscription status changed.
-             *
-             * @zh
-             * 订阅状态已改变。
-             */
-            SUBSCRIPTION_STATUS_UPDATED = 1
-        }
-        export type BillingResult = __private.__types_jsb__jsb.BillingResult;
-        export type OneTimePurchaseOfferDetails = __private.__types_jsb__jsb.OneTimePurchaseOfferDetails;
-        export type InstallmentPlanDetails = __private.__types_jsb__jsb.InstallmentPlanDetails;
-        export type PricingPhase = __private.__types_jsb__jsb.PricingPhase;
-        export type SubscriptionOfferDetails = __private.__types_jsb__jsb.SubscriptionOfferDetails;
-        export type ProductDetails = __private.__types_jsb__jsb.ProductDetails;
-        export type AccountIdentifiers = __private.__types_jsb__jsb.AccountIdentifiers;
-        export type PendingPurchaseUpdate = __private.__types_jsb__jsb.PendingPurchaseUpdate;
-        export type Purchase = __private.__types_jsb__jsb.Purchase;
-        export type BillingConfig = __private.__types_jsb__jsb.BillingConfig;
-        export type AlternativeBillingOnlyReportingDetails = __private.__types_jsb__jsb.AlternativeBillingOnlyReportingDetails;
-        export type ExternalOfferReportingDetails = __private.__types_jsb__jsb.ExternalOfferReportingDetails;
-        export type InAppMessageResult = __private.__types_jsb__jsb.InAppMessageResult;
-        /**
-         * @en
-         * Interface for Google Play blling module.
-         *
-         * @zh
-         * Google Play blling模块的接口。
-         *
-         */
-        export const billing: __private._vendor_google_billing_billing__Billing;
     }
     /**
      * @en
      * The video clip asset.
@@ -61477,12 +61116,12 @@
             protected _nativeObj: _cocos_2d_renderer_native_2d__NativeRenderDrawInfo;
             protected _uint8SharedBuffer: Uint8Array;
             protected _uint16SharedBuffer: Uint16Array;
             protected _uint32SharedBuffer: Uint32Array;
-            protected _render2dBuffer: Float32Array;
+            protected _render2dBuffer: Float32Array | null;
             constructor(nativeDrawInfo?: _cocos_2d_renderer_native_2d__NativeRenderDrawInfo);
             get nativeObj(): _cocos_2d_renderer_native_2d__NativeRenderDrawInfo;
-            get render2dBuffer(): Float32Array;
+            get render2dBuffer(): Float32Array | null;
             clear(): void;
             setAccId(accId: any): void;
             setBufferId(bufferId: any): void;
             setAccAndBuffer(accId: any, bufferId: any): void;
@@ -72254,8 +71893,41 @@
              * @deprecated since v3.5.0, this is an engine private interface that will be removed in the future.
              */
             _buildResult(containerW: number, containerH: number, contentW: number, contentH: number, scaleX: number, scaleY: number): _cocos_ui_view__AdaptResult;
         }
+        /**
+         * @en
+         * Recurrence mode of the pricing phase.
+         *
+         * @zh
+         * 定价阶段的复现模式。
+         */
+        export enum __types_jsb_jsb__RecurrenceMode {
+            /**
+             * @en
+             * The billing plan payment recurs for infinite billing periods unless cancelled.
+             *
+             * @zh
+             * 除非取消,否则billing计划付款将无限期地重复。
+             */
+            INFINITE_RECURRING = 1,
+            /**
+             * @en
+             * The billing plan payment recurs for a fixed number of billing period set in billingCycleCount.
+             *
+             * @zh
+             * Billing计划付款将在 billingCycleCount 中设置的固定计费周期内重复发生。
+             */
+            FINITE_RECURRING = 2,
+            /**
+             * @en
+             * The billing plan payment is a one time charge that does not repeat.
+             *
+             * @zh
+             * Billing计划付款是一次性费用,不会重复。
+             */
+            NON_RECURRING = 3
+        }
         export type __types_jsb_jsb__AccelerationXYZ = number;
         export type __types_jsb_jsb__AccelerationIncludingGravityXYZ = number;
         export type __types_jsb_jsb__RotationRateAlpha = number;
         export type __types_jsb_jsb__RotationRateBeta = number;
@@ -72439,8 +72111,16 @@
              */
             setVerifyCallback(verifyCallback: (path: string, asset: __types_jsb_jsb__ManifestAsset) => boolean): void;
             setEventCallback(eventCallback: (event: __types_jsb_jsb__EventAssetsManager) => void): void;
         }
+        export interface __types_jsb_jsb__UserChoiceDetailsProduct {
+            hashCode(): number;
+            getId(): string;
+            getOfferToken(): string;
+            getType(): string;
+            toString(): string;
+            equals(product: __types_jsb_jsb__UserChoiceDetailsProduct): boolean;
+        }
         /**
          * @en Represents a pricing phase, describing how a user pays at a point in time.
          * @zh 表示定价阶段,描述用户在某个时间点如何付款。
          */
@@ -72448,50 +72128,61 @@
             /**
              * @en Number of cycles for which the billing period is applied.
              * @zh 计费周期适用的周期数。
              */
-            readonly billingCycleCount: number;
+            getBillingCycleCount(): number;
             /**
              * @en The price for the payment cycle in micro-units, where 1,000,000 micro-units equal one unit of the currency.
              * @zh 微单位付款周期的价格,其中 1,000,000 个微单位等于 1 个货币单位。
              */
-            readonly priceAmountMicros: number;
+            getPriceAmountMicros(): number;
             /**
              * @en RecurrenceMode for the pricing phase.
              * @zh 定价阶段的RecurrenceMode。
              */
-            readonly recurrenceMode: number;
+            getRecurrenceMode(): number;
             /**
              * @en Billing period for which the given price applies, specified in ISO 8601 format.
              * @zh 给定价格适用的计费期,以 ISO 8601 格式指定。
              */
-            readonly billingPeriod: string;
+            getBillingPeriod(): string;
             /**
              * @en Formatted price for the payment cycle, including its currency sign.
              * @zh 付款周期的格式化价格,包括其货币符号。
              */
-            readonly formattedPrice: string;
+            getFormattedPrice(): string;
             /**
              * @en Returns ISO 4217 currency code for price.
              * @zh 返回价格的 ISO 4217 货币代码。
              */
-            readonly priceCurrencyCode: string;
+            getPriceCurrencyCode(): string;
         }
         /**
+         * @en Represents a pricing phase, describing how a user pays at a point in time.
+         * @zh 表示定价阶段,描述用户在某个时间点如何付款。
+         */
+        export interface __types_jsb_jsb__PricingPhases {
+            /**
+             * @en Returns ISO 4217 currency code for price.
+             * @zh 返回价格的 ISO 4217 货币代码。
+             */
+            getPricingPhaseList(): __types_jsb_jsb__PricingPhase[];
+        }
+        /**
          * @en Represents additional details of an installment subscription plan.
          * @zh 表示分期付款订阅计划的附加详细信息。
          */
         export interface __types_jsb_jsb__InstallmentPlanDetails {
             /**
              * @en Committed payments count after a user signs up for this subscription plan.
              * @zh 用户注册此订阅计划后承诺的付款数量。
              */
-            readonly installmentPlanCommitmentPaymentsCount: number;
+            getInstallmentPlanCommitmentPaymentsCount(): number;
             /**
              * @en Subsequent committed payments count after this subscription plan renews.
              * @zh 此订阅计划续订后的后续承诺付款数量。
              */
-            readonly subsequentInstallmentPlanCommitmentPaymentsCount: number;
+            getSubsequentInstallmentPlanCommitmentPaymentsCount(): number;
         }
         /**
          * @en Represents the offer details to buy an one-time purchase product.
          * @zh 代表一次性购买产品的报价详情。
@@ -72500,19 +72191,19 @@
             /**
              * @en The price for the payment in micro-units, where 1,000,000 micro-units equal one unit of the currency.
              * @zh 以微单位返回支付价格,其中 1,000,000 个微单位等于 1 个货币单位。
              */
-            readonly priceAmountMicros: number;
+            getPriceAmountMicros(): number;
             /**
              * @en Formatted price for the payment, including its currency sign.
              * @zh 支付的格式化价格,包括其货币单位。
              */
-            readonly formattedPrice: string;
+            getFormattedPrice(): string;
             /**
              * @en ISO 4217 currency code for price.
              * @zh 价格的 ISO 4217 货币代码。
              */
-            readonly priceCurrencyCode: string;
+            getPriceCurrencyCode(): string;
         }
         /**
          * @en Represents the available purchase plans to buy a subscription product.
          * @zh 代表一次性购买产品的报价详情。
@@ -72521,50 +72212,83 @@
             /**
              * @en The base plan id associated with the subscription product.
              * @zh 与订阅产品相关的基本计划 ID。
              */
-            readonly basePlanId: string;
+            getBasePlanId(): string;
             /**
              * @en The offer id associated with the subscription product.
              * @zh 与订阅产品相关的优惠 ID。
              */
-            readonly offerId: string;
+            getOfferId(): string;
             /**
              * @en The offer tags associated with this Subscription Offer.
              * @zh 与此订阅优惠相关的优惠标签。
              */
-            readonly offerTags: string[];
+            getOfferTags(): string[];
             /**
              * @en The offer token required to pass in launchBillingFlow to purchase the subscription product with these pricing phases.
              * @zh 在 launchBillingFlow 中传递以使用这些定价阶段购买订阅产品所需的优惠令牌。
              */
-            readonly offerToken: string;
+            getOfferToken(): string;
             /**
              * @en The pricing phases for the subscription product.
              * @zh 订阅产品的定价区间。
              */
-            readonly pricingPhaseList: __types_jsb_jsb__PricingPhase[];
+            getPricingPhases(): __types_jsb_jsb__PricingPhases;
             /**
              * @en The additional details of an installment plan.
              * @zh 分期付款计划的附加详细信息。
              */
-            readonly installmentPlanDetails: __types_jsb_jsb__InstallmentPlanDetails;
+            getInstallmentPlanDetails(): __types_jsb_jsb__InstallmentPlanDetails;
         }
         /**
+         * @en
+         * Possible purchase states.
+         *
+         * @zh
+         * 可能的购买状态。
+         */
+        export enum __types_jsb_jsb__PurchaseState {
+            /**
+             * @en
+             * Purchase is pending and not yet completed to be processed by your app.
+             *
+             * @zh
+             * 购买处于待处理状态且尚未完成,无法由您的应用程序处理。
+             */
+            PENDING = 2,
+            /**
+             * @en
+             * Purchase is completed..
+             *
+             * @zh
+             * 购买完成。
+             */
+            PURCHASED = 1,
+            /**
+             * @en
+             * Purchase with unknown state.
+             *
+             * @zh
+             * 未知状态
+             */
+            UNSPECIFIED_STATE = 0
+        }
+        /**
          * @en Account identifiers that were specified when the purchase was made.
          * @zh 购买时指定的帐户标识符。
          */
         export interface __types_jsb_jsb__AccountIdentifiers {
             /**
              * @en The obfuscated account id specified in setObfuscatedAccountId.
              * @zh 在setObfuscatedAccountId中设置的混淆账户id
              */
-            readonly obfuscatedAccountId: string;
+            getObfuscatedAccountId(): string;
             /**
              * @en The obfuscated profile id specified in setObfuscatedProfileId.
              * @zh 在setObfuscatedProfileId中设置的混淆profile id
              */
-            readonly obfuscatedProfileId: string;
+            getObfuscatedProfileId(): string;
         }
         /**
          * @en Represents a pending change/update to the existing purchase.
          * @zh 表示对现有购买的待定更改/更新。
@@ -72573,175 +72297,191 @@
             /**
              * @en A token that uniquely identifies this pending transaction.
              * @zh 唯一标识此待处理交易的令牌。
              */
-            readonly purchaseToken: string;
+            getPurchaseToken(): string;
             /**
              * @en The product ids.
              * @zh 产品 ID。
              */
-            readonly products: string[];
+            getProducts(): string[];
         }
         /**
-         * @en Represents the details of a one time or subscription product.
-         * @zh 代表一次性或订阅产品的详细信息。
+         * @en
+         * Possible response codes.
+         *
+         * @zh
+         * 可能的响应代码。
          */
-        export interface __types_jsb_jsb__ProductDetails {
+        export enum __types_jsb_jsb__InAppMessageResponseCode {
             /**
-             * @en Hash code
-             * @zh hash值
+             * @en
+             * The flow has finished and there is no action needed from developers.
+             *
+             * @zh
+             * 流程已经结束,开发人员无需采取任何行动。
              */
-            readonly hashCode: number;
+            NO_ACTION_NEEDED = 0,
             /**
-             * @en The description of the product.
-             * @zh 产品的描述。
+             * @en
+             * The subscription status changed.
+             *
+             * @zh
+             * 订阅状态已更改。
              */
-            readonly description: string;
-            /**
-             * @en The name of the product being sold.
-             * @zh 所售产品的名称。
-             */
-            readonly name: string;
-            /**
-             * @en The product's Id.
-             * @zh 产品的 ID。
-             */
-            readonly productId: string;
-            /**
-             * @en The ProductType of the product.
-             * @zh ProductType产品的。
-             */
-            readonly productType: string;
-            /**
-             * @en The title of the product being sold.
-             * @zh 所售产品的标题。
-             */
-            readonly title: string;
-            /**
-             * @en To string
-             * @zh 转换成字符串
-             */
-            readonly toStr: string;
-            /**
-             * @en The offer details of an one-time purchase product.
-             * @zh 代表一次性购买产品的报价详情。
-             */
-            readonly oneTimePurchaseOfferDetails: __types_jsb_jsb__OneTimePurchaseOfferDetails;
-            /**
-             * @en A list containing all available offers to purchase a subscription product.
-             * @zh 返回包含购买订阅产品的所有可用优惠的列表。
-             */
-            readonly subscriptionOfferDetails: __types_jsb_jsb__SubscriptionOfferDetails[];
+            SUBSCRIPTION_STATUS_UPDATED = 1
         }
+        export class __types_jsb_jsb__BillingResult {
+            static Builder: __types_jsb_jsb__BillingResultBuilder;
+            getResponseCode(): number;
+            getDebugMessage(): string;
+            toString(): string;
+            public static newBuilder(): __types_jsb_jsb__BillingResultBuilder;
+        }
+        export namespace __types_jsb_jsb__BillingResult {
+            type Builder = __types_jsb_jsb__BillingResultBuilder;
+        }
+        export interface __types_jsb_jsb__BillingResultBuilder {
+            setDebugMessage(productType: string): __types_jsb_jsb__BillingResultBuilder;
+            setResponseCode(productType: number): __types_jsb_jsb__BillingResultBuilder;
+            build(): __types_jsb_jsb__BillingResult;
+        }
+        export class __types_jsb_jsb__UserChoiceDetails {
+            getExternalTransactionToken(): string;
+            getOriginalExternalTransactionId(): string;
+            getProducts(): __types_jsb_jsb__UserChoiceDetailsProduct[];
+        }
         /**
          * @en Represents an in-app billing purchase.
          * @zh 代表应用内billing购买。
          */
-        export interface __types_jsb_jsb__Purchase {
+        export class __types_jsb_jsb__Purchase {
+            static PurchaseState: typeof __types_jsb__jsb.PurchaseState;
             /**
              * @en One of PurchaseState indicating the state of the purchase.
              * @zh PurchaseState表示购买状态的其中一个值。
              */
-            readonly purchaseState: number;
+            getPurchaseState(): number;
             /**
              * @en The time the product was purchased, in milliseconds since the epoch (Jan 1, 1970).
              * @zh 产品购买的时间,以纪元(1970 年 1 月 1 日)以来的毫秒数表示。
              */
-            readonly purchaseTime: number;
+            getPurchaseTime(): number;
             /**
              * @en Indicates whether the purchase has been acknowledged.
              * @zh 表示是否已确认购买。
              */
-            readonly isAcknowledged: number;
+            isAcknowledged(): number;
             /**
              * @en Indicates whether the subscription renews automatically.
              * @zh 指示订阅是否自动续订。
              */
-            readonly isAutoRenewing: number;
+            isAutoRenewing(): number;
             /**
              * @en Hash code
              * @zh hash值
              */
-            readonly hashCode: number;
+            hashCode(): number;
             /**
              * @en The quantity of the purchased product.
              * @zh 购买产品的数量。
              */
-            readonly quantity: number;
+            getQuantity(): number;
             /**
              * @en The payload specified when the purchase was acknowledged or consumed.
              * @zh 确认或消费购买时指定的有效负载。
              */
-            readonly developerPayload: string;
+            getDeveloperPayload(): string;
             /**
              * @en Returns a unique order identifier for the transaction.
              * @zh 交易的唯一订单标识符。
              */
-            readonly orderId: string;
+            getOrderId(): string;
             /**
              * @en Returns a String in JSON format that contains details about the purchase order.
              * @zh 包含有关采购订单详细信息的 JSON 格式的字符串。
              */
-            readonly originalJson: string;
+            getOriginalJson(): string;
             /**
              * @en The application package from which the purchase originated.
              * @zh 购买来源的应用程序包。
              */
-            readonly packageName: string;
+            getPackageName(): string;
             /**
              * @en A token that uniquely identifies a purchase for a given item and user pair.
              * @zh 唯一标识给定商品和用户对的购买的令牌。
              */
-            readonly purchaseToken: string;
+            getPurchaseToken(): string;
             /**
              * @en String containing the signature of the purchase data that was signed with the private key of the developer.
              * @zh 包含使用开发者私钥签名的购买数据签名的字符串。
              */
-            readonly signature: string;
+            getSignature(): string;
             /**
              * @en To string
              * @zh 转换成字符串
              */
-            readonly toStr: string;
+            toString(): string;
             /**
              * @en Returns account identifiers that were provided when the purchase was made.
              * @zh 返回购买时提供的帐户标识符。
              */
-            readonly accountIdentifiers: __types_jsb_jsb__AccountIdentifiers;
+            getAccountIdentifiers(): __types_jsb_jsb__AccountIdentifiers;
             /**
              * @en The PendingPurchaseUpdate for an uncommitted transaction.
              * @zh 返回PendingPurchaseUpdate未提交的事务。
              */
-            readonly pendingPurchaseUpdate: __types_jsb_jsb__PendingPurchaseUpdate;
+            getPendingPurchaseUpdate(): __types_jsb_jsb__PendingPurchaseUpdate;
             /**
              * @en the product Ids.
              * @zh 产品 ID。
              */
-            readonly products: string[];
+            getProducts(): string[];
         }
-        /**
-         * @en Params containing the response code and the debug message from In-app Billing API response.
-         * @zh 包含应用内结算 API 响应代码和调试信息的参数
-         */
-        export interface __types_jsb_jsb__BillingResult {
-            /**
-             * @en Debug message returned in In-app Billing API calls.
-             * @zh 应用内结算 API 调用中返回的调试消息。
-             */
-            readonly debugMessage: string;
-            /**
-             * @en Code returned in In-app Billing API calls.
-             * @zh 应用内结算 API 调用中返回的响应代码。
-             */
-            readonly responseCode: string;
-            readonly toStr: string;
+        export class __types_jsb_jsb__PendingPurchasesParams {
+            public static newBuilder(): __types_jsb_jsb__PendingPurchasesParamsBuilder;
         }
+        export interface __types_jsb_jsb__PendingPurchasesParamsBuilder {
+            enableOneTimeProducts: () => __types_jsb_jsb__PendingPurchasesParamsBuilder;
+            enablePrepaidPlans: () => __types_jsb_jsb__PendingPurchasesParamsBuilder;
+            build: () => __types_jsb_jsb__PendingPurchasesParams;
+        }
+        export class __types_jsb_jsb__QueryProductDetailsParamsProduct {
+            public static newBuilder(): __types_jsb_jsb__QueryProductDetailsParamsProductBuilder;
+        }
+        export interface __types_jsb_jsb__QueryProductDetailsParamsProductBuilder {
+            setProductId: (productID: string) => __types_jsb_jsb__QueryProductDetailsParamsProductBuilder;
+            setProductType: (productType: string) => __types_jsb_jsb__QueryProductDetailsParamsProductBuilder;
+            build: () => __types_jsb_jsb__QueryProductDetailsParamsProduct;
+        }
+        export class __types_jsb_jsb__QueryProductDetailsParams {
+            static Product: typeof __types_jsb__jsb.QueryProductDetailsParamsProduct;
+            public static newBuilder(): __types_jsb_jsb__QueryProductDetailsParamsBuilder;
+        }
+        export interface __types_jsb_jsb__QueryProductDetailsParamsBuilder {
+            setProductList: (products: __types_jsb_jsb__QueryProductDetailsParamsProduct[]) => __types_jsb_jsb__QueryProductDetailsParamsBuilder;
+            build: () => __types_jsb_jsb__QueryProductDetailsParams;
+        }
+        export interface __types_jsb_jsb__UserChoiceBillingListener {
+            userSelectedAlternativeBilling(userChoiceDetails: __types_jsb_jsb__UserChoiceDetails): void;
+        }
+        export interface __types_jsb_jsb__PurchasesUpdatedListener {
+            onPurchasesUpdated(billingResult: __types_jsb_jsb__BillingResult, purchases: __types_jsb_jsb__Purchase[]): void;
+        }
+        export interface __types_jsb_jsb__BillingClientBuilder {
+            enableAlternativeBillingOnly: () => __types_jsb_jsb__BillingClientBuilder;
+            enableExternalOffer: () => __types_jsb_jsb__BillingClientBuilder;
+            enablePendingPurchases: (params: __types_jsb_jsb__PendingPurchasesParams) => __types_jsb_jsb__BillingClientBuilder;
+            enableUserChoiceBilling: (userChoiceBillingListener: __types_jsb_jsb__UserChoiceBillingListener) => __types_jsb_jsb__BillingClientBuilder;
+            setListener: (listener: __types_jsb_jsb__PurchasesUpdatedListener) => __types_jsb_jsb__BillingClientBuilder;
+            build: () => __types_jsb_jsb__BillingClient;
+        }
         export interface __types_jsb_jsb__BillingConfig {
             /**
              * @en The customer's country code.
              * @zh 客户的国家代码。
              */
-            readonly countryCode: string;
+            getCountryCode(): string;
         }
         /**
          * @en The details used to report transactions made via alternative billing without user choice to use Google Play Billing.
          * @zh 用于报告用户未选择使用 Google Play Billing方式而通过替代Billing方式进行的交易的详细信息。
@@ -72751,9 +72491,9 @@
              * @en An external transaction token that can be used to report a transaction made via alternative billing
              *     without user choice to use Google Play billing.
              * @zh 返回一个外部交易令牌,该令牌可用于报告通过替代付款方式进行的交易,而无需用户选择使用 Google Play 付款方式。
              */
-            readonly externalTransactionToken: string;
+            getExternalTransactionToken(): string;
         }
         /**
          * @en The details used to report transactions made via external offer.
          * @zh 用于报告通过外部报价进行的交易的详细信息。
@@ -72762,26 +72502,459 @@
             /**
              * @en An external transaction token that can be used to report a transaction made via external offer.
              * @zh 可用于报告通过外部报价进行的交易的外部交易令牌。
              */
-            readonly externalTransactionToken: string;
+            getExternalTransactionToken(): string;
         }
         /**
          * @en Results related to in-app messaging.
          * @zh 与应用程序内消息相关的结果。
          */
-        export interface __types_jsb_jsb__InAppMessageResult {
+        export class __types_jsb_jsb__InAppMessageResult {
+            static InAppMessageResponseCode: typeof __types_jsb_jsb__InAppMessageResponseCode;
             /**
              * @en Response code for the in-app messaging API call.
              * @zh 应用内消息传递 API 调用的响应代码。
              */
-            readonly responseCode: number;
+            getResponseCode(): number;
             /**
              * @en Token that identifies the purchase to be acknowledged, if any.
              * @zh 返回标识需要确认的购买的令牌。
              */
-            readonly purchaseToken: string;
+            getPurchaseToken(): string;
         }
+        /**
+         * @en
+         * Supported replacement modes to replace an existing subscription with a new one.
+         *
+         * @zh
+         * 支持替换模式,可将现有订购替换为新订购。
+         */
+        export enum __types_jsb_jsb__ReplacementMode {
+            /**
+             * @en
+             * Unknown replacement mode.
+             *
+             * @zh
+             * 未知替换模式
+             */
+            UNKNOWN_REPLACEMENT_MODE = 0,
+            /**
+             * @en
+             * The new plan takes effect immediately, and the remaining time will be prorated and credited to the user.
+             *
+             * @zh
+             * 新计划立即生效,剩余时间将按比例计入用户贷方。
+             */
+            WITH_TIME_PRORATION = 1,
+            /**
+             * @en
+             * The new plan takes effect immediately, and the billing cycle remains the same.
+             *
+             * @zh
+             * 新计划立即生效,计费周期保持不变。
+             */
+            CHARGE_PRORATED_PRICE = 2,
+            /**
+             * @en
+             * The new plan takes effect immediately, and the new price will be charged on next recurrence time.
+             *
+             * @zh
+             * 新计划立即生效,新价格将在下次复诊时收取。
+             */
+            WITHOUT_PRORATION = 3,
+            /**
+             * @en
+             * Replacement takes effect immediately, and the user is charged full price of new plan and
+             * is given a full billing cycle of subscription, plus remaining prorated time from the old plan.
+             *
+             * @zh
+             * 替换立即生效,用户将被收取新计划的全额费用,并获得一个完整的计费周期,加上旧计划按比例计算的剩余时间。
+             */
+            CHARGE_FULL_PRICE = 5,
+            /**
+             * @en
+             * The new purchase takes effect immediately, the new plan will take effect when the old item expires.
+             *
+             * @zh
+             * 新购买立即生效,新计划将在旧项目到期时生效。
+             */
+            DEFERRED = 6
+        }
+        export class __types_jsb_jsb__SubscriptionUpdateParams {
+            static Builder: __types_jsb_jsb__SubscriptionUpdateParamsBuilder;
+            static newBuilder: () => __types_jsb_jsb__SubscriptionUpdateParamsBuilder;
+            static ReplacementMode: typeof __types_jsb__jsb.ReplacementMode;
+        }
+        export interface __types_jsb_jsb__SubscriptionUpdateParamsBuilder {
+            setOldPurchaseToken: (purchaseToken: string) => __types_jsb_jsb__SubscriptionUpdateParamsBuilder;
+            setOriginalExternalTransactionId: (externalTransactionId: string) => __types_jsb_jsb__SubscriptionUpdateParamsBuilder;
+            setSubscriptionReplacementMode: (subscriptionReplacementMode: number) => __types_jsb_jsb__SubscriptionUpdateParamsBuilder;
+            build: () => __types_jsb_jsb__SubscriptionUpdateParams;
+        }
+        export class __types_jsb_jsb__BillingFlowParams {
+            static ProductDetailsParams: typeof __types_jsb__jsb.ProductDetailsParams;
+            static SubscriptionUpdateParams: typeof __types_jsb__jsb.SubscriptionUpdateParams;
+            static Builder: __types_jsb_jsb__BillingFlowParamsBuilder;
+            public static newBuilder(): __types_jsb_jsb__BillingFlowParamsBuilder;
+        }
+        export class __types_jsb_jsb__ConsumeParams {
+            public static newBuilder(): __types_jsb_jsb__ConsumeParamsBuilder;
+        }
+        export interface __types_jsb_jsb__ConsumeParamsBuilder {
+            setPurchaseToken: (purchaseToken: string) => __types_jsb_jsb__ConsumeParamsBuilder;
+            build: () => __types_jsb_jsb__ConsumeParams;
+        }
+        export class __types_jsb_jsb__AcknowledgePurchaseParams {
+            public static newBuilder(): __types_jsb_jsb__AcknowledgePurchaseParamsBuilder;
+        }
+        export interface __types_jsb_jsb__AcknowledgePurchaseParamsBuilder {
+            setPurchaseToken: (purchaseToken: string) => __types_jsb_jsb__AcknowledgePurchaseParamsBuilder;
+            build: () => __types_jsb_jsb__AcknowledgePurchaseParams;
+        }
+        export class __types_jsb_jsb__QueryPurchasesParams {
+            public static newBuilder(): __types_jsb_jsb__QueryPurchasesParamsBuilder;
+        }
+        export interface __types_jsb_jsb__QueryPurchasesParamsBuilder {
+            setProductType: (productType: string) => __types_jsb_jsb__QueryPurchasesParamsBuilder;
+            build: () => __types_jsb_jsb__QueryPurchasesParams;
+        }
+        /**
+         * @en
+         * A high-level category of the in-app message.
+         * One category can be mapped to multiple in-app messages.
+         *
+         * @zh
+         * 应用程序内信息的高级类别。
+         * 一个类别可映射到多个应用程序内信息。
+         */
+        export enum __types_jsb_jsb__InAppMessageCategoryId {
+            /**
+             * @en
+             * A Product type for Android apps in-app products.
+             *
+             * @zh
+             * 应用程序中未知的消息类别 ID
+             */
+            UNKNOWN_IN_APP_MESSAGE_CATEGORY_ID = 0,
+            /**
+             * @en
+             * The in-app messages of this category are for transactional purpose, such as payment issues.
+             *
+             * @zh
+             * 这类应用内信息用于交易目的,如支付问题。
+             */
+            TRANSACTIONAL = 2
+        }
+        export class __types_jsb_jsb__InAppMessageParams {
+            public static newBuilder(): __types_jsb_jsb__InAppMessageParamsBuilder;
+            static InAppMessageCategoryId: typeof __types_jsb_jsb__InAppMessageCategoryId;
+        }
+        export interface __types_jsb_jsb__InAppMessageParamsBuilder {
+            addAllInAppMessageCategoriesToShow: () => __types_jsb_jsb__InAppMessageParamsBuilder;
+            addInAppMessageCategoryToShow: (inAppMessageCategoryId: number) => __types_jsb_jsb__InAppMessageParamsBuilder;
+            build: () => __types_jsb_jsb__InAppMessageParams;
+        }
+        export interface __types_jsb_jsb__GetBillingConfigParamsBuilder {
+            build: () => __types_jsb_jsb__GetBillingConfigParams;
+        }
+        export class __types_jsb_jsb__GetBillingConfigParams {
+            public static newBuilder(): __types_jsb_jsb__GetBillingConfigParamsBuilder;
+        }
+        /**
+         * @en
+         * Connection state of billing client.
+         *
+         * @zh
+         * Billing client的连接状态
+         */
+        export enum __types_jsb_jsb__ConnectionState {
+            /**
+             * @en
+             * This client was not yet connected to billing service or was already closed.
+             *
+             * @zh
+             * 此客户端尚未连接到Billing服务或已关闭。
+             */
+            DISCONNECTED = 0,
+            /**
+             * @en
+             * This client is currently in process of connecting to billing service.
+             *
+             * @zh
+             * 此客户端目前正在连接到Billing服务。
+             */
+            CONNECTING = 1,
+            /**
+             * @en
+             * This client is currently connected to billing service.
+             *
+             * @zh
+             * 此客户端当前已连接到Billing服务。
+             */
+            CONNECTED = 2,
+            /**
+             * @en
+             * This client was already closed and shouldn't be used again.
+             *
+             * @zh
+             * 该客户端已关闭,不应再次使用。
+             */
+            CLOSED = 3
+        }
+        /**
+         * @en
+         * Possible response codes.
+         *
+         * @zh
+         * 可能的响应代码。
+         */
+        export enum __types_jsb_jsb__BillingResponseCode {
+            /**
+             * @en
+             * This field is deprecated.
+             * See SERVICE_UNAVAILABLE which will be used instead of this code.
+             *
+             * @zh
+             * 这个字段已经废弃。
+             * 看看SERVICE_UNAVAILABLE将使用哪一个来代替此代码。
+             */
+            SERVICE_TIMEOUT = "Bad expression <-3>",
+            /**
+             * @en
+             * The requested feature is not supported by the Play Store on the current device.
+             *
+             * @zh
+             * 当前设备上的 Play Store 不支持所请求的功能。
+             */
+            FEATURE_NOT_SUPPORTED = "Bad expression <-2>",
+            /**
+             * @en
+             * The app is not connected to the Play Store service via the Google Play Billing Library.
+             *
+             * @zh
+             * 该应用未通过 Google Play Billing库连接到 Play Store 服务。
+             */
+            SERVICE_DISCONNECTED = "Bad expression <-1>",
+            /**
+             * @en
+             * Success.
+             *
+             * @zh
+             * 成功。
+             */
+            OK = 0,
+            /**
+             * @en
+             * Transaction was canceled by the user.
+             *
+             * @zh
+             * 交易已被用户取消。
+             */
+            USER_CANCELED = 1,
+            /**
+             * @en
+             * The service is currently unavailable.
+             *
+             * @zh
+             * 当前设备上的 Play Store 不支持所请求的功能。
+             */
+            SERVICE_UNAVAILABLE = 2,
+            /**
+             * @en
+             * A user billing error occurred during processing.
+             *
+             * @zh
+             * 处理过程中出现用户billing错误。
+             */
+            BILLING_UNAVAILABLE = 3,
+            /**
+             * @en
+             * The requested product is not available for purchase.
+             *
+             * @zh
+             * 所请求的产品无法购买。
+             */
+            ITEM_UNAVAILABLE = 4,
+            /**
+             * @en
+             * Error resulting from incorrect usage of the API.
+             *
+             * @zh
+             * 由于错误使用 API 而导致的错误。
+             */
+            DEVELOPER_ERROR = 5,
+            /**
+             * @en
+             * Fatal error during the API action.
+             *
+             * @zh
+             * API 操作期间发生致命错误。
+             */
+            ERROR = 6,
+            /**
+             * @en
+             * The purchase failed because the item is already owned.
+             *
+             * @zh
+             * 购买失败,因为该物品已被拥有。
+             */
+            ITEM_ALREADY_OWNED = 7,
+            /**
+             * @en
+             * Requested action on the item failed since it is not owned by the user.
+             *
+             * @zh
+             * 由于该项目不属于用户,因此对该项目请求的操作失败。
+             */
+            ITEM_NOT_OWNED = 8,
+            /**
+             * @en
+             * A network error occurred during the operation.
+             *
+             * @zh
+             * 操作期间发生网络错误。
+             */
+            NETWORK_ERROR = 12
+        }
+        /**
+         * @en
+         * Features/capabilities supported by isFeatureSupported.
+         *
+         * @zh
+         * 支持的特性/能力isFeatureSupported。
+         */
+        export enum __types_jsb_jsb__FeatureType {
+            /**
+             * @en
+             * Purchase/query for subscriptions.
+             *
+             * @zh
+             * 购买/查询订阅。
+             */
+            SUBSCRIPTIONS = "subscriptions",
+            /**
+             * @en
+             * Subscriptions update/replace.
+             *
+             * @zh
+             * 订阅更新/替换。
+             */
+            SUBSCRIPTIONS_UPDATE = "subscriptionsUpdate",
+            /**
+             * @en
+             * Launch a price change confirmation flow.
+             *
+             * @zh
+             * 启动价格变动确认流程。
+             */
+            PRICE_CHANGE_CONFIRMATION = "priceChangeConfirmation",
+            /**
+             * @en
+             * Show in-app messages.
+             *
+             * @zh
+             * 显示应用内消息。
+             */
+            IN_APP_MESSAGING = "bbb",
+            /**
+             * @en
+             * Play billing library support for querying and purchasing.
+             *
+             * @zh
+             * Play Billing库支持查询、购买。
+             */
+            PRODUCT_DETAILS = "fff",
+            /**
+             * @en
+             * Get billing config.
+             *
+             * @zh
+             * 获取计费配置。
+             */
+            BILLING_CONFIG = "ggg",
+            /**
+             * @en
+             * Alternative billing only.
+             *
+             * @zh
+             * 仅限替代Billing。
+             */
+            ALTERNATIVE_BILLING_ONLY = "jjj",
+            /**
+             * @en
+             * Play billing library support for external offer.
+             *
+             * @zh
+             * Play billing库支持外部报价。
+             */
+            EXTERNAL_OFFER = "kkk"
+        }
+        /**
+         * @en
+         * Supported Product types.
+         *
+         * @zh
+         * 支持的产品类型。
+         */
+        export enum __types_jsb_jsb__ProductType {
+            /**
+             * @en
+             * A Product type for Android apps in-app products.
+             *
+             * @zh
+             * Android 应用内产品的产品类型。
+             */
+            INAPP = "inapp",
+            /**
+             * @en
+             * A Product type for Android apps subscriptions.
+             *
+             * @zh
+             * Android 应用程序订阅的产品类型。
+             */
+            SUBS = "subs"
+        }
+        export interface __types_jsb_jsb__BillingClientStateListener {
+            onBillingServiceDisconnected(): void;
+            onBillingSetupFinished(billingResult: __types_jsb_jsb__BillingResult): void;
+        }
+        export interface __types_jsb_jsb__ProductDetailsResponseListener {
+            onProductDetailsResponse(billingResult: __types_jsb_jsb__BillingResult, productDetailsList: __types_jsb_jsb__ProductDetails[]): void;
+        }
+        export interface __types_jsb_jsb__ConsumeRespo...*[Comment body truncated]*

@minggo minggo merged commit a2c7ea8 into cocos:v3.8.6 Dec 23, 2024
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants