Skip to main content
Glama
ryft-io

IcebergMCP

by ryft-io

get_namespaces

Retrieve a list of namespaces from the Iceberg catalog to organize and manage data within your lakehouse. Simplifies metadata access for structured data querying and analysis.

Instructions

Provides a list of namespaces from the Iceberg catalog.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Handler function decorated with @mcp.tool() that retrieves and returns a newline-separated list of namespaces from the Iceberg Glue catalog.
    @mcp.tool() def get_namespaces() -> str: """Provides a list of namespaces from the Iceberg catalog.""" catalog = get_catalog() namespaces = catalog.list_namespaces() return "\n".join(ns[0] for ns in namespaces)
  • Helper function that initializes and returns the GlueCatalog using AWS credentials from the configured profile.
    def get_catalog() -> GlueCatalog: try: session = boto3.Session(profile_name=iceberg_config.profile_name) credentials = session.get_credentials().get_frozen_credentials() catalog = GlueCatalog( "glue", **{ "client.access-key-id": credentials.access_key, "client.secret-access-key": credentials.secret_key, "client.session-token": credentials.token, "client.region": iceberg_config.region, }, ) except Exception as e: logger.error(f"Error creating AWS connection: {str(e)}") raise return catalog
  • Configuration variables for AWS profile and region used by get_catalog().
    profile_name = os.environ.get("ICEBERG_MCP_PROFILE") region = os.environ.get("ICEBERG_AWS_REGION") or 'us-east-1'

Other Tools

Related Tools

Latest Blog Posts

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/ryft-io/iceberg-mcp'

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