async lookupMergeHistory(params = {}) {
    const { customerId, errorOnNotFound } = await validateAsync(Joi.object({
      customerId: this.schema.customerId.required(),
      errorOnNotFound: Joi.boolean().default(false),
    }).required(), params);
    const endpoint = `/customer/${customerId}/mergehistory/*`;
    const response = await this.client.get({ endpoint, errorOnNotFound });
    const customerIds = response.getAsArray('CustomerMergeHistory').map((customer) => customer.Id);
    return new ApiSetResponse({ data: customerIds, response });
  }
/**
   * This API provides capabilities to retrieve the merge history for the requested Customer Id.
   *
   * @link https://main.omeda.com/knowledge-base/customer-merge-history-lookup/
   * @param {object} params
   * @param {number} params.customerId The customer ID to find history for.
   * @param {boolean} [params.errorOnNotFound=false] Whether to error when not found.
   * @returns {Promise<ApiSetResponse>} The customer merge history.
   */
This API provides capabilities to retrieve the merge history for the requested Customer Id.
This API provides capabilities to retrieve the merge history for the requested Customer Id .
async lookupMergeHistory(params = {}) {
    const { customerId, errorOnNotFound } = await validateAsync(Joi.object({
      customerId: this.schema.customerId.required(),
      errorOnNotFound: Joi.boolean().default(false),
    }).required(), params);
    const endpoint = `/customer/${customerId}/mergehistory/*`;
    const response = await this.client.get({ endpoint, errorOnNotFound });
    const customerIds = response.getAsArray('CustomerMergeHistory').map((customer) => customer.Id);
    return new ApiSetResponse({ data: customerIds, response });
  }
async lookupMergeHistory ( params = { } ) { const { customerId , errorOnNotFound } = await validateAsync ( Joi . object ( { customerId : this . schema . customerId . required ( ) , errorOnNotFound : Joi . boolean ( ) . default ( false ) , } ) . required ( ) , params ) ; const endpoint = ` ${ customerId } ` ; const response = await this . client . get ( { endpoint , errorOnNotFound } ) ; const customerIds = response . getAsArray ( 'CustomerMergeHistory' ) . map ( ( customer ) => customer . Id ) ; return new ApiSetResponse ( { data : customerIds , response } ) ; }
This API provides capabilities to retrieve the merge history for the requested Customer Id.
This API provides capabilities to retrieve the merge history for the requested Customer Id .