Skip to main content

WXO Bootcamp Lab Hospital Data Server

Project description

Hospital Data MCP Server

A repo to manage an MCP server to enable access to the data set providing hospital data

The data is entirely made up and bears no linkage and or repsentation to any person.

Running: SSE

Need two terminal:

Terminal 1

  1. uv run -m wxo_bootcamp_mcp_server.app_sse : Run the SSE server

Terminal 2

  1. npx @modelcontextprotocol/inspector : Run the inspector for testing

Running: STDIO

Terminal

  1. npx @modelcontextprotocol/inspector : Run the inspector for testing
  2. Use the following setup:
    • Transport Type: STDIO
    • Command: uv run -m wxo_bootcamp_mcp_server.app_stdio
    • Arguments: --no-banner

Podman

You can do this for Terminal 1

  1. from root
  2. podman build .
  3. podman run -p 8080:8080 [Container ID]
  4. npx @modelcontextprotocol/inspector
  5. https://localhost:8080/sse

Deploy to a TechZone zone Code Engine

Pre Reqs:

Use an external IBM Cloud Container Registry

Account A (The one with the Container Registry)

  • $ibmcloud login -a https://cloud.ibm.com --sso
    • Choose the account with the Container
  • $ibmcloud target -r [region]
  • $ibmcloud target -g [group_name]
  • $ibmcloud cr login
  • $ibmcloud cr namespace-add [NAMESPACE]
  • $podman tag wxo-bootcamp-mcp-sever us.icr.io/[NAMESPACE]/[IMAGE_NAME]:[TAG]
  • $podman push us.icr.io/[NAMESPACE]/[IMAGE_NAME]:[TAG]
  • $ibmcloud iam service-id-create [SERVICE_ID_NAME] --description "Service ID for cross-account Container Registry access"
  • $ibmcloud iam service-policy-create [SERVICE_ID_NAME] --roles Reader --service-name container-registry
  • $ibmcloud iam service-api-key-create [API_KEY_NAME] [SERVICE_ID_NAME] --description "API key for cross-account registry access" --file api-key.json
  • To view the API Key and get [API_KEY_VALUE]
    • $cat api-jey.json

Account B (The techzone one with the Code Engine)

  • $ibmcloud login -a https://cloud.ibm.com --sso
    • Choose the account with the Techzone Account
  • $ibmcloud ce login
  • $ibmcloud ce project select -n [PROJECT NAME]
    • The project name is visible in the Code Engine page
  • $ibmcloud ce registry create --name [REGISTRY_SECRET_NAME] --server us.icr.io --username iamapikey --password [API_KEY_VALUE]
  • $ibmcloud ce application create --name [APP_NAME] --image us.icr.io/[NAMESPACE]/[IMAGE_NAME]:[TAG] --registry-secret [REGISTRY_SECRET_NAME]

Use everything on the Techzone instance

  • $ibmcloud login -a https://cloud.ibm.com --sso
    • Choose the account with the Techzone Account
  • $ibmcloud target -g [RESOURCE_GROUP]
    • Get the Resource GRoup from the Resource List
  • $ibmcloud cr login
  • $podman tag wxo-bootcamp-mcp-sever us.icr.io/[NAMESPACE]/[IMAGE_NAME]:[TAG]
    • The [NAMESPACE] is the only one available when you look at Container Registry in the techzone instance. You do not need to create one
  • $podman push us.icr.io/[NAMESPACE]/[IMAGE_NAME]:[TAG]
  • $ibmcloud iam api-key-create [API_KEY_NAME] --d "Tech Zone Code Engine registry access"
  • $ibmcloud ce project select -n [PROJECT NAME]
  • $ibmcloud ce registry create -name [REGISTRY_SECRET_NAME] --server us.icr.io --username iamapikey --password [API_KEY_VALUE]
    • THE [API_KEY_VALUE] will be available from the previous command
  • $ibmcloud ce application create --name [APP_NAME] --image us.icr.io/[NAME_SPACE]/[IMAGE_NAME]:[TAG] --registry-secret [REGISTRY_SECRET_NAME]

Test using MCP Inspector

  • $npx @modelcontextprotocol/inspector
  • Use the URL for the application (from Code Endgine) and append /sse as the URL
  • https://[APP_NAME].[IBM_CLOUD_URL_PART]/sse

To run using personal access token from GitHUb, for wxo

uvx --from git+https://YOUR_TOKEN@github.ibm.com/Benjamin-Janes/wxo-bootcamp-mcp-server.git wxo-bootcamp-data-server-stdio

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wxo_bootcamp_mcp_server-0.1.0.tar.gz (17.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wxo_bootcamp_mcp_server-0.1.0-py3-none-any.whl (18.6 kB view details)

Uploaded Python 3

File details

Details for the file wxo_bootcamp_mcp_server-0.1.0.tar.gz.

File metadata

File hashes

Hashes for wxo_bootcamp_mcp_server-0.1.0.tar.gz
Algorithm Hash digest
SHA256 608350b68a404feff9ebd182a0bfca725b4ff8254b73f339c3f483028e48e95b
MD5 5609fd4f57cb508ddada9e9680c3b716
BLAKE2b-256 68c742553380ecb312ba801a329ba6f99d36570936fc684d672eb52840381a37

See more details on using hashes here.

File details

Details for the file wxo_bootcamp_mcp_server-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for wxo_bootcamp_mcp_server-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6258baa60403b9c34eeb820ca936a404bc9094639ceec0b27b91a0355685dc7b
MD5 278e80927744159810a027e5e218c664
BLAKE2b-256 772a5e3b40851ac444481ab58867a803feea96580daec3c9d8d006741622b657

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page