Malaysia Prayer Time for Claude Desktop

Malaysia Prayer Time for Claude Desktop

By amanasmuei GitHub

A Model Context Protocol (MCP) server for Malaysia Prayer Time data

Overview

what is Malaysia Prayer Time for Claude Desktop?

Malaysia Prayer Time for Claude Desktop is a Model Context Protocol (MCP) server that provides accurate prayer time data for various zones in Malaysia, designed to integrate seamlessly with Claude Desktop.

how to use Malaysia Prayer Time for Claude Desktop?

To use the server, install the required dependencies, run the installation script, and connect it to Claude Desktop either through the Extensions UI or by editing the configuration file directly.

key features of Malaysia Prayer Time for Claude Desktop?

  • Accurate prayer times for all zones in Malaysia
  • Current prayer time status
  • Upcoming prayer times
  • Easy setup with Claude Desktop

use cases of Malaysia Prayer Time for Claude Desktop?

  1. Checking prayer times for different regions in Malaysia.
  2. Integrating prayer time notifications into Claude Desktop.
  3. Assisting users in planning their daily activities around prayer times.

FAQ from Malaysia Prayer Time for Claude Desktop?

  • How do I install the server?

You can install it using the provided installation script or manually by installing the dependencies and making the server file executable.

  • Can I use this server without Claude Desktop?

The server is designed to work with Claude Desktop, but you can access the API directly if needed.

  • What if I encounter issues?

Ensure all dependencies are installed, check API accessibility, and verify configuration settings.

Content

Malaysia Prayer Time for Claude Desktop

This repository contains a prayer time utility for Malaysia that integrates with Claude Desktop as an MCP extension.

Features

  • Get accurate prayer times for all zones in Malaysia
  • Check current prayer time status
  • View upcoming prayer times
  • Simple setup with Claude Desktop

Dependencies

You need the following dependencies:

pip install requests mcp

Quick Setup

The easiest way to get started is to use the installation script:

./install.sh

This will:

  1. Create a Python virtual environment
  2. Install the required dependencies
  3. Make the server file executable

Manual Setup

If you prefer to set up manually:

  1. Install the dependencies:

    pip install requests mcp
    
  2. Make the server file executable:

    chmod +x claude_mcp_server.py
    

Running the Server

Start the MCP server with:

./claude_mcp_server.py

The server will start and display the port it's running on (typically localhost:XXXX).

Connecting to Claude Desktop

Method 1: Using the Extensions UI (if available)

  1. Make sure Claude Desktop is installed.

  2. In Claude Desktop:

    • Go to Settings > Extensions
    • Add a new extension
    • Select "Custom Extension"
    • Enter the name "Malaysia Prayer Time"
    • Use the connection details shown in the terminal

Method 2: Edit Configuration File Directly

If you don't see the Extensions option in Claude Desktop, you can edit the configuration file directly:

  1. Run the helper script to get the correct path and configuration snippet:

    ./get_path.py
    

    This will display the absolute path to the server file and provide JSON snippets for your configuration.

  2. Find your Claude Desktop configuration file:

    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows: %APPDATA%\Claude\claude_desktop_config.json
  3. Add the configuration snippet from the helper script to your config file. The basic structure is:

    {
      "mcpServers": {
        "Malaysia Prayer Time": {
          "command": "/absolute/path/to/claude_mcp_server.py",
          "args": []
        }
      }
    }
    

    Or if you want to run it through Python explicitly:

    {
      "mcpServers": {
        "Malaysia Prayer Time": {
          "command": "python",
          "args": ["/absolute/path/to/claude_mcp_server.py"]
        }
      }
    }
    
  4. Save the file and restart Claude Desktop.

Using the Server

Once connected, you can ask Claude to:

  • List all available prayer time zones in Malaysia
  • Get prayer times for a specific zone
  • Check the current prayer time status

Available Tools

The MCP server provides three main tools:

  1. list_zones - Lists all available prayer time zones in Malaysia
  2. get_prayer_times - Gets prayer times for a specific zone
  3. get_current_prayer - Gets the current prayer time status for a specific zone

Zone Codes

Some of the available zone codes:

  • SGR01: Selangor (Petaling, Kuala Lumpur)
  • JHR01: Johor (Pulau Aur, Pemanggil)
  • KTN01: Kelantan (Kota Bharu)
  • MLK01: Melaka (Bandar Melaka)
  • NGS01: Negeri Sembilan (Jelebu, Kuala Pilah)
  • PHG01: Pahang (Kuantan, Pekan)
  • PLS01: Perlis (Kangar)
  • PNG01: Pulau Pinang (Georgetown)
  • PRK01: Perak (Tapah, Slim River)
  • WLY01: Kuala Lumpur, Putrajaya

Example Queries

Here are some examples of what you can ask Claude:

  1. "What are the available prayer time zones in Malaysia?"
  2. "Show me the prayer times for Kuala Lumpur today."
  3. "What's the current prayer time in Kelantan?"
  4. "When is the next prayer time for SGR01?"

Troubleshooting

If you encounter any issues:

  1. Make sure you have all required dependencies installed.
  2. Check that the API endpoint is accessible (https://api.waktusolat.app/api/v2/solat/SGR01).
  3. For MCP server issues, check that the port is not being used by another application.
  4. Make sure the connection details in Claude Desktop match what's shown in the terminal.
  5. If you get "module 'mcp' has no attribute 'App'" error, make sure to update to the latest version of the server script from this repository.
  6. When editing the config file manually:
    • Ensure JSON syntax is correct (no trailing commas, properly quoted strings)
    • Use absolute paths, not relative paths
    • Make sure the file has correct permissions
    • Restart Claude Desktop after making changes
    • If the file doesn't exist, you may need to create it

Credits

This server uses the API from github.com/mptwaktusolat/api-waktusolat.

No tools information available.
No content found.