"""
Slack MCP Server — Model Context Protocol server for Slack workspace operations.

An independent, generalized MCP server that can connect to any AI agent
supporting the Model Context Protocol. Not tied to any specific project.

Quick start:
    pip install workos-slack-mcp-server
    SLACK_BOT_TOKEN=xoxb-... slack-mcp-server

Or run as a module:
    python -m slack_mcp_server
"""

__version__ = "1.0.2"

from slack_mcp_server.server import create_server


def main():
    """Entry point for the slack-mcp-server CLI command."""
    import sys
    if "--help" in sys.argv or "-h" in sys.argv:
        print("Slack MCP Server — Model Context Protocol server for Slack")
        print()
        print("Usage: slack-mcp-server")
        print()
        print("Environment variables:")
        print("  SLACK_BOT_TOKEN       Bot User OAuth Token (xoxb-...)  [required]")
        print("  SLACK_USER_TOKEN      User OAuth Token (xoxp-...)      [optional]")
        print("  SLACK_SIGNING_SECRET  Signing secret for verification  [optional]")
        print("  SLACK_LOG_LEVEL       Logging level (default: INFO)    [optional]")
        sys.exit(0)
    server = create_server()
    server.run()


__all__ = ["main", "create_server", "__version__"]
