@outlit/tools 0.2.0 → 0.2.1
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 +67 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +67 -4
- package/dist/index.d.ts +67 -4
- package/dist/index.js +67 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -66,6 +66,7 @@ var customerToolNames = [
|
|
|
66
66
|
"outlit_list_facts",
|
|
67
67
|
"outlit_get_fact",
|
|
68
68
|
"outlit_get_source",
|
|
69
|
+
"outlit_list_sources",
|
|
69
70
|
"outlit_search_customer_context",
|
|
70
71
|
"outlit_query",
|
|
71
72
|
"outlit_schema",
|
|
@@ -88,7 +89,6 @@ var customerSourceTypeInputs = [
|
|
|
88
89
|
"CRM",
|
|
89
90
|
"CRM_OPPORTUNITY"
|
|
90
91
|
];
|
|
91
|
-
var notificationProviderValues = ["slack"];
|
|
92
92
|
var customerToolContracts = {
|
|
93
93
|
outlit_list_customers: {
|
|
94
94
|
toolName: "outlit_list_customers",
|
|
@@ -493,6 +493,69 @@ var customerToolContracts = {
|
|
|
493
493
|
additionalProperties: false
|
|
494
494
|
}
|
|
495
495
|
},
|
|
496
|
+
outlit_list_sources: {
|
|
497
|
+
toolName: "outlit_list_sources",
|
|
498
|
+
description: "List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, or opportunities.",
|
|
499
|
+
inputSchema: {
|
|
500
|
+
$schema: "https://json-schema.org/draft/2020-12/schema",
|
|
501
|
+
type: "object",
|
|
502
|
+
properties: {
|
|
503
|
+
sourceType: {
|
|
504
|
+
description: "Generic source type to list.",
|
|
505
|
+
type: "string",
|
|
506
|
+
enum: customerSourceTypeInputs
|
|
507
|
+
},
|
|
508
|
+
customer: {
|
|
509
|
+
description: "Customer ID, domain, or name to scope source listing.",
|
|
510
|
+
type: "string",
|
|
511
|
+
minLength: 1,
|
|
512
|
+
maxLength: 200
|
|
513
|
+
},
|
|
514
|
+
after: {
|
|
515
|
+
description: "ISO 8601 datetime lower bound.",
|
|
516
|
+
type: "string",
|
|
517
|
+
format: "date-time",
|
|
518
|
+
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
|
519
|
+
},
|
|
520
|
+
before: {
|
|
521
|
+
description: "ISO 8601 datetime upper bound.",
|
|
522
|
+
type: "string",
|
|
523
|
+
format: "date-time",
|
|
524
|
+
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
|
525
|
+
},
|
|
526
|
+
participant: {
|
|
527
|
+
description: "Participant email or name to filter source records.",
|
|
528
|
+
type: "string",
|
|
529
|
+
minLength: 1,
|
|
530
|
+
maxLength: 500
|
|
531
|
+
},
|
|
532
|
+
provider: {
|
|
533
|
+
description: "Provider identifier such as gmail, gong, or google-calendar.",
|
|
534
|
+
type: "string",
|
|
535
|
+
minLength: 1,
|
|
536
|
+
maxLength: 200
|
|
537
|
+
},
|
|
538
|
+
hasTranscript: {
|
|
539
|
+
description: "Filter call sources by transcript presence.",
|
|
540
|
+
type: "boolean"
|
|
541
|
+
},
|
|
542
|
+
limit: {
|
|
543
|
+
description: "Results per page.",
|
|
544
|
+
default: 50,
|
|
545
|
+
type: "integer",
|
|
546
|
+
minimum: 1,
|
|
547
|
+
maximum: 100
|
|
548
|
+
},
|
|
549
|
+
cursor: {
|
|
550
|
+
description: "Pagination cursor.",
|
|
551
|
+
type: "string",
|
|
552
|
+
minLength: 1,
|
|
553
|
+
maxLength: 2e3
|
|
554
|
+
}
|
|
555
|
+
},
|
|
556
|
+
additionalProperties: false
|
|
557
|
+
}
|
|
558
|
+
},
|
|
496
559
|
outlit_search_customer_context: {
|
|
497
560
|
toolName: "outlit_search_customer_context",
|
|
498
561
|
description: "Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.",
|
|
@@ -646,7 +709,7 @@ var customerToolContracts = {
|
|
|
646
709
|
provider: {
|
|
647
710
|
description: "Notification provider",
|
|
648
711
|
type: "string",
|
|
649
|
-
enum:
|
|
712
|
+
enum: ["slack"]
|
|
650
713
|
},
|
|
651
714
|
channelId: {
|
|
652
715
|
description: "Provider-specific destination channel ID",
|
|
@@ -765,6 +828,7 @@ var customerIncludeSections = [
|
|
|
765
828
|
"behaviorMetrics"
|
|
766
829
|
];
|
|
767
830
|
var customerTimeframes = ["7d", "14d", "30d", "90d"];
|
|
831
|
+
var notificationProviderValues = ["slack"];
|
|
768
832
|
var notificationSeverityValues = ["low", "medium", "high"];
|
|
769
833
|
var timelineChannels = [
|
|
770
834
|
"SDK",
|
|
@@ -787,7 +851,7 @@ var userJourneyStages = [
|
|
|
787
851
|
];
|
|
788
852
|
var userListOrderFields = ["last_activity_at", "first_seen_at", "email"];
|
|
789
853
|
var schemaTables = ["activity", "customers", "users", "revenue"];
|
|
790
|
-
var customerToolContractHash = "
|
|
854
|
+
var customerToolContractHash = "5016d146842452855bfdd9ecc8f6be1a122125d0c392ceff315aeb2e44fefc7f";
|
|
791
855
|
var customerToolNameSet = new Set(customerToolNames);
|
|
792
856
|
var customerSourceTypeSet = new Set(customerSourceTypes);
|
|
793
857
|
var customerSourceTypeAliasMap = /* @__PURE__ */ new Map([
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts","../src/contracts.ts","../src/client.ts","../src/toolsets.ts"],"sourcesContent":["export type { OutlitToolsClient, OutlitToolsClientOptions, OutlitToolsFetch } from \"./client.js\"\nexport { createOutlitClient, DEFAULT_OUTLIT_API_URL } from \"./client.js\"\nexport type {\n CustomerContextSearchInput,\n CustomerSourceType,\n CustomerSourceTypeInput,\n CustomerToolContract,\n CustomerToolName,\n JsonSchema,\n SearchArgsLike,\n} from \"./contracts.js\"\nexport {\n customerActivityWindows,\n customerBillingStatuses,\n customerFactCategories,\n customerFactIncludes,\n customerFactStatuses,\n customerFactTypes,\n customerIncludeSections,\n customerListOrderFields,\n customerSourceTypeAliases,\n customerSourceTypeInputs,\n customerSourceTypes,\n customerTimeframes,\n customerToolContractHash,\n customerToolContracts,\n customerToolNames,\n getCustomerToolContract,\n isCustomerToolName,\n normalizeCustomerSourceType,\n notificationProviderValues,\n notificationSeverityValues,\n resolveCustomerContextSearchInput,\n schemaTables,\n timelineChannels,\n timelineTimeframes,\n unsupportedCustomerFactTypes,\n userJourneyStages,\n userListOrderFields,\n} from \"./contracts.js\"\n\nexport {\n actionToolNames,\n allCustomerToolNames,\n analyticalAgentToolNames,\n defaultAgentToolNames,\n sqlToolNames,\n} from \"./toolsets.js\"\n","export type JsonSchema = {\n readonly [key: string]: unknown\n}\n\nexport const customerToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_search_customer_context\",\n \"outlit_query\",\n \"outlit_schema\",\n \"outlit_send_notification\",\n] as const\n\nexport const customerSourceTypes = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n] as const\n\nexport const customerSourceTypeAliases = [\"CRM\", \"CRM_OPPORTUNITY\"] as const\n\nexport const customerSourceTypeInputs = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n \"CRM\",\n \"CRM_OPPORTUNITY\",\n] as const\n\nexport const notificationProviderValues = [\"slack\"] as const\n\nexport const customerToolContracts = {\n outlit_list_customers: {\n toolName: \"outlit_list_customers\",\n description:\n \"Browse and filter customers. Use this to find customers by billing status, activity recency, revenue, or name. Returns a paginated list with summary info (MRR, last activity, status).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n billingStatus: {\n description: \"Filter by billing status\",\n type: \"string\",\n enum: [\"NONE\", \"TRIALING\", \"PAYING\", \"PAST_DUE\", \"CHURNED\"],\n },\n hasActivityInLast: {\n description: \"Filter customers with activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n noActivityInLast: {\n description: \"Filter customers with NO activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n mrrAbove: {\n description: \"Minimum MRR in cents (e.g., 10000 = $100)\",\n type: \"number\",\n minimum: 0,\n },\n mrrBelow: {\n description: \"Maximum MRR in cents\",\n type: \"number\",\n minimum: 0,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n search: {\n description: \"Search by customer name or domain (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order results by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"name\", \"mrr_cents\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_list_users: {\n toolName: \"outlit_list_users\",\n description:\n \"Browse and filter users. Use this to find users by journey stage, activity recency, customer, or email/name. Returns a paginated list with activity info.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n journeyStage: {\n description: \"Filter by user journey stage\",\n type: \"string\",\n enum: [\"DISCOVERED\", \"SIGNED_UP\", \"ACTIVATED\", \"ENGAGED\", \"INACTIVE\"],\n },\n customerId: {\n description: \"Filter users by customer ID\",\n type: \"string\",\n maxLength: 500,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n hasActivityInLast: {\n description:\n \"Filter users active within this window. Format: Nd, Nh, or Nm (e.g., '7d', '24h', '90m')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n noActivityInLast: {\n description:\n \"Filter users NOT active within this window. Format: Nd, Nh, or Nm (e.g., '30d', '2h')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n search: {\n description: \"Search by user email or name (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"email\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_get_customer: {\n toolName: \"outlit_get_customer\",\n description:\n \"Get full details for a single customer. Use this when you already know which customer you want to inspect. Optionally include related data (users, revenue, recent activity, engagement metrics).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID, domain, or name to look up\",\n },\n include: {\n description: \"Additional data sections to include in the response\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"users\", \"revenue\", \"recentTimeline\", \"behaviorMetrics\"],\n },\n },\n timeframe: {\n description: \"Timeframe for timeline and behavior metrics (default: 30d)\",\n default: \"30d\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_timeline: {\n toolName: \"outlit_get_timeline\",\n description:\n \"Get the chronological activity timeline for a customer. Use this to see what happened and when — emails, calls, Slack messages, billing events, etc. Supports channel and date filtering.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n channels: {\n description: \"Filter by event channel (e.g., EMAIL, SLACK, CALL, CALENDAR)\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n ],\n },\n },\n eventTypes: {\n description: \"Filter by event type\",\n type: \"array\",\n items: {\n type: \"string\",\n },\n },\n timeframe: {\n description:\n \"Relative time window (default: 30d). Cannot be used with startDate/endDate.\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"],\n },\n startDate: {\n description:\n \"Start of time window (ISO 8601, e.g. '2025-01-01T00:00:00Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n endDate: {\n description:\n \"End of time window (ISO 8601, e.g. '2025-01-31T23:59:59Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_list_facts: {\n toolName: \"outlit_list_facts\",\n description:\n \"List structured facts known about a customer. Use filters like status, sourceTypes, factTypes, factCategories, and date bounds to narrow the result set. For topic-specific retrieval, use outlit_search_customer_context instead.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n status: {\n description: \"Optional fact status filter\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"ACTIVE\", \"ACKNOWLEDGED\", \"RESOLVED\", \"SNOOZED\", \"CANDIDATE\"],\n },\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict fact results to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n factTypes: {\n description:\n \"Optional customer-memory fact type filters, such as CHURN_RISK, EXPANSION, SENTIMENT, or BUDGET. Anomaly detector fact types are not supported.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n ],\n },\n },\n factCategories: {\n description: \"Optional public fact category filters. Supported values: MEMORY, CUSTOM.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"MEMORY\", \"CUSTOM\"],\n },\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 100)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 100,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_fact: {\n toolName: \"outlit_get_fact\",\n description:\n \"Get one exact fact by ID. Returns the canonical fact shape and optionally expands requested related data such as evidence.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n factId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n description: \"Exact fact ID to retrieve\",\n },\n include: {\n description:\n \"Optional best-effort expansions. Use include=['evidence'] to request evidence when available; unsupported include values are ignored.\",\n type: \"array\",\n items: {\n type: \"string\",\n minLength: 1,\n maxLength: 100,\n },\n },\n },\n required: [\"factId\"],\n additionalProperties: false,\n },\n },\n outlit_get_source: {\n toolName: \"outlit_get_source\",\n description:\n \"Get one exact source record by generic sourceType and sourceId. Use this when you already know the concrete underlying source you want to inspect.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sourceType: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n sourceId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n },\n required: [\"sourceType\", \"sourceId\"],\n additionalProperties: false,\n },\n },\n outlit_search_customer_context: {\n toolName: \"outlit_search_customer_context\",\n description:\n \"Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n description: \"Customer ID, domain, or name. Omit to search across all customers.\",\n anyOf: [\n {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n {\n type: \"null\",\n },\n ],\n },\n query: {\n type: \"string\",\n minLength: 2,\n maxLength: 2000,\n description: \"Natural language query or topic to search for.\",\n },\n topK: {\n description: \"Maximum number of artifact results to return (default 20).\",\n type: \"integer\",\n minimum: 1,\n maximum: 50,\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict the search to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n },\n required: [\"query\"],\n additionalProperties: false,\n },\n },\n outlit_query: {\n toolName: \"outlit_query\",\n description:\n \"Execute read-only SQL queries against your analytics views.\\n\\nAvailable views:\\n- activity: Customer activity events (event_name, event_type, event_channel, customer_id, occurred_at, properties, ...)\\n- customers: Customer attributes (customer_id, domain, name, billing_status, plan, mrr_cents, traits, ...)\\n- users: User attributes (user_id, email, name, customer_id, traits, ...)\\n- revenue: Revenue snapshots over time (customer_id, snapshot_date, mrr_cents, ...)\\n\\nAll queries are automatically filtered to your organization's data.\\nOnly SELECT queries are allowed.\\nProperties and traits are JSON strings; inspect schemas and examples before filtering nested values.\\n\\nExample queries:\\n- SELECT event_name, count(*) FROM activity GROUP BY 1 ORDER BY 2 DESC LIMIT 10\\n- SELECT billing_status, sum(mrr_cents)/100 as mrr FROM customers GROUP BY 1\\n- SELECT * FROM activity WHERE customer_id = 'cust_123' ORDER BY occurred_at DESC LIMIT 50\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sql: {\n type: \"string\",\n description: \"SQL SELECT query to execute\",\n },\n limit: {\n description: \"Max rows to return (default 1000, max 10000)\",\n default: 1000,\n type: \"integer\",\n minimum: 1,\n maximum: 10000,\n },\n },\n required: [\"sql\"],\n additionalProperties: false,\n },\n },\n outlit_schema: {\n toolName: \"outlit_schema\",\n description:\n \"Get schemas for available analytics views.\\n\\nUse this to discover column names, types, and descriptions before writing SQL queries.\\nReturns column definitions and example queries for each view.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n table: {\n description: \"Specific analytics view to describe. Omit to list all views.\",\n type: \"string\",\n enum: [\"activity\", \"customers\", \"users\", \"revenue\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_send_notification: {\n toolName: \"outlit_send_notification\",\n description:\n \"Send or post a notification. Use only when the user explicitly asks you to send, post, or notify. Slack is the default notifier when destinations are omitted.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n title: {\n type: \"string\",\n minLength: 1,\n maxLength: 160,\n description: \"Notification title\",\n },\n markdown: {\n description: \"Markdown notification body rendered for the target provider\",\n type: \"string\",\n minLength: 1,\n maxLength: 100000,\n },\n payload: {\n description:\n \"Optional JSON-compatible payload. Serialized size must be 100,000 characters or fewer.\",\n $ref: \"#/$defs/__schema0\",\n },\n message: {\n description: \"Optional summary message\",\n type: \"string\",\n minLength: 1,\n maxLength: 1200,\n },\n severity: {\n description: \"Optional notification severity\",\n type: \"string\",\n enum: [\"low\", \"medium\", \"high\"],\n },\n source: {\n description: \"Optional source label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n subject: {\n description: \"Optional subject line\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n destinations: {\n description:\n \"Optional explicit notification destinations. Omit to use the default notifier.\",\n minItems: 1,\n maxItems: 10,\n type: \"array\",\n items: {\n type: \"object\",\n properties: {\n provider: {\n description: \"Notification provider\",\n type: \"string\",\n enum: notificationProviderValues,\n },\n channelId: {\n description: \"Provider-specific destination channel ID\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n label: {\n description: \"Optional destination label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n },\n required: [\"provider\"],\n additionalProperties: false,\n },\n },\n },\n required: [\"title\"],\n additionalProperties: false,\n $defs: {\n __schema0: {\n anyOf: [\n {\n type: \"string\",\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n {\n type: \"null\",\n },\n {\n type: \"array\",\n items: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n {\n type: \"object\",\n propertyNames: {\n type: \"string\",\n },\n additionalProperties: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n ],\n },\n },\n },\n },\n} as const\n\nexport const customerBillingStatuses = [\n \"NONE\",\n \"TRIALING\",\n \"PAYING\",\n \"PAST_DUE\",\n \"CHURNED\",\n] as const\n\nexport const customerActivityWindows = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const customerFactStatuses = [\n \"ACTIVE\",\n \"ACKNOWLEDGED\",\n \"RESOLVED\",\n \"SNOOZED\",\n \"CANDIDATE\",\n] as const\n\nexport const customerFactIncludes = [\"evidence\"] as const\n\nexport const customerFactTypes = [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n] as const\n\nexport const unsupportedCustomerFactTypes = [\n \"TRACKING_GAP\",\n \"SCHEMA_DRIFT\",\n \"INGESTION_LAG\",\n \"ACTIVATION_RATE_DROP\",\n \"FUNNEL_DROPOFF\",\n \"CORE_ACTION_DECAY\",\n \"CADENCE_BREAK\",\n \"QUIET_ACCOUNT\",\n \"CHAMPION_AT_RISK\",\n \"SEGMENT_DIVERGENCE\",\n] as const\n\nexport const customerFactCategories = [\"MEMORY\", \"CUSTOM\"] as const\n\nexport const customerListOrderFields = [\n \"last_activity_at\",\n \"first_seen_at\",\n \"name\",\n \"mrr_cents\",\n] as const\n\nexport const customerIncludeSections = [\n \"users\",\n \"revenue\",\n \"recentTimeline\",\n \"behaviorMetrics\",\n] as const\n\nexport const customerTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const notificationSeverityValues = [\"low\", \"medium\", \"high\"] as const\n\nexport const timelineChannels = [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n] as const\n\nexport const timelineTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"] as const\n\nexport const userJourneyStages = [\n \"DISCOVERED\",\n \"SIGNED_UP\",\n \"ACTIVATED\",\n \"ENGAGED\",\n \"INACTIVE\",\n] as const\n\nexport const userListOrderFields = [\"last_activity_at\", \"first_seen_at\", \"email\"] as const\n\nexport const schemaTables = [\"activity\", \"customers\", \"users\", \"revenue\"] as const\n\nexport const customerToolContractHash =\n \"006ce091382509c3224815c4f6ead4c5e78e34f54df281fe8f143811890b04af\" as const\n\nexport type CustomerToolName = (typeof customerToolNames)[number]\nexport type CustomerSourceType = (typeof customerSourceTypes)[number]\nexport type CustomerSourceTypeInput = (typeof customerSourceTypeInputs)[number]\n\nexport type CustomerToolContract = {\n toolName: CustomerToolName\n description: string\n inputSchema: JsonSchema\n}\n\nconst customerToolNameSet = new Set<string>(customerToolNames)\nconst customerSourceTypeSet = new Set<string>(customerSourceTypes)\nconst customerSourceTypeAliasMap = new Map<\n (typeof customerSourceTypeAliases)[number],\n CustomerSourceType\n>([\n [\"CRM\", \"OPPORTUNITY\"],\n [\"CRM_OPPORTUNITY\", \"OPPORTUNITY\"],\n])\nconst iso8601UtcDateTimeRegex =\n /^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$/\n\nexport function isCustomerToolName(value: string): value is CustomerToolName {\n return customerToolNameSet.has(value)\n}\n\nexport function getCustomerToolContract(name: CustomerToolName): CustomerToolContract {\n return customerToolContracts[name]\n}\n\nexport function normalizeCustomerSourceType(value: string): CustomerSourceType | null {\n const normalized = value.trim().toUpperCase()\n if (customerSourceTypeSet.has(normalized)) {\n return normalized as CustomerSourceType\n }\n\n return (\n customerSourceTypeAliasMap.get(normalized as (typeof customerSourceTypeAliases)[number]) ?? null\n )\n}\n\nexport type SearchArgsLike = {\n query?: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: string[]\n}\n\nexport type CustomerContextSearchInput = {\n query: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: CustomerSourceType[]\n}\n\nexport function resolveCustomerContextSearchInput(value: SearchArgsLike):\n | { ok: true; request: CustomerContextSearchInput }\n | {\n ok: false\n message: string\n } {\n if (!value.query) {\n return {\n ok: false,\n message: \"A query argument is required\",\n }\n }\n\n const normalizedQuery = value.query.trim()\n if (normalizedQuery.length < 2) {\n return {\n ok: false,\n message: \"Query must be at least 2 non-whitespace characters\",\n }\n }\n\n if (value.after !== undefined && !iso8601UtcDateTimeRegex.test(value.after)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n const afterTime = value.after === undefined ? undefined : new Date(value.after).getTime()\n if (afterTime !== undefined && Number.isNaN(afterTime)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n if (value.before !== undefined && !iso8601UtcDateTimeRegex.test(value.before)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n const beforeTime = value.before === undefined ? undefined : new Date(value.before).getTime()\n if (beforeTime !== undefined && Number.isNaN(beforeTime)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n if (afterTime !== undefined && beforeTime !== undefined && afterTime > beforeTime) {\n return {\n ok: false,\n message: \"--after must be before or equal to --before\",\n }\n }\n\n const invalidSourceTypes =\n value.sourceTypes?.filter((sourceType) => !normalizeCustomerSourceType(sourceType)) ?? []\n if (invalidSourceTypes.length > 0) {\n return {\n ok: false,\n message: `Unknown source types: ${invalidSourceTypes.join(\", \")}. Allowed: ${customerSourceTypeInputs.join(\", \")}`,\n }\n }\n\n const normalizedSourceTypes = value.sourceTypes\n ? Array.from(\n new Set(value.sourceTypes.map((sourceType) => normalizeCustomerSourceType(sourceType))),\n ).filter((sourceType): sourceType is CustomerSourceType => sourceType !== null)\n : undefined\n\n return {\n ok: true,\n request: {\n query: normalizedQuery,\n customer: value.customer,\n topK: value.topK,\n after: value.after,\n before: value.before,\n sourceTypes: normalizedSourceTypes,\n },\n }\n}\n","import { type CustomerToolName, isCustomerToolName } from \"./contracts.js\"\n\nexport const DEFAULT_OUTLIT_API_URL = \"https://app.outlit.ai\"\n\nexport type OutlitToolsFetch = (\n input: string | URL | Request,\n init?: RequestInit,\n) => Promise<Response>\n\nexport type OutlitToolsClientOptions = {\n apiKey: string\n baseUrl?: string\n fetch?: OutlitToolsFetch\n}\n\nexport type OutlitToolsClient = {\n key: string\n baseUrl: string\n callTool(toolName: CustomerToolName, input?: Record<string, unknown>): Promise<unknown>\n}\n\nexport function createOutlitClient(options: OutlitToolsClientOptions): OutlitToolsClient {\n const key = options.apiKey.trim()\n const baseUrl = options.baseUrl ?? DEFAULT_OUTLIT_API_URL\n const fetchImpl = options.fetch ?? globalThis.fetch\n\n if (!key) {\n throw new Error(\"apiKey is required\")\n }\n\n if (!fetchImpl) {\n throw new Error(\"fetch is not available\")\n }\n\n return {\n key,\n baseUrl,\n async callTool(toolName, input = {}) {\n if (!isCustomerToolName(toolName)) {\n throw new Error(`Unknown customer tool: ${toolName}`)\n }\n\n const response = await fetchImpl(new URL(\"/api/tools/call\", baseUrl).toString(), {\n method: \"POST\",\n headers: {\n Authorization: `Bearer ${key}`,\n \"Content-Type\": \"application/json\",\n },\n body: JSON.stringify({\n tool: toolName,\n input,\n }),\n })\n\n if (!response.ok) {\n const text = await response.text()\n throw new Error(`API error (${response.status}): ${text}`)\n }\n\n return response.json()\n },\n }\n}\n","import { type CustomerToolName, customerToolNames } from \"./contracts.js\"\n\nexport const actionToolNames = [\n \"outlit_send_notification\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const defaultAgentToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_search_customer_context\",\n ...actionToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const sqlToolNames = [\n \"outlit_schema\",\n \"outlit_query\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const analyticalAgentToolNames = [\n ...defaultAgentToolNames,\n ...sqlToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const allCustomerToolNames = customerToolNames\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACIO,IAAM,oBAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,sBAAsB;AAAA,EACjC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,4BAA4B,CAAC,OAAO,iBAAiB;AAE3D,IAAM,2BAA2B;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,6BAA6B,CAAC,OAAO;AAE3C,IAAM,wBAAwB;AAAA,EACnC,uBAAuB;AAAA,IACrB,UAAU;AAAA,IACV,aACE;AAAA,IACF,aAAa;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AAI,CAAC,KAAK;AACR,UAAM,IAAI,MAAM,oBAAoB;AAAA,EACtC;AAEA,MAAI,CAAC,WAAW;AACd,UAAM,IAAI,MAAM,wBAAwB;AAAA,EAC1C;AAEA,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA,MAAM,SAAS,UAAU,QAAQ,CAAC,GAAG;AACnC,UAAI,CAAC,mBAAmB,QAAQ,GAAG;AACjC,cAAM,IAAI,MAAM,0BAA0B,QAAQ,EAAE;AAAA,MACtD;AAEA,YAAM,WAAW,MAAM,UAAU,IAAI,IAAI,mBAAmB,OAAO,EAAE,SAAS,GAAG;AAAA,QAC/E,QAAQ;AAAA,QACR,SAAS;AAAA,UACP,eAAe,UAAU,GAAG;AAAA,UAC5B,gBAAgB;AAAA,QAClB;AAAA,QACA,MAAM,KAAK,UAAU;AAAA,UACnB,MAAM;AAAA,UACN;AAAA,QACF,CAAC;AAAA,MACH,CAAC;AAED,UAAI,CAAC,SAAS,IAAI;AAChB,cAAM,OAAO,MAAM,SAAS,KAAK;AACjC,cAAM,IAAI,MAAM,cAAc,SAAS,MAAM,MAAM,IAAI,EAAE;AAAA,MAC3D;AAEA,aAAO,SAAS,KAAK;AAAA,IACvB;AAAA,EACF;AACF;;;AC5DO,IAAM,kBAAkB;AAAA,EAC7B;AACF;AAEO,IAAM,wBAAwB;AAAA,EACnC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL;AAEO,IAAM,eAAe;AAAA,EAC1B;AAAA,EACA;AACF;AAEO,IAAM,2BAA2B;AAAA,EACtC,GAAG;AAAA,EACH,GAAG;AACL;AAEO,IAAM,uBAAuB;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts","../src/contracts.ts","../src/client.ts","../src/toolsets.ts"],"sourcesContent":["export type { OutlitToolsClient, OutlitToolsClientOptions, OutlitToolsFetch } from \"./client.js\"\nexport { createOutlitClient, DEFAULT_OUTLIT_API_URL } from \"./client.js\"\nexport type {\n CustomerContextSearchInput,\n CustomerSourceType,\n CustomerSourceTypeInput,\n CustomerToolContract,\n CustomerToolName,\n JsonSchema,\n SearchArgsLike,\n} from \"./contracts.js\"\nexport {\n customerActivityWindows,\n customerBillingStatuses,\n customerFactCategories,\n customerFactIncludes,\n customerFactStatuses,\n customerFactTypes,\n customerIncludeSections,\n customerListOrderFields,\n customerSourceTypeAliases,\n customerSourceTypeInputs,\n customerSourceTypes,\n customerTimeframes,\n customerToolContractHash,\n customerToolContracts,\n customerToolNames,\n getCustomerToolContract,\n isCustomerToolName,\n normalizeCustomerSourceType,\n notificationProviderValues,\n notificationSeverityValues,\n resolveCustomerContextSearchInput,\n schemaTables,\n timelineChannels,\n timelineTimeframes,\n unsupportedCustomerFactTypes,\n userJourneyStages,\n userListOrderFields,\n} from \"./contracts.js\"\n\nexport {\n actionToolNames,\n allCustomerToolNames,\n analyticalAgentToolNames,\n defaultAgentToolNames,\n sqlToolNames,\n} from \"./toolsets.js\"\n","export type JsonSchema = {\n readonly [key: string]: unknown\n}\n\nexport const customerToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_list_sources\",\n \"outlit_search_customer_context\",\n \"outlit_query\",\n \"outlit_schema\",\n \"outlit_send_notification\",\n] as const\n\nexport const customerSourceTypes = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n] as const\n\nexport const customerSourceTypeAliases = [\"CRM\", \"CRM_OPPORTUNITY\"] as const\n\nexport const customerSourceTypeInputs = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n \"CRM\",\n \"CRM_OPPORTUNITY\",\n] as const\n\nexport const customerToolContracts = {\n outlit_list_customers: {\n toolName: \"outlit_list_customers\",\n description:\n \"Browse and filter customers. Use this to find customers by billing status, activity recency, revenue, or name. Returns a paginated list with summary info (MRR, last activity, status).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n billingStatus: {\n description: \"Filter by billing status\",\n type: \"string\",\n enum: [\"NONE\", \"TRIALING\", \"PAYING\", \"PAST_DUE\", \"CHURNED\"],\n },\n hasActivityInLast: {\n description: \"Filter customers with activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n noActivityInLast: {\n description: \"Filter customers with NO activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n mrrAbove: {\n description: \"Minimum MRR in cents (e.g., 10000 = $100)\",\n type: \"number\",\n minimum: 0,\n },\n mrrBelow: {\n description: \"Maximum MRR in cents\",\n type: \"number\",\n minimum: 0,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n search: {\n description: \"Search by customer name or domain (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order results by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"name\", \"mrr_cents\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_list_users: {\n toolName: \"outlit_list_users\",\n description:\n \"Browse and filter users. Use this to find users by journey stage, activity recency, customer, or email/name. Returns a paginated list with activity info.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n journeyStage: {\n description: \"Filter by user journey stage\",\n type: \"string\",\n enum: [\"DISCOVERED\", \"SIGNED_UP\", \"ACTIVATED\", \"ENGAGED\", \"INACTIVE\"],\n },\n customerId: {\n description: \"Filter users by customer ID\",\n type: \"string\",\n maxLength: 500,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n hasActivityInLast: {\n description:\n \"Filter users active within this window. Format: Nd, Nh, or Nm (e.g., '7d', '24h', '90m')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n noActivityInLast: {\n description:\n \"Filter users NOT active within this window. Format: Nd, Nh, or Nm (e.g., '30d', '2h')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n search: {\n description: \"Search by user email or name (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"email\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_get_customer: {\n toolName: \"outlit_get_customer\",\n description:\n \"Get full details for a single customer. Use this when you already know which customer you want to inspect. Optionally include related data (users, revenue, recent activity, engagement metrics).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID, domain, or name to look up\",\n },\n include: {\n description: \"Additional data sections to include in the response\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"users\", \"revenue\", \"recentTimeline\", \"behaviorMetrics\"],\n },\n },\n timeframe: {\n description: \"Timeframe for timeline and behavior metrics (default: 30d)\",\n default: \"30d\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_timeline: {\n toolName: \"outlit_get_timeline\",\n description:\n \"Get the chronological activity timeline for a customer. Use this to see what happened and when — emails, calls, Slack messages, billing events, etc. Supports channel and date filtering.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n channels: {\n description: \"Filter by event channel (e.g., EMAIL, SLACK, CALL, CALENDAR)\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n ],\n },\n },\n eventTypes: {\n description: \"Filter by event type\",\n type: \"array\",\n items: {\n type: \"string\",\n },\n },\n timeframe: {\n description:\n \"Relative time window (default: 30d). Cannot be used with startDate/endDate.\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"],\n },\n startDate: {\n description:\n \"Start of time window (ISO 8601, e.g. '2025-01-01T00:00:00Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n endDate: {\n description:\n \"End of time window (ISO 8601, e.g. '2025-01-31T23:59:59Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_list_facts: {\n toolName: \"outlit_list_facts\",\n description:\n \"List structured facts known about a customer. Use filters like status, sourceTypes, factTypes, factCategories, and date bounds to narrow the result set. For topic-specific retrieval, use outlit_search_customer_context instead.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n status: {\n description: \"Optional fact status filter\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"ACTIVE\", \"ACKNOWLEDGED\", \"RESOLVED\", \"SNOOZED\", \"CANDIDATE\"],\n },\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict fact results to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n factTypes: {\n description:\n \"Optional customer-memory fact type filters, such as CHURN_RISK, EXPANSION, SENTIMENT, or BUDGET. Anomaly detector fact types are not supported.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n ],\n },\n },\n factCategories: {\n description: \"Optional public fact category filters. Supported values: MEMORY, CUSTOM.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"MEMORY\", \"CUSTOM\"],\n },\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 100)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 100,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_fact: {\n toolName: \"outlit_get_fact\",\n description:\n \"Get one exact fact by ID. Returns the canonical fact shape and optionally expands requested related data such as evidence.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n factId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n description: \"Exact fact ID to retrieve\",\n },\n include: {\n description:\n \"Optional best-effort expansions. Use include=['evidence'] to request evidence when available; unsupported include values are ignored.\",\n type: \"array\",\n items: {\n type: \"string\",\n minLength: 1,\n maxLength: 100,\n },\n },\n },\n required: [\"factId\"],\n additionalProperties: false,\n },\n },\n outlit_get_source: {\n toolName: \"outlit_get_source\",\n description:\n \"Get one exact source record by generic sourceType and sourceId. Use this when you already know the concrete underlying source you want to inspect.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sourceType: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n sourceId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n },\n required: [\"sourceType\", \"sourceId\"],\n additionalProperties: false,\n },\n },\n outlit_list_sources: {\n toolName: \"outlit_list_sources\",\n description:\n \"List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, or opportunities.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sourceType: {\n description: \"Generic source type to list.\",\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n customer: {\n description: \"Customer ID, domain, or name to scope source listing.\",\n type: \"string\",\n minLength: 1,\n maxLength: 200,\n },\n after: {\n description: \"ISO 8601 datetime lower bound.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n participant: {\n description: \"Participant email or name to filter source records.\",\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n provider: {\n description: \"Provider identifier such as gmail, gong, or google-calendar.\",\n type: \"string\",\n minLength: 1,\n maxLength: 200,\n },\n hasTranscript: {\n description: \"Filter call sources by transcript presence.\",\n type: \"boolean\",\n },\n limit: {\n description: \"Results per page.\",\n default: 50,\n type: \"integer\",\n minimum: 1,\n maximum: 100,\n },\n cursor: {\n description: \"Pagination cursor.\",\n type: \"string\",\n minLength: 1,\n maxLength: 2000,\n },\n },\n additionalProperties: false,\n },\n },\n outlit_search_customer_context: {\n toolName: \"outlit_search_customer_context\",\n description:\n \"Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n description: \"Customer ID, domain, or name. Omit to search across all customers.\",\n anyOf: [\n {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n {\n type: \"null\",\n },\n ],\n },\n query: {\n type: \"string\",\n minLength: 2,\n maxLength: 2000,\n description: \"Natural language query or topic to search for.\",\n },\n topK: {\n description: \"Maximum number of artifact results to return (default 20).\",\n type: \"integer\",\n minimum: 1,\n maximum: 50,\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict the search to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n },\n required: [\"query\"],\n additionalProperties: false,\n },\n },\n outlit_query: {\n toolName: \"outlit_query\",\n description:\n \"Execute read-only SQL queries against your analytics views.\\n\\nAvailable views:\\n- activity: Customer activity events (event_name, event_type, event_channel, customer_id, occurred_at, properties, ...)\\n- customers: Customer attributes (customer_id, domain, name, billing_status, plan, mrr_cents, traits, ...)\\n- users: User attributes (user_id, email, name, customer_id, traits, ...)\\n- revenue: Revenue snapshots over time (customer_id, snapshot_date, mrr_cents, ...)\\n\\nAll queries are automatically filtered to your organization's data.\\nOnly SELECT queries are allowed.\\nProperties and traits are JSON strings; inspect schemas and examples before filtering nested values.\\n\\nExample queries:\\n- SELECT event_name, count(*) FROM activity GROUP BY 1 ORDER BY 2 DESC LIMIT 10\\n- SELECT billing_status, sum(mrr_cents)/100 as mrr FROM customers GROUP BY 1\\n- SELECT * FROM activity WHERE customer_id = 'cust_123' ORDER BY occurred_at DESC LIMIT 50\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sql: {\n type: \"string\",\n description: \"SQL SELECT query to execute\",\n },\n limit: {\n description: \"Max rows to return (default 1000, max 10000)\",\n default: 1000,\n type: \"integer\",\n minimum: 1,\n maximum: 10000,\n },\n },\n required: [\"sql\"],\n additionalProperties: false,\n },\n },\n outlit_schema: {\n toolName: \"outlit_schema\",\n description:\n \"Get schemas for available analytics views.\\n\\nUse this to discover column names, types, and descriptions before writing SQL queries.\\nReturns column definitions and example queries for each view.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n table: {\n description: \"Specific analytics view to describe. Omit to list all views.\",\n type: \"string\",\n enum: [\"activity\", \"customers\", \"users\", \"revenue\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_send_notification: {\n toolName: \"outlit_send_notification\",\n description:\n \"Send or post a notification. Use only when the user explicitly asks you to send, post, or notify. Slack is the default notifier when destinations are omitted.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n title: {\n type: \"string\",\n minLength: 1,\n maxLength: 160,\n description: \"Notification title\",\n },\n markdown: {\n description: \"Markdown notification body rendered for the target provider\",\n type: \"string\",\n minLength: 1,\n maxLength: 100000,\n },\n payload: {\n description:\n \"Optional JSON-compatible payload. Serialized size must be 100,000 characters or fewer.\",\n $ref: \"#/$defs/__schema0\",\n },\n message: {\n description: \"Optional summary message\",\n type: \"string\",\n minLength: 1,\n maxLength: 1200,\n },\n severity: {\n description: \"Optional notification severity\",\n type: \"string\",\n enum: [\"low\", \"medium\", \"high\"],\n },\n source: {\n description: \"Optional source label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n subject: {\n description: \"Optional subject line\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n destinations: {\n description:\n \"Optional explicit notification destinations. Omit to use the default notifier.\",\n minItems: 1,\n maxItems: 10,\n type: \"array\",\n items: {\n type: \"object\",\n properties: {\n provider: {\n description: \"Notification provider\",\n type: \"string\",\n enum: [\"slack\"],\n },\n channelId: {\n description: \"Provider-specific destination channel ID\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n label: {\n description: \"Optional destination label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n },\n required: [\"provider\"],\n additionalProperties: false,\n },\n },\n },\n required: [\"title\"],\n additionalProperties: false,\n $defs: {\n __schema0: {\n anyOf: [\n {\n type: \"string\",\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n {\n type: \"null\",\n },\n {\n type: \"array\",\n items: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n {\n type: \"object\",\n propertyNames: {\n type: \"string\",\n },\n additionalProperties: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n ],\n },\n },\n },\n },\n} as const\n\nexport const customerBillingStatuses = [\n \"NONE\",\n \"TRIALING\",\n \"PAYING\",\n \"PAST_DUE\",\n \"CHURNED\",\n] as const\n\nexport const customerActivityWindows = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const customerFactStatuses = [\n \"ACTIVE\",\n \"ACKNOWLEDGED\",\n \"RESOLVED\",\n \"SNOOZED\",\n \"CANDIDATE\",\n] as const\n\nexport const customerFactIncludes = [\"evidence\"] as const\n\nexport const customerFactTypes = [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n] as const\n\nexport const unsupportedCustomerFactTypes = [\n \"TRACKING_GAP\",\n \"SCHEMA_DRIFT\",\n \"INGESTION_LAG\",\n \"ACTIVATION_RATE_DROP\",\n \"FUNNEL_DROPOFF\",\n \"CORE_ACTION_DECAY\",\n \"CADENCE_BREAK\",\n \"QUIET_ACCOUNT\",\n \"CHAMPION_AT_RISK\",\n \"SEGMENT_DIVERGENCE\",\n] as const\n\nexport const customerFactCategories = [\"MEMORY\", \"CUSTOM\"] as const\n\nexport const customerListOrderFields = [\n \"last_activity_at\",\n \"first_seen_at\",\n \"name\",\n \"mrr_cents\",\n] as const\n\nexport const customerIncludeSections = [\n \"users\",\n \"revenue\",\n \"recentTimeline\",\n \"behaviorMetrics\",\n] as const\n\nexport const customerTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const notificationProviderValues = [\"slack\"] as const\n\nexport const notificationSeverityValues = [\"low\", \"medium\", \"high\"] as const\n\nexport const timelineChannels = [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n] as const\n\nexport const timelineTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"] as const\n\nexport const userJourneyStages = [\n \"DISCOVERED\",\n \"SIGNED_UP\",\n \"ACTIVATED\",\n \"ENGAGED\",\n \"INACTIVE\",\n] as const\n\nexport const userListOrderFields = [\"last_activity_at\", \"first_seen_at\", \"email\"] as const\n\nexport const schemaTables = [\"activity\", \"customers\", \"users\", \"revenue\"] as const\n\nexport const customerToolContractHash =\n \"5016d146842452855bfdd9ecc8f6be1a122125d0c392ceff315aeb2e44fefc7f\" as const\n\nexport type CustomerToolName = (typeof customerToolNames)[number]\nexport type CustomerSourceType = (typeof customerSourceTypes)[number]\nexport type CustomerSourceTypeInput = (typeof customerSourceTypeInputs)[number]\n\nexport type CustomerToolContract = {\n toolName: CustomerToolName\n description: string\n inputSchema: JsonSchema\n}\n\nconst customerToolNameSet = new Set<string>(customerToolNames)\nconst customerSourceTypeSet = new Set<string>(customerSourceTypes)\nconst customerSourceTypeAliasMap = new Map<\n (typeof customerSourceTypeAliases)[number],\n CustomerSourceType\n>([\n [\"CRM\", \"OPPORTUNITY\"],\n [\"CRM_OPPORTUNITY\", \"OPPORTUNITY\"],\n])\nconst iso8601UtcDateTimeRegex =\n /^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$/\n\nexport function isCustomerToolName(value: string): value is CustomerToolName {\n return customerToolNameSet.has(value)\n}\n\nexport function getCustomerToolContract(name: CustomerToolName): CustomerToolContract {\n return customerToolContracts[name]\n}\n\nexport function normalizeCustomerSourceType(value: string): CustomerSourceType | null {\n const normalized = value.trim().toUpperCase()\n if (customerSourceTypeSet.has(normalized)) {\n return normalized as CustomerSourceType\n }\n\n return (\n customerSourceTypeAliasMap.get(normalized as (typeof customerSourceTypeAliases)[number]) ?? null\n )\n}\n\nexport type SearchArgsLike = {\n query?: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: string[]\n}\n\nexport type CustomerContextSearchInput = {\n query: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: CustomerSourceType[]\n}\n\nexport function resolveCustomerContextSearchInput(value: SearchArgsLike):\n | { ok: true; request: CustomerContextSearchInput }\n | {\n ok: false\n message: string\n } {\n if (!value.query) {\n return {\n ok: false,\n message: \"A query argument is required\",\n }\n }\n\n const normalizedQuery = value.query.trim()\n if (normalizedQuery.length < 2) {\n return {\n ok: false,\n message: \"Query must be at least 2 non-whitespace characters\",\n }\n }\n\n if (value.after !== undefined && !iso8601UtcDateTimeRegex.test(value.after)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n const afterTime = value.after === undefined ? undefined : new Date(value.after).getTime()\n if (afterTime !== undefined && Number.isNaN(afterTime)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n if (value.before !== undefined && !iso8601UtcDateTimeRegex.test(value.before)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n const beforeTime = value.before === undefined ? undefined : new Date(value.before).getTime()\n if (beforeTime !== undefined && Number.isNaN(beforeTime)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n if (afterTime !== undefined && beforeTime !== undefined && afterTime > beforeTime) {\n return {\n ok: false,\n message: \"--after must be before or equal to --before\",\n }\n }\n\n const invalidSourceTypes =\n value.sourceTypes?.filter((sourceType) => !normalizeCustomerSourceType(sourceType)) ?? []\n if (invalidSourceTypes.length > 0) {\n return {\n ok: false,\n message: `Unknown source types: ${invalidSourceTypes.join(\", \")}. Allowed: ${customerSourceTypeInputs.join(\", \")}`,\n }\n }\n\n const normalizedSourceTypes = value.sourceTypes\n ? Array.from(\n new Set(value.sourceTypes.map((sourceType) => normalizeCustomerSourceType(sourceType))),\n ).filter((sourceType): sourceType is CustomerSourceType => sourceType !== null)\n : undefined\n\n return {\n ok: true,\n request: {\n query: normalizedQuery,\n customer: value.customer,\n topK: value.topK,\n after: value.after,\n before: value.before,\n sourceTypes: normalizedSourceTypes,\n },\n }\n}\n","import { type CustomerToolName, isCustomerToolName } from \"./contracts.js\"\n\nexport const DEFAULT_OUTLIT_API_URL = \"https://app.outlit.ai\"\n\nexport type OutlitToolsFetch = (\n input: string | URL | Request,\n init?: RequestInit,\n) => Promise<Response>\n\nexport type OutlitToolsClientOptions = {\n apiKey: string\n baseUrl?: string\n fetch?: OutlitToolsFetch\n}\n\nexport type OutlitToolsClient = {\n key: string\n baseUrl: string\n callTool(toolName: CustomerToolName, input?: Record<string, unknown>): Promise<unknown>\n}\n\nexport function createOutlitClient(options: OutlitToolsClientOptions): OutlitToolsClient {\n const key = options.apiKey.trim()\n const baseUrl = options.baseUrl ?? DEFAULT_OUTLIT_API_URL\n const fetchImpl = options.fetch ?? globalThis.fetch\n\n if (!key) {\n throw new Error(\"apiKey is required\")\n }\n\n if (!fetchImpl) {\n throw new Error(\"fetch is not available\")\n }\n\n return {\n key,\n baseUrl,\n async callTool(toolName, input = {}) {\n if (!isCustomerToolName(toolName)) {\n throw new Error(`Unknown customer tool: ${toolName}`)\n }\n\n const response = await fetchImpl(new URL(\"/api/tools/call\", baseUrl).toString(), {\n method: \"POST\",\n headers: {\n Authorization: `Bearer ${key}`,\n \"Content-Type\": \"application/json\",\n },\n body: JSON.stringify({\n tool: toolName,\n input,\n }),\n })\n\n if (!response.ok) {\n const text = await response.text()\n throw new Error(`API error (${response.status}): ${text}`)\n }\n\n return response.json()\n },\n }\n}\n","import { type CustomerToolName, customerToolNames } from \"./contracts.js\"\n\nexport const actionToolNames = [\n \"outlit_send_notification\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const defaultAgentToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_search_customer_context\",\n ...actionToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const sqlToolNames = [\n \"outlit_schema\",\n \"outlit_query\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const analyticalAgentToolNames = [\n ...defaultAgentToolNames,\n ...sqlToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const allCustomerToolNames = customerToolNames\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACIO,IAAM,oBAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,sBAAsB;AAAA,EACjC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,4BAA4B,CAAC,OAAO,iBAAiB;AAE3D,IAAM,2BAA2B;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,wBAAwB;AAAA,EACnC,uBAAuB;AAAA,IACrB,UAAU;AAAA,IACV,aACE;AAAA,IACF,aAAa;AAAA,MACX,SAAS;AAAA,MACT,MAAM;AAAA,MAC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C,mBAAmB,QAAQ,GAAG;AACjC,cAAM,IAAI,MAAM,0BAA0B,QAAQ,EAAE;AAAA,MACtD;AAEA,YAAM,WAAW,MAAM,UAAU,IAAI,IAAI,mBAAmB,OAAO,EAAE,SAAS,GAAG;AAAA,QAC/E,QAAQ;AAAA,QACR,SAAS;AAAA,UACP,eAAe,UAAU,GAAG;AAAA,UAC5B,gBAAgB;AAAA,QAClB;AAAA,QACA,MAAM,KAAK,UAAU;AAAA,UACnB,MAAM;AAAA,UACN;AAAA,QACF,CAAC;AAAA,MACH,CAAC;AAED,UAAI,CAAC,SAAS,IAAI;AAChB,cAAM,OAAO,MAAM,SAAS,KAAK;AACjC,cAAM,IAAI,MAAM,cAAc,SAAS,MAAM,MAAM,IAAI,EAAE;AAAA,MAC3D;AAEA,aAAO,SAAS,KAAK;AAAA,IACvB;AAAA,EACF;AACF;;;AC5DO,IAAM,kBAAkB;AAAA,EAC7B;AACF;AAEO,IAAM,wBAAwB;AAAA,EACnC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL;AAEO,IAAM,eAAe;AAAA,EAC1B;AAAA,EACA;AACF;AAEO,IAAM,2BAA2B;AAAA,EACtC,GAAG;AAAA,EACH,GAAG;AACL;AAEO,IAAM,uBAAuB;","names":[]}
|
package/dist/index.d.cts
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
type JsonSchema = {
|
|
2
2
|
readonly [key: string]: unknown;
|
|
3
3
|
};
|
|
4
|
-
declare const customerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
4
|
+
declare const customerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_list_sources", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
5
5
|
declare const customerSourceTypes: readonly ["EMAIL", "CALL", "CALENDAR_EVENT", "SUPPORT_TICKET", "OPPORTUNITY"];
|
|
6
6
|
declare const customerSourceTypeAliases: readonly ["CRM", "CRM_OPPORTUNITY"];
|
|
7
7
|
declare const customerSourceTypeInputs: readonly ["EMAIL", "CALL", "CALENDAR_EVENT", "SUPPORT_TICKET", "OPPORTUNITY", "CRM", "CRM_OPPORTUNITY"];
|
|
8
|
-
declare const notificationProviderValues: readonly ["slack"];
|
|
9
8
|
declare const customerToolContracts: {
|
|
10
9
|
readonly outlit_list_customers: {
|
|
11
10
|
readonly toolName: "outlit_list_customers";
|
|
@@ -374,6 +373,69 @@ declare const customerToolContracts: {
|
|
|
374
373
|
readonly additionalProperties: false;
|
|
375
374
|
};
|
|
376
375
|
};
|
|
376
|
+
readonly outlit_list_sources: {
|
|
377
|
+
readonly toolName: "outlit_list_sources";
|
|
378
|
+
readonly description: "List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, or opportunities.";
|
|
379
|
+
readonly inputSchema: {
|
|
380
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
381
|
+
readonly type: "object";
|
|
382
|
+
readonly properties: {
|
|
383
|
+
readonly sourceType: {
|
|
384
|
+
readonly description: "Generic source type to list.";
|
|
385
|
+
readonly type: "string";
|
|
386
|
+
readonly enum: readonly ["EMAIL", "CALL", "CALENDAR_EVENT", "SUPPORT_TICKET", "OPPORTUNITY", "CRM", "CRM_OPPORTUNITY"];
|
|
387
|
+
};
|
|
388
|
+
readonly customer: {
|
|
389
|
+
readonly description: "Customer ID, domain, or name to scope source listing.";
|
|
390
|
+
readonly type: "string";
|
|
391
|
+
readonly minLength: 1;
|
|
392
|
+
readonly maxLength: 200;
|
|
393
|
+
};
|
|
394
|
+
readonly after: {
|
|
395
|
+
readonly description: "ISO 8601 datetime lower bound.";
|
|
396
|
+
readonly type: "string";
|
|
397
|
+
readonly format: "date-time";
|
|
398
|
+
readonly pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$";
|
|
399
|
+
};
|
|
400
|
+
readonly before: {
|
|
401
|
+
readonly description: "ISO 8601 datetime upper bound.";
|
|
402
|
+
readonly type: "string";
|
|
403
|
+
readonly format: "date-time";
|
|
404
|
+
readonly pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$";
|
|
405
|
+
};
|
|
406
|
+
readonly participant: {
|
|
407
|
+
readonly description: "Participant email or name to filter source records.";
|
|
408
|
+
readonly type: "string";
|
|
409
|
+
readonly minLength: 1;
|
|
410
|
+
readonly maxLength: 500;
|
|
411
|
+
};
|
|
412
|
+
readonly provider: {
|
|
413
|
+
readonly description: "Provider identifier such as gmail, gong, or google-calendar.";
|
|
414
|
+
readonly type: "string";
|
|
415
|
+
readonly minLength: 1;
|
|
416
|
+
readonly maxLength: 200;
|
|
417
|
+
};
|
|
418
|
+
readonly hasTranscript: {
|
|
419
|
+
readonly description: "Filter call sources by transcript presence.";
|
|
420
|
+
readonly type: "boolean";
|
|
421
|
+
};
|
|
422
|
+
readonly limit: {
|
|
423
|
+
readonly description: "Results per page.";
|
|
424
|
+
readonly default: 50;
|
|
425
|
+
readonly type: "integer";
|
|
426
|
+
readonly minimum: 1;
|
|
427
|
+
readonly maximum: 100;
|
|
428
|
+
};
|
|
429
|
+
readonly cursor: {
|
|
430
|
+
readonly description: "Pagination cursor.";
|
|
431
|
+
readonly type: "string";
|
|
432
|
+
readonly minLength: 1;
|
|
433
|
+
readonly maxLength: 2000;
|
|
434
|
+
};
|
|
435
|
+
};
|
|
436
|
+
readonly additionalProperties: false;
|
|
437
|
+
};
|
|
438
|
+
};
|
|
377
439
|
readonly outlit_search_customer_context: {
|
|
378
440
|
readonly toolName: "outlit_search_customer_context";
|
|
379
441
|
readonly description: "Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.";
|
|
@@ -585,13 +647,14 @@ declare const customerFactCategories: readonly ["MEMORY", "CUSTOM"];
|
|
|
585
647
|
declare const customerListOrderFields: readonly ["last_activity_at", "first_seen_at", "name", "mrr_cents"];
|
|
586
648
|
declare const customerIncludeSections: readonly ["users", "revenue", "recentTimeline", "behaviorMetrics"];
|
|
587
649
|
declare const customerTimeframes: readonly ["7d", "14d", "30d", "90d"];
|
|
650
|
+
declare const notificationProviderValues: readonly ["slack"];
|
|
588
651
|
declare const notificationSeverityValues: readonly ["low", "medium", "high"];
|
|
589
652
|
declare const timelineChannels: readonly ["SDK", "EMAIL", "SLACK", "CALL", "CALENDAR", "CRM", "BILLING", "SUPPORT", "INTERNAL"];
|
|
590
653
|
declare const timelineTimeframes: readonly ["7d", "14d", "30d", "90d", "all"];
|
|
591
654
|
declare const userJourneyStages: readonly ["DISCOVERED", "SIGNED_UP", "ACTIVATED", "ENGAGED", "INACTIVE"];
|
|
592
655
|
declare const userListOrderFields: readonly ["last_activity_at", "first_seen_at", "email"];
|
|
593
656
|
declare const schemaTables: readonly ["activity", "customers", "users", "revenue"];
|
|
594
|
-
declare const customerToolContractHash: "
|
|
657
|
+
declare const customerToolContractHash: "5016d146842452855bfdd9ecc8f6be1a122125d0c392ceff315aeb2e44fefc7f";
|
|
595
658
|
type CustomerToolName = (typeof customerToolNames)[number];
|
|
596
659
|
type CustomerSourceType = (typeof customerSourceTypes)[number];
|
|
597
660
|
type CustomerSourceTypeInput = (typeof customerSourceTypeInputs)[number];
|
|
@@ -645,6 +708,6 @@ declare const actionToolNames: readonly ["outlit_send_notification"];
|
|
|
645
708
|
declare const defaultAgentToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_send_notification"];
|
|
646
709
|
declare const sqlToolNames: readonly ["outlit_schema", "outlit_query"];
|
|
647
710
|
declare const analyticalAgentToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_send_notification", "outlit_schema", "outlit_query"];
|
|
648
|
-
declare const allCustomerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
711
|
+
declare const allCustomerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_list_sources", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
649
712
|
|
|
650
713
|
export { type CustomerContextSearchInput, type CustomerSourceType, type CustomerSourceTypeInput, type CustomerToolContract, type CustomerToolName, DEFAULT_OUTLIT_API_URL, type JsonSchema, type OutlitToolsClient, type OutlitToolsClientOptions, type OutlitToolsFetch, type SearchArgsLike, actionToolNames, allCustomerToolNames, analyticalAgentToolNames, createOutlitClient, customerActivityWindows, customerBillingStatuses, customerFactCategories, customerFactIncludes, customerFactStatuses, customerFactTypes, customerIncludeSections, customerListOrderFields, customerSourceTypeAliases, customerSourceTypeInputs, customerSourceTypes, customerTimeframes, customerToolContractHash, customerToolContracts, customerToolNames, defaultAgentToolNames, getCustomerToolContract, isCustomerToolName, normalizeCustomerSourceType, notificationProviderValues, notificationSeverityValues, resolveCustomerContextSearchInput, schemaTables, sqlToolNames, timelineChannels, timelineTimeframes, unsupportedCustomerFactTypes, userJourneyStages, userListOrderFields };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
type JsonSchema = {
|
|
2
2
|
readonly [key: string]: unknown;
|
|
3
3
|
};
|
|
4
|
-
declare const customerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
4
|
+
declare const customerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_list_sources", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
5
5
|
declare const customerSourceTypes: readonly ["EMAIL", "CALL", "CALENDAR_EVENT", "SUPPORT_TICKET", "OPPORTUNITY"];
|
|
6
6
|
declare const customerSourceTypeAliases: readonly ["CRM", "CRM_OPPORTUNITY"];
|
|
7
7
|
declare const customerSourceTypeInputs: readonly ["EMAIL", "CALL", "CALENDAR_EVENT", "SUPPORT_TICKET", "OPPORTUNITY", "CRM", "CRM_OPPORTUNITY"];
|
|
8
|
-
declare const notificationProviderValues: readonly ["slack"];
|
|
9
8
|
declare const customerToolContracts: {
|
|
10
9
|
readonly outlit_list_customers: {
|
|
11
10
|
readonly toolName: "outlit_list_customers";
|
|
@@ -374,6 +373,69 @@ declare const customerToolContracts: {
|
|
|
374
373
|
readonly additionalProperties: false;
|
|
375
374
|
};
|
|
376
375
|
};
|
|
376
|
+
readonly outlit_list_sources: {
|
|
377
|
+
readonly toolName: "outlit_list_sources";
|
|
378
|
+
readonly description: "List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, or opportunities.";
|
|
379
|
+
readonly inputSchema: {
|
|
380
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
381
|
+
readonly type: "object";
|
|
382
|
+
readonly properties: {
|
|
383
|
+
readonly sourceType: {
|
|
384
|
+
readonly description: "Generic source type to list.";
|
|
385
|
+
readonly type: "string";
|
|
386
|
+
readonly enum: readonly ["EMAIL", "CALL", "CALENDAR_EVENT", "SUPPORT_TICKET", "OPPORTUNITY", "CRM", "CRM_OPPORTUNITY"];
|
|
387
|
+
};
|
|
388
|
+
readonly customer: {
|
|
389
|
+
readonly description: "Customer ID, domain, or name to scope source listing.";
|
|
390
|
+
readonly type: "string";
|
|
391
|
+
readonly minLength: 1;
|
|
392
|
+
readonly maxLength: 200;
|
|
393
|
+
};
|
|
394
|
+
readonly after: {
|
|
395
|
+
readonly description: "ISO 8601 datetime lower bound.";
|
|
396
|
+
readonly type: "string";
|
|
397
|
+
readonly format: "date-time";
|
|
398
|
+
readonly pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$";
|
|
399
|
+
};
|
|
400
|
+
readonly before: {
|
|
401
|
+
readonly description: "ISO 8601 datetime upper bound.";
|
|
402
|
+
readonly type: "string";
|
|
403
|
+
readonly format: "date-time";
|
|
404
|
+
readonly pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$";
|
|
405
|
+
};
|
|
406
|
+
readonly participant: {
|
|
407
|
+
readonly description: "Participant email or name to filter source records.";
|
|
408
|
+
readonly type: "string";
|
|
409
|
+
readonly minLength: 1;
|
|
410
|
+
readonly maxLength: 500;
|
|
411
|
+
};
|
|
412
|
+
readonly provider: {
|
|
413
|
+
readonly description: "Provider identifier such as gmail, gong, or google-calendar.";
|
|
414
|
+
readonly type: "string";
|
|
415
|
+
readonly minLength: 1;
|
|
416
|
+
readonly maxLength: 200;
|
|
417
|
+
};
|
|
418
|
+
readonly hasTranscript: {
|
|
419
|
+
readonly description: "Filter call sources by transcript presence.";
|
|
420
|
+
readonly type: "boolean";
|
|
421
|
+
};
|
|
422
|
+
readonly limit: {
|
|
423
|
+
readonly description: "Results per page.";
|
|
424
|
+
readonly default: 50;
|
|
425
|
+
readonly type: "integer";
|
|
426
|
+
readonly minimum: 1;
|
|
427
|
+
readonly maximum: 100;
|
|
428
|
+
};
|
|
429
|
+
readonly cursor: {
|
|
430
|
+
readonly description: "Pagination cursor.";
|
|
431
|
+
readonly type: "string";
|
|
432
|
+
readonly minLength: 1;
|
|
433
|
+
readonly maxLength: 2000;
|
|
434
|
+
};
|
|
435
|
+
};
|
|
436
|
+
readonly additionalProperties: false;
|
|
437
|
+
};
|
|
438
|
+
};
|
|
377
439
|
readonly outlit_search_customer_context: {
|
|
378
440
|
readonly toolName: "outlit_search_customer_context";
|
|
379
441
|
readonly description: "Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.";
|
|
@@ -585,13 +647,14 @@ declare const customerFactCategories: readonly ["MEMORY", "CUSTOM"];
|
|
|
585
647
|
declare const customerListOrderFields: readonly ["last_activity_at", "first_seen_at", "name", "mrr_cents"];
|
|
586
648
|
declare const customerIncludeSections: readonly ["users", "revenue", "recentTimeline", "behaviorMetrics"];
|
|
587
649
|
declare const customerTimeframes: readonly ["7d", "14d", "30d", "90d"];
|
|
650
|
+
declare const notificationProviderValues: readonly ["slack"];
|
|
588
651
|
declare const notificationSeverityValues: readonly ["low", "medium", "high"];
|
|
589
652
|
declare const timelineChannels: readonly ["SDK", "EMAIL", "SLACK", "CALL", "CALENDAR", "CRM", "BILLING", "SUPPORT", "INTERNAL"];
|
|
590
653
|
declare const timelineTimeframes: readonly ["7d", "14d", "30d", "90d", "all"];
|
|
591
654
|
declare const userJourneyStages: readonly ["DISCOVERED", "SIGNED_UP", "ACTIVATED", "ENGAGED", "INACTIVE"];
|
|
592
655
|
declare const userListOrderFields: readonly ["last_activity_at", "first_seen_at", "email"];
|
|
593
656
|
declare const schemaTables: readonly ["activity", "customers", "users", "revenue"];
|
|
594
|
-
declare const customerToolContractHash: "
|
|
657
|
+
declare const customerToolContractHash: "5016d146842452855bfdd9ecc8f6be1a122125d0c392ceff315aeb2e44fefc7f";
|
|
595
658
|
type CustomerToolName = (typeof customerToolNames)[number];
|
|
596
659
|
type CustomerSourceType = (typeof customerSourceTypes)[number];
|
|
597
660
|
type CustomerSourceTypeInput = (typeof customerSourceTypeInputs)[number];
|
|
@@ -645,6 +708,6 @@ declare const actionToolNames: readonly ["outlit_send_notification"];
|
|
|
645
708
|
declare const defaultAgentToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_send_notification"];
|
|
646
709
|
declare const sqlToolNames: readonly ["outlit_schema", "outlit_query"];
|
|
647
710
|
declare const analyticalAgentToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_send_notification", "outlit_schema", "outlit_query"];
|
|
648
|
-
declare const allCustomerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
711
|
+
declare const allCustomerToolNames: readonly ["outlit_list_customers", "outlit_list_users", "outlit_get_customer", "outlit_get_timeline", "outlit_list_facts", "outlit_get_fact", "outlit_get_source", "outlit_list_sources", "outlit_search_customer_context", "outlit_query", "outlit_schema", "outlit_send_notification"];
|
|
649
712
|
|
|
650
713
|
export { type CustomerContextSearchInput, type CustomerSourceType, type CustomerSourceTypeInput, type CustomerToolContract, type CustomerToolName, DEFAULT_OUTLIT_API_URL, type JsonSchema, type OutlitToolsClient, type OutlitToolsClientOptions, type OutlitToolsFetch, type SearchArgsLike, actionToolNames, allCustomerToolNames, analyticalAgentToolNames, createOutlitClient, customerActivityWindows, customerBillingStatuses, customerFactCategories, customerFactIncludes, customerFactStatuses, customerFactTypes, customerIncludeSections, customerListOrderFields, customerSourceTypeAliases, customerSourceTypeInputs, customerSourceTypes, customerTimeframes, customerToolContractHash, customerToolContracts, customerToolNames, defaultAgentToolNames, getCustomerToolContract, isCustomerToolName, normalizeCustomerSourceType, notificationProviderValues, notificationSeverityValues, resolveCustomerContextSearchInput, schemaTables, sqlToolNames, timelineChannels, timelineTimeframes, unsupportedCustomerFactTypes, userJourneyStages, userListOrderFields };
|
package/dist/index.js
CHANGED
|
@@ -7,6 +7,7 @@ var customerToolNames = [
|
|
|
7
7
|
"outlit_list_facts",
|
|
8
8
|
"outlit_get_fact",
|
|
9
9
|
"outlit_get_source",
|
|
10
|
+
"outlit_list_sources",
|
|
10
11
|
"outlit_search_customer_context",
|
|
11
12
|
"outlit_query",
|
|
12
13
|
"outlit_schema",
|
|
@@ -29,7 +30,6 @@ var customerSourceTypeInputs = [
|
|
|
29
30
|
"CRM",
|
|
30
31
|
"CRM_OPPORTUNITY"
|
|
31
32
|
];
|
|
32
|
-
var notificationProviderValues = ["slack"];
|
|
33
33
|
var customerToolContracts = {
|
|
34
34
|
outlit_list_customers: {
|
|
35
35
|
toolName: "outlit_list_customers",
|
|
@@ -434,6 +434,69 @@ var customerToolContracts = {
|
|
|
434
434
|
additionalProperties: false
|
|
435
435
|
}
|
|
436
436
|
},
|
|
437
|
+
outlit_list_sources: {
|
|
438
|
+
toolName: "outlit_list_sources",
|
|
439
|
+
description: "List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, or opportunities.",
|
|
440
|
+
inputSchema: {
|
|
441
|
+
$schema: "https://json-schema.org/draft/2020-12/schema",
|
|
442
|
+
type: "object",
|
|
443
|
+
properties: {
|
|
444
|
+
sourceType: {
|
|
445
|
+
description: "Generic source type to list.",
|
|
446
|
+
type: "string",
|
|
447
|
+
enum: customerSourceTypeInputs
|
|
448
|
+
},
|
|
449
|
+
customer: {
|
|
450
|
+
description: "Customer ID, domain, or name to scope source listing.",
|
|
451
|
+
type: "string",
|
|
452
|
+
minLength: 1,
|
|
453
|
+
maxLength: 200
|
|
454
|
+
},
|
|
455
|
+
after: {
|
|
456
|
+
description: "ISO 8601 datetime lower bound.",
|
|
457
|
+
type: "string",
|
|
458
|
+
format: "date-time",
|
|
459
|
+
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
|
460
|
+
},
|
|
461
|
+
before: {
|
|
462
|
+
description: "ISO 8601 datetime upper bound.",
|
|
463
|
+
type: "string",
|
|
464
|
+
format: "date-time",
|
|
465
|
+
pattern: "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
|
466
|
+
},
|
|
467
|
+
participant: {
|
|
468
|
+
description: "Participant email or name to filter source records.",
|
|
469
|
+
type: "string",
|
|
470
|
+
minLength: 1,
|
|
471
|
+
maxLength: 500
|
|
472
|
+
},
|
|
473
|
+
provider: {
|
|
474
|
+
description: "Provider identifier such as gmail, gong, or google-calendar.",
|
|
475
|
+
type: "string",
|
|
476
|
+
minLength: 1,
|
|
477
|
+
maxLength: 200
|
|
478
|
+
},
|
|
479
|
+
hasTranscript: {
|
|
480
|
+
description: "Filter call sources by transcript presence.",
|
|
481
|
+
type: "boolean"
|
|
482
|
+
},
|
|
483
|
+
limit: {
|
|
484
|
+
description: "Results per page.",
|
|
485
|
+
default: 50,
|
|
486
|
+
type: "integer",
|
|
487
|
+
minimum: 1,
|
|
488
|
+
maximum: 100
|
|
489
|
+
},
|
|
490
|
+
cursor: {
|
|
491
|
+
description: "Pagination cursor.",
|
|
492
|
+
type: "string",
|
|
493
|
+
minLength: 1,
|
|
494
|
+
maxLength: 2e3
|
|
495
|
+
}
|
|
496
|
+
},
|
|
497
|
+
additionalProperties: false
|
|
498
|
+
}
|
|
499
|
+
},
|
|
437
500
|
outlit_search_customer_context: {
|
|
438
501
|
toolName: "outlit_search_customer_context",
|
|
439
502
|
description: "Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.",
|
|
@@ -587,7 +650,7 @@ var customerToolContracts = {
|
|
|
587
650
|
provider: {
|
|
588
651
|
description: "Notification provider",
|
|
589
652
|
type: "string",
|
|
590
|
-
enum:
|
|
653
|
+
enum: ["slack"]
|
|
591
654
|
},
|
|
592
655
|
channelId: {
|
|
593
656
|
description: "Provider-specific destination channel ID",
|
|
@@ -706,6 +769,7 @@ var customerIncludeSections = [
|
|
|
706
769
|
"behaviorMetrics"
|
|
707
770
|
];
|
|
708
771
|
var customerTimeframes = ["7d", "14d", "30d", "90d"];
|
|
772
|
+
var notificationProviderValues = ["slack"];
|
|
709
773
|
var notificationSeverityValues = ["low", "medium", "high"];
|
|
710
774
|
var timelineChannels = [
|
|
711
775
|
"SDK",
|
|
@@ -728,7 +792,7 @@ var userJourneyStages = [
|
|
|
728
792
|
];
|
|
729
793
|
var userListOrderFields = ["last_activity_at", "first_seen_at", "email"];
|
|
730
794
|
var schemaTables = ["activity", "customers", "users", "revenue"];
|
|
731
|
-
var customerToolContractHash = "
|
|
795
|
+
var customerToolContractHash = "5016d146842452855bfdd9ecc8f6be1a122125d0c392ceff315aeb2e44fefc7f";
|
|
732
796
|
var customerToolNameSet = new Set(customerToolNames);
|
|
733
797
|
var customerSourceTypeSet = new Set(customerSourceTypes);
|
|
734
798
|
var customerSourceTypeAliasMap = /* @__PURE__ */ new Map([
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/contracts.ts","../src/client.ts","../src/toolsets.ts"],"sourcesContent":["export type JsonSchema = {\n readonly [key: string]: unknown\n}\n\nexport const customerToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_search_customer_context\",\n \"outlit_query\",\n \"outlit_schema\",\n \"outlit_send_notification\",\n] as const\n\nexport const customerSourceTypes = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n] as const\n\nexport const customerSourceTypeAliases = [\"CRM\", \"CRM_OPPORTUNITY\"] as const\n\nexport const customerSourceTypeInputs = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n \"CRM\",\n \"CRM_OPPORTUNITY\",\n] as const\n\nexport const notificationProviderValues = [\"slack\"] as const\n\nexport const customerToolContracts = {\n outlit_list_customers: {\n toolName: \"outlit_list_customers\",\n description:\n \"Browse and filter customers. Use this to find customers by billing status, activity recency, revenue, or name. Returns a paginated list with summary info (MRR, last activity, status).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n billingStatus: {\n description: \"Filter by billing status\",\n type: \"string\",\n enum: [\"NONE\", \"TRIALING\", \"PAYING\", \"PAST_DUE\", \"CHURNED\"],\n },\n hasActivityInLast: {\n description: \"Filter customers with activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n noActivityInLast: {\n description: \"Filter customers with NO activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n mrrAbove: {\n description: \"Minimum MRR in cents (e.g., 10000 = $100)\",\n type: \"number\",\n minimum: 0,\n },\n mrrBelow: {\n description: \"Maximum MRR in cents\",\n type: \"number\",\n minimum: 0,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n search: {\n description: \"Search by customer name or domain (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order results by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"name\", \"mrr_cents\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_list_users: {\n toolName: \"outlit_list_users\",\n description:\n \"Browse and filter users. Use this to find users by journey stage, activity recency, customer, or email/name. Returns a paginated list with activity info.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n journeyStage: {\n description: \"Filter by user journey stage\",\n type: \"string\",\n enum: [\"DISCOVERED\", \"SIGNED_UP\", \"ACTIVATED\", \"ENGAGED\", \"INACTIVE\"],\n },\n customerId: {\n description: \"Filter users by customer ID\",\n type: \"string\",\n maxLength: 500,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n hasActivityInLast: {\n description:\n \"Filter users active within this window. Format: Nd, Nh, or Nm (e.g., '7d', '24h', '90m')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n noActivityInLast: {\n description:\n \"Filter users NOT active within this window. Format: Nd, Nh, or Nm (e.g., '30d', '2h')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n search: {\n description: \"Search by user email or name (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"email\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_get_customer: {\n toolName: \"outlit_get_customer\",\n description:\n \"Get full details for a single customer. Use this when you already know which customer you want to inspect. Optionally include related data (users, revenue, recent activity, engagement metrics).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID, domain, or name to look up\",\n },\n include: {\n description: \"Additional data sections to include in the response\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"users\", \"revenue\", \"recentTimeline\", \"behaviorMetrics\"],\n },\n },\n timeframe: {\n description: \"Timeframe for timeline and behavior metrics (default: 30d)\",\n default: \"30d\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_timeline: {\n toolName: \"outlit_get_timeline\",\n description:\n \"Get the chronological activity timeline for a customer. Use this to see what happened and when — emails, calls, Slack messages, billing events, etc. Supports channel and date filtering.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n channels: {\n description: \"Filter by event channel (e.g., EMAIL, SLACK, CALL, CALENDAR)\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n ],\n },\n },\n eventTypes: {\n description: \"Filter by event type\",\n type: \"array\",\n items: {\n type: \"string\",\n },\n },\n timeframe: {\n description:\n \"Relative time window (default: 30d). Cannot be used with startDate/endDate.\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"],\n },\n startDate: {\n description:\n \"Start of time window (ISO 8601, e.g. '2025-01-01T00:00:00Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n endDate: {\n description:\n \"End of time window (ISO 8601, e.g. '2025-01-31T23:59:59Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_list_facts: {\n toolName: \"outlit_list_facts\",\n description:\n \"List structured facts known about a customer. Use filters like status, sourceTypes, factTypes, factCategories, and date bounds to narrow the result set. For topic-specific retrieval, use outlit_search_customer_context instead.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n status: {\n description: \"Optional fact status filter\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"ACTIVE\", \"ACKNOWLEDGED\", \"RESOLVED\", \"SNOOZED\", \"CANDIDATE\"],\n },\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict fact results to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n factTypes: {\n description:\n \"Optional customer-memory fact type filters, such as CHURN_RISK, EXPANSION, SENTIMENT, or BUDGET. Anomaly detector fact types are not supported.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n ],\n },\n },\n factCategories: {\n description: \"Optional public fact category filters. Supported values: MEMORY, CUSTOM.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"MEMORY\", \"CUSTOM\"],\n },\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 100)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 100,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_fact: {\n toolName: \"outlit_get_fact\",\n description:\n \"Get one exact fact by ID. Returns the canonical fact shape and optionally expands requested related data such as evidence.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n factId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n description: \"Exact fact ID to retrieve\",\n },\n include: {\n description:\n \"Optional best-effort expansions. Use include=['evidence'] to request evidence when available; unsupported include values are ignored.\",\n type: \"array\",\n items: {\n type: \"string\",\n minLength: 1,\n maxLength: 100,\n },\n },\n },\n required: [\"factId\"],\n additionalProperties: false,\n },\n },\n outlit_get_source: {\n toolName: \"outlit_get_source\",\n description:\n \"Get one exact source record by generic sourceType and sourceId. Use this when you already know the concrete underlying source you want to inspect.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sourceType: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n sourceId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n },\n required: [\"sourceType\", \"sourceId\"],\n additionalProperties: false,\n },\n },\n outlit_search_customer_context: {\n toolName: \"outlit_search_customer_context\",\n description:\n \"Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n description: \"Customer ID, domain, or name. Omit to search across all customers.\",\n anyOf: [\n {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n {\n type: \"null\",\n },\n ],\n },\n query: {\n type: \"string\",\n minLength: 2,\n maxLength: 2000,\n description: \"Natural language query or topic to search for.\",\n },\n topK: {\n description: \"Maximum number of artifact results to return (default 20).\",\n type: \"integer\",\n minimum: 1,\n maximum: 50,\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict the search to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n },\n required: [\"query\"],\n additionalProperties: false,\n },\n },\n outlit_query: {\n toolName: \"outlit_query\",\n description:\n \"Execute read-only SQL queries against your analytics views.\\n\\nAvailable views:\\n- activity: Customer activity events (event_name, event_type, event_channel, customer_id, occurred_at, properties, ...)\\n- customers: Customer attributes (customer_id, domain, name, billing_status, plan, mrr_cents, traits, ...)\\n- users: User attributes (user_id, email, name, customer_id, traits, ...)\\n- revenue: Revenue snapshots over time (customer_id, snapshot_date, mrr_cents, ...)\\n\\nAll queries are automatically filtered to your organization's data.\\nOnly SELECT queries are allowed.\\nProperties and traits are JSON strings; inspect schemas and examples before filtering nested values.\\n\\nExample queries:\\n- SELECT event_name, count(*) FROM activity GROUP BY 1 ORDER BY 2 DESC LIMIT 10\\n- SELECT billing_status, sum(mrr_cents)/100 as mrr FROM customers GROUP BY 1\\n- SELECT * FROM activity WHERE customer_id = 'cust_123' ORDER BY occurred_at DESC LIMIT 50\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sql: {\n type: \"string\",\n description: \"SQL SELECT query to execute\",\n },\n limit: {\n description: \"Max rows to return (default 1000, max 10000)\",\n default: 1000,\n type: \"integer\",\n minimum: 1,\n maximum: 10000,\n },\n },\n required: [\"sql\"],\n additionalProperties: false,\n },\n },\n outlit_schema: {\n toolName: \"outlit_schema\",\n description:\n \"Get schemas for available analytics views.\\n\\nUse this to discover column names, types, and descriptions before writing SQL queries.\\nReturns column definitions and example queries for each view.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n table: {\n description: \"Specific analytics view to describe. Omit to list all views.\",\n type: \"string\",\n enum: [\"activity\", \"customers\", \"users\", \"revenue\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_send_notification: {\n toolName: \"outlit_send_notification\",\n description:\n \"Send or post a notification. Use only when the user explicitly asks you to send, post, or notify. Slack is the default notifier when destinations are omitted.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n title: {\n type: \"string\",\n minLength: 1,\n maxLength: 160,\n description: \"Notification title\",\n },\n markdown: {\n description: \"Markdown notification body rendered for the target provider\",\n type: \"string\",\n minLength: 1,\n maxLength: 100000,\n },\n payload: {\n description:\n \"Optional JSON-compatible payload. Serialized size must be 100,000 characters or fewer.\",\n $ref: \"#/$defs/__schema0\",\n },\n message: {\n description: \"Optional summary message\",\n type: \"string\",\n minLength: 1,\n maxLength: 1200,\n },\n severity: {\n description: \"Optional notification severity\",\n type: \"string\",\n enum: [\"low\", \"medium\", \"high\"],\n },\n source: {\n description: \"Optional source label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n subject: {\n description: \"Optional subject line\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n destinations: {\n description:\n \"Optional explicit notification destinations. Omit to use the default notifier.\",\n minItems: 1,\n maxItems: 10,\n type: \"array\",\n items: {\n type: \"object\",\n properties: {\n provider: {\n description: \"Notification provider\",\n type: \"string\",\n enum: notificationProviderValues,\n },\n channelId: {\n description: \"Provider-specific destination channel ID\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n label: {\n description: \"Optional destination label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n },\n required: [\"provider\"],\n additionalProperties: false,\n },\n },\n },\n required: [\"title\"],\n additionalProperties: false,\n $defs: {\n __schema0: {\n anyOf: [\n {\n type: \"string\",\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n {\n type: \"null\",\n },\n {\n type: \"array\",\n items: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n {\n type: \"object\",\n propertyNames: {\n type: \"string\",\n },\n additionalProperties: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n ],\n },\n },\n },\n },\n} as const\n\nexport const customerBillingStatuses = [\n \"NONE\",\n \"TRIALING\",\n \"PAYING\",\n \"PAST_DUE\",\n \"CHURNED\",\n] as const\n\nexport const customerActivityWindows = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const customerFactStatuses = [\n \"ACTIVE\",\n \"ACKNOWLEDGED\",\n \"RESOLVED\",\n \"SNOOZED\",\n \"CANDIDATE\",\n] as const\n\nexport const customerFactIncludes = [\"evidence\"] as const\n\nexport const customerFactTypes = [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n] as const\n\nexport const unsupportedCustomerFactTypes = [\n \"TRACKING_GAP\",\n \"SCHEMA_DRIFT\",\n \"INGESTION_LAG\",\n \"ACTIVATION_RATE_DROP\",\n \"FUNNEL_DROPOFF\",\n \"CORE_ACTION_DECAY\",\n \"CADENCE_BREAK\",\n \"QUIET_ACCOUNT\",\n \"CHAMPION_AT_RISK\",\n \"SEGMENT_DIVERGENCE\",\n] as const\n\nexport const customerFactCategories = [\"MEMORY\", \"CUSTOM\"] as const\n\nexport const customerListOrderFields = [\n \"last_activity_at\",\n \"first_seen_at\",\n \"name\",\n \"mrr_cents\",\n] as const\n\nexport const customerIncludeSections = [\n \"users\",\n \"revenue\",\n \"recentTimeline\",\n \"behaviorMetrics\",\n] as const\n\nexport const customerTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const notificationSeverityValues = [\"low\", \"medium\", \"high\"] as const\n\nexport const timelineChannels = [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n] as const\n\nexport const timelineTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"] as const\n\nexport const userJourneyStages = [\n \"DISCOVERED\",\n \"SIGNED_UP\",\n \"ACTIVATED\",\n \"ENGAGED\",\n \"INACTIVE\",\n] as const\n\nexport const userListOrderFields = [\"last_activity_at\", \"first_seen_at\", \"email\"] as const\n\nexport const schemaTables = [\"activity\", \"customers\", \"users\", \"revenue\"] as const\n\nexport const customerToolContractHash =\n \"006ce091382509c3224815c4f6ead4c5e78e34f54df281fe8f143811890b04af\" as const\n\nexport type CustomerToolName = (typeof customerToolNames)[number]\nexport type CustomerSourceType = (typeof customerSourceTypes)[number]\nexport type CustomerSourceTypeInput = (typeof customerSourceTypeInputs)[number]\n\nexport type CustomerToolContract = {\n toolName: CustomerToolName\n description: string\n inputSchema: JsonSchema\n}\n\nconst customerToolNameSet = new Set<string>(customerToolNames)\nconst customerSourceTypeSet = new Set<string>(customerSourceTypes)\nconst customerSourceTypeAliasMap = new Map<\n (typeof customerSourceTypeAliases)[number],\n CustomerSourceType\n>([\n [\"CRM\", \"OPPORTUNITY\"],\n [\"CRM_OPPORTUNITY\", \"OPPORTUNITY\"],\n])\nconst iso8601UtcDateTimeRegex =\n /^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$/\n\nexport function isCustomerToolName(value: string): value is CustomerToolName {\n return customerToolNameSet.has(value)\n}\n\nexport function getCustomerToolContract(name: CustomerToolName): CustomerToolContract {\n return customerToolContracts[name]\n}\n\nexport function normalizeCustomerSourceType(value: string): CustomerSourceType | null {\n const normalized = value.trim().toUpperCase()\n if (customerSourceTypeSet.has(normalized)) {\n return normalized as CustomerSourceType\n }\n\n return (\n customerSourceTypeAliasMap.get(normalized as (typeof customerSourceTypeAliases)[number]) ?? null\n )\n}\n\nexport type SearchArgsLike = {\n query?: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: string[]\n}\n\nexport type CustomerContextSearchInput = {\n query: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: CustomerSourceType[]\n}\n\nexport function resolveCustomerContextSearchInput(value: SearchArgsLike):\n | { ok: true; request: CustomerContextSearchInput }\n | {\n ok: false\n message: string\n } {\n if (!value.query) {\n return {\n ok: false,\n message: \"A query argument is required\",\n }\n }\n\n const normalizedQuery = value.query.trim()\n if (normalizedQuery.length < 2) {\n return {\n ok: false,\n message: \"Query must be at least 2 non-whitespace characters\",\n }\n }\n\n if (value.after !== undefined && !iso8601UtcDateTimeRegex.test(value.after)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n const afterTime = value.after === undefined ? undefined : new Date(value.after).getTime()\n if (afterTime !== undefined && Number.isNaN(afterTime)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n if (value.before !== undefined && !iso8601UtcDateTimeRegex.test(value.before)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n const beforeTime = value.before === undefined ? undefined : new Date(value.before).getTime()\n if (beforeTime !== undefined && Number.isNaN(beforeTime)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n if (afterTime !== undefined && beforeTime !== undefined && afterTime > beforeTime) {\n return {\n ok: false,\n message: \"--after must be before or equal to --before\",\n }\n }\n\n const invalidSourceTypes =\n value.sourceTypes?.filter((sourceType) => !normalizeCustomerSourceType(sourceType)) ?? []\n if (invalidSourceTypes.length > 0) {\n return {\n ok: false,\n message: `Unknown source types: ${invalidSourceTypes.join(\", \")}. Allowed: ${customerSourceTypeInputs.join(\", \")}`,\n }\n }\n\n const normalizedSourceTypes = value.sourceTypes\n ? Array.from(\n new Set(value.sourceTypes.map((sourceType) => normalizeCustomerSourceType(sourceType))),\n ).filter((sourceType): sourceType is CustomerSourceType => sourceType !== null)\n : undefined\n\n return {\n ok: true,\n request: {\n query: normalizedQuery,\n customer: value.customer,\n topK: value.topK,\n after: value.after,\n before: value.before,\n sourceTypes: normalizedSourceTypes,\n },\n }\n}\n","import { type CustomerToolName, isCustomerToolName } from \"./contracts.js\"\n\nexport const DEFAULT_OUTLIT_API_URL = \"https://app.outlit.ai\"\n\nexport type OutlitToolsFetch = (\n input: string | URL | Request,\n init?: RequestInit,\n) => Promise<Response>\n\nexport type OutlitToolsClientOptions = {\n apiKey: string\n baseUrl?: string\n fetch?: OutlitToolsFetch\n}\n\nexport type OutlitToolsClient = {\n key: string\n baseUrl: string\n callTool(toolName: CustomerToolName, input?: Record<string, unknown>): Promise<unknown>\n}\n\nexport function createOutlitClient(options: OutlitToolsClientOptions): OutlitToolsClient {\n const key = options.apiKey.trim()\n const baseUrl = options.baseUrl ?? DEFAULT_OUTLIT_API_URL\n const fetchImpl = options.fetch ?? globalThis.fetch\n\n if (!key) {\n throw new Error(\"apiKey is required\")\n }\n\n if (!fetchImpl) {\n throw new Error(\"fetch is not available\")\n }\n\n return {\n key,\n baseUrl,\n async callTool(toolName, input = {}) {\n if (!isCustomerToolName(toolName)) {\n throw new Error(`Unknown customer tool: ${toolName}`)\n }\n\n const response = await fetchImpl(new URL(\"/api/tools/call\", baseUrl).toString(), {\n method: \"POST\",\n headers: {\n Authorization: `Bearer ${key}`,\n \"Content-Type\": \"application/json\",\n },\n body: JSON.stringify({\n tool: toolName,\n input,\n }),\n })\n\n if (!response.ok) {\n const text = await response.text()\n throw new Error(`API error (${response.status}): ${text}`)\n }\n\n return response.json()\n },\n }\n}\n","import { type CustomerToolName, customerToolNames } from \"./contracts.js\"\n\nexport const actionToolNames = [\n \"outlit_send_notification\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const defaultAgentToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_search_customer_context\",\n ...actionToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const sqlToolNames = [\n \"outlit_schema\",\n \"outlit_query\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const analyticalAgentToolNames = [\n ...defaultAgentToolNames,\n ...sqlToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const allCustomerToolNames = customerToolNames\n"],"mappings":";AAIO,IAAM,oBAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,sBAAsB;AAAA,EACjC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,4BAA4B,CAAC,OAAO,iBAAiB;AAE3D,IAAM,2BAA2B;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,6BAA6B,CAAC,OAAO;AAE3C,IAAM,wBAAwB;AAAA,EACnC,uBAAuB;AAAA,IACrB,UAAU;AAAA,IACV,aACE;AAAA,IACF,aAAa;AAAA,MACX,SAAS;AAAA,MACT,MAAM;AAAA,MACN,YAAY;AAAA,QACV,eAAe;AAAA,UACb,aAAa;AAAA,UACb,MAAM;AAAA,UACN,MAAM,CAAC,QAAQ,YAAY,UAAU,YAAY,SAAS;AAAA,QAC5D;AAAA,QACA,mBAAmB;AAAA,UACjB,aAAa;AAAA,UACb,MAAM;AAAA,UACN,MAAM,CAAC,MAAM,OAAO,OAAO,KAAK;AAAA,QAClC;AAAA,Q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,EAAE;AAAA,MACtD;AAEA,YAAM,WAAW,MAAM,UAAU,IAAI,IAAI,mBAAmB,OAAO,EAAE,SAAS,GAAG;AAAA,QAC/E,QAAQ;AAAA,QACR,SAAS;AAAA,UACP,eAAe,UAAU,GAAG;AAAA,UAC5B,gBAAgB;AAAA,QAClB;AAAA,QACA,MAAM,KAAK,UAAU;AAAA,UACnB,MAAM;AAAA,UACN;AAAA,QACF,CAAC;AAAA,MACH,CAAC;AAED,UAAI,CAAC,SAAS,IAAI;AAChB,cAAM,OAAO,MAAM,SAAS,KAAK;AACjC,cAAM,IAAI,MAAM,cAAc,SAAS,MAAM,MAAM,IAAI,EAAE;AAAA,MAC3D;AAEA,aAAO,SAAS,KAAK;AAAA,IACvB;AAAA,EACF;AACF;;;AC5DO,IAAM,kBAAkB;AAAA,EAC7B;AACF;AAEO,IAAM,wBAAwB;AAAA,EACnC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL;AAEO,IAAM,eAAe;AAAA,EAC1B;AAAA,EACA;AACF;AAEO,IAAM,2BAA2B;AAAA,EACtC,GAAG;AAAA,EACH,GAAG;AACL;AAEO,IAAM,uBAAuB;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/contracts.ts","../src/client.ts","../src/toolsets.ts"],"sourcesContent":["export type JsonSchema = {\n readonly [key: string]: unknown\n}\n\nexport const customerToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_list_sources\",\n \"outlit_search_customer_context\",\n \"outlit_query\",\n \"outlit_schema\",\n \"outlit_send_notification\",\n] as const\n\nexport const customerSourceTypes = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n] as const\n\nexport const customerSourceTypeAliases = [\"CRM\", \"CRM_OPPORTUNITY\"] as const\n\nexport const customerSourceTypeInputs = [\n \"EMAIL\",\n \"CALL\",\n \"CALENDAR_EVENT\",\n \"SUPPORT_TICKET\",\n \"OPPORTUNITY\",\n \"CRM\",\n \"CRM_OPPORTUNITY\",\n] as const\n\nexport const customerToolContracts = {\n outlit_list_customers: {\n toolName: \"outlit_list_customers\",\n description:\n \"Browse and filter customers. Use this to find customers by billing status, activity recency, revenue, or name. Returns a paginated list with summary info (MRR, last activity, status).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n billingStatus: {\n description: \"Filter by billing status\",\n type: \"string\",\n enum: [\"NONE\", \"TRIALING\", \"PAYING\", \"PAST_DUE\", \"CHURNED\"],\n },\n hasActivityInLast: {\n description: \"Filter customers with activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n noActivityInLast: {\n description: \"Filter customers with NO activity in the last N days\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n mrrAbove: {\n description: \"Minimum MRR in cents (e.g., 10000 = $100)\",\n type: \"number\",\n minimum: 0,\n },\n mrrBelow: {\n description: \"Maximum MRR in cents\",\n type: \"number\",\n minimum: 0,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n search: {\n description: \"Search by customer name or domain (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order results by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"name\", \"mrr_cents\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_list_users: {\n toolName: \"outlit_list_users\",\n description:\n \"Browse and filter users. Use this to find users by journey stage, activity recency, customer, or email/name. Returns a paginated list with activity info.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n journeyStage: {\n description: \"Filter by user journey stage\",\n type: \"string\",\n enum: [\"DISCOVERED\", \"SIGNED_UP\", \"ACTIVATED\", \"ENGAGED\", \"INACTIVE\"],\n },\n customerId: {\n description: \"Filter users by customer ID\",\n type: \"string\",\n maxLength: 500,\n },\n traitFilters: {\n description: \"Filter by exact trait values using key/value pairs\",\n type: \"object\",\n propertyNames: {\n type: \"string\",\n pattern: \"^[A-Za-z0-9_-]{1,100}$\",\n },\n additionalProperties: {\n anyOf: [\n {\n type: \"string\",\n maxLength: 500,\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n ],\n },\n },\n hasActivityInLast: {\n description:\n \"Filter users active within this window. Format: Nd, Nh, or Nm (e.g., '7d', '24h', '90m')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n noActivityInLast: {\n description:\n \"Filter users NOT active within this window. Format: Nd, Nh, or Nm (e.g., '30d', '2h')\",\n type: \"string\",\n pattern: \"^\\\\d+(d|h|m)$\",\n },\n search: {\n description: \"Search by user email or name (case-insensitive)\",\n type: \"string\",\n maxLength: 500,\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n orderBy: {\n description: \"Field to order by\",\n default: \"last_activity_at\",\n type: \"string\",\n enum: [\"last_activity_at\", \"first_seen_at\", \"email\"],\n },\n orderDirection: {\n description: \"Sort direction\",\n default: \"desc\",\n type: \"string\",\n enum: [\"asc\", \"desc\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_get_customer: {\n toolName: \"outlit_get_customer\",\n description:\n \"Get full details for a single customer. Use this when you already know which customer you want to inspect. Optionally include related data (users, revenue, recent activity, engagement metrics).\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID, domain, or name to look up\",\n },\n include: {\n description: \"Additional data sections to include in the response\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"users\", \"revenue\", \"recentTimeline\", \"behaviorMetrics\"],\n },\n },\n timeframe: {\n description: \"Timeframe for timeline and behavior metrics (default: 30d)\",\n default: \"30d\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\"],\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_timeline: {\n toolName: \"outlit_get_timeline\",\n description:\n \"Get the chronological activity timeline for a customer. Use this to see what happened and when — emails, calls, Slack messages, billing events, etc. Supports channel and date filtering.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n channels: {\n description: \"Filter by event channel (e.g., EMAIL, SLACK, CALL, CALENDAR)\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n ],\n },\n },\n eventTypes: {\n description: \"Filter by event type\",\n type: \"array\",\n items: {\n type: \"string\",\n },\n },\n timeframe: {\n description:\n \"Relative time window (default: 30d). Cannot be used with startDate/endDate.\",\n type: \"string\",\n enum: [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"],\n },\n startDate: {\n description:\n \"Start of time window (ISO 8601, e.g. '2025-01-01T00:00:00Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n endDate: {\n description:\n \"End of time window (ISO 8601, e.g. '2025-01-31T23:59:59Z'). Cannot be used with timeframe.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 1000)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 1000,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_list_facts: {\n toolName: \"outlit_list_facts\",\n description:\n \"List structured facts known about a customer. Use filters like status, sourceTypes, factTypes, factCategories, and date bounds to narrow the result set. For topic-specific retrieval, use outlit_search_customer_context instead.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n type: \"string\",\n description: \"Customer ID or domain\",\n },\n status: {\n description: \"Optional fact status filter\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"ACTIVE\", \"ACKNOWLEDGED\", \"RESOLVED\", \"SNOOZED\", \"CANDIDATE\"],\n },\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict fact results to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n factTypes: {\n description:\n \"Optional customer-memory fact type filters, such as CHURN_RISK, EXPANSION, SENTIMENT, or BUDGET. Anomaly detector fact types are not supported.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n ],\n },\n },\n factCategories: {\n description: \"Optional public fact category filters. Supported values: MEMORY, CUSTOM.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: [\"MEMORY\", \"CUSTOM\"],\n },\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n limit: {\n description: \"Results per page (max 100)\",\n default: 50,\n type: \"number\",\n minimum: 1,\n maximum: 100,\n },\n cursor: {\n description: \"Pagination cursor from previous response\",\n type: \"string\",\n },\n },\n required: [\"customer\"],\n additionalProperties: false,\n },\n },\n outlit_get_fact: {\n toolName: \"outlit_get_fact\",\n description:\n \"Get one exact fact by ID. Returns the canonical fact shape and optionally expands requested related data such as evidence.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n factId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n description: \"Exact fact ID to retrieve\",\n },\n include: {\n description:\n \"Optional best-effort expansions. Use include=['evidence'] to request evidence when available; unsupported include values are ignored.\",\n type: \"array\",\n items: {\n type: \"string\",\n minLength: 1,\n maxLength: 100,\n },\n },\n },\n required: [\"factId\"],\n additionalProperties: false,\n },\n },\n outlit_get_source: {\n toolName: \"outlit_get_source\",\n description:\n \"Get one exact source record by generic sourceType and sourceId. Use this when you already know the concrete underlying source you want to inspect.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sourceType: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n sourceId: {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n },\n required: [\"sourceType\", \"sourceId\"],\n additionalProperties: false,\n },\n },\n outlit_list_sources: {\n toolName: \"outlit_list_sources\",\n description:\n \"List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, or opportunities.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sourceType: {\n description: \"Generic source type to list.\",\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n customer: {\n description: \"Customer ID, domain, or name to scope source listing.\",\n type: \"string\",\n minLength: 1,\n maxLength: 200,\n },\n after: {\n description: \"ISO 8601 datetime lower bound.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound.\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n participant: {\n description: \"Participant email or name to filter source records.\",\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n provider: {\n description: \"Provider identifier such as gmail, gong, or google-calendar.\",\n type: \"string\",\n minLength: 1,\n maxLength: 200,\n },\n hasTranscript: {\n description: \"Filter call sources by transcript presence.\",\n type: \"boolean\",\n },\n limit: {\n description: \"Results per page.\",\n default: 50,\n type: \"integer\",\n minimum: 1,\n maximum: 100,\n },\n cursor: {\n description: \"Pagination cursor.\",\n type: \"string\",\n minLength: 1,\n maxLength: 2000,\n },\n },\n additionalProperties: false,\n },\n },\n outlit_search_customer_context: {\n toolName: \"outlit_search_customer_context\",\n description:\n \"Search across all known customer context using a natural-language query. Returns grouped artifact-level results for matching sources and facts. Omit customer to search across all customers in the organization.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n customer: {\n description: \"Customer ID, domain, or name. Omit to search across all customers.\",\n anyOf: [\n {\n type: \"string\",\n minLength: 1,\n maxLength: 500,\n },\n {\n type: \"null\",\n },\n ],\n },\n query: {\n type: \"string\",\n minLength: 2,\n maxLength: 2000,\n description: \"Natural language query or topic to search for.\",\n },\n topK: {\n description: \"Maximum number of artifact results to return (default 20).\",\n type: \"integer\",\n minimum: 1,\n maximum: 50,\n },\n after: {\n description: \"ISO 8601 datetime lower bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n before: {\n description: \"ISO 8601 datetime upper bound\",\n type: \"string\",\n format: \"date-time\",\n pattern:\n \"^(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))T(?:(?:[01]\\\\d|2[0-3]):[0-5]\\\\d(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?(?:Z))$\",\n },\n sourceTypes: {\n description: \"Optional generic source types to restrict the search to.\",\n type: \"array\",\n items: {\n type: \"string\",\n enum: customerSourceTypeInputs,\n },\n },\n },\n required: [\"query\"],\n additionalProperties: false,\n },\n },\n outlit_query: {\n toolName: \"outlit_query\",\n description:\n \"Execute read-only SQL queries against your analytics views.\\n\\nAvailable views:\\n- activity: Customer activity events (event_name, event_type, event_channel, customer_id, occurred_at, properties, ...)\\n- customers: Customer attributes (customer_id, domain, name, billing_status, plan, mrr_cents, traits, ...)\\n- users: User attributes (user_id, email, name, customer_id, traits, ...)\\n- revenue: Revenue snapshots over time (customer_id, snapshot_date, mrr_cents, ...)\\n\\nAll queries are automatically filtered to your organization's data.\\nOnly SELECT queries are allowed.\\nProperties and traits are JSON strings; inspect schemas and examples before filtering nested values.\\n\\nExample queries:\\n- SELECT event_name, count(*) FROM activity GROUP BY 1 ORDER BY 2 DESC LIMIT 10\\n- SELECT billing_status, sum(mrr_cents)/100 as mrr FROM customers GROUP BY 1\\n- SELECT * FROM activity WHERE customer_id = 'cust_123' ORDER BY occurred_at DESC LIMIT 50\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n sql: {\n type: \"string\",\n description: \"SQL SELECT query to execute\",\n },\n limit: {\n description: \"Max rows to return (default 1000, max 10000)\",\n default: 1000,\n type: \"integer\",\n minimum: 1,\n maximum: 10000,\n },\n },\n required: [\"sql\"],\n additionalProperties: false,\n },\n },\n outlit_schema: {\n toolName: \"outlit_schema\",\n description:\n \"Get schemas for available analytics views.\\n\\nUse this to discover column names, types, and descriptions before writing SQL queries.\\nReturns column definitions and example queries for each view.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n table: {\n description: \"Specific analytics view to describe. Omit to list all views.\",\n type: \"string\",\n enum: [\"activity\", \"customers\", \"users\", \"revenue\"],\n },\n },\n additionalProperties: false,\n },\n },\n outlit_send_notification: {\n toolName: \"outlit_send_notification\",\n description:\n \"Send or post a notification. Use only when the user explicitly asks you to send, post, or notify. Slack is the default notifier when destinations are omitted.\",\n inputSchema: {\n $schema: \"https://json-schema.org/draft/2020-12/schema\",\n type: \"object\",\n properties: {\n title: {\n type: \"string\",\n minLength: 1,\n maxLength: 160,\n description: \"Notification title\",\n },\n markdown: {\n description: \"Markdown notification body rendered for the target provider\",\n type: \"string\",\n minLength: 1,\n maxLength: 100000,\n },\n payload: {\n description:\n \"Optional JSON-compatible payload. Serialized size must be 100,000 characters or fewer.\",\n $ref: \"#/$defs/__schema0\",\n },\n message: {\n description: \"Optional summary message\",\n type: \"string\",\n minLength: 1,\n maxLength: 1200,\n },\n severity: {\n description: \"Optional notification severity\",\n type: \"string\",\n enum: [\"low\", \"medium\", \"high\"],\n },\n source: {\n description: \"Optional source label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n subject: {\n description: \"Optional subject line\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n destinations: {\n description:\n \"Optional explicit notification destinations. Omit to use the default notifier.\",\n minItems: 1,\n maxItems: 10,\n type: \"array\",\n items: {\n type: \"object\",\n properties: {\n provider: {\n description: \"Notification provider\",\n type: \"string\",\n enum: [\"slack\"],\n },\n channelId: {\n description: \"Provider-specific destination channel ID\",\n type: \"string\",\n minLength: 1,\n maxLength: 240,\n },\n label: {\n description: \"Optional destination label\",\n type: \"string\",\n minLength: 1,\n maxLength: 120,\n },\n },\n required: [\"provider\"],\n additionalProperties: false,\n },\n },\n },\n required: [\"title\"],\n additionalProperties: false,\n $defs: {\n __schema0: {\n anyOf: [\n {\n type: \"string\",\n },\n {\n type: \"number\",\n },\n {\n type: \"boolean\",\n },\n {\n type: \"null\",\n },\n {\n type: \"array\",\n items: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n {\n type: \"object\",\n propertyNames: {\n type: \"string\",\n },\n additionalProperties: {\n $ref: \"#/$defs/__schema0\",\n },\n },\n ],\n },\n },\n },\n },\n} as const\n\nexport const customerBillingStatuses = [\n \"NONE\",\n \"TRIALING\",\n \"PAYING\",\n \"PAST_DUE\",\n \"CHURNED\",\n] as const\n\nexport const customerActivityWindows = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const customerFactStatuses = [\n \"ACTIVE\",\n \"ACKNOWLEDGED\",\n \"RESOLVED\",\n \"SNOOZED\",\n \"CANDIDATE\",\n] as const\n\nexport const customerFactIncludes = [\"evidence\"] as const\n\nexport const customerFactTypes = [\n \"CUSTOM\",\n \"COMPANY_CHANGE\",\n \"FUNDING_REVENUE\",\n \"TECHNOLOGY\",\n \"STRATEGY\",\n \"COMPETITIVE\",\n \"SENTIMENT\",\n \"CHAMPION_RISK\",\n \"EXPANSION\",\n \"CHURN_RISK\",\n \"TIMELINE\",\n \"BUDGET\",\n \"DECISION_MAKER\",\n \"REQUIREMENTS\",\n \"PRODUCT_USAGE\",\n \"CONTACT_INFO\",\n \"CONTACT_PREFERENCE\",\n] as const\n\nexport const unsupportedCustomerFactTypes = [\n \"TRACKING_GAP\",\n \"SCHEMA_DRIFT\",\n \"INGESTION_LAG\",\n \"ACTIVATION_RATE_DROP\",\n \"FUNNEL_DROPOFF\",\n \"CORE_ACTION_DECAY\",\n \"CADENCE_BREAK\",\n \"QUIET_ACCOUNT\",\n \"CHAMPION_AT_RISK\",\n \"SEGMENT_DIVERGENCE\",\n] as const\n\nexport const customerFactCategories = [\"MEMORY\", \"CUSTOM\"] as const\n\nexport const customerListOrderFields = [\n \"last_activity_at\",\n \"first_seen_at\",\n \"name\",\n \"mrr_cents\",\n] as const\n\nexport const customerIncludeSections = [\n \"users\",\n \"revenue\",\n \"recentTimeline\",\n \"behaviorMetrics\",\n] as const\n\nexport const customerTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\"] as const\n\nexport const notificationProviderValues = [\"slack\"] as const\n\nexport const notificationSeverityValues = [\"low\", \"medium\", \"high\"] as const\n\nexport const timelineChannels = [\n \"SDK\",\n \"EMAIL\",\n \"SLACK\",\n \"CALL\",\n \"CALENDAR\",\n \"CRM\",\n \"BILLING\",\n \"SUPPORT\",\n \"INTERNAL\",\n] as const\n\nexport const timelineTimeframes = [\"7d\", \"14d\", \"30d\", \"90d\", \"all\"] as const\n\nexport const userJourneyStages = [\n \"DISCOVERED\",\n \"SIGNED_UP\",\n \"ACTIVATED\",\n \"ENGAGED\",\n \"INACTIVE\",\n] as const\n\nexport const userListOrderFields = [\"last_activity_at\", \"first_seen_at\", \"email\"] as const\n\nexport const schemaTables = [\"activity\", \"customers\", \"users\", \"revenue\"] as const\n\nexport const customerToolContractHash =\n \"5016d146842452855bfdd9ecc8f6be1a122125d0c392ceff315aeb2e44fefc7f\" as const\n\nexport type CustomerToolName = (typeof customerToolNames)[number]\nexport type CustomerSourceType = (typeof customerSourceTypes)[number]\nexport type CustomerSourceTypeInput = (typeof customerSourceTypeInputs)[number]\n\nexport type CustomerToolContract = {\n toolName: CustomerToolName\n description: string\n inputSchema: JsonSchema\n}\n\nconst customerToolNameSet = new Set<string>(customerToolNames)\nconst customerSourceTypeSet = new Set<string>(customerSourceTypes)\nconst customerSourceTypeAliasMap = new Map<\n (typeof customerSourceTypeAliases)[number],\n CustomerSourceType\n>([\n [\"CRM\", \"OPPORTUNITY\"],\n [\"CRM_OPPORTUNITY\", \"OPPORTUNITY\"],\n])\nconst iso8601UtcDateTimeRegex =\n /^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$/\n\nexport function isCustomerToolName(value: string): value is CustomerToolName {\n return customerToolNameSet.has(value)\n}\n\nexport function getCustomerToolContract(name: CustomerToolName): CustomerToolContract {\n return customerToolContracts[name]\n}\n\nexport function normalizeCustomerSourceType(value: string): CustomerSourceType | null {\n const normalized = value.trim().toUpperCase()\n if (customerSourceTypeSet.has(normalized)) {\n return normalized as CustomerSourceType\n }\n\n return (\n customerSourceTypeAliasMap.get(normalized as (typeof customerSourceTypeAliases)[number]) ?? null\n )\n}\n\nexport type SearchArgsLike = {\n query?: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: string[]\n}\n\nexport type CustomerContextSearchInput = {\n query: string\n customer?: string | null\n topK?: number\n after?: string\n before?: string\n sourceTypes?: CustomerSourceType[]\n}\n\nexport function resolveCustomerContextSearchInput(value: SearchArgsLike):\n | { ok: true; request: CustomerContextSearchInput }\n | {\n ok: false\n message: string\n } {\n if (!value.query) {\n return {\n ok: false,\n message: \"A query argument is required\",\n }\n }\n\n const normalizedQuery = value.query.trim()\n if (normalizedQuery.length < 2) {\n return {\n ok: false,\n message: \"Query must be at least 2 non-whitespace characters\",\n }\n }\n\n if (value.after !== undefined && !iso8601UtcDateTimeRegex.test(value.after)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n const afterTime = value.after === undefined ? undefined : new Date(value.after).getTime()\n if (afterTime !== undefined && Number.isNaN(afterTime)) {\n return {\n ok: false,\n message: \"--after must be a valid ISO 8601 datetime\",\n }\n }\n\n if (value.before !== undefined && !iso8601UtcDateTimeRegex.test(value.before)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n const beforeTime = value.before === undefined ? undefined : new Date(value.before).getTime()\n if (beforeTime !== undefined && Number.isNaN(beforeTime)) {\n return {\n ok: false,\n message: \"--before must be a valid ISO 8601 datetime\",\n }\n }\n\n if (afterTime !== undefined && beforeTime !== undefined && afterTime > beforeTime) {\n return {\n ok: false,\n message: \"--after must be before or equal to --before\",\n }\n }\n\n const invalidSourceTypes =\n value.sourceTypes?.filter((sourceType) => !normalizeCustomerSourceType(sourceType)) ?? []\n if (invalidSourceTypes.length > 0) {\n return {\n ok: false,\n message: `Unknown source types: ${invalidSourceTypes.join(\", \")}. Allowed: ${customerSourceTypeInputs.join(\", \")}`,\n }\n }\n\n const normalizedSourceTypes = value.sourceTypes\n ? Array.from(\n new Set(value.sourceTypes.map((sourceType) => normalizeCustomerSourceType(sourceType))),\n ).filter((sourceType): sourceType is CustomerSourceType => sourceType !== null)\n : undefined\n\n return {\n ok: true,\n request: {\n query: normalizedQuery,\n customer: value.customer,\n topK: value.topK,\n after: value.after,\n before: value.before,\n sourceTypes: normalizedSourceTypes,\n },\n }\n}\n","import { type CustomerToolName, isCustomerToolName } from \"./contracts.js\"\n\nexport const DEFAULT_OUTLIT_API_URL = \"https://app.outlit.ai\"\n\nexport type OutlitToolsFetch = (\n input: string | URL | Request,\n init?: RequestInit,\n) => Promise<Response>\n\nexport type OutlitToolsClientOptions = {\n apiKey: string\n baseUrl?: string\n fetch?: OutlitToolsFetch\n}\n\nexport type OutlitToolsClient = {\n key: string\n baseUrl: string\n callTool(toolName: CustomerToolName, input?: Record<string, unknown>): Promise<unknown>\n}\n\nexport function createOutlitClient(options: OutlitToolsClientOptions): OutlitToolsClient {\n const key = options.apiKey.trim()\n const baseUrl = options.baseUrl ?? DEFAULT_OUTLIT_API_URL\n const fetchImpl = options.fetch ?? globalThis.fetch\n\n if (!key) {\n throw new Error(\"apiKey is required\")\n }\n\n if (!fetchImpl) {\n throw new Error(\"fetch is not available\")\n }\n\n return {\n key,\n baseUrl,\n async callTool(toolName, input = {}) {\n if (!isCustomerToolName(toolName)) {\n throw new Error(`Unknown customer tool: ${toolName}`)\n }\n\n const response = await fetchImpl(new URL(\"/api/tools/call\", baseUrl).toString(), {\n method: \"POST\",\n headers: {\n Authorization: `Bearer ${key}`,\n \"Content-Type\": \"application/json\",\n },\n body: JSON.stringify({\n tool: toolName,\n input,\n }),\n })\n\n if (!response.ok) {\n const text = await response.text()\n throw new Error(`API error (${response.status}): ${text}`)\n }\n\n return response.json()\n },\n }\n}\n","import { type CustomerToolName, customerToolNames } from \"./contracts.js\"\n\nexport const actionToolNames = [\n \"outlit_send_notification\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const defaultAgentToolNames = [\n \"outlit_list_customers\",\n \"outlit_list_users\",\n \"outlit_get_customer\",\n \"outlit_get_timeline\",\n \"outlit_list_facts\",\n \"outlit_get_fact\",\n \"outlit_get_source\",\n \"outlit_search_customer_context\",\n ...actionToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const sqlToolNames = [\n \"outlit_schema\",\n \"outlit_query\",\n] as const satisfies readonly CustomerToolName[]\n\nexport const analyticalAgentToolNames = [\n ...defaultAgentToolNames,\n ...sqlToolNames,\n] as const satisfies readonly CustomerToolName[]\n\nexport const allCustomerToolNames = customerToolNames\n"],"mappings":";AAIO,IAAM,oBAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,sBAAsB;AAAA,EACjC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,4BAA4B,CAAC,OAAO,iBAAiB;AAE3D,IAAM,2BAA2B;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,IAAM,wBAAwB;AAAA,EACnC,uBAAuB;AAAA,IACrB,UAAU;AAAA,IACV,aACE;AAAA,IACF,aAAa;AAAA,MACX,SAAS;AAAA,MACT,MAAM;AAAA,MACN,YAAY;AAAA,QACV,eAAe;AAAA,UACb,aAAa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