Skip to content

Commit e706c07

Browse files
authored
feat(tools): added google sheets append tool (#331)
1 parent 5714441 commit e706c07

13 files changed

Lines changed: 238 additions & 26 deletions

File tree

docs/content/docs/tools/clay.mdx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Clay
3-
description: Populate Clay with data
3+
description: Populate Clay workbook with data
44
---
55

66
import { BlockInfoCard } from "@/components/ui/block-info-card"
@@ -197,7 +197,8 @@ In Sim Studio, the Clay integration allows your agents to push structured data i
197197

198198
## Usage Instructions
199199

200-
Populate Clay with data from a JSON file. Enables direct communication and notifications with timestamp tracking and channel confirmation.
200+
Populate Clay workbook with data using a JSON or plain text. Enables direct communication and notifications with channel confirmation.
201+
201202

202203

203204
## Tools
@@ -210,7 +211,7 @@ Populate Clay with data from a JSON file. Enables direct communication and notif
210211

211212
| Parameter | Type | Required | Description |
212213
| --------- | ---- | -------- | ----------- |
213-
| `webhookId` | string | Yes | The webhook ID to populate |
214+
| `webhookURL` | string | Yes | The webhook URL to populate |
214215
| `data` | json | Yes | The data to populate |
215216
| `authToken` | string | No | Optional auth token for WebhookURL |
216217

@@ -228,7 +229,7 @@ Populate Clay with data from a JSON file. Enables direct communication and notif
228229

229230
| Parameter | Type | Required | Description |
230231
| --------- | ---- | -------- | ----------- |
231-
| `apiKey` | string | No | Auth Token - Enter your Clay Auth token |
232+
| `authToken` | string | Yes | Auth Token - Enter your Clay Auth token |
232233

233234

234235

docs/content/docs/tools/google_sheets.mdx

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ In Sim Studio, the Google Sheets integration enables your agents to interact dir
4848

4949
## Usage Instructions
5050

51-
Integrate Google Sheets functionality to manage spreadsheet data. Read data from specific ranges, write new data, and update existing cells using OAuth authentication. Supports various input and output formats for flexible data handling.
51+
Integrate Google Sheets functionality to manage spreadsheet data. Read data from specific ranges, write new data, update existing cells, and append data to the end of sheets using OAuth authentication. Supports various input and output formats for flexible data handling.
5252

5353

5454

@@ -126,6 +126,28 @@ Update data in a Google Sheets spreadsheet
126126
| `spreadsheetId` | string |
127127
| `spreadsheetUrl` | string |
128128

129+
### `google_sheets_append`
130+
131+
Append data to the end of a Google Sheets spreadsheet
132+
133+
#### Input
134+
135+
| Parameter | Type | Required | Description |
136+
| --------- | ---- | -------- | ----------- |
137+
| `accessToken` | string | Yes | The access token for the Google Sheets API |
138+
| `spreadsheetId` | string | Yes | The ID of the spreadsheet to append to |
139+
| `range` | string | No | The range of cells to append after |
140+
| `values` | array | Yes | The data to append to the spreadsheet |
141+
| `valueInputOption` | string | No | The format of the data to append |
142+
| `insertDataOption` | string | No | How to insert the data \(OVERWRITE or INSERT_ROWS\) |
143+
| `includeValuesInResponse` | boolean | No | Whether to include the appended values in the response |
144+
145+
#### Output
146+
147+
| Parameter | Type |
148+
| --------- | ---- |
149+
| `data` | json |
150+
129151

130152

131153
## Block Configuration
@@ -149,6 +171,7 @@ Update data in a Google Sheets spreadsheet
149171
|`updatedRows` | number | updatedRows of the response |
150172
|`updatedColumns` | number | updatedColumns of the response |
151173
|`updatedCells` | number | updatedCells of the response |
174+
|`tableRange` | string | tableRange of the response |
152175

153176

154177
## Notes

docs/content/docs/tools/jira.mdx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import { BlockInfoCard } from "@/components/ui/block-info-card"
2525
</svg>`}
2626
/>
2727

28+
{/* MANUAL-CONTENT-START:intro */}
2829
[Jira](https://www.atlassian.com/jira) is a leading project management and issue tracking platform that helps teams plan, track, and manage agile software development projects effectively. As part of the Atlassian suite, Jira has become the industry standard for software development teams and project management professionals worldwide.
2930

3031
Jira provides a comprehensive set of tools for managing complex projects through its flexible and customizable workflow system. With its robust API and integration capabilities, Jira enables teams to streamline their development processes and maintain clear visibility of project progress.
@@ -37,6 +38,8 @@ Key features of Jira include:
3738
- Advanced Search: JQL (Jira Query Language) for complex issue filtering and reporting
3839

3940
In Sim Studio, the Jira integration allows your agents to seamlessly interact with your project management workflow. This creates opportunities for automated issue creation, updates, and tracking as part of your AI workflows. The integration enables agents to create, retrieve, and update Jira issues programmatically, facilitating automated project management tasks and ensuring that important information is properly tracked and documented. By connecting Sim Studio with Jira, you can build intelligent agents that maintain project visibility while automating routine project management tasks, enhancing team productivity and ensuring consistent project tracking.
41+
{/* MANUAL-CONTENT-END */}
42+
4043

4144
## Usage Instructions
4245

docs/content/docs/tools/meta.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
"stagehand_agent",
3535
"supabase",
3636
"tavily",
37+
"telegram",
3738
"thinking",
3839
"translate",
3940
"twilio_sms",

docs/content/docs/tools/slack.mdx

Lines changed: 25 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ title: Slack
33
description: Send a message to Slack
44
---
55

6-
import { BlockInfoCard } from '@/components/ui/block-info-card'
6+
import { BlockInfoCard } from "@/components/ui/block-info-card"
77

8-
<BlockInfoCard
8+
<BlockInfoCard
99
type="slack"
1010
color="#611f69"
1111
icon={true}
@@ -53,10 +53,13 @@ With Slack, you can:
5353
In Sim Studio, the Slack integration enables your agents to programmatically send messages to any Slack channel or user as part of their workflows. This allows for powerful automation scenarios such as sending notifications, alerts, updates, and reports directly to your team's communication hub. Your agents can deliver timely information, share results from processes they've completed, or alert team members when attention is needed. This integration bridges the gap between your AI workflows and your team's communication, ensuring everyone stays informed without manual intervention. By connecting Sim Studio with Slack, you can create agents that keep your team updated with relevant information at the right time, enhance collaboration by sharing insights automatically, and reduce the need for manual status updates - all while leveraging your existing Slack workspace where your team already communicates.
5454
{/* MANUAL-CONTENT-END */}
5555

56+
5657
## Usage Instructions
5758

5859
Send messages to any Slack channel using OAuth authentication. Integrate automated notifications and alerts into your workflow to keep your team informed.
5960

61+
62+
6063
## Tools
6164

6265
### `slack_message`
@@ -65,35 +68,40 @@ Send messages to Slack channels or users through the Slack API. Enables direct c
6568

6669
#### Input
6770

68-
| Parameter | Type | Required | Description |
69-
| --------- | ------ | -------- | --------------------------------------- |
70-
| `apiKey` | string | Yes | Your Slack API token |
71-
| `channel` | string | Yes | Target Slack channel \(e.g., #general\) |
72-
| `text` | string | Yes | Message text to send |
71+
| Parameter | Type | Required | Description |
72+
| --------- | ---- | -------- | ----------- |
73+
| `apiKey` | string | Yes | Your Slack API token |
74+
| `channel` | string | Yes | Target Slack channel \(e.g., #general\) |
75+
| `text` | string | Yes | Message text to send |
7376

7477
#### Output
7578

76-
| Parameter | Type |
77-
| --------- | ------ |
78-
| `ts` | string |
79+
| Parameter | Type |
80+
| --------- | ---- |
81+
| `ts` | string |
7982
| `channel` | string |
8083

84+
85+
8186
## Block Configuration
8287

8388
### Input
8489

85-
| Parameter | Type | Required | Description |
86-
| --------- | ------ | -------- | ------------------------------------------ |
87-
| `apiKey` | string | Yes | OAuth Token - Enter your Slack OAuth token |
90+
| Parameter | Type | Required | Description |
91+
| --------- | ---- | -------- | ----------- |
92+
| `apiKey` | string | Yes | OAuth Token - Enter your Slack OAuth token |
93+
94+
8895

8996
### Outputs
9097

91-
| Output | Type | Description |
92-
| ----------- | ------ | ----------------------- |
93-
| `response` | object | Output from response |
94-
|`ts` | string | ts of the response |
98+
| Output | Type | Description |
99+
| ------ | ---- | ----------- |
100+
| `response` | object | Output from response |
101+
|`ts` | string | ts of the response |
95102
|`channel` | string | channel of the response |
96103

104+
97105
## Notes
98106

99107
- Category: `tools`

docs/content/docs/tools/telegram.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import { BlockInfoCard } from "@/components/ui/block-info-card"
3131
</svg>`}
3232
/>
3333

34+
{/* MANUAL-CONTENT-START:intro */}
3435
[Telegram](https://telegram.org) is a secure, cloud-based messaging platform that enables fast and reliable communication across devices and platforms. With over 700 million monthly active users, Telegram has established itself as one of the world's leading messaging services, known for its security, speed, and powerful API capabilities.
3536

3637
<iframe width="100%" height="400" src="https://www.youtube.com/embed/nhq2Q8fndFg?start=62" title="Use Telegram with Sim Studio" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowFullScreen ></iframe>
@@ -45,6 +46,7 @@ Key features of Telegram include:
4546
- Global Reach: Connect with users worldwide with support for multiple languages and platforms
4647

4748
In Sim Studio, the Telegram integration enables your agents to leverage these powerful messaging capabilities as part of their workflows. This creates opportunities for automated notifications, alerts, and interactive conversations through Telegram's secure messaging platform. The integration allows agents to send messages programmatically to individuals or channels, enabling timely communication and updates. By connecting Sim Studio with Telegram, you can build intelligent agents that engage users through a secure and widely-adopted messaging platform, perfect for delivering notifications, updates, and interactive communications.
49+
{/* MANUAL-CONTENT-END */}
4850

4951
## Usage Instructions
5052

sim/blocks/blocks/google_sheets.ts

Lines changed: 40 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { GoogleSheetsIcon } from '@/components/icons'
22
import {
3+
GoogleSheetsAppendResponse,
34
GoogleSheetsReadResponse,
45
GoogleSheetsUpdateResponse,
56
GoogleSheetsWriteResponse,
@@ -10,13 +11,14 @@ type GoogleSheetsResponse =
1011
| GoogleSheetsReadResponse
1112
| GoogleSheetsWriteResponse
1213
| GoogleSheetsUpdateResponse
14+
| GoogleSheetsAppendResponse
1315

1416
export const GoogleSheetsBlock: BlockConfig<GoogleSheetsResponse> = {
1517
type: 'google_sheets',
1618
name: 'Google Sheets',
1719
description: 'Read, write, and update data',
1820
longDescription:
19-
'Integrate Google Sheets functionality to manage spreadsheet data. Read data from specific ranges, write new data, and update existing cells using OAuth authentication. Supports various input and output formats for flexible data handling.',
21+
'Integrate Google Sheets functionality to manage spreadsheet data. Read data from specific ranges, write new data, update existing cells, and append data to the end of sheets using OAuth authentication. Supports various input and output formats for flexible data handling.',
2022
category: 'tools',
2123
bgColor: '#E0E0E0',
2224
icon: GoogleSheetsIcon,
@@ -31,6 +33,7 @@ export const GoogleSheetsBlock: BlockConfig<GoogleSheetsResponse> = {
3133
{ label: 'Read Data', id: 'read' },
3234
{ label: 'Write Data', id: 'write' },
3335
{ label: 'Update Data', id: 'update' },
36+
{ label: 'Append Data', id: 'append' },
3437
],
3538
},
3639
// Google Sheets Credentials
@@ -113,9 +116,40 @@ export const GoogleSheetsBlock: BlockConfig<GoogleSheetsResponse> = {
113116
],
114117
condition: { field: 'operation', value: 'update' },
115118
},
119+
// Append-specific Fields
120+
{
121+
id: 'values',
122+
title: 'Values',
123+
type: 'long-input',
124+
layout: 'full',
125+
placeholder: 'Enter values as JSON array of arrays (e.g., [["A1", "B1"], ["A2", "B2"]])',
126+
condition: { field: 'operation', value: 'append' },
127+
},
128+
{
129+
id: 'valueInputOption',
130+
title: 'Value Input Option',
131+
type: 'dropdown',
132+
layout: 'full',
133+
options: [
134+
{ label: 'User Entered (Parse formulas)', id: 'USER_ENTERED' },
135+
{ label: "Raw (Don't parse formulas)", id: 'RAW' },
136+
],
137+
condition: { field: 'operation', value: 'append' },
138+
},
139+
{
140+
id: 'insertDataOption',
141+
title: 'Insert Data Option',
142+
type: 'dropdown',
143+
layout: 'full',
144+
options: [
145+
{ label: 'Insert Rows (Add new rows)', id: 'INSERT_ROWS' },
146+
{ label: 'Overwrite (Add to existing data)', id: 'OVERWRITE' },
147+
],
148+
condition: { field: 'operation', value: 'append' },
149+
},
116150
],
117151
tools: {
118-
access: ['google_sheets_read', 'google_sheets_write', 'google_sheets_update'],
152+
access: ['google_sheets_read', 'google_sheets_write', 'google_sheets_update', 'google_sheets_append'],
119153
config: {
120154
tool: (params) => {
121155
switch (params.operation) {
@@ -125,6 +159,8 @@ export const GoogleSheetsBlock: BlockConfig<GoogleSheetsResponse> = {
125159
return 'google_sheets_write'
126160
case 'update':
127161
return 'google_sheets_update'
162+
case 'append':
163+
return 'google_sheets_append'
128164
default:
129165
throw new Error(`Invalid Google Sheets operation: ${params.operation}`)
130166
}
@@ -163,6 +199,7 @@ export const GoogleSheetsBlock: BlockConfig<GoogleSheetsResponse> = {
163199
range: { type: 'string', required: false },
164200
values: { type: 'string', required: false },
165201
valueInputOption: { type: 'string', required: false },
202+
insertDataOption: { type: 'string', required: false },
166203
},
167204
outputs: {
168205
response: {
@@ -173,6 +210,7 @@ export const GoogleSheetsBlock: BlockConfig<GoogleSheetsResponse> = {
173210
updatedRows: 'number',
174211
updatedColumns: 'number',
175212
updatedCells: 'number',
213+
tableRange: 'string',
176214
},
177215
},
178216
},

sim/blocks/registry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import { ClayBlock } from './blocks/clay'
1515
import { ConditionBlock } from './blocks/condition'
1616
import { ConfluenceBlock } from './blocks/confluence'
1717
import { GoogleDocsBlock } from './blocks/google_docs'
18-
import { GoogleDriveBlock } from './blocks/drive'
18+
import { GoogleDriveBlock } from './blocks/google_drive'
1919
import { ElevenLabsBlock } from './blocks/elevenlabs'
2020
import { EvaluatorBlock } from './blocks/evaluator'
2121
import { ExaBlock } from './blocks/exa'

0 commit comments

Comments
 (0)