lumnisai 0.5.26 → 0.5.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -949,6 +949,9 @@ class CrmResource {
949
949
  * `crmRecordId`. Stale links (record deleted in the CRM) are detected
950
950
  * and re-created automatically.
951
951
  *
952
+ * Works with or without a `campaign_prospects` row — search-sourced
953
+ * prospects are enriched from profile cache when needed.
954
+ *
952
955
  * @example
953
956
  * ```typescript
954
957
  * const result = await client.crm.syncProspect({
@@ -968,16 +971,13 @@ class CrmResource {
968
971
  * render a "linked" indicator for the ones that come back true.
969
972
  *
970
973
  * Layered cache on the server side: persistent positive matches are
971
- * served from the `campaign_prospects.crm_record_id` column, negative
972
- * results are served from a Redis cache (TTL configured by
973
- * `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`). Only the leftover unknowns
974
- * fan out to the live CRM, bounded by
974
+ * served from the `campaign_prospects.crm_record_id` column and the
975
+ * local `crm_contacts` ledger; negative results are served from a Redis
976
+ * cache (TTL configured by `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`).
977
+ * Only the leftover unknowns fan out to the live CRM, bounded by
975
978
  * `CRM_MATCH_LIVE_SEARCH_PARALLELISM`.
976
979
  *
977
- * Note: HubSpot does not expose a LinkedIn-URL search field through
978
- * Composio, so for `provider: 'hubspot'` URLs that aren't already in
979
- * the persistent cache will always come back `linked: false`. The
980
- * sync endpoint still reconciles via email when available.
980
+ * Provider-id/URN inputs are resolved to vanity before matching.
981
981
  *
982
982
  * @example
983
983
  * ```typescript
@@ -994,6 +994,51 @@ class CrmResource {
994
994
  async matchBatch(data) {
995
995
  return this.http.post("/crm/prospects/match-batch", data);
996
996
  }
997
+ /**
998
+ * Trigger a full mirror of the owner's CRM contact book into the local
999
+ * `crm_contacts` ledger. Returns immediately (`202`); poll
1000
+ * {@link getContactsSyncStatus} for progress.
1001
+ */
1002
+ async syncContacts(data) {
1003
+ return this.http.post("/crm/contacts/sync", data);
1004
+ }
1005
+ /**
1006
+ * Ledger sync freshness for an owner+provider: connection state, whether a
1007
+ * sync is in progress, last reconcile time, and row count in the ledger.
1008
+ */
1009
+ async getContactsSyncStatus(userId, provider) {
1010
+ return this.http.get("/crm/contacts/sync-status", {
1011
+ // Backend requires snake_case query params (FastAPI `user_id`). Query
1012
+ // keys are sent verbatim by the http layer (only bodies are snake-cased),
1013
+ // so pass snake_case here like every other resource — a camelCase
1014
+ // `userId` 422s with "field required: user_id".
1015
+ params: { user_id: userId, provider }
1016
+ });
1017
+ }
1018
+ /**
1019
+ * Grant a member the right to exclude against an owner's synced CRM ledger
1020
+ * (all providers for that owner). Typically called by the FE on org join.
1021
+ */
1022
+ async grantExclusionGrant(data) {
1023
+ return this.http.post("/crm/exclusion-grants", data);
1024
+ }
1025
+ /**
1026
+ * Revoke a member's access to an owner's CRM exclusion ledger.
1027
+ */
1028
+ async revokeExclusionGrant(data) {
1029
+ return this.http.delete("/crm/exclusion-grants", {
1030
+ body: data
1031
+ });
1032
+ }
1033
+ /**
1034
+ * List CRM owners whose exclusion ledger a member may read (via grants).
1035
+ */
1036
+ async listExclusionGrants(memberUserId) {
1037
+ return this.http.get("/crm/exclusion-grants", {
1038
+ // Backend requires snake_case `member_user_id` (see getContactsSyncStatus).
1039
+ params: { member_user_id: memberUserId }
1040
+ });
1041
+ }
997
1042
  }
998
1043
 
999
1044
  class EmailResource {
@@ -3512,6 +3557,9 @@ class ResponsesResource {
3512
3557
  * @param options - Optional search parameters
3513
3558
  * @param options.limit - Maximum number of results (1-100, default: 20)
3514
3559
  * @param options.dataSources - Specific data sources to use: ["PDL", "CORESIGNAL", "CRUST_DATA"]
3560
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true (via request `options`)
3561
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
3562
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
3515
3563
  * @returns Response with structured_response containing:
3516
3564
  * - candidates: List of person results
3517
3565
  * - totalFound: Total unique candidates found
@@ -3532,6 +3580,15 @@ class ResponsesResource {
3532
3580
  params.dataSources = options.dataSources;
3533
3581
  if (Object.keys(params).length > 0)
3534
3582
  request.specializedAgentParams = params;
3583
+ const crmOptions = {};
3584
+ if (options.excludeCrmContacts !== void 0)
3585
+ crmOptions.excludeCrmContacts = options.excludeCrmContacts;
3586
+ if (options.crmExclusionOwners)
3587
+ crmOptions.crmExclusionOwners = options.crmExclusionOwners;
3588
+ if (options.crmNameCompanyMatch !== void 0)
3589
+ crmOptions.crmNameCompanyMatch = options.crmNameCompanyMatch;
3590
+ if (Object.keys(crmOptions).length > 0)
3591
+ request.options = crmOptions;
3535
3592
  }
3536
3593
  return this.create(request);
3537
3594
  }
@@ -3553,6 +3610,9 @@ class ResponsesResource {
3553
3610
  * @param options.excludeProfiles - LinkedIn URLs to exclude from results
3554
3611
  * @param options.excludePreviouslyContacted - Exclude previously contacted people
3555
3612
  * @param options.excludeNames - Names to exclude from results
3613
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true
3614
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
3615
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
3556
3616
  * @param options.searchJobSignal - CrustData job-listing signal search (decision makers at hiring companies); true | false | 'auto'
3557
3617
  * @param options.deepVerify - Web verification for org/location/third-party criteria: 'auto' (default), 'always', or 'off'
3558
3618
  * @param options.deepValidationUseRelevanceReranker - SLM relevance reranker for surfaced candidates (ranking-only); @default true
@@ -3595,6 +3655,12 @@ class ResponsesResource {
3595
3655
  params.excludePreviouslyContacted = options.excludePreviouslyContacted;
3596
3656
  if (options.excludeNames)
3597
3657
  params.excludeNames = options.excludeNames;
3658
+ if (options.excludeCrmContacts !== void 0)
3659
+ params.excludeCrmContacts = options.excludeCrmContacts;
3660
+ if (options.crmExclusionOwners)
3661
+ params.crmExclusionOwners = options.crmExclusionOwners;
3662
+ if (options.crmNameCompanyMatch !== void 0)
3663
+ params.crmNameCompanyMatch = options.crmNameCompanyMatch;
3598
3664
  if (options.searchProfiles !== void 0)
3599
3665
  params.searchProfiles = options.searchProfiles;
3600
3666
  if (options.searchPosts !== void 0)
package/dist/index.d.cts CHANGED
@@ -1742,6 +1742,26 @@ interface SpecializedAgentParams {
1742
1742
  * Names to exclude from results (passed through to CrustData post-processing when supported).
1743
1743
  */
1744
1744
  excludeNames?: string[];
1745
+ /**
1746
+ * Exclude people already in the acting user's synced CRM (`crm_contacts` ledger;
1747
+ * local lookup only, never a live CRM call). Matches on exact LinkedIn URL and
1748
+ * email; optionally name+company when `crmNameCompanyMatch` is true.
1749
+ * @default true
1750
+ * Used by deep_people_search (via `specializedAgentParams`) and quick_people_search
1751
+ * (via top-level `options` on the create request).
1752
+ */
1753
+ excludeCrmContacts?: boolean;
1754
+ /**
1755
+ * Narrow CRM exclusion to specific granted owners' ledgers (user id or email).
1756
+ * Omitted = the acting user's own CRM only. Ungranted entries are ignored.
1757
+ */
1758
+ crmExclusionOwners?: string[];
1759
+ /**
1760
+ * Within CRM exclusion, also drop candidates matching by exact name + company
1761
+ * (catches CRM contacts with no LinkedIn URL, especially HubSpot).
1762
+ * @default true
1763
+ */
1764
+ crmNameCompanyMatch?: boolean;
1745
1765
  /**
1746
1766
  * Response ID to reuse criteria from.
1747
1767
  */
@@ -2487,6 +2507,12 @@ interface CampaignGuardrails {
2487
2507
  * as a kill-switch.
2488
2508
  */
2489
2509
  customerEditsEnabled?: boolean;
2510
+ /**
2511
+ * When true (default), prospects already in the campaign owner's synced CRM
2512
+ * are skipped at add-time (exact LinkedIn/email) and flagged on name+company.
2513
+ * Set false to disable for this campaign.
2514
+ */
2515
+ excludeCrmContacts?: boolean;
2490
2516
  }
2491
2517
  type ApprovalMode = 'auto' | 'require';
2492
2518
  interface ApprovalSettings {
@@ -2622,6 +2648,8 @@ interface AddProspectsResponse {
2622
2648
  added: number;
2623
2649
  skipped: number;
2624
2650
  warnings: ProspectWarning[];
2651
+ /** Prospects hard-skipped because they exactly matched the owner's CRM ledger. */
2652
+ skippedInCrm?: number;
2625
2653
  }
2626
2654
  interface TransferProspectsRequest {
2627
2655
  /** Campaign to move the prospects into. Must belong to the same user and not be stopped/completed. */
@@ -3172,16 +3200,61 @@ declare class ContactRelationshipsResource {
3172
3200
  *
3173
3201
  * Capability notes:
3174
3202
  * - `attio` supports both email and LinkedIn-URL person search.
3175
- * - `hubspot` only supports email search; LinkedIn URLs are stored as a
3176
- * custom property on create but are not searchable through the
3177
- * reconciliation flow.
3203
+ * - `hubspot` reconciles via email and name+company; LinkedIn URLs are
3204
+ * stored on create but are not directly searchable in live CRM calls.
3205
+ * The local `crm_contacts` ledger (see contacts sync) improves match-batch
3206
+ * and search/campaign exclusion without live HubSpot lookups.
3178
3207
  */
3179
3208
  type CrmProvider = 'attio' | 'hubspot';
3209
+ /**
3210
+ * Trigger a full mirror of the owner's CRM contact book into the local
3211
+ * `crm_contacts` ledger (used for fast exclusion/matching; not a live CRM call).
3212
+ */
3213
+ interface CrmContactsSyncRequest {
3214
+ /** UUID or email of the CRM owner whose connection is synced. */
3215
+ userId: string;
3216
+ provider: CrmProvider;
3217
+ }
3218
+ interface CrmContactsSyncResponse {
3219
+ /** `started` — sync claimed; `already_in_progress` — another run holds the lock. */
3220
+ status: 'started' | 'already_in_progress';
3221
+ provider: CrmProvider;
3222
+ }
3223
+ /** Sync freshness for an owner+provider ledger mirror. */
3224
+ interface CrmContactsSyncStatusResponse {
3225
+ provider: CrmProvider;
3226
+ connected: boolean;
3227
+ syncInProgress: boolean;
3228
+ lastReconciledAt?: string | null;
3229
+ syncedCount: number;
3230
+ /** Null in v1 — LIST APIs do not return a reliable total. */
3231
+ totalInCrm?: number | null;
3232
+ }
3233
+ /**
3234
+ * Grant or revoke a member's right to exclude against an owner's CRM ledger.
3235
+ * Per-owner (all of that owner's synced CRMs inherit). Self-grant is a no-op.
3236
+ */
3237
+ interface CrmExclusionGrantRequest {
3238
+ /** Member (UUID or email) who reads the owner's exclusion ledger. */
3239
+ memberUserId: string;
3240
+ /** CRM owner (UUID or email) whose ledger is shared. */
3241
+ ownerUserId: string;
3242
+ }
3243
+ interface CrmExclusionGrantResponse {
3244
+ memberUserId: string;
3245
+ ownerUserId: string;
3246
+ status: 'granted' | 'revoked';
3247
+ }
3248
+ interface CrmExclusionGrantListResponse {
3249
+ memberUserId: string;
3250
+ ownerUserIds: string[];
3251
+ }
3180
3252
  /**
3181
3253
  * Push one Lumnis prospect to the connected CRM.
3182
3254
  *
3183
- * The prospect must already exist in a `campaign_prospects` row owned
3184
- * by `userId`; the linkedin URL is the lookup key.
3255
+ * Prefer a `campaign_prospects` row owned by `userId` when present; otherwise
3256
+ * the server enriches from profile cache / Fiber and creates the CRM record.
3257
+ * Provider-id/URN LinkedIn URLs are resolved to vanity before reconcile.
3185
3258
  */
3186
3259
  interface CrmSyncProspectRequest {
3187
3260
  /** UUID or email of the user whose CRM connection executes the call. */
@@ -3230,7 +3303,8 @@ interface CrmMatchBatchResponse {
3230
3303
  /**
3231
3304
  * Resource for the user-triggered CRM Sync API.
3232
3305
  *
3233
- * Wraps `POST /v1/crm/prospects/sync` and `POST /v1/crm/prospects/match-batch`.
3306
+ * Wraps prospect sync/match, contacts-ledger sync, and exclusion-grant routes
3307
+ * under `/v1/crm`.
3234
3308
  *
3235
3309
  * The user identified by `userId` must already have an active CRM
3236
3310
  * connection (see `client.integrations.initiateConnection`). When the
@@ -3240,8 +3314,9 @@ interface CrmMatchBatchResponse {
3240
3314
  *
3241
3315
  * Failure modes worth handling:
3242
3316
  * - `409 crm_not_connected` — user hasn't connected the provider.
3243
- * - `404 prospect_not_found` (sync only) — no `campaign_prospects` row
3244
- * matches `linkedinUrl` for this user.
3317
+ * - `404 prospect_not_found` (sync) — profile could not be identified.
3318
+ * - `422 linkedin_url_unresolved` (sync) internal member-id URL could not
3319
+ * be resolved to a public vanity URL.
3245
3320
  * - `502 crm_upstream_error` — Attio/HubSpot returned an error.
3246
3321
  * - `503 crm_upstream_rate_limited` — upstream rate-limit; the response
3247
3322
  * includes a `Retry-After` header.
@@ -3257,6 +3332,9 @@ declare class CrmResource {
3257
3332
  * `crmRecordId`. Stale links (record deleted in the CRM) are detected
3258
3333
  * and re-created automatically.
3259
3334
  *
3335
+ * Works with or without a `campaign_prospects` row — search-sourced
3336
+ * prospects are enriched from profile cache when needed.
3337
+ *
3260
3338
  * @example
3261
3339
  * ```typescript
3262
3340
  * const result = await client.crm.syncProspect({
@@ -3274,16 +3352,13 @@ declare class CrmResource {
3274
3352
  * render a "linked" indicator for the ones that come back true.
3275
3353
  *
3276
3354
  * Layered cache on the server side: persistent positive matches are
3277
- * served from the `campaign_prospects.crm_record_id` column, negative
3278
- * results are served from a Redis cache (TTL configured by
3279
- * `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`). Only the leftover unknowns
3280
- * fan out to the live CRM, bounded by
3355
+ * served from the `campaign_prospects.crm_record_id` column and the
3356
+ * local `crm_contacts` ledger; negative results are served from a Redis
3357
+ * cache (TTL configured by `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`).
3358
+ * Only the leftover unknowns fan out to the live CRM, bounded by
3281
3359
  * `CRM_MATCH_LIVE_SEARCH_PARALLELISM`.
3282
3360
  *
3283
- * Note: HubSpot does not expose a LinkedIn-URL search field through
3284
- * Composio, so for `provider: 'hubspot'` URLs that aren't already in
3285
- * the persistent cache will always come back `linked: false`. The
3286
- * sync endpoint still reconciles via email when available.
3361
+ * Provider-id/URN inputs are resolved to vanity before matching.
3287
3362
  *
3288
3363
  * @example
3289
3364
  * ```typescript
@@ -3298,6 +3373,30 @@ declare class CrmResource {
3298
3373
  * ```
3299
3374
  */
3300
3375
  matchBatch(data: CrmMatchBatchRequest): Promise<CrmMatchBatchResponse>;
3376
+ /**
3377
+ * Trigger a full mirror of the owner's CRM contact book into the local
3378
+ * `crm_contacts` ledger. Returns immediately (`202`); poll
3379
+ * {@link getContactsSyncStatus} for progress.
3380
+ */
3381
+ syncContacts(data: CrmContactsSyncRequest): Promise<CrmContactsSyncResponse>;
3382
+ /**
3383
+ * Ledger sync freshness for an owner+provider: connection state, whether a
3384
+ * sync is in progress, last reconcile time, and row count in the ledger.
3385
+ */
3386
+ getContactsSyncStatus(userId: string, provider: CrmProvider): Promise<CrmContactsSyncStatusResponse>;
3387
+ /**
3388
+ * Grant a member the right to exclude against an owner's synced CRM ledger
3389
+ * (all providers for that owner). Typically called by the FE on org join.
3390
+ */
3391
+ grantExclusionGrant(data: CrmExclusionGrantRequest): Promise<CrmExclusionGrantResponse>;
3392
+ /**
3393
+ * Revoke a member's access to an owner's CRM exclusion ledger.
3394
+ */
3395
+ revokeExclusionGrant(data: CrmExclusionGrantRequest): Promise<CrmExclusionGrantResponse>;
3396
+ /**
3397
+ * List CRM owners whose exclusion ledger a member may read (via grants).
3398
+ */
3399
+ listExclusionGrants(memberUserId: string): Promise<CrmExclusionGrantListResponse>;
3301
3400
  }
3302
3401
 
3303
3402
  /**
@@ -5881,6 +5980,9 @@ declare class ResponsesResource {
5881
5980
  * @param options - Optional search parameters
5882
5981
  * @param options.limit - Maximum number of results (1-100, default: 20)
5883
5982
  * @param options.dataSources - Specific data sources to use: ["PDL", "CORESIGNAL", "CRUST_DATA"]
5983
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true (via request `options`)
5984
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
5985
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
5884
5986
  * @returns Response with structured_response containing:
5885
5987
  * - candidates: List of person results
5886
5988
  * - totalFound: Total unique candidates found
@@ -5891,6 +5993,9 @@ declare class ResponsesResource {
5891
5993
  quickPeopleSearch(query: string, options?: {
5892
5994
  limit?: number;
5893
5995
  dataSources?: string[];
5996
+ excludeCrmContacts?: boolean;
5997
+ crmExclusionOwners?: string[];
5998
+ crmNameCompanyMatch?: boolean;
5894
5999
  }): Promise<CreateResponseResponse>;
5895
6000
  /**
5896
6001
  * Perform a deep people search with AI-generated criteria and validation
@@ -5910,6 +6015,9 @@ declare class ResponsesResource {
5910
6015
  * @param options.excludeProfiles - LinkedIn URLs to exclude from results
5911
6016
  * @param options.excludePreviouslyContacted - Exclude previously contacted people
5912
6017
  * @param options.excludeNames - Names to exclude from results
6018
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true
6019
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
6020
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
5913
6021
  * @param options.searchJobSignal - CrustData job-listing signal search (decision makers at hiring companies); true | false | 'auto'
5914
6022
  * @param options.deepVerify - Web verification for org/location/third-party criteria: 'auto' (default), 'always', or 'off'
5915
6023
  * @param options.deepValidationUseRelevanceReranker - SLM relevance reranker for surfaced candidates (ranking-only); @default true
@@ -5937,6 +6045,9 @@ declare class ResponsesResource {
5937
6045
  excludeProfiles?: string[];
5938
6046
  excludePreviouslyContacted?: boolean;
5939
6047
  excludeNames?: string[];
6048
+ excludeCrmContacts?: boolean;
6049
+ crmExclusionOwners?: string[];
6050
+ crmNameCompanyMatch?: boolean;
5940
6051
  searchProfiles?: boolean | 'auto';
5941
6052
  searchPosts?: boolean | 'auto';
5942
6053
  includeEngagementInScore?: boolean | 'auto';
@@ -7645,4 +7756,4 @@ declare class ProgressTracker {
7645
7756
  */
7646
7757
  declare function verifyWebhookSignature(payload: string, signature: string, secret: string): boolean;
7647
7758
 
7648
- export { ACTION_DELAYS, type ActionLimit, type ActiveHours, type AddAndRunCriterionRequest, type AddCriterionRequest, type AddOrgMemberRequest, type AddOrgMemberResponse, type AddPersonaRequest, type AddPersonaResponse, type AddProspectsRequest, type AddProspectsResponse, type AgentConfig, type AgentCostStats, type ApiKeyMode, type ApiKeyModeRequest, type ApiKeyModeResponse, type ApiProvider, type AppEnabledResponse, type AppliedFilters, type ApprovalActionRequest, type ApprovalItem, type ApprovalListResponse, type ApprovalMode, type ApprovalResponse, type ApprovalSettings, type ApprovalStatus, type ApprovalsParams, type ApprovalsRequestItem, type ApprovalsResponseItem, type ApproveStepRequest, type AppsListResponse, type ArtifactObject, type ArtifactsListResponse, AuthenticationError, type BaseResource, type BatchCheckConnectionRequest, type BatchCheckPriorContactRequest, type BatchCheckPriorContactResponse, type BatchConnectionRequest, type BatchConnectionResponse, type BatchConnectionStatus, type BatchConnectionStatusResponse, type BatchDraftCompleteData, type BatchDraftCreatedData, type BatchDraftErrorData, type BatchDraftJobProgress, type BatchDraftJobResponse, type BatchDraftJobStartedData, type BatchDraftJobStatusResponse, type BatchDraftProgressData, type BatchDraftRequest, type BatchDraftResponse, type BatchDraftStreamCallbacks, type BatchDraftStreamEvent, type BatchDraftStreamEventType, type BatchExecutionInclude, type BatchExecutionRequest, type BatchExecutionResponse, BatchJobStatus, type BatchPollRequest, type BatchPollResponse, type BatchProspectIdentifier, type BatchRequestItem, type BatchRequestType, type BatchResponseItem, type BatchSendRequest, type BatchSendResponse, type BatchStepMetric, type BillingStatus, type BulkApprovalAction, type BulkApprovalFailure, type BulkApprovalRequest, type BulkApprovalResponse, type BulkCompleteFailure, type BulkCompleteRequest, type BulkCompleteResponse, type BulkDeleteRequest, type BulkDeleteResponse, type BulkOperationRequest, type BulkOperationResponse, type BulkUploadResponse, CONTENT_LIMITS, CONTENT_LIMITS_MAP, type CampaignActionListResponse, type CampaignActionResponse, type CampaignActionStatus, type CampaignActionType, type CampaignBulkApprovalAction, type CampaignBulkApprovalItem, type CampaignBulkApprovalRequest, type CampaignBulkApprovalResponse, type CampaignBulkApprovalResult, type CampaignCreate, type CampaignGuardrails, type CampaignListResponse, type CampaignMetricsResponse, type CampaignOutcomeType, type CampaignProspectDetailResponse, type CampaignProspectInput, type CampaignProspectResponse, type CampaignProspectState, type CampaignResponse, type CampaignStatus, type CampaignUpdate, CampaignsResource, type CancelDraftResponse, type CancelQueuedRequest, type CancelResponseResponse, type Channel, type ChannelContactHistory, type ChannelFunnel, type ChannelRatios, ChannelType, type CheckAppEnabledParams, type CheckLinkedInConnectionRequest, type CheckPriorContactRequest, type CheckPriorContactResponse, type ChunkingStrategy, type CompetitorPostEngagementOutput, type CompetitorRepEngagementOutput, type CompleteExecutionRequest, type CompleteExecutionResponse, type ConnectInboxRequest, type ConnectInboxResponse, type Connection, type ConnectionAcceptedData, type ConnectionCallbackRequest, type ConnectionCallbackResponse, type ConnectionInfo, type ConnectionStatus, type ConnectionStatusResponse, type ConnectionSummary, type ConnectionsResponse, type ConnectionsSyncStatus, type ContactDetailsInput, type ContactEnrichPersonInput, type ContactEnrichPersonResult, type ContactEnrichRequest, type ContactEnrichResponse, type ContactFinding, type ContactHistorySyncStatus, type ContactRelationshipProvider, type ContactRelationshipResponse, type ContactRelationshipStatus, ContactRelationshipsResource, type ContactScore, type ContentLimit, type ContentSource, type ContentType, type ConversationDetail, ConversationStatus, type ConversationSummary, type CreateDraftRequest, type CreateFeedbackRequest, type CreateFeedbackResponse, type CreateResponseRequest, type CreateResponseResponse, type CreateThreadRequest, type CriteriaClassification, type CriteriaMetadata, type CriterionDefinition, type CriterionResult, type CriterionType, type CrmMatchBatchRequest, type CrmMatchBatchResponse, type CrmMatchedProspect, type CrmProvider, CrmResource, type CrmSyncProspectRequest, type CrmSyncProspectResponse, DAILY_INMAIL_LIMITS, DEFAULT_SUBSCRIPTION_TYPE, type DatabaseStatus, type DeepPeopleSearchOutput, type DeepSearchPreview, type DeepSearchStats, type DeleteApiKeyResponse, type DeleteConnectionsResponse, type DeleteConversationResponse, type DeleteConversationsByProjectResponse, type DisconnectRequest, type DisconnectResponse, type DiscoveryTrace, type DraftResponse, type DraftSendOverride, DraftStatus, type DuplicateHandling, type DuplicateTemplateRequest, type EditQueuedRequest, type Email, type EmailAction, type EmailInboxItem, type EmailInboxListResponse, type EmailInboxPersona, type EmailOnboardRequest, type EmailOnboardResponse, type EmailOnboardStatusResponse, type EmailOrgHealthResponse, type EmailOrgListResponse, type EmailOrgSettingsResponse, type EmailOrgSettingsUpdate, type EmailOrgSummary, EmailResource, type EmailSenderPersona, type EmailThreadSummary, type EngagementStatus, type EngagementStatusData, type EngagementStatusRequest, type EngagementStatusResponse, EnrichmentResource, type ErrorDetail, type ErrorResponse, type ErrorResponseItem, type EvidenceSource, type ExecutionDetailResponse, type ExecutionEvent, type ExecutionEventData, type ExecutionListResponse, type ExecutionMetricsOptions, type ExecutionMetricsResponse, type ExecutionStatus, type ExecutionSummary, type ExecutionSummaryExtended, type ExecutionsParams, type ExecutionsRequestItem, type ExecutionsResponseItem, ExternalAPIKeysResource, type ExternalApiKeyResponse, type FeedbackListResponse, type FeedbackObject, type FeedbackType, type FileAttachment, type FileChunk, type FileContentResponse, type FileListResponse, type FileMetadata, type FileScope, type FileScopeUpdateRequest, type FileSearchRequest, type FileSearchResponse, type FileSearchResult, type FileStatisticsResponse, type FileUploadResponse, FilesResource, type FilterLogic, type FilterValue, type FunnelStage, type GetConnectionStatusParams, type GetContactRelationshipsOptions, type GetToolsRequest, type GetToolsResponse, type GetUserConnectionsParams, type InboxKind, type InitiateConnectionRequest, type InitiateConnectionResponse, type InmailSubscription, IntegrationsResource, type IntentSignal, InternalServerError, LINKEDIN_LIMITS, type LifecycleOperationRequest, type LifecycleOperationResponse, type LinkAssetsRequest, type LinkedAssetsResponse, type LinkedInAccountInfoResponse, type LinkedInAccountRateLimits, type LinkedInAccountRateLimitsResponse, type LinkedInAccountRateLimitsUpdate, type LinkedInAction, type LinkedInConnectionStatus, type LinkedInCreditsResponse, type LinkedInLimitSubscriptionType, type LinkedInLimits, type LinkedInSendRequest, type LinkedInSubscriptionInfo, LinkedInSubscriptionType, type LinkedInSyncStatusResponse, type ListAcceptedConnectionsParams, type ListApprovalsOptions, type ListAssetsOptions, type ListCampaignActionsOptions, type ListCampaignProspectsOptions, type ListCampaignsOptions, type ListConnectionsParams, type ListExecutionsOptions, type ListInboxesParams, type ListPendingApprovalsOptions, type ListPlaybooksOptions, type ListProvidersResponse, type ListStepExecutionsOptions, type ListTemplatesOptions, LocalFileNotSupportedError, LumnisClient, type LumnisClientOptions, LumnisError, type LumnisErrorOptions, type MCPScope, type MCPServerCreateRequest, type MCPServerListResponse, type MCPServerResponse, type MCPServerUpdateRequest, MCPServersResource, type MCPToolListResponse, type MCPToolResponse, type MCPTransport, type MailboxUpdateRequest, type MailboxUpdateResponse, type Message, type MessageReceivedData, type MessageResponse, type MessageSentData, MessageType, MessagingAPIError, MessagingConnectionError, MessagingNotFoundError, MessagingResource, MessagingSendError, MessagingValidationError, type MetricsParams, type MetricsRequestItem, type MetricsResponseItem, type ModelAvailability, type ModelOverrides, type ModelPreferenceCreate, type ModelPreferencesBulkUpdate, ModelPreferencesResource, type ModelProvider, type ModelType, NetworkDistance, NoDataSourcesError, NotFoundError, type OnFailure, type OutcomeType, type OutreachAssetCreate, type OutreachAssetResponse, type OutreachAssetType, type OutreachAssetUpdate, OutreachMethod, OutreachResource, type OutreachSource, type OutreachStats, type PaginationInfo, type PaginationParams, type PauseResumeQueuedRequest, type PendingApprovalExtended, PeopleDataSource, PeopleResource, type PeopleSearchRequest, type PeopleSearchResponse, type PersonResult, type Plan, type PlaybookCreate, type PlaybookGenerateJobResponse, type PlaybookGenerateJobStatusResponse, type PlaybookGenerateRequest, type PlaybookResponse, type PlaybookUpdate, type PlaybookVersionResponse, type PostEngagementData, type PostEngagementProvenance, type PostEngagementType, type PostPreviewRequest, type PostPreviewResponse, type PostPreviewResult, type PostsDateRange, type PostsSearchStats, type PriorContactMessage, type ProcessingStatus, type ProcessingStatusResponse, type ProgressEntry, ProgressTracker, type ProjectApprovalsData, type ProjectExecutionsData, type ProjectMetricsData, type ProspectConnectionCheck, type ProspectInfo, type ProspectInput, type ProspectPriorContactResult, type ProspectSyncIdentifier, type ProspectSyncResult, type ProspectWarning, ProviderType, QueueItemStatus, type QuickPeopleSearchOutput, RATE_LIMIT_COOLDOWNS, type RateLimitData, RateLimitError, type RateLimitErrorOptions, type RateLimitInfo$1 as RateLimitInfo, type RateLimitStatusResponse, type RateLimitsParams, type RateLimitsRequestItem, type RateLimitsResponseItem, type RecordOutcomeRequest, type RejectActionRequest, type RejectStepRequest, type RelevanceTier, type RemoveOrgMemberResponse, type RepEngagementData, type RepEngagementStats, type ReplySentiment, type ResolvedCompetitorTarget, type ResponseArtifact, type ResponseListResponse, type ResponseObject, type ResponseStatus, ResponsesResource, SEQUENCE_RATE_LIMITS, type SalaryRange, type Scope, type SelectedSkill, type SendMessageRequest, type SendMessageResponse, type SendReplyRequest, type SendResult, type SenderPersonaInput, type SequenceAction, type SequenceApprovalNeededData, type SequenceChannel, type SequenceEventType, type SequenceExecutionCompletedData, type SequenceExecutionFailedData, type SequenceRateLimitAction, type SequenceStepCompletedData, type SequenceTemplateCreate, type SequenceTemplateResponse, type SequenceTemplateUpdate, SequencesResource, SharePermission, type SkillAnalyticsRequest, type SkillEffectivenessMetrics, type SkillGuidelineBase, type SkillGuidelineCreate, type SkillGuidelineListResponse, type SkillGuidelineResponse, type SkillGuidelineUpdate, type SkillRetrievalMetadata, type SkillUsageBase, type SkillUsageCreate, type SkillUsageListResponse, type SkillUsageResponse, type SkillUsageUpdate, SkillsResource, type SkipActionRequest, type SkipStepRequest, type SkipStepResponse, type SkippedProspect, type SkippedTransferProspect, SourcesNotAvailableError, type SpecializedAgentParams, type SpecializedAgentType, type Stage, type StageFilter, type StartExecutionRequest, type StartExecutionResponse, type StepConfig, type StepExecutionItem, type StepExecutionListResponse, type StepExecutionStatus, type StepHistoryEntry, type StepMetric, type StoppedBreakdown, type StoreApiKeyRequest, type StructuredResponse, type SyncJobResponse, SyncJobStatus, SyncPhaseStatus, type SyncProspectRequest, type SyncProspectResponse, type SyncRequest, type SyncStats, type TeardownOrgResponse, type TemplateShareConfig, type TemplateShareInfo, type TemplateShareRequest, type TemplateSharesResponse, type TenantDetailsResponse, TenantInfoResource, type TenantModelPreference, type TenantModelPreferencesResponse, type TestConnectionResponse, type ThreadListResponse, type ThreadObject, type ThreadResponsesParams, ThreadsResource, type ToolInfo, type TransferProspectsRequest, type TransferProspectsResponse, type TransferSkipReason, type TransitionCondition, type TransitionConditionOperator, type TransitionConditionType, type TransitionConfig, type TransitionEventParams, type TriggerSyncResponse, UNIPILE_RATE_LIMIT_ERRORS, UNIPILE_SAFE_LIMITS, type UUID, type UnlinkConversationsResponse, type UpdateAppStatusParams, type UpdateAppStatusResponse, type UpdateDraftRequest, type UpdateLinkedInSubscriptionRequest, type UpdatePersonaRequest, type UpdatePersonaResponse, type UpdateStepExecutionRequest, type UpdateStepExecutionResponse, type UpdateThreadRequest, type UserConnectionsResponse, type UserCreateRequest, type UserDeleteResponse, type UserIdentifier, type UserListResponse, type UserResponse, type UserUpdateRequest, UsersResource, VALID_EVENT_TYPES, type ValidatedCandidate, ValidationError, type ValidationIssue, type ValidationResponse, type WebhookEvent, type WebhookPayload, canSendInmail, displayProgress, formatProgressEntry, getBestSubscriptionForAction, getConnectionRequestLimit, getContentLimit, getDailyInmailLimit, getDefaultDailyLimits, getInmailAllowance, getLimits, getMessageLimit, getRateLimit, hasOpenProfileMessages, isRecruiterSubscription, normalizeAction, verifyWebhookSignature };
7759
+ export { ACTION_DELAYS, type ActionLimit, type ActiveHours, type AddAndRunCriterionRequest, type AddCriterionRequest, type AddOrgMemberRequest, type AddOrgMemberResponse, type AddPersonaRequest, type AddPersonaResponse, type AddProspectsRequest, type AddProspectsResponse, type AgentConfig, type AgentCostStats, type ApiKeyMode, type ApiKeyModeRequest, type ApiKeyModeResponse, type ApiProvider, type AppEnabledResponse, type AppliedFilters, type ApprovalActionRequest, type ApprovalItem, type ApprovalListResponse, type ApprovalMode, type ApprovalResponse, type ApprovalSettings, type ApprovalStatus, type ApprovalsParams, type ApprovalsRequestItem, type ApprovalsResponseItem, type ApproveStepRequest, type AppsListResponse, type ArtifactObject, type ArtifactsListResponse, AuthenticationError, type BaseResource, type BatchCheckConnectionRequest, type BatchCheckPriorContactRequest, type BatchCheckPriorContactResponse, type BatchConnectionRequest, type BatchConnectionResponse, type BatchConnectionStatus, type BatchConnectionStatusResponse, type BatchDraftCompleteData, type BatchDraftCreatedData, type BatchDraftErrorData, type BatchDraftJobProgress, type BatchDraftJobResponse, type BatchDraftJobStartedData, type BatchDraftJobStatusResponse, type BatchDraftProgressData, type BatchDraftRequest, type BatchDraftResponse, type BatchDraftStreamCallbacks, type BatchDraftStreamEvent, type BatchDraftStreamEventType, type BatchExecutionInclude, type BatchExecutionRequest, type BatchExecutionResponse, BatchJobStatus, type BatchPollRequest, type BatchPollResponse, type BatchProspectIdentifier, type BatchRequestItem, type BatchRequestType, type BatchResponseItem, type BatchSendRequest, type BatchSendResponse, type BatchStepMetric, type BillingStatus, type BulkApprovalAction, type BulkApprovalFailure, type BulkApprovalRequest, type BulkApprovalResponse, type BulkCompleteFailure, type BulkCompleteRequest, type BulkCompleteResponse, type BulkDeleteRequest, type BulkDeleteResponse, type BulkOperationRequest, type BulkOperationResponse, type BulkUploadResponse, CONTENT_LIMITS, CONTENT_LIMITS_MAP, type CampaignActionListResponse, type CampaignActionResponse, type CampaignActionStatus, type CampaignActionType, type CampaignBulkApprovalAction, type CampaignBulkApprovalItem, type CampaignBulkApprovalRequest, type CampaignBulkApprovalResponse, type CampaignBulkApprovalResult, type CampaignCreate, type CampaignGuardrails, type CampaignListResponse, type CampaignMetricsResponse, type CampaignOutcomeType, type CampaignProspectDetailResponse, type CampaignProspectInput, type CampaignProspectResponse, type CampaignProspectState, type CampaignResponse, type CampaignStatus, type CampaignUpdate, CampaignsResource, type CancelDraftResponse, type CancelQueuedRequest, type CancelResponseResponse, type Channel, type ChannelContactHistory, type ChannelFunnel, type ChannelRatios, ChannelType, type CheckAppEnabledParams, type CheckLinkedInConnectionRequest, type CheckPriorContactRequest, type CheckPriorContactResponse, type ChunkingStrategy, type CompetitorPostEngagementOutput, type CompetitorRepEngagementOutput, type CompleteExecutionRequest, type CompleteExecutionResponse, type ConnectInboxRequest, type ConnectInboxResponse, type Connection, type ConnectionAcceptedData, type ConnectionCallbackRequest, type ConnectionCallbackResponse, type ConnectionInfo, type ConnectionStatus, type ConnectionStatusResponse, type ConnectionSummary, type ConnectionsResponse, type ConnectionsSyncStatus, type ContactDetailsInput, type ContactEnrichPersonInput, type ContactEnrichPersonResult, type ContactEnrichRequest, type ContactEnrichResponse, type ContactFinding, type ContactHistorySyncStatus, type ContactRelationshipProvider, type ContactRelationshipResponse, type ContactRelationshipStatus, ContactRelationshipsResource, type ContactScore, type ContentLimit, type ContentSource, type ContentType, type ConversationDetail, ConversationStatus, type ConversationSummary, type CreateDraftRequest, type CreateFeedbackRequest, type CreateFeedbackResponse, type CreateResponseRequest, type CreateResponseResponse, type CreateThreadRequest, type CriteriaClassification, type CriteriaMetadata, type CriterionDefinition, type CriterionResult, type CriterionType, type CrmContactsSyncRequest, type CrmContactsSyncResponse, type CrmContactsSyncStatusResponse, type CrmExclusionGrantListResponse, type CrmExclusionGrantRequest, type CrmExclusionGrantResponse, type CrmMatchBatchRequest, type CrmMatchBatchResponse, type CrmMatchedProspect, type CrmProvider, CrmResource, type CrmSyncProspectRequest, type CrmSyncProspectResponse, DAILY_INMAIL_LIMITS, DEFAULT_SUBSCRIPTION_TYPE, type DatabaseStatus, type DeepPeopleSearchOutput, type DeepSearchPreview, type DeepSearchStats, type DeleteApiKeyResponse, type DeleteConnectionsResponse, type DeleteConversationResponse, type DeleteConversationsByProjectResponse, type DisconnectRequest, type DisconnectResponse, type DiscoveryTrace, type DraftResponse, type DraftSendOverride, DraftStatus, type DuplicateHandling, type DuplicateTemplateRequest, type EditQueuedRequest, type Email, type EmailAction, type EmailInboxItem, type EmailInboxListResponse, type EmailInboxPersona, type EmailOnboardRequest, type EmailOnboardResponse, type EmailOnboardStatusResponse, type EmailOrgHealthResponse, type EmailOrgListResponse, type EmailOrgSettingsResponse, type EmailOrgSettingsUpdate, type EmailOrgSummary, EmailResource, type EmailSenderPersona, type EmailThreadSummary, type EngagementStatus, type EngagementStatusData, type EngagementStatusRequest, type EngagementStatusResponse, EnrichmentResource, type ErrorDetail, type ErrorResponse, type ErrorResponseItem, type EvidenceSource, type ExecutionDetailResponse, type ExecutionEvent, type ExecutionEventData, type ExecutionListResponse, type ExecutionMetricsOptions, type ExecutionMetricsResponse, type ExecutionStatus, type ExecutionSummary, type ExecutionSummaryExtended, type ExecutionsParams, type ExecutionsRequestItem, type ExecutionsResponseItem, ExternalAPIKeysResource, type ExternalApiKeyResponse, type FeedbackListResponse, type FeedbackObject, type FeedbackType, type FileAttachment, type FileChunk, type FileContentResponse, type FileListResponse, type FileMetadata, type FileScope, type FileScopeUpdateRequest, type FileSearchRequest, type FileSearchResponse, type FileSearchResult, type FileStatisticsResponse, type FileUploadResponse, FilesResource, type FilterLogic, type FilterValue, type FunnelStage, type GetConnectionStatusParams, type GetContactRelationshipsOptions, type GetToolsRequest, type GetToolsResponse, type GetUserConnectionsParams, type InboxKind, type InitiateConnectionRequest, type InitiateConnectionResponse, type InmailSubscription, IntegrationsResource, type IntentSignal, InternalServerError, LINKEDIN_LIMITS, type LifecycleOperationRequest, type LifecycleOperationResponse, type LinkAssetsRequest, type LinkedAssetsResponse, type LinkedInAccountInfoResponse, type LinkedInAccountRateLimits, type LinkedInAccountRateLimitsResponse, type LinkedInAccountRateLimitsUpdate, type LinkedInAction, type LinkedInConnectionStatus, type LinkedInCreditsResponse, type LinkedInLimitSubscriptionType, type LinkedInLimits, type LinkedInSendRequest, type LinkedInSubscriptionInfo, LinkedInSubscriptionType, type LinkedInSyncStatusResponse, type ListAcceptedConnectionsParams, type ListApprovalsOptions, type ListAssetsOptions, type ListCampaignActionsOptions, type ListCampaignProspectsOptions, type ListCampaignsOptions, type ListConnectionsParams, type ListExecutionsOptions, type ListInboxesParams, type ListPendingApprovalsOptions, type ListPlaybooksOptions, type ListProvidersResponse, type ListStepExecutionsOptions, type ListTemplatesOptions, LocalFileNotSupportedError, LumnisClient, type LumnisClientOptions, LumnisError, type LumnisErrorOptions, type MCPScope, type MCPServerCreateRequest, type MCPServerListResponse, type MCPServerResponse, type MCPServerUpdateRequest, MCPServersResource, type MCPToolListResponse, type MCPToolResponse, type MCPTransport, type MailboxUpdateRequest, type MailboxUpdateResponse, type Message, type MessageReceivedData, type MessageResponse, type MessageSentData, MessageType, MessagingAPIError, MessagingConnectionError, MessagingNotFoundError, MessagingResource, MessagingSendError, MessagingValidationError, type MetricsParams, type MetricsRequestItem, type MetricsResponseItem, type ModelAvailability, type ModelOverrides, type ModelPreferenceCreate, type ModelPreferencesBulkUpdate, ModelPreferencesResource, type ModelProvider, type ModelType, NetworkDistance, NoDataSourcesError, NotFoundError, type OnFailure, type OutcomeType, type OutreachAssetCreate, type OutreachAssetResponse, type OutreachAssetType, type OutreachAssetUpdate, OutreachMethod, OutreachResource, type OutreachSource, type OutreachStats, type PaginationInfo, type PaginationParams, type PauseResumeQueuedRequest, type PendingApprovalExtended, PeopleDataSource, PeopleResource, type PeopleSearchRequest, type PeopleSearchResponse, type PersonResult, type Plan, type PlaybookCreate, type PlaybookGenerateJobResponse, type PlaybookGenerateJobStatusResponse, type PlaybookGenerateRequest, type PlaybookResponse, type PlaybookUpdate, type PlaybookVersionResponse, type PostEngagementData, type PostEngagementProvenance, type PostEngagementType, type PostPreviewRequest, type PostPreviewResponse, type PostPreviewResult, type PostsDateRange, type PostsSearchStats, type PriorContactMessage, type ProcessingStatus, type ProcessingStatusResponse, type ProgressEntry, ProgressTracker, type ProjectApprovalsData, type ProjectExecutionsData, type ProjectMetricsData, type ProspectConnectionCheck, type ProspectInfo, type ProspectInput, type ProspectPriorContactResult, type ProspectSyncIdentifier, type ProspectSyncResult, type ProspectWarning, ProviderType, QueueItemStatus, type QuickPeopleSearchOutput, RATE_LIMIT_COOLDOWNS, type RateLimitData, RateLimitError, type RateLimitErrorOptions, type RateLimitInfo$1 as RateLimitInfo, type RateLimitStatusResponse, type RateLimitsParams, type RateLimitsRequestItem, type RateLimitsResponseItem, type RecordOutcomeRequest, type RejectActionRequest, type RejectStepRequest, type RelevanceTier, type RemoveOrgMemberResponse, type RepEngagementData, type RepEngagementStats, type ReplySentiment, type ResolvedCompetitorTarget, type ResponseArtifact, type ResponseListResponse, type ResponseObject, type ResponseStatus, ResponsesResource, SEQUENCE_RATE_LIMITS, type SalaryRange, type Scope, type SelectedSkill, type SendMessageRequest, type SendMessageResponse, type SendReplyRequest, type SendResult, type SenderPersonaInput, type SequenceAction, type SequenceApprovalNeededData, type SequenceChannel, type SequenceEventType, type SequenceExecutionCompletedData, type SequenceExecutionFailedData, type SequenceRateLimitAction, type SequenceStepCompletedData, type SequenceTemplateCreate, type SequenceTemplateResponse, type SequenceTemplateUpdate, SequencesResource, SharePermission, type SkillAnalyticsRequest, type SkillEffectivenessMetrics, type SkillGuidelineBase, type SkillGuidelineCreate, type SkillGuidelineListResponse, type SkillGuidelineResponse, type SkillGuidelineUpdate, type SkillRetrievalMetadata, type SkillUsageBase, type SkillUsageCreate, type SkillUsageListResponse, type SkillUsageResponse, type SkillUsageUpdate, SkillsResource, type SkipActionRequest, type SkipStepRequest, type SkipStepResponse, type SkippedProspect, type SkippedTransferProspect, SourcesNotAvailableError, type SpecializedAgentParams, type SpecializedAgentType, type Stage, type StageFilter, type StartExecutionRequest, type StartExecutionResponse, type StepConfig, type StepExecutionItem, type StepExecutionListResponse, type StepExecutionStatus, type StepHistoryEntry, type StepMetric, type StoppedBreakdown, type StoreApiKeyRequest, type StructuredResponse, type SyncJobResponse, SyncJobStatus, SyncPhaseStatus, type SyncProspectRequest, type SyncProspectResponse, type SyncRequest, type SyncStats, type TeardownOrgResponse, type TemplateShareConfig, type TemplateShareInfo, type TemplateShareRequest, type TemplateSharesResponse, type TenantDetailsResponse, TenantInfoResource, type TenantModelPreference, type TenantModelPreferencesResponse, type TestConnectionResponse, type ThreadListResponse, type ThreadObject, type ThreadResponsesParams, ThreadsResource, type ToolInfo, type TransferProspectsRequest, type TransferProspectsResponse, type TransferSkipReason, type TransitionCondition, type TransitionConditionOperator, type TransitionConditionType, type TransitionConfig, type TransitionEventParams, type TriggerSyncResponse, UNIPILE_RATE_LIMIT_ERRORS, UNIPILE_SAFE_LIMITS, type UUID, type UnlinkConversationsResponse, type UpdateAppStatusParams, type UpdateAppStatusResponse, type UpdateDraftRequest, type UpdateLinkedInSubscriptionRequest, type UpdatePersonaRequest, type UpdatePersonaResponse, type UpdateStepExecutionRequest, type UpdateStepExecutionResponse, type UpdateThreadRequest, type UserConnectionsResponse, type UserCreateRequest, type UserDeleteResponse, type UserIdentifier, type UserListResponse, type UserResponse, type UserUpdateRequest, UsersResource, VALID_EVENT_TYPES, type ValidatedCandidate, ValidationError, type ValidationIssue, type ValidationResponse, type WebhookEvent, type WebhookPayload, canSendInmail, displayProgress, formatProgressEntry, getBestSubscriptionForAction, getConnectionRequestLimit, getContentLimit, getDailyInmailLimit, getDefaultDailyLimits, getInmailAllowance, getLimits, getMessageLimit, getRateLimit, hasOpenProfileMessages, isRecruiterSubscription, normalizeAction, verifyWebhookSignature };
package/dist/index.d.mts CHANGED
@@ -1742,6 +1742,26 @@ interface SpecializedAgentParams {
1742
1742
  * Names to exclude from results (passed through to CrustData post-processing when supported).
1743
1743
  */
1744
1744
  excludeNames?: string[];
1745
+ /**
1746
+ * Exclude people already in the acting user's synced CRM (`crm_contacts` ledger;
1747
+ * local lookup only, never a live CRM call). Matches on exact LinkedIn URL and
1748
+ * email; optionally name+company when `crmNameCompanyMatch` is true.
1749
+ * @default true
1750
+ * Used by deep_people_search (via `specializedAgentParams`) and quick_people_search
1751
+ * (via top-level `options` on the create request).
1752
+ */
1753
+ excludeCrmContacts?: boolean;
1754
+ /**
1755
+ * Narrow CRM exclusion to specific granted owners' ledgers (user id or email).
1756
+ * Omitted = the acting user's own CRM only. Ungranted entries are ignored.
1757
+ */
1758
+ crmExclusionOwners?: string[];
1759
+ /**
1760
+ * Within CRM exclusion, also drop candidates matching by exact name + company
1761
+ * (catches CRM contacts with no LinkedIn URL, especially HubSpot).
1762
+ * @default true
1763
+ */
1764
+ crmNameCompanyMatch?: boolean;
1745
1765
  /**
1746
1766
  * Response ID to reuse criteria from.
1747
1767
  */
@@ -2487,6 +2507,12 @@ interface CampaignGuardrails {
2487
2507
  * as a kill-switch.
2488
2508
  */
2489
2509
  customerEditsEnabled?: boolean;
2510
+ /**
2511
+ * When true (default), prospects already in the campaign owner's synced CRM
2512
+ * are skipped at add-time (exact LinkedIn/email) and flagged on name+company.
2513
+ * Set false to disable for this campaign.
2514
+ */
2515
+ excludeCrmContacts?: boolean;
2490
2516
  }
2491
2517
  type ApprovalMode = 'auto' | 'require';
2492
2518
  interface ApprovalSettings {
@@ -2622,6 +2648,8 @@ interface AddProspectsResponse {
2622
2648
  added: number;
2623
2649
  skipped: number;
2624
2650
  warnings: ProspectWarning[];
2651
+ /** Prospects hard-skipped because they exactly matched the owner's CRM ledger. */
2652
+ skippedInCrm?: number;
2625
2653
  }
2626
2654
  interface TransferProspectsRequest {
2627
2655
  /** Campaign to move the prospects into. Must belong to the same user and not be stopped/completed. */
@@ -3172,16 +3200,61 @@ declare class ContactRelationshipsResource {
3172
3200
  *
3173
3201
  * Capability notes:
3174
3202
  * - `attio` supports both email and LinkedIn-URL person search.
3175
- * - `hubspot` only supports email search; LinkedIn URLs are stored as a
3176
- * custom property on create but are not searchable through the
3177
- * reconciliation flow.
3203
+ * - `hubspot` reconciles via email and name+company; LinkedIn URLs are
3204
+ * stored on create but are not directly searchable in live CRM calls.
3205
+ * The local `crm_contacts` ledger (see contacts sync) improves match-batch
3206
+ * and search/campaign exclusion without live HubSpot lookups.
3178
3207
  */
3179
3208
  type CrmProvider = 'attio' | 'hubspot';
3209
+ /**
3210
+ * Trigger a full mirror of the owner's CRM contact book into the local
3211
+ * `crm_contacts` ledger (used for fast exclusion/matching; not a live CRM call).
3212
+ */
3213
+ interface CrmContactsSyncRequest {
3214
+ /** UUID or email of the CRM owner whose connection is synced. */
3215
+ userId: string;
3216
+ provider: CrmProvider;
3217
+ }
3218
+ interface CrmContactsSyncResponse {
3219
+ /** `started` — sync claimed; `already_in_progress` — another run holds the lock. */
3220
+ status: 'started' | 'already_in_progress';
3221
+ provider: CrmProvider;
3222
+ }
3223
+ /** Sync freshness for an owner+provider ledger mirror. */
3224
+ interface CrmContactsSyncStatusResponse {
3225
+ provider: CrmProvider;
3226
+ connected: boolean;
3227
+ syncInProgress: boolean;
3228
+ lastReconciledAt?: string | null;
3229
+ syncedCount: number;
3230
+ /** Null in v1 — LIST APIs do not return a reliable total. */
3231
+ totalInCrm?: number | null;
3232
+ }
3233
+ /**
3234
+ * Grant or revoke a member's right to exclude against an owner's CRM ledger.
3235
+ * Per-owner (all of that owner's synced CRMs inherit). Self-grant is a no-op.
3236
+ */
3237
+ interface CrmExclusionGrantRequest {
3238
+ /** Member (UUID or email) who reads the owner's exclusion ledger. */
3239
+ memberUserId: string;
3240
+ /** CRM owner (UUID or email) whose ledger is shared. */
3241
+ ownerUserId: string;
3242
+ }
3243
+ interface CrmExclusionGrantResponse {
3244
+ memberUserId: string;
3245
+ ownerUserId: string;
3246
+ status: 'granted' | 'revoked';
3247
+ }
3248
+ interface CrmExclusionGrantListResponse {
3249
+ memberUserId: string;
3250
+ ownerUserIds: string[];
3251
+ }
3180
3252
  /**
3181
3253
  * Push one Lumnis prospect to the connected CRM.
3182
3254
  *
3183
- * The prospect must already exist in a `campaign_prospects` row owned
3184
- * by `userId`; the linkedin URL is the lookup key.
3255
+ * Prefer a `campaign_prospects` row owned by `userId` when present; otherwise
3256
+ * the server enriches from profile cache / Fiber and creates the CRM record.
3257
+ * Provider-id/URN LinkedIn URLs are resolved to vanity before reconcile.
3185
3258
  */
3186
3259
  interface CrmSyncProspectRequest {
3187
3260
  /** UUID or email of the user whose CRM connection executes the call. */
@@ -3230,7 +3303,8 @@ interface CrmMatchBatchResponse {
3230
3303
  /**
3231
3304
  * Resource for the user-triggered CRM Sync API.
3232
3305
  *
3233
- * Wraps `POST /v1/crm/prospects/sync` and `POST /v1/crm/prospects/match-batch`.
3306
+ * Wraps prospect sync/match, contacts-ledger sync, and exclusion-grant routes
3307
+ * under `/v1/crm`.
3234
3308
  *
3235
3309
  * The user identified by `userId` must already have an active CRM
3236
3310
  * connection (see `client.integrations.initiateConnection`). When the
@@ -3240,8 +3314,9 @@ interface CrmMatchBatchResponse {
3240
3314
  *
3241
3315
  * Failure modes worth handling:
3242
3316
  * - `409 crm_not_connected` — user hasn't connected the provider.
3243
- * - `404 prospect_not_found` (sync only) — no `campaign_prospects` row
3244
- * matches `linkedinUrl` for this user.
3317
+ * - `404 prospect_not_found` (sync) — profile could not be identified.
3318
+ * - `422 linkedin_url_unresolved` (sync) internal member-id URL could not
3319
+ * be resolved to a public vanity URL.
3245
3320
  * - `502 crm_upstream_error` — Attio/HubSpot returned an error.
3246
3321
  * - `503 crm_upstream_rate_limited` — upstream rate-limit; the response
3247
3322
  * includes a `Retry-After` header.
@@ -3257,6 +3332,9 @@ declare class CrmResource {
3257
3332
  * `crmRecordId`. Stale links (record deleted in the CRM) are detected
3258
3333
  * and re-created automatically.
3259
3334
  *
3335
+ * Works with or without a `campaign_prospects` row — search-sourced
3336
+ * prospects are enriched from profile cache when needed.
3337
+ *
3260
3338
  * @example
3261
3339
  * ```typescript
3262
3340
  * const result = await client.crm.syncProspect({
@@ -3274,16 +3352,13 @@ declare class CrmResource {
3274
3352
  * render a "linked" indicator for the ones that come back true.
3275
3353
  *
3276
3354
  * Layered cache on the server side: persistent positive matches are
3277
- * served from the `campaign_prospects.crm_record_id` column, negative
3278
- * results are served from a Redis cache (TTL configured by
3279
- * `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`). Only the leftover unknowns
3280
- * fan out to the live CRM, bounded by
3355
+ * served from the `campaign_prospects.crm_record_id` column and the
3356
+ * local `crm_contacts` ledger; negative results are served from a Redis
3357
+ * cache (TTL configured by `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`).
3358
+ * Only the leftover unknowns fan out to the live CRM, bounded by
3281
3359
  * `CRM_MATCH_LIVE_SEARCH_PARALLELISM`.
3282
3360
  *
3283
- * Note: HubSpot does not expose a LinkedIn-URL search field through
3284
- * Composio, so for `provider: 'hubspot'` URLs that aren't already in
3285
- * the persistent cache will always come back `linked: false`. The
3286
- * sync endpoint still reconciles via email when available.
3361
+ * Provider-id/URN inputs are resolved to vanity before matching.
3287
3362
  *
3288
3363
  * @example
3289
3364
  * ```typescript
@@ -3298,6 +3373,30 @@ declare class CrmResource {
3298
3373
  * ```
3299
3374
  */
3300
3375
  matchBatch(data: CrmMatchBatchRequest): Promise<CrmMatchBatchResponse>;
3376
+ /**
3377
+ * Trigger a full mirror of the owner's CRM contact book into the local
3378
+ * `crm_contacts` ledger. Returns immediately (`202`); poll
3379
+ * {@link getContactsSyncStatus} for progress.
3380
+ */
3381
+ syncContacts(data: CrmContactsSyncRequest): Promise<CrmContactsSyncResponse>;
3382
+ /**
3383
+ * Ledger sync freshness for an owner+provider: connection state, whether a
3384
+ * sync is in progress, last reconcile time, and row count in the ledger.
3385
+ */
3386
+ getContactsSyncStatus(userId: string, provider: CrmProvider): Promise<CrmContactsSyncStatusResponse>;
3387
+ /**
3388
+ * Grant a member the right to exclude against an owner's synced CRM ledger
3389
+ * (all providers for that owner). Typically called by the FE on org join.
3390
+ */
3391
+ grantExclusionGrant(data: CrmExclusionGrantRequest): Promise<CrmExclusionGrantResponse>;
3392
+ /**
3393
+ * Revoke a member's access to an owner's CRM exclusion ledger.
3394
+ */
3395
+ revokeExclusionGrant(data: CrmExclusionGrantRequest): Promise<CrmExclusionGrantResponse>;
3396
+ /**
3397
+ * List CRM owners whose exclusion ledger a member may read (via grants).
3398
+ */
3399
+ listExclusionGrants(memberUserId: string): Promise<CrmExclusionGrantListResponse>;
3301
3400
  }
3302
3401
 
3303
3402
  /**
@@ -5881,6 +5980,9 @@ declare class ResponsesResource {
5881
5980
  * @param options - Optional search parameters
5882
5981
  * @param options.limit - Maximum number of results (1-100, default: 20)
5883
5982
  * @param options.dataSources - Specific data sources to use: ["PDL", "CORESIGNAL", "CRUST_DATA"]
5983
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true (via request `options`)
5984
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
5985
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
5884
5986
  * @returns Response with structured_response containing:
5885
5987
  * - candidates: List of person results
5886
5988
  * - totalFound: Total unique candidates found
@@ -5891,6 +5993,9 @@ declare class ResponsesResource {
5891
5993
  quickPeopleSearch(query: string, options?: {
5892
5994
  limit?: number;
5893
5995
  dataSources?: string[];
5996
+ excludeCrmContacts?: boolean;
5997
+ crmExclusionOwners?: string[];
5998
+ crmNameCompanyMatch?: boolean;
5894
5999
  }): Promise<CreateResponseResponse>;
5895
6000
  /**
5896
6001
  * Perform a deep people search with AI-generated criteria and validation
@@ -5910,6 +6015,9 @@ declare class ResponsesResource {
5910
6015
  * @param options.excludeProfiles - LinkedIn URLs to exclude from results
5911
6016
  * @param options.excludePreviouslyContacted - Exclude previously contacted people
5912
6017
  * @param options.excludeNames - Names to exclude from results
6018
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true
6019
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
6020
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
5913
6021
  * @param options.searchJobSignal - CrustData job-listing signal search (decision makers at hiring companies); true | false | 'auto'
5914
6022
  * @param options.deepVerify - Web verification for org/location/third-party criteria: 'auto' (default), 'always', or 'off'
5915
6023
  * @param options.deepValidationUseRelevanceReranker - SLM relevance reranker for surfaced candidates (ranking-only); @default true
@@ -5937,6 +6045,9 @@ declare class ResponsesResource {
5937
6045
  excludeProfiles?: string[];
5938
6046
  excludePreviouslyContacted?: boolean;
5939
6047
  excludeNames?: string[];
6048
+ excludeCrmContacts?: boolean;
6049
+ crmExclusionOwners?: string[];
6050
+ crmNameCompanyMatch?: boolean;
5940
6051
  searchProfiles?: boolean | 'auto';
5941
6052
  searchPosts?: boolean | 'auto';
5942
6053
  includeEngagementInScore?: boolean | 'auto';
@@ -7645,4 +7756,4 @@ declare class ProgressTracker {
7645
7756
  */
7646
7757
  declare function verifyWebhookSignature(payload: string, signature: string, secret: string): boolean;
7647
7758
 
7648
- export { ACTION_DELAYS, type ActionLimit, type ActiveHours, type AddAndRunCriterionRequest, type AddCriterionRequest, type AddOrgMemberRequest, type AddOrgMemberResponse, type AddPersonaRequest, type AddPersonaResponse, type AddProspectsRequest, type AddProspectsResponse, type AgentConfig, type AgentCostStats, type ApiKeyMode, type ApiKeyModeRequest, type ApiKeyModeResponse, type ApiProvider, type AppEnabledResponse, type AppliedFilters, type ApprovalActionRequest, type ApprovalItem, type ApprovalListResponse, type ApprovalMode, type ApprovalResponse, type ApprovalSettings, type ApprovalStatus, type ApprovalsParams, type ApprovalsRequestItem, type ApprovalsResponseItem, type ApproveStepRequest, type AppsListResponse, type ArtifactObject, type ArtifactsListResponse, AuthenticationError, type BaseResource, type BatchCheckConnectionRequest, type BatchCheckPriorContactRequest, type BatchCheckPriorContactResponse, type BatchConnectionRequest, type BatchConnectionResponse, type BatchConnectionStatus, type BatchConnectionStatusResponse, type BatchDraftCompleteData, type BatchDraftCreatedData, type BatchDraftErrorData, type BatchDraftJobProgress, type BatchDraftJobResponse, type BatchDraftJobStartedData, type BatchDraftJobStatusResponse, type BatchDraftProgressData, type BatchDraftRequest, type BatchDraftResponse, type BatchDraftStreamCallbacks, type BatchDraftStreamEvent, type BatchDraftStreamEventType, type BatchExecutionInclude, type BatchExecutionRequest, type BatchExecutionResponse, BatchJobStatus, type BatchPollRequest, type BatchPollResponse, type BatchProspectIdentifier, type BatchRequestItem, type BatchRequestType, type BatchResponseItem, type BatchSendRequest, type BatchSendResponse, type BatchStepMetric, type BillingStatus, type BulkApprovalAction, type BulkApprovalFailure, type BulkApprovalRequest, type BulkApprovalResponse, type BulkCompleteFailure, type BulkCompleteRequest, type BulkCompleteResponse, type BulkDeleteRequest, type BulkDeleteResponse, type BulkOperationRequest, type BulkOperationResponse, type BulkUploadResponse, CONTENT_LIMITS, CONTENT_LIMITS_MAP, type CampaignActionListResponse, type CampaignActionResponse, type CampaignActionStatus, type CampaignActionType, type CampaignBulkApprovalAction, type CampaignBulkApprovalItem, type CampaignBulkApprovalRequest, type CampaignBulkApprovalResponse, type CampaignBulkApprovalResult, type CampaignCreate, type CampaignGuardrails, type CampaignListResponse, type CampaignMetricsResponse, type CampaignOutcomeType, type CampaignProspectDetailResponse, type CampaignProspectInput, type CampaignProspectResponse, type CampaignProspectState, type CampaignResponse, type CampaignStatus, type CampaignUpdate, CampaignsResource, type CancelDraftResponse, type CancelQueuedRequest, type CancelResponseResponse, type Channel, type ChannelContactHistory, type ChannelFunnel, type ChannelRatios, ChannelType, type CheckAppEnabledParams, type CheckLinkedInConnectionRequest, type CheckPriorContactRequest, type CheckPriorContactResponse, type ChunkingStrategy, type CompetitorPostEngagementOutput, type CompetitorRepEngagementOutput, type CompleteExecutionRequest, type CompleteExecutionResponse, type ConnectInboxRequest, type ConnectInboxResponse, type Connection, type ConnectionAcceptedData, type ConnectionCallbackRequest, type ConnectionCallbackResponse, type ConnectionInfo, type ConnectionStatus, type ConnectionStatusResponse, type ConnectionSummary, type ConnectionsResponse, type ConnectionsSyncStatus, type ContactDetailsInput, type ContactEnrichPersonInput, type ContactEnrichPersonResult, type ContactEnrichRequest, type ContactEnrichResponse, type ContactFinding, type ContactHistorySyncStatus, type ContactRelationshipProvider, type ContactRelationshipResponse, type ContactRelationshipStatus, ContactRelationshipsResource, type ContactScore, type ContentLimit, type ContentSource, type ContentType, type ConversationDetail, ConversationStatus, type ConversationSummary, type CreateDraftRequest, type CreateFeedbackRequest, type CreateFeedbackResponse, type CreateResponseRequest, type CreateResponseResponse, type CreateThreadRequest, type CriteriaClassification, type CriteriaMetadata, type CriterionDefinition, type CriterionResult, type CriterionType, type CrmMatchBatchRequest, type CrmMatchBatchResponse, type CrmMatchedProspect, type CrmProvider, CrmResource, type CrmSyncProspectRequest, type CrmSyncProspectResponse, DAILY_INMAIL_LIMITS, DEFAULT_SUBSCRIPTION_TYPE, type DatabaseStatus, type DeepPeopleSearchOutput, type DeepSearchPreview, type DeepSearchStats, type DeleteApiKeyResponse, type DeleteConnectionsResponse, type DeleteConversationResponse, type DeleteConversationsByProjectResponse, type DisconnectRequest, type DisconnectResponse, type DiscoveryTrace, type DraftResponse, type DraftSendOverride, DraftStatus, type DuplicateHandling, type DuplicateTemplateRequest, type EditQueuedRequest, type Email, type EmailAction, type EmailInboxItem, type EmailInboxListResponse, type EmailInboxPersona, type EmailOnboardRequest, type EmailOnboardResponse, type EmailOnboardStatusResponse, type EmailOrgHealthResponse, type EmailOrgListResponse, type EmailOrgSettingsResponse, type EmailOrgSettingsUpdate, type EmailOrgSummary, EmailResource, type EmailSenderPersona, type EmailThreadSummary, type EngagementStatus, type EngagementStatusData, type EngagementStatusRequest, type EngagementStatusResponse, EnrichmentResource, type ErrorDetail, type ErrorResponse, type ErrorResponseItem, type EvidenceSource, type ExecutionDetailResponse, type ExecutionEvent, type ExecutionEventData, type ExecutionListResponse, type ExecutionMetricsOptions, type ExecutionMetricsResponse, type ExecutionStatus, type ExecutionSummary, type ExecutionSummaryExtended, type ExecutionsParams, type ExecutionsRequestItem, type ExecutionsResponseItem, ExternalAPIKeysResource, type ExternalApiKeyResponse, type FeedbackListResponse, type FeedbackObject, type FeedbackType, type FileAttachment, type FileChunk, type FileContentResponse, type FileListResponse, type FileMetadata, type FileScope, type FileScopeUpdateRequest, type FileSearchRequest, type FileSearchResponse, type FileSearchResult, type FileStatisticsResponse, type FileUploadResponse, FilesResource, type FilterLogic, type FilterValue, type FunnelStage, type GetConnectionStatusParams, type GetContactRelationshipsOptions, type GetToolsRequest, type GetToolsResponse, type GetUserConnectionsParams, type InboxKind, type InitiateConnectionRequest, type InitiateConnectionResponse, type InmailSubscription, IntegrationsResource, type IntentSignal, InternalServerError, LINKEDIN_LIMITS, type LifecycleOperationRequest, type LifecycleOperationResponse, type LinkAssetsRequest, type LinkedAssetsResponse, type LinkedInAccountInfoResponse, type LinkedInAccountRateLimits, type LinkedInAccountRateLimitsResponse, type LinkedInAccountRateLimitsUpdate, type LinkedInAction, type LinkedInConnectionStatus, type LinkedInCreditsResponse, type LinkedInLimitSubscriptionType, type LinkedInLimits, type LinkedInSendRequest, type LinkedInSubscriptionInfo, LinkedInSubscriptionType, type LinkedInSyncStatusResponse, type ListAcceptedConnectionsParams, type ListApprovalsOptions, type ListAssetsOptions, type ListCampaignActionsOptions, type ListCampaignProspectsOptions, type ListCampaignsOptions, type ListConnectionsParams, type ListExecutionsOptions, type ListInboxesParams, type ListPendingApprovalsOptions, type ListPlaybooksOptions, type ListProvidersResponse, type ListStepExecutionsOptions, type ListTemplatesOptions, LocalFileNotSupportedError, LumnisClient, type LumnisClientOptions, LumnisError, type LumnisErrorOptions, type MCPScope, type MCPServerCreateRequest, type MCPServerListResponse, type MCPServerResponse, type MCPServerUpdateRequest, MCPServersResource, type MCPToolListResponse, type MCPToolResponse, type MCPTransport, type MailboxUpdateRequest, type MailboxUpdateResponse, type Message, type MessageReceivedData, type MessageResponse, type MessageSentData, MessageType, MessagingAPIError, MessagingConnectionError, MessagingNotFoundError, MessagingResource, MessagingSendError, MessagingValidationError, type MetricsParams, type MetricsRequestItem, type MetricsResponseItem, type ModelAvailability, type ModelOverrides, type ModelPreferenceCreate, type ModelPreferencesBulkUpdate, ModelPreferencesResource, type ModelProvider, type ModelType, NetworkDistance, NoDataSourcesError, NotFoundError, type OnFailure, type OutcomeType, type OutreachAssetCreate, type OutreachAssetResponse, type OutreachAssetType, type OutreachAssetUpdate, OutreachMethod, OutreachResource, type OutreachSource, type OutreachStats, type PaginationInfo, type PaginationParams, type PauseResumeQueuedRequest, type PendingApprovalExtended, PeopleDataSource, PeopleResource, type PeopleSearchRequest, type PeopleSearchResponse, type PersonResult, type Plan, type PlaybookCreate, type PlaybookGenerateJobResponse, type PlaybookGenerateJobStatusResponse, type PlaybookGenerateRequest, type PlaybookResponse, type PlaybookUpdate, type PlaybookVersionResponse, type PostEngagementData, type PostEngagementProvenance, type PostEngagementType, type PostPreviewRequest, type PostPreviewResponse, type PostPreviewResult, type PostsDateRange, type PostsSearchStats, type PriorContactMessage, type ProcessingStatus, type ProcessingStatusResponse, type ProgressEntry, ProgressTracker, type ProjectApprovalsData, type ProjectExecutionsData, type ProjectMetricsData, type ProspectConnectionCheck, type ProspectInfo, type ProspectInput, type ProspectPriorContactResult, type ProspectSyncIdentifier, type ProspectSyncResult, type ProspectWarning, ProviderType, QueueItemStatus, type QuickPeopleSearchOutput, RATE_LIMIT_COOLDOWNS, type RateLimitData, RateLimitError, type RateLimitErrorOptions, type RateLimitInfo$1 as RateLimitInfo, type RateLimitStatusResponse, type RateLimitsParams, type RateLimitsRequestItem, type RateLimitsResponseItem, type RecordOutcomeRequest, type RejectActionRequest, type RejectStepRequest, type RelevanceTier, type RemoveOrgMemberResponse, type RepEngagementData, type RepEngagementStats, type ReplySentiment, type ResolvedCompetitorTarget, type ResponseArtifact, type ResponseListResponse, type ResponseObject, type ResponseStatus, ResponsesResource, SEQUENCE_RATE_LIMITS, type SalaryRange, type Scope, type SelectedSkill, type SendMessageRequest, type SendMessageResponse, type SendReplyRequest, type SendResult, type SenderPersonaInput, type SequenceAction, type SequenceApprovalNeededData, type SequenceChannel, type SequenceEventType, type SequenceExecutionCompletedData, type SequenceExecutionFailedData, type SequenceRateLimitAction, type SequenceStepCompletedData, type SequenceTemplateCreate, type SequenceTemplateResponse, type SequenceTemplateUpdate, SequencesResource, SharePermission, type SkillAnalyticsRequest, type SkillEffectivenessMetrics, type SkillGuidelineBase, type SkillGuidelineCreate, type SkillGuidelineListResponse, type SkillGuidelineResponse, type SkillGuidelineUpdate, type SkillRetrievalMetadata, type SkillUsageBase, type SkillUsageCreate, type SkillUsageListResponse, type SkillUsageResponse, type SkillUsageUpdate, SkillsResource, type SkipActionRequest, type SkipStepRequest, type SkipStepResponse, type SkippedProspect, type SkippedTransferProspect, SourcesNotAvailableError, type SpecializedAgentParams, type SpecializedAgentType, type Stage, type StageFilter, type StartExecutionRequest, type StartExecutionResponse, type StepConfig, type StepExecutionItem, type StepExecutionListResponse, type StepExecutionStatus, type StepHistoryEntry, type StepMetric, type StoppedBreakdown, type StoreApiKeyRequest, type StructuredResponse, type SyncJobResponse, SyncJobStatus, SyncPhaseStatus, type SyncProspectRequest, type SyncProspectResponse, type SyncRequest, type SyncStats, type TeardownOrgResponse, type TemplateShareConfig, type TemplateShareInfo, type TemplateShareRequest, type TemplateSharesResponse, type TenantDetailsResponse, TenantInfoResource, type TenantModelPreference, type TenantModelPreferencesResponse, type TestConnectionResponse, type ThreadListResponse, type ThreadObject, type ThreadResponsesParams, ThreadsResource, type ToolInfo, type TransferProspectsRequest, type TransferProspectsResponse, type TransferSkipReason, type TransitionCondition, type TransitionConditionOperator, type TransitionConditionType, type TransitionConfig, type TransitionEventParams, type TriggerSyncResponse, UNIPILE_RATE_LIMIT_ERRORS, UNIPILE_SAFE_LIMITS, type UUID, type UnlinkConversationsResponse, type UpdateAppStatusParams, type UpdateAppStatusResponse, type UpdateDraftRequest, type UpdateLinkedInSubscriptionRequest, type UpdatePersonaRequest, type UpdatePersonaResponse, type UpdateStepExecutionRequest, type UpdateStepExecutionResponse, type UpdateThreadRequest, type UserConnectionsResponse, type UserCreateRequest, type UserDeleteResponse, type UserIdentifier, type UserListResponse, type UserResponse, type UserUpdateRequest, UsersResource, VALID_EVENT_TYPES, type ValidatedCandidate, ValidationError, type ValidationIssue, type ValidationResponse, type WebhookEvent, type WebhookPayload, canSendInmail, displayProgress, formatProgressEntry, getBestSubscriptionForAction, getConnectionRequestLimit, getContentLimit, getDailyInmailLimit, getDefaultDailyLimits, getInmailAllowance, getLimits, getMessageLimit, getRateLimit, hasOpenProfileMessages, isRecruiterSubscription, normalizeAction, verifyWebhookSignature };
7759
+ export { ACTION_DELAYS, type ActionLimit, type ActiveHours, type AddAndRunCriterionRequest, type AddCriterionRequest, type AddOrgMemberRequest, type AddOrgMemberResponse, type AddPersonaRequest, type AddPersonaResponse, type AddProspectsRequest, type AddProspectsResponse, type AgentConfig, type AgentCostStats, type ApiKeyMode, type ApiKeyModeRequest, type ApiKeyModeResponse, type ApiProvider, type AppEnabledResponse, type AppliedFilters, type ApprovalActionRequest, type ApprovalItem, type ApprovalListResponse, type ApprovalMode, type ApprovalResponse, type ApprovalSettings, type ApprovalStatus, type ApprovalsParams, type ApprovalsRequestItem, type ApprovalsResponseItem, type ApproveStepRequest, type AppsListResponse, type ArtifactObject, type ArtifactsListResponse, AuthenticationError, type BaseResource, type BatchCheckConnectionRequest, type BatchCheckPriorContactRequest, type BatchCheckPriorContactResponse, type BatchConnectionRequest, type BatchConnectionResponse, type BatchConnectionStatus, type BatchConnectionStatusResponse, type BatchDraftCompleteData, type BatchDraftCreatedData, type BatchDraftErrorData, type BatchDraftJobProgress, type BatchDraftJobResponse, type BatchDraftJobStartedData, type BatchDraftJobStatusResponse, type BatchDraftProgressData, type BatchDraftRequest, type BatchDraftResponse, type BatchDraftStreamCallbacks, type BatchDraftStreamEvent, type BatchDraftStreamEventType, type BatchExecutionInclude, type BatchExecutionRequest, type BatchExecutionResponse, BatchJobStatus, type BatchPollRequest, type BatchPollResponse, type BatchProspectIdentifier, type BatchRequestItem, type BatchRequestType, type BatchResponseItem, type BatchSendRequest, type BatchSendResponse, type BatchStepMetric, type BillingStatus, type BulkApprovalAction, type BulkApprovalFailure, type BulkApprovalRequest, type BulkApprovalResponse, type BulkCompleteFailure, type BulkCompleteRequest, type BulkCompleteResponse, type BulkDeleteRequest, type BulkDeleteResponse, type BulkOperationRequest, type BulkOperationResponse, type BulkUploadResponse, CONTENT_LIMITS, CONTENT_LIMITS_MAP, type CampaignActionListResponse, type CampaignActionResponse, type CampaignActionStatus, type CampaignActionType, type CampaignBulkApprovalAction, type CampaignBulkApprovalItem, type CampaignBulkApprovalRequest, type CampaignBulkApprovalResponse, type CampaignBulkApprovalResult, type CampaignCreate, type CampaignGuardrails, type CampaignListResponse, type CampaignMetricsResponse, type CampaignOutcomeType, type CampaignProspectDetailResponse, type CampaignProspectInput, type CampaignProspectResponse, type CampaignProspectState, type CampaignResponse, type CampaignStatus, type CampaignUpdate, CampaignsResource, type CancelDraftResponse, type CancelQueuedRequest, type CancelResponseResponse, type Channel, type ChannelContactHistory, type ChannelFunnel, type ChannelRatios, ChannelType, type CheckAppEnabledParams, type CheckLinkedInConnectionRequest, type CheckPriorContactRequest, type CheckPriorContactResponse, type ChunkingStrategy, type CompetitorPostEngagementOutput, type CompetitorRepEngagementOutput, type CompleteExecutionRequest, type CompleteExecutionResponse, type ConnectInboxRequest, type ConnectInboxResponse, type Connection, type ConnectionAcceptedData, type ConnectionCallbackRequest, type ConnectionCallbackResponse, type ConnectionInfo, type ConnectionStatus, type ConnectionStatusResponse, type ConnectionSummary, type ConnectionsResponse, type ConnectionsSyncStatus, type ContactDetailsInput, type ContactEnrichPersonInput, type ContactEnrichPersonResult, type ContactEnrichRequest, type ContactEnrichResponse, type ContactFinding, type ContactHistorySyncStatus, type ContactRelationshipProvider, type ContactRelationshipResponse, type ContactRelationshipStatus, ContactRelationshipsResource, type ContactScore, type ContentLimit, type ContentSource, type ContentType, type ConversationDetail, ConversationStatus, type ConversationSummary, type CreateDraftRequest, type CreateFeedbackRequest, type CreateFeedbackResponse, type CreateResponseRequest, type CreateResponseResponse, type CreateThreadRequest, type CriteriaClassification, type CriteriaMetadata, type CriterionDefinition, type CriterionResult, type CriterionType, type CrmContactsSyncRequest, type CrmContactsSyncResponse, type CrmContactsSyncStatusResponse, type CrmExclusionGrantListResponse, type CrmExclusionGrantRequest, type CrmExclusionGrantResponse, type CrmMatchBatchRequest, type CrmMatchBatchResponse, type CrmMatchedProspect, type CrmProvider, CrmResource, type CrmSyncProspectRequest, type CrmSyncProspectResponse, DAILY_INMAIL_LIMITS, DEFAULT_SUBSCRIPTION_TYPE, type DatabaseStatus, type DeepPeopleSearchOutput, type DeepSearchPreview, type DeepSearchStats, type DeleteApiKeyResponse, type DeleteConnectionsResponse, type DeleteConversationResponse, type DeleteConversationsByProjectResponse, type DisconnectRequest, type DisconnectResponse, type DiscoveryTrace, type DraftResponse, type DraftSendOverride, DraftStatus, type DuplicateHandling, type DuplicateTemplateRequest, type EditQueuedRequest, type Email, type EmailAction, type EmailInboxItem, type EmailInboxListResponse, type EmailInboxPersona, type EmailOnboardRequest, type EmailOnboardResponse, type EmailOnboardStatusResponse, type EmailOrgHealthResponse, type EmailOrgListResponse, type EmailOrgSettingsResponse, type EmailOrgSettingsUpdate, type EmailOrgSummary, EmailResource, type EmailSenderPersona, type EmailThreadSummary, type EngagementStatus, type EngagementStatusData, type EngagementStatusRequest, type EngagementStatusResponse, EnrichmentResource, type ErrorDetail, type ErrorResponse, type ErrorResponseItem, type EvidenceSource, type ExecutionDetailResponse, type ExecutionEvent, type ExecutionEventData, type ExecutionListResponse, type ExecutionMetricsOptions, type ExecutionMetricsResponse, type ExecutionStatus, type ExecutionSummary, type ExecutionSummaryExtended, type ExecutionsParams, type ExecutionsRequestItem, type ExecutionsResponseItem, ExternalAPIKeysResource, type ExternalApiKeyResponse, type FeedbackListResponse, type FeedbackObject, type FeedbackType, type FileAttachment, type FileChunk, type FileContentResponse, type FileListResponse, type FileMetadata, type FileScope, type FileScopeUpdateRequest, type FileSearchRequest, type FileSearchResponse, type FileSearchResult, type FileStatisticsResponse, type FileUploadResponse, FilesResource, type FilterLogic, type FilterValue, type FunnelStage, type GetConnectionStatusParams, type GetContactRelationshipsOptions, type GetToolsRequest, type GetToolsResponse, type GetUserConnectionsParams, type InboxKind, type InitiateConnectionRequest, type InitiateConnectionResponse, type InmailSubscription, IntegrationsResource, type IntentSignal, InternalServerError, LINKEDIN_LIMITS, type LifecycleOperationRequest, type LifecycleOperationResponse, type LinkAssetsRequest, type LinkedAssetsResponse, type LinkedInAccountInfoResponse, type LinkedInAccountRateLimits, type LinkedInAccountRateLimitsResponse, type LinkedInAccountRateLimitsUpdate, type LinkedInAction, type LinkedInConnectionStatus, type LinkedInCreditsResponse, type LinkedInLimitSubscriptionType, type LinkedInLimits, type LinkedInSendRequest, type LinkedInSubscriptionInfo, LinkedInSubscriptionType, type LinkedInSyncStatusResponse, type ListAcceptedConnectionsParams, type ListApprovalsOptions, type ListAssetsOptions, type ListCampaignActionsOptions, type ListCampaignProspectsOptions, type ListCampaignsOptions, type ListConnectionsParams, type ListExecutionsOptions, type ListInboxesParams, type ListPendingApprovalsOptions, type ListPlaybooksOptions, type ListProvidersResponse, type ListStepExecutionsOptions, type ListTemplatesOptions, LocalFileNotSupportedError, LumnisClient, type LumnisClientOptions, LumnisError, type LumnisErrorOptions, type MCPScope, type MCPServerCreateRequest, type MCPServerListResponse, type MCPServerResponse, type MCPServerUpdateRequest, MCPServersResource, type MCPToolListResponse, type MCPToolResponse, type MCPTransport, type MailboxUpdateRequest, type MailboxUpdateResponse, type Message, type MessageReceivedData, type MessageResponse, type MessageSentData, MessageType, MessagingAPIError, MessagingConnectionError, MessagingNotFoundError, MessagingResource, MessagingSendError, MessagingValidationError, type MetricsParams, type MetricsRequestItem, type MetricsResponseItem, type ModelAvailability, type ModelOverrides, type ModelPreferenceCreate, type ModelPreferencesBulkUpdate, ModelPreferencesResource, type ModelProvider, type ModelType, NetworkDistance, NoDataSourcesError, NotFoundError, type OnFailure, type OutcomeType, type OutreachAssetCreate, type OutreachAssetResponse, type OutreachAssetType, type OutreachAssetUpdate, OutreachMethod, OutreachResource, type OutreachSource, type OutreachStats, type PaginationInfo, type PaginationParams, type PauseResumeQueuedRequest, type PendingApprovalExtended, PeopleDataSource, PeopleResource, type PeopleSearchRequest, type PeopleSearchResponse, type PersonResult, type Plan, type PlaybookCreate, type PlaybookGenerateJobResponse, type PlaybookGenerateJobStatusResponse, type PlaybookGenerateRequest, type PlaybookResponse, type PlaybookUpdate, type PlaybookVersionResponse, type PostEngagementData, type PostEngagementProvenance, type PostEngagementType, type PostPreviewRequest, type PostPreviewResponse, type PostPreviewResult, type PostsDateRange, type PostsSearchStats, type PriorContactMessage, type ProcessingStatus, type ProcessingStatusResponse, type ProgressEntry, ProgressTracker, type ProjectApprovalsData, type ProjectExecutionsData, type ProjectMetricsData, type ProspectConnectionCheck, type ProspectInfo, type ProspectInput, type ProspectPriorContactResult, type ProspectSyncIdentifier, type ProspectSyncResult, type ProspectWarning, ProviderType, QueueItemStatus, type QuickPeopleSearchOutput, RATE_LIMIT_COOLDOWNS, type RateLimitData, RateLimitError, type RateLimitErrorOptions, type RateLimitInfo$1 as RateLimitInfo, type RateLimitStatusResponse, type RateLimitsParams, type RateLimitsRequestItem, type RateLimitsResponseItem, type RecordOutcomeRequest, type RejectActionRequest, type RejectStepRequest, type RelevanceTier, type RemoveOrgMemberResponse, type RepEngagementData, type RepEngagementStats, type ReplySentiment, type ResolvedCompetitorTarget, type ResponseArtifact, type ResponseListResponse, type ResponseObject, type ResponseStatus, ResponsesResource, SEQUENCE_RATE_LIMITS, type SalaryRange, type Scope, type SelectedSkill, type SendMessageRequest, type SendMessageResponse, type SendReplyRequest, type SendResult, type SenderPersonaInput, type SequenceAction, type SequenceApprovalNeededData, type SequenceChannel, type SequenceEventType, type SequenceExecutionCompletedData, type SequenceExecutionFailedData, type SequenceRateLimitAction, type SequenceStepCompletedData, type SequenceTemplateCreate, type SequenceTemplateResponse, type SequenceTemplateUpdate, SequencesResource, SharePermission, type SkillAnalyticsRequest, type SkillEffectivenessMetrics, type SkillGuidelineBase, type SkillGuidelineCreate, type SkillGuidelineListResponse, type SkillGuidelineResponse, type SkillGuidelineUpdate, type SkillRetrievalMetadata, type SkillUsageBase, type SkillUsageCreate, type SkillUsageListResponse, type SkillUsageResponse, type SkillUsageUpdate, SkillsResource, type SkipActionRequest, type SkipStepRequest, type SkipStepResponse, type SkippedProspect, type SkippedTransferProspect, SourcesNotAvailableError, type SpecializedAgentParams, type SpecializedAgentType, type Stage, type StageFilter, type StartExecutionRequest, type StartExecutionResponse, type StepConfig, type StepExecutionItem, type StepExecutionListResponse, type StepExecutionStatus, type StepHistoryEntry, type StepMetric, type StoppedBreakdown, type StoreApiKeyRequest, type StructuredResponse, type SyncJobResponse, SyncJobStatus, SyncPhaseStatus, type SyncProspectRequest, type SyncProspectResponse, type SyncRequest, type SyncStats, type TeardownOrgResponse, type TemplateShareConfig, type TemplateShareInfo, type TemplateShareRequest, type TemplateSharesResponse, type TenantDetailsResponse, TenantInfoResource, type TenantModelPreference, type TenantModelPreferencesResponse, type TestConnectionResponse, type ThreadListResponse, type ThreadObject, type ThreadResponsesParams, ThreadsResource, type ToolInfo, type TransferProspectsRequest, type TransferProspectsResponse, type TransferSkipReason, type TransitionCondition, type TransitionConditionOperator, type TransitionConditionType, type TransitionConfig, type TransitionEventParams, type TriggerSyncResponse, UNIPILE_RATE_LIMIT_ERRORS, UNIPILE_SAFE_LIMITS, type UUID, type UnlinkConversationsResponse, type UpdateAppStatusParams, type UpdateAppStatusResponse, type UpdateDraftRequest, type UpdateLinkedInSubscriptionRequest, type UpdatePersonaRequest, type UpdatePersonaResponse, type UpdateStepExecutionRequest, type UpdateStepExecutionResponse, type UpdateThreadRequest, type UserConnectionsResponse, type UserCreateRequest, type UserDeleteResponse, type UserIdentifier, type UserListResponse, type UserResponse, type UserUpdateRequest, UsersResource, VALID_EVENT_TYPES, type ValidatedCandidate, ValidationError, type ValidationIssue, type ValidationResponse, type WebhookEvent, type WebhookPayload, canSendInmail, displayProgress, formatProgressEntry, getBestSubscriptionForAction, getConnectionRequestLimit, getContentLimit, getDailyInmailLimit, getDefaultDailyLimits, getInmailAllowance, getLimits, getMessageLimit, getRateLimit, hasOpenProfileMessages, isRecruiterSubscription, normalizeAction, verifyWebhookSignature };
package/dist/index.d.ts CHANGED
@@ -1742,6 +1742,26 @@ interface SpecializedAgentParams {
1742
1742
  * Names to exclude from results (passed through to CrustData post-processing when supported).
1743
1743
  */
1744
1744
  excludeNames?: string[];
1745
+ /**
1746
+ * Exclude people already in the acting user's synced CRM (`crm_contacts` ledger;
1747
+ * local lookup only, never a live CRM call). Matches on exact LinkedIn URL and
1748
+ * email; optionally name+company when `crmNameCompanyMatch` is true.
1749
+ * @default true
1750
+ * Used by deep_people_search (via `specializedAgentParams`) and quick_people_search
1751
+ * (via top-level `options` on the create request).
1752
+ */
1753
+ excludeCrmContacts?: boolean;
1754
+ /**
1755
+ * Narrow CRM exclusion to specific granted owners' ledgers (user id or email).
1756
+ * Omitted = the acting user's own CRM only. Ungranted entries are ignored.
1757
+ */
1758
+ crmExclusionOwners?: string[];
1759
+ /**
1760
+ * Within CRM exclusion, also drop candidates matching by exact name + company
1761
+ * (catches CRM contacts with no LinkedIn URL, especially HubSpot).
1762
+ * @default true
1763
+ */
1764
+ crmNameCompanyMatch?: boolean;
1745
1765
  /**
1746
1766
  * Response ID to reuse criteria from.
1747
1767
  */
@@ -2487,6 +2507,12 @@ interface CampaignGuardrails {
2487
2507
  * as a kill-switch.
2488
2508
  */
2489
2509
  customerEditsEnabled?: boolean;
2510
+ /**
2511
+ * When true (default), prospects already in the campaign owner's synced CRM
2512
+ * are skipped at add-time (exact LinkedIn/email) and flagged on name+company.
2513
+ * Set false to disable for this campaign.
2514
+ */
2515
+ excludeCrmContacts?: boolean;
2490
2516
  }
2491
2517
  type ApprovalMode = 'auto' | 'require';
2492
2518
  interface ApprovalSettings {
@@ -2622,6 +2648,8 @@ interface AddProspectsResponse {
2622
2648
  added: number;
2623
2649
  skipped: number;
2624
2650
  warnings: ProspectWarning[];
2651
+ /** Prospects hard-skipped because they exactly matched the owner's CRM ledger. */
2652
+ skippedInCrm?: number;
2625
2653
  }
2626
2654
  interface TransferProspectsRequest {
2627
2655
  /** Campaign to move the prospects into. Must belong to the same user and not be stopped/completed. */
@@ -3172,16 +3200,61 @@ declare class ContactRelationshipsResource {
3172
3200
  *
3173
3201
  * Capability notes:
3174
3202
  * - `attio` supports both email and LinkedIn-URL person search.
3175
- * - `hubspot` only supports email search; LinkedIn URLs are stored as a
3176
- * custom property on create but are not searchable through the
3177
- * reconciliation flow.
3203
+ * - `hubspot` reconciles via email and name+company; LinkedIn URLs are
3204
+ * stored on create but are not directly searchable in live CRM calls.
3205
+ * The local `crm_contacts` ledger (see contacts sync) improves match-batch
3206
+ * and search/campaign exclusion without live HubSpot lookups.
3178
3207
  */
3179
3208
  type CrmProvider = 'attio' | 'hubspot';
3209
+ /**
3210
+ * Trigger a full mirror of the owner's CRM contact book into the local
3211
+ * `crm_contacts` ledger (used for fast exclusion/matching; not a live CRM call).
3212
+ */
3213
+ interface CrmContactsSyncRequest {
3214
+ /** UUID or email of the CRM owner whose connection is synced. */
3215
+ userId: string;
3216
+ provider: CrmProvider;
3217
+ }
3218
+ interface CrmContactsSyncResponse {
3219
+ /** `started` — sync claimed; `already_in_progress` — another run holds the lock. */
3220
+ status: 'started' | 'already_in_progress';
3221
+ provider: CrmProvider;
3222
+ }
3223
+ /** Sync freshness for an owner+provider ledger mirror. */
3224
+ interface CrmContactsSyncStatusResponse {
3225
+ provider: CrmProvider;
3226
+ connected: boolean;
3227
+ syncInProgress: boolean;
3228
+ lastReconciledAt?: string | null;
3229
+ syncedCount: number;
3230
+ /** Null in v1 — LIST APIs do not return a reliable total. */
3231
+ totalInCrm?: number | null;
3232
+ }
3233
+ /**
3234
+ * Grant or revoke a member's right to exclude against an owner's CRM ledger.
3235
+ * Per-owner (all of that owner's synced CRMs inherit). Self-grant is a no-op.
3236
+ */
3237
+ interface CrmExclusionGrantRequest {
3238
+ /** Member (UUID or email) who reads the owner's exclusion ledger. */
3239
+ memberUserId: string;
3240
+ /** CRM owner (UUID or email) whose ledger is shared. */
3241
+ ownerUserId: string;
3242
+ }
3243
+ interface CrmExclusionGrantResponse {
3244
+ memberUserId: string;
3245
+ ownerUserId: string;
3246
+ status: 'granted' | 'revoked';
3247
+ }
3248
+ interface CrmExclusionGrantListResponse {
3249
+ memberUserId: string;
3250
+ ownerUserIds: string[];
3251
+ }
3180
3252
  /**
3181
3253
  * Push one Lumnis prospect to the connected CRM.
3182
3254
  *
3183
- * The prospect must already exist in a `campaign_prospects` row owned
3184
- * by `userId`; the linkedin URL is the lookup key.
3255
+ * Prefer a `campaign_prospects` row owned by `userId` when present; otherwise
3256
+ * the server enriches from profile cache / Fiber and creates the CRM record.
3257
+ * Provider-id/URN LinkedIn URLs are resolved to vanity before reconcile.
3185
3258
  */
3186
3259
  interface CrmSyncProspectRequest {
3187
3260
  /** UUID or email of the user whose CRM connection executes the call. */
@@ -3230,7 +3303,8 @@ interface CrmMatchBatchResponse {
3230
3303
  /**
3231
3304
  * Resource for the user-triggered CRM Sync API.
3232
3305
  *
3233
- * Wraps `POST /v1/crm/prospects/sync` and `POST /v1/crm/prospects/match-batch`.
3306
+ * Wraps prospect sync/match, contacts-ledger sync, and exclusion-grant routes
3307
+ * under `/v1/crm`.
3234
3308
  *
3235
3309
  * The user identified by `userId` must already have an active CRM
3236
3310
  * connection (see `client.integrations.initiateConnection`). When the
@@ -3240,8 +3314,9 @@ interface CrmMatchBatchResponse {
3240
3314
  *
3241
3315
  * Failure modes worth handling:
3242
3316
  * - `409 crm_not_connected` — user hasn't connected the provider.
3243
- * - `404 prospect_not_found` (sync only) — no `campaign_prospects` row
3244
- * matches `linkedinUrl` for this user.
3317
+ * - `404 prospect_not_found` (sync) — profile could not be identified.
3318
+ * - `422 linkedin_url_unresolved` (sync) internal member-id URL could not
3319
+ * be resolved to a public vanity URL.
3245
3320
  * - `502 crm_upstream_error` — Attio/HubSpot returned an error.
3246
3321
  * - `503 crm_upstream_rate_limited` — upstream rate-limit; the response
3247
3322
  * includes a `Retry-After` header.
@@ -3257,6 +3332,9 @@ declare class CrmResource {
3257
3332
  * `crmRecordId`. Stale links (record deleted in the CRM) are detected
3258
3333
  * and re-created automatically.
3259
3334
  *
3335
+ * Works with or without a `campaign_prospects` row — search-sourced
3336
+ * prospects are enriched from profile cache when needed.
3337
+ *
3260
3338
  * @example
3261
3339
  * ```typescript
3262
3340
  * const result = await client.crm.syncProspect({
@@ -3274,16 +3352,13 @@ declare class CrmResource {
3274
3352
  * render a "linked" indicator for the ones that come back true.
3275
3353
  *
3276
3354
  * Layered cache on the server side: persistent positive matches are
3277
- * served from the `campaign_prospects.crm_record_id` column, negative
3278
- * results are served from a Redis cache (TTL configured by
3279
- * `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`). Only the leftover unknowns
3280
- * fan out to the live CRM, bounded by
3355
+ * served from the `campaign_prospects.crm_record_id` column and the
3356
+ * local `crm_contacts` ledger; negative results are served from a Redis
3357
+ * cache (TTL configured by `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`).
3358
+ * Only the leftover unknowns fan out to the live CRM, bounded by
3281
3359
  * `CRM_MATCH_LIVE_SEARCH_PARALLELISM`.
3282
3360
  *
3283
- * Note: HubSpot does not expose a LinkedIn-URL search field through
3284
- * Composio, so for `provider: 'hubspot'` URLs that aren't already in
3285
- * the persistent cache will always come back `linked: false`. The
3286
- * sync endpoint still reconciles via email when available.
3361
+ * Provider-id/URN inputs are resolved to vanity before matching.
3287
3362
  *
3288
3363
  * @example
3289
3364
  * ```typescript
@@ -3298,6 +3373,30 @@ declare class CrmResource {
3298
3373
  * ```
3299
3374
  */
3300
3375
  matchBatch(data: CrmMatchBatchRequest): Promise<CrmMatchBatchResponse>;
3376
+ /**
3377
+ * Trigger a full mirror of the owner's CRM contact book into the local
3378
+ * `crm_contacts` ledger. Returns immediately (`202`); poll
3379
+ * {@link getContactsSyncStatus} for progress.
3380
+ */
3381
+ syncContacts(data: CrmContactsSyncRequest): Promise<CrmContactsSyncResponse>;
3382
+ /**
3383
+ * Ledger sync freshness for an owner+provider: connection state, whether a
3384
+ * sync is in progress, last reconcile time, and row count in the ledger.
3385
+ */
3386
+ getContactsSyncStatus(userId: string, provider: CrmProvider): Promise<CrmContactsSyncStatusResponse>;
3387
+ /**
3388
+ * Grant a member the right to exclude against an owner's synced CRM ledger
3389
+ * (all providers for that owner). Typically called by the FE on org join.
3390
+ */
3391
+ grantExclusionGrant(data: CrmExclusionGrantRequest): Promise<CrmExclusionGrantResponse>;
3392
+ /**
3393
+ * Revoke a member's access to an owner's CRM exclusion ledger.
3394
+ */
3395
+ revokeExclusionGrant(data: CrmExclusionGrantRequest): Promise<CrmExclusionGrantResponse>;
3396
+ /**
3397
+ * List CRM owners whose exclusion ledger a member may read (via grants).
3398
+ */
3399
+ listExclusionGrants(memberUserId: string): Promise<CrmExclusionGrantListResponse>;
3301
3400
  }
3302
3401
 
3303
3402
  /**
@@ -5881,6 +5980,9 @@ declare class ResponsesResource {
5881
5980
  * @param options - Optional search parameters
5882
5981
  * @param options.limit - Maximum number of results (1-100, default: 20)
5883
5982
  * @param options.dataSources - Specific data sources to use: ["PDL", "CORESIGNAL", "CRUST_DATA"]
5983
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true (via request `options`)
5984
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
5985
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
5884
5986
  * @returns Response with structured_response containing:
5885
5987
  * - candidates: List of person results
5886
5988
  * - totalFound: Total unique candidates found
@@ -5891,6 +5993,9 @@ declare class ResponsesResource {
5891
5993
  quickPeopleSearch(query: string, options?: {
5892
5994
  limit?: number;
5893
5995
  dataSources?: string[];
5996
+ excludeCrmContacts?: boolean;
5997
+ crmExclusionOwners?: string[];
5998
+ crmNameCompanyMatch?: boolean;
5894
5999
  }): Promise<CreateResponseResponse>;
5895
6000
  /**
5896
6001
  * Perform a deep people search with AI-generated criteria and validation
@@ -5910,6 +6015,9 @@ declare class ResponsesResource {
5910
6015
  * @param options.excludeProfiles - LinkedIn URLs to exclude from results
5911
6016
  * @param options.excludePreviouslyContacted - Exclude previously contacted people
5912
6017
  * @param options.excludeNames - Names to exclude from results
6018
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true
6019
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
6020
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
5913
6021
  * @param options.searchJobSignal - CrustData job-listing signal search (decision makers at hiring companies); true | false | 'auto'
5914
6022
  * @param options.deepVerify - Web verification for org/location/third-party criteria: 'auto' (default), 'always', or 'off'
5915
6023
  * @param options.deepValidationUseRelevanceReranker - SLM relevance reranker for surfaced candidates (ranking-only); @default true
@@ -5937,6 +6045,9 @@ declare class ResponsesResource {
5937
6045
  excludeProfiles?: string[];
5938
6046
  excludePreviouslyContacted?: boolean;
5939
6047
  excludeNames?: string[];
6048
+ excludeCrmContacts?: boolean;
6049
+ crmExclusionOwners?: string[];
6050
+ crmNameCompanyMatch?: boolean;
5940
6051
  searchProfiles?: boolean | 'auto';
5941
6052
  searchPosts?: boolean | 'auto';
5942
6053
  includeEngagementInScore?: boolean | 'auto';
@@ -7645,4 +7756,4 @@ declare class ProgressTracker {
7645
7756
  */
7646
7757
  declare function verifyWebhookSignature(payload: string, signature: string, secret: string): boolean;
7647
7758
 
7648
- export { ACTION_DELAYS, type ActionLimit, type ActiveHours, type AddAndRunCriterionRequest, type AddCriterionRequest, type AddOrgMemberRequest, type AddOrgMemberResponse, type AddPersonaRequest, type AddPersonaResponse, type AddProspectsRequest, type AddProspectsResponse, type AgentConfig, type AgentCostStats, type ApiKeyMode, type ApiKeyModeRequest, type ApiKeyModeResponse, type ApiProvider, type AppEnabledResponse, type AppliedFilters, type ApprovalActionRequest, type ApprovalItem, type ApprovalListResponse, type ApprovalMode, type ApprovalResponse, type ApprovalSettings, type ApprovalStatus, type ApprovalsParams, type ApprovalsRequestItem, type ApprovalsResponseItem, type ApproveStepRequest, type AppsListResponse, type ArtifactObject, type ArtifactsListResponse, AuthenticationError, type BaseResource, type BatchCheckConnectionRequest, type BatchCheckPriorContactRequest, type BatchCheckPriorContactResponse, type BatchConnectionRequest, type BatchConnectionResponse, type BatchConnectionStatus, type BatchConnectionStatusResponse, type BatchDraftCompleteData, type BatchDraftCreatedData, type BatchDraftErrorData, type BatchDraftJobProgress, type BatchDraftJobResponse, type BatchDraftJobStartedData, type BatchDraftJobStatusResponse, type BatchDraftProgressData, type BatchDraftRequest, type BatchDraftResponse, type BatchDraftStreamCallbacks, type BatchDraftStreamEvent, type BatchDraftStreamEventType, type BatchExecutionInclude, type BatchExecutionRequest, type BatchExecutionResponse, BatchJobStatus, type BatchPollRequest, type BatchPollResponse, type BatchProspectIdentifier, type BatchRequestItem, type BatchRequestType, type BatchResponseItem, type BatchSendRequest, type BatchSendResponse, type BatchStepMetric, type BillingStatus, type BulkApprovalAction, type BulkApprovalFailure, type BulkApprovalRequest, type BulkApprovalResponse, type BulkCompleteFailure, type BulkCompleteRequest, type BulkCompleteResponse, type BulkDeleteRequest, type BulkDeleteResponse, type BulkOperationRequest, type BulkOperationResponse, type BulkUploadResponse, CONTENT_LIMITS, CONTENT_LIMITS_MAP, type CampaignActionListResponse, type CampaignActionResponse, type CampaignActionStatus, type CampaignActionType, type CampaignBulkApprovalAction, type CampaignBulkApprovalItem, type CampaignBulkApprovalRequest, type CampaignBulkApprovalResponse, type CampaignBulkApprovalResult, type CampaignCreate, type CampaignGuardrails, type CampaignListResponse, type CampaignMetricsResponse, type CampaignOutcomeType, type CampaignProspectDetailResponse, type CampaignProspectInput, type CampaignProspectResponse, type CampaignProspectState, type CampaignResponse, type CampaignStatus, type CampaignUpdate, CampaignsResource, type CancelDraftResponse, type CancelQueuedRequest, type CancelResponseResponse, type Channel, type ChannelContactHistory, type ChannelFunnel, type ChannelRatios, ChannelType, type CheckAppEnabledParams, type CheckLinkedInConnectionRequest, type CheckPriorContactRequest, type CheckPriorContactResponse, type ChunkingStrategy, type CompetitorPostEngagementOutput, type CompetitorRepEngagementOutput, type CompleteExecutionRequest, type CompleteExecutionResponse, type ConnectInboxRequest, type ConnectInboxResponse, type Connection, type ConnectionAcceptedData, type ConnectionCallbackRequest, type ConnectionCallbackResponse, type ConnectionInfo, type ConnectionStatus, type ConnectionStatusResponse, type ConnectionSummary, type ConnectionsResponse, type ConnectionsSyncStatus, type ContactDetailsInput, type ContactEnrichPersonInput, type ContactEnrichPersonResult, type ContactEnrichRequest, type ContactEnrichResponse, type ContactFinding, type ContactHistorySyncStatus, type ContactRelationshipProvider, type ContactRelationshipResponse, type ContactRelationshipStatus, ContactRelationshipsResource, type ContactScore, type ContentLimit, type ContentSource, type ContentType, type ConversationDetail, ConversationStatus, type ConversationSummary, type CreateDraftRequest, type CreateFeedbackRequest, type CreateFeedbackResponse, type CreateResponseRequest, type CreateResponseResponse, type CreateThreadRequest, type CriteriaClassification, type CriteriaMetadata, type CriterionDefinition, type CriterionResult, type CriterionType, type CrmMatchBatchRequest, type CrmMatchBatchResponse, type CrmMatchedProspect, type CrmProvider, CrmResource, type CrmSyncProspectRequest, type CrmSyncProspectResponse, DAILY_INMAIL_LIMITS, DEFAULT_SUBSCRIPTION_TYPE, type DatabaseStatus, type DeepPeopleSearchOutput, type DeepSearchPreview, type DeepSearchStats, type DeleteApiKeyResponse, type DeleteConnectionsResponse, type DeleteConversationResponse, type DeleteConversationsByProjectResponse, type DisconnectRequest, type DisconnectResponse, type DiscoveryTrace, type DraftResponse, type DraftSendOverride, DraftStatus, type DuplicateHandling, type DuplicateTemplateRequest, type EditQueuedRequest, type Email, type EmailAction, type EmailInboxItem, type EmailInboxListResponse, type EmailInboxPersona, type EmailOnboardRequest, type EmailOnboardResponse, type EmailOnboardStatusResponse, type EmailOrgHealthResponse, type EmailOrgListResponse, type EmailOrgSettingsResponse, type EmailOrgSettingsUpdate, type EmailOrgSummary, EmailResource, type EmailSenderPersona, type EmailThreadSummary, type EngagementStatus, type EngagementStatusData, type EngagementStatusRequest, type EngagementStatusResponse, EnrichmentResource, type ErrorDetail, type ErrorResponse, type ErrorResponseItem, type EvidenceSource, type ExecutionDetailResponse, type ExecutionEvent, type ExecutionEventData, type ExecutionListResponse, type ExecutionMetricsOptions, type ExecutionMetricsResponse, type ExecutionStatus, type ExecutionSummary, type ExecutionSummaryExtended, type ExecutionsParams, type ExecutionsRequestItem, type ExecutionsResponseItem, ExternalAPIKeysResource, type ExternalApiKeyResponse, type FeedbackListResponse, type FeedbackObject, type FeedbackType, type FileAttachment, type FileChunk, type FileContentResponse, type FileListResponse, type FileMetadata, type FileScope, type FileScopeUpdateRequest, type FileSearchRequest, type FileSearchResponse, type FileSearchResult, type FileStatisticsResponse, type FileUploadResponse, FilesResource, type FilterLogic, type FilterValue, type FunnelStage, type GetConnectionStatusParams, type GetContactRelationshipsOptions, type GetToolsRequest, type GetToolsResponse, type GetUserConnectionsParams, type InboxKind, type InitiateConnectionRequest, type InitiateConnectionResponse, type InmailSubscription, IntegrationsResource, type IntentSignal, InternalServerError, LINKEDIN_LIMITS, type LifecycleOperationRequest, type LifecycleOperationResponse, type LinkAssetsRequest, type LinkedAssetsResponse, type LinkedInAccountInfoResponse, type LinkedInAccountRateLimits, type LinkedInAccountRateLimitsResponse, type LinkedInAccountRateLimitsUpdate, type LinkedInAction, type LinkedInConnectionStatus, type LinkedInCreditsResponse, type LinkedInLimitSubscriptionType, type LinkedInLimits, type LinkedInSendRequest, type LinkedInSubscriptionInfo, LinkedInSubscriptionType, type LinkedInSyncStatusResponse, type ListAcceptedConnectionsParams, type ListApprovalsOptions, type ListAssetsOptions, type ListCampaignActionsOptions, type ListCampaignProspectsOptions, type ListCampaignsOptions, type ListConnectionsParams, type ListExecutionsOptions, type ListInboxesParams, type ListPendingApprovalsOptions, type ListPlaybooksOptions, type ListProvidersResponse, type ListStepExecutionsOptions, type ListTemplatesOptions, LocalFileNotSupportedError, LumnisClient, type LumnisClientOptions, LumnisError, type LumnisErrorOptions, type MCPScope, type MCPServerCreateRequest, type MCPServerListResponse, type MCPServerResponse, type MCPServerUpdateRequest, MCPServersResource, type MCPToolListResponse, type MCPToolResponse, type MCPTransport, type MailboxUpdateRequest, type MailboxUpdateResponse, type Message, type MessageReceivedData, type MessageResponse, type MessageSentData, MessageType, MessagingAPIError, MessagingConnectionError, MessagingNotFoundError, MessagingResource, MessagingSendError, MessagingValidationError, type MetricsParams, type MetricsRequestItem, type MetricsResponseItem, type ModelAvailability, type ModelOverrides, type ModelPreferenceCreate, type ModelPreferencesBulkUpdate, ModelPreferencesResource, type ModelProvider, type ModelType, NetworkDistance, NoDataSourcesError, NotFoundError, type OnFailure, type OutcomeType, type OutreachAssetCreate, type OutreachAssetResponse, type OutreachAssetType, type OutreachAssetUpdate, OutreachMethod, OutreachResource, type OutreachSource, type OutreachStats, type PaginationInfo, type PaginationParams, type PauseResumeQueuedRequest, type PendingApprovalExtended, PeopleDataSource, PeopleResource, type PeopleSearchRequest, type PeopleSearchResponse, type PersonResult, type Plan, type PlaybookCreate, type PlaybookGenerateJobResponse, type PlaybookGenerateJobStatusResponse, type PlaybookGenerateRequest, type PlaybookResponse, type PlaybookUpdate, type PlaybookVersionResponse, type PostEngagementData, type PostEngagementProvenance, type PostEngagementType, type PostPreviewRequest, type PostPreviewResponse, type PostPreviewResult, type PostsDateRange, type PostsSearchStats, type PriorContactMessage, type ProcessingStatus, type ProcessingStatusResponse, type ProgressEntry, ProgressTracker, type ProjectApprovalsData, type ProjectExecutionsData, type ProjectMetricsData, type ProspectConnectionCheck, type ProspectInfo, type ProspectInput, type ProspectPriorContactResult, type ProspectSyncIdentifier, type ProspectSyncResult, type ProspectWarning, ProviderType, QueueItemStatus, type QuickPeopleSearchOutput, RATE_LIMIT_COOLDOWNS, type RateLimitData, RateLimitError, type RateLimitErrorOptions, type RateLimitInfo$1 as RateLimitInfo, type RateLimitStatusResponse, type RateLimitsParams, type RateLimitsRequestItem, type RateLimitsResponseItem, type RecordOutcomeRequest, type RejectActionRequest, type RejectStepRequest, type RelevanceTier, type RemoveOrgMemberResponse, type RepEngagementData, type RepEngagementStats, type ReplySentiment, type ResolvedCompetitorTarget, type ResponseArtifact, type ResponseListResponse, type ResponseObject, type ResponseStatus, ResponsesResource, SEQUENCE_RATE_LIMITS, type SalaryRange, type Scope, type SelectedSkill, type SendMessageRequest, type SendMessageResponse, type SendReplyRequest, type SendResult, type SenderPersonaInput, type SequenceAction, type SequenceApprovalNeededData, type SequenceChannel, type SequenceEventType, type SequenceExecutionCompletedData, type SequenceExecutionFailedData, type SequenceRateLimitAction, type SequenceStepCompletedData, type SequenceTemplateCreate, type SequenceTemplateResponse, type SequenceTemplateUpdate, SequencesResource, SharePermission, type SkillAnalyticsRequest, type SkillEffectivenessMetrics, type SkillGuidelineBase, type SkillGuidelineCreate, type SkillGuidelineListResponse, type SkillGuidelineResponse, type SkillGuidelineUpdate, type SkillRetrievalMetadata, type SkillUsageBase, type SkillUsageCreate, type SkillUsageListResponse, type SkillUsageResponse, type SkillUsageUpdate, SkillsResource, type SkipActionRequest, type SkipStepRequest, type SkipStepResponse, type SkippedProspect, type SkippedTransferProspect, SourcesNotAvailableError, type SpecializedAgentParams, type SpecializedAgentType, type Stage, type StageFilter, type StartExecutionRequest, type StartExecutionResponse, type StepConfig, type StepExecutionItem, type StepExecutionListResponse, type StepExecutionStatus, type StepHistoryEntry, type StepMetric, type StoppedBreakdown, type StoreApiKeyRequest, type StructuredResponse, type SyncJobResponse, SyncJobStatus, SyncPhaseStatus, type SyncProspectRequest, type SyncProspectResponse, type SyncRequest, type SyncStats, type TeardownOrgResponse, type TemplateShareConfig, type TemplateShareInfo, type TemplateShareRequest, type TemplateSharesResponse, type TenantDetailsResponse, TenantInfoResource, type TenantModelPreference, type TenantModelPreferencesResponse, type TestConnectionResponse, type ThreadListResponse, type ThreadObject, type ThreadResponsesParams, ThreadsResource, type ToolInfo, type TransferProspectsRequest, type TransferProspectsResponse, type TransferSkipReason, type TransitionCondition, type TransitionConditionOperator, type TransitionConditionType, type TransitionConfig, type TransitionEventParams, type TriggerSyncResponse, UNIPILE_RATE_LIMIT_ERRORS, UNIPILE_SAFE_LIMITS, type UUID, type UnlinkConversationsResponse, type UpdateAppStatusParams, type UpdateAppStatusResponse, type UpdateDraftRequest, type UpdateLinkedInSubscriptionRequest, type UpdatePersonaRequest, type UpdatePersonaResponse, type UpdateStepExecutionRequest, type UpdateStepExecutionResponse, type UpdateThreadRequest, type UserConnectionsResponse, type UserCreateRequest, type UserDeleteResponse, type UserIdentifier, type UserListResponse, type UserResponse, type UserUpdateRequest, UsersResource, VALID_EVENT_TYPES, type ValidatedCandidate, ValidationError, type ValidationIssue, type ValidationResponse, type WebhookEvent, type WebhookPayload, canSendInmail, displayProgress, formatProgressEntry, getBestSubscriptionForAction, getConnectionRequestLimit, getContentLimit, getDailyInmailLimit, getDefaultDailyLimits, getInmailAllowance, getLimits, getMessageLimit, getRateLimit, hasOpenProfileMessages, isRecruiterSubscription, normalizeAction, verifyWebhookSignature };
7759
+ export { ACTION_DELAYS, type ActionLimit, type ActiveHours, type AddAndRunCriterionRequest, type AddCriterionRequest, type AddOrgMemberRequest, type AddOrgMemberResponse, type AddPersonaRequest, type AddPersonaResponse, type AddProspectsRequest, type AddProspectsResponse, type AgentConfig, type AgentCostStats, type ApiKeyMode, type ApiKeyModeRequest, type ApiKeyModeResponse, type ApiProvider, type AppEnabledResponse, type AppliedFilters, type ApprovalActionRequest, type ApprovalItem, type ApprovalListResponse, type ApprovalMode, type ApprovalResponse, type ApprovalSettings, type ApprovalStatus, type ApprovalsParams, type ApprovalsRequestItem, type ApprovalsResponseItem, type ApproveStepRequest, type AppsListResponse, type ArtifactObject, type ArtifactsListResponse, AuthenticationError, type BaseResource, type BatchCheckConnectionRequest, type BatchCheckPriorContactRequest, type BatchCheckPriorContactResponse, type BatchConnectionRequest, type BatchConnectionResponse, type BatchConnectionStatus, type BatchConnectionStatusResponse, type BatchDraftCompleteData, type BatchDraftCreatedData, type BatchDraftErrorData, type BatchDraftJobProgress, type BatchDraftJobResponse, type BatchDraftJobStartedData, type BatchDraftJobStatusResponse, type BatchDraftProgressData, type BatchDraftRequest, type BatchDraftResponse, type BatchDraftStreamCallbacks, type BatchDraftStreamEvent, type BatchDraftStreamEventType, type BatchExecutionInclude, type BatchExecutionRequest, type BatchExecutionResponse, BatchJobStatus, type BatchPollRequest, type BatchPollResponse, type BatchProspectIdentifier, type BatchRequestItem, type BatchRequestType, type BatchResponseItem, type BatchSendRequest, type BatchSendResponse, type BatchStepMetric, type BillingStatus, type BulkApprovalAction, type BulkApprovalFailure, type BulkApprovalRequest, type BulkApprovalResponse, type BulkCompleteFailure, type BulkCompleteRequest, type BulkCompleteResponse, type BulkDeleteRequest, type BulkDeleteResponse, type BulkOperationRequest, type BulkOperationResponse, type BulkUploadResponse, CONTENT_LIMITS, CONTENT_LIMITS_MAP, type CampaignActionListResponse, type CampaignActionResponse, type CampaignActionStatus, type CampaignActionType, type CampaignBulkApprovalAction, type CampaignBulkApprovalItem, type CampaignBulkApprovalRequest, type CampaignBulkApprovalResponse, type CampaignBulkApprovalResult, type CampaignCreate, type CampaignGuardrails, type CampaignListResponse, type CampaignMetricsResponse, type CampaignOutcomeType, type CampaignProspectDetailResponse, type CampaignProspectInput, type CampaignProspectResponse, type CampaignProspectState, type CampaignResponse, type CampaignStatus, type CampaignUpdate, CampaignsResource, type CancelDraftResponse, type CancelQueuedRequest, type CancelResponseResponse, type Channel, type ChannelContactHistory, type ChannelFunnel, type ChannelRatios, ChannelType, type CheckAppEnabledParams, type CheckLinkedInConnectionRequest, type CheckPriorContactRequest, type CheckPriorContactResponse, type ChunkingStrategy, type CompetitorPostEngagementOutput, type CompetitorRepEngagementOutput, type CompleteExecutionRequest, type CompleteExecutionResponse, type ConnectInboxRequest, type ConnectInboxResponse, type Connection, type ConnectionAcceptedData, type ConnectionCallbackRequest, type ConnectionCallbackResponse, type ConnectionInfo, type ConnectionStatus, type ConnectionStatusResponse, type ConnectionSummary, type ConnectionsResponse, type ConnectionsSyncStatus, type ContactDetailsInput, type ContactEnrichPersonInput, type ContactEnrichPersonResult, type ContactEnrichRequest, type ContactEnrichResponse, type ContactFinding, type ContactHistorySyncStatus, type ContactRelationshipProvider, type ContactRelationshipResponse, type ContactRelationshipStatus, ContactRelationshipsResource, type ContactScore, type ContentLimit, type ContentSource, type ContentType, type ConversationDetail, ConversationStatus, type ConversationSummary, type CreateDraftRequest, type CreateFeedbackRequest, type CreateFeedbackResponse, type CreateResponseRequest, type CreateResponseResponse, type CreateThreadRequest, type CriteriaClassification, type CriteriaMetadata, type CriterionDefinition, type CriterionResult, type CriterionType, type CrmContactsSyncRequest, type CrmContactsSyncResponse, type CrmContactsSyncStatusResponse, type CrmExclusionGrantListResponse, type CrmExclusionGrantRequest, type CrmExclusionGrantResponse, type CrmMatchBatchRequest, type CrmMatchBatchResponse, type CrmMatchedProspect, type CrmProvider, CrmResource, type CrmSyncProspectRequest, type CrmSyncProspectResponse, DAILY_INMAIL_LIMITS, DEFAULT_SUBSCRIPTION_TYPE, type DatabaseStatus, type DeepPeopleSearchOutput, type DeepSearchPreview, type DeepSearchStats, type DeleteApiKeyResponse, type DeleteConnectionsResponse, type DeleteConversationResponse, type DeleteConversationsByProjectResponse, type DisconnectRequest, type DisconnectResponse, type DiscoveryTrace, type DraftResponse, type DraftSendOverride, DraftStatus, type DuplicateHandling, type DuplicateTemplateRequest, type EditQueuedRequest, type Email, type EmailAction, type EmailInboxItem, type EmailInboxListResponse, type EmailInboxPersona, type EmailOnboardRequest, type EmailOnboardResponse, type EmailOnboardStatusResponse, type EmailOrgHealthResponse, type EmailOrgListResponse, type EmailOrgSettingsResponse, type EmailOrgSettingsUpdate, type EmailOrgSummary, EmailResource, type EmailSenderPersona, type EmailThreadSummary, type EngagementStatus, type EngagementStatusData, type EngagementStatusRequest, type EngagementStatusResponse, EnrichmentResource, type ErrorDetail, type ErrorResponse, type ErrorResponseItem, type EvidenceSource, type ExecutionDetailResponse, type ExecutionEvent, type ExecutionEventData, type ExecutionListResponse, type ExecutionMetricsOptions, type ExecutionMetricsResponse, type ExecutionStatus, type ExecutionSummary, type ExecutionSummaryExtended, type ExecutionsParams, type ExecutionsRequestItem, type ExecutionsResponseItem, ExternalAPIKeysResource, type ExternalApiKeyResponse, type FeedbackListResponse, type FeedbackObject, type FeedbackType, type FileAttachment, type FileChunk, type FileContentResponse, type FileListResponse, type FileMetadata, type FileScope, type FileScopeUpdateRequest, type FileSearchRequest, type FileSearchResponse, type FileSearchResult, type FileStatisticsResponse, type FileUploadResponse, FilesResource, type FilterLogic, type FilterValue, type FunnelStage, type GetConnectionStatusParams, type GetContactRelationshipsOptions, type GetToolsRequest, type GetToolsResponse, type GetUserConnectionsParams, type InboxKind, type InitiateConnectionRequest, type InitiateConnectionResponse, type InmailSubscription, IntegrationsResource, type IntentSignal, InternalServerError, LINKEDIN_LIMITS, type LifecycleOperationRequest, type LifecycleOperationResponse, type LinkAssetsRequest, type LinkedAssetsResponse, type LinkedInAccountInfoResponse, type LinkedInAccountRateLimits, type LinkedInAccountRateLimitsResponse, type LinkedInAccountRateLimitsUpdate, type LinkedInAction, type LinkedInConnectionStatus, type LinkedInCreditsResponse, type LinkedInLimitSubscriptionType, type LinkedInLimits, type LinkedInSendRequest, type LinkedInSubscriptionInfo, LinkedInSubscriptionType, type LinkedInSyncStatusResponse, type ListAcceptedConnectionsParams, type ListApprovalsOptions, type ListAssetsOptions, type ListCampaignActionsOptions, type ListCampaignProspectsOptions, type ListCampaignsOptions, type ListConnectionsParams, type ListExecutionsOptions, type ListInboxesParams, type ListPendingApprovalsOptions, type ListPlaybooksOptions, type ListProvidersResponse, type ListStepExecutionsOptions, type ListTemplatesOptions, LocalFileNotSupportedError, LumnisClient, type LumnisClientOptions, LumnisError, type LumnisErrorOptions, type MCPScope, type MCPServerCreateRequest, type MCPServerListResponse, type MCPServerResponse, type MCPServerUpdateRequest, MCPServersResource, type MCPToolListResponse, type MCPToolResponse, type MCPTransport, type MailboxUpdateRequest, type MailboxUpdateResponse, type Message, type MessageReceivedData, type MessageResponse, type MessageSentData, MessageType, MessagingAPIError, MessagingConnectionError, MessagingNotFoundError, MessagingResource, MessagingSendError, MessagingValidationError, type MetricsParams, type MetricsRequestItem, type MetricsResponseItem, type ModelAvailability, type ModelOverrides, type ModelPreferenceCreate, type ModelPreferencesBulkUpdate, ModelPreferencesResource, type ModelProvider, type ModelType, NetworkDistance, NoDataSourcesError, NotFoundError, type OnFailure, type OutcomeType, type OutreachAssetCreate, type OutreachAssetResponse, type OutreachAssetType, type OutreachAssetUpdate, OutreachMethod, OutreachResource, type OutreachSource, type OutreachStats, type PaginationInfo, type PaginationParams, type PauseResumeQueuedRequest, type PendingApprovalExtended, PeopleDataSource, PeopleResource, type PeopleSearchRequest, type PeopleSearchResponse, type PersonResult, type Plan, type PlaybookCreate, type PlaybookGenerateJobResponse, type PlaybookGenerateJobStatusResponse, type PlaybookGenerateRequest, type PlaybookResponse, type PlaybookUpdate, type PlaybookVersionResponse, type PostEngagementData, type PostEngagementProvenance, type PostEngagementType, type PostPreviewRequest, type PostPreviewResponse, type PostPreviewResult, type PostsDateRange, type PostsSearchStats, type PriorContactMessage, type ProcessingStatus, type ProcessingStatusResponse, type ProgressEntry, ProgressTracker, type ProjectApprovalsData, type ProjectExecutionsData, type ProjectMetricsData, type ProspectConnectionCheck, type ProspectInfo, type ProspectInput, type ProspectPriorContactResult, type ProspectSyncIdentifier, type ProspectSyncResult, type ProspectWarning, ProviderType, QueueItemStatus, type QuickPeopleSearchOutput, RATE_LIMIT_COOLDOWNS, type RateLimitData, RateLimitError, type RateLimitErrorOptions, type RateLimitInfo$1 as RateLimitInfo, type RateLimitStatusResponse, type RateLimitsParams, type RateLimitsRequestItem, type RateLimitsResponseItem, type RecordOutcomeRequest, type RejectActionRequest, type RejectStepRequest, type RelevanceTier, type RemoveOrgMemberResponse, type RepEngagementData, type RepEngagementStats, type ReplySentiment, type ResolvedCompetitorTarget, type ResponseArtifact, type ResponseListResponse, type ResponseObject, type ResponseStatus, ResponsesResource, SEQUENCE_RATE_LIMITS, type SalaryRange, type Scope, type SelectedSkill, type SendMessageRequest, type SendMessageResponse, type SendReplyRequest, type SendResult, type SenderPersonaInput, type SequenceAction, type SequenceApprovalNeededData, type SequenceChannel, type SequenceEventType, type SequenceExecutionCompletedData, type SequenceExecutionFailedData, type SequenceRateLimitAction, type SequenceStepCompletedData, type SequenceTemplateCreate, type SequenceTemplateResponse, type SequenceTemplateUpdate, SequencesResource, SharePermission, type SkillAnalyticsRequest, type SkillEffectivenessMetrics, type SkillGuidelineBase, type SkillGuidelineCreate, type SkillGuidelineListResponse, type SkillGuidelineResponse, type SkillGuidelineUpdate, type SkillRetrievalMetadata, type SkillUsageBase, type SkillUsageCreate, type SkillUsageListResponse, type SkillUsageResponse, type SkillUsageUpdate, SkillsResource, type SkipActionRequest, type SkipStepRequest, type SkipStepResponse, type SkippedProspect, type SkippedTransferProspect, SourcesNotAvailableError, type SpecializedAgentParams, type SpecializedAgentType, type Stage, type StageFilter, type StartExecutionRequest, type StartExecutionResponse, type StepConfig, type StepExecutionItem, type StepExecutionListResponse, type StepExecutionStatus, type StepHistoryEntry, type StepMetric, type StoppedBreakdown, type StoreApiKeyRequest, type StructuredResponse, type SyncJobResponse, SyncJobStatus, SyncPhaseStatus, type SyncProspectRequest, type SyncProspectResponse, type SyncRequest, type SyncStats, type TeardownOrgResponse, type TemplateShareConfig, type TemplateShareInfo, type TemplateShareRequest, type TemplateSharesResponse, type TenantDetailsResponse, TenantInfoResource, type TenantModelPreference, type TenantModelPreferencesResponse, type TestConnectionResponse, type ThreadListResponse, type ThreadObject, type ThreadResponsesParams, ThreadsResource, type ToolInfo, type TransferProspectsRequest, type TransferProspectsResponse, type TransferSkipReason, type TransitionCondition, type TransitionConditionOperator, type TransitionConditionType, type TransitionConfig, type TransitionEventParams, type TriggerSyncResponse, UNIPILE_RATE_LIMIT_ERRORS, UNIPILE_SAFE_LIMITS, type UUID, type UnlinkConversationsResponse, type UpdateAppStatusParams, type UpdateAppStatusResponse, type UpdateDraftRequest, type UpdateLinkedInSubscriptionRequest, type UpdatePersonaRequest, type UpdatePersonaResponse, type UpdateStepExecutionRequest, type UpdateStepExecutionResponse, type UpdateThreadRequest, type UserConnectionsResponse, type UserCreateRequest, type UserDeleteResponse, type UserIdentifier, type UserListResponse, type UserResponse, type UserUpdateRequest, UsersResource, VALID_EVENT_TYPES, type ValidatedCandidate, ValidationError, type ValidationIssue, type ValidationResponse, type WebhookEvent, type WebhookPayload, canSendInmail, displayProgress, formatProgressEntry, getBestSubscriptionForAction, getConnectionRequestLimit, getContentLimit, getDailyInmailLimit, getDefaultDailyLimits, getInmailAllowance, getLimits, getMessageLimit, getRateLimit, hasOpenProfileMessages, isRecruiterSubscription, normalizeAction, verifyWebhookSignature };
package/dist/index.mjs CHANGED
@@ -943,6 +943,9 @@ class CrmResource {
943
943
  * `crmRecordId`. Stale links (record deleted in the CRM) are detected
944
944
  * and re-created automatically.
945
945
  *
946
+ * Works with or without a `campaign_prospects` row — search-sourced
947
+ * prospects are enriched from profile cache when needed.
948
+ *
946
949
  * @example
947
950
  * ```typescript
948
951
  * const result = await client.crm.syncProspect({
@@ -962,16 +965,13 @@ class CrmResource {
962
965
  * render a "linked" indicator for the ones that come back true.
963
966
  *
964
967
  * Layered cache on the server side: persistent positive matches are
965
- * served from the `campaign_prospects.crm_record_id` column, negative
966
- * results are served from a Redis cache (TTL configured by
967
- * `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`). Only the leftover unknowns
968
- * fan out to the live CRM, bounded by
968
+ * served from the `campaign_prospects.crm_record_id` column and the
969
+ * local `crm_contacts` ledger; negative results are served from a Redis
970
+ * cache (TTL configured by `CRM_MATCH_NEGATIVE_CACHE_TTL_SECONDS`).
971
+ * Only the leftover unknowns fan out to the live CRM, bounded by
969
972
  * `CRM_MATCH_LIVE_SEARCH_PARALLELISM`.
970
973
  *
971
- * Note: HubSpot does not expose a LinkedIn-URL search field through
972
- * Composio, so for `provider: 'hubspot'` URLs that aren't already in
973
- * the persistent cache will always come back `linked: false`. The
974
- * sync endpoint still reconciles via email when available.
974
+ * Provider-id/URN inputs are resolved to vanity before matching.
975
975
  *
976
976
  * @example
977
977
  * ```typescript
@@ -988,6 +988,51 @@ class CrmResource {
988
988
  async matchBatch(data) {
989
989
  return this.http.post("/crm/prospects/match-batch", data);
990
990
  }
991
+ /**
992
+ * Trigger a full mirror of the owner's CRM contact book into the local
993
+ * `crm_contacts` ledger. Returns immediately (`202`); poll
994
+ * {@link getContactsSyncStatus} for progress.
995
+ */
996
+ async syncContacts(data) {
997
+ return this.http.post("/crm/contacts/sync", data);
998
+ }
999
+ /**
1000
+ * Ledger sync freshness for an owner+provider: connection state, whether a
1001
+ * sync is in progress, last reconcile time, and row count in the ledger.
1002
+ */
1003
+ async getContactsSyncStatus(userId, provider) {
1004
+ return this.http.get("/crm/contacts/sync-status", {
1005
+ // Backend requires snake_case query params (FastAPI `user_id`). Query
1006
+ // keys are sent verbatim by the http layer (only bodies are snake-cased),
1007
+ // so pass snake_case here like every other resource — a camelCase
1008
+ // `userId` 422s with "field required: user_id".
1009
+ params: { user_id: userId, provider }
1010
+ });
1011
+ }
1012
+ /**
1013
+ * Grant a member the right to exclude against an owner's synced CRM ledger
1014
+ * (all providers for that owner). Typically called by the FE on org join.
1015
+ */
1016
+ async grantExclusionGrant(data) {
1017
+ return this.http.post("/crm/exclusion-grants", data);
1018
+ }
1019
+ /**
1020
+ * Revoke a member's access to an owner's CRM exclusion ledger.
1021
+ */
1022
+ async revokeExclusionGrant(data) {
1023
+ return this.http.delete("/crm/exclusion-grants", {
1024
+ body: data
1025
+ });
1026
+ }
1027
+ /**
1028
+ * List CRM owners whose exclusion ledger a member may read (via grants).
1029
+ */
1030
+ async listExclusionGrants(memberUserId) {
1031
+ return this.http.get("/crm/exclusion-grants", {
1032
+ // Backend requires snake_case `member_user_id` (see getContactsSyncStatus).
1033
+ params: { member_user_id: memberUserId }
1034
+ });
1035
+ }
991
1036
  }
992
1037
 
993
1038
  class EmailResource {
@@ -3506,6 +3551,9 @@ class ResponsesResource {
3506
3551
  * @param options - Optional search parameters
3507
3552
  * @param options.limit - Maximum number of results (1-100, default: 20)
3508
3553
  * @param options.dataSources - Specific data sources to use: ["PDL", "CORESIGNAL", "CRUST_DATA"]
3554
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true (via request `options`)
3555
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
3556
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
3509
3557
  * @returns Response with structured_response containing:
3510
3558
  * - candidates: List of person results
3511
3559
  * - totalFound: Total unique candidates found
@@ -3526,6 +3574,15 @@ class ResponsesResource {
3526
3574
  params.dataSources = options.dataSources;
3527
3575
  if (Object.keys(params).length > 0)
3528
3576
  request.specializedAgentParams = params;
3577
+ const crmOptions = {};
3578
+ if (options.excludeCrmContacts !== void 0)
3579
+ crmOptions.excludeCrmContacts = options.excludeCrmContacts;
3580
+ if (options.crmExclusionOwners)
3581
+ crmOptions.crmExclusionOwners = options.crmExclusionOwners;
3582
+ if (options.crmNameCompanyMatch !== void 0)
3583
+ crmOptions.crmNameCompanyMatch = options.crmNameCompanyMatch;
3584
+ if (Object.keys(crmOptions).length > 0)
3585
+ request.options = crmOptions;
3529
3586
  }
3530
3587
  return this.create(request);
3531
3588
  }
@@ -3547,6 +3604,9 @@ class ResponsesResource {
3547
3604
  * @param options.excludeProfiles - LinkedIn URLs to exclude from results
3548
3605
  * @param options.excludePreviouslyContacted - Exclude previously contacted people
3549
3606
  * @param options.excludeNames - Names to exclude from results
3607
+ * @param options.excludeCrmContacts - Exclude people in the acting user's synced CRM ledger; @default true
3608
+ * @param options.crmExclusionOwners - Granted owner ledgers to exclude against (user id or email)
3609
+ * @param options.crmNameCompanyMatch - Also exclude by exact name+company; @default true
3550
3610
  * @param options.searchJobSignal - CrustData job-listing signal search (decision makers at hiring companies); true | false | 'auto'
3551
3611
  * @param options.deepVerify - Web verification for org/location/third-party criteria: 'auto' (default), 'always', or 'off'
3552
3612
  * @param options.deepValidationUseRelevanceReranker - SLM relevance reranker for surfaced candidates (ranking-only); @default true
@@ -3589,6 +3649,12 @@ class ResponsesResource {
3589
3649
  params.excludePreviouslyContacted = options.excludePreviouslyContacted;
3590
3650
  if (options.excludeNames)
3591
3651
  params.excludeNames = options.excludeNames;
3652
+ if (options.excludeCrmContacts !== void 0)
3653
+ params.excludeCrmContacts = options.excludeCrmContacts;
3654
+ if (options.crmExclusionOwners)
3655
+ params.crmExclusionOwners = options.crmExclusionOwners;
3656
+ if (options.crmNameCompanyMatch !== void 0)
3657
+ params.crmNameCompanyMatch = options.crmNameCompanyMatch;
3592
3658
  if (options.searchProfiles !== void 0)
3593
3659
  params.searchProfiles = options.searchProfiles;
3594
3660
  if (options.searchPosts !== void 0)
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "lumnisai",
3
3
  "type": "module",
4
- "version": "0.5.26",
4
+ "version": "0.5.28",
5
5
  "description": "Official Node.js SDK for the Lumnis AI API",
6
6
  "author": "Lumnis AI",
7
7
  "license": "MIT",