GraphQL API

Authentication

You must set the HTTP Authorization header to Bearer <license key> to use the REST APIs. For example, if your EqualTo Sheets license key is:

  • 12345679-1234-1234-1234-123456789abc

Then you should set the Authorization header to:

  • Bearer 12345679-1234-1234-1234-123456789abc

See Authentication in production for more information.

List all workbooks

query {
	workbooks {
		id
		name
	}
}

Create a blank workbook

mutation {
	createWorkbook {
		workbook {
			id
			name
		}
	}
}

List the sheets in a specific workbook

query {
	workbook(workbookId: "<workbook id>") {
		id
		name
		sheets {
			name
		}
	}
}

View the contents of A1 in the first sheet of a workbook

query {
   workbook(workbookId: "<workbook id>") {
   	id
   	name
   	sheet(sheetIndex: 1) {
   		cell(ref: "A1") {
   			value {
   				boolean
   				text
   				number
   			}
   			formattedValue
   		}
   	}
   }
}

Set cell A1 in the first sheet of a workbook to "300$"

mutation {
	setCellInput(workbookId:"<workbook id>", sheetIndex: 1, row: 1, col: 1, input: "300$") {
		__typename
	}
}

Notes

The GraphiQL client also contains some auto-generated documentation on the API:

Last updated