{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/aimeat-io/json-schema/aimeat-io-action-publish-schema.json",
  "title": "ActionPublish",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/aimeat-io-actions-api-openapi.yml#/components/schemas/ActionPublish",
  "type": "object",
  "required": [
    "id",
    "display_name",
    "description",
    "input_schema",
    "output_schema",
    "pricing"
  ],
  "properties": {
    "id": {
      "type": "string"
    },
    "display_name": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "category": {
      "type": "string"
    },
    "input_schema": {
      "type": "object",
      "description": "JSON Schema for action input"
    },
    "output_schema": {
      "type": "object",
      "description": "JSON Schema for action output"
    },
    "pricing": {
      "$ref": "#/$defs/ActionPricing"
    },
    "estimated_time_seconds": {
      "type": "integer"
    },
    "max_input_size_bytes": {
      "type": "integer"
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "federate": {
      "type": "boolean",
      "default": false,
      "description": "Whether this action is visible to federated peer nodes"
    },
    "semantic": {
      "$ref": "#/$defs/SemanticAnnotation"
    }
  },
  "$defs": {
    "ActionPricing": {
      "type": "object",
      "description": "An action's pacing. A morsel is pacing, never a price: `toll_morsels` is the morsels each use takes from the requester's owner (the burn rate's share burns, the rest goes to the provider).\n",
      "properties": {
        "toll_morsels": {
          "$ref": "#/$defs/TollMorsels"
        },
        "base_morsels": {
          "type": "integer",
          "minimum": 0,
          "deprecated": true,
          "description": "Deprecated until 4.0.0. On write it is read as pacing and added to `toll_morsels`. On read it mirrors `toll_morsels`, and a sibling `deprecated` object names it. From 4.0.0 a write with it answers 400 MORSEL_PRICE_REMOVED and reads leave it out.\n"
        },
        "deprecated": {
          "$ref": "#/$defs/MorselPriceDeprecation"
        },
        "per_unit": {
          "type": "object",
          "properties": {
            "unit": {
              "type": "string"
            },
            "morsels_per_1000": {
              "type": "number"
            }
          }
        }
      }
    },
    "MorselPriceDeprecation": {
      "type": "object",
      "description": "Present while the node is older than release 4.0.0, beside a scalar mirror of an old morsel price field (for example `price_morsels`, `base_morsels`). Each key is the old field's name and each value is the deprecation note. The mirror holds the pacing amount (`toll_morsels`); after 4.0.0 neither the mirror nor this object is sent, and a write that sends the old field is refused with 400 MORSEL_PRICE_REMOVED.\n",
      "additionalProperties": {
        "type": "string"
      }
    },
    "SemanticAnnotation": {
      "type": "object",
      "description": "A JSON-LD annotation. Every prefix it names must resolve: either declared in its own `@context`, or one this node carries by default (aimeat, schema, skos, dcterms, prov, rdfs, qudt, saref — see GET /v1/ns). A prefixed name whose prefix nobody defined is refused, since it expands to nothing in any JSON-LD processor. A BARE type (`\"@type\": \"LocalBusiness\"`) is always accepted: it resolves against the document's default vocabulary. Ontology-specific properties pass through untouched, and are checked the same way.",
      "properties": {
        "@context": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          }
        },
        "@type": {
          "type": "string"
        }
      },
      "additionalProperties": true
    },
    "TollMorsels": {
      "type": "integer",
      "minimum": 0,
      "maximum": 100,
      "description": "Pacing amount in morsels per use, set by the provider. Each use by another owner takes this many morsels from the user's owner: the burn rate's share burns and the rest goes to the provider's owner. Omitted: the node default (`morsel_policy.pacing_toll_default`). Clamped to the node ceiling (`AIMEAT_EXT_MAX_DEBIT`, 100 by default). This is not a price; the price is the money field beside it, and an offer without one is free.\n"
    }
  }
}