Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions changelog/0.4.10.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# [0.4.10] - 2025-08-22
# [0.4.10] - 2025-08-20

## Added
## Fixed

- `get_job` tool now supports fetching job details by job ID.
- `run_sql` tool now supports optional username and password parameters for database authentication.
- No authentication flow when `MCP_JWT_TOKEN` and `JWT_ORG_ID` are set in the environment variables.
6 changes: 6 additions & 0 deletions changelog/0.4.11.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# [0.4.11] - 2025-08-22

## Added

- `get_job` tool now supports fetching job details by job ID.
- `run_sql` tool now supports optional username and password parameters for database authentication.
9 changes: 8 additions & 1 deletion src/commands/start.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,20 @@

def start_command(transport: str, host: str):
api_key = os.environ.get("MCP_API_KEY")
jwt_token = os.environ.get("MCP_JWT_TOKEN")
org_id = os.environ.get("MCP_ORG_ID")

if transport == config.Transport.STDIO:
if api_key:
# Silent API key authentication for Docker containers
logger.debug("Using API key authentication")
settings = config.init_settings(transport=transport, host=host)
# API key will be automatically loaded from env vars via Pydantic
elif jwt_token and org_id:
logger.debug("Using JWT token authentication")
settings = config.init_settings(
transport=transport, jwt_token=jwt_token, org_id=org_id, host=host
)
# JWT token and org_id will be automatically loaded from env vars via Pydantic
else:
# Use browser authentication for stdio mode
oauth_token = get_authentication_token()
Expand Down
7 changes: 5 additions & 2 deletions src/config/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,18 @@ def get_user_id() -> str | None:


def init_settings(
transport: Transport, jwt_token: str | None = None, host: str | None = None
transport: Transport,
jwt_token: str | None = None,
org_id: str | None = None,
host: str | None = None,
) -> RemoteSettings | LocalSettings:
match transport:
case Transport.HTTP:
settings = RemoteSettings(transport=Transport.HTTP)
case Transport.SSE:
settings = RemoteSettings(transport=Transport.SSE)
case Transport.STDIO:
settings = LocalSettings(jwt_token=jwt_token, host=host)
settings = LocalSettings(jwt_token=jwt_token, org_id=org_id, host=host)
case _:
raise ValueError(f"Unsupported transport mode: {transport}")

Expand Down
2 changes: 1 addition & 1 deletion src/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.4.9"
__version__ = "0.4.10"