> ## Documentation Index
> Fetch the complete documentation index at: https://docs.r28.ai/charter/llms.txt
> Use this file to discover all available pages before exploring further.

# Objects

> Every object and enum the Databases tools accept.

## Model tree

<div className="model-tree"><div className="model-tree-scroll"><div className="tree-node"><a href="#databasecreatebody">DatabaseCreateBody</a><div className="tree-children"><div className="tree-node"><a href="#databaseparent">DatabaseParent</a></div><div className="tree-node"><a href="#initialdatasource">InitialDataSource</a><div className="tree-children"><div className="tree-node"><a href="#propertyconfiguration">PropertyConfiguration</a><div className="tree-children"><div className="tree-node"><a href="#emptyconfig">EmptyConfig</a></div><div className="tree-node"><a href="#numberconfig">NumberConfig</a></div><div className="tree-node"><a href="#selectconfig">SelectConfig</a><div className="tree-children"><div className="tree-node"><a href="#selectoption">SelectOption</a></div></div></div><div className="tree-node"><a href="#statusconfig">StatusConfig</a><div className="tree-children"><div className="tree-node"><a href="#statusoption">StatusOption</a></div></div></div><div className="tree-node"><a href="#formulaconfig">FormulaConfig</a></div><div className="tree-node"><a href="#relationconfig">RelationConfig</a><div className="tree-children"><div className="tree-node"><a href="#singlepropertyrelation">SinglePropertyRelation</a></div><div className="tree-node"><a href="#dualpropertyrelation">DualPropertyRelation</a></div></div></div><div className="tree-node"><a href="#rollupconfig">RollupConfig</a></div><div className="tree-node"><a href="#uniqueidconfig">UniqueIdConfig</a></div></div></div></div></div></div></div><div className="tree-node"><a href="#databaseupdatebody">DatabaseUpdateBody</a><div className="tree-children"><div className="tree-node"><a href="#databaseparent">DatabaseParent</a></div></div></div></div></div>

## DatabaseCreateBody

The body of a create-database request.

<div className="reference-table">
  | Field                                                          | Type                                                        | Description                                                                                                                                  |
  | -------------------------------------------------------------- | ----------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
  | `parent` <span className="required" title="required">\*</span> | [DatabaseParent](#databaseparent)                           | Where the database is created.                                                                                                               |
  | `title`                                                        | [RichText](/charter/charter/packs/notion/pages/objects#richtext)\[] | The title of the database. <span className="field-constraints">max 100 items</span>                                                          |
  | `description`                                                  | [RichText](/charter/charter/packs/notion/pages/objects#richtext)\[] | The description of the database. <span className="field-constraints">max 100 items</span>                                                    |
  | `isInline`                                                     | `boolean`                                                   | Whether the database renders inside its parent page rather than as a page of its own. Not inline when absent.                                |
  | `initialDataSource`                                            | [InitialDataSource](#initialdatasource)                     | The first data source, and the columns it starts with.                                                                                       |
  | `databaseType`                                                 | `"tasks" \| "projects" \| "skills"`                         | Create a database with Notion's canonical schema for tasks, projects or skills. When `title` is absent the database is named after the type. |
  | `icon`                                                         | [Icon](/charter/charter/packs/notion/pages/objects#icon)            | The database's icon.                                                                                                                         |
  | `cover`                                                        | [Cover](/charter/charter/packs/notion/pages/objects#cover)          | The database's cover image.                                                                                                                  |
</div>

## DatabaseParent

Where a database lives.

<div className="reference-table">
  | Field       | Type                       | Description                                                            |
  | ----------- | -------------------------- | ---------------------------------------------------------------------- |
  | `type`      | `"page_id" \| "workspace"` | The type of parent.                                                    |
  | `pageId`    | `string`                   | The ID of the parent page.                                             |
  | `workspace` | `boolean`                  | Always true, to create the database at the top level of the workspace. |
</div>

## InitialDataSource

The first data source created alongside a new database.

<div className="reference-table">
  | Field                                                              | Type                                                   | Description                                                                                  |
  | ------------------------------------------------------------------ | ------------------------------------------------------ | -------------------------------------------------------------------------------------------- |
  | `properties` <span className="required" title="required">\*</span> | map of [PropertyConfiguration](#propertyconfiguration) | The columns of the first data source, keyed by name. Exactly one must be the `title` column. |
</div>

## PropertyConfiguration

One column of a data source.

<div className="reference-table">
  | Field             | Type                              | Description                                                                                                              |
  | ----------------- | --------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
  | `type`            | `string`                          | The type of the column. Returned on a read; on a write Notion infers it from whichever configuration field below is set. |
  | `description`     | `string`                          | The description of the property. <span className="field-constraints">max length 280</span>                               |
  | `title`           | [EmptyConfig](#emptyconfig)       | The title column. Every data source has exactly one, and it cannot be deleted. Send an empty object.                     |
  | `richText`        | [EmptyConfig](#emptyconfig)       | A text column. Send an empty object.                                                                                     |
  | `number`          | [NumberConfig](#numberconfig)     | A number column.                                                                                                         |
  | `select`          | [SelectConfig](#selectconfig)     | A single-choice column.                                                                                                  |
  | `multiSelect`     | [SelectConfig](#selectconfig)     | A multiple-choice column.                                                                                                |
  | `status`          | [StatusConfig](#statusconfig)     | A status column, whose options belong to three groups.                                                                   |
  | `date`            | [EmptyConfig](#emptyconfig)       | A date column. Send an empty object.                                                                                     |
  | `people`          | [EmptyConfig](#emptyconfig)       | A people column. Send an empty object.                                                                                   |
  | `files`           | [EmptyConfig](#emptyconfig)       | A files column. Send an empty object.                                                                                    |
  | `checkbox`        | [EmptyConfig](#emptyconfig)       | A checkbox column. Send an empty object.                                                                                 |
  | `url`             | [EmptyConfig](#emptyconfig)       | A URL column. Send an empty object.                                                                                      |
  | `email`           | [EmptyConfig](#emptyconfig)       | An email column. Send an empty object.                                                                                   |
  | `phoneNumber`     | [EmptyConfig](#emptyconfig)       | A phone number column. Send an empty object.                                                                             |
  | `formula`         | [FormulaConfig](#formulaconfig)   | A column computed from the page's other properties.                                                                      |
  | `relation`        | [RelationConfig](#relationconfig) | A column of links to pages in another data source.                                                                       |
  | `rollup`          | [RollupConfig](#rollupconfig)     | A column that gathers values through a relation.                                                                         |
  | `createdTime`     | [EmptyConfig](#emptyconfig)       | When the page was created. Send an empty object.                                                                         |
  | `createdBy`       | [EmptyConfig](#emptyconfig)       | Who created the page. Send an empty object.                                                                              |
  | `lastEditedTime`  | [EmptyConfig](#emptyconfig)       | When the page was last edited. Send an empty object.                                                                     |
  | `lastEditedBy`    | [EmptyConfig](#emptyconfig)       | Who last edited the page. Send an empty object.                                                                          |
  | `lastVisitedTime` | [EmptyConfig](#emptyconfig)       | When the page was last visited. Send an empty object.                                                                    |
  | `uniqueId`        | [UniqueIdConfig](#uniqueidconfig) | An ID Notion increments for each new page.                                                                               |
  | `verification`    | [EmptyConfig](#emptyconfig)       | A wiki page's verification status. Send an empty object.                                                                 |
  | `button`          | [EmptyConfig](#emptyconfig)       | A button column. Send an empty object.                                                                                   |
  | `location`        | [EmptyConfig](#emptyconfig)       | A location column. Send an empty object.                                                                                 |
  | `place`           | [EmptyConfig](#emptyconfig)       | A place column. Send an empty object.                                                                                    |
</div>

## EmptyConfig

A column type with nothing to configure.

This object has no settable fields.

## NumberConfig

How a number column is displayed.

<div className="reference-table">
  | Field    | Type     | Description                                                                                                                                                                                                                                                |
  | -------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | `format` | `string` | How the number is formatted — `number`, `number_with_commas`, `percent`, `dollar`, `euro`, `pound`, `yen` and the other currency codes Notion supports. The API declares this an open string rather than a fixed set, so a format added later is accepted. |
</div>

## SelectConfig

The options of a select or multi-select column.

<div className="reference-table">
  | Field     | Type                             | Description                                                                     |
  | --------- | -------------------------------- | ------------------------------------------------------------------------------- |
  | `options` | [SelectOption](#selectoption)\[] | The available options. <span className="field-constraints">max 100 items</span> |
</div>

## SelectOption

One option of a select or multi-select column.

<div className="reference-table">
  | Field         | Type                        | Description                                                            |
  | ------------- | --------------------------- | ---------------------------------------------------------------------- |
  | `name`        | `string`                    | The name of the option, as it appears in Notion.                       |
  | `id`          | `string`                    | The ID of an existing option, when updating it rather than adding one. |
  | `color`       | [SelectColor](#selectcolor) | The color of the option.                                               |
  | `description` | `string`                    | The description of the option.                                         |
</div>

## StatusConfig

The options of a status column.

<div className="reference-table">
  | Field     | Type                             | Description                                                                     |
  | --------- | -------------------------------- | ------------------------------------------------------------------------------- |
  | `options` | [StatusOption](#statusoption)\[] | The available options. <span className="field-constraints">max 100 items</span> |
</div>

## StatusOption

One option of a status column, which also belongs to a group.

<div className="reference-table">
  | Field         | Type                                     | Description                                                            |
  | ------------- | ---------------------------------------- | ---------------------------------------------------------------------- |
  | `name`        | `string`                                 | The name of the option, as it appears in Notion.                       |
  | `id`          | `string`                                 | The ID of an existing option, when updating it rather than adding one. |
  | `color`       | [SelectColor](#selectcolor)              | The color of the option.                                               |
  | `description` | `string`                                 | The description of the option.                                         |
  | `group`       | `"To-do" \| "In progress" \| "Complete"` | Which of the three status groups this option belongs to.               |
</div>

## FormulaConfig

The expression a formula column evaluates.

<div className="reference-table">
  | Field        | Type     | Description                                |
  | ------------ | -------- | ------------------------------------------ |
  | `expression` | `string` | The formula, in Notion's formula language. |
</div>

## RelationConfig

Which data source a relation column points at, and whether it is mirrored.

<div className="reference-table">
  | Field                                                                | Type                                              | Description                                                                                  |
  | -------------------------------------------------------------------- | ------------------------------------------------- | -------------------------------------------------------------------------------------------- |
  | `dataSourceId` <span className="required" title="required">\*</span> | `string`                                          | The ID of the data source the relation points at.                                            |
  | `type`                                                               | `"single_property" \| "dual_property"`            | Whether the relation is mirrored on the other data source.                                   |
  | `singleProperty`                                                     | [SinglePropertyRelation](#singlepropertyrelation) | A one-way relation, which adds no property to the related data source. Send an empty object. |
  | `dualProperty`                                                       | [DualPropertyRelation](#dualpropertyrelation)     | A two-way relation, mirrored by a property on the related data source.                       |
</div>

## SinglePropertyRelation

A relation that does not show up on the related data source.

This object has no settable fields.

## DualPropertyRelation

A relation mirrored by a property on the related data source.

<div className="reference-table">
  | Field                | Type     | Description                                                   |
  | -------------------- | -------- | ------------------------------------------------------------- |
  | `syncedPropertyId`   | `string` | The ID of the mirrored property on the related data source.   |
  | `syncedPropertyName` | `string` | The name of the mirrored property on the related data source. |
</div>

## RollupConfig

What a rollup column gathers and how it aggregates it.

<div className="reference-table">
  | Field                                                            | Type     | Description                                                                                                                                                                                                                                                                                                                                                                       |
  | ---------------------------------------------------------------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | `function` <span className="required" title="required">\*</span> | `string` | How the gathered values are aggregated: `count`, `count_values`, `empty`, `not_empty`, `unique`, `show_unique`, `percent_empty`, `percent_not_empty`, `sum`, `average`, `median`, `min`, `max`, `range`, `earliest_date`, `latest_date`, `date_range`, `checked`, `unchecked`, `percent_checked`, `percent_unchecked`, `count_per_group`, `percent_per_group` or `show_original`. |
  | `relationPropertyName`                                           | `string` | The name of the relation column to follow.                                                                                                                                                                                                                                                                                                                                        |
  | `relationPropertyId`                                             | `string` | The ID of the relation column to follow.                                                                                                                                                                                                                                                                                                                                          |
  | `rollupPropertyName`                                             | `string` | The name of the property to gather from the related pages.                                                                                                                                                                                                                                                                                                                        |
  | `rollupPropertyId`                                               | `string` | The ID of the property to gather from the related pages.                                                                                                                                                                                                                                                                                                                          |
</div>

## UniqueIdConfig

The prefix shown before an auto-incrementing ID.

<div className="reference-table">
  | Field    | Type     | Description                                                    |
  | -------- | -------- | -------------------------------------------------------------- |
  | `prefix` | `string` | The prefix, for example `RC` to produce `RC-1`. Null for none. |
</div>

## DatabaseUpdateBody

The body of an update-database request.

<div className="reference-table">
  | Field         | Type                                                        | Description                                                                                                 |
  | ------------- | ----------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
  | `parent`      | [DatabaseParent](#databaseparent)                           | A new parent, to move the database.                                                                         |
  | `title`       | [RichText](/charter/charter/packs/notion/pages/objects#richtext)\[] | The title of the database. <span className="field-constraints">max 100 items</span>                         |
  | `description` | [RichText](/charter/charter/packs/notion/pages/objects#richtext)\[] | The description of the database. <span className="field-constraints">max 100 items</span>                   |
  | `isInline`    | `boolean`                                                   | Whether the database renders inside its parent page.                                                        |
  | `icon`        | [Icon](/charter/charter/packs/notion/pages/objects#icon)            | The database's icon.                                                                                        |
  | `cover`       | [Cover](/charter/charter/packs/notion/pages/objects#cover)          | The database's cover image.                                                                                 |
  | `inTrash`     | `boolean`                                                   | Whether the database is in the trash. False restores it.                                                    |
  | `isLocked`    | `boolean`                                                   | Whether the database is locked against editing in the Notion app. It does not block writes through the API. |
</div>

## SelectColor

<div className="enum-table">
  | Value     |
  | --------- |
  | `default` |
  | `blue`    |
  | `brown`   |
  | `gray`    |
  | `green`   |
  | `orange`  |
  | `pink`    |
  | `purple`  |
  | `red`     |
  | `yellow`  |
</div>
