{"version":3,"sources":["../../../src/tips-staff-v1-staff-tippable-staff.http.ts","../../../src/tips-staff-v1-staff-tippable-staff.types.ts","../../../src/tips-staff-v1-staff-tippable-staff.meta.ts"],"sourcesContent":["import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixTipsStaffV1TipStaffServiceUrl(\n  opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n  const domainToMappings = {\n    'manage._base_domain_': [\n      {\n        srcPath: '/_api/tips-staff-service',\n        destPath: '',\n      },\n    ],\n    _: [\n      {\n        srcPath: '/_api/tips-staff-service',\n        destPath: '',\n      },\n    ],\n    'bo._base_domain_': [\n      {\n        srcPath: '/_api/tips-staff-service',\n        destPath: '',\n      },\n    ],\n    'wixbo.ai': [\n      {\n        srcPath: '/_api/tips-staff-service',\n        destPath: '',\n      },\n    ],\n    'wix-bo.com': [\n      {\n        srcPath: '/_api/tips-staff-service',\n        destPath: '',\n      },\n    ],\n    'www.wixapis.com': [\n      {\n        srcPath: '/tips-staff',\n        destPath: '',\n      },\n    ],\n    '*.dev.wix-code.com': [\n      {\n        srcPath: '/tips/staff/v1/eligible-staff',\n        destPath: '/v1/eligible-staff',\n      },\n    ],\n  };\n\n  return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_tippable-staff';\n\n/**\n * Retrieves a list of up to 100 staff who are eligible to receive tips, given\n * the provided filtering.\n */\nexport function listTippableStaff(payload: object): RequestOptionsFactory<any> {\n  function __listTippableStaff({ host }: any) {\n    const metadata = {\n      entityFqdn: 'wix.tips.staff.v1.staff',\n      method: 'GET' as any,\n      methodFqn: 'wix.tips.staff.v1.TipStaffService.ListTippableStaff',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveWixTipsStaffV1TipStaffServiceUrl({\n        protoPath: '/v1/eligible-staff',\n        data: payload,\n        host,\n      }),\n      params: toURLSearchParams(payload),\n    };\n\n    return metadata;\n  }\n\n  return __listTippableStaff;\n}\n","/**\n * Information about a team member who's eligible to receive a portion of the tip.\n * Currently, only Bookings staff members ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/staff-members/introduction) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/staff-members/staff-member-object))\n * and [site collaborators](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site)\n * are eligible for tip distributions.\n */\nexport interface Staff {\n  /**\n   * Staff ID. Matches `staffMemberId` if available, or\n   * `identificationData.wixUserId` if not.\n   * @format GUID\n   * @readonly\n   */\n  id?: string | null;\n  /**\n   * Staff name. Matches the name of the\n   * Bookings staff member ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/staff-members/introduction) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/staff-members/staff-member-object)),\n   * if available.\n   * @maxLength 500\n   */\n  name?: string | null;\n  /**\n   * Staff member ID. Available only if the staff is connected to a\n   * Bookings staff member ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/staff-members/introduction) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/staff-members/staff-member-object)).\n   * @format GUID\n   */\n  staffMemberId?: string | null;\n  /**\n   * Identification data of the staff. Available only if the staff is a\n   * [site collaborator](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site).\n   */\n  identificationData?: IdentificationData;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n  /**\n   * ID of a site visitor who hasn't logged in to the site.\n   * @format GUID\n   */\n  anonymousVisitorId?: string;\n  /**\n   * ID of a site visitor who has logged in to the site.\n   * @format GUID\n   */\n  memberId?: string;\n  /**\n   * ID of a Wix user. For example, the site owner or a\n   * [site collaborator](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site).\n   * @format GUID\n   */\n  wixUserId?: string;\n  /**\n   * ID of an app.\n   * @format GUID\n   */\n  appId?: string;\n  /**\n   * ID of the contact in the site's [CRM by Ascend](https://www.wix.com/ascend/crm) system.\n   * See the Contacts API for additional details.\n   * @format GUID\n   */\n  contactId?: string | null;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n  /**\n   * ID of a site visitor who hasn't logged in to the site.\n   * @format GUID\n   */\n  anonymousVisitorId?: string;\n  /**\n   * ID of a site visitor who has logged in to the site.\n   * @format GUID\n   */\n  memberId?: string;\n  /**\n   * ID of a Wix user. For example, the site owner or a\n   * [site collaborator](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site).\n   * @format GUID\n   */\n  wixUserId?: string;\n  /**\n   * ID of an app.\n   * @format GUID\n   */\n  appId?: string;\n}\n\nexport enum IdentityType {\n  UNKNOWN = 'UNKNOWN',\n  ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n  MEMBER = 'MEMBER',\n  WIX_USER = 'WIX_USER',\n  APP = 'APP',\n}\n\n/** @enumType */\nexport type IdentityTypeWithLiterals =\n  | IdentityType\n  | 'UNKNOWN'\n  | 'ANONYMOUS_VISITOR'\n  | 'MEMBER'\n  | 'WIX_USER'\n  | 'APP';\n\nexport interface ListTippableStaffRequest {\n  /**\n   * Whether to include staff who are only Wix users and not\n   * Bookings staff members ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/staff-members/introduction) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/staff-members/staff-member-object))\n   * in the response. Setting `{\"includeWixUsers\": true}` returns all tippable\n   * staff, including Bookings staff, site collaborators, or those who are both.\n   * By default, or if you provide `{\"includeWixUsers\": false}`, only Bookings\n   * staff members or those who are both are returned.\n   *\n   * Default: `false`.\n   */\n  includeWixUsers?: boolean;\n  /**\n   * Filters the returned staff by name. If you provide a name as filter, only\n   * staff whose names start with the given input are returned. The filter isn't\n   * case sensitive.\n   *\n   * Max: 500 characters\n   * @maxLength 500\n   */\n  filterByName?: string | null;\n  /**\n   * Filters the returned staff by ID. If you provide a list of IDs as filter,\n   * only staff members with exact matching IDs are returned.\n   *\n   * Max: 100 IDs\n   * @maxSize 100\n   * @format GUID\n   */\n  filterByIds?: string[] | null;\n}\n\nexport interface ListTippableStaffResponse {\n  /**\n   * Retrieved staff.\n   * @maxSize 100\n   */\n  staff?: Staff[];\n}\n","import * as ambassadorWixTipsStaffV1Staff from './tips-staff-v1-staff-tippable-staff.http.js';\nimport * as ambassadorWixTipsStaffV1StaffTypes from './tips-staff-v1-staff-tippable-staff.types.js';\nimport * as ambassadorWixTipsStaffV1StaffUniversalTypes from './tips-staff-v1-staff-tippable-staff.universal.js';\n\nexport type __PublicMethodMetaInfo<\n  K = string,\n  M = unknown,\n  T = unknown,\n  S = unknown,\n  Q = unknown,\n  R = unknown\n> = {\n  getUrl: (context: any) => string;\n  httpMethod: K;\n  path: string;\n  pathParams: M;\n  __requestType: T;\n  __originalRequestType: S;\n  __responseType: Q;\n  __originalResponseType: R;\n};\n\nexport function listTippableStaff(): __PublicMethodMetaInfo<\n  'GET',\n  {},\n  ambassadorWixTipsStaffV1StaffUniversalTypes.ListTippableStaffRequest,\n  ambassadorWixTipsStaffV1StaffTypes.ListTippableStaffRequest,\n  ambassadorWixTipsStaffV1StaffUniversalTypes.ListTippableStaffResponse,\n  ambassadorWixTipsStaffV1StaffTypes.ListTippableStaffResponse\n> {\n  const payload = {} as any;\n\n  const getRequestOptions =\n    ambassadorWixTipsStaffV1Staff.listTippableStaff(payload);\n\n  const getUrl = (context: any): string => {\n    const { url } = getRequestOptions(context);\n    return url!;\n  };\n\n  return {\n    getUrl,\n    httpMethod: 'GET',\n    path: '/v1/eligible-staff',\n    pathParams: {},\n    __requestType: null as any,\n    __originalRequestType: null as any,\n    __responseType: null as any,\n    __originalResponseType: null as any,\n  };\n}\n\nexport {\n  Staff as StaffOriginal,\n  IdentificationData as IdentificationDataOriginal,\n  IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal,\n  IdentityType as IdentityTypeOriginal,\n  IdentityTypeWithLiterals as IdentityTypeWithLiteralsOriginal,\n  ListTippableStaffRequest as ListTippableStaffRequestOriginal,\n  ListTippableStaffResponse as ListTippableStaffResponseOriginal,\n} from './tips-staff-v1-staff-tippable-staff.types.js';\n"],"mappings":";AAAA,SAAS,yBAAyB;AAClC,SAAS,kBAAkB;AAI3B,SAAS,wCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,oBAAoB;AAAA,MAClB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,YAAY;AAAA,MACV;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,cAAc;AAAA,MACZ;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,sBAAsB;AAAA,MACpB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,SAAO,WAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAMd,SAAS,kBAAkB,SAA6C;AAC7E,WAAS,oBAAoB,EAAE,KAAK,GAAQ;AAC1C,UAAM,WAAW;AAAA,MACf,YAAY;AAAA,MACZ,QAAQ;AAAA,MACR,WAAW;AAAA,MACX,aAAa;AAAA,MACb,kBAAkB;AAAA,QAChB,wBAAwB;AAAA,MAC1B;AAAA,MACA,KAAK,wCAAwC;AAAA,QAC3C,WAAW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