HYBRID-CHAINDEVELOPERS
DOCUMENTATIONv2
POST

Price feeds

Create subscription

/api/v2/price-feed-subscriptions
AUTHENTICATIONBearer token · pricing:writeAUTHORITATIVE OWNERmarket-data-serviceCONTRACT AUTHORITYGenerated Rust OpenAPISTATUSSource ready · production listed

PURPOSE + BUSINESS CONTEXT

Create an ACTIVE owner-scoped delivery contract with exact feed entitlements, plan limits, metered-service posture, and retained retry semantics.

WHEN THIS CALL IS USEFUL

After listing plans and feeds, use this planning contract to bind a workspace to an explicit set of active public or workspace-owned feeds under one delivery plan.

OUTCOME · Create or advance

What changes

When promoted, creates an ACTIVE metered delivery contract, entitled feed items, retained contract evidence, and a workspace-owned subscription. It does not grant trading, publisher, ingress, or settlement authority.

WHY IT MATTERS

  • Gives people and agents a contract-backed way to advance subscription.
  • Makes feed provenance, quality, delivery entitlement, replay limits, and workspace-owned composite policy explicit before price data enters valuation or decision workflows.

ISOLATION + AUTHORITY

Instrument, provider, observation, signature, hash-chain, aggregation, composite owner, subscription, delivery, billing, valuation, market, and trading boundaries remain distinct. A feed, snapshot, replay, plan, or subscription supplies data only and grants no oracle-finality, valuation approval, publisher, order, matching, settlement, or trading authority.

BEFORE YOU CALL

  • Authenticate at the documented boundary: bearer+scope.
  • Supply the required feed_uuids (body) exactly as defined by the live contract.
  • Use one Idempotency-Key only for retries of the same byte-equivalent logical mutation.
  • Resolve the canonical instrument and feed, source and aggregation policy, required freshness and quality, and any subscription entitlement or replay window.

WHAT TO DO NEXT

  • Re-read the created or updated feed or subscription and confirm its owner, plan, entitlements, lifecycle state, and effective policy.
  • Reconcile an ambiguous result with the same idempotency key, then verify feed provenance and freshness before dependent use.

AGENT GUIDANCE

  • Use subscription only for the purpose and lifecycle stage described by this operation; do not treat it as authority for an adjacent action.
  • Supply the required feed_uuids (body) exactly as defined by the live contract.
  • Preserve decimal values and observation timestamps exactly; distinguish source time, ingestion time, sequence, freshness, health, quality, aggregation, delivery entitlement, and business acceptance.
  • After a timeout or conflict, read authoritative state before deciding whether an equivalent retry is safe.
MACHINE CONTRACT

The exact deployed parameters, schemas, responses, security requirements, and Hybrid-Chain agent metadata are authoritative at this operation's production OpenAPI JSON Pointer. The readable tables below add integration guidance; the deployed OpenAPI controls if guidance and the machine contract ever differ.

Open the authoritative production contract

EXTENDED INTEGRATION GUIDANCE

Readable request and response reference

Examples illustrate integration intent; the referenced OpenAPI operation and component schemas define the executable shape.

PARAMETERS

Headers, path, query, and body

NAMELOCATIONPRESENCETYPE / RULES / PURPOSE
AuthorizationheaderRequired

Bearer tokenCredential containing the pricing:write scope.EXAMPLEBearer hc_live_…

Idempotency-KeyheaderRequired

ASCII string · 1–128Caller-generated key reused for every retry of the same logical mutation.EXAMPLEprice-delivery-treasury-valuation-20260901

Content-TypeheaderRequired

application/jsonSigned mutations accept canonical JSON only.EXAMPLEapplication/json

Content-DigestheaderRequired

RFC 9530 SHA-256 digestDigest of the exact transmitted body bytes.EXAMPLEsha-256=:47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=:

Signature-InputheaderRequired

RFC 9421 signature parametersCovers @method, @path, content-digest, content-type, and idempotency-key; includes keyid, nonce, created, and expires.EXAMPLEsig1=("@method" "@path" "content-digest" "content-type" "idempotency-key");created=1786582800;expires=1786583100;nonce="01J…";keyid="machine-prod"

SignatureheaderRequired

Ed25519 HTTP Message SignatureSignature made by an active public key registered to the authenticated client.EXAMPLEsig1=:base64-signature:

namebodyOptional

string · 1–120Human-readable contract label. Omit it to use My price delivery.EXAMPLETreasury valuation evidence

client_idbodyOptional

printable ASCII · 1–64Caller-owned attribution label retained on the private owner record. It grants no identity, scope, ownership, or transport authority.EXAMPLEtreasury-agent-prod

plan_codebodyOptional

letters, digits, underscore, or hyphen · 1–32Active code freshly resolved from GET /api/v2/price-feed-plans. Omit it to select DEVELOPER.EXAMPLEDEVELOPER

feed_uuidsbodyRequired

32-character hexadecimal identifier[] · 1–100 uniqueActive public or workspace-owned feeds. The selected plan applies its lower max_feeds bound and raises delivery cadence to at least min_cadence_ms.EXAMPLE["8c1490adbe524bb79b8be0618e58fe55"]

REQUEST

JSON body example

{
  "name": "Treasury valuation evidence",
  "client_id": "treasury-agent-prod",
  "plan_code": "DEVELOPER",
  "feed_uuids": [
    "8c1490adbe524bb79b8be0618e58fe55"
  ]
}

RESPONSES

Status and payload examples

201Canonical ACTIVE delivery subscription, exact entitlements, plan limits, metering posture, and retained service contract.Mutation completed · JSON RESPONSE+
{
  "subscription_id": "05aa9566990f42fa8e8e74624d4ec906",
  "name": "Treasury valuation evidence",
  "status": "ACTIVE",
  "started_at": "2026-08-01T00:00:00Z",
  "paused_at": null,
  "cancelled_at": null,
  "last_ticket_at": "2026-08-31T22:40:00Z",
  "created_at": "2026-08-01T00:00:00Z",
  "updated_at": "2026-08-31T22:40:00Z",
  "plan": {
    "code": "DEVELOPER",
    "name": "Developer",
    "max_feeds": 5,
    "max_connections": 2,
    "replay_window_minutes": 1440,
    "min_cadence_ms": 1000,
    "retained_history_days": 7
  },
  "feeds": [
    {
      "feed_id": "8c1490adbe524bb79b8be0618e58fe55",
      "cadence_ms": 1000,
      "enabled": true,
      "name": "BTC / USD composite",
      "mode": "AGGREGATED",
      "instrument": "BTC-USD",
      "asset_class": "DIGITAL_ASSET"
    }
  ],
  "usage_current_month": {
    "delivered_messages": 184221,
    "delivered_bytes": 42199112,
    "connection_seconds": 2389200,
    "reconnect_count": 3,
    "replayed_messages": 1200
  },
  "contract": {
    "billing_mode": "METERED",
    "billing_state": "ACTIVE",
    "renewal_mode": "AUTOMATIC",
    "current_period_started_at": "2026-08-01T00:00:00Z",
    "current_period_ends_at": "2026-09-01T00:00:00Z",
    "payload_schema": "price-evidence-v1",
    "usage_schema": "price-delivery-usage-v1",
    "retention_days": 7,
    "entitlements": {
      "feeds": 5,
      "connections": 2,
      "replay_window_minutes": 1440
    }
  }
}
INTEGRATION DECISION
CALLER ACTION
Accept the returned representation or receipt, then re-read the created or updated feed or subscription and confirm its owner, plan, entitlements, lifecycle state, and effective policy.
RETRY SAFETY
Do not repeat a successful mutation merely to confirm it. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Persist returned identifiers, versions, commitments, and receipts. Refresh the feed, source mapping, observation timestamp, quality and staleness state, policy version, and delivery or command receipt.
404The selected active delivery plan is unavailable.Resource not visible · JSON RESPONSE+
{
  "code": "price_feed_plan_not_found",
  "message": "The selected active delivery plan is unavailable."
}
INTEGRATION DECISIONprice_feed_plan_not_found
CALLER ACTION
Verify the canonical identifier and authenticated owner boundary. A 404 may intentionally conceal a resource outside the caller's authority.
RETRY SAFETY
Do not retry the unchanged identifier repeatedly. Refresh the relevant collection or lookup before choosing another identifier.
STATE RECONCILIATION
Refresh the feed, source mapping, observation timestamp, quality and staleness state, policy version, and delivery or command receipt.
ESCALATE WHEN
Escalate when source identity, observation time, confidence, staleness, entitlement, or delivery evidence cannot be reconciled.
401The bearer credential is missing, expired, or invalid.Authentication required · JSON RESPONSE+
{
  "code": "invalid_credentials",
  "message": "The bearer credential is missing, expired, or invalid."
}
INTEGRATION DECISIONinvalid_credentials
CALLER ACTION
Discard the rejected credential, complete the documented authentication or reassertion flow, and rebuild any request signature with fresh timestamps and nonces.
RETRY SAFETY
Retry only with a newly valid credential and fresh replay-protection values. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Assume the outcome is unknown only when the connection failed after transmission; otherwise authentication failed before domain work. Refresh the feed, source mapping, observation timestamp, quality and staleness state, policy version, and delivery or command receipt.
ESCALATE WHEN
Escalate when source identity, observation time, confidence, staleness, entitlement, or delivery evidence cannot be reconciled.
403The credential lacks pricing:write or the selected resource is outside the authenticated workspace.Authority or policy denied · JSON RESPONSE+
{
  "code": "insufficient_scope",
  "message": "The credential lacks pricing:write or the selected resource is outside the authenticated workspace."
}
INTEGRATION DECISIONinsufficient_scope
CALLER ACTION
Verify the exact scope, tenant or workspace membership, owner boundary, step-up purpose, feature policy, and resource eligibility. Never broaden authority automatically.
RETRY SAFETY
Do not retry until the missing authority or policy condition has been deliberately resolved with least privilege.
STATE RECONCILIATION
Confirm the caller and resource resolve to the same authority boundary for workspace price-feed definitions, source mappings, observations, quality status, subscriptions, and delivery receipts.
ESCALATE WHEN
Escalate when source identity, observation time, confidence, staleness, entitlement, or delivery evidence cannot be reconciled.
409The Idempotency-Key conflicts with another request or the requested lifecycle transition is forbidden.State reconciliation required · JSON RESPONSE+
{
  "code": "price_feed_conflict",
  "message": "The Idempotency-Key conflicts with another request or the requested lifecycle transition is forbidden."
}
INTEGRATION DECISIONprice_feed_conflict
CALLER ACTION
Stop the mutation sequence and fetch the latest authoritative resource, lifecycle state, version, ETag, reservation, or existing idempotency result.
RETRY SAFETY
Retry only after reconciling the conflict. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Refresh the feed, source mapping, observation timestamp, quality and staleness state, policy version, and delivery or command receipt.
ESCALATE WHEN
Escalate when source identity, observation time, confidence, staleness, entitlement, or delivery evidence cannot be reconciled.
422An identifier, field, source mapping, policy bound, action, or Idempotency-Key is invalid.Request must change · JSON RESPONSE+
{
  "code": "invalid_price_feed_command",
  "message": "An identifier, field, source mapping, policy bound, action, or Idempotency-Key is invalid."
}
INTEGRATION DECISIONinvalid_price_feed_command
CALLER ACTION
Rebuild the request from the live OpenAPI operation and correct the rejected method, media type, header, parameter, or body field.
RETRY SAFETY
Do not retry the same invalid request. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Compare the submitted values with the documented constraints before another call. Refresh the feed, source mapping, observation timestamp, quality and staleness state, policy version, and delivery or command receipt.
ESCALATE WHEN
Escalate when source identity, observation time, confidence, staleness, entitlement, or delivery evidence cannot be reconciled.
503The authoritative Core pricing mutation boundary is unavailable.Dependency unavailable or outcome uncertain · JSON RESPONSE+
{
  "code": "price_feeds_unavailable",
  "message": "The authoritative Core pricing mutation boundary is unavailable."
}
INTEGRATION DECISIONprice_feeds_unavailable
CALLER ACTION
Preserve the exact request and treat the outcome as uncertain until authoritative state proves whether it committed.
RETRY SAFETY
Reconcile before retrying. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions. Use bounded backoff with jitter.
STATE RECONCILIATION
Refresh the feed, source mapping, observation timestamp, quality and staleness state, policy version, and delivery or command receipt.
ESCALATE WHEN
Escalate when source identity, observation time, confidence, staleness, entitlement, or delivery evidence cannot be reconciled.

OPERATIONAL NOTES

Security and lifecycle guarantees

  • Resolve plan_code and every feed_uuids member immediately before submission. Plan limits and feed visibility are server-owned; never guess, cache indefinitely, or substitute display symbols for identifiers.
  • The workspace is derived from the bearer and signed into the private Core command. Creation retains the feed entitlement rows and metered-service registration as one owner-scoped contract; it does not create an invoice or prove external settlement.
  • The body, Content-Digest, path, method, content type, and Idempotency-Key are covered by the RFC 9421 Ed25519 signature. Reuse the key only for an equivalent retry; after ambiguity, list subscriptions before inventing another contract.
  • This operation grants price-data delivery only. It cannot publish data, enable ingress, open a market, place or match an order, alter settlement, move value, change market status, or route traffic. The response is no-store.
DOCUMENTATION STATUS

This route is implemented in canonical gateway source and appears in the production OpenAPI snapshot observed 2026-09-11T06:35:11.572Z. Authentication, tenant, feature, venue, and market policy still apply.

Verify the exact production OpenAPI operation Return to the V2 directory