Light
Dark
System
v3latest
v3latest
v2
v1

Base Objects

BaseObject

Root object type

Object

Root for user-defined object types

std::BaseObject is the root of the object type hierarchy and all object types in EdgeDB, including system types, extend it either directly or indirectly. User-defined object types extend from std::Object type, which is a subtype of std::BaseObject.

type

BaseObject
BaseObject

The root object type.

Definition:

Copy
abstract type std::BaseObject {
    # Universally unique object identifier
    required property id -> uuid {
        default := (select std::uuid_generate_v1mc());
        readonly := true;
        constraint exclusive;
    }

    # Object type in the information schema.
    required readonly link __type__ -> schema::ObjectType;
}

Subtypes may override the id property, but only with a valid UUID generation function. Currently, these are uuid_generate_v1mc() and uuid_generate_v4().

type

Object
Object

The root object type for user-defined types.

Definition:

Copy
abstract type std::Object extending std::BaseObject;
Light
Dark
System

We use ChatGPT with additional context from our documentation to answer your questions. Not all answers will be accurate. Please join our Discord if you need more help.