Sheet
A sheet in a spreadsheet.
JSON representation |
---|
{ "properties": { object ( |
Fields | |
---|---|
properties
|
The properties of the sheet. |
data[]
|
Data in the grid, if this is a grid sheet.
The number of GridData objects returned is dependent on the number of ranges requested on this sheet. For example, if this is representing
For a
|
merges[]
|
The ranges that are merged together. |
conditionalFormats[]
|
The conditional format rules in this sheet. |
filterViews[]
|
The filter views in this sheet. |
protectedRanges[]
|
The protected ranges in this sheet. |
basicFilter
|
The filter on this sheet, if any. |
charts[]
|
The specifications of every chart on this sheet. |
bandedRanges[]
|
The banded (alternating colors) ranges on this sheet. |
developerMetadata[]
|
The developer metadata associated with a sheet. |
rowGroups[]
|
All row groups on this sheet, ordered by increasing range start index, then by group depth. |
columnGroups[]
|
All column groups on this sheet, ordered by increasing range start index, then by group depth. |
slicers[]
|
The slicers on this sheet. |
SheetProperties
Properties of a sheet.
JSON representation |
---|
{ "sheetId": integer, "title": string, "index": integer, "sheetType": enum ( |
Fields | |
---|---|
sheetId
|
The ID of the sheet. Must be non-negative. This field cannot be changed once set. |
title
|
The name of the sheet. |
index
|
The index of the sheet within the spreadsheet. When adding or updating sheet properties, if this field is excluded then the sheet is added or moved to the end of the sheet list. When updating sheet indices or inserting sheets, movement is considered in "before the move" indexes. For example, if there were three sheets (S1, S2, S3) in order to move S1 ahead of S2 the index would have to be set to 2. A sheet index update request is ignored if the requested index is identical to the sheets current index or if the requested new index is equal to the current sheet index + 1. |
sheetType
|
The type of sheet. Defaults to
|
gridProperties
|
Additional properties of the sheet if this sheet is a grid. (If the sheet is an object sheet, containing a chart or image, then this field will be absent.) When writing it is an error to set any grid properties on non-grid sheets.
If this sheet is a
|
tabColor
|
The color of the tab in the UI. Deprecated: Use
|
tabColorStyle
|
The color of the tab in the UI. If
|
rightToLeft
|
True if the sheet is an RTL sheet instead of an LTR sheet. |
dataSourceSheetProperties
|
Output only. If present, the field contains
|
SheetType
The kind of sheet.
Enums | |
---|---|
SHEET_TYPE_UNSPECIFIED
|
Default value, do not use. |
GRID
|
The sheet is a grid. |
OBJECT
|
The sheet has no grid and instead has an object like a chart or image. |
DATA_SOURCE
|
The sheet connects with an external
DataSource
and shows the preview of data.
|
GridProperties
Properties of a grid.
JSON representation |
---|
{ "rowCount": integer, "columnCount": integer, "frozenRowCount": integer, "frozenColumnCount": integer, "hideGridlines": boolean, "rowGroupControlAfter": boolean, "columnGroupControlAfter": boolean } |
Fields | |
---|---|
rowCount
|
The number of rows in the grid. |
columnCount
|
The number of columns in the grid. |
frozenRowCount
|
The number of rows that are frozen in the grid. |
frozenColumnCount
|
The number of columns that are frozen in the grid. |
hideGridlines
|
True if the grid isn't showing gridlines in the UI. |
rowGroupControlAfter
|
True if the row grouping control toggle is shown after the group. |
columnGroupControlAfter
|
True if the column grouping control toggle is shown after the group. |
DataSourceSheetProperties
Additional properties of a
DATA_SOURCE
sheet.
JSON representation |
---|
{ "dataSourceId": string, "columns": [ { object ( |
Fields | |
---|---|
dataSourceId
|
ID of the
|
columns[]
|
The columns displayed on the sheet, corresponding to the values in
|
dataExecutionStatus
|
The data execution status. |
GridData
Data in the grid, as well as metadata about the dimensions.
JSON representation |
---|
{ "startRow": integer, "startColumn": integer, "rowData": [ { object ( |
Fields | |
---|---|
startRow
|
The first row this GridData refers to, zero-based. |
startColumn
|
The first column this GridData refers to, zero-based. |
rowData[]
|
The data in the grid, one entry per row, starting with the row in startRow. The values in RowData will correspond to columns starting at
|
rowMetadata[]
|
Metadata about the requested rows in the grid, starting with the row in
|
columnMetadata[]
|
Metadata about the requested columns in the grid, starting with the column in
|
RowData
Data about each cell in a row.
JSON representation |
---|
{
"values": [
{
object (
|
Fields | |
---|---|
values[]
|
The values in the row, one per column. |
DimensionProperties
Properties about a dimension.
JSON representation |
---|
{ "hiddenByFilter": boolean, "hiddenByUser": boolean, "pixelSize": integer, "developerMetadata": [ { object ( |
Fields | |
---|---|
pixelSize
|
The height (if a row) or width (if a column) of the dimension in pixels. |
developerMetadata[]
|
The developer metadata associated with a single row or column. |
dataSourceColumnReference
|
Output only. If set, this is a column in a data source sheet. |
ConditionalFormatRule
A rule describing a conditional format.
JSON representation |
---|
{ "ranges": [ { object ( |
Fields | |
---|---|
ranges[]
|
The ranges that are formatted if the condition is true. All the ranges must be on the same grid. |
Union field
rule . The rule controlling this conditional format, exactly one must be set.
rule
can be only one of the following:
|
|
booleanRule
|
The formatting is either "on" or "off" according to the rule. |
gradientRule
|
The formatting will vary based on the gradients in the rule. |
BooleanRule
A rule that may or may not match, depending on the condition.
JSON representation |
---|
{ "condition": { object ( |
Fields | |
---|---|
condition
|
The condition of the rule. If the condition evaluates to true, the format is applied. |
format
|
The format to apply. Conditional formatting can only apply a subset of formatting:
|
GradientRule
A rule that applies a gradient color scale format, based on the interpolation points listed. The format of a cell will vary based on its contents as compared to the values of the interpolation points.
JSON representation |
---|
{ "minpoint": { object ( |
Fields | |
---|---|
minpoint
|
The starting interpolation point. |
midpoint
|
An optional midway interpolation point. |
maxpoint
|
The final interpolation point. |
InterpolationPoint
A single interpolation point on a gradient conditional format. These pin the gradient color scale according to the color, type and value chosen.
JSON representation |
---|
{ "color": { object ( |
Fields | |
---|---|
color
|
The color this interpolation point should use. Deprecated: Use
|
colorStyle
|
The color this interpolation point should use. If
|
type
|
How the value should be interpreted. |
value
|
The value this interpolation point uses. May be a formula. Unused if
|
InterpolationPointType
The kind of interpolation point.
Enums | |
---|---|
INTERPOLATION_POINT_TYPE_UNSPECIFIED
|
The default value, do not use. |
MIN
|
The interpolation point uses the minimum value in the cells over the range of the conditional format. |
MAX
|
The interpolation point uses the maximum value in the cells over the range of the conditional format. |
NUMBER
|
The interpolation point uses exactly the value in
InterpolationPoint.value .
|
PERCENT
|
The interpolation point is the given percentage over all the cells in the range of the conditional format. This is equivalent to
|
PERCENTILE
|
The interpolation point is the given percentile over all the cells in the range of the conditional format. This is equivalent to
NUMBER
if the value was:
=PERCENTILE(FLATTEN(range), value / 100)
(where errors in the range are ignored when flattening).
|
FilterView
A filter view.
JSON representation |
---|
{ "filterViewId": integer, "title": string, "range": { object ( |
Fields | |
---|---|
filterViewId
|
The ID of the filter view. |
title
|
The name of the filter view. |
range
|
The range this filter view covers.
When writing, only one of
|
namedRangeId
|
The named range this filter view is backed by, if any.
When writing, only one of
|
sortSpecs[]
|
The sort order per column. Later specifications are used when values are equal in the earlier specifications. |
criteria
|
The criteria for showing/hiding values per column. The map's key is the column index, and the value is the criteria for that column.
This field is deprecated in favor of
|
filterSpecs[]
|
The filter criteria for showing/hiding values per column.
Both
|
ProtectedRange
A protected range.
JSON representation |
---|
{ "protectedRangeId": integer, "range": { object ( |
Fields | |
---|---|
protectedRangeId
|
The ID of the protected range. This field is read-only. |
range
|
The range that is being protected. The range may be fully unbounded, in which case this is considered a protected sheet.
When writing, only one of
|
namedRangeId
|
The named range this protected range is backed by, if any.
When writing, only one of
|
description
|
The description of this protected range. |
warningOnly
|
True if this protected range will show a warning when editing. Warning-based protection means that every user can edit data in the protected range, except editing will prompt a warning asking the user to confirm the edit.
When writing: if this field is true, then
|
requestingUserCanEdit
|
True if the user who requested this protected range can edit the protected area. This field is read-only. |
unprotectedRanges[]
|
The list of unprotected ranges within a protected sheet. Unprotected ranges are only supported on protected sheets. |
editors
|
The users and groups with edit access to the protected range. This field is only visible to users with edit access to the protected range and the document. Editors are not supported with
|
Editors
The editors of a protected range.
JSON representation |
---|
{ "users": [ string ], "groups": [ string ], "domainUsersCanEdit": boolean } |
Fields | |
---|---|
users[]
|
The email addresses of users with edit access to the protected range. |
groups[]
|
The email addresses of groups with edit access to the protected range. |
domainUsersCanEdit
|
True if anyone in the document's domain has edit access to the protected range. Domain protection is only supported on documents within a domain. |
BasicFilter
The default filter associated with a sheet.
JSON representation |
---|
{ "range": { object ( |
Fields | |
---|---|
range
|
The range the filter covers. |
sortSpecs[]
|
The sort order per column. Later specifications are used when values are equal in the earlier specifications. |
criteria
|
The criteria for showing/hiding values per column. The map's key is the column index, and the value is the criteria for that column.
This field is deprecated in favor of
|
filterSpecs[]
|
The filter criteria per column.
Both
|
BandedRange
A banded (alternating colors) range in a sheet.
JSON representation |
---|
{ "bandedRangeId": integer, "range": { object ( |
Fields | |
---|---|
bandedRangeId
|
The ID of the banded range. |
range
|
The range over which these properties are applied. |
rowProperties
|
Properties for row bands. These properties are applied on a row-by-row basis throughout all the rows in the range. At least one of
|
columnProperties
|
Properties for column bands. These properties are applied on a column- by-column basis throughout all the columns in the range. At least one of
|
BandingProperties
Properties referring a single dimension (either row or column). If both
BandedRange.row_properties
and
BandedRange.column_properties
are set, the fill colors are applied to cells according to the following rules:
-
headerColor
andfooterColor
take priority over band colors. -
firstBandColor
takes priority oversecondBandColor
. -
rowProperties
takes priority overcolumnProperties
.
For example, the first row color takes priority over the first column color, but the first column color takes priority over the second row color. Similarly, the row header takes priority over the column header in the top left cell, but the column header takes priority over the first row color if the row header is not set.
JSON representation |
---|
{ "headerColor": { object ( |
Fields | |
---|---|
headerColor
|
The color of the first row or column. If this field is set, the first row or column is filled with this color and the colors alternate between
|
headerColorStyle
|
The color of the first row or column. If this field is set, the first row or column is filled with this color and the colors alternate between
|
firstBandColor
|
The first color that is alternating. (Required) Deprecated: Use
|
firstBandColorStyle
|
The first color that is alternating. (Required) If
|
secondBandColor
|
The second color that is alternating. (Required) Deprecated: Use
|
secondBandColorStyle
|
The second color that is alternating. (Required) If
|
footerColor
|
The color of the last row or column. If this field is not set, the last row or column is filled with either
|
footerColorStyle
|
The color of the last row or column. If this field is not set, the last row or column is filled with either
|
DimensionGroup
A group over an interval of rows or columns on a sheet, which can contain or be contained within other groups. A group can be collapsed or expanded as a unit on the sheet.
JSON representation |
---|
{
"range": {
object (
|
Fields | |
---|---|
range
|
The range over which this group exists. |
depth
|
The depth of the group, representing how many groups have a range that wholly contains the range of this group. |
collapsed
|
This field is true if this group is collapsed. A collapsed group remains collapsed if an overlapping group at a shallower depth is expanded. A true value does not imply that all dimensions within the group are hidden, since a dimension's visibility can change independently from this group property. However, when this property is updated, all dimensions within it are set to hidden if this field is true, or set to visible if this field is false. |
Slicer
A slicer in a sheet.
JSON representation |
---|
{ "slicerId": integer, "spec": { object ( |
Fields | |
---|---|
slicerId
|
The ID of the slicer. |
spec
|
The specification of the slicer. |
position
|
The position of the slicer. Note that slicer can be positioned only on existing sheet. Also, width and height of slicer can be automatically adjusted to keep it within permitted limits. |
SlicerSpec
The specifications of a slicer.
JSON representation |
---|
{ "dataRange": { object ( |
Fields | |
---|---|
dataRange
|
The data range of the slicer. |
filterCriteria
|
The filtering criteria of the slicer. |
columnIndex
|
The zero-based column index in the data table on which the filter is applied to. |
applyToPivotTables
|
True if the filter should apply to pivot tables. If not set, default to
|
title
|
The title of the slicer. |
textFormat
|
The text format of title in the slicer. The link field is not supported. |
backgroundColor
|
The background color of the slicer. Deprecated: Use
|
backgroundColorStyle
|
The background color of the slicer. If
|
horizontalAlignment
|
The horizontal alignment of title in the slicer. If unspecified, defaults to
|