兼容端
安卓 | 苹果 | Web | 鸿蒙 | 小程序 |
---|---|---|---|---|
✅ | ✅ | ❌ | ❌ | ❌ |
使用示例
vue
<script>
import { TstartFacial,TTFacialcorebodyResult,TTFacialcorebodyOptions } from "@/uni_modules/t-tfacialcore-api"
const handleOpenAuth = () => {
TstartFacial({
faceId: "",
agreementNo: "",
openApiAppId: "",
openApiAppVersion: "",
openApiNonce: "",
openApiUserId: "",
openApiSign: "",
verifyMode: 0,
keyLicence: "",
success: (result:TTFacialcorebodyResult) => {
},
fail: (result: TTFacialcorebodyResult) => {
}
} as TTFacialcorebodyOptions)
}
</script>
暴露的类型
ts
export type TTFacialcorebodyResult = {
code: number;
msg: string;
data?: any;
}
export type TTFacialcorebodyOptions = {
faceId?: string;
agreementNo?: string;
openApiAppId?: string;
openApiAppVersion?: string;
openApiNonce?: string;
openApiUserId?: string;
openApiSign?: string;
verifyMode?: number;
keyLicence?: string;
success?: (result: TTFacialcorebodyResult) => void;
fail?: (result: TTFacialcorebodyResult) => void;
}
export declare function TstartFacial(options:TTFacialcorebodyOptions): void;