import { NativeModules } from "react-native";

const { WWNativeModule } = NativeModules;

interface WeWorkInterface {
  /**
   * 初始化
   */
  init: (schema: string) => void;
  /**
   * 登录
   */
  login: (appId: string, agentId: string, schema: string) => Promise<string>;
  /**
   * 获取常量
   */
  getConstants: () => Record<string, string>;
}

export const WeWork = WWNativeModule as WeWorkInterface;
