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

conversationsLeave

Leaves a conversation.

Details

  • Method: POST
  • Path: /conversations.leave
  • Operation ID: conversations_leave

Parameters

{
  "token": {
    "description": "Authentication token. Requires scope: `conversations:write`",
    "required": false,
    "location": "header",
    "type": "string"
  },
  "channel": {
    "description": "Conversation to leave",
    "required": false,
    "location": "formData",
    "type": "string"
  }
}

Response Schema

{
  "additionalProperties": false,
  "description": "Schema for successful response from conversations.leave method",
  "properties": {
    "not_in_channel": {
      "enum": [
        true
      ],
      "type": "boolean"
    },
    "ok": {
      "enum": [
        true
      ],
      "title": "default success response",
      "type": "boolean"
    }
  },
  "required": [
    "ok"
  ],
  "title": "conversations.leave success schema",
  "type": "object"
}

Usage

from ocp_agent import OCPAgent

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

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