spacelift-policy-writer

spacelift-policy-writer is a skill for Claude Code from spacelift-io/claude-plugins. It costs 166 tokens per session (1,352 once invoked), scanned A, original, MIT.

A writing guide for Spacelift policies, which are rules written in Rego, the policy language used by Open Policy Agent. It covers policy types such as access, approval, planning, tasks, and notifications.

In plain words
What is it for?
Writing, editing, debugging, and explaining Spacelift policies. It is useful when checking policy inputs, outputs, formatting, flags, and notification delivery.
Why use it?
It helps avoid using invalid fields or rule results when creating or explaining policies. It also helps keep Rego compatible across language versions.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions subagents.

Part of the spacelift plugin — 2 skills, 2 agents shipped together

Good fit Writing, editing, debugging, and explaining Spacelift policies. It is useful when checking policy inputs, outputs, formatting, flags, and notification delivery.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/spacelift-io/claude-plugins/spacelift-policy-writer
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add spacelift-io/claude-plugins --skill spacelift-policy-writer
Clone the repo
git clone --depth 1 https://github.com/spacelift-io/claude-plugins

Made for: Claude Code.

Or install spacelift, the plugin that ships this one along with the rest of its 2 skills, 2 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for spacelift-policy-writer

README.md
[![agentmods](https://agentmods.dev/badge/skills/spacelift-io/claude-plugins/spacelift-policy-writer/github.svg)](https://agentmods.dev/skills/spacelift-io/claude-plugins/spacelift-policy-writer)
Your own site
<a href="https://agentmods.dev/skills/spacelift-io/claude-plugins/spacelift-policy-writer"><img src="https://agentmods.dev/badge/skills/spacelift-io/claude-plugins/spacelift-policy-writer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for spacelift-policy-writer

Your own site · 80×15
<a href="https://agentmods.dev/skills/spacelift-io/claude-plugins/spacelift-policy-writer"><img src="https://agentmods.dev/badge/skills/spacelift-io/claude-plugins/spacelift-policy-writer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 166 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,352 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00166 $0.01352
Opus 5.5 $0.00066 $0.00541
Sonnet 5.5 $0.00033 $0.00270
Haiku 4.5 $0.00017 $0.00135

Measured 29d ago against content hash fb8651ae7a09, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

spacelift-policy-writer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 29d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/spacelift/skills/spacelift-policy-writer/SKILL.md · 65 lines

How it starts

The opening of the file, as written. The whole thing — 65 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Spacelift Policy Writer

Procedural guide for authoring Spacelift policies. A policy is Rego that evaluates a per-type input document into named rule outputs. Read this router, then load the one resource your task needs.

Ground rules

  1. Every policy uses package spacelift.
  2. Never guess a field. Input paths and rule outputs differ per type - the contract in references/ is authoritative.
  3. Prefer the portable syntax. import future.keywords plus contains ... if rule heads run under both REGO_V0 and REGO_V1 (see guides/formatting.md).

Reference selector

Load only the file that matches the task. Do not preload references.

Question / task Load
Which policy type(s) fit a goal, and how types compose guides/policy-types.md
Exact input paths / rule outputs for a type references/policy-contract.md (machine-readable: references/policy-contract.json)
Rego rule shapes, missing and null fields, Rego v0 vs v1, the portable pattern guides/formatting.md
Flags, or one policy feeding / interacting with another guides/flags-and-interaction.md
Notifications - webhooks, Slack, inbox, pull request comments guides/delivery-webhooks-vs-integrations.md
Test / simulate a policy with no deploy guides/testing.md
Debug a policy that errors, does nothing, or misbehaves; or explain one guides/debugging.md

End-to-end recipe: examples/01-plan-guard-destructive.md.

Specialist sub-agents

Delegate when the task is bigger than a single lookup (prompts in agents/):

Sub-agent Use for
agents/capability-synthesizer.md Map a governance goal to the policy type(s) and how they compose
agents/tester.md Build inputs, simulate with the Spacelift MCP policy_simulate tool, iterate on the decision

Output shape

Clean Rego in a ```rego block - package spacelift, a one-line purpose comment, the rules, then helper rules. No sample JSON unless asked.

Pitfalls catalog

Read the full file on GitHub · 65 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 29d ago Changed · +4 lines · +8 tokens per session fb8651ae7a09
  2. 3mo ago First seen · 61 lines · 158 tokens per session scan A af5716c1df35

Subscribe to this mod's changes

spacelift-policy-writer is a skill published in the GitHub repository spacelift-io/claude-plugins (3 stars, last pushed 9d ago), licensed MIT. It adds 166 tokens to every session and 1,352 once invoked, about $0.0007 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

spacelift-policy-writer compared with skills from other repositories

spacelift-policy-writer next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
spacelift-policy-writerspacelift-io/claude-pluginsSkill39d agoMITA166Claude Code
local-ai-agentsmicrosoft/ai-agents-for-beginnersSkill82ktodayMITA200Claude Code, Codex
imagegenopenai/codexSkill137ktodayApache-2.0A113Codex
playwright-climicrosoft/playwrightSkill102ktodayApache-2.0A19Claude Code
browser-automationopenclaw/openclawSkill396ktodayMITA36Claude Code
free-llm-apismnfst/awesome-free-llm-apisSkill15ktodayCC0-1.0A113Claude Code, Codex
systematic-debuggingobra/superpowersSkill332k6d agoMITA21Claude Code