Skip to main content
Glama

Brapi Connect

brapi_connect
Idempotent

Open a connection to a BrAPI v2 server, authenticate, and return the full orientation envelope (server identity, capability profile, content summary, suggested next tools). Required handshake before other BrAPI tools. Supports multiple concurrent connections via named aliases. Credentials can be configured server-side and omitted from this call. When a request carries no MCP session on a deployment without per-user auth, aliases live in one namespace shared by every such caller: re-registering an alias re-points their later calls to it. Built-in known servers (callable with no baseUrl or auth — public BrAPI v2 endpoints): bti-breedbase-demo, bti-cassava, bti-sweetpotato. Operator-configured aliases on this deployment (credentials and/or baseUrl read from server env vars): default, cassava. Aliases are shortcuts only; any other BrAPI v2 server is reachable by passing baseUrl directly.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
authNoAuth payload. Omit to use credentials configured server-side for this alias (or no auth when none are configured).
aliasNoAlias for this connection. Use distinct aliases to register multiple BrAPI servers in one session.default
baseUrlNoBrAPI v2 base URL (absolute URL) including any path prefix — e.g. https://test-server.brapi.org/brapi/v2. Omit to use the configured default for this alias.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
authNoAuth summary for the active connection.
aliasNoConnection alias.
errorNoPresent when the call failed. Absent on success.
notesNoServer-specific quirks or degradation notes.
serverNoNormalized server identity block.
baseUrlNoBrAPI v2 base URL for this connection.
contentNoContent summary (crops + optional totals).
dialectNoActive dialect adapter — translates outbound filters and declares known-dead routes for this server.
fetchedAtNoISO 8601 timestamp of when this envelope was composed.
attributionNoAttribution metadata for built-in known-server connections. Absent for custom (env-only) connections.
capabilitiesNoCapability profile derived from /serverinfo.
nextToolSuggestionsNoEntry-point finders (studies, germplasm, variables, locations — in that order) whose GET or POST /search route this server exposes under the active dialect. Empty when none apply.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedOutput schema / anyOf
      Previous value: -[
      -  {
      -    "not": {
      -      "required": [
      -        "error"
      -      ]
      -    },
      -    "required": [
      -      "alias",
      -      "baseUrl",
      -      "server",
      -      "auth",
      -      "capabilities",
      -      "dialect",
      -      "content",
      -      "notes",
      -      "fetchedAt"
      -    ]
      -  },
      -  {
      -    "required": [
      -      "error"
      -    ]
      -  }
      -]New value: +[
      +  {
      +    "not": {
      +      "required": [
      +        "error"
      +      ]
      +    },
      +    "required": [
      +      "alias",
      +      "baseUrl",
      +      "server",
      +      "auth",
      +      "capabilities",
      +      "dialect",
      +      "content",
      +      "nextToolSuggestions",
      +      "notes",
      +      "fetchedAt"
      +    ]
      +  },
      +  {
      +    "required": [
      +      "error"
      +    ]
      +  }
      +]
    • changedOutput schema / properties / error / properties / data / properties / reason / description
      Previous value: -"Machine-readable failure mode. Declared by this tool: `auth_token_exchange_failed`: SGN or OAuth token exchange against the BrAPI /token endpoint failed. `auth_no_access_token`: Token endpoint responded but did not return an access_token. Other values are possible when a failure originates below the handler."New value: +"Machine-readable failure mode. Declared by this tool: `auth_session_required`: Caller-supplied credentials on an HTTP deployment without per-user auth, from a request that carries no MCP session. `auth_base_url_mismatch`: The alias has server-configured credentials and the supplied baseUrl differs from the server configured for it. `alias_base_url_unset`: The alias has server-configured credentials but no base URL of its own (no BRAPI_<ALIAS>_BASE_URL and no enabled built-in), so they pair with no server. `auth_token_exchange_failed`: SGN or OAuth token exchange against the BrAPI /token endpoint failed. `auth_no_access_token`: Token endpoint responded but did not return an access_token. `upstream_unauthorized`: The server answered HTTP 401 on /serverinfo or /calls — it requires login for capability discovery. `upstream_forbidden`: The server answered HTTP 403 on /serverinfo or /calls — the request (anonymous or credentialed) lacks read access. Other values are possible when a failure originates below the handler."
    • changedOutput schema / properties / error / properties / data / properties / reason / examples
      Previous value: -[
      -  "auth_token_exchange_failed",
      -  "auth_no_access_token"
      -]New value: +[
      +  "auth_session_required",
      +  "auth_base_url_mismatch",
      +  "alias_base_url_unset",
      +  "auth_token_exchange_failed",
      +  "auth_no_access_token",
      +  "upstream_unauthorized",
      +  "upstream_forbidden"
      +]
    • addedOutput schema / properties / nextToolSuggestions
      Added value: +{
      +  "description": "Entry-point finders (studies, germplasm, variables, locations — in that order) whose GET or POST /search route this server exposes under the active dialect. Empty when none apply.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "A finder the connected server supports, with the arguments to start it.",
      +    "properties": {
      +      "args": {
      +        "additionalProperties": false,
      +        "description": "Arguments to call the tool with. Alias only — narrow further with the tool filters.",
      +        "properties": {
      +          "alias": {
      +            "description": "Connection alias to pass to the suggested tool.",
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "alias"
      +        ],
      +        "type": "object"
      +      },
      +      "reason": {
      +        "description": "Why this tool applies to the connected server.",
      +        "type": "string"
      +      },
      +      "toolName": {
      +        "description": "Entry-point finder tool this server can serve.",
      +        "enum": [
      +          "brapi_find_studies",
      +          "brapi_find_germplasm",
      +          "brapi_find_variables",
      +          "brapi_find_locations"
      +        ],
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "toolName",
      +      "reason",
      +      "args"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  2. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the annotations, the description discloses meaningful behavior: multiple concurrent connections via named aliases, server-side credential configuration, and a namespace-warning that re-registering an alias re-points later calls from shared callers. It also names the built-in public endpoints that require no auth. This is rich, non-obvious behavioral context.

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

Conciseness4/5

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

The description is long but information-dense, and the core purpose is front-loaded in the first sentence. The namespace-sharing caveat and alias lists earn their place because they warn about global side effects that an agent could not infer from the schema. Slightly dense, but not padded.

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

Completeness4/5

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

An output schema exists, so return-value documentation is not required. The complex auth modes, alias semantics, and shared-namespace risks are covered well. The only minor gap is that the description never explicitly states how later BrAPI tools reference the alias, but 'named aliases' plus the re-pointing warning makes this reasonably inferable.

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?

Schema description coverage is 100%, so the baseline is 3. The description adds deployment-specific meaning beyond the schema: concrete aliases like `bti-cassava`, `default`, and `cassava`, the fact that aliases are shortcuts, and that credentials can be omitted when configured server-side. This goes beyond redundant schema explanation.

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 opens with a specific verb and resource: 'Open a connection to a BrAPI v2 server, authenticate, and return the full orientation envelope'. It clearly distinguishes itself as the required handshake before other BrAPI tools, which separates it from all sibling data-retrieval and query tools.

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

Usage Guidelines4/5

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

It explicitly states when to use the tool: 'Required handshake before other BrAPI tools.' It also gives concrete usage context for built-in aliases, operator-configured aliases, and direct baseUrl use. It does not name sibling tools as alternatives, but the prerequisite framing makes the intended usage clear.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.