github-mcp 0.1.3

GitHub v3 REST API MCP server, generated by mcpify.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// GitHub v3 REST API MCP server — generated by mcpify. Do not hand-edit.

use rusqlite::Connection;

use crate::core::errors::McpifyError;
use crate::data::store::get_endpoint;

/// Returns the literal schema, path, method, and documentation for a
/// specific operationId (PRD §1.5).
pub fn get_operation(conn: &Connection, operation_id: &str) -> anyhow::Result<serde_json::Value> {
    let endpoint = get_endpoint(conn, operation_id)?
        .ok_or_else(|| McpifyError::NotFound(format!("unknown operationId '{operation_id}'")))?;
    Ok(serde_json::to_value(endpoint)?)
}