---
summary: "Three field-test fixes against T3 / Breedbase image surfaces: collapse double slashes in resolved imageURL paths, wire the SGN row normalizer through brapi_get_image, and coerce numeric-string image dimensions at schema-validation time."
breaking: false
security: false
---

# 0.6.1 — 2026-05-22

## Fixed

- **`brapi_get_image` collapses double slashes in resolved `imageURL`** ([`src/mcp-server/tools/definitions/brapi-get-image.tool.ts`](./src/mcp-server/tools/definitions/brapi-get-image.tool.ts)) — `resolveImageUrl` now parses the resolved URL and replaces consecutive slashes in `pathname` with a single slash, leaving the query string and fragment untouched. T3-family servers occasionally emit absolute `imageURL` values like `https://wheat.triticeaetoolbox.org//data/images/abc.jpg`; the verbatim fetch 404'd. Same pass also documents the four schemeless cases the resolver handles.
- **SGN row normalizer wired into `brapi_get_image`** ([`src/mcp-server/tools/definitions/brapi-get-image.tool.ts`](./src/mcp-server/tools/definitions/brapi-get-image.tool.ts)) — the singleton `/images/{imageDbId}` fetch now runs through `dialect.normalizeRow('images', …)` before output validation. CassavaBase / Breedbase emit `description: null`, `copyright: null` etc. for unset fields; without the normalizer the upstream null reached `z.string().optional()` and tripped output-schema rejection. The find_* surface already had this wired; the per-id path was the gap.
- **Numeric-string image dimensions coerced at schema-validation time** ([`src/mcp-server/tools/definitions/brapi-find-images.tool.ts`](./src/mcp-server/tools/definitions/brapi-find-images.tool.ts), [`src/mcp-server/tools/definitions/brapi-get-image.tool.ts`](./src/mcp-server/tools/definitions/brapi-get-image.tool.ts)) — `imageHeight`, `imageWidth`, and `imageFileSize` now use `z.coerce.number()` instead of bare `z.number()`. T3 and Breedbase commonly serialize these as strings (`"480"` rather than `480`); the row normalizer strips nulls but doesn't coerce types, so the upstream string reached the schema and Zod rejected with `Invalid input: expected number, received string`. Coercion runs at the framework's output-parse boundary — the inline handler return continues to mirror the upstream shape.
