← Playbooks

Role playbook

#Ops Agent: wolne miejsca w subskrypcjach (scenariusz §59, Postiz)

Cel: zanim biznes Clothing kupi nowe narzędzie do social publishing, sprawdzić, czy współdzielona subskrypcja Postiz Pro ma wolne sloty. Ma: 10 slotów, 7 użytych, 3 wolne. Agent proponuje wykorzystanie wolnego slotu zamiast nowej subskrypcji.

Passport: szablon ops dla Clothing: subscriptions:execute@business ≤ 500/10 000 PLN, allocations:execute@business, expenses:recommend@business, finances:observe@business. Do plan_capacity wystarczy subscriptions:observe; propozycja podziału kosztu (z idempotency_key + reason) idzie przez allocations (recommend → 202, execute → 201).

#System prompt (skopiuj)

You are the Ops Agent for Clothing in Operlance. When someone needs a tool, first check shared subscriptions: get_subscriptions and get_subscription_capacity show total, used and free seats per subscription and per workspace. Prefer a free seat of an existing subscription over a new cost; a new subscription needs a clear reason and the cost split (allocations sum to 10000 bps). One-off expenses are only recommendations for you (202); the owner decides. Report unused capacity as money (monthly cost of free seats). Never touch personal or other businesses.

#Sekwencja

  1. Subskrypcje Clothing z alokacjami.
{
 "data": [
  {
   "id": "<subscription:Claude Team>",
   "owner_id": "<id-19>",
   "name": "Claude Team",
   "vendor": "Anthropic",
   "plan": "Team",
   "price_minor": 15000,
   "currency": "USD",
   "billing_interval": "monthly",
   "interval_count": 1,
   "started_on": null,
   "next_charge_on": "2026-10-08",
   "auto_renew": true,
   "status": "active",
   "provenance": {
    "reason": "Claude Team subscription",
    "source": {
     "type": "HUMAN",
     "agent_id": null,
     "approval_id": null,
     "external_id": null,
     "integration_id": null
    },
    "confidence": 0.95,
    "data_class": "manual",
    "recorded_at": "2026-09-18T…Z"
   },
   "created_at": "2026-09-18T…Z",
   "updated_at": "2026-09-18T…Z",
   "base_amount_minor": 15000,
   "base_currency": "USD",
   "fx": {
    "rate": "1.00000000",
    "as_of": "2026-09-18",
    "source": "identity",
    "kind": "current",
    "stale": false
   },
…
  1. Capacity: Postiz Pro ma 3 wolne sloty.
{
 "data": [
  {
   "subscription_name": "Claude Team",
   "id": "<id-23>",
   "subscription_id": "<subscription:Claude Team>",
   "unit": "seats",
   "total": 5,
   "used": 4,
   "free": 1,
   "utilization": 0.8,
   "usages": [
    {
     "business_id": "<business:klima>",
     "personal": false,
     "project_id": null,
     "used": 1
    },
    {
     "business_id": "<business:tharan>",
     "personal": false,
     "project_id": null,
     "used": 3
    }
   ]
  },
  {
   "subscription_name": "Figma",
   "id": "<id-26>",
   "subscription_id": "<subscription:Figma>",
   "unit": "seats",
   "total": 4,
   "used": 3,
   "free": 1,
   "utilization": 0.75,
   "usages": [
    {
     "business_id": "<business:clothing>",
     "personal": false,
     "project_id": null,
…
  1. plan_capacity: potrzeba 1 profilu social dla Clothing → Postiz ma 3 wolne sloty → sugestia allocate (koszt 0, podział wg użycia).
{
 "data": {
  "plans": [
   {
    "unit": "social_profiles",
    "amount": 1,
    "business_id": "<business:clothing>",
    "covered_by": {
     "subscription_id": "<subscription:Postiz Pro>",
     "subscription_name": "Postiz Pro",
     "unit": "social_profiles",
     "total": 10,
     "used": 7,
     "free": 3
    },
    "shortfall": 0,
    "suggestion": "allocate",
    "est_cost_minor": 0,
    "currency": "PLN",
    "note": "Postiz Pro has 3 free social_profiles; assign 1 instead of buying a new tool (total cost unchanged, share moves to the business)",
    "proposed_allocations": [
     {
      "business_id": "<business:clothing>",
      "share_bps": 3750
     },
     {
      "business_id": "<business:klima>",
      "share_bps": 2500
     },
     {
      "business_id": "<business:tharan>",
      "share_bps": 3750
     }
    ]
   }
  ],
  "proposals": []
 },
 "coverage": {
  "coverage_pct": 0.4775,
…
  1. Zamiast nowej subskrypcji: jednorazowy koszt onboardingu profilu (recommend → 202).
{
 "status": "pending_approval",
 "approval_id": "<id-42>",
 "coverage": {
  "coverage_pct": 0.4775,
  "domains": {
   "revenue": {
    "status": "mostly_covered",
    "sources": [],
    "last_sync_at": null
   },
   "ad_spend": {
    "status": "mostly_covered",
    "sources": [],
    "last_sync_at": null
   },
   "subscriptions": {
    "status": "incomplete",
    "sources": [
     "HUMAN",
     "SYSTEM"
    ],
    "last_sync_at": null
   },
   "operating_costs": {
    "status": "missing",
    "sources": [],
    "last_sync_at": null
   },
   "cash": {
    "status": "incomplete",
    "sources": [
     "HUMAN"
    ],
    "last_sync_at": null
   }
  }
 },
 "request_id": "req_<id-43>"
}
  1. Owner odrzuca (playbook nie zostawia śladów poza audytem).
{
 "status": 200,
 "data": {
  "id": "<id-42>",
  "owner_id": "<id-19>",
  "agent_id": "<id-44>",
  "action": "create_expense",
  "params": {
   "reason": "Use a free Postiz slot for Clothing instead of a new tool; one-off setup",
   "category": "saas",
   "currency": "PLN",
   "business_id": "<business:clothing>",
   "description": "Postiz profile setup (free slot)",
   "occurred_on": "2026-09-18",
   "amount_minor": 15000
  },
  "reason": "Use a free Postiz slot for Clothing instead of a new tool; one-off setup",
  "amount_minor": 15000,
  "currency": "PLN",
  "business_id": "<business:clothing>",
  "personal": false,
  "status": "rejected",
  "decided_by": "<id-19>",
  "decided_at": "2026-09-18T…Z",
  "decision_note": "playbook",
  "expires_at": "2026-09-25T…Z",
  "result_ref": null,
  "idempotency_key": "pb-ops-1",
  "created_at": "2026-09-18T…Z",
  "kind": "write"
 },
 "request_id": "req_<id-45>"
}

#Gdzie jest 202

Krok 4: expenses:recommend oznacza, że każdy koszt jest tylko propozycją. Owner widzi kwotę, kategorię, opis i powód; po akceptacji system zapisuje event z approval_id w provenance.

#Czego agent NIE może

Zapisać kosztu od razu (poziom recommend), czytać THARAN ani personal, przekroczyć limitu subskrypcji (500 PLN na akcję → Approval; 10 000 PLN miesięcznie → 403 limit_exceeded).