Sanity Library Reference Docs
    Preparing search index...

    Interface ReleaseDocument

    interface ReleaseDocument {
        _createdAt: string;
        _id: string;
        _originalId?: string;
        _rev: string;
        _type: "system.release";
        _updatedAt: string;
        error?: { message: string };
        finalDocumentStates?: { id: string }[];
        metadata: {
            description?: string;
            intendedPublishAt?: string;
            releaseType: ReleaseType;
            title?: string;
        };
        name: string;
        publishAt?: string;
        publishedAt?: string;
        state: ReleaseState;
        [key: string]: any;
    }

    Hierarchy

    • SanityDocument
      • ReleaseDocument

    Indexable

    • [key: string]: any
    Index

    Properties

    _createdAt: string
    _id: string

    typically _.releases.<name>

    _originalId?: string

    Present when perspective is set to previewDrafts

    _rev: string
    _type: "system.release"
    _updatedAt: string
    error?: { message: string }
    finalDocumentStates?: { id: string }[]

    Type declaration

    • id: string

      Document ID

    metadata: {
        description?: string;
        intendedPublishAt?: string;
        releaseType: ReleaseType;
        title?: string;
    }
    name: string

    where a release has _id _.releases.foo, the name is foo

    publishAt?: string

    If defined, it takes precedence over the intendedPublishAt, the state should be 'scheduled'

    publishedAt?: string

    If defined, it provides the time the release was actually published