Skip to main content
Glama

mcp-jenkins

queue_item.py957 B
from mcp.server.fastmcp import Context from mcp_jenkins.server import client, mcp @mcp.tool(tag='read') async def get_all_queue_items(ctx: Context) -> list[dict]: """ Get all items in Jenkins queue Returns: list[dict]: A list of all items in the Jenkins queue """ return [item.model_dump(exclude_none=True) for item in client(ctx).queue_item.get_all_queue_items()] @mcp.tool(tag='read') async def get_queue_item(ctx: Context, id_: int) -> dict: """ Get a specific item in Jenkins queue Args: id_: The id of the queue item Returns: dict: The queue item """ return client(ctx).queue_item.get_queue_item(id_).model_dump(exclude_none=True) @mcp.tool(tag='write') async def cancel_queue_item(ctx: Context, id_: int) -> None: """ Cancel a specific item in Jenkins queue Args: id_: The id of the queue item """ client(ctx).queue_item.cancel_queue_item(id_)

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/lanbaoshen/mcp-jenkins'

If you have feedback or need assistance with the MCP directory API, please join our Discord server