Skip to content

objects.get

One object by URI (majordomus://<kind>/<identity>): metadata, provenance and content; a URI a query projects (majordomus://repository) answers that query as a JSON document. The same resolution serves the MCP resource read.

One object by URI (majordomus://<kind>/<identity>): metadata, provenance and content; a URI a query projects (majordomus://repository) answers that query as a JSON document. The same resolution serves the MCP resource read.

Exposure

Where this one definition is reachable. Absence is explicit: a surface not listed does not carry it.

surfaceas
MCPtool majordomus_get
HTTPGET /api/v1/object operationId objects.get
command line

Schemas

The canonical input and output, from the Rust types; the MCP tool schema and the OpenAPI parameters and responses are derived from these.

input · GetInput

The input of `objects.get`: which object.

propertytyperequireddescription
uri string yes `majordomus://<kind>/<identity>`, or a URI a query projects (`majordomus://repository`).
JSON Schema
{
  "additionalProperties": false,
  "description": "The input of `objects.get`: which object.",
  "properties": {
    "uri": {
      "description": "`majordomus://<kind>/<identity>`, or a URI a query projects\n(`majordomus://repository`).",
      "type": "string"
    }
  },
  "required": [
    "uri"
  ],
  "title": "GetInput",
  "type": "object"
}

output · ResourceView

The answer of `objects.get`: what the URI resolved to, tagged by `source` the way a capability's provenance is.

No properties.

JSON Schema
{
  "$defs": {
    "AnswerView": {
      "description": "A URI a query projects (`majordomus://repository`), answered: the same fields a client\nreads on an [`ObjectView`] where they apply, the answer itself as data, and the text\n`resources/read` returns for the URI.",
      "properties": {
        "answer": {
          "description": "The answer, as the capability's output schema describes it (`capabilities.describe`\ncarries that schema)."
        },
        "content": {
          "description": "The answer as text: byte for byte what `resources/read` returns for the URI.",
          "type": "string"
        },
        "description": {
          "description": "The capability's description, when it has one.",
          "type": [
            "string",
            "null"
          ]
        },
        "id": {
          "description": "The capability that answered (`repository.info`).",
          "type": "string"
        },
        "identity": {
          "description": "The resource name a client lists (`repository`).",
          "type": "string"
        },
        "kind": {
          "$ref": "#/$defs/CapabilityKind",
          "description": "Its kind: `query`."
        },
        "media_type": {
          "description": "`application/json`.",
          "type": "string"
        },
        "provenance": {
          "$ref": "#/$defs/CapabilityProvenance",
          "description": "Where the capability comes from: the Rust module it is composed in."
        },
        "title": {
          "description": "The capability's title.",
          "type": "string"
        },
        "uri": {
          "description": "The URI as given.",
          "type": "string"
        }
      },
      "required": [
        "uri",
        "id",
        "kind",
        "identity",
        "title",
        "answer",
        "provenance",
        "media_type",
        "content"
      ],
      "type": "object"
    },
    "CapabilityKind": {
      "description": "What a capability is. Three kinds exist because three semantics exist: something that\nis executed and changes nothing, something that is executed and changes this process's\nown memory, and something that is read. Nothing of any kind writes to the repository.\n\nHow *long* a call takes is not a kind. A read that walks every file of the layer is\nstill a read, and the thing that makes it worth watching — that it reports as it goes\nand stops when it is asked to — is one property of its handler, declared with\n[`crate::capability::Executable::cancellable`] and carried on [`ExecutionPolicy`].",
      "oneOf": [
        {
          "const": "query",
          "description": "Executable and read-only: a typed handler, an input schema, an output schema.",
          "type": "string"
        },
        {
          "const": "command",
          "description": "Executable with an effect on this process's in-memory state and nowhere else (a\npeer announcing itself): a typed handler, bound to `POST` over HTTP, and announced\nto MCP clients as not read-only.",
          "type": "string"
        },
        {
          "const": "resource",
          "description": "Declarative content the repository holds: read as it is, never executed.",
          "type": "string"
        }
      ]
    },
    "CapabilityProvenance": {
      "description": "Where a capability came from. Never an absolute path.",
      "oneOf": [
        {
          "description": "Written in Rust, in the named module of this executable.\nWritten in Rust, composed in `builtin.rs`.",
          "properties": {
            "module": {
              "description": "The Rust module the descriptor was composed in.",
              "type": "string"
            },
            "source": {
              "const": "builtin",
              "type": "string"
            }
          },
          "required": [
            "source",
            "module"
          ],
          "type": "object"
        },
        {
          "description": "Read from the repository's layer.",
          "properties": {
            "directory": {
              "description": "The directory the path sits in, repository-relative; `.` for the root.",
              "type": "string"
            },
            "media_type": {
              "description": "IANA media type of the object's content.",
              "type": "string"
            },
            "member": {
              "description": "For one member of a collection file, its key path in the file (`claims.3`).",
              "type": [
                "string",
                "null"
              ]
            },
            "path": {
              "description": "Repository-relative path.",
              "type": "string"
            },
            "section": {
              "description": "The manifest section the path falls under, when it falls under one.",
              "type": [
                "string",
                "null"
              ]
            },
            "source": {
              "const": "declarative",
              "type": "string"
            },
            "source_class": {
              "description": "The `sources.yaml` class that discovered the file.",
              "type": "string"
            }
          },
          "required": [
            "source",
            "path",
            "directory",
            "source_class",
            "media_type"
          ],
          "type": "object"
        }
      ]
    },
    "ObjectProvenance": {
      "description": "Where an object came from. Every field is computed from the repository, never authored.",
      "properties": {
        "bytes": {
          "description": "Size of the file in bytes.",
          "format": "uint64",
          "minimum": 0,
          "type": "integer"
        },
        "directory": {
          "description": "The directory the path sits in, repository-relative; `.` for the root. This is the\nhierarchy position a client orders by; no merge semantics are implied.",
          "type": "string"
        },
        "member": {
          "description": "For an object that is one member of a collection file: the member's key path in\nthe file (`claims.3`).",
          "type": [
            "string",
            "null"
          ]
        },
        "path": {
          "description": "Repository-relative path, forward slashes, as the version-control index names it.",
          "type": "string"
        },
        "section": {
          "description": "The manifest section the path falls under (`rules`, `prompts`, ...), when it falls\nunder one; a root `README.md` falls under none.",
          "type": [
            "string",
            "null"
          ]
        },
        "source_class": {
          "description": "The `sources.yaml` class that discovered the file (`rule`, `readme`, ...).",
          "type": "string"
        }
      },
      "required": [
        "path",
        "directory",
        "source_class",
        "bytes"
      ],
      "type": "object"
    },
    "ObjectView": {
      "description": "One declarative object of the repository's layer, as a client reads it.",
      "properties": {
        "content": {
          "description": "The file as read.",
          "type": "string"
        },
        "description": {
          "description": "The one-line description the kind's description field held, when it held one.",
          "type": [
            "string",
            "null"
          ]
        },
        "id": {
          "description": "The capability id, `<kind>.<identity>`.",
          "type": "string"
        },
        "identity": {
          "description": "The identity within the kind (`majordomus.scope-integrity@1`, `continue`, a path).",
          "type": "string"
        },
        "kind": {
          "description": "The kind the object was read as (`rule`, `prompt`, `document`, ...).",
          "type": "string"
        },
        "media_type": {
          "description": "IANA media type of `content` (`text/markdown`, `application/yaml`, `application/json`, `text/plain`).",
          "type": "string"
        },
        "metadata": {
          "description": "The parsed front matter or YAML, keys in the file's order."
        },
        "provenance": {
          "$ref": "#/$defs/ObjectProvenance",
          "description": "Where the object came from: path, directory, source class, section, size, member."
        },
        "title": {
          "description": "The title the kind's title rule found, when it found one.",
          "type": [
            "string",
            "null"
          ]
        },
        "uri": {
          "description": "`majordomus://<kind>/<identity>`.",
          "type": "string"
        }
      },
      "required": [
        "uri",
        "id",
        "kind",
        "identity",
        "metadata",
        "provenance",
        "media_type",
        "content"
      ],
      "type": "object"
    }
  },
  "description": "The answer of `objects.get`: what the URI resolved to, tagged by `source` the way a\ncapability's provenance is.",
  "oneOf": [
    {
      "$ref": "#/$defs/ObjectView",
      "description": "A file of the layer, read as it is.",
      "properties": {
        "source": {
          "const": "declarative",
          "type": "string"
        }
      },
      "required": [
        "source"
      ],
      "type": "object"
    },
    {
      "$ref": "#/$defs/AnswerView",
      "description": "A query with a resource exposure, executed and rendered as a JSON document.",
      "properties": {
        "source": {
          "const": "builtin",
          "type": "string"
        }
      },
      "required": [
        "source"
      ],
      "type": "object"
    }
  ],
  "title": "ResourceView"
}

Policies

benchmark
required — a target on every transport the exposure declares; the cases are the input type's
cache
disabled — every call runs the handler

Benchmark targets

Derived from the registry for this repository: one requirement per transport, and the cases the input type provides. The whole matrix is on the benchmarks page.

transportstatecasestargets
directcovered2first-object
repository
mcpcovered2first-object
repository
httpcovered2first-object
repository

Claims implemented beside it

Attached by the file that implements each claim; every one links to its page with the implementation and the test that proves it.

The moments this answers