import { APIResource } from "../core/resource.mjs"; import * as BusinessPartnerGroupsAPI from "./business-partner-groups.mjs"; import * as WorkersAPI from "./workers.mjs"; import * as SupergroupsAPI from "./supergroups/supergroups.mjs"; import { APIPromise } from "../core/api-promise.mjs"; import { PageCursorURL, PagePromise } from "../core/pagination.mjs"; import { RequestOptions } from "../internal/request-options.mjs"; /** * Business partners of the company */ export declare class BusinessPartners extends APIResource { /** * A list of business partners. * * - Requires: `API Tier 1` * - Filterable fields: `worker_id`, `business_partner_group_id` * - Expandable fields: `business_partner_group`, `worker`, `client_group` * - Sortable fields: `id`, `created_at`, `updated_at` */ list(query?: BusinessPartnerListParams | null | undefined, options?: RequestOptions): PagePromise; /** * Create a new business partner */ create(body: BusinessPartnerCreateParams, options?: RequestOptions): APIPromise; /** * Retrieve a specific business partner */ retrieve(id: string, query?: BusinessPartnerRetrieveParams | null | undefined, options?: RequestOptions): APIPromise; /** * Delete a business partner */ delete(id: string, options?: RequestOptions): APIPromise; } export type BusinessPartnersPageCursorURL = PageCursorURL; export interface BusinessPartner { /** * Identifier field */ id: string; /** * Identifier of business partner group the business parter is a part of */ business_partner_group_id: string; /** * Record creation date */ created_at: string; /** * Record update date */ updated_at: string; /** * Identifier of worker who is the business partner */ worker_id: string; /** * Business partner group the business partner is a part of * * Expandable field */ business_partner_group?: BusinessPartnerGroupsAPI.BusinessPartnerGroup; /** * Group of workers associated with the business partner * * Expandable field */ client_group?: SupergroupsAPI.Supergroup; /** * Identifier of group of workers associated with the business partner */ client_group_id?: string; /** * Number of workers associated with the business partner */ client_group_member_count?: number; /** * Worker who is the business partner * * Expandable field */ worker?: WorkersAPI.Worker; } /** * Meta information for the response. */ export interface Meta { __meta?: Meta._Meta; } export declare namespace Meta { interface _Meta { redacted_fields?: Array<_Meta.RedactedField>; } namespace _Meta { /** * Info about the redacted fields. */ interface RedactedField { /** * The name for the redacted field */ name?: string; /** * The reason for the redaction */ reason?: string; } } } /** * Meta information for the response. */ export interface BusinessPartnerRetrieveResponse extends Meta, BusinessPartner { } export interface BusinessPartnerListParams { cursor?: string; expand?: string; filter?: string; order_by?: string; } export interface BusinessPartnerCreateParams { /** * Identifier of business partner group the business parter is a part of */ business_partner_group_id: string; /** * Identifier of worker who is the business partner */ worker_id: string; } export interface BusinessPartnerRetrieveParams { expand?: string; } export declare namespace BusinessPartners { export { type BusinessPartner as BusinessPartner, type Meta as Meta, type BusinessPartnerRetrieveResponse as BusinessPartnerRetrieveResponse, type BusinessPartnersPageCursorURL as BusinessPartnersPageCursorURL, type BusinessPartnerListParams as BusinessPartnerListParams, type BusinessPartnerCreateParams as BusinessPartnerCreateParams, type BusinessPartnerRetrieveParams as BusinessPartnerRetrieveParams, }; } //# sourceMappingURL=business-partners.d.mts.map