{
  "$schema": "https://static.modelcontextprotocol.io/schemas/server-card/2025-06-18.json",
  "name": "shared-forest",
  "title": "Shared Forest",
  "description": "Shared Forest is a free, shared illustrated forest that grows from its traffic. Every page load adds growth energy, and every visitor, human or AI agent, can plant one tree per day.",
  "version": "1.0.0",
  "icon": "https://sharedforest.com/icon-512.png",
  "icons": [
    {
      "src": "https://sharedforest.com/icon-512.png",
      "mimeType": "image/png",
      "sizes": [
        "512x512"
      ]
    }
  ],
  "serverUrl": "https://sharedforest.com/mcp",
  "url": "https://sharedforest.com/mcp",
  "transport": {
    "type": "streamable-http",
    "url": "https://sharedforest.com/mcp"
  },
  "protocolVersion": "2025-06-18",
  "protocolVersions": [
    "2025-06-18",
    "2025-03-26",
    "2024-11-05"
  ],
  "authentication": {
    "type": "oauth2",
    "required": false,
    "description": "Read tools and plant_tree need no authentication. start_sponsorship needs scope sponsor:write; get_order, my_orders and my_trees need account:read. OAuth 2.1: authorization code with PKCE S256, Dynamic Client Registration, refresh token rotation. 120 requests per minute per IP address.",
    "protectedResourceMetadata": "https://sharedforest.com/.well-known/oauth-protected-resource/mcp",
    "authorizationServer": "https://sharedforest.com/.well-known/oauth-authorization-server",
    "scopes": [
      "forest:read",
      "sponsor:write",
      "account:read"
    ],
    "toolScopes": {
      "start_sponsorship": [
        "sponsor:write"
      ],
      "get_order": [
        "account:read",
        "sponsor:write"
      ],
      "my_orders": [
        "account:read"
      ],
      "my_trees": [
        "account:read"
      ]
    }
  },
  "capabilities": {
    "tools": {},
    "resources": {}
  },
  "tools": [
    {
      "name": "get_forest_stats",
      "title": "Forest statistics",
      "description": "Read-only. Counts of trees, groves, total and unique visitors, and traffic by class (humans, agents, bots, trees planted today).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "fields": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "trees",
                "groves",
                "visitors",
                "uniqueVisitors",
                "humans",
                "agents",
                "bots",
                "plantedToday"
              ]
            },
            "uniqueItems": true,
            "description": "Return only these counters. Omit for all counters."
          }
        },
        "required": [],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "get_forest",
      "title": "Forest summary",
      "description": "Read-only. Bounded summary of the live forest: counts per tree type, growth stage and origin, grove levels, and the newest trees (default 20, max 100).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "default": 20,
            "description": "Number of newest trees to return."
          },
          "bbox": {
            "type": "array",
            "items": {
              "type": "number"
            },
            "minItems": 4,
            "maxItems": 4,
            "description": "Bounding box [minX, minY, maxX, maxY] in world coordinates. Only trees inside it are returned."
          }
        },
        "required": [],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "list_trees",
      "title": "List trees",
      "description": "Read-only. One page of trees with cursor pagination, the same data as GET /api/forest?limit=. Pass nextCursor as cursor until it is null.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 500,
            "description": "Trees per page, for example 100."
          },
          "cursor": {
            "type": "string",
            "description": "Opaque cursor from nextCursor of the previous page."
          },
          "bbox": {
            "type": "array",
            "items": {
              "type": "number"
            },
            "minItems": 4,
            "maxItems": 4,
            "description": "Bounding box [minX, minY, maxX, maxY] in world coordinates. Only trees inside it are returned."
          }
        },
        "required": [
          "limit"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "plant_tree",
      "title": "Plant a tree",
      "description": "Plant one tree in the Shared Forest for the caller. One tree per visitor per day; repeats only add growth energy. The visit counts as agent traffic. Ask the user before you call it.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "idempotency_key": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "Optional retry key, for example a UUID. A retry with the same key within 24 hours returns the first visitId and plants nothing new."
          }
        },
        "required": [],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": true
      }
    },
    {
      "name": "explain_shared_forest",
      "title": "Explain Shared Forest",
      "description": "Read-only. Returns the full agent guide as Markdown: growth rules, API, tools and limits.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "section": {
            "type": "string",
            "description": "Return only the section whose heading contains this text, for example 'Limits' or 'MCP tools'. Omit for the whole guide."
          }
        },
        "required": [],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "get_price_quote",
      "title": "Quote a tree sponsorship",
      "description": "Read-only. Price for sponsoring N trees for 12 months: unit price, total in euro cents (VAT included) and discount. Call it before you tell the user a price.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "quantity": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "description": "Number of trees, 1-100. Larger orders get a lower unit price."
          }
        },
        "required": [
          "quantity"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "design_tree",
      "title": "Design a sponsored tree",
      "description": "Turns a short wish (for example 'a silver birch with lanterns') into a custom tree design. Returns design_id and the tree genome. Max 3 designs per caller per day. Show the result to the user before you order.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "wish": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "What the tree should look like, 1-200 characters. No brands, logos or text."
          }
        },
        "required": [
          "wish"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": false,
        "openWorldHint": false
      }
    },
    {
      "name": "get_design",
      "title": "Read a tree design",
      "description": "Read-only. Returns one design by design_id: genome, genomeHash and expiresAt.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "design_id": {
            "type": "string",
            "pattern": "^dsn_[A-Za-z0-9_-]{4,64}$",
            "description": "Design id from design_tree, for example dsn_abc123."
          }
        },
        "required": [
          "design_id"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "find_spots",
      "title": "Find free spots",
      "description": "Read-only. Suggests free positions for N sponsored trees, optionally near a point. Pass the spots to start_sponsorship, or omit spots there and the server picks them.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "quantity": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "description": "Number of trees, 1-100. Larger orders get a lower unit price."
          },
          "near_x": {
            "type": "number",
            "minimum": 0,
            "maximum": 8192,
            "description": "Optional x coordinate (0-8192) to search near. Needs near_y."
          },
          "near_y": {
            "type": "number",
            "minimum": 0,
            "maximum": 8192,
            "description": "Optional y coordinate (0-8192) to search near. Needs near_x."
          }
        },
        "required": [
          "quantity"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "start_sponsorship",
      "title": "Start a tree sponsorship",
      "description": "Needs OAuth scope sponsor:write (a Shared Forest account). Creates an unpaid order for the signed-in user and holds the spots. It charges nothing. The total must fit the spending limit the user set when connecting. The order expires after 30 minutes unless the user confirms. Returns confirm_url: give it to your user. The user logs in, accepts the terms and pays on that page. Ask the user before you call it and confirm name and total.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "quantity": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "description": "Number of trees, 1-100. Larger orders get a lower unit price."
          },
          "design_ids": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^dsn_[A-Za-z0-9_-]{4,64}$",
              "description": "Design id."
            },
            "minItems": 1,
            "maxItems": 100,
            "description": "One design_id for all trees, or one per tree."
          },
          "spots": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "x": {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 8192
                },
                "y": {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 8192
                }
              },
              "required": [
                "x",
                "y"
              ],
              "additionalProperties": false
            },
            "minItems": 1,
            "maxItems": 100,
            "description": "Optional positions from find_spots, one per tree. Omit and the server picks free spots."
          },
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 32,
            "description": "Name shown on the trees, 1-32 characters, labelled Sponsored."
          },
          "link": {
            "type": "string",
            "format": "uri",
            "pattern": "^https://",
            "maxLength": 2048,
            "description": "Optional https link. It goes live after manual review."
          },
          "email": {
            "type": "string",
            "format": "email",
            "maxLength": 254,
            "description": "Optional email for the confirmation and the invoice. Default: the email of the signed-in account."
          },
          "idempotency_key": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "Retry key, for example a UUID. A retry with the same key returns the same order."
          }
        },
        "required": [
          "quantity",
          "design_ids",
          "display_name",
          "idempotency_key"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": false,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": true
      }
    },
    {
      "name": "get_order",
      "title": "Read a sponsorship order",
      "description": "Read-only. Needs OAuth scope account:read or sponsor:write. Status of one of the user's orders (open, paid, fulfilled, expired, refunded, disputed, cancelled, refund_pending) and its tree ids once fulfilled. Poll every 10 seconds or more after the user pays.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "order_id": {
            "type": "string",
            "pattern": "^ord_[A-Za-z0-9_-]{4,64}$",
            "description": "Order id from start_sponsorship, for example ord_abc123."
          }
        },
        "required": [
          "order_id"
        ],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "my_orders",
      "title": "My sponsorship orders",
      "description": "Read-only. Needs OAuth scope account:read. The signed-in user's sponsorship orders, newest first, with status, total and tree ids.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 50,
            "default": 20,
            "description": "Number of orders, 1-50."
          }
        },
        "required": [],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    },
    {
      "name": "my_trees",
      "title": "My sponsored trees",
      "description": "Read-only. Needs OAuth scope account:read. The trees of the signed-in user's fulfilled orders, with a link to each tree in the forest.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 500,
            "default": 100,
            "description": "Number of trees, 1-500."
          }
        },
        "required": [],
        "additionalProperties": false
      },
      "annotations": {
        "readOnlyHint": true,
        "destructiveHint": false,
        "idempotentHint": true,
        "openWorldHint": false
      }
    }
  ],
  "resources": [
    {
      "uri": "https://sharedforest.com/llms-full.txt",
      "name": "Shared Forest agent guide",
      "mimeType": "text/markdown"
    }
  ],
  "documentation": "https://sharedforest.com/developers",
  "openapi": "https://sharedforest.com/openapi.json",
  "repository": "https://github.com/ArneFfm/shared-forest-agents"
}