/**
 * This code was generated by "react-native codegen-lib-harmony"
 */

import { Tag } from "@rnoh/react-native-openharmony/ts"

export namespace WechatLibTurboModule {
  export const NAME = 'WechatLibTurboModule' as const

  export enum WXScene {
    WXSceneSession = 0,
    WXSceneTimeline = 1,
    WXSceneFavorite = 2,
    WXSceneSpecifiedSession = 3,
  }

  export type GeneratedTypeLiteralInterface_2 = {authCode: null | string, errCode: null | number}
  
  export type ShareTextMetadata = {text: string, scene?: WXScene}
  
  export type ShareImageMetadata = {imageUrl: string, scene?: WXScene}
  
  export type ShareFileMetadata = {url: string, title?: string, ext?: string, scene?: WXScene}
  
  export type ShareMusicMetadata = {musicUrl: string, musicLowBandUrl?: string, musicDataUrl?: string, musicLowBandDataUrl?: string, title?: string, description?: string, thumbImageUrl?: string, scene?: WXScene}
  
  export type ShareVideoMetadata = {videoUrl: string, videoLowBandUrl?: string, title?: string, description?: string, thumbImageUrl?: string, scene?: WXScene}
  
  export type ShareWebpageMetadata = {webpageUrl: string, title?: string, description?: string, thumbImageUrl?: string, scene?: WXScene}
  
  export type ShareMiniProgramMetadata = {webpageUrl?: string, userName: string, path?: string, hdImageUrl?: string, withShareTicket?: boolean, miniProgramType?: number, title?: string, description?: string, thumbImageUrl?: string, scene?: WXScene}
  
  export type LaunchMiniProgramMetadata = {userName: string, miniProgramType?: number, path?: string}
  
  export type ChooseInvoice = {signType?: string, nonceStr?: string, timeStamp?: number, cardSign?: string}
  
  export type PaymentLoad = {partnerId: string, prepayId: string, nonceStr: string, timeStamp: string, package: string, sign: string, extData: string}
  
  export type SubscribeMessageMetadata = {scene?: WXScene, templateId: string, reserved?: string}
  
  export interface Spec {
    registerApp(appId: string, universalLink: string, callback: (error: null | string, result: null | boolean) => void): void;
  
    isWXAppInstalled(callback: (error: null | string, result: null | boolean) => void): void;
  
    isWXAppSupportApi(callback: (error: null | string, result: null | boolean) => void): void;
  
    getApiVersion(callback: (error: null | string, result: null | boolean) => void): void;
  
    openWXApp(callback: (error: null | string, result: null | boolean) => void): void;
  
    sendAuthRequest(scope: string, state: string, callback: (error: null | string, result: null | boolean) => void): void;
  
    authByScan(appId: string, nonceStr: string, timeStamp: string, scope: string, signature: string, schemeData: string, callback: (error: null | string, result: null | GeneratedTypeLiteralInterface_2) => void): void;
  
    shareText(message: ShareTextMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareImage(message: ShareImageMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareLocalImage(message: ShareImageMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareFile(message: ShareFileMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareMusic(message: ShareMusicMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareVideo(message: ShareVideoMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareWebpage(message: ShareWebpageMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    shareMiniProgram(message: ShareMiniProgramMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    launchMiniProgram(message: LaunchMiniProgramMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    chooseInvoice(data: ChooseInvoice, callback: (error: null | string, result: null | boolean) => void): void;
  
    pay(payload: PaymentLoad, callback: (result: null | Object) => void): void;
  
    subscribeMessage(message: SubscribeMessageMetadata, callback: (error: null | string, result: null | boolean) => void): void;
  
    subscribeAuthGotQrcode(onQRGet: (qrcode: string) => void): void;
  
    unSubscribeAuthGotQrcode(): void;
  
    registerCallback(name: string, callback: (result: null | Object) => void): void;
  
    unregisterCallback(name: string): void;
  
  }
}
