Open Context Protocol is live! 🚀 Read the launch post
issuesRemoveLabel

issuesRemoveLabel

Remove a label from an issue

Details

  • Method: DELETE
  • Path: /repos/{owner}/{repo}/issues/{issue_number}/labels/{name}
  • Operation ID: issues/remove-label

Parameters

{
  "owner": {
    "description": "The account owner of the repository. The name is not case sensitive.",
    "required": true,
    "location": "path",
    "type": "string"
  },
  "repo": {
    "description": "The name of the repository without the `.git` extension. The name is not case sensitive.",
    "required": true,
    "location": "path",
    "type": "string"
  },
  "issue_number": {
    "description": "The number that identifies the issue.",
    "required": true,
    "location": "path",
    "type": "integer"
  },
  "name": {
    "description": "",
    "required": true,
    "location": "path",
    "type": "string"
  }
}

Response Schema

{
  "type": "array",
  "items": {
    "title": "Label",
    "description": "Color-coded labels help you categorize and filter your issues (just like labels in Gmail).",
    "type": "object",
    "properties": {
      "id": {
        "description": "Unique identifier for the label.",
        "type": "integer",
        "format": "int64",
        "example": 208045946
      },
      "node_id": {
        "type": "string",
        "example": "MDU6TGFiZWwyMDgwNDU5NDY="
      },
      "url": {
        "description": "URL for the label",
        "example": "https://api.github.com/repositories/42/labels/bug",
        "type": "string",
        "format": "uri"
      },
      "name": {
        "description": "The name of the label.",
        "example": "bug",
        "type": "string"
      },
      "description": {
        "description": "Optional description of the label, such as its purpose.",
        "type": "string",
        "example": "Something isn't working",
        "nullable": true
      },
      "color": {
        "description": "6-character hex code, without the leading #, identifying the color",
        "example": "FFFFFF",
        "type": "string"
      },
      "default": {
        "description": "Whether this label comes by default in a new repository.",
        "type": "boolean",
        "example": true
      }
    },
    "required": [
      "id",
      "node_id",
      "url",
      "name",
      "description",
      "color",
      "default"
    ]
  }
}

Usage

from ocp_agent import OCPAgent

agent = OCPAgent()
await agent.register_api('github')

# Call this tool
result = await agent.call_tool('issuesRemoveLabel', {
    # Add required parameters here
})