Schema · write_intent.v1

Write Intent schema

Clear, versioned metadata every orchestrator emits to check_write before a mutating side effect. TekCapitol™ does not query the system of record.

Identity

schemaVersionwrite_intent.v1 (const)
Canonical JSON Schema/schema/write-intent/v1/write-intent.v1.json
Alias/schemas/write-intent-v1.json
$idhttps://tekcapitol.com/schema/write-intent/v1/write-intent.v1.json

Required fields

FieldMeaning
schemaVersionMust be write_intent.v1.
systemSystem of record id (e.g. Salesforce, SAP, Snowflake).
objectTypeObject / entity type (e.g. Opportunity).
objectRefRecord id in that system.
intendedChangesArray of { field, newValue }. At least one change.

Recommended fields

FieldMeaning
authorityIndependent entitlement / SoR value the write must match. Prefer billing_sor / crm_entitlement, not prompt text.
authority.checkedAtISO-8601 time the orchestrator read authority.
authority.maxAgeMsFreshness window for checkedAt.
authority.stalePolicywarn | pause | block. Default in Live API: warn.
freshness.recordVersione.g. Salesforce SystemModstamp or row version.
freshness.stampTypee.g. SystemModstamp, hash, etag.
freshness.hashOptional hash of critical fields known to the orchestrator.
agentIdentityWhich agent / service identity is writing.
workflowId / runIdCorrelation for Trace and audit.
requireApprovalIf true, Check Write returns pause even when values match (HITL).
idempotencyKeyOptional dedupe key for the write attempt.

Freshness and authorityStalePolicy

The gate is only as strong as the signals the orchestrator emits. If the orchestrator only has stale context and sends no freshness window, the freshness check is weak.

stalePolicyWhen authority age > maxAgeMs
warnDecision may still allow; response flags freshness warn. Default for backward compatibility.
pauseDecision pause. Do not write until a human clears or authority is re-read.
blockDecision block. Fail closed on stale authority.
High-assurance workflows should set authority.stalePolicy to pause or block, and emit a lightweight SoR stamp (for example orchestrator reads Salesforce SystemModstamp only and includes it in freshness). TekCapitol™ never opens Salesforce for you.

Minimal example

{
  "schemaVersion": "write_intent.v1",
  "system": "Salesforce",
  "objectType": "Opportunity",
  "objectRef": "006XXXXXXXXXXXX",
  "intendedChanges": [
    { "field": "StageName", "newValue": "Approved" }
  ],
  "authority": {
    "value": "eligible",
    "source": "billing_sor",
    "checkedAt": "2026-08-11T18:00:00.000Z",
    "maxAgeMs": 5000,
    "stalePolicy": "pause"
  },
  "freshness": {
    "recordVersion": "2026-08-11T17:59:58.000Z",
    "stampType": "SystemModstamp"
  },
  "agentIdentity": "renewal-agent-v3",
  "workflowId": "sf-renewal-opp",
  "runId": "run_abc123"
}

SDK helpers

Private package @tekcapitol/tc-protect-sdk (folder drop / file dependency): buildWriteIntent, withRecordFreshness, evaluateWriteIntent, guardedWrite. See Check Write design.

Also in Docs