diff --git a/apps/docs/components/icons.tsx b/apps/docs/components/icons.tsx index 00db61dd498..ea1eeea8a10 100644 --- a/apps/docs/components/icons.tsx +++ b/apps/docs/components/icons.tsx @@ -1561,6 +1561,110 @@ export function PineconeIcon(props: SVGProps) { ) } +export function LangChainIcon(props: SVGProps) { + return ( + + + + ) +} + +export function CrewAIIcon(props: SVGProps) { + return ( + + + + ) +} + +export function DustIcon(props: SVGProps) { + return ( + + + + ) +} + +export function OpenClawIcon(props: SVGProps) { + const id = useId() + const gid = (name: string) => `openclaw_${name}_${id}` + + return ( + + + + + + + + + + + + + + + + + + + + + ) +} + export function OpenAIIcon(props: SVGProps) { return ( ) { ) } +export function MicrosoftCopilotIcon(props: SVGProps) { + const id = useId() + const gid = (name: string) => `mscopilot_${name}_${id}` + + return ( + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ) +} + export function MicrosoftTeamsIcon(props: SVGProps) { const id = useId() const gradientId = `msteams_gradient_${id}` @@ -8055,3 +8267,148 @@ export function EnrowIcon(props: SVGProps) { ) } + +// ---- Competitor brand logos (sourced via Context.dev brand-intelligence API, 2026-07-02) ---- + +export function N8nIcon(props: SVGProps) { + return ( + + + + ) +} + +export function ZapierIcon(props: SVGProps) { + return ( + + + + ) +} + +export function MakeIcon(props: SVGProps) { + return ( + + + + ) +} + +export function GumloopIcon(props: SVGProps) { + return ( + + + + ) +} + +export function WorkatoIcon(props: SVGProps) { + return ( + + + + ) +} + +export function PipedreamIcon(props: SVGProps) { + return ( + + + + ) +} + +export function TinesIcon(props: SVGProps) { + return ( + + + + ) +} + +export function StackAIIcon(props: SVGProps) { + return ( + + + + ) +} + +export function VellumIcon(props: SVGProps) { + return ( + + + + ) +} + +export function RetoolIcon(props: SVGProps) { + return ( + + + + ) +} + +export function LangflowIcon(props: SVGProps) { + return ( + + + + ) +} + +export function FlowiseIcon(props: SVGProps) { + return ( + + + + ) +} diff --git a/apps/docs/content/docs/en/integrations/athena.mdx b/apps/docs/content/docs/en/integrations/athena.mdx index 478acf8369c..8119b5d368a 100644 --- a/apps/docs/content/docs/en/integrations/athena.mdx +++ b/apps/docs/content/docs/en/integrations/athena.mdx @@ -166,6 +166,45 @@ List recent Athena query execution IDs | `queryExecutionIds` | array | List of query execution IDs | | `nextToken` | string | Pagination token for next page | +### `athena_batch_get_query_execution` + +Get the status and details of up to 50 Athena query executions in one call + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `queryExecutionIds` | string | Yes | Comma-separated query execution IDs to check \(up to 50\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `queryExecutions` | array | Details for each successfully retrieved query execution | +| ↳ `queryExecutionId` | string | Query execution ID | +| ↳ `query` | string | SQL query string | +| ↳ `state` | string | Query state \(QUEUED, RUNNING, SUCCEEDED, FAILED, CANCELLED\) | +| ↳ `stateChangeReason` | string | Reason for state change | +| ↳ `statementType` | string | Statement type \(DDL, DML, UTILITY\) | +| ↳ `database` | string | Database name | +| ↳ `catalog` | string | Data catalog name | +| ↳ `workGroup` | string | Workgroup name | +| ↳ `submissionDateTime` | number | Query submission time \(Unix epoch ms\) | +| ↳ `completionDateTime` | number | Query completion time \(Unix epoch ms\) | +| ↳ `dataScannedInBytes` | number | Amount of data scanned in bytes | +| ↳ `engineExecutionTimeInMillis` | number | Engine execution time in milliseconds | +| ↳ `queryPlanningTimeInMillis` | number | Query planning time in milliseconds | +| ↳ `queryQueueTimeInMillis` | number | Time the query spent in queue in milliseconds | +| ↳ `totalExecutionTimeInMillis` | number | Total execution time in milliseconds | +| ↳ `outputLocation` | string | S3 location of query results | +| `unprocessedQueryExecutionIds` | array | Query execution IDs that could not be retrieved, with error details | +| ↳ `queryExecutionId` | string | Query execution ID | +| ↳ `errorCode` | string | Error code | +| ↳ `errorMessage` | string | Error message | + ### `athena_create_named_query` Create a saved/named query in AWS Athena @@ -235,4 +274,85 @@ List saved/named query IDs in AWS Athena | `namedQueryIds` | array | List of named query IDs | | `nextToken` | string | Pagination token for next page | +### `athena_delete_named_query` + +Delete a saved/named query in AWS Athena + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `namedQueryId` | string | Yes | Named query ID to delete | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the named query was successfully deleted | + +### `athena_list_databases` + +List the databases available in an Athena data catalog + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `catalogName` | string | Yes | Data catalog name to list databases from \(e.g., AwsDataCatalog\) | +| `workGroup` | string | No | Workgroup for which the metadata is being fetched \(required for IAM Identity Center enabled catalogs\) | +| `maxResults` | number | No | Maximum number of results \(1-50\) | +| `nextToken` | string | No | Pagination token from a previous request | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `databases` | array | List of databases \(name, description\) | +| ↳ `name` | string | Database name | +| ↳ `description` | string | Database description | +| `nextToken` | string | Pagination token for next page | + +### `athena_list_table_metadata` + +List tables and their column/partition metadata for an Athena database + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `catalogName` | string | Yes | Data catalog name \(e.g., AwsDataCatalog\) | +| `databaseName` | string | Yes | Database name to list tables from | +| `expression` | string | No | Regex filter that pattern-matches table names | +| `workGroup` | string | No | Workgroup for which the metadata is being fetched \(required for IAM Identity Center enabled catalogs\) | +| `maxResults` | number | No | Maximum number of results \(1-50\) | +| `nextToken` | string | No | Pagination token from a previous request | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `tables` | array | Table metadata \(name, type, columns, partition keys\) | +| ↳ `name` | string | Table name | +| ↳ `tableType` | string | Table type | +| ↳ `createTime` | number | Table creation time \(Unix epoch ms\) | +| ↳ `lastAccessTime` | number | Table last access time \(Unix epoch ms\) | +| ↳ `columns` | array | Column definitions | +| ↳ `name` | string | Column name | +| ↳ `type` | string | Column data type | +| ↳ `comment` | string | Column comment | +| ↳ `partitionKeys` | array | Partition key definitions | +| ↳ `name` | string | Partition key name | +| ↳ `type` | string | Partition key data type | +| ↳ `comment` | string | Partition key comment | +| `nextToken` | string | Pagination token for next page | + diff --git a/apps/docs/content/docs/en/integrations/attio.mdx b/apps/docs/content/docs/en/integrations/attio.mdx index c34ad91c3d6..d52cfe55e58 100644 --- a/apps/docs/content/docs/en/integrations/attio.mdx +++ b/apps/docs/content/docs/en/integrations/attio.mdx @@ -234,8 +234,10 @@ List notes in Attio, optionally filtered by parent record | ↳ `contentMarkdown` | string | The note content as markdown | | ↳ `meetingId` | string | The linked meeting ID | | ↳ `tags` | array | Tags on the note | -| ↳ `type` | string | The tag type \(e.g. workspace-member\) | -| ↳ `workspaceMemberId` | string | The workspace member ID of the tagger | +| ↳ `type` | string | The tag type \(workspace-member or record\) | +| ↳ `workspaceMemberId` | string | The workspace member ID \(present when type is workspace-member\) | +| ↳ `object` | string | The tagged object slug \(present when type is record\) | +| ↳ `recordId` | string | The tagged record ID \(present when type is record\) | | ↳ `createdByActor` | object | The actor who created the note | | ↳ `type` | string | The actor type \(e.g. workspace-member, api-token, system\) | | ↳ `id` | string | The actor ID | @@ -264,8 +266,10 @@ Get a single note by ID from Attio | `contentMarkdown` | string | The note content as markdown | | `meetingId` | string | The linked meeting ID | | `tags` | array | Tags on the note | -| ↳ `type` | string | The tag type \(e.g. workspace-member\) | -| ↳ `workspaceMemberId` | string | The workspace member ID of the tagger | +| ↳ `type` | string | The tag type \(workspace-member or record\) | +| ↳ `workspaceMemberId` | string | The workspace member ID \(present when type is workspace-member\) | +| ↳ `object` | string | The tagged object slug \(present when type is record\) | +| ↳ `recordId` | string | The tagged record ID \(present when type is record\) | | `createdByActor` | object | The actor who created the note | | ↳ `type` | string | The actor type \(e.g. workspace-member, api-token, system\) | | ↳ `id` | string | The actor ID | @@ -299,8 +303,10 @@ Create a note on a record in Attio | `contentMarkdown` | string | The note content as markdown | | `meetingId` | string | The linked meeting ID | | `tags` | array | Tags on the note | -| ↳ `type` | string | The tag type \(e.g. workspace-member\) | -| ↳ `workspaceMemberId` | string | The workspace member ID of the tagger | +| ↳ `type` | string | The tag type \(workspace-member or record\) | +| ↳ `workspaceMemberId` | string | The workspace member ID \(present when type is workspace-member\) | +| ↳ `object` | string | The tagged object slug \(present when type is record\) | +| ↳ `recordId` | string | The tagged record ID \(present when type is record\) | | `createdByActor` | object | The actor who created the note | | ↳ `type` | string | The actor type \(e.g. workspace-member, api-token, system\) | | ↳ `id` | string | The actor ID | @@ -334,7 +340,7 @@ List tasks in Attio, optionally filtered by record, assignee, or completion stat | `linkedRecordId` | string | No | Record ID to filter tasks by \(requires linkedObject\) | | `assignee` | string | No | Assignee email or member ID to filter by | | `isCompleted` | boolean | No | Filter by completion status | -| `sort` | string | No | Sort order: created_at:asc or created_at:desc | +| `sort` | string | No | Sort order: created_at:asc, created_at:desc, completed_at:asc, or completed_at:desc | | `limit` | number | No | Maximum number of tasks to return \(default 500\) | | `offset` | number | No | Number of tasks to skip for pagination | @@ -347,6 +353,7 @@ List tasks in Attio, optionally filtered by record, assignee, or completion stat | ↳ `content` | string | The task content | | ↳ `deadlineAt` | string | The task deadline | | ↳ `isCompleted` | boolean | Whether the task is completed | +| ↳ `completedAt` | string | When the task was completed | | ↳ `linkedRecords` | array | Records linked to this task | | ↳ `targetObjectId` | string | The linked object ID | | ↳ `targetRecordId` | string | The linked record ID | @@ -377,6 +384,7 @@ Get a single task by ID from Attio | `content` | string | The task content | | `deadlineAt` | string | The task deadline | | `isCompleted` | boolean | Whether the task is completed | +| `completedAt` | string | When the task was completed | | `linkedRecords` | array | Records linked to this task | | ↳ `targetObjectId` | string | The linked object ID | | ↳ `targetRecordId` | string | The linked record ID | @@ -410,6 +418,7 @@ Create a task in Attio | `content` | string | The task content | | `deadlineAt` | string | The task deadline | | `isCompleted` | boolean | Whether the task is completed | +| `completedAt` | string | When the task was completed | | `linkedRecords` | array | Records linked to this task | | ↳ `targetObjectId` | string | The linked object ID | | ↳ `targetRecordId` | string | The linked record ID | @@ -443,6 +452,7 @@ Update a task in Attio (deadline, completion status, linked records, assignees) | `content` | string | The task content | | `deadlineAt` | string | The task deadline | | `isCompleted` | boolean | Whether the task is completed | +| `completedAt` | string | When the task was completed | | `linkedRecords` | array | Records linked to this task | | ↳ `targetObjectId` | string | The linked object ID | | ↳ `targetRecordId` | string | The linked record ID | @@ -835,9 +845,11 @@ Create a comment on a list entry in Attio | `format` | string | No | Content format: plaintext or markdown \(default plaintext\) | | `authorType` | string | Yes | Author type \(e.g. workspace-member\) | | `authorId` | string | Yes | Author workspace member ID | -| `list` | string | Yes | The list ID or slug the entry belongs to | -| `entryId` | string | Yes | The entry ID to comment on | -| `threadId` | string | No | Thread ID to reply to \(omit to start a new thread\) | +| `list` | string | No | The list ID or slug the entry belongs to \(used with entryId; omit if threadId or recordId is set\) | +| `entryId` | string | No | The list entry ID to comment on \(used with list; omit if threadId or recordId is set\) | +| `recordObject` | string | No | The object ID or slug the record belongs to \(used with recordId; omit if threadId or entryId is set\) | +| `recordId` | string | No | The record ID to comment on directly \(used with recordObject; omit if threadId or entryId is set\) | +| `threadId` | string | No | Thread ID to reply to \(omit to start a new thread on a record or list entry\) | | `createdAt` | string | No | Backdate the comment \(ISO 8601 format\) | #### Output @@ -1072,6 +1084,156 @@ Delete a webhook from Attio | --------- | ---- | ----------- | | `deleted` | boolean | Whether the webhook was deleted | +### `attio_list_attributes` + +List the attributes (schema fields) defined on an Attio object or list + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `target` | string | Yes | Whether the attributes belong to an object or a list: objects or lists | +| `identifier` | string | Yes | The object or list ID or slug \(e.g. people, companies\) | +| `limit` | number | No | Maximum number of attributes to return | +| `offset` | number | No | Number of attributes to skip for pagination | +| `showArchived` | boolean | No | Whether to include archived attributes \(default false\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `attributes` | array | Array of attributes | +| ↳ `attributeId` | string | The attribute ID | +| ↳ `title` | string | The attribute display title | +| ↳ `apiSlug` | string | The attribute API slug | +| ↳ `description` | string | The attribute description | +| ↳ `type` | string | The attribute value type \(e.g. text, number, select, record-reference\) | +| ↳ `isSystemAttribute` | boolean | Whether this is a built-in system attribute | +| ↳ `isWritable` | boolean | Whether the attribute can be written to | +| ↳ `isRequired` | boolean | Whether new records must provide a value | +| ↳ `isUnique` | boolean | Whether the attribute enforces uniqueness | +| ↳ `isMultiselect` | boolean | Whether the attribute supports multiple values | +| ↳ `isDefaultValueEnabled` | boolean | Whether this attribute has a default value enabled | +| ↳ `isArchived` | boolean | Whether the attribute is archived | +| ↳ `defaultValue` | json | The default value for this attribute, if enabled | +| ↳ `relationship` | json | The related attribute, if this attribute is part of a relationship | +| ↳ `config` | json | Type-dependent attribute configuration | +| ↳ `createdAt` | string | When the attribute was created | +| `count` | number | Number of attributes returned | + +### `attio_get_attribute` + +Get a single attribute (schema field) on an Attio object or list + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `target` | string | Yes | Whether the attribute belongs to an object or a list: objects or lists | +| `identifier` | string | Yes | The object or list ID or slug \(e.g. people, companies\) | +| `attribute` | string | Yes | The attribute ID or slug | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `attributeId` | string | The attribute ID | +| `title` | string | The attribute display title | +| `apiSlug` | string | The attribute API slug | +| `description` | string | The attribute description | +| `type` | string | The attribute value type \(e.g. text, number, select, record-reference\) | +| `isSystemAttribute` | boolean | Whether this is a built-in system attribute | +| `isWritable` | boolean | Whether the attribute can be written to | +| `isRequired` | boolean | Whether new records must provide a value | +| `isUnique` | boolean | Whether the attribute enforces uniqueness | +| `isMultiselect` | boolean | Whether the attribute supports multiple values | +| `isDefaultValueEnabled` | boolean | Whether this attribute has a default value enabled | +| `isArchived` | boolean | Whether the attribute is archived | +| `defaultValue` | json | The default value for this attribute, if enabled | +| `relationship` | json | The related attribute, if this attribute is part of a relationship | +| `config` | json | Type-dependent attribute configuration | +| `createdAt` | string | When the attribute was created | + +### `attio_create_attribute` + +Create a new attribute (schema field) on an Attio object or list + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `target` | string | Yes | Whether to create the attribute on an object or a list: objects or lists | +| `identifier` | string | Yes | The object or list ID or slug \(e.g. people, companies\) | +| `title` | string | Yes | The attribute display title | +| `apiSlug` | string | Yes | The attribute API slug \(unique, snake_case\) | +| `type` | string | Yes | The attribute value type \(e.g. text, number, checkbox, currency, date, timestamp, rating, status, select, record-reference, actor-reference, location, domain, email-address, phone-number\) | +| `description` | string | No | A description of the attribute | +| `isRequired` | boolean | No | Whether new records must provide a value \(default false\) | +| `isUnique` | boolean | No | Whether the attribute enforces uniqueness on new data \(default false\) | +| `isMultiselect` | boolean | No | Whether the attribute supports multiple values \(default false\) | +| `config` | string | No | JSON object of type-dependent configuration \(e.g. currency or record-reference settings\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `attributeId` | string | The attribute ID | +| `title` | string | The attribute display title | +| `apiSlug` | string | The attribute API slug | +| `description` | string | The attribute description | +| `type` | string | The attribute value type \(e.g. text, number, select, record-reference\) | +| `isSystemAttribute` | boolean | Whether this is a built-in system attribute | +| `isWritable` | boolean | Whether the attribute can be written to | +| `isRequired` | boolean | Whether new records must provide a value | +| `isUnique` | boolean | Whether the attribute enforces uniqueness | +| `isMultiselect` | boolean | Whether the attribute supports multiple values | +| `isDefaultValueEnabled` | boolean | Whether this attribute has a default value enabled | +| `isArchived` | boolean | Whether the attribute is archived | +| `defaultValue` | json | The default value for this attribute, if enabled | +| `relationship` | json | The related attribute, if this attribute is part of a relationship | +| `config` | json | Type-dependent attribute configuration | +| `createdAt` | string | When the attribute was created | + +### `attio_update_attribute` + +Update an attribute (schema field) on an Attio object or list + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `target` | string | Yes | Whether the attribute belongs to an object or a list: objects or lists | +| `identifier` | string | Yes | The object or list ID or slug \(e.g. people, companies\) | +| `attribute` | string | Yes | The attribute ID or slug to update | +| `title` | string | No | New attribute display title | +| `apiSlug` | string | No | New attribute API slug | +| `description` | string | No | New attribute description | +| `isRequired` | boolean | No | Whether new records must provide a value | +| `isUnique` | boolean | No | Whether the attribute enforces uniqueness on new data | +| `isArchived` | boolean | No | Archive or unarchive the attribute | +| `config` | string | No | JSON object of type-dependent configuration | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `attributeId` | string | The attribute ID | +| `title` | string | The attribute display title | +| `apiSlug` | string | The attribute API slug | +| `description` | string | The attribute description | +| `type` | string | The attribute value type \(e.g. text, number, select, record-reference\) | +| `isSystemAttribute` | boolean | Whether this is a built-in system attribute | +| `isWritable` | boolean | Whether the attribute can be written to | +| `isRequired` | boolean | Whether new records must provide a value | +| `isUnique` | boolean | Whether the attribute enforces uniqueness | +| `isMultiselect` | boolean | Whether the attribute supports multiple values | +| `isDefaultValueEnabled` | boolean | Whether this attribute has a default value enabled | +| `isArchived` | boolean | Whether the attribute is archived | +| `defaultValue` | json | The default value for this attribute, if enabled | +| `relationship` | json | The related attribute, if this attribute is part of a relationship | +| `config` | json | Type-dependent attribute configuration | +| `createdAt` | string | When the attribute was created | + ## Triggers diff --git a/apps/docs/content/docs/en/integrations/brightdata.mdx b/apps/docs/content/docs/en/integrations/brightdata.mdx index 763ebba25b9..2cbf754f4eb 100644 --- a/apps/docs/content/docs/en/integrations/brightdata.mdx +++ b/apps/docs/content/docs/en/integrations/brightdata.mdx @@ -31,6 +31,7 @@ Fetch content from any URL using Bright Data Web Unlocker. Bypasses anti-bot pro | `url` | string | Yes | The URL to scrape \(e.g., "https://example.com/page"\) | | `format` | string | No | Response format: "raw" for HTML or "json" for parsed content. Defaults to "raw" | | `country` | string | No | Two-letter country code for geo-targeting \(e.g., "us", "gb"\) | +| `dataFormat` | string | No | Convert the response to "markdown" instead of raw HTML, useful for feeding page content to an LLM. Omit for the default HTML/JSON response | #### Output @@ -70,7 +71,7 @@ Search Google, Bing, DuckDuckGo, or Yandex and get structured search results usi ### `brightdata_discover` -AI-powered web discovery that finds and ranks results by intent. Returns up to 1,000 results with optional cleaned page content for RAG and verification. +AI-powered web discovery that finds and ranks results by intent. Returns up to 20 results with optional cleaned page content for RAG and verification. #### Input @@ -78,10 +79,11 @@ AI-powered web discovery that finds and ranks results by intent. Returns up to 1 | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | Bright Data API token | | `query` | string | Yes | The search query \(e.g., "competitor pricing changes enterprise plan"\) | -| `numResults` | number | No | Number of results to return, up to 1000. Defaults to 10 | +| `numResults` | number | No | Number of results to return \(1-20\). Defaults to 10 | +| `mode` | string | No | Search depth and ranking mode: "standard" \(balanced\), "deep" \(exhaustive, broader search\), "fast" \(optimized for speed\), or "zeroRanking" \(raw volume without AI filtering\). Defaults to "standard" | | `intent` | string | No | Describes what the agent is trying to accomplish, used to rank results by relevance \(e.g., "find official pricing pages and change notes"\) | | `includeContent` | boolean | No | Whether to include cleaned page content in results | -| `format` | string | No | Response format: "json" or "markdown". Defaults to "json" | +| `format` | string | No | Response format: "json" or "md". Defaults to "json" | | `language` | string | No | Search language code \(e.g., "en", "es", "fr"\). Defaults to "en" | | `country` | string | No | Two-letter ISO country code for localized results \(e.g., "us", "gb"\) | @@ -132,6 +134,7 @@ Trigger a Bright Data pre-built scraper to extract structured data from URLs. Su | `datasetId` | string | Yes | Dataset scraper ID from your Bright Data dashboard \(e.g., "gd_l1viktl72bvl7bjuj0"\) | | `urls` | string | Yes | JSON array of URL objects to scrape \(e.g., \[\{"url": "https://example.com/product"\}\]\) | | `format` | string | No | Output format: "json" or "csv". Defaults to "json" | +| `includeErrors` | boolean | No | Whether to include a per-input error report in the results | #### Output diff --git a/apps/docs/content/docs/en/integrations/cloudformation.mdx b/apps/docs/content/docs/en/integrations/cloudformation.mdx index 064c832a59d..afe668068ab 100644 --- a/apps/docs/content/docs/en/integrations/cloudformation.mdx +++ b/apps/docs/content/docs/en/integrations/cloudformation.mdx @@ -29,7 +29,7 @@ In Sim, the CloudFormation integration enables your agents to monitor infrastruc ## Usage Instructions -Integrate AWS CloudFormation into workflows. Describe stacks, list resources, detect drift, view stack events, retrieve templates, and validate templates. Requires AWS access key and secret access key. +Integrate AWS CloudFormation into workflows. Create, update, and delete stacks, preview changes with change sets, describe stacks, list resources, detect drift, view stack events, and retrieve or validate templates. Requires AWS access key and secret access key. @@ -54,6 +54,171 @@ List and describe CloudFormation stacks | --------- | ---- | ----------- | | `stacks` | array | List of CloudFormation stacks with status, outputs, and tags | +### `cloudformation_create_stack` + +Create a new CloudFormation stack from a template + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `stackName` | string | Yes | Name for the new stack \(must be unique in the Region\) | +| `templateBody` | string | Yes | The CloudFormation template body \(JSON or YAML\) | +| `parameters` | json | No | Template input parameters \(e.g., \[\{"parameterKey": "InstanceType", "parameterValue": "t3.micro"\}\]\) | +| `capabilities` | string | No | Comma-separated capabilities to acknowledge \(CAPABILITY_IAM, CAPABILITY_NAMED_IAM, CAPABILITY_AUTO_EXPAND\) required when the template creates IAM resources or uses macros | +| `tags` | json | No | Tags to apply to the stack and its resources \(e.g., \[\{"key": "env", "value": "prod"\}\]\) | +| `onFailure` | string | No | Action to take on creation failure: ROLLBACK \(default\), DELETE, or DO_NOTHING | +| `timeoutInMinutes` | number | No | Amount of time before the stack creation times out and rolls back | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `stackId` | string | The unique ID of the created stack | + +### `cloudformation_update_stack` + +Update an existing CloudFormation stack with a new or previous template + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `stackName` | string | Yes | Name or ID of the stack to update | +| `templateBody` | string | No | The new CloudFormation template body \(JSON or YAML\). Required unless usePreviousTemplate is true | +| `usePreviousTemplate` | boolean | No | Reuse the template currently associated with the stack instead of providing templateBody | +| `parameters` | json | No | Template input parameters \(e.g., \[\{"parameterKey": "InstanceType", "parameterValue": "t3.micro"\}\]\) | +| `capabilities` | string | No | Comma-separated capabilities to acknowledge \(CAPABILITY_IAM, CAPABILITY_NAMED_IAM, CAPABILITY_AUTO_EXPAND\) | +| `tags` | json | No | Tags to apply to the stack and its resources \(e.g., \[\{"key": "env", "value": "prod"\}\]\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `stackId` | string | The unique ID of the updated stack | + +### `cloudformation_delete_stack` + +Delete a CloudFormation stack and its resources + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `stackName` | string | Yes | Name or ID of the stack to delete | +| `retainResources` | string | No | Comma-separated logical resource IDs to retain instead of deleting \(only applies to stacks in DELETE_FAILED state\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Operation status message | + +### `cloudformation_cancel_update_stack` + +Cancel an in-progress stack update and roll back to the last known stable state + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `stackName` | string | Yes | Name or ID of the stack whose update should be cancelled | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Operation status message | + +### `cloudformation_create_change_set` + +Preview the changes a stack create or update would make before applying them + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `stackName` | string | Yes | Name of the stack to create or update \(new name for CREATE type, existing name for UPDATE\) | +| `changeSetName` | string | Yes | Name for the new change set | +| `templateBody` | string | No | The CloudFormation template body \(JSON or YAML\). Required unless usePreviousTemplate is true | +| `usePreviousTemplate` | boolean | No | Reuse the template currently associated with the stack \(UPDATE change sets only\) | +| `parameters` | json | No | Template input parameters \(e.g., \[\{"parameterKey": "InstanceType", "parameterValue": "t3.micro"\}\]\) | +| `capabilities` | string | No | Comma-separated capabilities to acknowledge \(CAPABILITY_IAM, CAPABILITY_NAMED_IAM, CAPABILITY_AUTO_EXPAND\) | +| `changeSetType` | string | No | CREATE \(default, new stack\), UPDATE \(existing stack\), or IMPORT \(import existing resources\) | +| `description` | string | No | Description of the change set for reference | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `changeSetId` | string | The unique ID of the created change set | +| `stackId` | string | The unique ID of the target stack | + +### `cloudformation_describe_change_set` + +View the resource changes a change set would make and its execution status + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `changeSetName` | string | Yes | Name or ARN of the change set to describe | +| `stackName` | string | No | Name or ID of the stack the change set belongs to \(required if changeSetName is not an ARN\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `changeSetName` | string | Name of the change set | +| `changeSetId` | string | The unique ID of the change set | +| `stackId` | string | The unique ID of the target stack | +| `stackName` | string | Name of the target stack | +| `description` | string | Description of the change set | +| `executionStatus` | string | Whether the change set can be executed \(AVAILABLE, UNAVAILABLE, EXECUTE_IN_PROGRESS, EXECUTE_COMPLETE, EXECUTE_FAILED, OBSOLETE\) | +| `status` | string | Current status of the change set \(CREATE_PENDING, CREATE_IN_PROGRESS, CREATE_COMPLETE, DELETE_COMPLETE, FAILED\) | +| `statusReason` | string | Reason for the current status, particularly if failed | +| `creationTime` | number | Timestamp the change set was created | +| `capabilities` | array | Capabilities required to execute the change set | +| `changes` | array | List of resource changes \(action, logical/physical resource ID, resource type, replacement\) | + +### `cloudformation_execute_change_set` + +Apply a previously created and reviewed change set to its stack + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `changeSetName` | string | Yes | Name or ARN of the change set to execute | +| `stackName` | string | No | Name or ID of the stack the change set belongs to \(required if changeSetName is not an ARN\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Operation status message | + ### `cloudformation_list_stack_resources` List all resources in a CloudFormation stack @@ -149,6 +314,7 @@ Retrieve the template body for a CloudFormation stack | `awsAccessKeyId` | string | Yes | AWS access key ID | | `awsSecretAccessKey` | string | Yes | AWS secret access key | | `stackName` | string | Yes | Stack name or ID | +| `templateStage` | string | No | Which template version to retrieve: Processed \(default, with transforms applied\) or Original \(as submitted\) | #### Output @@ -157,6 +323,32 @@ Retrieve the template body for a CloudFormation stack | `templateBody` | string | The template body as a JSON or YAML string | | `stagesAvailable` | array | Available template stages | +### `cloudformation_get_template_summary` + +Get a summary of a template or deployed stack: resource types, required capabilities, and parameters, without full validation + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `templateBody` | string | No | The CloudFormation template body \(JSON or YAML\). Required if stackName is not provided | +| `stackName` | string | No | Name or ID of a deployed stack to summarize instead of a template body | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `description` | string | Template description | +| `parameters` | array | Template parameters with types, defaults, and descriptions | +| `capabilities` | array | Required capabilities \(e.g., CAPABILITY_IAM\) | +| `capabilitiesReason` | string | Reason capabilities are required | +| `resourceTypes` | array | AWS resource types declared in the template \(e.g., AWS::S3::Bucket\) | +| `version` | string | Template format version | +| `declaredTransforms` | array | Transforms used in the template \(e.g., AWS::Serverless-2016-10-31\) | + ### `cloudformation_validate_template` Validate a CloudFormation template for syntax and structural correctness diff --git a/apps/docs/content/docs/en/integrations/cloudwatch.mdx b/apps/docs/content/docs/en/integrations/cloudwatch.mdx index 6c451cd5c85..04836a57b03 100644 --- a/apps/docs/content/docs/en/integrations/cloudwatch.mdx +++ b/apps/docs/content/docs/en/integrations/cloudwatch.mdx @@ -64,6 +64,35 @@ Run a CloudWatch Log Insights query against one or more log groups | ↳ `recordsScanned` | number | Total log records scanned | | `status` | string | Query completion status \(Complete, Failed, Cancelled, or Timeout\) | +### `cloudwatch_filter_log_events` + +Search log events across all streams in a log group by filter pattern and time range, without writing a Log Insights query + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `logGroupName` | string | Yes | CloudWatch log group name to search | +| `filterPattern` | string | No | CloudWatch Logs filter pattern \(e.g., "ERROR", "?ERROR ?Exception"\). Matches all events if omitted. | +| `logStreamNamePrefix` | string | No | Only search log streams whose name starts with this prefix | +| `startTime` | number | No | Start time as Unix epoch seconds | +| `endTime` | number | No | End time as Unix epoch seconds | +| `startFromHead` | boolean | No | Return the earliest matching events first instead of the latest | +| `limit` | number | No | Maximum number of events to return | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `events` | array | Matching log events across all searched streams, sorted by timestamp | +| ↳ `logStreamName` | string | Log stream the event belongs to | +| ↳ `timestamp` | number | Event timestamp in epoch milliseconds | +| ↳ `message` | string | Log event message | +| ↳ `ingestionTime` | number | Ingestion time in epoch milliseconds | + ### `cloudwatch_describe_log_groups` List available CloudWatch log groups @@ -141,6 +170,28 @@ List log streams within a CloudWatch log group | ↳ `creationTime` | number | Stream creation time in epoch milliseconds | | ↳ `storedBytes` | number | Total stored bytes | +### `cloudwatch_put_log_group_retention` + +Set (or clear, for never-expire) the retention period for a CloudWatch log group + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `logGroupName` | string | Yes | CloudWatch log group name | +| `retentionInDays` | number | No | Days to retain log events \(one of 1, 3, 5, 7, 14, 30, 60, 90, 120, 150, 180, 365, 400, 545, 731, 1096, 1827, 2192, 2557, 2922, 3288, 3653\). Omit to make events never expire. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the retention policy was updated | +| `logGroupName` | string | Log group the policy applies to | +| `retentionInDays` | number | Retention period in days, or null if events never expire | + ### `cloudwatch_list_metrics` List available CloudWatch metrics @@ -257,6 +308,35 @@ List and filter CloudWatch alarms | ↳ `threshold` | number | Threshold value \(MetricAlarm only\) | | ↳ `stateUpdatedTimestamp` | number | Epoch ms when state last changed | +### `cloudwatch_describe_alarm_history` + +Retrieve state-change and configuration history for CloudWatch alarms + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `alarmName` | string | No | Name of a specific alarm to retrieve history for. Omit for all alarms. | +| `historyItemType` | string | No | Filter by history item type \(ConfigurationUpdate, StateUpdate, Action, AlarmContributorStateUpdate, AlarmContributorAction\) | +| `startDate` | number | No | Start of the history window as Unix epoch seconds | +| `endDate` | number | No | End of the history window as Unix epoch seconds | +| `scanBy` | string | No | Sort order: TimestampDescending \(newest first\) or TimestampAscending | +| `limit` | number | No | Maximum number of history records to return | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `alarmHistoryItems` | array | Alarm history items sorted per scanBy, newest first by default | +| ↳ `alarmName` | string | Name of the alarm this history item belongs to | +| ↳ `alarmType` | string | MetricAlarm or CompositeAlarm | +| ↳ `timestamp` | number | Epoch ms when the history item occurred | +| ↳ `historyItemType` | string | ConfigurationUpdate, StateUpdate, Action, or contributor variants | +| ↳ `historySummary` | string | Human-readable summary of the event | + ### `cloudwatch_mute_alarm` Create a CloudWatch alarm mute rule that suppresses alarms for a fixed duration diff --git a/apps/docs/content/docs/en/integrations/codepipeline.mdx b/apps/docs/content/docs/en/integrations/codepipeline.mdx index 8dee8fae7d9..155de0cb7d6 100644 --- a/apps/docs/content/docs/en/integrations/codepipeline.mdx +++ b/apps/docs/content/docs/en/integrations/codepipeline.mdx @@ -45,6 +45,42 @@ List all CodePipeline pipelines in an AWS account and region | ↳ `updated` | number | Epoch ms when the pipeline was last updated | | `nextToken` | string | Pagination token for the next page of results | +### `codepipeline_get_pipeline` + +Get the structure of a CodePipeline pipeline, including its stages, actions, and variables + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `pipelineName` | string | Yes | Name of the pipeline | +| `version` | number | No | Pipeline version to retrieve \(defaults to the current version\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `pipelineName` | string | Pipeline name | +| `pipelineArn` | string | Pipeline ARN | +| `roleArn` | string | IAM role ARN the pipeline assumes | +| `version` | number | Pipeline version number | +| `pipelineType` | string | Pipeline type \(V1 or V2\) | +| `executionMode` | string | Execution mode \(QUEUED, SUPERSEDED, PARALLEL\) | +| `artifactStoreType` | string | Artifact store type \(S3\) | +| `artifactStoreLocation` | string | Artifact store bucket location | +| `stages` | array | Pipeline stages with their actions \(name, category, provider, configuration\) | +| ↳ `stageName` | string | Stage name | +| ↳ `actions` | array | Actions in the stage, in run order | +| `variables` | array | Pipeline variable declarations with default values | +| ↳ `name` | string | Variable name | +| ↳ `defaultValue` | string | Default value | +| ↳ `description` | string | Variable description | +| `created` | number | Epoch ms when the pipeline was created | +| `updated` | number | Epoch ms when the pipeline was last updated | + ### `codepipeline_get_pipeline_state` Get the current state of a CodePipeline pipeline, including stage and action status and pending approval tokens @@ -141,9 +177,47 @@ List recent executions of a CodePipeline pipeline with status and source revisio | ↳ `stopTriggerReason` | string | Reason the execution was stopped, if applicable | | ↳ `triggerType` | string | What triggered the execution | | ↳ `triggerDetail` | string | Detail about the trigger | +| ↳ `rollbackTargetPipelineExecutionId` | string | Execution ID this run rolled back to, if it was a rollback | | ↳ `sourceRevisions` | array | Source revisions \(commit IDs, summaries, URLs\) for the execution | | `nextToken` | string | Pagination token for the next page of results | +### `codepipeline_list_action_executions` + +List action-level execution history for a CodePipeline pipeline, including per-action status, timing, and error details + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `pipelineName` | string | Yes | Name of the pipeline | +| `pipelineExecutionId` | string | No | Only return action executions for this pipeline execution | +| `maxResults` | number | No | Maximum number of action executions to return \(1-100, default 100\) | +| `nextToken` | string | No | Pagination token from a previous call | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `actionExecutionDetails` | array | Action execution history, most recent first | +| ↳ `pipelineExecutionId` | string | Pipeline execution ID | +| ↳ `actionExecutionId` | string | Action execution ID \(use as the approval token for PARALLEL execution-mode pipelines\) | +| ↳ `pipelineVersion` | number | Pipeline version number | +| ↳ `stageName` | string | Stage the action belongs to | +| ↳ `actionName` | string | Action name | +| ↳ `startTime` | number | Epoch ms when the action started | +| ↳ `lastUpdateTime` | number | Epoch ms when the action was last updated | +| ↳ `updatedBy` | string | Who or what last updated the action | +| ↳ `status` | string | Action execution status \(InProgress, Abandoned, Succeeded, Failed\) | +| ↳ `externalExecutionId` | string | ID of the external system execution \(e.g., CodeBuild build ID\) | +| ↳ `externalExecutionSummary` | string | Summary from the external system execution | +| ↳ `externalExecutionUrl` | string | URL of the external system execution | +| ↳ `errorCode` | string | Error code if the action failed | +| ↳ `errorMessage` | string | Error message if the action failed | +| `nextToken` | string | Pagination token for the next page of results | + ### `codepipeline_start_execution` Start a CodePipeline pipeline execution, optionally overriding pipeline variables @@ -234,4 +308,51 @@ Approve or reject a pending CodePipeline manual approval action. The approval to | `approvedAt` | number | Epoch ms when the approval or rejection was submitted | | `status` | string | The submitted approval decision \(Approved or Rejected\) | +### `codepipeline_disable_stage_transition` + +Prevent artifacts from transitioning into or out of a CodePipeline stage, freezing the pipeline at that point + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `pipelineName` | string | Yes | Name of the pipeline | +| `stageName` | string | Yes | Name of the stage to disable the transition for | +| `transitionType` | string | Yes | Inbound to block artifacts entering the stage, Outbound to block artifacts leaving it | +| `reason` | string | Yes | Reason the transition is disabled, shown in the pipeline console \(max 300 characters\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `pipelineName` | string | Pipeline name | +| `stageName` | string | Stage whose transition was disabled | +| `transitionType` | string | Transition type that was disabled \(Inbound or Outbound\) | + +### `codepipeline_enable_stage_transition` + +Re-enable artifacts transitioning into or out of a CodePipeline stage after it was disabled + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `awsRegion` | string | Yes | AWS region \(e.g., us-east-1\) | +| `awsAccessKeyId` | string | Yes | AWS access key ID | +| `awsSecretAccessKey` | string | Yes | AWS secret access key | +| `pipelineName` | string | Yes | Name of the pipeline | +| `stageName` | string | Yes | Name of the stage to enable the transition for | +| `transitionType` | string | Yes | Inbound to allow artifacts entering the stage, Outbound to allow artifacts leaving it | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `pipelineName` | string | Pipeline name | +| `stageName` | string | Stage whose transition was enabled | +| `transitionType` | string | Transition type that was enabled \(Inbound or Outbound\) | + diff --git a/apps/docs/content/docs/en/integrations/discord.mdx b/apps/docs/content/docs/en/integrations/discord.mdx index 91011794893..1878bb30336 100644 --- a/apps/docs/content/docs/en/integrations/discord.mdx +++ b/apps/docs/content/docs/en/integrations/discord.mdx @@ -140,8 +140,8 @@ Retrieve information about a Discord server (guild) | ↳ `description` | string | Server description | | ↳ `owner_id` | string | Server owner user ID | | ↳ `roles` | array | Server roles | -| ↳ `channels` | array | Server channels | -| ↳ `member_count` | number | Number of members in server | +| ↳ `approximate_member_count` | number | Approximate total member count | +| ↳ `approximate_presence_count` | number | Approximate online member count | ### `discord_get_user` @@ -213,6 +213,25 @@ Delete a message from a Discord channel | --------- | ---- | ----------- | | `message` | string | Success or error message | +### `discord_bulk_delete_messages` + +Delete 2-100 messages from a Discord channel in a single request + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `botToken` | string | Yes | The bot token for authentication | +| `channelId` | string | Yes | The Discord channel ID to delete messages from, e.g., 123456789012345678 | +| `messageIds` | json | Yes | Array of 2-100 message IDs to delete. Messages older than 2 weeks cannot be bulk deleted. | +| `serverId` | string | Yes | The Discord server ID \(guild ID\), e.g., 123456789012345678 | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Success or error message | + ### `discord_add_reaction` Add a reaction emoji to a Discord message @@ -292,6 +311,35 @@ Unpin a message in a Discord channel | --------- | ---- | ----------- | | `message` | string | Success or error message | +### `discord_get_pinned_messages` + +Retrieve all pinned messages in a Discord channel + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `botToken` | string | Yes | The bot token for authentication | +| `channelId` | string | Yes | The Discord channel ID to retrieve pinned messages from, e.g., 123456789012345678 | +| `limit` | number | No | Maximum number of pins to return per page \(1-50\). Defaults to 50. | +| `before` | string | No | Return pins created before this ISO8601 timestamp, for paging past the first 50 results | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Success or error message | +| `data` | array | Array of pinned Discord messages | +| ↳ `id` | string | Message ID | +| ↳ `content` | string | Message content | +| ↳ `channel_id` | string | Channel ID | +| ↳ `timestamp` | string | Message timestamp | +| ↳ `pinned_at` | string | When the message was pinned | +| ↳ `author` | object | Message author information | +| ↳ `id` | string | Author user ID | +| ↳ `username` | string | Author username | +| `hasMore` | boolean | Whether more pinned messages exist beyond this page | + ### `discord_create_thread` Create a thread in a Discord channel @@ -305,6 +353,7 @@ Create a thread in a Discord channel | `name` | string | Yes | The name of the thread \(1-100 characters\) | | `messageId` | string | No | The message ID to create a thread from \(if creating from existing message\), e.g., 123456789012345678 | | `autoArchiveDuration` | number | No | Duration in minutes to auto-archive the thread \(60, 1440, 4320, 10080\) | +| `isPublic` | boolean | No | Whether the standalone thread is public \(visible to everyone in the channel\) or private. Ignored when creating a thread from an existing message, which always inherits the parent channel visibility. Defaults to public if omitted. | | `serverId` | string | Yes | The Discord server ID \(guild ID\), e.g., 123456789012345678 | #### Output @@ -445,6 +494,11 @@ Delete a Discord channel | Parameter | Type | Description | | --------- | ---- | ----------- | | `message` | string | Success or error message | +| `data` | object | The deleted channel, as returned by Discord | +| ↳ `id` | string | Channel ID | +| ↳ `name` | string | Channel name | +| ↳ `type` | number | Channel type | +| ↳ `guild_id` | string | Server ID | ### `discord_get_channel` @@ -470,6 +524,30 @@ Get information about a Discord channel | ↳ `topic` | string | Channel topic | | ↳ `guild_id` | string | Server ID | +### `discord_list_channels` + +List all channels in a Discord server + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `botToken` | string | Yes | The bot token for authentication | +| `serverId` | string | Yes | The Discord server ID \(guild ID\), e.g., 123456789012345678 | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Success or error message | +| `data` | array | Array of Discord channels in the server | +| ↳ `id` | string | Channel ID | +| ↳ `name` | string | Channel name | +| ↳ `type` | number | Channel type | +| ↳ `topic` | string | Channel topic | +| ↳ `parent_id` | string | Parent category ID | +| ↳ `position` | number | Sort position within the channel list | + ### `discord_create_role` Create a new role in a Discord server @@ -579,6 +657,30 @@ Remove a role from a member in a Discord server | --------- | ---- | ----------- | | `message` | string | Success or error message | +### `discord_list_roles` + +List all roles in a Discord server + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `botToken` | string | Yes | The bot token for authentication | +| `serverId` | string | Yes | The Discord server ID \(guild ID\), e.g., 123456789012345678 | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `message` | string | Success or error message | +| `data` | array | Array of Discord roles in the server | +| ↳ `id` | string | Role ID | +| ↳ `name` | string | Role name | +| ↳ `color` | number | Role color | +| ↳ `hoist` | boolean | Whether role is hoisted | +| ↳ `position` | number | Role position in the hierarchy | +| ↳ `mentionable` | boolean | Whether role is mentionable | + ### `discord_kick_member` Kick a member from a Discord server @@ -610,7 +712,7 @@ Ban a member from a Discord server | `serverId` | string | Yes | The Discord server ID \(guild ID\), e.g., 123456789012345678 | | `userId` | string | Yes | The user ID to ban, e.g., 123456789012345678 | | `reason` | string | No | Reason for banning the member | -| `deleteMessageDays` | number | No | Number of days to delete messages for \(0-7\) | +| `deleteMessageSeconds` | number | No | Seconds of message history to delete, 0-604800 \(7 days\) | #### Output diff --git a/apps/docs/content/docs/en/integrations/dropbox.mdx b/apps/docs/content/docs/en/integrations/dropbox.mdx index 553c76b064a..362730b768b 100644 --- a/apps/docs/content/docs/en/integrations/dropbox.mdx +++ b/apps/docs/content/docs/en/integrations/dropbox.mdx @@ -216,10 +216,10 @@ Get metadata for a file or folder in Dropbox | ↳ `path_display` | string | Display path | | ↳ `path_lower` | string | Lowercase path | | ↳ `size` | number | Size in bytes \(files only\) | -| ↳ `client_modified` | string | Client modification time | -| ↳ `server_modified` | string | Server modification time | -| ↳ `rev` | string | Revision identifier | -| ↳ `content_hash` | string | Content hash | +| ↳ `client_modified` | string | Client modification time \(files only\) | +| ↳ `server_modified` | string | Server modification time \(files only\) | +| ↳ `rev` | string | Revision identifier \(files only\) | +| ↳ `content_hash` | string | Content hash \(files only\) | ### `dropbox_create_shared_link` @@ -245,6 +245,30 @@ Create a shareable link for a file or folder in Dropbox | ↳ `expires` | string | Expiration date if set | | ↳ `link_permissions` | object | Permissions for the shared link | +### `dropbox_list_shared_links` + +List shared links for a path, or for the entire account if no path is given + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `path` | string | No | Path to list shared links for. If omitted, lists all shared links. | +| `directOnly` | boolean | No | If true, only return links directly to the path, not parent folder links | +| `cursor` | string | No | Cursor from a previous call to fetch the next page of results | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `links` | array | Shared links applicable to the path argument | +| ↳ `url` | string | The shared link URL | +| ↳ `name` | string | Name of the shared item | +| ↳ `path_lower` | string | Lowercase path of the shared item | +| ↳ `expires` | string | Expiration date if set | +| `hasMore` | boolean | Whether there are more results | +| `cursor` | string | Cursor for pagination \(only returned when no path is given\) | + ### `dropbox_search` Search for files and folders in Dropbox @@ -268,4 +292,54 @@ Search for files and folders in Dropbox | `hasMore` | boolean | Whether there are more results | | `cursor` | string | Cursor for pagination | +### `dropbox_list_revisions` + +List the revision history for a file in Dropbox (files only, not folders) + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `path` | string | Yes | The path of the file to list revisions for | +| `limit` | number | No | Maximum number of revisions to return, 1-100 \(default: 10\) | +| `beforeRev` | string | No | Only return revisions before this one. Pass the rev of the last revision from a previous call to fetch the next page. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `entries` | array | The revisions for the file, most recent first | +| ↳ `id` | string | Unique identifier for this revision | +| ↳ `name` | string | Name of the file | +| ↳ `path_display` | string | Display path | +| ↳ `rev` | string | Revision identifier, pass to Restore | +| ↳ `size` | number | Size of this revision in bytes | +| ↳ `server_modified` | string | Server modification time | +| `isDeleted` | boolean | Whether the file identified by the latest revision is deleted or moved | +| `hasMore` | boolean | Whether there are more revisions available | + +### `dropbox_restore` + +Restore a specific revision of a file to the given path + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `path` | string | Yes | The path to save the restored file to | +| `rev` | string | Yes | The revision identifier to restore \(from Dropbox List Revisions\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `metadata` | object | Metadata of the restored file | +| ↳ `id` | string | Unique identifier for the file | +| ↳ `name` | string | Name of the file | +| ↳ `path_display` | string | Display path of the file | +| ↳ `path_lower` | string | Lowercase path of the file | +| ↳ `size` | number | Size of the file in bytes | +| ↳ `rev` | string | Revision identifier of the restored file | +| ↳ `server_modified` | string | Server modification time | + diff --git a/apps/docs/content/docs/en/integrations/dub.mdx b/apps/docs/content/docs/en/integrations/dub.mdx index 6612bec6764..7bed0f7377b 100644 --- a/apps/docs/content/docs/en/integrations/dub.mdx +++ b/apps/docs/content/docs/en/integrations/dub.mdx @@ -48,6 +48,9 @@ Create a new short link with Dub. Supports custom domains, slugs, UTM parameters | `domain` | string | No | Custom domain for the short link \(defaults to dub.sh\) | | `key` | string | No | Custom slug for the short link \(randomly generated if not provided\) | | `externalId` | string | No | External ID for the link in your database | +| `tenantId` | string | No | Tenant ID for grouping links created on behalf of a customer/tenant | +| `folderId` | string | No | Folder ID to organize the link into | +| `trackConversion` | boolean | No | Whether to track conversions \(leads/sales\) for the short link | | `tagIds` | string | No | Comma-separated tag IDs to assign to the link | | `comments` | string | No | Comments for the short link | | `expiresAt` | string | No | Expiration date in ISO 8601 format | @@ -77,8 +80,12 @@ Create a new short link with Dub. Supports custom domains, slugs, UTM parameters | `title` | string | OG title | | `description` | string | OG description | | `tags` | json | Tags assigned to the link \(id, name, color\) | +| `folderId` | string | Folder the link is organized into | +| `tenantId` | string | Tenant ID associated with the link | +| `trackConversion` | boolean | Whether conversion tracking is enabled | | `clicks` | number | Number of clicks | | `leads` | number | Number of leads | +| `conversions` | number | Number of conversions | | `sales` | number | Number of sales | | `saleAmount` | number | Total sale amount in cents | | `lastClicked` | string | Last clicked timestamp | @@ -103,6 +110,9 @@ Create or update a short link by its URL. If a link with the same URL already ex | `domain` | string | No | Custom domain for the short link \(defaults to dub.sh\) | | `key` | string | No | Custom slug for the short link \(randomly generated if not provided\) | | `externalId` | string | No | External ID for the link in your database | +| `tenantId` | string | No | Tenant ID for grouping links created on behalf of a customer/tenant | +| `folderId` | string | No | Folder ID to organize the link into | +| `trackConversion` | boolean | No | Whether to track conversions \(leads/sales\) for the short link | | `tagIds` | string | No | Comma-separated tag IDs to assign to the link | | `comments` | string | No | Comments for the short link | | `expiresAt` | string | No | Expiration date in ISO 8601 format | @@ -132,8 +142,12 @@ Create or update a short link by its URL. If a link with the same URL already ex | `title` | string | OG title | | `description` | string | OG description | | `tags` | json | Tags assigned to the link \(id, name, color\) | +| `folderId` | string | Folder the link is organized into | +| `tenantId` | string | Tenant ID associated with the link | +| `trackConversion` | boolean | Whether conversion tracking is enabled | | `clicks` | number | Number of clicks | | `leads` | number | Number of leads | +| `conversions` | number | Number of conversions | | `sales` | number | Number of sales | | `saleAmount` | number | Total sale amount in cents | | `lastClicked` | string | Last clicked timestamp | @@ -174,8 +188,12 @@ Retrieve information about a short link by its link ID, external ID, or domain + | `title` | string | OG title | | `description` | string | OG description | | `tags` | json | Tags assigned to the link \(id, name, color\) | +| `folderId` | string | Folder the link is organized into | +| `tenantId` | string | Tenant ID associated with the link | +| `trackConversion` | boolean | Whether conversion tracking is enabled | | `clicks` | number | Number of clicks | | `leads` | number | Number of leads | +| `conversions` | number | Number of conversions | | `sales` | number | Number of sales | | `saleAmount` | number | Total sale amount in cents | | `lastClicked` | string | Last clicked timestamp | @@ -203,6 +221,9 @@ Update an existing short link. You can modify the destination URL, slug, metadat | `title` | string | No | Custom OG title | | `description` | string | No | Custom OG description | | `externalId` | string | No | External ID for the link | +| `tenantId` | string | No | Tenant ID for grouping links created on behalf of a customer/tenant | +| `folderId` | string | No | Folder ID to organize the link into | +| `trackConversion` | boolean | No | Whether to track conversions \(leads/sales\) for the short link | | `tagIds` | string | No | Comma-separated tag IDs | | `comments` | string | No | Comments for the short link | | `expiresAt` | string | No | Expiration date in ISO 8601 format | @@ -230,8 +251,12 @@ Update an existing short link. You can modify the destination URL, slug, metadat | `title` | string | OG title | | `description` | string | OG description | | `tags` | json | Tags assigned to the link \(id, name, color\) | +| `folderId` | string | Folder the link is organized into | +| `tenantId` | string | Tenant ID associated with the link | +| `trackConversion` | boolean | Whether conversion tracking is enabled | | `clicks` | number | Number of clicks | | `leads` | number | Number of leads | +| `conversions` | number | Number of conversions | | `sales` | number | Number of sales | | `saleAmount` | number | Total sale amount in cents | | `lastClicked` | string | Last clicked timestamp | @@ -272,9 +297,13 @@ Retrieve a paginated list of short links for the authenticated workspace. Suppor | `domain` | string | No | Filter by domain | | `search` | string | No | Search query matched against the short link slug and destination URL | | `tagIds` | string | No | Comma-separated tag IDs to filter by | +| `tenantId` | string | No | Filter by tenant ID | +| `folderId` | string | No | Filter by folder ID | | `showArchived` | boolean | No | Whether to include archived links \(defaults to false\) | -| `page` | number | No | Page number \(default: 1\) | +| `page` | number | No | Page number \(deprecated by Dub in favor of startingAfter/endingBefore\) | | `pageSize` | number | No | Number of links per page \(default: 100, max: 100\) | +| `startingAfter` | string | No | Cursor: fetch results after this link ID | +| `endingBefore` | string | No | Cursor: fetch results before this link ID | #### Output @@ -432,6 +461,7 @@ Generate a customizable QR code (PNG) for a short link, with control over size, | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | Dub API key | | `url` | string | Yes | The short link URL to encode in the QR code | +| `logo` | string | No | URL of a custom logo to embed in the QR code \(requires a paid Dub plan\) | | `size` | number | No | QR code size in pixels \(default: 600\) | | `level` | string | No | Error correction level: L \(default\), M, Q, or H | | `fgColor` | string | No | Foreground color in hex \(default: #000000\) | @@ -446,4 +476,87 @@ Generate a customizable QR code (PNG) for a short link, with control over size, | `file` | file | Generated QR code image stored in execution files | | `content` | string | Base64-encoded PNG image data | +### `dub_list_domains` + +Retrieve the custom domains registered in the workspace, so links can be created against the right domain. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | Dub API key | +| `archived` | boolean | No | Whether to include archived domains \(defaults to false\) | +| `search` | string | No | Search by domain name | +| `page` | number | No | Page number \(default: 1\) | +| `pageSize` | number | No | Number of domains per page \(default: 50, max: 50\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `domains` | json | Array of domain objects \(slug, verified, primary, archived\) | +| `count` | number | Number of domains returned | + +### `dub_list_tags` + +Retrieve the tags defined in the workspace, so the right tag IDs can be assigned to links. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | Dub API key | +| `search` | string | No | Search by tag name | +| `sortBy` | string | No | Field to sort by: name \(default\) or createdAt | +| `sortOrder` | string | No | Sort order: asc \(default\) or desc | +| `page` | number | No | Page number \(default: 1\) | +| `pageSize` | number | No | Number of tags per page \(default: 100, max: 100\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `tags` | json | Array of tag objects \(id, name, color\) | +| `count` | number | Number of tags returned | + +### `dub_create_tag` + +Create a new tag in the workspace for organizing and filtering short links. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | Dub API key | +| `name` | string | Yes | The name of the tag to create \(1-50 characters\) | +| `color` | string | No | Tag color: red, yellow, green, blue, purple, brown, gray, or pink \(random if omitted\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Unique ID of the created tag | +| `name` | string | Name of the tag | +| `color` | string | Color assigned to the tag | + +### `dub_list_folders` + +Retrieve the folders defined in the workspace, so the right folder ID can be used to organize links. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | Dub API key | +| `search` | string | No | Search by folder name | +| `page` | number | No | Page number \(default: 1\) | +| `pageSize` | number | No | Number of folders per page \(default: 50, max: 50\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `folders` | json | Array of folder objects \(id, name, accessLevel\) | +| `count` | number | Number of folders returned | + diff --git a/apps/docs/content/docs/en/integrations/github.mdx b/apps/docs/content/docs/en/integrations/github.mdx index 9512707428f..d5a8eaf3d87 100644 --- a/apps/docs/content/docs/en/integrations/github.mdx +++ b/apps/docs/content/docs/en/integrations/github.mdx @@ -648,7 +648,7 @@ Request reviewers for a pull request | `owner` | string | Yes | Repository owner | | `repo` | string | Yes | Repository name | | `pullNumber` | number | Yes | Pull request number | -| `reviewers` | string | Yes | Comma-separated list of user logins to request reviews from | +| `reviewers` | string | No | Comma-separated list of user logins to request reviews from \(at least one of reviewers or team_reviewers is required\) | | `team_reviewers` | string | No | Comma-separated list of team slugs to request reviews from | | `apiKey` | string | Yes | GitHub API token | @@ -663,6 +663,40 @@ Request reviewers for a pull request | `requested_reviewers` | array | Array of requested reviewer objects | | `requested_teams` | array | Array of requested team objects | +### `github_create_pr_review` + +Submit a review for a pull request. Use APPROVE, REQUEST_CHANGES, or COMMENT. A body is required for REQUEST_CHANGES and COMMENT reviews. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `owner` | string | Yes | Repository owner | +| `repo` | string | Yes | Repository name | +| `pullNumber` | number | Yes | Pull request number | +| `event` | string | Yes | The review action to perform: APPROVE, REQUEST_CHANGES, or COMMENT | +| `body` | string | No | The body text of the review \(required for REQUEST_CHANGES and COMMENT\) | +| `commit_id` | string | No | The SHA of the commit that needs a review \(defaults to the most recent commit\) | +| `apiKey` | string | Yes | GitHub API token | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | number | Review ID | +| `user` | object | GitHub user object | +| ↳ `login` | string | GitHub username | +| ↳ `id` | number | User ID | +| ↳ `avatar_url` | string | Avatar image URL | +| ↳ `html_url` | string | Profile URL | +| ↳ `type` | string | Account type \(User or Organization\) | +| `body` | string | Review body text | +| `state` | string | Review state \(APPROVED/CHANGES_REQUESTED/COMMENTED\) | +| `html_url` | string | GitHub web URL for the review | +| `pull_request_url` | string | API URL of the reviewed pull request | +| `commit_id` | string | SHA of the reviewed commit | +| `submitted_at` | string | Review submission timestamp | + ### `github_get_file_content` Get the content of a file from a GitHub repository. Supports files up to 1MB. Content is returned decoded and human-readable. @@ -795,6 +829,60 @@ Get the contents of a directory in a GitHub repository. Returns a list of files | ↳ `_links` | json | Related links | | `count` | number | Total number of items | +### `github_get_readme` + +Get the preferred README for a GitHub repository, with its content decoded to plain text. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `owner` | string | Yes | Repository owner \(user or organization\) | +| `repo` | string | Yes | Repository name | +| `ref` | string | No | The name of the commit/branch/tag to read the README from \(defaults to the repository default branch\) | +| `apiKey` | string | Yes | GitHub Personal Access Token | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `name` | string | README file name | +| `path` | string | README file path | +| `sha` | string | Blob SHA of the README | +| `size` | number | File size in bytes | +| `encoding` | string | Original content encoding from the API | +| `html_url` | string | GitHub web URL for the README | +| `download_url` | string | Raw download URL for the README | +| `content` | string | Decoded README text content | + +### `github_list_tags` + +List tags for a GitHub repository. Returns tag names with their commit SHA and download URLs. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `owner` | string | Yes | Repository owner \(user or organization\) | +| `repo` | string | Yes | Repository name | +| `per_page` | number | No | Number of results per page \(max 100\) | +| `page` | number | No | Page number of the results to fetch | +| `apiKey` | string | Yes | GitHub Personal Access Token | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `items` | array | Array of tag objects | +| ↳ `name` | string | Tag name | +| ↳ `zipball_url` | string | Zipball download URL | +| ↳ `tarball_url` | string | Tarball download URL | +| ↳ `node_id` | string | Node ID | +| ↳ `commit` | object | Commit the tag points to | +| ↳ `sha` | string | Commit SHA | +| ↳ `url` | string | Commit API URL | +| `count` | number | Number of tags returned | + ### `github_list_branches` List all branches in a GitHub repository. Optionally filter by protected status and control pagination. @@ -1556,6 +1644,60 @@ Get detailed information about a specific GitHub release by ID. Returns release | ↳ `created_at` | string | Upload timestamp | | ↳ `updated_at` | string | Last update timestamp | +### `github_get_latest_release` + +Get the latest published, non-draft, non-prerelease release for a GitHub repository. Returns release metadata including assets and download URLs. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `owner` | string | Yes | Repository owner \(user or organization\) | +| `repo` | string | Yes | Repository name | +| `apiKey` | string | Yes | GitHub Personal Access Token | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `author` | object | GitHub user object | +| ↳ `login` | string | GitHub username | +| ↳ `id` | number | User ID | +| ↳ `avatar_url` | string | Avatar image URL | +| ↳ `html_url` | string | Profile URL | +| ↳ `type` | string | Account type \(User or Organization\) | +| `id` | number | Release ID | +| `node_id` | string | GraphQL node ID | +| `tag_name` | string | Git tag name | +| `name` | string | Release name | +| `body` | string | Release notes \(markdown\) | +| `html_url` | string | GitHub web URL | +| `tarball_url` | string | Source tarball URL | +| `zipball_url` | string | Source zipball URL | +| `draft` | boolean | Whether this is a draft release | +| `prerelease` | boolean | Whether this is a prerelease | +| `target_commitish` | string | Target branch or commit SHA | +| `created_at` | string | Creation timestamp | +| `published_at` | string | Publication timestamp | +| `assets` | array | Release assets | +| ↳ `uploader` | object | GitHub user object | +| ↳ `login` | string | GitHub username | +| ↳ `id` | number | User ID | +| ↳ `avatar_url` | string | Avatar image URL | +| ↳ `html_url` | string | Profile URL | +| ↳ `type` | string | Account type \(User or Organization\) | +| ↳ `id` | number | Asset ID | +| ↳ `node_id` | string | GraphQL node ID | +| ↳ `name` | string | Asset filename | +| ↳ `label` | string | Asset label | +| ↳ `state` | string | Asset state \(uploaded/open\) | +| ↳ `content_type` | string | MIME type | +| ↳ `size` | number | File size in bytes | +| ↳ `download_count` | number | Number of downloads | +| ↳ `browser_download_url` | string | Direct download URL | +| ↳ `created_at` | string | Upload timestamp | +| ↳ `updated_at` | string | Last update timestamp | + ### `github_delete_release` Delete a GitHub release by ID. This permanently removes the release but does not delete the associated Git tag. diff --git a/apps/docs/content/docs/en/integrations/gitlab.mdx b/apps/docs/content/docs/en/integrations/gitlab.mdx index eb37db7210b..adb905bdbee 100644 --- a/apps/docs/content/docs/en/integrations/gitlab.mdx +++ b/apps/docs/content/docs/en/integrations/gitlab.mdx @@ -90,7 +90,7 @@ List issues in a GitLab project | `assigneeId` | number | No | Filter by assignee user ID | | `milestoneTitle` | string | No | Filter by milestone title | | `search` | string | No | Search issues by title and description | -| `orderBy` | string | No | Order by field \(created_at, updated_at\) | +| `orderBy` | string | No | Order by field \(created_at, updated_at, priority, due_date, relative_position, label_priority, milestone_due, popularity, title, weight\) | | `sort` | string | No | Sort direction \(asc, desc\) | | `perPage` | number | No | Number of results per page \(default 20, max 100\) | | `page` | number | No | Page number for pagination | @@ -217,11 +217,11 @@ List merge requests in a GitLab project | --------- | ---- | -------- | ----------- | | `host` | string | No | Self-managed GitLab host \(e.g. gitlab.example.com\). Defaults to gitlab.com. | | `projectId` | string | Yes | Project ID or URL-encoded path | -| `state` | string | No | Filter by state \(opened, closed, merged, all\) | +| `state` | string | No | Filter by state \(opened, closed, locked, merged, all\) | | `labels` | string | No | Comma-separated list of label names | | `sourceBranch` | string | No | Filter by source branch | | `targetBranch` | string | No | Filter by target branch | -| `orderBy` | string | No | Order by field \(created_at, updated_at\) | +| `orderBy` | string | No | Order by field \(created_at, updated_at, merged_at, priority, label_priority, milestone_due, popularity, title\) | | `sort` | string | No | Sort direction \(asc, desc\) | | `perPage` | number | No | Number of results per page \(default 20, max 100\) | | `page` | number | No | Page number for pagination | @@ -560,6 +560,49 @@ Create a new branch in a GitLab project repository | `protected` | boolean | Whether the branch is protected | | `commit` | object | The commit the branch points to | +### `gitlab_delete_branch` + +Delete a branch from a GitLab project repository + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `host` | string | No | Self-managed GitLab host \(e.g. gitlab.example.com\). Defaults to gitlab.com. | +| `projectId` | string | Yes | Project ID or URL-encoded path | +| `branch` | string | Yes | Name of the branch to delete | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the branch was deleted successfully | + +### `gitlab_compare_branches` + +Compare two branches, tags, or commits in a GitLab project repository + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `host` | string | No | Self-managed GitLab host \(e.g. gitlab.example.com\). Defaults to gitlab.com. | +| `projectId` | string | Yes | Project ID or URL-encoded path | +| `from` | string | Yes | Commit SHA or branch/tag name to compare from | +| `to` | string | Yes | Commit SHA or branch/tag name to compare to | +| `straight` | boolean | No | Compare directly from..to instead of using the merge base \(defaults to false\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `commit` | object | The latest commit in the comparison | +| `commits` | array | Commits between the two references | +| `diffs` | array | File diffs between the two references | +| `compareTimeout` | boolean | Whether the comparison exceeded size limits or timed out | +| `compareSameRef` | boolean | Whether both references point to the same commit | +| `webUrl` | string | The web URL for viewing the comparison | + ### `gitlab_list_branches` List branches in a GitLab project repository @@ -709,6 +752,51 @@ Trigger (play) a manual GitLab job | `status` | string | The job status | | `webUrl` | string | The web URL of the job | +### `gitlab_list_releases` + +List releases in a GitLab project + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `host` | string | No | Self-managed GitLab host \(e.g. gitlab.example.com\). Defaults to gitlab.com. | +| `projectId` | string | Yes | Project ID or URL-encoded path | +| `orderBy` | string | No | Order by field \(released_at, created_at\) | +| `sort` | string | No | Sort direction \(asc, desc\) | +| `perPage` | number | No | Number of results per page \(default 20, max 100\) | +| `page` | number | No | Page number for pagination | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `releases` | array | List of GitLab releases | +| `total` | number | Total number of releases | + +### `gitlab_create_release` + +Create a new release in a GitLab project + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `host` | string | No | Self-managed GitLab host \(e.g. gitlab.example.com\). Defaults to gitlab.com. | +| `projectId` | string | Yes | Project ID or URL-encoded path | +| `tagName` | string | Yes | The Git tag for the release | +| `name` | string | No | The release name | +| `description` | string | No | Release description/notes \(Markdown supported\) | +| `ref` | string | No | Commit SHA, branch, or tag to create the tag from if it does not already exist | +| `releasedAt` | string | No | ISO 8601 date for an upcoming or historical release | +| `milestones` | array | No | Array of milestone titles to associate with the release | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `release` | object | The created GitLab release | + ## Triggers diff --git a/apps/docs/content/docs/en/integrations/google_bigquery.mdx b/apps/docs/content/docs/en/integrations/google_bigquery.mdx index f14008b9ba3..9e5aa17c862 100644 --- a/apps/docs/content/docs/en/integrations/google_bigquery.mdx +++ b/apps/docs/content/docs/en/integrations/google_bigquery.mdx @@ -63,6 +63,38 @@ Run a SQL query against Google BigQuery and return the results | ↳ `location` | string | Geographic location of the job | | `pageToken` | string | Token for fetching additional result pages | +### `google_bigquery_get_query_results` + +Fetch results for a previously submitted BigQuery job, or the next page of a Run Query result + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | Google Cloud project ID | +| `jobId` | string | Yes | ID of the BigQuery job to fetch results for | +| `pageToken` | string | No | Token for pagination | +| `maxResults` | number | No | Maximum number of rows to return | +| `timeoutMs` | number | No | How long to wait for the job to complete, in milliseconds | +| `location` | string | No | Processing location of the job \(e.g., "US", "EU"\) | +| `startIndex` | string | No | Zero-based index of the starting row | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `columns` | array | Array of column names from the query result | +| `rows` | array | Array of row objects keyed by column name | +| `totalRows` | string | Total number of rows in the complete result set | +| `jobComplete` | boolean | Whether the job has completed | +| `totalBytesProcessed` | string | Total bytes processed by the query | +| `cacheHit` | boolean | Whether the query result was served from cache | +| `jobReference` | object | Job reference \(useful when jobComplete is false\) | +| ↳ `projectId` | string | Project ID containing the job | +| ↳ `jobId` | string | Unique job identifier | +| ↳ `location` | string | Geographic location of the job | +| `pageToken` | string | Token for fetching additional result pages | + ### `google_bigquery_list_datasets` List all datasets in a Google BigQuery project @@ -86,6 +118,49 @@ List all datasets in a Google BigQuery project | ↳ `location` | string | Geographic location where the data resides | | `nextPageToken` | string | Token for fetching next page of results | +### `google_bigquery_create_dataset` + +Create a new dataset in a Google BigQuery project + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | Google Cloud project ID | +| `datasetId` | string | Yes | ID for the new BigQuery dataset | +| `location` | string | No | Geographic location for the dataset \(e.g., "US", "EU"\) | +| `friendlyName` | string | No | Human-readable name for the dataset | +| `description` | string | No | Description of the dataset | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `datasetId` | string | Unique dataset identifier | +| `projectId` | string | Project ID containing this dataset | +| `friendlyName` | string | Descriptive name for the dataset | +| `description` | string | Dataset description | +| `location` | string | Geographic location where the data resides | +| `creationTime` | string | Dataset creation time \(milliseconds since epoch\) | + +### `google_bigquery_delete_dataset` + +Delete a dataset from a Google BigQuery project + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | Google Cloud project ID | +| `datasetId` | string | Yes | BigQuery dataset ID to delete | +| `deleteContents` | boolean | No | Whether to delete tables inside the dataset \(default: false\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `deleted` | boolean | Whether the dataset was deleted | + ### `google_bigquery_list_tables` List all tables in a Google BigQuery dataset @@ -145,6 +220,80 @@ Get metadata and schema for a Google BigQuery table | `lastModifiedTime` | string | Last modification time \(milliseconds since epoch\) | | `location` | string | Geographic location where the table resides | +### `google_bigquery_create_table` + +Create a new table in a Google BigQuery dataset + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | Google Cloud project ID | +| `datasetId` | string | Yes | BigQuery dataset ID | +| `tableId` | string | Yes | ID for the new BigQuery table | +| `schema` | string | Yes | JSON array of column field definitions, e.g. \[\{"name":"id","type":"STRING","mode":"REQUIRED"\}\] | +| `description` | string | No | Description of the table | +| `friendlyName` | string | No | Human-readable name for the table | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `tableId` | string | Table ID | +| `datasetId` | string | Dataset ID | +| `projectId` | string | Project ID | +| `type` | string | Table type \(usually TABLE\) | +| `description` | string | Table description | +| `schema` | array | Array of column definitions | +| ↳ `name` | string | Column name | +| ↳ `type` | string | Data type | +| ↳ `mode` | string | Column mode \(NULLABLE, REQUIRED, or REPEATED\) | +| ↳ `description` | string | Column description | +| `creationTime` | string | Table creation time \(milliseconds since epoch\) | +| `location` | string | Geographic location where the table resides | + +### `google_bigquery_delete_table` + +Delete a table from a Google BigQuery dataset + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | Google Cloud project ID | +| `datasetId` | string | Yes | BigQuery dataset ID | +| `tableId` | string | Yes | BigQuery table ID to delete | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `deleted` | boolean | Whether the table was deleted | + +### `google_bigquery_list_table_data` + +Preview rows from a Google BigQuery table without running a query. Pair with Get Table to know the column order. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | Google Cloud project ID | +| `datasetId` | string | Yes | BigQuery dataset ID | +| `tableId` | string | Yes | BigQuery table ID | +| `maxResults` | number | No | Maximum number of rows to return | +| `pageToken` | string | No | Token for pagination | +| `startIndex` | string | No | Zero-based index of the starting row | +| `selectedFields` | string | No | Comma-separated list of column names to return | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `rows` | array | Array of rows, each a raw array of column values in schema order | +| `totalRows` | string | Total number of rows in the table | +| `pageToken` | string | Token for fetching the next page of results | + ### `google_bigquery_insert_rows` Insert rows into a Google BigQuery table using streaming insert diff --git a/apps/docs/content/docs/en/integrations/google_calendar.mdx b/apps/docs/content/docs/en/integrations/google_calendar.mdx index 2bedcf12eb5..d494e28c386 100644 --- a/apps/docs/content/docs/en/integrations/google_calendar.mdx +++ b/apps/docs/content/docs/en/integrations/google_calendar.mdx @@ -372,6 +372,47 @@ Create a new secondary calendar. Returns API-aligned fields only. | `location` | string | Calendar location | | `timeZone` | string | Calendar time zone | +### `google_calendar_update_calendar` + +Update a secondary calendar's metadata. Returns API-aligned fields only. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `calendarId` | string | No | Calendar ID to update \(e.g., primary or calendar@group.calendar.google.com\) | +| `summary` | string | No | New title for the calendar | +| `description` | string | No | New description for the calendar | +| `location` | string | No | New geographic location of the calendar as free-form text | +| `timeZone` | string | No | New time zone of the calendar as an IANA name \(e.g., America/Los_Angeles\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Calendar ID | +| `summary` | string | Calendar title | +| `description` | string | Calendar description | +| `location` | string | Calendar location | +| `timeZone` | string | Calendar time zone | + +### `google_calendar_delete_calendar` + +Permanently delete a secondary calendar. Returns API-aligned fields only. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `calendarId` | string | Yes | Secondary calendar ID to delete \(e.g., calendar@group.calendar.google.com\). The primary calendar cannot be deleted. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `calendarId` | string | Deleted calendar ID | +| `deleted` | boolean | Whether deletion was successful | + ### `google_calendar_share_calendar` Grant a user, group, or domain access to a calendar. Returns API-aligned fields only. @@ -394,6 +435,27 @@ Grant a user, group, or domain access to a calendar. Returns API-aligned fields | `role` | string | Granted access role | | `scope` | json | Grantee scope \(type and value\) | +### `google_calendar_update_acl` + +Change the access role granted by an existing calendar sharing (ACL) rule. Returns API-aligned fields only. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `calendarId` | string | No | Calendar ID to modify \(e.g., primary or calendar@group.calendar.google.com\) | +| `ruleId` | string | Yes | ACL rule ID to update \(e.g., user:person@example.com\) | +| `role` | string | Yes | New access role to grant: freeBusyReader, reader, writer, or owner | +| `sendNotifications` | boolean | No | Whether to send a notification email about the change. Defaults to true. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | ACL rule ID | +| `role` | string | Granted access role | +| `scope` | json | Grantee scope \(type and value\) | + ### `google_calendar_list_acl` List the access control rules (sharing) for a calendar. Returns API-aligned fields only. diff --git a/apps/docs/content/docs/en/integrations/google_maps.mdx b/apps/docs/content/docs/en/integrations/google_maps.mdx index 0531162db91..0977dd8c435 100644 --- a/apps/docs/content/docs/en/integrations/google_maps.mdx +++ b/apps/docs/content/docs/en/integrations/google_maps.mdx @@ -289,6 +289,43 @@ Get detailed information about a specific place | `vicinity` | string | Simplified address \(neighborhood/street\) | | `businessStatus` | string | Business status \(OPERATIONAL, CLOSED_TEMPORARILY, CLOSED_PERMANENTLY\) | +### `google_maps_places_nearby` + +Search for places of a given type within a radius of a location + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | Google Maps API key | +| `lat` | number | Yes | Latitude of the center point to search around | +| `lng` | number | Yes | Longitude of the center point to search around | +| `radius` | number | Yes | Search radius in meters \(up to 50000\) | +| `includedTypes` | array | No | Place types to include in the results \(e.g., restaurant, cafe\) | +| `maxResultCount` | number | No | Maximum number of results to return \(1-20, defaults to 20\) | +| `rankPreference` | string | No | How to rank results: POPULARITY \(default\) or DISTANCE | +| `languageCode` | string | No | Language code for the response \(e.g., en, es\) | +| `regionCode` | string | No | Region bias as a ccTLD code \(e.g., us, uk\) | +| `pricing` | per_request | No | No description | +| `rateLimit` | string | No | No description | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `places` | array | List of places found near the given location | +| ↳ `placeId` | string | Google Place resource ID | +| ↳ `name` | string | Place name | +| ↳ `formattedAddress` | string | Formatted address | +| ↳ `lat` | number | Latitude | +| ↳ `lng` | number | Longitude | +| ↳ `types` | array | Place types | +| ↳ `rating` | number | Average rating \(1-5\) | +| ↳ `userRatingsTotal` | number | Number of ratings | +| ↳ `priceLevel` | string | Price level \(e.g., PRICE_LEVEL_MODERATE\) | +| ↳ `openNow` | boolean | Whether currently open | +| ↳ `businessStatus` | string | Business status | + ### `google_maps_places_search` Search for places using a text query @@ -304,6 +341,7 @@ Search for places using a text query | `type` | string | No | Place type filter \(e.g., restaurant, cafe, hotel\) | | `language` | string | No | Language code for results \(e.g., en, es, fr\) | | `region` | string | No | Region bias as a ccTLD code \(e.g., us, uk\) | +| `pageToken` | string | No | Token from a previous search response to fetch the next page of results. Wait a couple seconds after receiving the token before using it, or the API returns INVALID_REQUEST | | `pricing` | per_request | No | No description | | `rateLimit` | string | No | No description | @@ -457,6 +495,7 @@ Get speed limits for road segments. Requires either path coordinates or placeIds | `apiKey` | string | Yes | Google Maps API key with Roads API enabled | | `path` | string | No | Pipe-separated list of lat,lng coordinates \(required if placeIds not provided\) | | `placeIds` | array | No | Array of Place IDs for road segments \(required if path not provided\) | +| `units` | string | No | Units for the returned speed limits: KPH \(default\) or MPH | #### Output diff --git a/apps/docs/content/docs/en/integrations/google_vault.mdx b/apps/docs/content/docs/en/integrations/google_vault.mdx index c83ee44eefd..b30f5e7d11b 100644 --- a/apps/docs/content/docs/en/integrations/google_vault.mdx +++ b/apps/docs/content/docs/en/integrations/google_vault.mdx @@ -1,6 +1,6 @@ --- title: Google Vault -description: Search, export, and manage holds/exports for Vault matters +description: Search, export, and manage matters, holds, exports, and saved queries in Vault --- import { BlockInfoCard } from "@/components/ui/block-info-card" @@ -28,7 +28,7 @@ In Sim, the Google Vault integration lets your AI agents programmatically manage ## Usage Instructions -Connect Google Vault to create exports, list exports, and manage holds within matters. +Connect Google Vault to manage the full matter lifecycle, create and manage holds and exports, and save reusable search queries for eDiscovery and compliance. @@ -78,6 +78,23 @@ List exports for a matter | `export` | json | Single export object \(when exportId is provided\) | | `nextPageToken` | string | Token for fetching next page of results | +### `google_vault_delete_matters_export` + +Delete an export from a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `exportId` | string | Yes | The export ID to delete \(e.g., "exportId123456"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the export was deleted | + ### `google_vault_download_export_file` Download a single file from a Google Vault export (GCS object) @@ -142,6 +159,86 @@ List holds for a matter | `hold` | json | Single hold object \(when holdId is provided\) | | `nextPageToken` | string | Token for fetching next page of results | +### `google_vault_update_matters_holds` + +Replace the name, query, and scope of an existing hold. This is a full-resource update: fetch the current hold first (Vault List Holds) and resupply every field you want to keep — any field left blank is cleared, not left unchanged. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `holdId` | string | Yes | The hold ID to update \(e.g., "holdId123456"\) | +| `holdName` | string | Yes | Name for the hold | +| `corpus` | string | Yes | Data corpus of the hold \(MAIL, DRIVE, GROUPS, HANGOUTS_CHAT, VOICE\) | +| `accountEmails` | string | No | Comma-separated list of user emails covered by the hold \(e.g., "user1@example.com, user2@example.com"\) | +| `orgUnitId` | string | No | Organization unit ID covered by the hold \(e.g., "id:03ph8a2z1enx5q0", alternative to accounts\) | +| `terms` | string | No | Search terms to filter held content \(e.g., "from:sender@example.com subject:invoice", for MAIL and GROUPS corpus\). Resupply the hold\'s current terms to keep them — this replaces the hold, so leaving it blank clears any existing filter. | +| `startTime` | string | No | Start time for date filtering \(ISO 8601 format, e.g., "2024-01-01T00:00:00Z", for MAIL and GROUPS corpus\). Resupply the hold\'s current value to keep it — leaving it blank clears any existing date filter. | +| `endTime` | string | No | End time for date filtering \(ISO 8601 format, e.g., "2024-12-31T23:59:59Z", for MAIL and GROUPS corpus\). Resupply the hold\'s current value to keep it — leaving it blank clears any existing date filter. | +| `includeSharedDrives` | boolean | No | Include files in shared drives \(for DRIVE corpus\). Resupply true if the hold currently includes shared drives — leaving it false/blank clears that setting. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `hold` | json | Updated hold object | + +### `google_vault_delete_matters_holds` + +Delete a hold and release its covered accounts + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `holdId` | string | Yes | The hold ID to delete \(e.g., "holdId123456"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the hold was deleted | + +### `google_vault_add_held_accounts` + +Add accounts to an existing hold + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `holdId` | string | Yes | The hold ID to add accounts to \(e.g., "holdId123456"\) | +| `accountEmails` | string | Yes | Comma-separated list of user emails to add to the hold \(e.g., "user1@example.com, user2@example.com"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `responses` | array | Per-account results of the add operation | +| ↳ `account` | json | Held account \(accountId, email\) | +| ↳ `status` | json | Status \(code, message\) if the add failed | + +### `google_vault_remove_held_accounts` + +Remove accounts from an existing hold + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `holdId` | string | Yes | The hold ID to remove accounts from \(e.g., "holdId123456"\) | +| `accountIds` | string | Yes | Comma-separated list of Admin SDK account IDs to remove from the hold \(e.g., "accountId1, accountId2"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `statuses` | array | Per-account removal status, in request order | + ### `google_vault_create_matters` Create a new matter in Google Vault @@ -179,4 +276,184 @@ List matters, or get a specific matter if matterId is provided | `matter` | json | Single matter object \(when matterId is provided\) | | `nextPageToken` | string | Token for fetching next page of results | +### `google_vault_update_matters` + +Update the name and/or description of a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID to update \(e.g., "12345678901234567890"\) | +| `name` | string | Yes | New name for the matter | +| `description` | string | No | New description for the matter | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `matter` | json | Updated matter object | + +### `google_vault_close_matters` + +Close a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID to close \(e.g., "12345678901234567890"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `matter` | json | Closed matter object | + +### `google_vault_reopen_matters` + +Reopen a closed matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID to reopen \(e.g., "12345678901234567890"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `matter` | json | Reopened matter object | + +### `google_vault_delete_matters` + +Permanently delete a matter (must be closed first) + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID to delete \(e.g., "12345678901234567890"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `matter` | json | Deleted matter object | + +### `google_vault_undelete_matters` + +Restore a deleted matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID to restore \(e.g., "12345678901234567890"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `matter` | json | Restored matter object | + +### `google_vault_add_matters_permissions` + +Add a collaborator (or transfer ownership) to a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `accountId` | string | Yes | Admin SDK account ID of the user to add as a collaborator/owner | +| `role` | string | Yes | Permission level to grant: COLLABORATOR or OWNER | +| `sendEmails` | boolean | No | Send a notification email to the added account | +| `ccMe` | boolean | No | CC the requestor on the notification email \(only relevant if sendEmails is true\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `permission` | json | Created matter permission \(accountId, role\) | + +### `google_vault_remove_matters_permissions` + +Remove a collaborator from a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `accountId` | string | Yes | Admin SDK account ID of the collaborator to remove | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the collaborator was removed | + +### `google_vault_create_saved_query` + +Save a reusable search query in a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `displayName` | string | Yes | Name for the saved query | +| `corpus` | string | Yes | Data corpus to search \(MAIL, DRIVE, GROUPS, HANGOUTS_CHAT, VOICE\) | +| `accountEmails` | string | No | Comma-separated list of user emails to scope the query \(e.g., "user1@example.com, user2@example.com"\) | +| `orgUnitId` | string | No | Organization unit ID to scope the query \(e.g., "id:03ph8a2z1enx5q0", alternative to emails\) | +| `startTime` | string | No | Start time for date filtering \(ISO 8601 format, e.g., "2024-01-01T00:00:00Z"\) | +| `endTime` | string | No | End time for date filtering \(ISO 8601 format, e.g., "2024-12-31T23:59:59Z"\) | +| `terms` | string | No | Search query terms \(e.g., "from:sender@example.com subject:invoice"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `savedQuery` | json | Created saved query object | + +### `google_vault_list_saved_queries` + +List saved queries in a matter, or get a specific one if savedQueryId is provided + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `pageSize` | number | No | Number of saved queries to return per page | +| `pageToken` | string | No | Token for pagination | +| `savedQueryId` | string | No | Optional saved query ID to fetch a specific saved query | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `savedQueries` | json | Array of saved query objects | +| `savedQuery` | json | Single saved query object \(when savedQueryId is provided\) | +| `nextPageToken` | string | Token for fetching next page of results | + +### `google_vault_delete_saved_query` + +Delete a saved query from a matter + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `matterId` | string | Yes | The matter ID \(e.g., "12345678901234567890"\) | +| `savedQueryId` | string | Yes | The saved query ID to delete | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the saved query was deleted | + diff --git a/apps/docs/content/docs/en/integrations/granola.mdx b/apps/docs/content/docs/en/integrations/granola.mdx index d4e35e368ff..e1d96ad531d 100644 --- a/apps/docs/content/docs/en/integrations/granola.mdx +++ b/apps/docs/content/docs/en/integrations/granola.mdx @@ -88,6 +88,7 @@ Retrieves a specific meeting note from Granola by ID, including summary, attende | `transcript` | json | Meeting transcript entries \(only if requested\) | | ↳ `speaker` | string | Speaker source \(microphone or speaker\) | | ↳ `speakerLabel` | string | Diarization label for the speaker \(e.g., Speaker A\) | +| ↳ `speakerName` | string | Resolved name of the identified speaker, when available | | ↳ `text` | string | Transcript text | | ↳ `startTime` | string | Segment start time | | ↳ `endTime` | string | Segment end time | diff --git a/apps/docs/content/docs/en/integrations/instantly.mdx b/apps/docs/content/docs/en/integrations/instantly.mdx index 7ed15ea7aef..2dd0ae4923f 100644 --- a/apps/docs/content/docs/en/integrations/instantly.mdx +++ b/apps/docs/content/docs/en/integrations/instantly.mdx @@ -12,7 +12,7 @@ import { BlockInfoCard } from "@/components/ui/block-info-card" ## Usage Instructions -Integrate Instantly API V2 into workflows. Create and list leads, manage lead interest status, delete leads in bulk, list and create campaigns, reply to emails, and manage lead lists. +Integrate Instantly API V2 into workflows. Create, update, and list leads, manage lead interest status, delete leads in bulk, list, create, patch, activate, pause, and delete campaigns, reply to emails, and manage lead lists. @@ -155,6 +155,51 @@ Creates an Instantly V2 lead in a campaign or lead list. | `thread_id` | string | Email thread ID | | `message` | string | Operation message | +### `instantly_patch_lead` + +Updates fields on an existing Instantly V2 lead. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `leadId` | string | Yes | Lead ID | +| `first_name` | string | No | Lead first name | +| `last_name` | string | No | Lead last name | +| `company_name` | string | No | Lead company name | +| `job_title` | string | No | Lead job title | +| `phone` | string | No | Lead phone number | +| `website` | string | No | Lead website | +| `personalization` | string | No | Lead personalization text | +| `lt_interest_status` | number | No | Lead interest status value | +| `pl_value_lead` | string | No | Potential value of the lead | +| `assigned_to` | string | No | ID of the user assigned to the lead | +| `custom_variables` | json | No | Custom variable object with string, number, boolean, or null values | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `leads` | array | List of leads \(id, email, first_name, last_name, campaign, status\) | +| `lead` | json | Lead details \(id, email, first_name, last_name, company_name, job_title, campaign, status, payload\) | +| `campaigns` | array | List of campaigns \(id, name, status, daily_limit\) | +| `campaign` | json | Campaign details \(id, name, status, daily_limit, daily_max_leads, open_tracking\) | +| `emails` | array | List of emails \(id, subject, from_address_email, lead, thread_id\) | +| `email` | json | Email details \(id, subject, from_address_email, to_address_email_list, thread_id, content_preview\) | +| `lead_lists` | array | List of lead lists \(id, name, has_enrichment_task, timestamp_created\) | +| `lead_list` | json | Lead list details \(id, organization_id, has_enrichment_task, owned_by, name, timestamp_created\) | +| `count` | number | Returned or affected record count | +| `next_starting_after` | string | Cursor for the next page | +| `id` | string | Record ID | +| `name` | string | Record name | +| `email_address` | string | Lead email address | +| `first_name` | string | Lead first name | +| `last_name` | string | Lead last name | +| `status` | number | Lead or campaign status | +| `subject` | string | Email subject | +| `thread_id` | string | Email thread ID | +| `message` | string | Operation message | + ### `instantly_delete_leads` Deletes Instantly V2 leads in bulk from a campaign or lead list. @@ -208,7 +253,7 @@ Retrieves Instantly V2 campaigns with search, status, tag, and pagination filter | `starting_after` | string | No | Pagination cursor from next_starting_after | | `search` | string | No | Search by campaign name | | `tag_ids` | string | No | Comma-separated campaign tag IDs | -| `ai_sales_agent_id` | string | No | AI Sales Agent ID filter | +| `ai_sales_agent_id` | string | No | Filter campaigns by AI Sales Agent ID | | `status` | number | No | Campaign status enum value | #### Output @@ -360,6 +405,74 @@ Activates, starts, or resumes an Instantly V2 campaign. | `thread_id` | string | Email thread ID | | `message` | string | Operation message | +### `instantly_pause_campaign` + +Pauses a running Instantly V2 campaign, stopping further email sends. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `campaignId` | string | Yes | Campaign ID | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `leads` | array | List of leads \(id, email, first_name, last_name, campaign, status\) | +| `lead` | json | Lead details \(id, email, first_name, last_name, company_name, job_title, campaign, status, payload\) | +| `campaigns` | array | List of campaigns \(id, name, status, daily_limit\) | +| `campaign` | json | Campaign details \(id, name, status, daily_limit, daily_max_leads, open_tracking\) | +| `emails` | array | List of emails \(id, subject, from_address_email, lead, thread_id\) | +| `email` | json | Email details \(id, subject, from_address_email, to_address_email_list, thread_id, content_preview\) | +| `lead_lists` | array | List of lead lists \(id, name, has_enrichment_task, timestamp_created\) | +| `lead_list` | json | Lead list details \(id, organization_id, has_enrichment_task, owned_by, name, timestamp_created\) | +| `count` | number | Returned or affected record count | +| `next_starting_after` | string | Cursor for the next page | +| `id` | string | Record ID | +| `name` | string | Record name | +| `email_address` | string | Lead email address | +| `first_name` | string | Lead first name | +| `last_name` | string | Lead last name | +| `status` | number | Lead or campaign status | +| `subject` | string | Email subject | +| `thread_id` | string | Email thread ID | +| `message` | string | Operation message | + +### `instantly_delete_campaign` + +Permanently deletes an Instantly V2 campaign. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `campaignId` | string | Yes | Campaign ID | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `leads` | array | List of leads \(id, email, first_name, last_name, campaign, status\) | +| `lead` | json | Lead details \(id, email, first_name, last_name, company_name, job_title, campaign, status, payload\) | +| `campaigns` | array | List of campaigns \(id, name, status, daily_limit\) | +| `campaign` | json | Campaign details \(id, name, status, daily_limit, daily_max_leads, open_tracking\) | +| `emails` | array | List of emails \(id, subject, from_address_email, lead, thread_id\) | +| `email` | json | Email details \(id, subject, from_address_email, to_address_email_list, thread_id, content_preview\) | +| `lead_lists` | array | List of lead lists \(id, name, has_enrichment_task, timestamp_created\) | +| `lead_list` | json | Lead list details \(id, organization_id, has_enrichment_task, owned_by, name, timestamp_created\) | +| `count` | number | Returned or affected record count | +| `next_starting_after` | string | Cursor for the next page | +| `id` | string | Record ID | +| `name` | string | Record name | +| `email_address` | string | Lead email address | +| `first_name` | string | Lead first name | +| `last_name` | string | Lead last name | +| `status` | number | Lead or campaign status | +| `subject` | string | Email subject | +| `thread_id` | string | Email thread ID | +| `message` | string | Operation message | + ### `instantly_list_emails` Retrieves Instantly V2 Unibox emails with search and pagination filters. diff --git a/apps/docs/content/docs/en/integrations/microsoft_ad.mdx b/apps/docs/content/docs/en/integrations/microsoft_ad.mdx index 2d752e06c4d..cf35a8dbbbd 100644 --- a/apps/docs/content/docs/en/integrations/microsoft_ad.mdx +++ b/apps/docs/content/docs/en/integrations/microsoft_ad.mdx @@ -48,6 +48,7 @@ List users in Azure AD (Microsoft Entra ID) | `top` | number | No | Maximum number of users to return \(default 100, max 999\) | | `filter` | string | No | OData filter expression \(e.g., "department eq \'Sales\'"\) | | `search` | string | No | Search string to filter users by displayName or mail | +| `nextLink` | string | No | Continuation URL from a previous response\'s "nextLink" output, used to fetch the next page of results | #### Output @@ -55,6 +56,7 @@ List users in Azure AD (Microsoft Entra ID) | --------- | ---- | ----------- | | `users` | array | List of users | | `userCount` | number | Number of users returned | +| `nextLink` | string | Continuation URL for the next page of results, or null if there are no more | ### `microsoft_ad_get_user` @@ -173,6 +175,7 @@ List groups in Azure AD (Microsoft Entra ID) | `top` | number | No | Maximum number of groups to return \(default 100, max 999\) | | `filter` | string | No | OData filter expression \(e.g., "securityEnabled eq true"\) | | `search` | string | No | Search string to filter groups by displayName or description | +| `nextLink` | string | No | Continuation URL from a previous response\'s "nextLink" output, used to fetch the next page of results | #### Output @@ -180,6 +183,7 @@ List groups in Azure AD (Microsoft Entra ID) | --------- | ---- | ----------- | | `groups` | array | List of groups | | `groupCount` | number | Number of groups returned | +| `nextLink` | string | Continuation URL for the next page of results, or null if there are no more | ### `microsoft_ad_get_group` @@ -221,7 +225,7 @@ Create a new group in Azure AD (Microsoft Entra ID) | `mailEnabled` | boolean | Yes | Whether mail is enabled \(true for Microsoft 365 groups\) | | `securityEnabled` | boolean | Yes | Whether security is enabled \(true for security groups\) | | `groupTypes` | string | No | Group type: "Unified" for Microsoft 365 group, leave empty for security group | -| `visibility` | string | No | Group visibility: "Private" or "Public" | +| `visibility` | string | No | Group visibility: "Private" or "Public" \(can be changed later\), or "HiddenMembership" \(Microsoft 365 groups only; can only be set at creation and never changed afterward\) | #### Output @@ -285,8 +289,9 @@ List members of a group in Azure AD (Microsoft Entra ID) | Parameter | Type | Required | Description | | --------- | ---- | -------- | ----------- | -| `groupId` | string | Yes | Group ID | +| `groupId` | string | No | Group ID. Not needed when Next Page is provided to fetch a later page. | | `top` | number | No | Maximum number of members to return \(default 100, max 999\) | +| `nextLink` | string | No | Continuation URL from a previous response\'s "nextLink" output, used to fetch the next page of results | #### Output @@ -294,6 +299,7 @@ List members of a group in Azure AD (Microsoft Entra ID) | --------- | ---- | ----------- | | `members` | array | List of group members | | `memberCount` | number | Number of members returned | +| `nextLink` | string | Continuation URL for the next page of results, or null if there are no more | ### `microsoft_ad_add_group_member` diff --git a/apps/docs/content/docs/en/integrations/microsoft_dataverse.mdx b/apps/docs/content/docs/en/integrations/microsoft_dataverse.mdx index fbfc837fa9f..225cca52da6 100644 --- a/apps/docs/content/docs/en/integrations/microsoft_dataverse.mdx +++ b/apps/docs/content/docs/en/integrations/microsoft_dataverse.mdx @@ -30,7 +30,7 @@ Connect Microsoft Dataverse to your automations to unlock sophisticated data man ## Usage Instructions -Integrate Microsoft Dataverse into your workflow. Create, read, update, delete, upsert, associate, query, search, and execute actions and functions against Dataverse tables using the Web API. Supports bulk operations, FetchXML, file uploads, and relevance search. Works with Dynamics 365, Power Platform, and custom Dataverse environments. +Integrate Microsoft Dataverse into your workflow. Create, read, update, delete, upsert, associate, query, search, and execute actions and functions against Dataverse tables using the Web API. Supports bulk operations, FetchXML, file uploads, relevance search, and table metadata lookup. Works with Dynamics 365, Power Platform, and custom Dataverse environments. @@ -149,7 +149,7 @@ Remove an association between two records in Microsoft Dataverse. For collection ### `microsoft_dataverse_download_file` -Download a file from a file or image column on a Dataverse record. Returns the file content as a base64-encoded string along with file metadata from response headers. +Download a file from a file or image column on a Dataverse record. Stores the file in execution storage and returns a file reference, plus the base64 content and metadata directly. #### Input @@ -164,10 +164,12 @@ Download a file from a file or image column on a Dataverse record. Returns the f | Parameter | Type | Description | | --------- | ---- | ----------- | +| `file` | file | Downloaded file stored in execution files | | `fileContent` | string | Base64-encoded file content | | `fileName` | string | Name of the downloaded file | | `fileSize` | number | File size in bytes | | `mimeType` | string | MIME type of the file | +| `fileColumn` | string | File column the file was downloaded from | | `success` | boolean | Whether the file was downloaded successfully | ### `microsoft_dataverse_execute_action` @@ -203,7 +205,7 @@ Execute a bound or unbound Dataverse function. Functions are read-only operation | `functionName` | string | Yes | Function name \(e.g., RetrievePrincipalAccess, RetrieveTotalRecordCount\). Do not include the Microsoft.Dynamics.CRM. namespace prefix for unbound functions. | | `entitySetName` | string | No | Entity set name for bound functions \(e.g., systemusers\). Leave empty for unbound functions. | | `recordId` | string | No | Record GUID for bound functions. Leave empty for unbound functions. | -| `parameters` | string | No | Function parameters as a comma-separated list of name=value pairs for the URL \(e.g., "LocalizedStandardName=\'Pacific Standard Time\ | +| `parameters` | string | No | Function parameters for the URL. Simple values can be inlined \(e.g., "LocalizedStandardName=\'Pacific Standard Time\ | #### Output @@ -234,6 +236,32 @@ Execute a FetchXML query against a Microsoft Dataverse table. FetchXML supports | `moreRecords` | boolean | Whether more records are available beyond the current page | | `success` | boolean | Operation success status | +### `microsoft_dataverse_get_entity_metadata` + +Retrieve table (entity) and column (attribute) definitions for a Microsoft Dataverse table by its singular logical name. Use this to look up the correct entity set name and column logical names before building record data for other operations. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `environmentUrl` | string | Yes | Dataverse environment URL \(e.g., https://myorg.crm.dynamics.com\) | +| `entityLogicalName` | string | Yes | Singular table logical name to look up \(e.g., account, contact\) | +| `select` | string | No | Comma-separated table metadata properties to return \(OData $select, e.g., LogicalName,DisplayName,EntitySetName,PrimaryIdAttribute\) | +| `includeAttributes` | string | No | Set to "true" to also return the column \(attribute\) definitions for the table | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `entitySetName` | string | The entity set name \(plural, used in Web API URLs\) for this table | +| `logicalName` | string | The singular logical name of the table | +| `displayName` | string | The localized display name of the table | +| `primaryIdAttribute` | string | The logical name of the primary key column | +| `primaryNameAttribute` | string | The logical name of the primary name \(title\) column | +| `attributes` | array | Column \(attribute\) definitions for the table \(only populated when includeAttributes is "true"\) | +| `metadata` | object | The full raw entity metadata response from Dataverse | +| `success` | boolean | Whether the metadata was retrieved successfully | + ### `microsoft_dataverse_get_record` Retrieve a single record from a Microsoft Dataverse table by its ID. Supports $select and $expand OData query options. diff --git a/apps/docs/content/docs/en/integrations/microsoft_teams.mdx b/apps/docs/content/docs/en/integrations/microsoft_teams.mdx index 955088c7fc5..79a30ac432a 100644 --- a/apps/docs/content/docs/en/integrations/microsoft_teams.mdx +++ b/apps/docs/content/docs/en/integrations/microsoft_teams.mdx @@ -29,7 +29,7 @@ In Sim, the Microsoft Teams integration enables your agents to interact directly ## Usage Instructions -Integrate Microsoft Teams into the workflow. Read, write, update, and delete chat and channel messages. Reply to messages, add reactions, and list team/channel members. Can be used in trigger mode to trigger a workflow when a message is sent to a chat or channel. To mention users in messages, wrap their name in `` tags: `userName` +Integrate Microsoft Teams into the workflow. Read, write, update, and delete chat and channel messages. Reply to messages, add reactions, and list teams, chats, channels, and their members. Can be used in trigger mode to trigger a workflow when a message is sent to a chat or channel. To mention users in messages, wrap their name in `` tags: `userName` @@ -347,6 +347,80 @@ List all members of a Microsoft Teams channel | `members` | array | Array of channel members | | `memberCount` | number | Total number of members | +### `microsoft_teams_list_chat_members` + +List all members of a Microsoft Teams chat + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `chatId` | string | Yes | The ID of the chat \(e.g., "19:abc123def456@thread.v2" - from chat listings\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the listing was successful | +| `members` | array | Array of chat members | +| `memberCount` | number | Total number of members | +| `hasMore` | boolean | Whether Graph indicated additional pages beyond this response | + +### `microsoft_teams_list_teams` + +List the Microsoft Teams the current user is a direct member of + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the listing was successful | +| `teams` | array | Array of teams the user is a member of | +| `teamCount` | number | Total number of teams | +| `hasMore` | boolean | Whether Graph indicated additional pages beyond this response | + +### `microsoft_teams_list_chats` + +List the Microsoft Teams chats the current user is part of + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the listing was successful | +| `chats` | array | Array of chats the user is part of | +| `chatCount` | number | Total number of chats | +| `hasMore` | boolean | Whether Graph indicated additional pages beyond this response | + +### `microsoft_teams_list_channels` + +List all channels in a Microsoft Teams team + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `teamId` | string | Yes | The ID of the team \(e.g., "12345678-abcd-1234-efgh-123456789012" - a GUID from team listings\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the listing was successful | +| `channels` | array | Array of channels in the team | +| `channelCount` | number | Total number of channels | +| `hasMore` | boolean | Whether Graph indicated additional pages beyond this response | + ## Triggers diff --git a/apps/docs/content/docs/en/integrations/new_relic.mdx b/apps/docs/content/docs/en/integrations/new_relic.mdx index 7f24f87e7bb..8e5e5b72108 100644 --- a/apps/docs/content/docs/en/integrations/new_relic.mdx +++ b/apps/docs/content/docs/en/integrations/new_relic.mdx @@ -76,6 +76,12 @@ Search New Relic entities by name, GUID, domain type, tags, or reporting state. | ↳ `guid` | string | Entity GUID | | ↳ `name` | string | Entity name | | ↳ `entityType` | string | Entity type | +| ↳ `domain` | string | Entity domain, e.g. APM, INFRA | +| ↳ `reporting` | boolean | Whether the entity is currently reporting data | +| ↳ `alertSeverity` | string | Current alert severity for the entity | +| ↳ `tags` | array | Entity tags | +| ↳ `key` | string | Tag key | +| ↳ `values` | array | Tag values | | `nextCursor` | string | Cursor for the next page of results | ### `new_relic_get_entity` @@ -98,6 +104,12 @@ Fetch a New Relic entity by GUID. | ↳ `guid` | string | Entity GUID | | ↳ `name` | string | Entity name | | ↳ `entityType` | string | Entity type | +| ↳ `domain` | string | Entity domain, e.g. APM, INFRA | +| ↳ `reporting` | boolean | Whether the entity is currently reporting data | +| ↳ `alertSeverity` | string | Current alert severity for the entity | +| ↳ `tags` | array | Entity tags | +| ↳ `key` | string | Tag key | +| ↳ `values` | array | Tag values | ### `new_relic_create_deployment_event` diff --git a/apps/docs/content/docs/en/integrations/onedrive.mdx b/apps/docs/content/docs/en/integrations/onedrive.mdx index 1383114ec11..110a34e77b8 100644 --- a/apps/docs/content/docs/en/integrations/onedrive.mdx +++ b/apps/docs/content/docs/en/integrations/onedrive.mdx @@ -1,6 +1,6 @@ --- title: OneDrive -description: Create, upload, download, list, and delete files +description: Create, upload, download, search, move, copy, share, and delete files --- import { BlockInfoCard } from "@/components/ui/block-info-card" @@ -30,7 +30,7 @@ In Sim, the OneDrive integration enables your agents to directly interact with y ## Usage Instructions -Integrate OneDrive into the workflow. Can create text and Excel files, upload files, download files, list files, and delete files or folders. +Integrate OneDrive into the workflow. Can create text and Excel files, upload files, download files, list and search files, move or rename files, copy files, create sharing links, and delete files or folders. @@ -48,8 +48,7 @@ Upload a file to OneDrive | `file` | file | No | The file to upload \(binary\) | | `content` | string | No | The text content to upload \(if no file is provided\) | | `mimeType` | string | No | The MIME type of the file to create \(e.g., text/plain for .txt, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet for .xlsx\) | -| `folderSelector` | string | No | Folder ID to upload the file to \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\) | -| `manualFolderId` | string | No | Manually entered folder ID \(advanced mode\) | +| `folderId` | string | No | Folder ID to upload the file to \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\) | #### Output @@ -67,8 +66,7 @@ Create a new folder in OneDrive | Parameter | Type | Required | Description | | --------- | ---- | -------- | ----------- | | `folderName` | string | Yes | Name of the folder to create \(e.g., "My Documents", "Project Files"\) | -| `folderSelector` | string | No | Parent folder ID to create the folder in \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\) | -| `manualFolderId` | string | No | Manually entered parent folder ID \(advanced mode\) | +| `folderId` | string | No | Parent folder ID to create the folder in \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\) | #### Output @@ -102,10 +100,10 @@ List files and folders in OneDrive | Parameter | Type | Required | Description | | --------- | ---- | -------- | ----------- | -| `folderSelector` | string | No | Folder ID to list files from \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\) | -| `manualFolderId` | string | No | The manually entered folder ID \(advanced mode\) | +| `folderId` | string | No | Folder ID to list files from \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\) | | `query` | string | No | Filter files by name prefix \(e.g., "report", "invoice_2024"\) | | `pageSize` | number | No | Maximum number of files to return \(e.g., 10, 50, 100\) | +| `pageToken` | string | No | Continuation URL from a previous response's nextPageToken, used to fetch the next page | #### Output @@ -115,6 +113,122 @@ List files and folders in OneDrive | `files` | array | Array of file and folder objects with metadata | | `nextPageToken` | string | Token for retrieving the next page of results \(optional\) | +### `onedrive_search` + +Search for files and folders across OneDrive by name, metadata, or content (recursive) + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `query` | string | No | Search text matched against file name, metadata, and content. Not required when paginating with pageToken | +| `pageSize` | number | No | Maximum number of results to return \(e.g., 10, 50, 100\) | +| `pageToken` | string | No | Continuation URL from a previous response's nextPageToken, used to fetch the next page | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the search completed successfully | +| `files` | array | Array of file and folder objects matching the search query | +| `nextPageToken` | string | Token for retrieving the next page of results \(optional\) | + +### `onedrive_get_item` + +Get metadata for a specific OneDrive file or folder by ID, or the drive root + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `fileId` | string | No | The ID of the file or folder to retrieve \(e.g., "01BYE5RZ6QN3ZWBTUFOFD3GSPGOHDJD36M"\). Leave empty to get the drive root folder | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the item metadata was retrieved | +| `file` | object | The file or folder metadata, including id, name, webViewLink, size, and timestamps | + +### `onedrive_get_drive_info` + +Get information about the OneDrive drive, including storage quota + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the drive info was retrieved | +| `driveId` | string | The ID of the drive | +| `driveType` | string | The type of drive \(e.g., "personal", "business"\) | +| `webUrl` | string | URL to the drive in the browser | +| `owner` | string | Display name of the drive owner | +| `quota` | object | Storage quota information in bytes \(total, used, remaining, deleted, state\) | + +### `onedrive_move` + +Move a file or folder to a new parent folder, rename it, or both + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `fileId` | string | Yes | The ID of the file or folder to move or rename | +| `destinationFolderId` | string | No | The ID of the destination parent folder \(omit to only rename in place\) | +| `newName` | string | No | The new name for the file or folder \(omit to only move\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the move or rename was successful | +| `file` | object | The updated file object with its new name and/or parent folder | + +### `onedrive_copy` + +Copy a file or folder to another location within OneDrive + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `fileId` | string | Yes | The ID of the file or folder to copy | +| `destinationFolderId` | string | Yes | The ID of the destination parent folder | +| `destinationFileName` | string | No | Optional new name for the copy \(defaults to the original name\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the copy request was accepted | +| `sourceFileId` | string | The ID of the file or folder that was copied | +| `name` | string | The requested name for the copy, if provided | +| `monitorUrl` | string | URL to poll for the status of the asynchronous copy operation \(copy completes in the background\) | + +### `onedrive_create_share_link` + +Create a view or edit sharing link for a OneDrive file or folder + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `fileId` | string | Yes | The ID of the file or folder to share | +| `linkType` | string | No | Type of link to create: "view" \(read-only\), "edit" \(read-write\), or "embed" | +| `linkScope` | string | No | Who can use the link: "anonymous" \(anyone\), "organization" \(tenant members\), or "users" \(specific people\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `success` | boolean | Whether the sharing link was created successfully | +| `link` | object | The created sharing link, including its type, scope, and URL | + ### `onedrive_delete` Delete a file or folder from OneDrive diff --git a/apps/docs/content/docs/en/integrations/pagerduty.mdx b/apps/docs/content/docs/en/integrations/pagerduty.mdx index a7ffe68650e..664b937d786 100644 --- a/apps/docs/content/docs/en/integrations/pagerduty.mdx +++ b/apps/docs/content/docs/en/integrations/pagerduty.mdx @@ -30,7 +30,7 @@ In Sim, the PagerDuty integration enables powerful incident automation scenarios ## Usage Instructions -Integrate PagerDuty into your workflow to list, create, and update incidents, add notes, list services, and check on-call schedules. +Integrate PagerDuty into your workflow to list, get, create, update, snooze, and merge incidents, add notes and list alerts, look up services and escalation policies, check on-call schedules, list users, and send monitoring events through the Events API v2. @@ -46,11 +46,13 @@ List incidents from PagerDuty with optional filters. | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PagerDuty REST API Key | | `statuses` | string | No | Comma-separated statuses to filter \(triggered, acknowledged, resolved\) | +| `urgencies` | string | No | Comma-separated urgencies to filter \(high, low\) | | `serviceIds` | string | No | Comma-separated service IDs to filter | | `since` | string | No | Start date filter \(ISO 8601 format\) | | `until` | string | No | End date filter \(ISO 8601 format\) | | `sortBy` | string | No | Sort field \(e.g., created_at:desc\) | | `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | #### Output @@ -70,8 +72,41 @@ List incidents from PagerDuty with optional filters. | ↳ `assigneeId` | string | Assignee ID | | ↳ `escalationPolicyName` | string | Escalation policy name | | ↳ `htmlUrl` | string | PagerDuty web URL | -| `total` | number | Total number of matching incidents | +| `total` | number | Total number of matching incidents \(null unless explicitly requested by PagerDuty\) | | `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + +### `pagerduty_get_incident` + +Get a single incident from PagerDuty by ID. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `incidentId` | string | Yes | ID of the incident to fetch | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Incident ID | +| `incidentNumber` | number | Incident number | +| `title` | string | Incident title | +| `status` | string | Incident status | +| `urgency` | string | Incident urgency | +| `createdAt` | string | Creation timestamp | +| `updatedAt` | string | Last updated timestamp | +| `resolvedAt` | string | Resolution timestamp | +| `serviceName` | string | Service name | +| `serviceId` | string | Service ID | +| `assigneeName` | string | Assignee name | +| `assigneeId` | string | Assignee ID | +| `escalationPolicyName` | string | Escalation policy name | +| `escalationPolicyId` | string | Escalation policy ID | +| `incidentKey` | string | De-duplication key | +| `htmlUrl` | string | PagerDuty web URL | ### `pagerduty_create_incident` @@ -89,6 +124,7 @@ Create a new incident in PagerDuty. | `body` | string | No | Detailed description of the incident | | `escalationPolicyId` | string | No | Escalation policy ID to assign | | `assigneeId` | string | No | User ID to assign the incident to | +| `incidentKey` | string | No | De-duplication key. A subsequent request with the same service and incident key updates the existing open incident instead of creating a new one | #### Output @@ -115,10 +151,11 @@ Update an incident in PagerDuty (acknowledge, resolve, change urgency, etc.). | `apiKey` | string | Yes | PagerDuty REST API Key | | `fromEmail` | string | Yes | Email address of a valid PagerDuty user | | `incidentId` | string | Yes | ID of the incident to update | -| `status` | string | No | New status \(acknowledged or resolved\) | +| `status` | string | No | New status \(triggered, acknowledged, or resolved\) | | `title` | string | No | New incident title | | `urgency` | string | No | New urgency \(high or low\) | | `escalationLevel` | string | No | Escalation level to escalate to | +| `resolution` | string | No | Resolution note added to the incident's log entry. Only used when status is set to resolved | #### Output @@ -132,6 +169,51 @@ Update an incident in PagerDuty (acknowledge, resolve, change urgency, etc.). | `updatedAt` | string | Last updated timestamp | | `htmlUrl` | string | PagerDuty web URL | +### `pagerduty_snooze_incident` + +Snooze a triggered PagerDuty incident for a number of seconds, after which it returns to triggered. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `fromEmail` | string | Yes | Email address of a valid PagerDuty user | +| `incidentId` | string | Yes | ID of the incident to snooze | +| `duration` | string | Yes | Number of seconds to snooze the incident for \(1 to 604800\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Incident ID | +| `incidentNumber` | number | Incident number | +| `status` | string | Incident status after snoozing | +| `htmlUrl` | string | PagerDuty web URL | + +### `pagerduty_merge_incidents` + +Merge one or more source incidents into a target incident. Source incidents are resolved and their alerts move to the target. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `fromEmail` | string | Yes | Email address of a valid PagerDuty user | +| `targetIncidentId` | string | Yes | ID of the incident that will absorb the source incidents | +| `sourceIncidentIds` | string | Yes | Comma-separated IDs of the incidents to merge into the target incident | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Target incident ID | +| `incidentNumber` | number | Target incident number | +| `title` | string | Target incident title | +| `status` | string | Target incident status | +| `htmlUrl` | string | PagerDuty web URL | + ### `pagerduty_add_note` Add a note to an existing PagerDuty incident. @@ -154,6 +236,38 @@ Add a note to an existing PagerDuty incident. | `createdAt` | string | Creation timestamp | | `userName` | string | Name of the user who created the note | +### `pagerduty_list_incident_alerts` + +List the individual alerts attached to a PagerDuty incident. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `incidentId` | string | Yes | ID of the incident whose alerts to list | +| `statuses` | string | No | Comma-separated statuses to filter \(triggered, resolved\) | +| `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `alerts` | array | Array of alerts attached to the incident | +| ↳ `id` | string | Alert ID | +| ↳ `summary` | string | Alert summary | +| ↳ `status` | string | Alert status | +| ↳ `severity` | string | Alert severity | +| ↳ `createdAt` | string | Creation timestamp | +| ↳ `alertKey` | string | De-duplication key | +| ↳ `serviceName` | string | Service name | +| ↳ `serviceId` | string | Service ID | +| ↳ `htmlUrl` | string | PagerDuty web URL | +| `total` | number | Total number of matching alerts \(null unless explicitly requested by PagerDuty\) | +| `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + ### `pagerduty_list_services` List services from PagerDuty with optional name filter. @@ -165,6 +279,7 @@ List services from PagerDuty with optional name filter. | `apiKey` | string | Yes | PagerDuty REST API Key | | `query` | string | No | Filter services by name | | `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | #### Output @@ -179,8 +294,36 @@ List services from PagerDuty with optional name filter. | ↳ `escalationPolicyId` | string | Escalation policy ID | | ↳ `createdAt` | string | Creation timestamp | | ↳ `htmlUrl` | string | PagerDuty web URL | -| `total` | number | Total number of matching services | +| `total` | number | Total number of matching services \(null unless explicitly requested by PagerDuty\) | | `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + +### `pagerduty_get_service` + +Get a single service from PagerDuty by ID. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `serviceId` | string | Yes | ID of the service to fetch | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Service ID | +| `name` | string | Service name | +| `description` | string | Service description | +| `status` | string | Service status | +| `autoResolveTimeout` | number | Seconds before an open incident auto-resolves | +| `acknowledgementTimeout` | number | Seconds before an acknowledged incident reverts to triggered | +| `createdAt` | string | Creation timestamp | +| `lastIncidentTimestamp` | string | Timestamp of the most recent incident | +| `escalationPolicyName` | string | Escalation policy name | +| `escalationPolicyId` | string | Escalation policy ID | +| `htmlUrl` | string | PagerDuty web URL | ### `pagerduty_list_oncalls` @@ -196,6 +339,7 @@ List current on-call entries from PagerDuty. | `since` | string | No | Start time filter \(ISO 8601 format\) | | `until` | string | No | End time filter \(ISO 8601 format\) | | `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | #### Output @@ -211,8 +355,119 @@ List current on-call entries from PagerDuty. | ↳ `scheduleId` | string | Schedule ID | | ↳ `start` | string | On-call start time | | ↳ `end` | string | On-call end time | -| `total` | number | Total number of matching on-call entries | +| `total` | number | Total number of matching on-call entries \(null unless explicitly requested by PagerDuty\) | +| `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + +### `pagerduty_list_escalation_policies` + +List escalation policies from PagerDuty with an optional name filter. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `query` | string | No | Filter escalation policies by name | +| `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `escalationPolicies` | array | Array of escalation policies | +| ↳ `id` | string | Escalation policy ID | +| ↳ `name` | string | Escalation policy name | +| ↳ `description` | string | Escalation policy description | +| ↳ `numLoops` | number | Number of times the policy repeats | +| ↳ `onCallHandoffNotifications` | string | Handoff notification setting \(if_has_services or always\) | +| ↳ `htmlUrl` | string | PagerDuty web URL | +| `total` | number | Total number of matching escalation policies \(null unless explicitly requested by PagerDuty\) | +| `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + +### `pagerduty_list_schedules` + +List on-call schedules from PagerDuty with an optional name filter. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `query` | string | No | Filter schedules by name | +| `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `schedules` | array | Array of on-call schedules | +| ↳ `id` | string | Schedule ID | +| ↳ `name` | string | Schedule name | +| ↳ `description` | string | Schedule description | +| ↳ `timeZone` | string | Schedule time zone | +| ↳ `htmlUrl` | string | PagerDuty web URL | +| `total` | number | Total number of matching schedules \(null unless explicitly requested by PagerDuty\) | | `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + +### `pagerduty_list_users` + +List users from PagerDuty with an optional name/email filter. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PagerDuty REST API Key | +| `query` | string | No | Filter users by name or email | +| `limit` | string | No | Maximum number of results \(max 100\) | +| `offset` | string | No | Offset to start pagination search results | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `users` | array | Array of users | +| ↳ `id` | string | User ID | +| ↳ `name` | string | User name | +| ↳ `email` | string | User email | +| ↳ `role` | string | User role | +| ↳ `jobTitle` | string | User job title | +| ↳ `timeZone` | string | User preferred time zone | +| ↳ `htmlUrl` | string | PagerDuty web URL | +| `total` | number | Total number of matching users \(null unless explicitly requested by PagerDuty\) | +| `more` | boolean | Whether more results are available | +| `offset` | number | Offset used for this page of results | + +### `pagerduty_send_event` + +Send a trigger, acknowledge, or resolve event to PagerDuty Events API v2 using a service integration key. Used to page from monitoring/alerting sources without a PagerDuty user account. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `routingKey` | string | Yes | The Events API v2 integration key \(routing key\) for the target service | +| `eventAction` | string | Yes | Event action: trigger, acknowledge, or resolve | +| `summary` | string | No | Brief summary of the event. Required when eventAction is trigger | +| `source` | string | No | Unique location of the affected system \(e.g. hostname\). Required when eventAction is trigger | +| `severity` | string | No | Perceived severity: critical, warning, error, or info. Required when eventAction is trigger | +| `dedupKey` | string | No | De-duplication key identifying the alert. Required when eventAction is acknowledge or resolve; optional on trigger | +| `component` | string | No | Component of the source machine responsible for the event | +| `group` | string | No | Logical grouping of components of a service | +| `class` | string | No | The class/type of the event | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `status` | string | Result status \("success" if accepted\) | +| `message` | string | Description of the result | +| `dedupKey` | string | De-duplication key for the alert | diff --git a/apps/docs/content/docs/en/integrations/posthog.mdx b/apps/docs/content/docs/en/integrations/posthog.mdx index 7b87e552fd8..9857e27607f 100644 --- a/apps/docs/content/docs/en/integrations/posthog.mdx +++ b/apps/docs/content/docs/en/integrations/posthog.mdx @@ -49,6 +49,7 @@ Capture a single event in PostHog. Use this to track user actions, page views, o | --------- | ---- | -------- | ----------- | | `projectApiKey` | string | Yes | PostHog Project API Key \(public token for event ingestion\) | | `region` | string | No | PostHog region: us \(default\) or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `event` | string | Yes | The name of the event to capture \(e.g., "page_view", "button_clicked"\) | | `distinctId` | string | Yes | Unique identifier for the user or device \(e.g., "user123", email, or device UUID\) | | `properties` | string | No | JSON string of event properties \(e.g., \{"button_name": "signup", "page": "homepage"\}\) | @@ -70,6 +71,7 @@ Capture multiple events at once in PostHog. Use this for bulk event ingestion to | --------- | ---- | -------- | ----------- | | `projectApiKey` | string | Yes | PostHog Project API Key \(public token for event ingestion\) | | `region` | string | No | PostHog region: us \(default\) or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `batch` | string | Yes | JSON array of events to capture. Each event should have: event, distinct_id, and optional properties, timestamp. Example: \[\{"event": "page_view", "distinct_id": "user123", "properties": \{"page": "/"\}\}\] | #### Output @@ -89,6 +91,7 @@ List persons (users) in PostHog. Returns user profiles with their properties and | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PostHog Personal API Key \(for authenticated API access\) | | `region` | string | No | PostHog region: us \(default\) or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `limit` | number | No | Number of persons to return \(default: 100, max: 100\) | | `offset` | number | No | Number of persons to skip for pagination \(e.g., 0, 100, 200\) | @@ -117,6 +120,7 @@ Get detailed information about a specific person in PostHog by their ID or UUID. | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PostHog Personal API Key \(for authenticated API access\) | | `region` | string | No | PostHog region: us \(default\) or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `personId` | string | Yes | Person ID or UUID to retrieve \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | @@ -141,6 +145,7 @@ Delete a person from PostHog. This will remove all associated events and data. U | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PostHog Personal API Key \(for authenticated API access\) | | `region` | string | No | PostHog region: us \(default\) or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `personId` | string | Yes | Person ID or UUID to delete \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | @@ -160,6 +165,7 @@ Execute a HogQL query in PostHog. HogQL is PostHog's SQL-like query language for | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PostHog Personal API Key \(for authenticated API access\) | | `region` | string | No | PostHog region: us \(default\) or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `query` | string | Yes | HogQL query to execute. Example: \{"kind": "HogQLQuery", "query": "SELECT event, count\(\) FROM events WHERE timestamp > now\(\) - INTERVAL 1 DAY GROUP BY event"\} | | `values` | string | No | Optional JSON string of parameter values for parameterized queries. Example: \{"user_id": "123"\} | @@ -176,7 +182,7 @@ Execute a HogQL query in PostHog. HogQL is PostHog's SQL-like query language for ### `posthog_list_insights` -List all insights in a PostHog project. Returns insight configurations, filters, and metadata. +List all insights in a PostHog project. Returns insight configurations and metadata. #### Input @@ -185,6 +191,7 @@ List all insights in a PostHog project. Returns insight configurations, filters, | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -199,18 +206,16 @@ List all insights in a PostHog project. Returns insight configurations, filters, | ↳ `id` | number | Unique identifier for the insight | | ↳ `name` | string | Name of the insight | | ↳ `description` | string | Description of the insight | -| ↳ `filters` | object | Filter configuration for the insight | | ↳ `query` | object | Query configuration for the insight | | ↳ `created_at` | string | ISO timestamp when insight was created | | ↳ `created_by` | object | User who created the insight | | ↳ `last_modified_at` | string | ISO timestamp when insight was last modified | | ↳ `last_modified_by` | object | User who last modified the insight | -| ↳ `saved` | boolean | Whether the insight is saved | | ↳ `dashboards` | array | IDs of dashboards this insight appears on | ### `posthog_get_insight` -Get a specific insight by ID from PostHog. Returns detailed insight configuration, filters, and metadata. +Get a specific insight by ID from PostHog. Returns detailed insight configuration and metadata. #### Input @@ -220,6 +225,7 @@ Get a specific insight by ID from PostHog. Returns detailed insight configuratio | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `insightId` | string | Yes | The insight ID to retrieve \(e.g., "42" or short ID like "abc123"\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -228,20 +234,18 @@ Get a specific insight by ID from PostHog. Returns detailed insight configuratio | `id` | number | Unique identifier for the insight | | `name` | string | Name of the insight | | `description` | string | Description of the insight | -| `filters` | object | Filter configuration for the insight | | `query` | object | Query configuration for the insight | | `created_at` | string | ISO timestamp when insight was created | | `created_by` | object | User who created the insight | | `last_modified_at` | string | ISO timestamp when insight was last modified | | `last_modified_by` | object | User who last modified the insight | -| `saved` | boolean | Whether the insight is saved | | `dashboards` | array | IDs of dashboards this insight appears on | | `tags` | array | Tags associated with the insight | | `favorited` | boolean | Whether the insight is favorited | ### `posthog_create_insight` -Create a new insight in PostHog. Requires insight name and configuration filters or query. +Create a new insight in PostHog. Requires insight name and a query configuration. #### Input @@ -250,9 +254,9 @@ Create a new insight in PostHog. Requires insight name and configuration filters | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `name` | string | No | Name for the insight \(optional - PostHog will generate a derived name if not provided\) | | `description` | string | No | Description of the insight | -| `filters` | string | No | JSON string of filter configuration for the insight | | `query` | string | No | JSON string of query configuration for the insight | | `dashboards` | string | No | Comma-separated list of dashboard IDs to add this insight to | | `tags` | string | No | Comma-separated list of tags for the insight | @@ -264,15 +268,47 @@ Create a new insight in PostHog. Requires insight name and configuration filters | `id` | number | Unique identifier for the created insight | | `name` | string | Name of the insight | | `description` | string | Description of the insight | -| `filters` | object | Filter configuration for the insight | | `query` | object | Query configuration for the insight | | `created_at` | string | ISO timestamp when insight was created | | `created_by` | object | User who created the insight | | `last_modified_at` | string | ISO timestamp when insight was last modified | -| `saved` | boolean | Whether the insight is saved | | `dashboards` | array | IDs of dashboards this insight appears on | | `tags` | array | Tags associated with the insight | +### `posthog_update_insight` + +Update an existing insight in PostHog. Can modify name, description, query, dashboards, tags, and favorited status. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PostHog Personal API Key | +| `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | +| `insightId` | string | Yes | The insight ID to update \(e.g., "42" or short ID like "abc123"\) | +| `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | +| `name` | string | No | Updated name for the insight | +| `description` | string | No | Updated description for the insight | +| `query` | string | No | JSON string of updated query configuration for the insight | +| `dashboards` | string | No | Comma-separated list of dashboard IDs to attach this insight to | +| `tags` | string | No | Comma-separated list of tags for the insight | +| `favorited` | boolean | No | Whether to mark the insight as favorited | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | number | Unique identifier for the insight | +| `name` | string | Name of the insight | +| `description` | string | Description of the insight | +| `query` | object | Query configuration for the insight | +| `created_at` | string | ISO timestamp when insight was created | +| `last_modified_at` | string | ISO timestamp when insight was last modified | +| `dashboards` | array | IDs of dashboards this insight appears on | +| `tags` | array | Tags associated with the insight | +| `favorited` | boolean | Whether the insight is favorited | + ### `posthog_list_dashboards` List all dashboards in a PostHog project. Returns dashboard configurations, tiles, and metadata. @@ -284,6 +320,7 @@ List all dashboards in a PostHog project. Returns dashboard configurations, tile | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -319,6 +356,7 @@ Get a specific dashboard by ID from PostHog. Returns detailed dashboard configur | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `dashboardId` | string | Yes | The dashboard ID to retrieve \(e.g., "42"\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -337,6 +375,37 @@ Get a specific dashboard by ID from PostHog. Returns detailed dashboard configur | `tags` | array | Tags associated with the dashboard | | `restriction_level` | number | Access restriction level for the dashboard | +### `posthog_create_dashboard` + +Create a new dashboard in PostHog. Optionally seed it from a built-in template, then attach insights to it afterward. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PostHog Personal API Key | +| `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | +| `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | +| `name` | string | Yes | Name for the new dashboard | +| `description` | string | No | Description of the dashboard | +| `pinned` | boolean | No | Whether to pin the dashboard to the sidebar | +| `tags` | string | No | Comma-separated list of tags for the dashboard | +| `useTemplate` | string | No | Name of a built-in PostHog dashboard template to seed this dashboard from \(e.g., "Product analytics"\) | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | number | Unique identifier for the created dashboard | +| `name` | string | Name of the dashboard | +| `description` | string | Description of the dashboard | +| `pinned` | boolean | Whether the dashboard is pinned | +| `created_at` | string | ISO timestamp when dashboard was created | +| `tiles` | array | Tiles/widgets on the dashboard | +| `filters` | object | Global filters applied to the dashboard | +| `tags` | array | Tags associated with the dashboard | + ### `posthog_list_actions` List all actions in a PostHog project. Returns action definitions, steps, and metadata. @@ -348,8 +417,10 @@ List all actions in a PostHog project. Returns action definitions, steps, and me | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | +| `search` | string | No | Search term to filter actions by name | #### Output @@ -383,6 +454,7 @@ List all cohorts in a PostHog project. Returns cohort definitions, filters, and | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -421,6 +493,7 @@ Get a specific cohort by ID from PostHog. Returns detailed cohort definition, fi | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `cohortId` | string | Yes | The cohort ID to retrieve \(e.g., "42"\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -453,6 +526,7 @@ Create a new cohort in PostHog. Requires cohort name and filter or query configu | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `name` | string | No | Name for the cohort \(optional - PostHog will use "Untitled cohort" if not provided\) | | `description` | string | No | Description of the cohort | | `filters` | string | No | JSON string of filter configuration for the cohort | @@ -478,6 +552,44 @@ Create a new cohort in PostHog. Requires cohort name and filter or query configu | `is_static` | boolean | Whether the cohort is static | | `version` | number | Version number of the cohort | +### `posthog_update_cohort` + +Update an existing cohort in PostHog. Can modify name, description, filters, query, static membership, and deleted status. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PostHog Personal API Key | +| `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | +| `cohortId` | string | Yes | The cohort ID to update \(e.g., "42"\) | +| `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | +| `name` | string | No | Updated name for the cohort | +| `description` | string | No | Updated description of the cohort | +| `filters` | string | No | JSON string of updated filter configuration for the cohort | +| `query` | string | No | JSON string of updated query configuration for the cohort | +| `isStatic` | boolean | No | Whether the cohort is static | +| `groups` | string | No | JSON string of updated groups that define the cohort | +| `deleted` | boolean | No | Set to true to archive \(soft-delete\) the cohort | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | number | Unique identifier for the cohort | +| `name` | string | Name of the cohort | +| `description` | string | Description of the cohort | +| `groups` | array | Groups that define the cohort | +| `deleted` | boolean | Whether the cohort is deleted | +| `filters` | object | Filter configuration for the cohort | +| `query` | object | Query configuration for the cohort | +| `created_at` | string | ISO timestamp when cohort was created | +| `is_calculating` | boolean | Whether the cohort is being calculated | +| `count` | number | Number of users in the cohort | +| `is_static` | boolean | Whether the cohort is static | +| `version` | number | Version number of the cohort | + ### `posthog_list_annotations` List all annotations in a PostHog project. Returns annotation content, timestamps, and associated insights. @@ -489,6 +601,7 @@ List all annotations in a PostHog project. Returns annotation content, timestamp | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -507,6 +620,7 @@ List all annotations in a PostHog project. Returns annotation content, timestamp | ↳ `updated_at` | string | ISO timestamp when annotation was last updated | | ↳ `created_by` | object | User who created the annotation | | ↳ `dashboard_item` | number | ID of dashboard item this annotation is attached to | +| ↳ `dashboard_id` | number | ID of the dashboard this annotation is attached to | | ↳ `insight_short_id` | string | Short ID of the insight this annotation is attached to | | ↳ `insight_name` | string | Name of the insight this annotation is attached to | | ↳ `scope` | string | Scope of the annotation \(project or dashboard\) | @@ -523,11 +637,12 @@ Create a new annotation in PostHog. Mark important events on your graphs with da | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: "us" or "eu" \(default: "us"\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `content` | string | Yes | Content/text of the annotation | | `date_marker` | string | Yes | ISO timestamp marking when the annotation applies \(e.g., "2024-01-15T10:00:00Z"\) | -| `scope` | string | No | Scope of the annotation: "project" or "dashboard_item" \(default: "project"\) | -| `dashboard_item` | string | No | ID of dashboard item to attach this annotation to | -| `insight_short_id` | string | No | Short ID of the insight to attach this annotation to | +| `scope` | string | No | Scope of the annotation: "project", "organization", "dashboard", or "dashboard_item" \(default: "project"\) | +| `dashboard_item` | string | No | ID of the dashboard tile \(insight\) to attach this annotation to \(used when scope is "dashboard_item"\) | +| `dashboard_id` | string | No | ID of the dashboard to attach this annotation to \(used when scope is "dashboard"\) | #### Output @@ -540,9 +655,10 @@ Create a new annotation in PostHog. Mark important events on your graphs with da | `updated_at` | string | ISO timestamp when annotation was last updated | | `created_by` | object | User who created the annotation | | `dashboard_item` | number | ID of dashboard item this annotation is attached to | +| `dashboard_id` | number | ID of the dashboard this annotation is attached to | | `insight_short_id` | string | Short ID of the insight this annotation is attached to | | `insight_name` | string | Name of the insight this annotation is attached to | -| `scope` | string | Scope of the annotation \(project or dashboard_item\) | +| `scope` | string | Scope of the annotation \(project, organization, dashboard, or dashboard_item\) | | `deleted` | boolean | Whether the annotation is deleted | ### `posthog_list_feature_flags` @@ -555,6 +671,7 @@ List all feature flags in a PostHog project | --------- | ---- | -------- | ----------- | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `limit` | number | No | Number of results to return \(e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -590,6 +707,7 @@ Get details of a specific feature flag | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `flagId` | string | Yes | The feature flag ID \(e.g., "42"\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | #### Output @@ -621,6 +739,7 @@ Create a new feature flag in PostHog | --------- | ---- | -------- | ----------- | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `name` | string | No | Feature flag name \(optional - can be empty\) | | `key` | string | Yes | Feature flag key \(unique identifier\) | @@ -657,6 +776,7 @@ Update an existing feature flag in PostHog | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `flagId` | string | Yes | The feature flag ID \(e.g., "42"\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `name` | string | No | Feature flag name | | `key` | string | No | Feature flag key \(unique identifier\) | @@ -693,6 +813,7 @@ Delete a feature flag from PostHog | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `flagId` | string | Yes | The feature flag ID to delete \(e.g., "42"\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | #### Output @@ -711,6 +832,7 @@ Evaluate feature flags for a specific user or group. This is a public endpoint t | Parameter | Type | Required | Description | | --------- | ---- | -------- | ----------- | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `projectApiKey` | string | Yes | PostHog Project API Key \(not personal API key\) | | `distinctId` | string | Yes | The distinct ID of the user to evaluate flags for \(e.g., "user123" or email\) | | `groups` | string | No | Groups as JSON string \(e.g., \{"company": "company_id_in_your_db"\}\) | @@ -735,6 +857,7 @@ List all experiments in a PostHog project | --------- | ---- | -------- | ----------- | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `limit` | number | No | Number of results to return \(e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -751,7 +874,6 @@ List all experiments in a PostHog project | ↳ `feature_flag` | object | Feature flag details | | ↳ `parameters` | object | Experiment parameters | | ↳ `filters` | object | Experiment filters | -| ↳ `variants` | object | Experiment variants | | ↳ `start_date` | string | Start date | | ↳ `end_date` | string | End date | | ↳ `created_at` | string | Creation timestamp | @@ -772,6 +894,7 @@ Get details of a specific experiment | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `experimentId` | string | Yes | The experiment ID \(e.g., "42"\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | #### Output @@ -786,7 +909,6 @@ Get details of a specific experiment | ↳ `feature_flag` | object | Feature flag details | | ↳ `parameters` | object | Experiment parameters | | ↳ `filters` | object | Experiment filters | -| ↳ `variants` | object | Experiment variants | | ↳ `start_date` | string | Start date | | ↳ `end_date` | string | End date | | ↳ `created_at` | string | Creation timestamp | @@ -805,13 +927,13 @@ Create a new experiment in PostHog | --------- | ---- | -------- | ----------- | | `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | -| `name` | string | No | Experiment name \(optional\) | +| `name` | string | Yes | Experiment name | | `description` | string | No | Experiment description | | `featureFlagKey` | string | Yes | Feature flag key to use for the experiment | | `parameters` | string | No | Experiment parameters as JSON string | | `filters` | string | No | Experiment filters as JSON string | -| `variants` | string | No | Experiment variants as JSON string | | `startDate` | string | No | Experiment start date \(ISO format\) | | `endDate` | string | No | Experiment end date \(ISO format\) | @@ -827,13 +949,50 @@ Create a new experiment in PostHog | ↳ `feature_flag` | object | Feature flag details | | ↳ `parameters` | object | Experiment parameters | | ↳ `filters` | object | Experiment filters | -| ↳ `variants` | object | Experiment variants | | ↳ `start_date` | string | Start date | | ↳ `end_date` | string | End date | | ↳ `created_at` | string | Creation timestamp | | ↳ `created_by` | object | Creator information | | ↳ `archived` | boolean | Whether the experiment is archived | +### `posthog_update_experiment` + +Update an existing experiment in PostHog. Use this to change dates, archive an experiment, or adjust its parameters and filters. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `projectId` | string | Yes | The PostHog project ID \(e.g., "12345" or project UUID\) | +| `experimentId` | string | Yes | The experiment ID to update \(e.g., "42"\) | +| `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | +| `apiKey` | string | Yes | PostHog Personal API Key | +| `name` | string | No | Updated experiment name | +| `description` | string | No | Updated experiment description | +| `parameters` | string | No | Updated experiment parameters as JSON string | +| `filters` | string | No | Updated experiment filters as JSON string | +| `startDate` | string | No | Updated start date \(ISO 8601\). Set this to launch a draft experiment. | +| `endDate` | string | No | Updated end date \(ISO 8601\). Set this to conclude a running experiment. | +| `archived` | boolean | No | Whether to archive the experiment | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `experiment` | object | Updated experiment | +| ↳ `id` | number | Experiment ID | +| ↳ `name` | string | Experiment name | +| ↳ `description` | string | Experiment description | +| ↳ `feature_flag_key` | string | Associated feature flag key | +| ↳ `feature_flag` | object | Feature flag details | +| ↳ `parameters` | object | Experiment parameters | +| ↳ `filters` | object | Experiment filters | +| ↳ `start_date` | string | Start date | +| ↳ `end_date` | string | End date | +| ↳ `created_at` | string | Creation timestamp | +| ↳ `archived` | boolean | Whether the experiment is archived | + ### `posthog_list_surveys` List all surveys in a PostHog project. Surveys allow you to collect feedback from users. @@ -845,6 +1004,7 @@ List all surveys in a PostHog project. Surveys allow you to collect feedback fro | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -878,6 +1038,7 @@ Get details of a specific survey in PostHog by ID. | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `surveyId` | string | Yes | Survey ID to retrieve \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -909,7 +1070,8 @@ Create a new survey in PostHog. Supports question types: Basic (open), Link, Rat | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | -| `name` | string | No | Survey name \(optional\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | +| `name` | string | Yes | Survey name | | `description` | string | No | Survey description | | `type` | string | No | Survey type: popover \(in-app\) or api \(custom implementation\) \(default: popover\) | | `questions` | string | Yes | JSON string of survey questions array. Each question must have type \(open/link/rating/multiple_choice\) and question text. Rating questions can have scale \(1-10\), lowerBoundLabel, upperBoundLabel. Multiple choice questions need choices array. Link questions can have buttonText. | @@ -947,6 +1109,7 @@ Update an existing survey in PostHog. Can modify questions, appearance, conditio | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `surveyId` | string | Yes | Survey ID to update \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `name` | string | No | Survey name | | `description` | string | No | Survey description | | `type` | string | No | Survey type: popover or api | @@ -975,6 +1138,26 @@ Update an existing survey in PostHog. Can modify questions, appearance, conditio | ↳ `end_date` | string | Survey end date | | ↳ `archived` | boolean | Whether survey is archived | +### `posthog_delete_survey` + +Delete a survey from PostHog. Use this to remove expired or unused surveys. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `apiKey` | string | Yes | PostHog Personal API Key | +| `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | +| `surveyId` | string | Yes | Survey ID to delete \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | +| `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `status` | string | Status message indicating whether the survey was deleted successfully | + ### `posthog_list_session_recordings` List session recordings in a PostHog project. Session recordings capture user interactions with your application. @@ -986,6 +1169,7 @@ List session recordings in a PostHog project. Session recordings capture user in | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return \(default: 50, e.g., 10, 25, 50\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 50, 100\) | @@ -1024,6 +1208,7 @@ Get details of a specific session recording in PostHog by ID. | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `recordingId` | string | Yes | Session recording ID to retrieve \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -1045,7 +1230,6 @@ Get details of a specific session recording in PostHog by ID. | ↳ `console_error_count` | number | Number of console errors | | ↳ `start_url` | string | Starting URL of the recording | | ↳ `person` | object | Person information | -| ↳ `matching_events` | array | Events that occurred during recording | ### `posthog_list_recording_playlists` @@ -1058,6 +1242,7 @@ List session recording playlists in a PostHog project. Playlists allow you to or | `apiKey` | string | Yes | PostHog Personal API Key | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `region` | string | No | PostHog cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `limit` | number | No | Number of results to return \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | Number of results to skip for pagination \(e.g., 0, 100, 200\) | @@ -1091,6 +1276,7 @@ List all event definitions in a PostHog project. Event definitions represent tra | --------- | ---- | -------- | ----------- | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | The initial index from which to return results \(e.g., 0, 100, 200\) | @@ -1108,8 +1294,6 @@ List all event definitions in a PostHog project. Event definitions represent tra | ↳ `name` | string | Event name | | ↳ `description` | string | Event description | | ↳ `tags` | array | Tags associated with the event | -| ↳ `volume_30_day` | number | Number of events received in the last 30 days | -| ↳ `query_usage_30_day` | number | Number of times this event was queried in the last 30 days | | ↳ `created_at` | string | ISO timestamp when the event was created | | ↳ `last_seen_at` | string | ISO timestamp when the event was last seen | | ↳ `updated_at` | string | ISO timestamp when the event was updated | @@ -1126,6 +1310,7 @@ Get details of a specific event definition in PostHog. Returns comprehensive inf | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `eventDefinitionId` | string | Yes | Event Definition ID to retrieve | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | #### Output @@ -1136,8 +1321,6 @@ Get details of a specific event definition in PostHog. Returns comprehensive inf | `name` | string | Event name | | `description` | string | Event description | | `tags` | array | Tags associated with the event | -| `volume_30_day` | number | Number of events received in the last 30 days | -| `query_usage_30_day` | number | Number of times this event was queried in the last 30 days | | `created_at` | string | ISO timestamp when the event was created | | `last_seen_at` | string | ISO timestamp when the event was last seen | | `updated_at` | string | ISO timestamp when the event was updated | @@ -1157,6 +1340,7 @@ Update an event definition in PostHog. Can modify description, tags, and verific | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `eventDefinitionId` | string | Yes | Event Definition ID to update | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `description` | string | No | Updated description for the event | | `tags` | string | No | Comma-separated list of tags to associate with the event | @@ -1170,8 +1354,6 @@ Update an event definition in PostHog. Can modify description, tags, and verific | `name` | string | Event name | | `description` | string | Updated event description | | `tags` | array | Updated tags associated with the event | -| `volume_30_day` | number | Number of events received in the last 30 days | -| `query_usage_30_day` | number | Number of times this event was queried in the last 30 days | | `created_at` | string | ISO timestamp when the event was created | | `last_seen_at` | string | ISO timestamp when the event was last seen | | `updated_at` | string | ISO timestamp when the event was updated | @@ -1190,6 +1372,7 @@ List all property definitions in a PostHog project. Property definitions represe | --------- | ---- | -------- | ----------- | | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `limit` | number | No | Number of results to return per page \(default: 100, e.g., 10, 50, 100\) | | `offset` | number | No | The initial index from which to return results \(e.g., 0, 100, 200\) | @@ -1211,9 +1394,7 @@ List all property definitions in a PostHog project. Property definitions represe | ↳ `is_numerical` | boolean | Whether the property is numerical | | ↳ `is_seen_on_filtered_events` | boolean | Whether the property is seen on filtered events | | ↳ `property_type` | string | The data type of the property | -| ↳ `type` | string | Property type: event, person, or group | -| ↳ `volume_30_day` | number | Number of times property was seen in the last 30 days | -| ↳ `query_usage_30_day` | number | Number of times this property was queried in the last 30 days | +| ↳ `type` | string | Property type: event, person, group, or session | | ↳ `created_at` | string | ISO timestamp when the property was created | | ↳ `updated_at` | string | ISO timestamp when the property was updated | | ↳ `updated_by` | object | User who last updated the property | @@ -1229,6 +1410,7 @@ Get details of a specific property definition in PostHog. Returns comprehensive | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `propertyDefinitionId` | string | Yes | Property Definition ID to retrieve | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | #### Output @@ -1242,16 +1424,13 @@ Get details of a specific property definition in PostHog. Returns comprehensive | `is_numerical` | boolean | Whether the property is numerical | | `is_seen_on_filtered_events` | boolean | Whether the property is seen on filtered events | | `property_type` | string | The data type of the property | -| `type` | string | Property type: event, person, or group | -| `volume_30_day` | number | Number of times property was seen in the last 30 days | -| `query_usage_30_day` | number | Number of times this property was queried in the last 30 days | +| `type` | string | Property type: event, person, group, or session | | `created_at` | string | ISO timestamp when the property was created | | `updated_at` | string | ISO timestamp when the property was updated | | `updated_by` | object | User who last updated the property | | `verified` | boolean | Whether the property has been verified | | `verified_at` | string | ISO timestamp when the property was verified | | `verified_by` | string | User who verified the property | -| `example` | string | Example value for the property | ### `posthog_update_property_definition` @@ -1264,6 +1443,7 @@ Update a property definition in PostHog. Can modify description, tags, property | `projectId` | string | Yes | PostHog Project ID \(e.g., "12345" or project UUID\) | | `propertyDefinitionId` | string | Yes | Property Definition ID to update | | `region` | string | Yes | PostHog cloud region: us or eu | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | | `apiKey` | string | Yes | PostHog Personal API Key | | `description` | string | No | Updated description for the property | | `tags` | string | No | Comma-separated list of tags to associate with the property | @@ -1281,16 +1461,13 @@ Update a property definition in PostHog. Can modify description, tags, property | `is_numerical` | boolean | Whether the property is numerical | | `is_seen_on_filtered_events` | boolean | Whether the property is seen on filtered events | | `property_type` | string | The data type of the property | -| `type` | string | Property type: event, person, or group | -| `volume_30_day` | number | Number of times property was seen in the last 30 days | -| `query_usage_30_day` | number | Number of times this property was queried in the last 30 days | +| `type` | string | Property type: event, person, group, or session | | `created_at` | string | ISO timestamp when the property was created | | `updated_at` | string | ISO timestamp when the property was updated | | `updated_by` | object | User who last updated the property | | `verified` | boolean | Whether the property has been verified | | `verified_at` | string | ISO timestamp when the property was verified | | `verified_by` | string | User who verified the property | -| `example` | string | Example value for the property | ### `posthog_list_projects` @@ -1302,6 +1479,7 @@ List all projects in the organization. Returns project details including IDs, na | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PostHog Personal API Key | | `region` | string | No | Cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -1336,6 +1514,7 @@ Get detailed information about a specific project by ID. Returns comprehensive p | `projectId` | string | Yes | Project ID \(e.g., "12345" or project UUID\) | | `apiKey` | string | Yes | PostHog Personal API Key | | `region` | string | No | Cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -1376,6 +1555,7 @@ List all organizations the user has access to. Returns organization details incl | --------- | ---- | -------- | ----------- | | `apiKey` | string | Yes | PostHog Personal API Key | | `region` | string | No | Cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output @@ -1403,6 +1583,7 @@ Get detailed information about a specific organization by ID. Returns comprehens | `organizationId` | string | Yes | Organization ID \(e.g., "01234567-89ab-cdef-0123-456789abcdef"\) | | `apiKey` | string | Yes | PostHog Personal API Key | | `region` | string | No | Cloud region: us or eu \(default: us\) | +| `host` | string | No | Self-hosted PostHog instance host \(e.g., "posthog.mycompany.com"\). Overrides the region setting when provided. | #### Output diff --git a/apps/docs/content/docs/en/integrations/textract.mdx b/apps/docs/content/docs/en/integrations/textract.mdx index 85473fc9961..e2dc421cb02 100644 --- a/apps/docs/content/docs/en/integrations/textract.mdx +++ b/apps/docs/content/docs/en/integrations/textract.mdx @@ -78,4 +78,68 @@ Integrate AWS Textract into your workflow to extract text, tables, forms, and ke | ↳ `pages` | number | Number of pages in the document | | `modelVersion` | string | Version of the Textract model used for processing | +### `textract_analyze_expense` + +Extract structured invoice and receipt fields using AWS Textract AnalyzeExpense + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `accessKeyId` | string | Yes | AWS Access Key ID | +| `secretAccessKey` | string | Yes | AWS Secret Access Key | +| `region` | string | Yes | AWS region for Textract service \(e.g., us-east-1\) | +| `processingMode` | string | No | Document type: single-page or multi-page. Defaults to single-page. | +| `file` | file | No | Invoice or receipt to be processed \(JPEG, PNG, or single-page PDF\). | +| `filePath` | string | No | URL to an invoice or receipt to be processed, if not uploaded directly. | +| `s3Uri` | string | No | S3 URI for multi-page processing \(s3://bucket/key\). | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `expenseDocuments` | array | Detected expense documents with summary fields and line items | +| ↳ `expenseIndex` | number | Index of the expense document | +| ↳ `summaryFields` | array | Header fields such as vendor name, invoice date, and totals | +| ↳ `lineItemGroups` | array | Groups of line items \(e.g., purchased items and their prices\) | +| ↳ `lineItemGroupIndex` | number | Index of the line item group | +| ↳ `lineItems` | array | Individual line items within the group | +| ↳ `lineItemExpenseFields` | array | Fields for a single line item \(description, quantity, price\) | +| `documentMetadata` | object | Metadata about the analyzed document | +| ↳ `pages` | number | Number of pages in the document | +| `modelVersion` | string | Version of the AnalyzeExpense model used \(multi-page/async only\) | + +### `textract_analyze_id` + +Extract identity document fields using AWS Textract AnalyzeID + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `accessKeyId` | string | Yes | AWS Access Key ID | +| `secretAccessKey` | string | Yes | AWS Secret Access Key | +| `region` | string | Yes | AWS region for Textract service \(e.g., us-east-1\) | +| `file` | file | No | Front of the identity document \(JPEG, PNG, or PDF\). | +| `filePath` | string | No | URL to the front of the identity document, if not uploaded directly. | +| `fileBack` | file | No | Back of the identity document, if applicable \(JPEG, PNG, or PDF\). | +| `filePathBack` | string | No | URL to the back of the identity document, if not uploaded directly. | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `identityDocuments` | array | Detected identity documents with normalized fields | +| ↳ `documentIndex` | number | Index of the document page set | +| ↳ `identityDocumentFields` | array | Normalized fields such as FIRST_NAME, LAST_NAME, DATE_OF_BIRTH, DOCUMENT_NUMBER, EXPIRATION_DATE | +| ↳ `type` | object | Normalized field label | +| ↳ `text` | string | Field label text | +| ↳ `confidence` | number | Confidence score \(0-100\) | +| ↳ `valueDetection` | object | Detected value for the field, with a normalized value for dates | +| ↳ `text` | string | Field value text | +| ↳ `confidence` | number | Confidence score \(0-100\) | +| `documentMetadata` | object | Metadata about the analyzed document | +| ↳ `pages` | number | Number of pages analyzed | +| `modelVersion` | string | Version of the AnalyzeID model used for processing | + diff --git a/apps/docs/content/docs/en/integrations/tinybird.mdx b/apps/docs/content/docs/en/integrations/tinybird.mdx index 4de04f0b281..ff58492cd35 100644 --- a/apps/docs/content/docs/en/integrations/tinybird.mdx +++ b/apps/docs/content/docs/en/integrations/tinybird.mdx @@ -30,7 +30,7 @@ Connect Tinybird to your workflows today to accelerate data-driven features, aut ## Usage Instructions -Interact with Tinybird: stream JSON or NDJSON events with the Events API, run SQL with the Query API, call published Pipe API Endpoints by name with dynamic parameters, and manage Data Sources by appending from a URL, truncating, or deleting rows by condition. +Interact with Tinybird: stream JSON or NDJSON events with the Events API, run SQL with the Query API, call published Pipe API Endpoints by name with dynamic parameters, manage Data Sources by appending from a URL, truncating, or deleting rows by condition, and poll the status of asynchronous jobs. @@ -50,7 +50,7 @@ Send events to a Tinybird Data Source using the Events API. Supports JSON and ND | `wait` | boolean | No | Wait for database acknowledgment before responding. Enables safer retries but introduces latency. Defaults to false. | | `format` | string | No | Format of the events data: "ndjson" \(default\) or "json" | | `compression` | string | No | Compression format: "none" \(default\) or "gzip" | -| `token` | string | Yes | Tinybird API Token with DATASOURCE:APPEND or DATASOURCE:CREATE scope | +| `token` | string | Yes | Tinybird API Token with DATASOURCES:APPEND or DATASOURCES:CREATE scope | #### Output @@ -70,7 +70,7 @@ Execute SQL queries against Tinybird Pipes and Data Sources using the Query API. | `base_url` | string | Yes | Tinybird API base URL \(e.g., https://api.tinybird.co\) | | `query` | string | Yes | SQL query to execute. Specify your desired output format \(e.g., FORMAT JSON, FORMAT CSV, FORMAT TSV\). JSON format provides structured data, while other formats return raw text. Example: "SELECT * FROM my_datasource LIMIT 100 FORMAT JSON" | | `pipeline` | string | No | Optional pipe name. When provided, enables SELECT * FROM _ syntax. Example: "my_pipe", "analytics_pipe" | -| `token` | string | Yes | Tinybird API Token with PIPE:READ scope | +| `token` | string | Yes | Tinybird API Token with PIPES:READ scope | #### Output @@ -96,7 +96,7 @@ Call a published Tinybird Pipe API Endpoint by name, passing dynamic parameters | `pipe` | string | Yes | Name of the published Pipe API Endpoint to call. Example: "top_pages" | | `parameters` | json | No | Dynamic Pipe parameters as a JSON object, sent as query-string arguments. Example: \{"start_date": "2024-01-01", "limit": 10\} | | `q` | string | No | Optional SQL to run on top of the Pipe result. Use "_" to reference the Pipe. Example: "SELECT count\(\) FROM _" | -| `token` | string | Yes | Tinybird API Token with PIPE:READ scope | +| `token` | string | Yes | Tinybird API Token with PIPES:READ scope | #### Output @@ -125,7 +125,7 @@ Append data to a Tinybird Data Source from a remote file URL (CSV, NDJSON, Parqu | `datasource` | string | Yes | Name of the existing Data Source to append to. Example: "events_raw" | | `url` | string | Yes | Publicly accessible URL of the file to append. Example: "https://example.com/data.csv" | | `format` | string | No | Format of the source file: "csv" \(default\), "ndjson", or "parquet" | -| `token` | string | Yes | Tinybird API Token with DATASOURCES:CREATE scope | +| `token` | string | Yes | Tinybird API Token with DATASOURCES:APPEND or DATASOURCES:CREATE scope | #### Output @@ -183,4 +183,32 @@ Delete rows from a Tinybird Data Source matching a SQL condition. | `status` | string | Current job status \(e.g., "waiting", "done"\) | | `job` | json | Full delete job details \(kind, id, status, delete_condition, rows_affected, ...\) | +### `tinybird_get_job` + +Check the status of an asynchronous Tinybird job (import, delete, etc.) by ID. + +#### Input + +| Parameter | Type | Required | Description | +| --------- | ---- | -------- | ----------- | +| `base_url` | string | Yes | Tinybird API base URL \(e.g., https://api.tinybird.co\) | +| `job_id` | string | Yes | ID of the job to check, as returned by an append or delete operation | +| `token` | string | Yes | Tinybird API Token with ADMIN scope, or the token that started the job | + +#### Output + +| Parameter | Type | Description | +| --------- | ---- | ----------- | +| `id` | string | Job identifier | +| `job_id` | string | Job identifier \(same as id\) | +| `kind` | string | Job kind \(e.g., "import", "delete_data", "populateview", "copy"\) | +| `status` | string | Current job status: "waiting", "working", "done", "error", or "cancelled" | +| `job_url` | string | URL to re-query this job status | +| `created_at` | string | Timestamp the job was created | +| `started_at` | string | Timestamp the job started running | +| `updated_at` | string | Timestamp of the last job status update | +| `is_cancellable` | boolean | Whether the job can still be cancelled | +| `error` | string | Error message, present only when status is "error" | +| `job` | json | Full raw job details, including kind-specific fields \(statistics, datasource, delete_condition, etc.\) | + diff --git a/apps/sim/blocks/blocks/google_vault.ts b/apps/sim/blocks/blocks/google_vault.ts index 57327385ff4..9a198a9a70e 100644 --- a/apps/sim/blocks/blocks/google_vault.ts +++ b/apps/sim/blocks/blocks/google_vault.ts @@ -8,11 +8,11 @@ import { SERVICE_ACCOUNT_SUBBLOCKS } from '@/blocks/utils' export const GoogleVaultBlock: BlockConfig = { type: 'google_vault', name: 'Google Vault', - description: 'Search, export, and manage holds/exports for Vault matters', + description: 'Search, export, and manage matters, holds, exports, and saved queries in Vault', authMode: AuthMode.OAuth, longDescription: - 'Connect Google Vault to create exports, list exports, and manage holds within matters.', - docsLink: 'https://developers.google.com/vault', + 'Connect Google Vault to manage the full matter lifecycle, create and manage holds and exports, and save reusable search queries for eDiscovery and compliance.', + docsLink: 'https://docs.sim.ai/integrations/google_vault', category: 'tools', integrationType: IntegrationType.Security, bgColor: '#E8F0FE', @@ -25,11 +25,26 @@ export const GoogleVaultBlock: BlockConfig = { options: [ { label: 'Create Export', id: 'create_matters_export' }, { label: 'List Exports', id: 'list_matters_export' }, + { label: 'Delete Export', id: 'delete_matters_export' }, { label: 'Download Export File', id: 'download_export_file' }, { label: 'Create Hold', id: 'create_matters_holds' }, { label: 'List Holds', id: 'list_matters_holds' }, + { label: 'Update Hold', id: 'update_matters_holds' }, + { label: 'Delete Hold', id: 'delete_matters_holds' }, + { label: 'Add Held Accounts', id: 'add_held_accounts' }, + { label: 'Remove Held Accounts', id: 'remove_held_accounts' }, { label: 'Create Matter', id: 'create_matters' }, { label: 'List Matters', id: 'list_matters' }, + { label: 'Update Matter', id: 'update_matters' }, + { label: 'Close Matter', id: 'close_matters' }, + { label: 'Reopen Matter', id: 'reopen_matters' }, + { label: 'Delete Matter', id: 'delete_matters' }, + { label: 'Undelete Matter', id: 'undelete_matters' }, + { label: 'Add Matter Collaborator', id: 'add_matters_permissions' }, + { label: 'Remove Matter Collaborator', id: 'remove_matters_permissions' }, + { label: 'Create Saved Query', id: 'create_saved_query' }, + { label: 'List Saved Queries', id: 'list_saved_queries' }, + { label: 'Delete Saved Query', id: 'delete_saved_query' }, ], value: () => 'list_matters_export', }, @@ -55,7 +70,6 @@ export const GoogleVaultBlock: BlockConfig = { required: true, }, ...SERVICE_ACCOUNT_SUBBLOCKS, - // Create Hold inputs { id: 'matterId', title: 'Matter ID', @@ -66,12 +80,62 @@ export const GoogleVaultBlock: BlockConfig = { value: [ 'create_matters_export', 'list_matters_export', + 'delete_matters_export', 'download_export_file', 'create_matters_holds', 'list_matters_holds', + 'update_matters_holds', + 'delete_matters_holds', + 'add_held_accounts', + 'remove_held_accounts', + 'update_matters', + 'close_matters', + 'reopen_matters', + 'delete_matters', + 'undelete_matters', + 'add_matters_permissions', + 'remove_matters_permissions', + 'create_saved_query', + 'list_saved_queries', + 'delete_saved_query', + ], + }), + required: () => ({ + field: 'operation', + value: [ + 'create_matters_export', + 'list_matters_export', + 'delete_matters_export', + 'download_export_file', + 'create_matters_holds', + 'list_matters_holds', + 'update_matters_holds', + 'delete_matters_holds', + 'add_held_accounts', + 'remove_held_accounts', + 'update_matters', + 'close_matters', + 'reopen_matters', + 'delete_matters', + 'undelete_matters', + 'add_matters_permissions', + 'remove_matters_permissions', + 'create_saved_query', + 'list_saved_queries', + 'delete_saved_query', ], }), }, + // Dedicated optional matter-id filter for list_matters — kept separate from the + // required matterId above so a value left over from another operation can never + // silently turn "List Matters" into a single-matter get. + { + id: 'listMatterId', + title: 'Matter ID', + type: 'short-input', + placeholder: 'Enter Matter ID (optional to fetch a specific matter)', + condition: { field: 'operation', value: 'list_matters' }, + }, // Download Export File inputs { id: 'bucketName', @@ -125,7 +189,7 @@ Return ONLY the export name - no explanations, no quotes, no extra text.`, title: 'Hold Name', type: 'short-input', placeholder: 'Name of the hold', - condition: { field: 'operation', value: 'create_matters_holds' }, + condition: { field: 'operation', value: ['create_matters_holds', 'update_matters_holds'] }, required: true, wandConfig: { enabled: true, @@ -155,7 +219,15 @@ Return ONLY the hold name - no explanations, no quotes, no extra text.`, { id: 'HANGOUTS_CHAT', label: 'HANGOUTS_CHAT' }, { id: 'VOICE', label: 'VOICE' }, ], - condition: { field: 'operation', value: ['create_matters_holds', 'create_matters_export'] }, + condition: { + field: 'operation', + value: [ + 'create_matters_holds', + 'update_matters_holds', + 'create_matters_export', + 'create_saved_query', + ], + }, required: true, }, { @@ -163,14 +235,53 @@ Return ONLY the hold name - no explanations, no quotes, no extra text.`, title: 'Account Emails', type: 'long-input', placeholder: 'Comma-separated emails (alternative to Org Unit)', - condition: { field: 'operation', value: ['create_matters_holds', 'create_matters_export'] }, + condition: { + field: 'operation', + value: ['create_matters_holds', 'create_matters_export'], + }, }, { id: 'orgUnitId', title: 'Org Unit ID', type: 'short-input', placeholder: 'Org Unit ID (alternative to emails)', - condition: { field: 'operation', value: ['create_matters_holds', 'create_matters_export'] }, + condition: { + field: 'operation', + value: ['create_matters_holds', 'create_matters_export'], + }, + }, + // Dedicated scope fields for update_matters_holds and create_saved_query — kept + // separate from the create_matters_holds/create_matters_export accountEmails/orgUnitId + // above so a stale value left over from a different operation can never silently win + // in the accountEmails-before-orgUnitId scope priority (each field is only ever + // populated by the user while its own operation is selected). + { + id: 'updateHoldAccountEmails', + title: 'Account Emails', + type: 'long-input', + placeholder: 'Comma-separated emails (alternative to Org Unit)', + condition: { field: 'operation', value: 'update_matters_holds' }, + }, + { + id: 'updateHoldOrgUnitId', + title: 'Org Unit ID', + type: 'short-input', + placeholder: 'Org Unit ID (alternative to emails)', + condition: { field: 'operation', value: 'update_matters_holds' }, + }, + { + id: 'savedQueryAccountEmails', + title: 'Account Emails', + type: 'long-input', + placeholder: 'Comma-separated emails (alternative to Org Unit)', + condition: { field: 'operation', value: 'create_saved_query' }, + }, + { + id: 'savedQueryOrgUnitId', + title: 'Org Unit ID', + type: 'short-input', + placeholder: 'Org Unit ID (alternative to emails)', + condition: { field: 'operation', value: 'create_saved_query' }, }, // Date filtering for exports (works with all corpus types) { @@ -178,7 +289,7 @@ Return ONLY the hold name - no explanations, no quotes, no extra text.`, title: 'Start Time', type: 'short-input', placeholder: 'YYYY-MM-DDTHH:mm:ssZ', - condition: { field: 'operation', value: 'create_matters_export' }, + condition: { field: 'operation', value: ['create_matters_export', 'create_saved_query'] }, wandConfig: { enabled: true, prompt: `Generate an ISO 8601 timestamp in GMT based on the user's description for Google Vault date filtering. @@ -200,7 +311,7 @@ Return ONLY the timestamp string - no explanations, no quotes, no extra text.`, title: 'End Time', type: 'short-input', placeholder: 'YYYY-MM-DDTHH:mm:ssZ', - condition: { field: 'operation', value: 'create_matters_export' }, + condition: { field: 'operation', value: ['create_matters_export', 'create_saved_query'] }, wandConfig: { enabled: true, prompt: `Generate an ISO 8601 timestamp in GMT based on the user's description for Google Vault date filtering. @@ -225,7 +336,7 @@ Return ONLY the timestamp string - no explanations, no quotes, no extra text.`, placeholder: 'YYYY-MM-DDTHH:mm:ssZ', condition: { field: 'operation', - value: 'create_matters_holds', + value: ['create_matters_holds', 'update_matters_holds'], and: { field: 'corpus', value: ['MAIL', 'GROUPS'] }, }, wandConfig: { @@ -251,7 +362,7 @@ Return ONLY the timestamp string - no explanations, no quotes, no extra text.`, placeholder: 'YYYY-MM-DDTHH:mm:ssZ', condition: { field: 'operation', - value: 'create_matters_holds', + value: ['create_matters_holds', 'update_matters_holds'], and: { field: 'corpus', value: ['MAIL', 'GROUPS'] }, }, wandConfig: { @@ -276,7 +387,7 @@ Return ONLY the timestamp string - no explanations, no quotes, no extra text.`, title: 'Search Terms', type: 'long-input', placeholder: 'Enter search query (e.g., from:user@example.com subject:confidential)', - condition: { field: 'operation', value: 'create_matters_export' }, + condition: { field: 'operation', value: ['create_matters_export', 'create_saved_query'] }, wandConfig: { enabled: true, prompt: `Generate a Google Vault search query based on the user's description. @@ -305,7 +416,7 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, placeholder: 'Enter search query (e.g., from:user@example.com subject:confidential)', condition: { field: 'operation', - value: 'create_matters_holds', + value: ['create_matters_holds', 'update_matters_holds'], and: { field: 'corpus', value: ['MAIL', 'GROUPS'] }, }, wandConfig: { @@ -329,7 +440,7 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, type: 'switch', condition: { field: 'operation', - value: 'create_matters_holds', + value: ['create_matters_holds', 'update_matters_holds'], and: { field: 'corpus', value: 'DRIVE' }, }, }, @@ -337,6 +448,17 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, id: 'exportId', title: 'Export ID', type: 'short-input', + placeholder: 'Enter Export ID', + condition: { field: 'operation', value: 'delete_matters_export' }, + required: true, + }, + // Dedicated optional export-id filter for list_matters_export — kept separate from + // the required exportId above so a value left over from Delete Export can never + // silently turn "List Exports" into a single-export get. + { + id: 'listExportId', + title: 'Export ID', + type: 'short-input', placeholder: 'Enter Export ID (optional to fetch a specific export)', condition: { field: 'operation', value: 'list_matters_export' }, }, @@ -344,6 +466,25 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, id: 'holdId', title: 'Hold ID', type: 'short-input', + placeholder: 'Enter Hold ID', + condition: { + field: 'operation', + value: [ + 'update_matters_holds', + 'delete_matters_holds', + 'add_held_accounts', + 'remove_held_accounts', + ], + }, + required: true, + }, + // Dedicated optional hold-id filter for list_matters_holds — kept separate from the + // required-everywhere holdId above so a value left over from another operation can + // never silently turn "List Holds" into a single-hold get. + { + id: 'listHoldId', + title: 'Hold ID', + type: 'short-input', placeholder: 'Enter Hold ID (optional to fetch a specific hold)', condition: { field: 'operation', value: 'list_matters_holds' }, }, @@ -354,7 +495,7 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, placeholder: 'Number of items to return', condition: { field: 'operation', - value: ['list_matters_export', 'list_matters_holds', 'list_matters'], + value: ['list_matters_export', 'list_matters_holds', 'list_matters', 'list_saved_queries'], }, }, { @@ -364,7 +505,7 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, placeholder: 'Pagination token', condition: { field: 'operation', - value: ['list_matters_export', 'list_matters_holds', 'list_matters'], + value: ['list_matters_export', 'list_matters_holds', 'list_matters', 'list_saved_queries'], }, }, @@ -373,7 +514,7 @@ Return ONLY the search query - no explanations, no quotes, no extra text.`, title: 'Matter Name', type: 'short-input', placeholder: 'Enter Matter name', - condition: { field: 'operation', value: 'create_matters' }, + condition: { field: 'operation', value: ['create_matters', 'update_matters'] }, required: true, wandConfig: { enabled: true, @@ -397,7 +538,7 @@ Return ONLY the matter name - no explanations, no quotes, no extra text.`, title: 'Description', type: 'short-input', placeholder: 'Optional description for the matter', - condition: { field: 'operation', value: 'create_matters' }, + condition: { field: 'operation', value: ['create_matters', 'update_matters'] }, wandConfig: { enabled: true, prompt: `Generate a professional description for a Google Vault matter based on the user's request. @@ -410,24 +551,113 @@ Return ONLY the description text - no explanations, no quotes, no extra text.`, placeholder: 'Describe the purpose of this matter...', }, }, - // Optional get specific matter by ID + // Held account management { - id: 'matterId', - title: 'Matter ID', + id: 'heldAccountEmails', + title: 'Account Emails', + type: 'long-input', + placeholder: 'Comma-separated emails (e.g., user1@example.com, user2@example.com)', + condition: { field: 'operation', value: 'add_held_accounts' }, + required: true, + }, + { + id: 'heldAccountIds', + title: 'Account IDs', + type: 'long-input', + placeholder: 'Comma-separated Admin SDK account IDs', + condition: { field: 'operation', value: 'remove_held_accounts' }, + required: true, + }, + // Matter collaborator management + { + id: 'accountId', + title: 'Account ID', type: 'short-input', - placeholder: 'Enter Matter ID (optional to fetch a specific matter)', - condition: { field: 'operation', value: 'list_matters' }, + placeholder: 'Admin SDK account ID', + condition: { + field: 'operation', + value: ['add_matters_permissions', 'remove_matters_permissions'], + }, + required: true, + }, + { + id: 'role', + title: 'Role', + type: 'dropdown', + options: [ + { id: 'COLLABORATOR', label: 'Collaborator' }, + { id: 'OWNER', label: 'Owner' }, + ], + condition: { field: 'operation', value: 'add_matters_permissions' }, + required: true, + value: () => 'COLLABORATOR', + }, + { + id: 'sendEmails', + title: 'Send Notification Email', + type: 'switch', + condition: { field: 'operation', value: 'add_matters_permissions' }, + mode: 'advanced', + }, + { + id: 'ccMe', + title: 'CC Me', + type: 'switch', + condition: { field: 'operation', value: 'add_matters_permissions' }, + mode: 'advanced', + }, + // Saved query management + { + id: 'displayName', + title: 'Saved Query Name', + type: 'short-input', + placeholder: 'Name for the saved query', + condition: { field: 'operation', value: 'create_saved_query' }, + required: true, + }, + { + id: 'savedQueryId', + title: 'Saved Query ID', + type: 'short-input', + placeholder: 'Enter Saved Query ID', + condition: { field: 'operation', value: 'delete_saved_query' }, + required: true, + }, + // Dedicated optional saved-query-id filter for list_saved_queries — kept separate + // from the required savedQueryId above so a value left over from Delete Saved Query + // can never silently turn "List Saved Queries" into a single-query get. + { + id: 'listSavedQueryId', + title: 'Saved Query ID', + type: 'short-input', + placeholder: 'Enter Saved Query ID (optional to fetch a specific saved query)', + condition: { field: 'operation', value: 'list_saved_queries' }, }, ], tools: { access: [ 'google_vault_create_matters_export', 'google_vault_list_matters_export', + 'google_vault_delete_matters_export', 'google_vault_download_export_file', 'google_vault_create_matters_holds', 'google_vault_list_matters_holds', + 'google_vault_update_matters_holds', + 'google_vault_delete_matters_holds', + 'google_vault_add_held_accounts', + 'google_vault_remove_held_accounts', 'google_vault_create_matters', 'google_vault_list_matters', + 'google_vault_update_matters', + 'google_vault_close_matters', + 'google_vault_reopen_matters', + 'google_vault_delete_matters', + 'google_vault_undelete_matters', + 'google_vault_add_matters_permissions', + 'google_vault_remove_matters_permissions', + 'google_vault_create_saved_query', + 'google_vault_list_saved_queries', + 'google_vault_delete_saved_query', ], config: { tool: (params) => { @@ -436,22 +666,68 @@ Return ONLY the description text - no explanations, no quotes, no extra text.`, return 'google_vault_create_matters_export' case 'list_matters_export': return 'google_vault_list_matters_export' + case 'delete_matters_export': + return 'google_vault_delete_matters_export' case 'download_export_file': return 'google_vault_download_export_file' case 'create_matters_holds': return 'google_vault_create_matters_holds' case 'list_matters_holds': return 'google_vault_list_matters_holds' + case 'update_matters_holds': + return 'google_vault_update_matters_holds' + case 'delete_matters_holds': + return 'google_vault_delete_matters_holds' + case 'add_held_accounts': + return 'google_vault_add_held_accounts' + case 'remove_held_accounts': + return 'google_vault_remove_held_accounts' case 'create_matters': return 'google_vault_create_matters' case 'list_matters': return 'google_vault_list_matters' + case 'update_matters': + return 'google_vault_update_matters' + case 'close_matters': + return 'google_vault_close_matters' + case 'reopen_matters': + return 'google_vault_reopen_matters' + case 'delete_matters': + return 'google_vault_delete_matters' + case 'undelete_matters': + return 'google_vault_undelete_matters' + case 'add_matters_permissions': + return 'google_vault_add_matters_permissions' + case 'remove_matters_permissions': + return 'google_vault_remove_matters_permissions' + case 'create_saved_query': + return 'google_vault_create_saved_query' + case 'list_saved_queries': + return 'google_vault_list_saved_queries' + case 'delete_saved_query': + return 'google_vault_delete_saved_query' default: throw new Error(`Invalid Google Vault operation: ${params.operation}`) } }, params: (params) => { - const { oauthCredential, holdStartTime, holdEndTime, holdTerms, ...rest } = params + const { + oauthCredential, + holdStartTime, + holdEndTime, + holdTerms, + heldAccountEmails, + heldAccountIds, + listMatterId, + updateHoldAccountEmails, + updateHoldOrgUnitId, + savedQueryAccountEmails, + savedQueryOrgUnitId, + listExportId, + listHoldId, + listSavedQueryId, + ...rest + } = params return { ...rest, oauthCredential, @@ -459,6 +735,22 @@ Return ONLY the description text - no explanations, no quotes, no extra text.`, ...(holdStartTime && { startTime: holdStartTime }), ...(holdEndTime && { endTime: holdEndTime }), ...(holdTerms && { terms: holdTerms }), + ...(heldAccountEmails && { accountEmails: heldAccountEmails }), + ...(heldAccountIds && { accountIds: heldAccountIds }), + // Map operation-scoped fields (kept separate in the UI so a stale value from + // another operation can never silently override these) to their tool parameter names + ...(listMatterId && { matterId: listMatterId }), + // These operation-scoped accountEmails/orgUnitId fields are mutually exclusive — + // each is only ever populated while its own single 'operation' value is selected, + // so at most one of the four spreads below is ever truthy at once. Ordered here + // defensively anyway so precedence stays correct even if that invariant changes. + ...(savedQueryAccountEmails && { accountEmails: savedQueryAccountEmails }), + ...(savedQueryOrgUnitId && { orgUnitId: savedQueryOrgUnitId }), + ...(updateHoldAccountEmails && { accountEmails: updateHoldAccountEmails }), + ...(updateHoldOrgUnitId && { orgUnitId: updateHoldOrgUnitId }), + ...(listExportId && { exportId: listExportId }), + ...(listHoldId && { holdId: listHoldId }), + ...(listSavedQueryId && { savedQueryId: listSavedQueryId }), } }, }, @@ -508,9 +800,56 @@ Return ONLY the description text - no explanations, no quotes, no extra text.`, pageSize: { type: 'number', description: 'Number of items per page' }, pageToken: { type: 'string', description: 'Pagination token' }, - // Create matter inputs + // Create/update matter inputs name: { type: 'string', description: 'Matter name' }, description: { type: 'string', description: 'Matter description' }, + + // Hold account management inputs + heldAccountEmails: { type: 'string', description: 'Comma-separated emails to add to a hold' }, + heldAccountIds: { + type: 'string', + description: 'Comma-separated account IDs to remove from a hold', + }, + + // Matter collaborator inputs + accountId: { type: 'string', description: 'Admin SDK account ID for collaborator management' }, + role: { type: 'string', description: 'Matter permission role (COLLABORATOR or OWNER)' }, + sendEmails: { type: 'boolean', description: 'Send a notification email to the added account' }, + ccMe: { type: 'boolean', description: 'CC the requestor on the notification email' }, + + // Saved query inputs + displayName: { type: 'string', description: 'Name for the saved query' }, + savedQueryId: { type: 'string', description: 'Specific saved query ID to fetch or delete' }, + + // Operation-scoped fields kept separate from their shared counterparts above so a + // stale value from another operation can never silently carry over + listMatterId: { type: 'string', description: 'Specific matter ID to fetch (list_matters)' }, + updateHoldAccountEmails: { + type: 'string', + description: 'Comma-separated emails covered by the hold (update_matters_holds)', + }, + updateHoldOrgUnitId: { + type: 'string', + description: 'Org unit ID covered by the hold (update_matters_holds, alternative to emails)', + }, + savedQueryAccountEmails: { + type: 'string', + description: 'Comma-separated emails to scope the saved query (create_saved_query)', + }, + savedQueryOrgUnitId: { + type: 'string', + description: + 'Org unit ID to scope the saved query (create_saved_query, alternative to emails)', + }, + listExportId: { + type: 'string', + description: 'Specific export ID to fetch (list_matters_export)', + }, + listHoldId: { type: 'string', description: 'Specific hold ID to fetch (list_matters_holds)' }, + listSavedQueryId: { + type: 'string', + description: 'Specific saved query ID to fetch (list_saved_queries)', + }, }, outputs: { matters: { @@ -544,6 +883,32 @@ Return ONLY the description text - no explanations, no quotes, no extra text.`, type: 'string', description: 'Token for fetching next page of results (for list operations)', }, + success: { + type: 'boolean', + description: 'Whether the delete/remove operation succeeded', + }, + responses: { + type: 'json', + description: + '[{account: {accountId, email}, status: {code, message}}] (for add_held_accounts)', + }, + statuses: { + type: 'json', + description: '[{code, message}] per-account removal status (for remove_held_accounts)', + }, + permission: { + type: 'json', + description: 'Matter permission (accountId, role) (for add_matters_permissions)', + }, + savedQuery: { + type: 'json', + description: + 'Single saved query object (for create_saved_query or list_saved_queries with savedQueryId)', + }, + savedQueries: { + type: 'json', + description: 'Array of saved query objects (for list_saved_queries without savedQueryId)', + }, }, } @@ -639,5 +1004,19 @@ export const GoogleVaultBlockMeta = { content: '# Audit Active Holds\n\nGenerate a status report of which matters and custodians are currently preserved.\n\n## Steps\n1. List all matters and capture their IDs, names, and states.\n2. For each open matter, list its holds and the custodians and services covered.\n3. Flag matters with no holds and custodians that appear across multiple matters.\n\n## Output\nReturn a per-matter summary listing holds, services, and custodians, plus a flagged section for matters missing holds. Suitable for a monthly legal review.', }, + { + name: 'close-out-matter', + description: + 'Wind down a resolved matter by closing it, and permanently delete it once retention requirements are satisfied.', + content: + '# Close Out Matter\n\nRetire a matter once the underlying investigation or litigation is resolved.\n\n## Steps\n1. List the holds on the matter and confirm none still need to be preserved; delete any holds that are no longer required.\n2. Close the matter.\n3. If the matter should be permanently removed and your retention policy allows it, delete the closed matter (reopen or undelete if this was done in error).\n\n## Output\nReturn the matterId, its final state, and which holds (if any) were deleted before close-out.', + }, + { + name: 'manage-hold-scope', + description: + 'Add or remove custodians from an existing legal hold as the custodian list for a matter changes.', + content: + '# Manage Hold Scope\n\nKeep an existing hold in sync with the current custodian list without recreating it.\n\n## Steps\n1. List the holds on the matter and identify the target hold.\n2. Add newly relevant custodians to the hold by email.\n3. Remove custodians who have left the investigation scope by account ID.\n4. Fetch the hold again by its ID to confirm the accounts field reflects the change.\n\n## Output\nReturn the holdId and the accounts added and removed, noting any that failed with their error status.', + }, ], } as const satisfies BlockMeta diff --git a/apps/sim/lib/integrations/integrations.json b/apps/sim/lib/integrations/integrations.json index 4357b52a503..9d543582283 100644 --- a/apps/sim/lib/integrations/integrations.json +++ b/apps/sim/lib/integrations/integrations.json @@ -1,5 +1,5 @@ { - "updatedAt": "2026-07-06", + "updatedAt": "2026-07-07", "integrations": [ { "type": "onepassword", @@ -1260,6 +1260,10 @@ "name": "List Query Executions", "description": "List recent Athena query execution IDs" }, + { + "name": "Batch Get Query Executions", + "description": "Get the status and details of up to 50 Athena query executions in one call" + }, { "name": "Create Named Query", "description": "Create a saved/named query in AWS Athena" @@ -1271,9 +1275,21 @@ { "name": "List Named Queries", "description": "List saved/named query IDs in AWS Athena" + }, + { + "name": "Delete Named Query", + "description": "Delete a saved/named query in AWS Athena" + }, + { + "name": "List Databases", + "description": "List the databases available in an Athena data catalog" + }, + { + "name": "List Table Metadata", + "description": "List tables and their column/partition metadata for an Athena database" } ], - "operationCount": 8, + "operationCount": 12, "triggers": [], "triggerCount": 0, "authType": "none", @@ -1454,9 +1470,25 @@ { "name": "Delete Webhook", "description": "Delete a webhook from Attio" + }, + { + "name": "List Attributes", + "description": "List the attributes (schema fields) defined on an Attio object or list" + }, + { + "name": "Get Attribute", + "description": "Get a single attribute (schema field) on an Attio object or list" + }, + { + "name": "Create Attribute", + "description": "Create a new attribute (schema field) on an Attio object or list" + }, + { + "name": "Update Attribute", + "description": "Update an attribute (schema field) on an Attio object or list" } ], - "operationCount": 41, + "operationCount": 45, "triggers": [ { "id": "attio_record_created", @@ -2071,8 +2103,21 @@ "bgColor": "linear-gradient(135deg, #055F4E 0%, #56C0A7 100%)", "iconName": "TextractIcon", "docsUrl": "https://docs.sim.ai/integrations/textract", - "operations": [], - "operationCount": 0, + "operations": [ + { + "name": "Analyze Document (Text, Tables, Forms)", + "description": "" + }, + { + "name": "Analyze Expense (Invoices & Receipts)", + "description": "Extract structured invoice and receipt fields using AWS Textract AnalyzeExpense" + }, + { + "name": "Analyze Identity Document", + "description": "Extract identity document fields using AWS Textract AnalyzeID" + } + ], + "operationCount": 3, "triggers": [], "triggerCount": 0, "authType": "api-key", @@ -2509,7 +2554,7 @@ }, { "name": "Discover", - "description": "AI-powered web discovery that finds and ranks results by intent. Returns up to 1,000 results with optional cleaned page content for RAG and verification." + "description": "AI-powered web discovery that finds and ranks results by intent. Returns up to 20 results with optional cleaned page content for RAG and verification." }, { "name": "Sync Scrape", @@ -3211,7 +3256,7 @@ "slug": "cloudformation", "name": "CloudFormation", "description": "Manage and inspect AWS CloudFormation stacks, resources, and drift", - "longDescription": "Integrate AWS CloudFormation into workflows. Describe stacks, list resources, detect drift, view stack events, retrieve templates, and validate templates. Requires AWS access key and secret access key.", + "longDescription": "Integrate AWS CloudFormation into workflows. Create, update, and delete stacks, preview changes with change sets, describe stacks, list resources, detect drift, view stack events, and retrieve or validate templates. Requires AWS access key and secret access key.", "bgColor": "linear-gradient(45deg, #B0084D 0%, #FF4F8B 100%)", "iconName": "CloudFormationIcon", "docsUrl": "https://docs.sim.ai/integrations/cloudformation", @@ -3220,6 +3265,34 @@ "name": "Describe Stacks", "description": "List and describe CloudFormation stacks" }, + { + "name": "Create Stack", + "description": "Create a new CloudFormation stack from a template" + }, + { + "name": "Update Stack", + "description": "Update an existing CloudFormation stack with a new or previous template" + }, + { + "name": "Delete Stack", + "description": "Delete a CloudFormation stack and its resources" + }, + { + "name": "Cancel Update Stack", + "description": "Cancel an in-progress stack update and roll back to the last known stable state" + }, + { + "name": "Create Change Set", + "description": "Preview the changes a stack create or update would make before applying them" + }, + { + "name": "Describe Change Set", + "description": "View the resource changes a change set would make and its execution status" + }, + { + "name": "Execute Change Set", + "description": "Apply a previously created and reviewed change set to its stack" + }, { "name": "List Stack Resources", "description": "List all resources in a CloudFormation stack" @@ -3240,12 +3313,16 @@ "name": "Get Template", "description": "Retrieve the template body for a CloudFormation stack" }, + { + "name": "Get Template Summary", + "description": "Get a summary of a template or deployed stack: resource types, required capabilities, and parameters, without full validation" + }, { "name": "Validate Template", "description": "Validate a CloudFormation template for syntax and structural correctness" } ], - "operationCount": 7, + "operationCount": 15, "triggers": [], "triggerCount": 0, "authType": "none", @@ -3267,6 +3344,10 @@ "name": "Query Logs (Insights)", "description": "Run a CloudWatch Log Insights query against one or more log groups" }, + { + "name": "Filter Log Events", + "description": "Search log events across all streams in a log group by filter pattern and time range, without writing a Log Insights query" + }, { "name": "Describe Log Groups", "description": "List available CloudWatch log groups" @@ -3279,6 +3360,10 @@ "name": "Describe Log Streams", "description": "List log streams within a CloudWatch log group" }, + { + "name": "Set Log Group Retention", + "description": "Set (or clear, for never-expire) the retention period for a CloudWatch log group" + }, { "name": "List Metrics", "description": "List available CloudWatch metrics" @@ -3295,6 +3380,10 @@ "name": "Describe Alarms", "description": "List and filter CloudWatch alarms" }, + { + "name": "Describe Alarm History", + "description": "Retrieve state-change and configuration history for CloudWatch alarms" + }, { "name": "Mute Alarm", "description": "Create a CloudWatch alarm mute rule that suppresses alarms for a fixed duration" @@ -3304,7 +3393,7 @@ "description": "Delete a CloudWatch alarm mute rule, restoring alarm notifications" } ], - "operationCount": 10, + "operationCount": 13, "triggers": [], "triggerCount": 0, "authType": "none", @@ -3330,6 +3419,10 @@ "name": "Get Pipeline State", "description": "Get the current state of a CodePipeline pipeline, including stage and action status and pending approval tokens" }, + { + "name": "Get Pipeline Structure", + "description": "Get the structure of a CodePipeline pipeline, including its stages, actions, and variables" + }, { "name": "List Pipelines", "description": "List all CodePipeline pipelines in an AWS account and region" @@ -3338,6 +3431,10 @@ "name": "List Executions", "description": "List recent executions of a CodePipeline pipeline with status and source revisions" }, + { + "name": "List Action Executions", + "description": "List action-level execution history for a CodePipeline pipeline, including per-action status, timing, and error details" + }, { "name": "Get Execution", "description": "Get details of a CodePipeline execution, including status, trigger, source revisions, and resolved variables" @@ -3353,9 +3450,17 @@ { "name": "Approve / Reject Approval", "description": "Approve or reject a pending CodePipeline manual approval action. The approval token is available from Get Pipeline State on the pending approval action" + }, + { + "name": "Disable Stage Transition", + "description": "Prevent artifacts from transitioning into or out of a CodePipeline stage, freezing the pipeline at that point" + }, + { + "name": "Enable Stage Transition", + "description": "Re-enable artifacts transitioning into or out of a CodePipeline stage after it was disabled" } ], - "operationCount": 8, + "operationCount": 12, "triggers": [], "triggerCount": 0, "authType": "api-key", @@ -4367,6 +4472,10 @@ "name": "Delete Message", "description": "Delete a message from a Discord channel" }, + { + "name": "Bulk Delete Messages", + "description": "Delete 2-100 messages from a Discord channel in a single request" + }, { "name": "Add Reaction", "description": "Add a reaction emoji to a Discord message" @@ -4383,6 +4492,10 @@ "name": "Unpin Message", "description": "Unpin a message in a Discord channel" }, + { + "name": "Get Pinned Messages", + "description": "Retrieve all pinned messages in a Discord channel" + }, { "name": "Create Thread", "description": "Create a thread in a Discord channel" @@ -4415,6 +4528,10 @@ "name": "Get Channel", "description": "Get information about a Discord channel" }, + { + "name": "List Channels", + "description": "List all channels in a Discord server" + }, { "name": "Create Role", "description": "Create a new role in a Discord server" @@ -4435,6 +4552,10 @@ "name": "Remove Role", "description": "Remove a role from a member in a Discord server" }, + { + "name": "List Roles", + "description": "List all roles in a Discord server" + }, { "name": "Kick Member", "description": "Kick a member from a Discord server" @@ -4484,7 +4605,7 @@ "description": "Delete a Discord webhook" } ], - "operationCount": 35, + "operationCount": 39, "triggers": [], "triggerCount": 0, "authType": "api-key", @@ -4669,12 +4790,24 @@ "name": "Create Shared Link", "description": "Create a shareable link for a file or folder in Dropbox" }, + { + "name": "List Shared Links", + "description": "List shared links for a path, or for the entire account if no path is given" + }, { "name": "Search Files", "description": "Search for files and folders in Dropbox" + }, + { + "name": "List Revisions", + "description": "List the revision history for a file in Dropbox (files only, not folders)" + }, + { + "name": "Restore File", + "description": "Restore a specific revision of a file to the given path" } ], - "operationCount": 10, + "operationCount": 13, "triggers": [], "triggerCount": 0, "authType": "oauth", @@ -4798,9 +4931,25 @@ { "name": "Get QR Code", "description": "Generate a customizable QR code (PNG) for a short link, with control over size, error correction, colors, and margin." + }, + { + "name": "List Domains", + "description": "Retrieve the custom domains registered in the workspace, so links can be created against the right domain." + }, + { + "name": "List Tags", + "description": "Retrieve the tags defined in the workspace, so the right tag IDs can be assigned to links." + }, + { + "name": "Create Tag", + "description": "Create a new tag in the workspace for organizing and filtering short links." + }, + { + "name": "List Folders", + "description": "Retrieve the folders defined in the workspace, so the right folder ID can be used to organize links." } ], - "operationCount": 13, + "operationCount": 17, "triggers": [], "triggerCount": 0, "authType": "api-key", @@ -5705,6 +5854,10 @@ "name": "Request PR reviewers", "description": "Request reviewers for a pull request" }, + { + "name": "Create PR review", + "description": "Submit a review for a pull request. Use APPROVE, REQUEST_CHANGES, or COMMENT. A body is required for REQUEST_CHANGES and COMMENT reviews." + }, { "name": "Get file content", "description": "Get the content of a file from a GitHub repository. Supports files up to 1MB. Content is returned decoded and human-readable." @@ -5725,6 +5878,14 @@ "name": "Get directory tree", "description": "Get the contents of a directory in a GitHub repository. Returns a list of files and subdirectories. Use empty path or omit to get root directory contents." }, + { + "name": "Get README", + "description": "Get the preferred README for a GitHub repository, with its content decoded to plain text." + }, + { + "name": "List tags", + "description": "List tags for a GitHub repository. Returns tag names with their commit SHA and download URLs." + }, { "name": "List branches", "description": "List all branches in a GitHub repository. Optionally filter by protected status and control pagination." @@ -5797,6 +5958,10 @@ "name": "Get release", "description": "Get detailed information about a specific GitHub release by ID. Returns release metadata including assets and download URLs." }, + { + "name": "Get latest release", + "description": "Get the latest published, non-draft, non-prerelease release for a GitHub repository. Returns release metadata including assets and download URLs." + }, { "name": "Delete release", "description": "Delete a GitHub release by ID. This permanently removes the release but does not delete the associated Git tag." @@ -5974,7 +6139,7 @@ "description": "List users who have starred a repository" } ], - "operationCount": 83, + "operationCount": 87, "triggers": [ { "id": "github_issue_opened", @@ -6152,6 +6317,14 @@ "name": "Create Branch", "description": "Create a new branch in a GitLab project repository" }, + { + "name": "Delete Branch", + "description": "Delete a branch from a GitLab project repository" + }, + { + "name": "Compare Branches", + "description": "Compare two branches, tags, or commits in a GitLab project repository" + }, { "name": "Get MR Changes", "description": "Get the file changes (diffs) of a GitLab merge request" @@ -6171,9 +6344,17 @@ { "name": "Play Job", "description": "Trigger (play) a manual GitLab job" + }, + { + "name": "List Releases", + "description": "List releases in a GitLab project" + }, + { + "name": "Create Release", + "description": "Create a new release in a GitLab project" } ], - "operationCount": 31, + "operationCount": 35, "triggers": [ { "id": "gitlab_push", @@ -6513,10 +6694,22 @@ "name": "Run Query", "description": "Run a SQL query against Google BigQuery and return the results" }, + { + "name": "Get Query Results", + "description": "Fetch results for a previously submitted BigQuery job, or the next page of a Run Query result" + }, { "name": "List Datasets", "description": "List all datasets in a Google BigQuery project" }, + { + "name": "Create Dataset", + "description": "Create a new dataset in a Google BigQuery project" + }, + { + "name": "Delete Dataset", + "description": "Delete a dataset from a Google BigQuery project" + }, { "name": "List Tables", "description": "List all tables in a Google BigQuery dataset" @@ -6525,12 +6718,24 @@ "name": "Get Table", "description": "Get metadata and schema for a Google BigQuery table" }, + { + "name": "Create Table", + "description": "Create a new table in a Google BigQuery dataset" + }, + { + "name": "Delete Table", + "description": "Delete a table from a Google BigQuery dataset" + }, + { + "name": "List Table Data", + "description": "Preview rows from a Google BigQuery table without running a query. Pair with Get Table to know the column order." + }, { "name": "Insert Rows", "description": "Insert rows into a Google BigQuery table using streaming insert" } ], - "operationCount": 5, + "operationCount": 11, "triggers": [], "triggerCount": 0, "authType": "oauth", @@ -6624,10 +6829,22 @@ "name": "Create Calendar", "description": "Create a new secondary calendar" }, + { + "name": "Update Calendar", + "description": "Update a secondary calendar's metadata (title, description, location, time zone)" + }, + { + "name": "Delete Calendar", + "description": "Permanently delete a secondary calendar (not the primary calendar)" + }, { "name": "Share Calendar", "description": "Grant a user, group, or domain access to a calendar by creating an ACL rule" }, + { + "name": "Update Sharing", + "description": "Change the access role granted by an existing calendar sharing (ACL) rule" + }, { "name": "List Sharing", "description": "List the access control rules (sharing) for a calendar" @@ -6637,7 +6854,7 @@ "description": "Revoke an access control rule (sharing) from a calendar" } ], - "operationCount": 15, + "operationCount": 18, "triggers": [ { "id": "google_calendar_poller", @@ -7074,6 +7291,10 @@ "name": "Search Places", "description": "Search for places using a text query" }, + { + "name": "Nearby Places", + "description": "Search for places of a given type within a radius of a location" + }, { "name": "Place Details", "description": "Get detailed information about a specific place" @@ -7115,7 +7336,7 @@ "description": "Get solar potential and panel insights for the building nearest a location" } ], - "operationCount": 15, + "operationCount": 16, "triggers": [], "triggerCount": 0, "authType": "api-key", @@ -7588,11 +7809,11 @@ "type": "google_vault", "slug": "google-vault", "name": "Google Vault", - "description": "Search, export, and manage holds/exports for Vault matters", - "longDescription": "Connect Google Vault to create exports, list exports, and manage holds within matters.", + "description": "Search, export, and manage matters, holds, exports, and saved queries in Vault", + "longDescription": "Connect Google Vault to manage the full matter lifecycle, create and manage holds and exports, and save reusable search queries for eDiscovery and compliance.", "bgColor": "#E8F0FE", "iconName": "GoogleVaultIcon", - "docsUrl": "https://developers.google.com/vault", + "docsUrl": "https://docs.sim.ai/integrations/google_vault", "operations": [ { "name": "Create Export", @@ -7602,6 +7823,10 @@ "name": "List Exports", "description": "List exports for a matter" }, + { + "name": "Delete Export", + "description": "Delete an export from a matter" + }, { "name": "Download Export File", "description": "Download a single file from a Google Vault export (GCS object)" @@ -7614,6 +7839,22 @@ "name": "List Holds", "description": "List holds for a matter" }, + { + "name": "Update Hold", + "description": "Replace the name, query, and scope of an existing hold. This is a full-resource update: fetch the current hold first (Vault List Holds) and resupply every field you want to keep — any field left blank is cleared, not left unchanged." + }, + { + "name": "Delete Hold", + "description": "Delete a hold and release its covered accounts" + }, + { + "name": "Add Held Accounts", + "description": "Add accounts to an existing hold" + }, + { + "name": "Remove Held Accounts", + "description": "Remove accounts from an existing hold" + }, { "name": "Create Matter", "description": "Create a new matter in Google Vault" @@ -7621,9 +7862,49 @@ { "name": "List Matters", "description": "List matters, or get a specific matter if matterId is provided" + }, + { + "name": "Update Matter", + "description": "Update the name and/or description of a matter" + }, + { + "name": "Close Matter", + "description": "Close a matter" + }, + { + "name": "Reopen Matter", + "description": "Reopen a closed matter" + }, + { + "name": "Delete Matter", + "description": "Permanently delete a matter (must be closed first)" + }, + { + "name": "Undelete Matter", + "description": "Restore a deleted matter" + }, + { + "name": "Add Matter Collaborator", + "description": "Add a collaborator (or transfer ownership) to a matter" + }, + { + "name": "Remove Matter Collaborator", + "description": "Remove a collaborator from a matter" + }, + { + "name": "Create Saved Query", + "description": "Save a reusable search query in a matter" + }, + { + "name": "List Saved Queries", + "description": "List saved queries in a matter, or get a specific one if savedQueryId is provided" + }, + { + "name": "Delete Saved Query", + "description": "Delete a saved query from a matter" } ], - "operationCount": 7, + "operationCount": 22, "triggers": [], "triggerCount": 0, "authType": "oauth", @@ -8654,7 +8935,7 @@ "slug": "instantly", "name": "Instantly", "description": "Manage Instantly leads, campaigns, emails, and lead lists", - "longDescription": "Integrate Instantly API V2 into workflows. Create and list leads, manage lead interest status, delete leads in bulk, list and create campaigns, reply to emails, and manage lead lists.", + "longDescription": "Integrate Instantly API V2 into workflows. Create, update, and list leads, manage lead interest status, delete leads in bulk, list, create, patch, activate, pause, and delete campaigns, reply to emails, and manage lead lists.", "bgColor": "#FFFFFF", "iconName": "InstantlyIcon", "docsUrl": "https://docs.sim.ai/integrations/instantly", @@ -8671,6 +8952,10 @@ "name": "Create Lead", "description": "Creates an Instantly V2 lead in a campaign or lead list." }, + { + "name": "Patch Lead", + "description": "Updates fields on an existing Instantly V2 lead." + }, { "name": "Delete Leads", "description": "Deletes Instantly V2 leads in bulk from a campaign or lead list." @@ -8695,6 +8980,14 @@ "name": "Activate Campaign", "description": "Activates, starts, or resumes an Instantly V2 campaign." }, + { + "name": "Pause Campaign", + "description": "Pauses a running Instantly V2 campaign, stopping further email sends." + }, + { + "name": "Delete Campaign", + "description": "Permanently deletes an Instantly V2 campaign." + }, { "name": "List Emails", "description": "Retrieves Instantly V2 Unibox emails with search and pagination filters." @@ -8712,7 +9005,7 @@ "description": "Creates an Instantly V2 lead list." } ], - "operationCount": 13, + "operationCount": 16, "triggers": [ { "id": "instantly_webhook", @@ -11088,7 +11381,7 @@ "slug": "microsoft-dataverse", "name": "Microsoft Dataverse", "description": "Manage records in Microsoft Dataverse tables", - "longDescription": "Integrate Microsoft Dataverse into your workflow. Create, read, update, delete, upsert, associate, query, search, and execute actions and functions against Dataverse tables using the Web API. Supports bulk operations, FetchXML, file uploads, and relevance search. Works with Dynamics 365, Power Platform, and custom Dataverse environments.", + "longDescription": "Integrate Microsoft Dataverse into your workflow. Create, read, update, delete, upsert, associate, query, search, and execute actions and functions against Dataverse tables using the Web API. Supports bulk operations, FetchXML, file uploads, relevance search, and table metadata lookup. Works with Dynamics 365, Power Platform, and custom Dataverse environments.", "bgColor": "#FFFFFF", "iconName": "MicrosoftDataverseIcon", "docsUrl": "https://docs.sim.ai/integrations/microsoft_dataverse", @@ -11147,7 +11440,7 @@ }, { "name": "Download File", - "description": "Download a file from a file or image column on a Dataverse record. Returns the file content as a base64-encoded string along with file metadata from response headers." + "description": "Download a file from a file or image column on a Dataverse record. Stores the file in execution storage and returns a file reference, plus the base64 content and metadata directly." }, { "name": "Associate Records", @@ -11157,12 +11450,16 @@ "name": "Disassociate Records", "description": "Remove an association between two records in Microsoft Dataverse. For collection-valued navigation properties, provide the target record ID. For single-valued navigation properties, only the navigation property name is needed." }, + { + "name": "Get Table Metadata", + "description": "Retrieve table (entity) and column (attribute) definitions for a Microsoft Dataverse table by its singular logical name. Use this to look up the correct entity set name and column logical names before building record data for other operations." + }, { "name": "WhoAmI", "description": "Retrieve the current authenticated user information from Microsoft Dataverse. Useful for testing connectivity and getting the user ID, business unit ID, and organization ID." } ], - "operationCount": 17, + "operationCount": 18, "triggers": [], "triggerCount": 0, "authType": "oauth", @@ -11253,6 +11550,26 @@ "name": "Read Plan", "description": "Get details of a specific Microsoft Planner plan" }, + { + "name": "Create Plan", + "description": "Create a new Microsoft Planner plan owned by a Microsoft 365 group" + }, + { + "name": "Update Plan", + "description": "Rename a Microsoft Planner plan" + }, + { + "name": "Get Plan Details", + "description": "Get detailed information about a plan including category descriptions and sharing" + }, + { + "name": "Update Plan Details", + "description": "Update a plan's category (color label) descriptions and shared-with user list in Microsoft Planner" + }, + { + "name": "Delete Plan", + "description": "Delete a Microsoft Planner plan" + }, { "name": "List Buckets", "description": "List all buckets in a Microsoft Planner plan" @@ -11282,7 +11599,7 @@ "description": "Update task details including description, checklist items, and references in Microsoft Planner" } ], - "operationCount": 13, + "operationCount": 18, "triggers": [], "triggerCount": 0, "authType": "oauth", @@ -11296,7 +11613,7 @@ "slug": "microsoft-teams", "name": "Microsoft Teams", "description": "Manage messages, reactions, and members in Teams", - "longDescription": "Integrate Microsoft Teams into the workflow. Read, write, update, and delete chat and channel messages. Reply to messages, add reactions, and list team/channel members. Can be used in trigger mode to trigger a workflow when a message is sent to a chat or channel. To mention users in messages, wrap their name in `` tags: `userName`", + "longDescription": "Integrate Microsoft Teams into the workflow. Read, write, update, and delete chat and channel messages. Reply to messages, add reactions, and list teams, chats, channels, and their members. Can be used in trigger mode to trigger a workflow when a message is sent to a chat or channel. To mention users in messages, wrap their name in `` tags: `userName`", "bgColor": "#FFFFFF", "iconName": "MicrosoftTeamsIcon", "docsUrl": "https://docs.sim.ai/integrations/microsoft_teams", @@ -11356,9 +11673,25 @@ { "name": "List Channel Members", "description": "List all members of a Microsoft Teams channel" + }, + { + "name": "List Chat Members", + "description": "List all members of a Microsoft Teams chat" + }, + { + "name": "List Teams", + "description": "List the Microsoft Teams the current user is a direct member of" + }, + { + "name": "List Chats", + "description": "List the Microsoft Teams chats the current user is part of" + }, + { + "name": "List Channels", + "description": "List all channels in a Microsoft Teams team" } ], - "operationCount": 14, + "operationCount": 18, "triggers": [ { "id": "microsoftteams_webhook", @@ -11990,8 +12323,8 @@ "type": "onedrive", "slug": "onedrive", "name": "OneDrive", - "description": "Create, upload, download, list, and delete files", - "longDescription": "Integrate OneDrive into the workflow. Can create text and Excel files, upload files, download files, list files, and delete files or folders.", + "description": "Create, upload, download, search, move, copy, share, and delete files", + "longDescription": "Integrate OneDrive into the workflow. Can create text and Excel files, upload files, download files, list and search files, move or rename files, copy files, create sharing links, and delete files or folders.", "bgColor": "#FFFFFF", "iconName": "MicrosoftOneDriveIcon", "docsUrl": "https://docs.sim.ai/integrations/onedrive", @@ -12016,12 +12349,36 @@ "name": "List Files", "description": "List files and folders in OneDrive" }, + { + "name": "Search Files", + "description": "Search for files and folders across OneDrive by name, metadata, or content (recursive)" + }, + { + "name": "Get Item Info", + "description": "Get metadata for a specific OneDrive file or folder by ID, or the drive root" + }, + { + "name": "Get Drive Info", + "description": "Get information about the OneDrive drive, including storage quota" + }, + { + "name": "Move/Rename File", + "description": "Move a file or folder to a new parent folder, rename it, or both" + }, + { + "name": "Copy File", + "description": "Copy a file or folder to another location within OneDrive" + }, + { + "name": "Create Sharing Link", + "description": "Create a view or edit sharing link for a OneDrive file or folder" + }, { "name": "Delete File", "description": "Delete a file or folder from OneDrive" } ], - "operationCount": 6, + "operationCount": 12, "triggers": [], "triggerCount": 0, "authType": "oauth", @@ -12129,7 +12486,7 @@ "slug": "pagerduty", "name": "PagerDuty", "description": "Manage incidents and on-call schedules with PagerDuty", - "longDescription": "Integrate PagerDuty into your workflow to list, create, and update incidents, add notes, list services, and check on-call schedules.", + "longDescription": "Integrate PagerDuty into your workflow to list, get, create, update, snooze, and merge incidents, add notes and list alerts, look up services and escalation policies, check on-call schedules, list users, and send monitoring events through the Events API v2.", "bgColor": "#06AC38", "iconName": "PagerDutyIcon", "docsUrl": "https://docs.sim.ai/integrations/pagerduty", @@ -12138,6 +12495,10 @@ "name": "List Incidents", "description": "List incidents from PagerDuty with optional filters." }, + { + "name": "Get Incident", + "description": "Get a single incident from PagerDuty by ID." + }, { "name": "Create Incident", "description": "Create a new incident in PagerDuty." @@ -12146,20 +12507,52 @@ "name": "Update Incident", "description": "Update an incident in PagerDuty (acknowledge, resolve, change urgency, etc.)." }, + { + "name": "Snooze Incident", + "description": "Snooze a triggered PagerDuty incident for a number of seconds, after which it returns to triggered." + }, + { + "name": "Merge Incidents", + "description": "Merge one or more source incidents into a target incident. Source incidents are resolved and their alerts move to the target." + }, { "name": "Add Note", "description": "Add a note to an existing PagerDuty incident." }, + { + "name": "List Incident Alerts", + "description": "List the individual alerts attached to a PagerDuty incident." + }, { "name": "List Services", "description": "List services from PagerDuty with optional name filter." }, + { + "name": "Get Service", + "description": "Get a single service from PagerDuty by ID." + }, { "name": "List On-Calls", "description": "List current on-call entries from PagerDuty." + }, + { + "name": "List Escalation Policies", + "description": "List escalation policies from PagerDuty with an optional name filter." + }, + { + "name": "List Schedules", + "description": "List on-call schedules from PagerDuty with an optional name filter." + }, + { + "name": "List Users", + "description": "List users from PagerDuty with an optional name/email filter." + }, + { + "name": "Send Event", + "description": "Send a trigger, acknowledge, or resolve event to PagerDuty Events API v2 using a service integration key. Used to page from monitoring/alerting sources without a PagerDuty user account." } ], - "operationCount": 6, + "operationCount": 15, "triggers": [ { "id": "pagerduty_incident_triggered", @@ -12775,15 +13168,19 @@ }, { "name": "List Insights", - "description": "List all insights in a PostHog project. Returns insight configurations, filters, and metadata." + "description": "List all insights in a PostHog project. Returns insight configurations and metadata." }, { "name": "Get Insight", - "description": "Get a specific insight by ID from PostHog. Returns detailed insight configuration, filters, and metadata." + "description": "Get a specific insight by ID from PostHog. Returns detailed insight configuration and metadata." }, { "name": "Create Insight", - "description": "Create a new insight in PostHog. Requires insight name and configuration filters or query." + "description": "Create a new insight in PostHog. Requires insight name and a query configuration." + }, + { + "name": "Update Insight", + "description": "Update an existing insight in PostHog. Can modify name, description, query, dashboards, tags, and favorited status." }, { "name": "List Dashboards", @@ -12793,6 +13190,10 @@ "name": "Get Dashboard", "description": "Get a specific dashboard by ID from PostHog. Returns detailed dashboard configuration, tiles, and metadata." }, + { + "name": "Create Dashboard", + "description": "Create a new dashboard in PostHog. Optionally seed it from a built-in template, then attach insights to it afterward." + }, { "name": "List Actions", "description": "List all actions in a PostHog project. Returns action definitions, steps, and metadata." @@ -12809,6 +13210,10 @@ "name": "Create Cohort", "description": "Create a new cohort in PostHog. Requires cohort name and filter or query configuration." }, + { + "name": "Update Cohort", + "description": "Update an existing cohort in PostHog. Can modify name, description, filters, query, static membership, and deleted status." + }, { "name": "List Annotations", "description": "List all annotations in a PostHog project. Returns annotation content, timestamps, and associated insights." @@ -12853,6 +13258,10 @@ "name": "Create Experiment", "description": "Create a new experiment in PostHog" }, + { + "name": "Update Experiment", + "description": "Update an existing experiment in PostHog. Use this to change dates, archive an experiment, or adjust its parameters and filters." + }, { "name": "List Surveys", "description": "List all surveys in a PostHog project. Surveys allow you to collect feedback from users." @@ -12869,6 +13278,10 @@ "name": "Update Survey", "description": "Update an existing survey in PostHog. Can modify questions, appearance, conditions, and other settings." }, + { + "name": "Delete Survey", + "description": "Delete a survey from PostHog. Use this to remove expired or unused surveys." + }, { "name": "List Session Recordings", "description": "List session recordings in a PostHog project. Session recordings capture user interactions with your application." @@ -12922,7 +13335,7 @@ "description": "Get detailed information about a specific organization by ID. Returns comprehensive organization settings, features, usage, and team information." } ], - "operationCount": 43, + "operationCount": 48, "triggers": [], "triggerCount": 0, "authType": "api-key", @@ -18200,7 +18613,7 @@ "slug": "tinybird", "name": "Tinybird", "description": "Send events, query data, and manage Data Sources with Tinybird", - "longDescription": "Interact with Tinybird: stream JSON or NDJSON events with the Events API, run SQL with the Query API, call published Pipe API Endpoints by name with dynamic parameters, and manage Data Sources by appending from a URL, truncating, or deleting rows by condition.", + "longDescription": "Interact with Tinybird: stream JSON or NDJSON events with the Events API, run SQL with the Query API, call published Pipe API Endpoints by name with dynamic parameters, manage Data Sources by appending from a URL, truncating, or deleting rows by condition, and poll the status of asynchronous jobs.", "bgColor": "#2EF598", "iconName": "TinybirdIcon", "docsUrl": "https://docs.sim.ai/integrations/tinybird", @@ -18228,9 +18641,13 @@ { "name": "Delete Data Source Rows", "description": "Delete rows from a Tinybird Data Source matching a SQL condition." + }, + { + "name": "Get Job Status", + "description": "Check the status of an asynchronous Tinybird job (import, delete, etc.) by ID." } ], - "operationCount": 6, + "operationCount": 7, "triggers": [], "triggerCount": 0, "authType": "api-key", diff --git a/apps/sim/tools/google_vault/add_held_accounts.ts b/apps/sim/tools/google_vault/add_held_accounts.ts new file mode 100644 index 00000000000..34cca96781f --- /dev/null +++ b/apps/sim/tools/google_vault/add_held_accounts.ts @@ -0,0 +1,83 @@ +import type { GoogleVaultAddHeldAccountsParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const addHeldAccountsTool: ToolConfig = { + id: 'google_vault_add_held_accounts', + name: 'Vault Add Held Accounts', + description: 'Add accounts to an existing hold', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + holdId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The hold ID to add accounts to (e.g., "holdId123456")', + }, + accountEmails: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: + 'Comma-separated list of user emails to add to the hold (e.g., "user1@example.com, user2@example.com")', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/holds/${params.holdId.trim()}:addHeldAccounts`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => { + const emails = params.accountEmails + .split(',') + .map((e) => e.trim()) + .filter(Boolean) + return { emails } + }, + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to add held accounts' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { responses: data.responses ?? [] } } + }, + + outputs: { + responses: { + type: 'array', + description: 'Per-account results of the add operation', + items: { + type: 'object', + properties: { + account: { type: 'json', description: 'Held account (accountId, email)' }, + status: { type: 'json', description: 'Status (code, message) if the add failed' }, + }, + }, + }, + }, +} diff --git a/apps/sim/tools/google_vault/add_matters_permissions.ts b/apps/sim/tools/google_vault/add_matters_permissions.ts new file mode 100644 index 00000000000..6ab4a603900 --- /dev/null +++ b/apps/sim/tools/google_vault/add_matters_permissions.ts @@ -0,0 +1,83 @@ +import type { GoogleVaultAddMatterPermissionsParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const addMattersPermissionsTool: ToolConfig = { + id: 'google_vault_add_matters_permissions', + name: 'Vault Add Matter Collaborator', + description: 'Add a collaborator (or transfer ownership) to a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + accountId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'Admin SDK account ID of the user to add as a collaborator/owner', + }, + role: { + type: 'string', + required: true, + visibility: 'user-only', + description: 'Permission level to grant: COLLABORATOR or OWNER', + }, + sendEmails: { + type: 'boolean', + required: false, + visibility: 'user-only', + description: 'Send a notification email to the added account', + }, + ccMe: { + type: 'boolean', + required: false, + visibility: 'user-only', + description: + 'CC the requestor on the notification email (only relevant if sendEmails is true)', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}:addPermissions`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => ({ + matterPermission: { accountId: params.accountId, role: params.role }, + sendEmails: params.sendEmails, + ccMe: params.ccMe, + }), + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to add matter collaborator' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { permission: data } } + }, + + outputs: { + permission: { type: 'json', description: 'Created matter permission (accountId, role)' }, + }, +} diff --git a/apps/sim/tools/google_vault/close_matters.ts b/apps/sim/tools/google_vault/close_matters.ts new file mode 100644 index 00000000000..caa5ed1759c --- /dev/null +++ b/apps/sim/tools/google_vault/close_matters.ts @@ -0,0 +1,53 @@ +import type { GoogleVaultMatterActionParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const closeMattersTool: ToolConfig = { + id: 'google_vault_close_matters', + name: 'Vault Close Matter', + description: 'Close a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID to close (e.g., "12345678901234567890")', + }, + }, + + request: { + url: (params) => `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}:close`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: () => ({}), + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to close matter' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { matter: data.matter ?? data } } + }, + + outputs: { + matter: { type: 'json', description: 'Closed matter object' }, + }, +} diff --git a/apps/sim/tools/google_vault/create_matters.ts b/apps/sim/tools/google_vault/create_matters.ts index b7535baf357..7aa235b7dc9 100644 --- a/apps/sim/tools/google_vault/create_matters.ts +++ b/apps/sim/tools/google_vault/create_matters.ts @@ -6,7 +6,7 @@ export const createMattersTool: ToolConfig = { id: 'google_vault_create_matters', name: 'Vault Create Matter', description: 'Create a new matter in Google Vault', - version: '1.0', + version: '1.0.0', oauth: { required: true, diff --git a/apps/sim/tools/google_vault/create_matters_export.ts b/apps/sim/tools/google_vault/create_matters_export.ts index a7cdd14d55f..5f2acad00f8 100644 --- a/apps/sim/tools/google_vault/create_matters_export.ts +++ b/apps/sim/tools/google_vault/create_matters_export.ts @@ -6,7 +6,7 @@ export const createMattersExportTool: ToolConfig 0 ? 'ACCOUNT' : params.orgUnitId ? 'ORG_UNIT' : undefined + const method = + emails.length > 0 + ? 'ACCOUNT' + : params.orgUnitId + ? 'ORG_UNIT' + : params.corpus === 'MAIL' + ? 'ENTIRE_ORG' + : undefined + + if (!method) { + throw new Error( + `Account Emails or Org Unit ID is required to scope a ${params.corpus} export ` + + '(only MAIL exports can search the entire organization with no scope).' + ) + } const query: any = { corpus: params.corpus, dataScope: 'ALL_DATA', - searchMethod: searchMethod, + method, terms: params.terms || undefined, startTime: params.startTime || undefined, endTime: params.endTime || undefined, diff --git a/apps/sim/tools/google_vault/create_matters_holds.ts b/apps/sim/tools/google_vault/create_matters_holds.ts index 28014f61d31..31a1e5c5874 100644 --- a/apps/sim/tools/google_vault/create_matters_holds.ts +++ b/apps/sim/tools/google_vault/create_matters_holds.ts @@ -6,7 +6,7 @@ export const createMattersHoldsTool: ToolConfig = { + id: 'google_vault_create_saved_query', + name: 'Vault Create Saved Query', + description: 'Save a reusable search query in a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + displayName: { + type: 'string', + required: true, + visibility: 'user-only', + description: 'Name for the saved query', + }, + corpus: { + type: 'string', + required: true, + visibility: 'user-only', + description: 'Data corpus to search (MAIL, DRIVE, GROUPS, HANGOUTS_CHAT, VOICE)', + }, + accountEmails: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'Comma-separated list of user emails to scope the query (e.g., "user1@example.com, user2@example.com")', + }, + orgUnitId: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'Organization unit ID to scope the query (e.g., "id:03ph8a2z1enx5q0", alternative to emails)', + }, + startTime: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: 'Start time for date filtering (ISO 8601 format, e.g., "2024-01-01T00:00:00Z")', + }, + endTime: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: 'End time for date filtering (ISO 8601 format, e.g., "2024-12-31T23:59:59Z")', + }, + terms: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: 'Search query terms (e.g., "from:sender@example.com subject:invoice")', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/savedQueries`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => { + let emails: string[] = [] + if (params.accountEmails) { + if (Array.isArray(params.accountEmails)) { + emails = params.accountEmails + } else if (typeof params.accountEmails === 'string') { + emails = params.accountEmails + .split(',') + .map((e) => e.trim()) + .filter(Boolean) + } + } + + const scope = + emails.length > 0 + ? { accountInfo: { emails } } + : params.orgUnitId + ? { orgUnitInfo: { orgUnitId: params.orgUnitId } } + : {} + + const method = + emails.length > 0 + ? 'ACCOUNT' + : params.orgUnitId + ? 'ORG_UNIT' + : params.corpus === 'MAIL' + ? 'ENTIRE_ORG' + : undefined + + if (!method) { + throw new Error( + `Account Emails or Org Unit ID is required to scope a ${params.corpus} saved query ` + + '(only MAIL queries can search the entire organization with no scope).' + ) + } + + return { + displayName: params.displayName, + query: { + corpus: params.corpus, + dataScope: 'ALL_DATA', + method, + terms: params.terms || undefined, + startTime: params.startTime || undefined, + endTime: params.endTime || undefined, + ...scope, + }, + } + }, + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to create saved query' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { savedQuery: data } } + }, + + outputs: { + savedQuery: { type: 'json', description: 'Created saved query object' }, + }, +} diff --git a/apps/sim/tools/google_vault/delete_matters.ts b/apps/sim/tools/google_vault/delete_matters.ts new file mode 100644 index 00000000000..9add843580e --- /dev/null +++ b/apps/sim/tools/google_vault/delete_matters.ts @@ -0,0 +1,52 @@ +import type { GoogleVaultMatterActionParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const deleteMattersTool: ToolConfig = { + id: 'google_vault_delete_matters', + name: 'Vault Delete Matter', + description: 'Permanently delete a matter (must be closed first)', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID to delete (e.g., "12345678901234567890")', + }, + }, + + request: { + url: (params) => `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}`, + method: 'DELETE', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + }), + }, + + transformResponse: async (response: Response) => { + if (!response.ok) { + const data = await response.json().catch(() => ({})) + const errorMessage = data.error?.message || 'Failed to delete matter' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + const data = await response.json().catch(() => ({})) + return { success: true, output: { matter: data.matter ?? data } } + }, + + outputs: { + matter: { type: 'json', description: 'Deleted matter object' }, + }, +} diff --git a/apps/sim/tools/google_vault/delete_matters_export.ts b/apps/sim/tools/google_vault/delete_matters_export.ts new file mode 100644 index 00000000000..fdd5b158af6 --- /dev/null +++ b/apps/sim/tools/google_vault/delete_matters_export.ts @@ -0,0 +1,58 @@ +import type { GoogleVaultDeleteMattersExportParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const deleteMattersExportTool: ToolConfig = { + id: 'google_vault_delete_matters_export', + name: 'Vault Delete Export', + description: 'Delete an export from a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + exportId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The export ID to delete (e.g., "exportId123456")', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/exports/${params.exportId.trim()}`, + method: 'DELETE', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + }), + }, + + transformResponse: async (response: Response) => { + if (!response.ok) { + const data = await response.json().catch(() => ({})) + const errorMessage = data.error?.message || 'Failed to delete export' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { success: true } } + }, + + outputs: { + success: { type: 'boolean', description: 'Whether the export was deleted' }, + }, +} diff --git a/apps/sim/tools/google_vault/delete_matters_holds.ts b/apps/sim/tools/google_vault/delete_matters_holds.ts new file mode 100644 index 00000000000..0c4f07f9e6b --- /dev/null +++ b/apps/sim/tools/google_vault/delete_matters_holds.ts @@ -0,0 +1,58 @@ +import type { GoogleVaultDeleteMattersHoldsParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const deleteMattersHoldsTool: ToolConfig = { + id: 'google_vault_delete_matters_holds', + name: 'Vault Delete Hold', + description: 'Delete a hold and release its covered accounts', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + holdId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The hold ID to delete (e.g., "holdId123456")', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/holds/${params.holdId.trim()}`, + method: 'DELETE', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + }), + }, + + transformResponse: async (response: Response) => { + if (!response.ok) { + const data = await response.json().catch(() => ({})) + const errorMessage = data.error?.message || 'Failed to delete hold' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { success: true } } + }, + + outputs: { + success: { type: 'boolean', description: 'Whether the hold was deleted' }, + }, +} diff --git a/apps/sim/tools/google_vault/delete_saved_query.ts b/apps/sim/tools/google_vault/delete_saved_query.ts new file mode 100644 index 00000000000..2727b8884be --- /dev/null +++ b/apps/sim/tools/google_vault/delete_saved_query.ts @@ -0,0 +1,58 @@ +import type { GoogleVaultDeleteSavedQueryParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const deleteSavedQueryTool: ToolConfig = { + id: 'google_vault_delete_saved_query', + name: 'Vault Delete Saved Query', + description: 'Delete a saved query from a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + savedQueryId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The saved query ID to delete', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/savedQueries/${params.savedQueryId.trim()}`, + method: 'DELETE', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + }), + }, + + transformResponse: async (response: Response) => { + if (!response.ok) { + const data = await response.json().catch(() => ({})) + const errorMessage = data.error?.message || 'Failed to delete saved query' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { success: true } } + }, + + outputs: { + success: { type: 'boolean', description: 'Whether the saved query was deleted' }, + }, +} diff --git a/apps/sim/tools/google_vault/download_export_file.ts b/apps/sim/tools/google_vault/download_export_file.ts index 26453daee80..fe6058e786e 100644 --- a/apps/sim/tools/google_vault/download_export_file.ts +++ b/apps/sim/tools/google_vault/download_export_file.ts @@ -5,7 +5,7 @@ export const downloadExportFileTool: ToolConfig = { id: 'google_vault_list_matters', name: 'Vault List Matters', description: 'List matters, or get a specific matter if matterId is provided', - version: '1.0', + version: '1.0.0', oauth: { required: true, diff --git a/apps/sim/tools/google_vault/list_matters_export.ts b/apps/sim/tools/google_vault/list_matters_export.ts index ad0880c6a48..af320ddf98b 100644 --- a/apps/sim/tools/google_vault/list_matters_export.ts +++ b/apps/sim/tools/google_vault/list_matters_export.ts @@ -6,7 +6,7 @@ export const listMattersExportTool: ToolConfig id: 'google_vault_list_matters_holds', name: 'Vault List Holds', description: 'List holds for a matter', - version: '1.0', + version: '1.0.0', oauth: { required: true, diff --git a/apps/sim/tools/google_vault/list_saved_queries.ts b/apps/sim/tools/google_vault/list_saved_queries.ts new file mode 100644 index 00000000000..807902629d9 --- /dev/null +++ b/apps/sim/tools/google_vault/list_saved_queries.ts @@ -0,0 +1,90 @@ +import type { GoogleVaultListSavedQueriesParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const listSavedQueriesTool: ToolConfig = { + id: 'google_vault_list_saved_queries', + name: 'Vault List Saved Queries', + description: 'List saved queries in a matter, or get a specific one if savedQueryId is provided', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + pageSize: { + type: 'number', + required: false, + visibility: 'user-only', + description: 'Number of saved queries to return per page', + }, + pageToken: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: 'Token for pagination', + }, + savedQueryId: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: 'Optional saved query ID to fetch a specific saved query', + }, + }, + + request: { + url: (params) => { + if (params.savedQueryId) { + return `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/savedQueries/${params.savedQueryId.trim()}` + } + const url = new URL( + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/savedQueries` + ) + if (params.pageSize !== undefined && params.pageSize !== null) { + const pageSize = Number(params.pageSize) + if (Number.isFinite(pageSize) && pageSize > 0) { + url.searchParams.set('pageSize', String(pageSize)) + } + } + if (params.pageToken) url.searchParams.set('pageToken', params.pageToken) + return url.toString() + }, + method: 'GET', + headers: (params) => ({ Authorization: `Bearer ${params.accessToken}` }), + }, + + transformResponse: async (response: Response, params?: GoogleVaultListSavedQueriesParams) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to list saved queries' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + if (params?.savedQueryId) { + return { success: true, output: { savedQuery: data } } + } + return { success: true, output: data } + }, + + outputs: { + savedQueries: { type: 'json', description: 'Array of saved query objects' }, + savedQuery: { + type: 'json', + description: 'Single saved query object (when savedQueryId is provided)', + }, + nextPageToken: { type: 'string', description: 'Token for fetching next page of results' }, + }, +} diff --git a/apps/sim/tools/google_vault/remove_held_accounts.ts b/apps/sim/tools/google_vault/remove_held_accounts.ts new file mode 100644 index 00000000000..4265639c939 --- /dev/null +++ b/apps/sim/tools/google_vault/remove_held_accounts.ts @@ -0,0 +1,80 @@ +import type { GoogleVaultRemoveHeldAccountsParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const removeHeldAccountsTool: ToolConfig = { + id: 'google_vault_remove_held_accounts', + name: 'Vault Remove Held Accounts', + description: 'Remove accounts from an existing hold', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + holdId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The hold ID to remove accounts from (e.g., "holdId123456")', + }, + accountIds: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: + 'Comma-separated list of Admin SDK account IDs to remove from the hold (e.g., "accountId1, accountId2")', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/holds/${params.holdId.trim()}:removeHeldAccounts`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => { + const accountIds = params.accountIds + .split(',') + .map((id) => id.trim()) + .filter(Boolean) + return { accountIds } + }, + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to remove held accounts' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { statuses: data.statuses ?? [] } } + }, + + outputs: { + statuses: { + type: 'array', + description: 'Per-account removal status, in request order', + items: { + type: 'json', + description: 'Status (code, message) for one account removal', + }, + }, + }, +} diff --git a/apps/sim/tools/google_vault/remove_matters_permissions.ts b/apps/sim/tools/google_vault/remove_matters_permissions.ts new file mode 100644 index 00000000000..b3445ff52f6 --- /dev/null +++ b/apps/sim/tools/google_vault/remove_matters_permissions.ts @@ -0,0 +1,60 @@ +import type { GoogleVaultRemoveMatterPermissionsParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const removeMattersPermissionsTool: ToolConfig = { + id: 'google_vault_remove_matters_permissions', + name: 'Vault Remove Matter Collaborator', + description: 'Remove a collaborator from a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + accountId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'Admin SDK account ID of the collaborator to remove', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}:removePermissions`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => ({ accountId: params.accountId }), + }, + + transformResponse: async (response: Response) => { + if (!response.ok) { + const data = await response.json().catch(() => ({})) + const errorMessage = data.error?.message || 'Failed to remove matter collaborator' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { success: true } } + }, + + outputs: { + success: { type: 'boolean', description: 'Whether the collaborator was removed' }, + }, +} diff --git a/apps/sim/tools/google_vault/reopen_matters.ts b/apps/sim/tools/google_vault/reopen_matters.ts new file mode 100644 index 00000000000..6304ed33e6d --- /dev/null +++ b/apps/sim/tools/google_vault/reopen_matters.ts @@ -0,0 +1,53 @@ +import type { GoogleVaultMatterActionParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const reopenMattersTool: ToolConfig = { + id: 'google_vault_reopen_matters', + name: 'Vault Reopen Matter', + description: 'Reopen a closed matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID to reopen (e.g., "12345678901234567890")', + }, + }, + + request: { + url: (params) => `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}:reopen`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: () => ({}), + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to reopen matter' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { matter: data.matter ?? data } } + }, + + outputs: { + matter: { type: 'json', description: 'Reopened matter object' }, + }, +} diff --git a/apps/sim/tools/google_vault/types.ts b/apps/sim/tools/google_vault/types.ts index ce39da336e1..c5527ec3365 100644 --- a/apps/sim/tools/google_vault/types.ts +++ b/apps/sim/tools/google_vault/types.ts @@ -68,6 +68,85 @@ export interface GoogleVaultListMattersHoldsParams extends GoogleVaultCommonPara holdId?: string } +export interface GoogleVaultUpdateMatterParams { + accessToken: string + matterId: string + name: string + description?: string +} + +export interface GoogleVaultMatterActionParams { + accessToken: string + matterId: string +} + +export interface GoogleVaultAddMatterPermissionsParams { + accessToken: string + matterId: string + accountId: string + role: 'COLLABORATOR' | 'OWNER' + sendEmails?: boolean + ccMe?: boolean +} + +export interface GoogleVaultRemoveMatterPermissionsParams { + accessToken: string + matterId: string + accountId: string +} + +export interface GoogleVaultDeleteMattersExportParams { + accessToken: string + matterId: string + exportId: string +} + +export interface GoogleVaultUpdateMattersHoldsParams extends GoogleVaultCommonParams { + holdId: string + holdName: string + corpus: GoogleVaultCorpus + accountEmails?: string + orgUnitId?: string + terms?: string + startTime?: string + endTime?: string + includeSharedDrives?: boolean +} + +export interface GoogleVaultDeleteMattersHoldsParams extends GoogleVaultCommonParams { + holdId: string +} + +export interface GoogleVaultAddHeldAccountsParams extends GoogleVaultCommonParams { + holdId: string + accountEmails: string +} + +export interface GoogleVaultRemoveHeldAccountsParams extends GoogleVaultCommonParams { + holdId: string + accountIds: string +} + +export interface GoogleVaultCreateSavedQueryParams extends GoogleVaultCommonParams { + displayName: string + corpus: GoogleVaultCorpus + accountEmails?: string + orgUnitId?: string + terms?: string + startTime?: string + endTime?: string +} + +export interface GoogleVaultListSavedQueriesParams extends GoogleVaultCommonParams { + pageSize?: number + pageToken?: string + savedQueryId?: string +} + +export interface GoogleVaultDeleteSavedQueryParams extends GoogleVaultCommonParams { + savedQueryId: string +} + interface GoogleVaultListMattersHoldsResponse extends ToolResponse { output: any } diff --git a/apps/sim/tools/google_vault/undelete_matters.ts b/apps/sim/tools/google_vault/undelete_matters.ts new file mode 100644 index 00000000000..325004c8651 --- /dev/null +++ b/apps/sim/tools/google_vault/undelete_matters.ts @@ -0,0 +1,53 @@ +import type { GoogleVaultMatterActionParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const undeleteMattersTool: ToolConfig = { + id: 'google_vault_undelete_matters', + name: 'Vault Undelete Matter', + description: 'Restore a deleted matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID to restore (e.g., "12345678901234567890")', + }, + }, + + request: { + url: (params) => `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}:undelete`, + method: 'POST', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: () => ({}), + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to restore matter' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { matter: data.matter ?? data } } + }, + + outputs: { + matter: { type: 'json', description: 'Restored matter object' }, + }, +} diff --git a/apps/sim/tools/google_vault/update_matters.ts b/apps/sim/tools/google_vault/update_matters.ts new file mode 100644 index 00000000000..8754d455508 --- /dev/null +++ b/apps/sim/tools/google_vault/update_matters.ts @@ -0,0 +1,65 @@ +import type { GoogleVaultUpdateMatterParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const updateMattersTool: ToolConfig = { + id: 'google_vault_update_matters', + name: 'Vault Update Matter', + description: 'Update the name and/or description of a matter', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID to update (e.g., "12345678901234567890")', + }, + name: { + type: 'string', + required: true, + visibility: 'user-only', + description: 'New name for the matter', + }, + description: { + type: 'string', + required: false, + visibility: 'user-only', + description: 'New description for the matter', + }, + }, + + request: { + url: (params) => `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}`, + method: 'PUT', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => ({ name: params.name, description: params.description }), + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to update matter' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { matter: data } } + }, + + outputs: { + matter: { type: 'json', description: 'Updated matter object' }, + }, +} diff --git a/apps/sim/tools/google_vault/update_matters_holds.ts b/apps/sim/tools/google_vault/update_matters_holds.ts new file mode 100644 index 00000000000..23cd3ed0a6c --- /dev/null +++ b/apps/sim/tools/google_vault/update_matters_holds.ts @@ -0,0 +1,164 @@ +import type { GoogleVaultUpdateMattersHoldsParams } from '@/tools/google_vault/types' +import { enhanceGoogleVaultError } from '@/tools/google_vault/utils' +import type { ToolConfig } from '@/tools/types' + +export const updateMattersHoldsTool: ToolConfig = { + id: 'google_vault_update_matters_holds', + name: 'Vault Update Hold', + description: + 'Replace the name, query, and scope of an existing hold. This is a full-resource update: fetch the current hold first (Vault List Holds) and resupply every field you want to keep — any field left blank is cleared, not left unchanged.', + version: '1.0.0', + + oauth: { + required: true, + provider: 'google-vault', + }, + + params: { + accessToken: { + type: 'string', + required: true, + visibility: 'hidden', + description: 'OAuth access token', + }, + matterId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The matter ID (e.g., "12345678901234567890")', + }, + holdId: { + type: 'string', + required: true, + visibility: 'user-or-llm', + description: 'The hold ID to update (e.g., "holdId123456")', + }, + holdName: { + type: 'string', + required: true, + visibility: 'user-only', + description: 'Name for the hold', + }, + corpus: { + type: 'string', + required: true, + visibility: 'user-only', + description: 'Data corpus of the hold (MAIL, DRIVE, GROUPS, HANGOUTS_CHAT, VOICE)', + }, + accountEmails: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'Comma-separated list of user emails covered by the hold (e.g., "user1@example.com, user2@example.com")', + }, + orgUnitId: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'Organization unit ID covered by the hold (e.g., "id:03ph8a2z1enx5q0", alternative to accounts)', + }, + terms: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'Search terms to filter held content (e.g., "from:sender@example.com subject:invoice", for MAIL and GROUPS corpus). Resupply the hold\'s current terms to keep them — this replaces the hold, so leaving it blank clears any existing filter.', + }, + startTime: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'Start time for date filtering (ISO 8601 format, e.g., "2024-01-01T00:00:00Z", for MAIL and GROUPS corpus). Resupply the hold\'s current value to keep it — leaving it blank clears any existing date filter.', + }, + endTime: { + type: 'string', + required: false, + visibility: 'user-or-llm', + description: + 'End time for date filtering (ISO 8601 format, e.g., "2024-12-31T23:59:59Z", for MAIL and GROUPS corpus). Resupply the hold\'s current value to keep it — leaving it blank clears any existing date filter.', + }, + includeSharedDrives: { + type: 'boolean', + required: false, + visibility: 'user-only', + description: + 'Include files in shared drives (for DRIVE corpus). Resupply true if the hold currently includes shared drives — leaving it false/blank clears that setting.', + }, + }, + + request: { + url: (params) => + `https://vault.googleapis.com/v1/matters/${params.matterId.trim()}/holds/${params.holdId.trim()}`, + method: 'PUT', + headers: (params) => ({ + Authorization: `Bearer ${params.accessToken}`, + 'Content-Type': 'application/json', + }), + body: (params) => { + const body: any = { + name: params.holdName, + corpus: params.corpus, + } + + let emails: string[] = [] + if (params.accountEmails) { + if (Array.isArray(params.accountEmails)) { + emails = params.accountEmails + } else if (typeof params.accountEmails === 'string') { + emails = params.accountEmails + .split(',') + .map((e) => e.trim()) + .filter(Boolean) + } + } + + if (emails.length > 0) { + body.accounts = emails.map((email: string) => ({ email })) + } else if (params.orgUnitId) { + body.orgUnit = { orgUnitId: params.orgUnitId } + } else { + throw new Error( + 'Updating a hold replaces its full scope: re-provide the current Account Emails or Org Unit ID ' + + '(they are not preserved automatically). To add or remove individual custodians without ' + + 'resending the full scope, use Add Held Accounts / Remove Held Accounts instead.' + ) + } + + if (params.corpus === 'MAIL' || params.corpus === 'GROUPS') { + const hasQueryParams = params.terms || params.startTime || params.endTime + if (hasQueryParams) { + const queryObj: any = {} + if (params.terms) queryObj.terms = params.terms + if (params.startTime) queryObj.startTime = params.startTime + if (params.endTime) queryObj.endTime = params.endTime + + if (params.corpus === 'MAIL') { + body.query = { mailQuery: queryObj } + } else { + body.query = { groupsQuery: queryObj } + } + } + } else if (params.corpus === 'DRIVE' && params.includeSharedDrives) { + body.query = { driveQuery: { includeSharedDriveFiles: params.includeSharedDrives } } + } + + return body + }, + }, + + transformResponse: async (response: Response) => { + const data = await response.json() + if (!response.ok) { + const errorMessage = data.error?.message || 'Failed to update hold' + throw new Error(enhanceGoogleVaultError(errorMessage)) + } + return { success: true, output: { hold: data } } + }, + + outputs: { + hold: { type: 'json', description: 'Updated hold object' }, + }, +} diff --git a/apps/sim/tools/registry.ts b/apps/sim/tools/registry.ts index 72c6456b0b2..fa950a2c023 100644 --- a/apps/sim/tools/registry.ts +++ b/apps/sim/tools/registry.ts @@ -1564,13 +1564,28 @@ import { } from '@/tools/google_tasks' import { googleTranslateDetectTool, googleTranslateTool } from '@/tools/google_translate' import { + addHeldAccountsTool, + addMattersPermissionsTool, + closeMattersTool, createMattersExportTool, createMattersHoldsTool, createMattersTool, + createSavedQueryTool, + deleteMattersExportTool, + deleteMattersHoldsTool, + deleteMattersTool, + deleteSavedQueryTool, downloadExportFileTool, listMattersExportTool, listMattersHoldsTool, listMattersTool, + listSavedQueriesTool, + removeHeldAccountsTool, + removeMattersPermissionsTool, + reopenMattersTool, + undeleteMattersTool, + updateMattersHoldsTool, + updateMattersTool, } from '@/tools/google_vault' import { grafanaCheckDataSourceHealthTool, @@ -7826,13 +7841,28 @@ export const tools: Record = { google_bigquery_delete_table: googleBigQueryDeleteTableTool, google_bigquery_list_table_data: googleBigQueryListTableDataTool, google_bigquery_get_query_results: googleBigQueryGetQueryResultsTool, + google_vault_add_held_accounts: addHeldAccountsTool, + google_vault_add_matters_permissions: addMattersPermissionsTool, + google_vault_close_matters: closeMattersTool, google_vault_create_matters_export: createMattersExportTool, google_vault_list_matters_export: listMattersExportTool, google_vault_create_matters_holds: createMattersHoldsTool, google_vault_list_matters_holds: listMattersHoldsTool, google_vault_create_matters: createMattersTool, google_vault_list_matters: listMattersTool, + google_vault_create_saved_query: createSavedQueryTool, + google_vault_delete_matters: deleteMattersTool, + google_vault_delete_matters_export: deleteMattersExportTool, + google_vault_delete_matters_holds: deleteMattersHoldsTool, + google_vault_delete_saved_query: deleteSavedQueryTool, google_vault_download_export_file: downloadExportFileTool, + google_vault_list_saved_queries: listSavedQueriesTool, + google_vault_remove_held_accounts: removeHeldAccountsTool, + google_vault_remove_matters_permissions: removeMattersPermissionsTool, + google_vault_reopen_matters: reopenMattersTool, + google_vault_undelete_matters: undeleteMattersTool, + google_vault_update_matters: updateMattersTool, + google_vault_update_matters_holds: updateMattersHoldsTool, google_groups_add_alias: googleGroupsAddAliasTool, google_groups_add_member: googleGroupsAddMemberTool, google_groups_create_group: googleGroupsCreateGroupTool,