Skip to main content
GridOS organises your data into a workbook that contains one or more named sheets. The endpoints on this page let you inspect the current workbook state and perform structural operations — creating sheets, renaming them, switching which one is active, and renaming the workbook itself. None of these operations touch cell data.

GET /api/workbook

Retrieve the current workbook’s name, the list of all sheet names, and which sheet is currently active. Use this to sync your client state before making structural changes.

Response

string
The display name of the open workbook.
string
The name of the sheet that is currently active.
array of strings
Ordered list of all sheet names in the workbook.

Example

Response

POST /workbook/sheet

Create a new sheet in the workbook. If you omit name, GridOS generates one automatically (e.g. Sheet2). The new sheet is added to the end of the sheet list but does not become the active sheet automatically.

Request

string
The desired name for the new sheet. Must be unique within the workbook. If omitted, a name is auto-generated.

Response

string
The name of the newly created sheet.
array of strings
Updated ordered list of all sheet names.
string
The sheet that is currently active (unchanged by this call).

Example

Response

POST /workbook/sheet/rename

Rename an existing sheet. All internal references and chart associations follow the rename automatically.

Request

string
required
The current name of the sheet to rename.
string
required
The replacement name. Must be unique within the workbook.

Response

string
The new name of the renamed sheet.
array of strings
Updated ordered list of all sheet names.
string
The currently active sheet (updated to the new name if the active sheet was renamed).

Example

Response

POST /workbook/sheet/activate

Switch the active sheet. Subsequent agent calls and grid reads that do not specify a sheet parameter will target this sheet.

Request

string
required
The name of the sheet to make active. The sheet must already exist.

Response

string
The name of the now-active sheet.
array of strings
Current ordered list of all sheet names.
string
The name of the active sheet (same as sheet).

Example

Response
Activating a sheet does not modify any cell data. It only changes the default target for subsequent API calls that omit the sheet parameter.

POST /workbook/rename

Rename the workbook itself. The new name is reflected in file exports and the workbook UI header.

Request

string
required
The new display name for the workbook. Must be a non-empty string.

Response

string
The updated workbook name.

Errors

Example

Response