Integrations / Smartsheet
Smartsheet
Work management in spreadsheet form: sheets, rows, cells and row comments.
8 actions
OAuth 2
4 read3 write1 destructive
Calls api.smartsheet.com
Connect
const conn = await setu.connections.initiate({ userId: "user_1", toolkit: "smartsheet" });
console.log(conn.connectUrl); // show this to your user
await conn.waitUntilActive();Permissions requested
| Scope | Why it is requested |
|---|---|
READ_SHEETS | Read your sheets, rows and cells, and search them |
WRITE_SHEETS | Add, change and delete rows, and comment on rows |
Actions
Add rowswritesmartsheet.add_rowsAdd one or more rows to a sheet. Each row is an object with cells (columnId and value) and optionally toTop or toBottom (true) to choose the position.
Needs scope: WRITE_SHEETS
| Input | Type | Description | |
|---|---|---|---|
sheet_id | integer | Required | Sheet ID |
rows | array of object | Required | Rows to add: [{"toBottom": true, "cells": [{"columnId": 123, "value": "text"}]}] |
await setu.execute({
userId: "user_1",
action: "smartsheet.add_rows",
input: {
"sheet_id": 1,
"rows": []
},
});Comment on rowwritesmartsheet.comment_on_rowStart a discussion on a row with a first comment.
Needs scope: WRITE_SHEETS
| Input | Type | Description | |
|---|---|---|---|
sheet_id | integer | Required | Sheet ID |
row_id | integer | Required | Row ID |
text | string | Required | Comment text |
await setu.execute({
userId: "user_1",
action: "smartsheet.comment_on_row",
input: {
"sheet_id": 1,
"row_id": 1,
"text": "<text>"
},
});Delete rowsdestructivesmartsheet.delete_rowsPermanently delete rows from a sheet by row ID.
Needs scope: WRITE_SHEETS
| Input | Type | Description | |
|---|---|---|---|
sheet_id | integer | Required | Sheet ID |
row_ids | array of integer | Required | IDs of the rows to delete |
await setu.execute({
userId: "user_1",
action: "smartsheet.delete_rows",
input: {
"sheet_id": 1,
"row_ids": []
},
confirm: true,
});Get current userreadsmartsheet.get_current_userGet the connected Smartsheet user's ID, name, email and account.
No input.
await setu.execute({
userId: "user_1",
action: "smartsheet.get_current_user",
input: {},
});Get sheetreadsmartsheet.get_sheetGet a sheet's columns (IDs, titles, types) and rows with cell values. Use page_size to limit rows, and the column IDs it returns to add or update rows.
Needs scope: READ_SHEETS
| Input | Type | Description | |
|---|---|---|---|
sheet_id | integer | Required | Sheet ID from list_sheets or search |
page | integer | Optional | Page of rows, starting at 1 |
page_size | integer | Optional | Rows per page |
column_ids | array of integer | Optional | Only return these columns |
row_ids | array of integer | Optional | Only return these rows |
await setu.execute({
userId: "user_1",
action: "smartsheet.get_sheet",
input: {
"sheet_id": 1
},
});List sheetsreadsmartsheet.list_sheetsList the sheets the user can access with their IDs, names and links. Returns one page (100 sheets by default).
Needs scope: READ_SHEETS
| Input | Type | Description | |
|---|---|---|---|
page | integer | Optional | Page number, starting at 1 |
page_size | integer | Optional | Sheets per page (default 100) |
await setu.execute({
userId: "user_1",
action: "smartsheet.list_sheets",
input: {},
});Search sheetsreadsmartsheet.searchSearch all sheets the user can access for some text (sheet names, cell data, comments and more). Returns matching excerpts with the object type and ID.
Needs scope: READ_SHEETS
| Input | Type | Description | |
|---|---|---|---|
query | string | Required | Text to search for; wrap in double quotes for an exact match |
await setu.execute({
userId: "user_1",
action: "smartsheet.search",
input: {
"query": "<query>"
},
});Update rowswritesmartsheet.update_rowsChange cell values in existing rows. Each row is an object with the row id and the cells (columnId and value) to change.
Needs scope: WRITE_SHEETS
| Input | Type | Description | |
|---|---|---|---|
sheet_id | integer | Required | Sheet ID |
rows | array of object | Required | Rows to update: [{"id": 456, "cells": [{"columnId": 123, "value": "new"}]}] |
await setu.execute({
userId: "user_1",
action: "smartsheet.update_rows",
input: {
"sheet_id": 1,
"rows": []
},
});