Skip to content

Replit + Occult API

Add the MCP server to a Repl through the Integrations pane — no config file involved. Setup takes about two minutes and the server runs locally — your key never leaves your machine.

What this gives you

The MCP server exposes 309 astrology endpoints to Replit Agent as callable tools. Rather than describing an API and hoping the model writes a correct request, it searches the catalogue, reads the real request schema, and makes the call — so the numbers in its answer came from the ephemeris rather than from its training data.

Searching and reading schemas costs nothing. Only a successful call_endpoint spends a credit, and failed calls are free.

1. Get a key

Create one in the dashboard. It looks like yt_live_… and carries your credit balance, so treat it as a password: never in client-side code, never committed.

Create an API key

2. Add the server

Replit has no MCP configuration file — this is the one tool on our list where there is nothing to paste and nothing to commit. Add the server through the interface:

Replit Agent → Integrations → Add MCP server

Give it the command npx with the arguments -y occult-api-mcp, and set the environment variable OCCULT_API_KEY to your key.

3. Check it connected

Ask Replit Agent:

prompt
List the tools you have from the occult-api server.

You should get back five tools:

  • search_endpoints
  • describe_endpoint
  • call_endpoint
  • get_panchanga
  • check_account

If the list is empty the server has not started. The usual cause is the config file being in the right place with the wrong shape, so check the key name above before anything else.

4. A first prompt worth running

prompt
Use the occult-api MCP server to build a small Flask page that shows today's panchanga for a city the visitor types in.

It should call the API rather than answer from memory. If the reply arrives instantly and contains no tool call, the agent has answered from training data — say “use the occult-api tools” and it will.

Worth knowing about Replit

  • Replit is the one tool here with NO configuration file. Setup is entirely through the Integrations pane, so there is nothing to paste and nothing to commit.
  • Store the API key as a Replit Secret rather than typing it into the pane, so it does not travel with a fork of the Repl.
  • A forked Repl does not carry your Secrets. Whoever forks it supplies their own key, which is usually what you want.

If you would rather not use MCP

The endpoints are ordinary HTTP. Nothing on this page is required to use them:

curl
curl -X POST https://api.occultapi.com/api/astro/panchanga/ \
  -H 'X-API-Key: yt_live_your_key_here' \
  -H 'Content-Type: application/json' \
  -d '{
    "date_time": "2026-09-17T06:00:00+05:30",
    "latitude": 26.9124,
    "longitude": 75.7873,
    "timezone_as_float": 5.5,
    "keys": ["tithi", "nakshatra", "yogam", "karana"]
  }'

Note the keys array: four calculations in one request, charged as one credit. Calling four times costs four.

Other tools

Next