Sanity Library Reference Docs
    Preparing search index...

    The context a Sanity Function handler is invoked with. Both the document and the scheduled function context satisfy it.

    interface RuntimeFunctionContext {
        clientOptions?: {
            apiHost?: string;
            dataset?: string;
            projectId?: string;
            token?: string;
        };
    }
    Index

    Properties

    Properties

    clientOptions?: {
        apiHost?: string;
        dataset?: string;
        projectId?: string;
        token?: string;
    }

    Type declaration

    • OptionalapiHost?: string
    • Optionaldataset?: string

      The dataset a document function's event came from. Runtime.start throws without it.

    • OptionalprojectId?: string

      The project of the dataset a document function's event came from. Runtime.start throws without it.

    • Optionaltoken?: string