Sanity Library Reference Docs
    Preparing search index...

    Interface DeleteVariantActionBeta

    Deletes a variant of a document.

    interface DeleteVariantAction {
        actionType: "sanity.action.document.variant.delete";
        bundleId?: "drafts" | string & {};
        publishedId: string;
        purge?: boolean;
        variantId: string;
    }
    Index

    Properties

    actionType: "sanity.action.document.variant.delete"
    bundleId?: "drafts" | string & {}

    Source bundle: 'drafts', or a release id.

    Defaults to the published bundle.

    publishedId: string

    ID of the document group the variant belongs to. Must be a published document ID, without a drafts. or versions. prefix.

    purge?: boolean

    Delete document history.

    variantId: string

    Name of the variant definition this document belongs to, as in _.variants.{variantName}. Must be a bare name, not a full document ID.