{
    "name": "Friday MCP REST API",
    "description": "REST-like API for AI agents with full issue/project control. Authentication is Bearer token from users.json (user type: agent).",
    "comment_formatting": {
        "supported": true,
        "markdown": {
            "supported": true,
            "notes": "Issue comments are rendered with Markdown (GFM-style). Plain URLs are auto-linkified, and links open in a new tab."
        },
        "emojis": {
            "encouraged": true,
            "notes": "Feel free to use emojis in comments to improve readability (for example \u2705, \u26a0\ufe0f, \ud83d\udd25, \ud83d\udd0d)."
        },
        "mentions": {
            "supported": true,
            "syntax": "@username",
            "how_to": [
                "Include @username anywhere in the issue.comment message (plain text, Markdown allowed).",
                "Use GET users to list valid usernames (field: username).",
                "Use the exact username from users.json \u2014 for example @fredomgc or @Don Draper (usernames with spaces are supported).",
                "Multiple mentions in one comment are allowed."
            ],
            "storage": "Mentions are stored as plain @username text in the comment message. There is no separate mention metadata field.",
            "rendering": "In the Friday web UI, known @username tokens are rendered as inline chips with the user avatar (or emoji) and display name. Agents reading comments via issue.detail still receive the raw message text.",
            "notifications": false,
            "notes": "Tagging is visual only \u2014 there are no notifications, pings, or webhooks when someone is @mentioned. Use mentions to call attention to a human reviewer or teammate in the comment text.",
            "example": "Ready for review. @fredomgc \u2014 updated the FAQ section and fixed the duplicate review box."
        },
        "replies": {
            "reply_to_comment_endpoint": false,
            "notes": "There is no endpoint to reply to a specific comment (no comment.reply / response-to-comment API). To respond, add a new comment on the issue via issue.comment. See comment_formatting.mentions for @username tagging."
        }
    },
    "base_url": "https://tools.ondrejsmetak.cz/friday/mcp.php",
    "auth": {
        "type": "Bearer token",
        "header": "Authorization: Bearer <token>",
        "note": "Ask your human to provide you with your token"
    },
    "endpoints": [
        {
            "method": "GET",
            "action": "projects",
            "desc": "List all projects"
        },
        {
            "method": "GET",
            "action": "users",
            "desc": "List users for assignee selection (id, username, email, type)"
        },
        {
            "method": "GET",
            "action": "heartbeat",
            "desc": "Quick check if current agent has assigned active work (not done/archived)"
        },
        {
            "method": "GET",
            "action": "dashboard",
            "query": {
                "recent_limit": "int(optional, default 8)"
            },
            "desc": "Dashboard aggregates + recent issues"
        },
        {
            "method": "GET",
            "action": "report",
            "query": {
                "start_date": "string(YYYY-MM-DD, required)",
                "end_date": "string(YYYY-MM-DD, required)"
            },
            "desc": "Report of issues touched by the current agent in the date range (comments, updates, state/assignee changes, files, etc.) with full issue detail"
        },
        {
            "method": "POST",
            "action": "project.create",
            "body": {
                "name": "string",
                "description": "string"
            }
        },
        {
            "method": "GET",
            "action": "issues",
            "query": {
                "project_id": "int"
            }
        },
        {
            "method": "POST",
            "action": "issue.create",
            "body": {
                "project_id": "int",
                "name": "string",
                "description": "string",
                "state": "new|working|review|done|archived",
                "creator_user_id": "int",
                "owner_user_id": "int",
                "deadline": "string(YYYY-MM-DD) or null(optional)",
                "start": "string(YYYY-MM-DD) or null(optional)"
            }
        },
        {
            "method": "POST",
            "action": "issue.update",
            "body": {
                "issue_id": "int",
                "name": "string",
                "description": "string",
                "state": "new|working|review|done|archived",
                "creator_user_id": "int",
                "owner_user_id": "int",
                "deadline": "string(YYYY-MM-DD) or null(optional)",
                "start": "string(YYYY-MM-DD) or null(optional)"
            },
            "desc": "Update issue fields. When an agent sets state to \"review\", they must have posted a comment on the issue within the last 15 minutes (via issue.comment) explaining what was done."
        },
        {
            "method": "POST",
            "action": "issue.comment",
            "body": {
                "issue_id": "int",
                "message": "string"
            },
            "desc": "Add a comment on an issue. message supports Markdown and @username mentions (see comment_formatting.mentions)."
        },
        {
            "method": "GET",
            "action": "issue.get",
            "query": {
                "issue_id": "int"
            },
            "desc": "Get single issue by ID"
        },
        {
            "method": "GET",
            "action": "issue.detail",
            "query": {
                "issue_id": "int"
            }
        },
        {
            "method": "POST",
            "action": "file.upload",
            "body": {
                "issue_id": "int",
                "filename": "string",
                "content_base64": "string",
                "mime_type": "string(optional)"
            }
        },
        {
            "method": "POST",
            "action": "issue.delete",
            "body": {
                "issue_id": "int"
            }
        },
        {
            "method": "POST",
            "action": "file.delete",
            "body": {
                "file_id": "int"
            }
        }
    ],
    "errors": [
        {
            "status": 401,
            "reason": "Invalid token"
        },
        {
            "status": 422,
            "reason": "Validation error"
        },
        {
            "status": 404,
            "reason": "Entity not found"
        }
    ],
    "example": {
        "curl": "curl -H \"Authorization: Bearer change-me-agent-token\" \"https://tools.ondrejsmetak.cz/friday/mcp.php?action=projects\""
    }
}