Przejdź do treści

INAC Control Frame

Source schema: doc/schemas/inac-control.v1.schema.json

Control-plane frame for Inter-Node Artifact Channel offer/request/push/response exchanges. The frame is transport-neutral; concrete transports must preserve the byte identity of inline artifact bytes.

Fields

Field Required Shape Description
schema yes const: inac-control.v1
operation yes enum: offer, request, push, accept, decline, defer, ingested, already-present, refused, partial
correlation/id no string
idempotency/key no string
artifact no ref: #/$defs/artifact
request no ref: #/$defs/request
transfer no ref: #/$defs/transfer
authorization no ref: #/$defs/authorization
response no ref: #/$defs/response
meta no object

Definitions

Definition Shape Description
artifact object
request object
transfer object
authorization object
response object

Conditional Rules

Rule 1

When:

{
  "properties": {
    "operation": {
      "const": "offer"
    }
  },
  "required": [
    "operation"
  ]
}

Then:

{
  "required": [
    "artifact"
  ],
  "properties": {
    "artifact": {
      "oneOf": [
        {
          "required": [
            "bytes/base64url"
          ],
          "not": {
            "anyOf": [
              {
                "required": [
                  "artifact/ref"
                ]
              },
              {
                "required": [
                  "artifact/href"
                ]
              }
            ]
          }
        },
        {
          "required": [
            "artifact/ref"
          ],
          "not": {
            "anyOf": [
              {
                "required": [
                  "bytes/base64url"
                ]
              },
              {
                "required": [
                  "artifact/href"
                ]
              }
            ]
          }
        },
        {
          "required": [
            "artifact/href"
          ],
          "not": {
            "anyOf": [
              {
                "required": [
                  "bytes/base64url"
                ]
              },
              {
                "required": [
                  "artifact/ref"
                ]
              }
            ]
          }
        }
      ]
    }
  }
}

Rule 2

When:

{
  "properties": {
    "operation": {
      "const": "push"
    }
  },
  "required": [
    "operation"
  ]
}

Then:

{
  "required": [
    "artifact"
  ]
}

Rule 3

When:

{
  "properties": {
    "operation": {
      "const": "request"
    }
  },
  "required": [
    "operation"
  ]
}

Then:

{
  "required": [
    "request"
  ]
}

Rule 4

When:

{
  "properties": {
    "operation": {
      "enum": [
        "accept",
        "decline",
        "defer",
        "ingested",
        "already-present",
        "refused",
        "partial"
      ]
    }
  },
  "required": [
    "operation"
  ]
}

Then:

{
  "required": [
    "response"
  ]
}

Field Semantics

schema

  • Required: yes
  • Shape: const: inac-control.v1

operation

  • Required: yes
  • Shape: enum: offer, request, push, accept, decline, defer, ingested, already-present, refused, partial

correlation/id

  • Required: no
  • Shape: string

idempotency/key

  • Required: no
  • Shape: string

artifact

  • Required: no
  • Shape: ref: #/$defs/artifact

request

  • Required: no
  • Shape: ref: #/$defs/request

transfer

  • Required: no
  • Shape: ref: #/$defs/transfer

authorization

  • Required: no
  • Shape: ref: #/$defs/authorization

response

  • Required: no
  • Shape: ref: #/$defs/response

meta

  • Required: no
  • Shape: object

Definition Semantics

$defs.artifact

  • Shape: object

$defs.request

  • Shape: object

$defs.transfer

  • Shape: object

$defs.authorization

  • Shape: object

$defs.response

  • Shape: object