Tearleads

POST/containers/writer-projections/query

Operation containers.writerProjections.query

Description

Returns writer projections for up to 32 containers in one snapshot, sharing one manifest bundles dictionary and per-organization policyEvidenceByOrganization. When includeMetadataDocument: true, each readable container also includes the writer projection of the metadata document bound in its verified head manifest without re-walking the container path. Body knownCitations accepts up to 512 manifest and KEK-level digests and 64 organization directory digests. Per-container access or consistency errors report per item while sibling containers still resolve; a 202 asks the client to retry after policy history preparation.

Authentication

Requires a signed-in session: the client sends its session token as a bearer token in the Authorization header.

Request body

application/jsonQueryContainerWriterProjectionsRequest

Batch request for up to 32 container writer projections, optionally including each container's bound metadata document projection.

3 fields
  • containerIdslist of stringrequired
    • 1 to 32 items
    • each item: not empty

    Unique container ids to resolve.

  • includeMetadataDocumentbooleanoptional

    When true, resolves each readable container's verified metadata document projection in the same batch.

  • knownCitationsKnownProjectionCitationsRequestoptional

    Held digests omitted from the response.

Responses

200 OK

application/jsonQueryContainerWriterProjectionsWireResponse

Batched container writer projections sharing one bundles dictionary and per-organization policyEvidenceByOrganization.

4 fields
  • bundlesmap of string to ServedAccessManifestBundleWireResponserequired

    Signed manifest bundles keyed by manifest hash.

  • omittedBundleslist of stringrequired
    • each item: not empty

    Cited hashes left out because knownCitations declared them held.

  • policyEvidenceByOrganizationmap of string to ProjectionPolicyEvidenceWireResponserequired

    Public principal policy evidence keyed by organization id.

  • resultslist of one of: object, objectrequired
    • 1 to 32 items

    Per-container projection or failure in request order.

    1. object
      4 fields
      • containerIdstringrequired
      • metadataDocumentFailureDocumentWriterProjectionBatchFailureoptional
      • projectionobjectrequired
        4 fields
        • containerIdstringrequired
        • containerKekslist of one of: CitedContainerKekLevel, objectrequired
          1. object
            12 fields
            • accessManifestHashstringrequired
              • not empty
            • containerIdstringrequired
            • containerKeyEpochintegerrequired
              • greater than 0
            • containerKeyEpochIdstringrequired
              • not empty
            • containerManifestHistorylist of stringrequired
              • each item: not empty
            • keyEpochobject with any fieldsrequired
            • keyEpochHashstringrequired
              • not empty
            • keyringContainerKekKeyringWireRecordrequirednullable
            • keyTargetHashstringrequired
              • not empty
            • parentContainerKeyEpochIdstringrequirednullable
            • recipientTargetslist of object with any fieldsrequired
              • at least 1 item
            • wrapslist of object with any fieldsrequired
              • at least 1 item

            Other fields are allowed.

        • organizationIdstringrequired
        • pathlist of stringrequired
          • at least 1 item
          • each item: not empty

        Other fields are allowed.

    2. object
      2 fields

202 Accepted

application/jsonPrincipalHistoryPreparationResponse

A 202: the operation rolled back while the server prepares principal history. Retry the identical request.

3 fields
  • codestringrequired
    • always principal_history_preparation_pending
  • committedbooleanrequired
    • always false
  • progressTokenstringrequired
    • exactly 64 characters
    • lowercase hexadecimal

    Changes when preparation advances; clients stop after three identical tokens in a row.

Other responses

StatusMeaningBody
400Bad Request

application/jsonErrorResponse

401Unauthorized

application/jsonSessionFailureResponse

500Internal Server Error

application/jsonErrorResponse

503Service Unavailable

application/jsonErrorResponse

Additional rules

The server also enforces these rules, which the schema above cannot express.

  • containerIds must not repeat a container id.

  • Results must not repeat a containerId.

  • containerKeks must contain exactly one entry for every manifest in path.

  • A container response keyring is null exactly for container key epoch 1.

  • Every cited manifest hash names one bundles entry, every bundles key equals its bundle's manifestHash, and every bundle is cited.