/**
 * HubSpot Node - Version 2.1
 * Discriminator: resource=company, operation=searchByDomain
 */


interface Credentials {
  hubspotApi: CredentialReference;
  hubspotAppToken: CredentialReference;
  hubspotOAuth2Api: CredentialReference;
}

/** Search companies by their website domain */
export type HubspotV21CompanySearchByDomainParams = {
  resource: 'company';
  operation: 'searchByDomain';
  authentication?: 'apiKey' | 'appToken' | 'oAuth2' | Expression<string>;
/**
 * The company's website domain to search for, like n8n.io
 */
    domain?: string | Expression<string> | PlaceholderValue;
/**
 * Whether to return all results or only up to a given limit
 * @default false
 */
    returnAll?: boolean | Expression<boolean>;
/**
 * Max number of results to return
 * @displayOptions.show { returnAll: [false] }
 * @default 100
 */
    limit?: number | Expression<number>;
/**
 * Options
 * @default {}
 */
    options?: {
    /** Whether to include specific Company properties in the returned results. Choose from a list, or specify IDs using an &lt;a href="https://docs.n8n.io/code/expressions/"&gt;expression&lt;/a&gt;. Choose from the list, or specify IDs using an &lt;a href="https://docs.n8n.io/code/expressions/"&gt;expression&lt;/a&gt;.
     * @default []
     */
    properties?: string[];
  };
};

export type HubspotV21CompanySearchByDomainOutput = {
  additionalDomains?: Array<{
    domain?: string;
    source?: string;
    sourceId?: string;
    timestamp?: number;
  }>;
  companyId?: number;
  isDeleted?: boolean;
  portalId?: number;
  properties?: {
    domain?: {
      source?: string;
      timestamp?: number;
      value?: string;
      versions?: Array<{
        name?: string;
        requestId?: string;
        source?: string;
        sourceId?: string;
        sourceVid?: Array<number>;
        timestamp?: number;
        updatedByUserId?: number;
        useTimestampAsPersistenceTimestamp?: boolean;
        value?: string;
      }>;
    };
  };
};

export type HubspotV21CompanySearchByDomainNode = {
  type: 'n8n-nodes-base.hubspot';
  version: 2.1;
  credentials?: Credentials;
  config: NodeConfig<HubspotV21CompanySearchByDomainParams>;
  output?: Items<HubspotV21CompanySearchByDomainOutput>;
};