import { Method } from 'axios'; import { Executable } from './executable'; /** * The CreatePersonInput used by the constructor of CreatePerson */ export interface CreatePersonInput { /** * first name on the person. */ firstName?: string; /** * last name on the person. */ lastName?: string; /** * email on the person. */ email?: string; /** * phone number on the person, should start with +{country code} */ phone?: string; /** * any additional metadata attributes required by the person. */ metadata?: { [key: string]: string; }; /** * Existing person id if updating a customer record */ personId?: string; } /** * The CreatePerson response expected from the execution of the object within BambuClient execute. */ export interface CreatePersonResponse { /** * the message response from the request */ message: string; /** * any error messages that were returned by the request. */ error?: any; /** * If the person already exists, the personId is returned. */ personId?: string; } /** * The create person api is an asyncronous request to BambuMeta to issue the provided user an person. This request * will not guarentee an person is created. But checks if there is already an existing person. If so, the person id is returned. If no person already exists, * the request will be added to the processor for consumption and a success message should be returned. */ export declare class CreatePerson extends Executable { /** * getMethod is used by the BambuClient to properly construct the request call. * @returns request method */ getMethod(): Method; /** * getResponse is used by the BambuClient to propery return the response object type. * @param apiResponse the api response object returned by the BambuMeta client before being converted to the CreatePersonResponse * @returns CreatePersonResponse */ getResponse(apiResponse: any): CreatePersonResponse; /** * getURLPath is used by the BambuClient to properly construct the request call. * @param tenantId the tenant id defined in the BambuClient * @returns request url */ getURLPath(tenantId?: string): string; private _firstName?; private _lastName?; private _email?; private _phone?; private _metadata?; private _personId?; constructor(input?: CreatePersonInput); /** * Sets the first name on the person. * @param value first name * @returns */ setFirstName(value: string): CreatePerson; /** * Sets the last name on the person. * @param value last name * @returns */ setLastName(value: string): CreatePerson; /** * Sets the email address on the person. * @param value email * @returns */ setEmail(value: string): CreatePerson; /** * Sets the phone number on the person. * @param value phone number, should start with +{country code} * @returns */ setPhone(value: string): CreatePerson; /** * Sets the personId if known and the customer already exists to update the record. * @param value personId if known. * @returns */ setPersonId(value: string): CreatePerson; /** * Sets any additional metadata to be stored against the person record * @param key the metadata attribute key * @param value the metadata attribute value * @returns */ setMetaData(key: string, value: string): CreatePerson; /** * getBody is used by the BambuClient to properly construct the request object body. * @returns Returns the expected body of the request utilizing the defined request attributes. */ getBody(): any; /** * getRootPath is used by the BambuClient to properly construct the request call. * @returns The root path of the request */ getRootPath(): string | undefined; }