Skip to main content
Glama
orjahren

Nettskjema MCP Server

by orjahren

upload_image

Upload an image file to the Nettskjema API by base64-encoding it and sending it as JSON, with the filename supplied as a query parameter.

Instructions

Upload an image to the API, returning a response with string keys and values.

The entire file is read into memory, base64-encoded, and sent as a JSON string in the request body, per the published OpenAPI schema ({"type": "string", "format": "byte"} under application/json). The filename is derived from the file itself and sent as a query parameter.

The body format is most likely a Spring Boot serialisation artefact where a byte[] parameter was rendered as format: byte. The actual server may expect raw bytes; whether it accepts the JSON string can only be settled end-to-end.

Input Schema

NameRequiredDescriptionDefault
file_pathYesPath to the image file to upload. May be relative or contain ~.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior4/5

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

With no annotations, the description carries the full behavioral burden and does substantial work: it discloses in-memory file reading, base64 encoding, JSON string body format, derived filename query parameter, and uncertainty about the server's actual expected body. It omits auth, error handling, and size limits, but is unusually transparent for a no-annotation tool.

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

Conciseness2/5

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

The purpose is front-loaded, but the description is bloated with speculative OpenAPI and Spring Boot implementation details. The final paragraph about an uncertain serialization artefact is lengthy and may confuse an agent more than it helps; a shorter description would be more effective.

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 values need not be explained, and the description covers the upload's unusual body handling and the one required input. It still lacks auth requirements and error behavior, but is largely complete for a one-parameter upload tool with no annotations.

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

Parameters3/5

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

Schema description coverage is 100% for the single file_path parameter, so the schema already documents its meaning and acceptable forms. The description adds behavioral context about filename derivation but does not deepen the semantics of file_path itself, so the baseline of 3 is appropriate.

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

Purpose4/5

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

The first sentence states a clear verb and resource: 'Upload an image to the API.' It is specific enough for an agent to understand the operation, but it does not distinguish this tool from sibling upload tools such as upload_submission_attachment or upload_codebook.

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

Usage Guidelines2/5

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

The description gives no explicit guidance about when to use this tool versus alternatives. It implies usage for image uploads but never names conditions, exclusions, or sibling tools, leaving the agent to infer routing.

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