Skip to main content
Glama

secret_inspect

Read-only

Inspect a Docker swarm secret's metadata by id or name, returning creation time, labels, and driver details without exposing the secret's actual data.

Instructions

Get a swarm secret's metadata by id or name; requires a swarm manager.

The returned attrs never include the secret's actual data (Spec.Data is write-only - the daemon accepts it on secret_create but never returns it back, by design). Use this to check a secret's CreatedAt, Labels, or which driver created it, not to read its contents. To see which services reference it, inspect each service's spec via service_inspect (there is no server-side filter for "services using this secret").

Returns: dict: The secret's full document, excluding the actual secret data

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
id_or_nameYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.0.0

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only provide readOnlyHint and destructiveHint, but the description adds critical behavior: Spec.Data is write-only and never returned, so the tool cannot expose secret contents. It also adds the swarm-manager requirement, going well beyond the structured hints.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the main purpose, and every additional sentence adds value: data exclusion, intended use cases, and the service_inspect alternative. The Returns block is structured and non-redundant.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given there is no output schema, the description explains the return shape (dict excluding secret data), the access prerequisite, and the tool's limitations. An agent has enough context to invoke it correctly and interpret the result.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema provides only a required id_or_name string with no description, so the description carries the burden. It clarifies that the parameter accepts either a secret id or name, which is the essential meaning; a single self-descriptive string parameter needs little more.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: 'Get a swarm secret's metadata by id or name.' It clearly distinguishes the tool from secret_list by focusing on a single secret's metadata and explicitly says it is not for reading contents.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly states the swarm manager prerequisite and gives concrete use cases: checking CreatedAt, Labels, or driver. It also names the alternative for service references: service_inspect, with a clear reason that no server-side filter exists.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools