agent-backend

agent-backend is an agent for coding agents from jeftarmascarenhas/context-mesh. It costs 0 tokens per session (709 once invoked), scanned A, original, MIT.

A backend coding agent for adding weather lookup to a TypeScript weather app through the Open-Meteo service.

In plain words
What is it for?
Use it to create the weather service, API route, request and response types, error handling, weather descriptions, and Swagger documentation.
Why use it?
It provides the server-side code needed to turn a city name into coordinates and current weather data without changing the frontend.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/jeftarmascarenhas/context-mesh/agent-backend
Clone the repo
git clone --depth 1 https://github.com/jeftarmascarenhas/context-mesh

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for agent-backend

README.md
[![agentmods](https://agentmods.dev/badge/agents/jeftarmascarenhas/context-mesh/agent-backend.svg)](https://agentmods.dev/agents/jeftarmascarenhas/context-mesh/agent-backend)
Your own site
<a href="https://agentmods.dev/agents/jeftarmascarenhas/context-mesh/agent-backend"><img src="https://agentmods.dev/badge/agents/jeftarmascarenhas/context-mesh/agent-backend.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 709 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00709
Opus 5 $0.00000 $0.00354
Sonnet 5 $0.00000 $0.00142
Haiku 4.5 $0.00000 $0.00071

Measured 5d ago against content hash af0bfc7552e8, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

agent-backend scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

- [ ] Test: `curl "http://localhost:3000/api/weather?city=London"` returns data
examples/weather-app-minimal/context/agents/agent-backend.md · 92 lines

How it starts

The opening of the file, as written. The whole thing — 92 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agent: Backend - Weather App

Purpose

Implement the weather service and API route with Open-Meteo integration (geocoding + weather).

Context Files to Load

  • @context/intent/feature-weather-display.md
  • @context/decisions/002-api-integration.md
  • @context/knowledge/patterns/api-design.md

Scope

  • Allowed directories: backend/src/
  • Prohibited: Don't modify frontend

Execution Steps

  1. Create Weather Service

    • Create backend/src/services/weather.service.ts
    • Implement Open-Meteo Geocoding API call (city name → coordinates)
    • Implement Open-Meteo Weather API call (coordinates → weather)
    • Map WMO weather codes to descriptions and icons
    • Handle API errors gracefully
    • Transform response to simplified format
  2. Create Weather Route

    • Create backend/src/routes/weather.routes.ts
    • Implement GET /api/weather?city={city}
    • Add Swagger schema documentation
    • Register route in app.ts
  3. Create Types

    • Create backend/src/types/weather.ts
    • Define request/response interfaces
    • Define geocoding and weather API response types

Expected Output

backend/src/
├── services/
│   └── weather.service.ts
├── routes/
│   └── weather.routes.ts
├── types/
│   └── weather.ts
├── plugins/
│   ├── swagger.ts
│   └── cors.ts
└── app.ts (updated with routes)

API Response Format

// GET /api/weather?city=London
{
  "success": true,
  "data": {
    "city": "London",
    "country": "United Kingdom",
    "temperature": 15.2,
    "description": "Overcast",
    "icon": "☁️",
    "windSpeed": 8.5,
    "windDirection": 180
  }
}

Implementation Notes

  1. Geocoding First: Call https://geocoding-api.open-meteo.com/v1/search?name={city}&count=1
  2. Weather Second: Use coordinates from geocoding to call https://api.open-meteo.com/v1/forecast?latitude={lat}&longitude={lon}&current_weather=true
  3. Weather Code Mapping: Map WMO weather codes (0-99) to descriptions and icons (see 002-api-integration.md)
  4. Error Handling: Handle cases where city is not found or API fails

Read the full file on GitHub · 92 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 92 lines · 0 tokens per session scan A af0bfc7552e8

Subscribe to this mod's changes

agent-backend is an agent published in the GitHub repository jeftarmascarenhas/context-mesh (39 stars, last pushed 7mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 709 tokens. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.