Schema
schema ¶
Objects representing a data source schema.
Properties are used when
Unfortunately, the way a schema is defined in case of 1. and 2. is not consistent. In case 1., the property name is only defined as a key while in case 2. it is additionally defined as name attribute of the property object. We treat these two cases the same way when constructing the property objects. For this reason name is Unset by default.
GO_co = TypeVar('GO_co', bound=GenericObject, covariant=True, default=GenericObject) module-attribute ¶
Button ¶
Button data source property.
button: ButtonTypeData = Field(default_factory=ButtonTypeData) class-attribute instance-attribute ¶
ButtonTypeData ¶
Type data for Button.
Checkbox ¶
Defines the checkbox configuration for a data source property.
checkbox: CheckboxTypeData = Field(default_factory=CheckboxTypeData) class-attribute instance-attribute ¶
CheckboxTypeData ¶
Type data for Checkbox.
CreatedBy ¶
Defines the created-by configuration for a data source property.
created_by: CreatedByTypeData = Field(default_factory=CreatedByTypeData) class-attribute instance-attribute ¶
CreatedByTypeData ¶
Type data for CreatedBy.
CreatedTime ¶
Defines the created-time configuration for a data source property.
created_time: CreatedTimeTypeData = Field(default_factory=CreatedTimeTypeData) class-attribute instance-attribute ¶
CreatedTimeTypeData ¶
Type data for CreatedTime.
Date ¶
Defines the date configuration for a data source property.
date: DateTypeData = Field(default_factory=DateTypeData) class-attribute instance-attribute ¶
DateTypeData ¶
Type data for Date.
DualPropertyRelation ¶
Defines a two-way relation configuration for a data source property.
If a two-way relation property X relates to Y then the two-way relation property Y relates to X.
DualPropertyRelationTypeData ¶
Email ¶
Defines the email configuration for a data source property.
email: EmailTypeData = Field(default_factory=EmailTypeData) class-attribute instance-attribute ¶
EmailTypeData ¶
Type data for Email.
Files ¶
Defines the files configuration for a data source property.
files: FilesTypeData = Field(default_factory=FilesTypeData) class-attribute instance-attribute ¶
FilesTypeData ¶
Type data for Files.
Formula ¶
FormulaTypeData ¶
LastEditedBy ¶
Defines the last-edited-by configuration for a data source property.
last_edited_by: LastEditedByTypeData = Field(default_factory=LastEditedByTypeData) class-attribute instance-attribute ¶
LastEditedByTypeData ¶
Type data for LastEditedBy.
LastEditedTime ¶
Defines the last-edited-time configuration for a data source property.
last_edited_time: LastEditedTimeTypeData = Field(default_factory=LastEditedTimeTypeData) class-attribute instance-attribute ¶
LastEditedTimeTypeData ¶
Type data for LastEditedTime.
MultiSelect ¶
Defines the multi-select configuration for a data source property.
MultiSelectTypeData ¶
Type data for MultiSelect.
options: list[SelectOption] = Field(default_factory=list) class-attribute instance-attribute ¶
Number ¶
NumberTypeData ¶
People ¶
Defines the people configuration for a data source property.
people: PeopleTypeData = Field(default_factory=PeopleTypeData) class-attribute instance-attribute ¶
PeopleTypeData ¶
Type data for People.
PhoneNumber ¶
Defines the phone number configuration for a data source property.
phone_number: PhoneNumberTypeData = Field(default_factory=PhoneNumberTypeData) class-attribute instance-attribute ¶
PhoneNumberTypeData ¶
Type data for PhoneNumber.
Place ¶
Defines the place configuration for a data source property.
place: PlaceTypeData = Field(default_factory=PlaceTypeData) class-attribute instance-attribute ¶
PlaceTypeData ¶
Type data for Place.
Property ¶
PropertyRelation ¶
Defines common configuration for a property relation.
In API 2025-09-03+, relations primarily use data_source_id to reference the target data source. The database_id field references the parent database container.
Relation ¶
Defines the relation configuration for a data source property.
relation: SinglePropertyRelation | DualPropertyRelation instance-attribute ¶
RenameProp ¶
Property to rename a property during a data source update.
name: str instance-attribute ¶
RichText ¶
Defines the rich text configuration for a data source property.
rich_text: RichTextTypeData = Field(default_factory=RichTextTypeData) class-attribute instance-attribute ¶
RichTextTypeData ¶
Type data for RichText.
Rollup ¶
RollupTypeData ¶
Type data for Rollup.
function: AggFunc = AggFunc.COUNT_ALL class-attribute instance-attribute ¶
relation_property_id: str | UnsetType = Unset class-attribute instance-attribute ¶
relation_property_name: str instance-attribute ¶
rollup_property_id: str | UnsetType = Unset class-attribute instance-attribute ¶
rollup_property_name: str instance-attribute ¶
__eq__(other: object) -> bool ¶
Compare Rollup objects by all attributes except id.
validate_enum_field(field: str) -> AggFunc classmethod ¶
Select ¶
SelectTypeData ¶
Type data for Select.
options: list[SelectOption] = Field(default_factory=list) class-attribute instance-attribute ¶
SinglePropertyRelation ¶
Defines a one-way relation configuration for a data source property.
single_property: SinglePropertyRelationTypeData = Field(default_factory=SinglePropertyRelationTypeData) class-attribute instance-attribute ¶
build_relation(dsref: UUID) -> Relation classmethod ¶
Create a single_property relation using the target data source reference.
dsref must be either a string or UUID.
SinglePropertyRelationTypeData ¶
Type data for SinglePropertyRelation.
Status ¶
Defines the status configuration for a data source property.
status: StatusTypeData = Field(default_factory=StatusTypeData) class-attribute instance-attribute ¶
build(options: list[SelectOption], groups: list[SelectGroup]) -> Status classmethod ¶
Create a Status object from the list of SelectOption's.
Warning
While a Status property can be built, it can only be used to check a schema, not to create a data source having such a property.
StatusTypeData ¶
Title ¶
Defines the title configuration for a data source property.
title: TitleTypeData = Field(default_factory=TitleTypeData) class-attribute instance-attribute ¶
TitleTypeData ¶
Type data for Title.
URL ¶
Defines the URL configuration for a data source property.
url: URLTypeData = Field(default_factory=URLTypeData) class-attribute instance-attribute ¶
URLTypeData ¶
Type data for URL.
UniqueID ¶
UniqueIDTypeData ¶
Type data for UniqueID.
prefix: str | None = None class-attribute instance-attribute ¶
Verification ¶
Verfication data source property of Wiki databases.
verification: VerificationTypeData = Field(default_factory=VerificationTypeData) class-attribute instance-attribute ¶
VerificationTypeData ¶
Type data for Verification.