UNPKG

@prass/botpress-native

Version:

A simple and powerful SDK for integrating Botpress Chat API with React Native,

12 lines (11 loc) 694 B
import { GetOrCreateUserParams } from "../../types/botpress"; import { Botpress } from "../Botpress"; import { GetOrCreateUserResponse } from "../../types/botpress.response"; /** * Internal handler for retrieving an existing user or creating a new one if not found. * @param this - Botpress instance context * @param params - Parameters containing user details (name, pictureUrl, profile) * @returns Promise resolving to the user’s details (either existing or newly created) * @throws Error if user key is missing or API call fails */ export declare function handleGetOrCreateUser(this: Botpress, { name, pictureUrl, profile }: GetOrCreateUserParams): Promise<GetOrCreateUserResponse>;