Blueprints

Blueprints glossary

Definitions of the core Blueprints terms: stacks, scopes, values, deletion policies, and more.

Definitions of the core Blueprints terms. For a narrative introduction, see the Blueprints introduction.

TermDefinition
Attach / detachBring an existing resource under Blueprints management (attach), or stop managing it without deleting it (detach).
Blueprint config file.sanity/blueprint.config.json. Links a local blueprint file to a remote stack and records the scope. Gitignored by default; not secret.
Blueprint fileThe file you edit, sanity.blueprint.ts, declaring your desired resources. Also called the manifest. See the Blueprint configuration reference.
BlueprintsSanity's infrastructure-as-code system for managing resources from a file in your repo.
DefinerA typed function such as defineCorsOrigin or defineRole that declares a resource and checks your input as you write it.
Deletion policyA per-resource setting (allow, retain, replace, protect) controlling what happens when a resource is removed or a stack is destroyed.
DeployApplying the blueprint file to a stack so resources match it. The command is blueprints deploy.
DestroyRemoving a stack's resources, subject to their deletion policies. The command is blueprints destroy.
Organization scopeA stack scoped to an organization. Unlocks org-scoped resource types and spans multiple projects. See the Blueprints scopes reference.
PlanThe read-only, deterministic diff between your blueprint file and a stack's current state. The command is blueprints plan.
Project scopeA stack scoped to a single project.
PromotionConverting a project-scoped stack to organization scope. One-way and safe. See Promote a stack to organization scope.
Reference ($ syntax)In-file pointers: $.values.<key> for a constant, $.resources.<name> for another resource (which creates a dependency edge). See The resource graph.
ResourceA single thing Blueprints manages: a dataset, CORS origin, webhook, role, robot token, or function. Has a unique name.
RollbackBlueprints' best-effort attempt to undo completed changes, in reverse, when a deploy fails partway. See Errors and rollbacks.
ScopeThe boundary a stack operates within: project or organization.
StackThe deployed counterpart to a blueprint file: the live resources on Sanity's side. One file can deploy to many stacks.
ValueA reusable, file-level constant (always a string) defined in the values block and referenced with $.values.<key>.

Was this page helpful?