Documentation

API Reference

60 endpoints across 37 divination traditions. Structured JSON. Bearer auth. Pay with TIAN Points.

Changelog · Latest: v3.0.028 core systems · 7 TIAN blends · 2 predict oracles · 3 divination lots · 2 catalogue · 1 REST

Authentication

All API requests require authentication using an API key. Include your key in the Authorization header.

Authorization: Bearer at_live_your_api_key_here

Get your API key from the Dashboard. Pay with TIAN Points on Base to activate a subscription plan.

Rate Limits

Every authenticated response from /api/trpc includes three headers that expose your plan's monthly quota in real time. Read them to build backoff logic, usage dashboards, or pre-flight quota checks without an extra round-trip.

Header
Description
X-RateLimit-Limit
Your plan's total monthly call quota. Returns "unlimited" when no active subscription is on file.
X-RateLimit-Remaining
Calls remaining this month. Clamped to 0 — never goes negative. Returns "unlimited" when limit is unlimited.
X-RateLimit-Reset
Unix timestamp (seconds UTC) of the first second of next month — when your quota resets to the full plan limit.

Example response headers

HTTP/2 200
Content-Type: application/json
X-RateLimit-Limit: 10000
X-RateLimit-Remaining: 9650
X-RateLimit-Reset: 1746057600

Quota exhaustion

When your monthly quota is exhausted, LLM-backed procedures (tian.*, predict.*) return HTTP 429 with a Retry-After header containing the number of seconds until your quota resets. Core divination endpoints (non-LLM) are not quota-gated and continue to work.

HTTP/2 429
Retry-After: 432000
Content-Type: application/json

{"error":{"code":"TOO_MANY_REQUESTS","message":"Monthly quota exceeded: 10,000 / 10,000 calls used this month. Upgrade your plan to continue."}}

IP-based rate limit (429)

Separate from the monthly quota, all /api/ routes enforce an IP-level limit of 300 requests per 15-minute window. Auth routes (/api/auth/, /api/oauth/) have a stricter limit of 20 requests per 15 minutes to prevent credential-stuffing attacks. When this limit is exceeded the response carries a Retry-After header with the number of seconds until the window resets — the same header name as quota exhaustion, but a different trigger.

Trigger
Retry-After meaning
Monthly quota exhausted
Seconds until the 1st of next month (UTC) — quota resets on a calendar cycle.
IP rate limit hit
Seconds until the current 15-minute sliding window expires — typically ≤ 900 s.
HTTP/2 429
Retry-After: 743
RateLimit-Limit: 300
RateLimit-Remaining: 0
Content-Type: application/json

{"error":"Too many requests from this IP, please try again later."}

When to retry

HTTP status
Cause
Action
429 (IP burst)
300 req / 15 min exceeded
Wait Retry-After seconds, then retry
429 (quota)
Monthly quota exhausted
Wait until quota reset or upgrade plan
500
Transient server error
Exponential backoff with jitter
503
LLM upstream unavailable
Exponential backoff with jitter
400
Bad request payload
Fix input — do not retry
401 / 403
Auth / plan mismatch
Fix credentials — do not retry

Exponential backoff with jitter — Node.js

async function callWithRetry(fn, maxAttempts = 5) {
  for (let attempt = 0; attempt < maxAttempts; attempt++) {
    const resp = await fn();

    if (resp.status === 429) {
      const retryAfter = parseInt(resp.headers.get('Retry-After') ?? '60', 10);
      // IP burst: Retry-After is ≤ 900 s. Quota exhaustion: can be days.
      // For Enterprise callers the only 429 you'll see is the IP burst limit
      // (300 req / 15 min). Honour the header and retry once the window clears.
      if (retryAfter > 900) throw new Error('Monthly quota exhausted — upgrade plan');
      await sleep(retryAfter * 1000);
      continue;
    }

    if (resp.status >= 500) {
      if (attempt === maxAttempts - 1) throw new Error('Max retries exceeded');
      const delay = Math.min(1000 * 2 ** attempt + Math.random() * 500, 30_000);
      await sleep(delay);
      continue;
    }

    return resp; // 2xx or 4xx — return immediately
  }
}

const sleep = (ms) => new Promise(r => setTimeout(r, ms));

Exponential backoff with jitter — Python

import time, random, requests

def call_with_retry(fn, *args, max_attempts=5, **kwargs):
    for attempt in range(max_attempts):
        resp = fn(*args, **kwargs)

        if resp.status_code == 429:
            retry_after = int(resp.headers.get('Retry-After', 60))
            # Enterprise: only burst-limit 429s are expected (retry_after ≤ 900 s)
            if retry_after > 900:
                raise Exception('Monthly quota exhausted — upgrade plan')
            time.sleep(retry_after)
            continue

        if resp.status_code >= 500:
            if attempt == max_attempts - 1:
                raise Exception('Max retries exceeded')
            delay = min(1 * (2 ** attempt) + random.uniform(0, 0.5), 30)
            time.sleep(delay)
            continue

        return resp  # 2xx or 4xx — return immediately

    raise Exception('Max retries exceeded')

Enterprise note: Enterprise plans have unlimited monthly quota — the only 429 you will encounter is the IP-level burst limit of 300 requests / 15 minutes. The Retry-After value in this case is always ≤ 900 seconds (the remaining window duration). Spread high-volume predict.binaryBatch calls across multiple source IPs or introduce a client-side token bucket (≈ 18 req/min sustained) to stay under the limit.

Base URL & Request Format

Base URL

https://api.asktian.com

GET Queries

Pass input as a URL-encoded JSON string:

GET /trpc/{procedure}?input={"json":{...params}}

POST Mutations

POST /trpc/{procedure}
Content-Type: application/json
{"json":{...params}}

Divination Lot Systems

Available system slugs for the divination.draw and divination.list endpoints:

Slug
System Name
Total Lots
leiyushi
雷雨師一百籤
101
jiaziqian
六十甲子籤
64
guanyin100
觀音一百籤
100
baoshengdadi
保生大帝六十籤
61
penghutianhougong
澎湖天后宮一百籤
100
asakusaguanyin
淺草觀音寺一百籤
101
guanyin28
觀音二八籤
28
guanyin24
觀音二四籤
24
zhushengniangniang
註生娘娘三十籤
30
jinqiangua
金錢卦三十二籤
32
yuelao
月老靈籤
101
guandi
關帝靈籤
100
huangdaxian
黃大仙靈籤
100
fozhu
佛祖靈籤
51
lvzu
呂祖靈籤
100
caishenmiao
財神廟靈籤
61
wulucaishen
五路財神籤
100
caishenyeqian
財神爺籤
62
wenshu
文殊菩薩靈籤
100
kongsheng
孔聖靈籤
72
wenchangmiao
文昌廟靈籤
100
yuhuangdadi
玉皇大帝靈籤
100
chenghuan
城隍廟靈籤
100
dizangwang
地藏王菩薩靈籤
100
guanyinpusa
觀音菩薩靈籤
100
mazu
媽祖靈籤
100
xuantianshangdi
玄天上帝靈籤
100
tudigong
土地公靈籤
60
sanshengwang
三聖王靈籤
100
jiutianxuannv
九天玄女靈籤
100
doumuyuanjun
斗母元君靈籤
100
lingguan
靈官靈籤
100
zhenwu
真武大帝靈籤
100
taisui
太歲靈籤
60
caishenye
財神爺靈籤(武財神)
100
guanshiyin
觀世音菩薩靈籤
100
weituo
韋馱菩薩靈籤
60
bixiayuanjun
碧霞元君靈籤
100
longwang
龍王靈籤
60
sanqing
三清靈籤
100
wangye
王爺靈籤
100
jigong
濟公靈籤
100

Icon Pack

All 37 system icons plus 8 Mahabote planet icons are available in three variants: original (colored icon with dark background baked in), white (white monochrome on transparent PNG — for dark UIs), and transparent (colored icon on transparent PNG — for light UIs). Planet icons use original (outlined) and white (shiny flat) variants.

Right-click any icon to save, or click the variant label to download directly.

Qimen Dunjia

Qimen Dunjia

qimen

Liuyao

Liuyao

liuyao

Meihua Yishu

Meihua Yishu

meihua

Da Liu Ren

Da Liu Ren

daliu

Tai Yi

Tai Yi

taiyi

Xiao Liu Ren

Xiao Liu Ren

xiaoliu

Chinese Astrology

Chinese Astrology

astrology

Chinese Zodiac Compatibility

Chinese Zodiac Compatibility

compatibility

Almanac

Almanac

almanac

Auspicious Dates

Auspicious Dates

auspicious

Name Analysis

Name Analysis

name

Western Horoscope

Western Horoscope

zodiac

Tarot

Tarot

tarot

Runes

Runes

runes

Numerology

Numerology

numerology

Birthday Compatibility

Birthday Compatibility

birthday

Blood Type Compatibility

Blood Type Compatibility

bloodtype

Coin Flip Oracle

Coin Flip Oracle

coinflip

General Divination

General Divination

divination

Jyotish

Jyotish

jyotish

Anka Shastra

Anka Shastra

anka

Ifá

Ifá

ifa

Fa/Vodun

Fa/Vodun

vodun

Hakata

Hakata

hakata

Rammal

Rammal

rammal

Khatt al-Raml

Khatt al-Raml

khatt

TIAN Eastern Blend

TIAN Eastern Blend

tian-eastern

TIAN Western Blend

TIAN Western Blend

tian-western

TIAN East-West Blend

TIAN East-West Blend

tian-eastwest

TIAN African Blend

TIAN African Blend

tian-african

TIAN Islamic Blend

TIAN Islamic Blend

tian-islamic

TIAN Indian Blend

TIAN Indian Blend

tian-indian

TIAN Global Blend

TIAN Global Blend

tian-global

Horoscope

Horoscope

horoscope

Bone Weight

Bone Weight

boneWeight

Mahabote

Mahabote

mahabote

Twelve Palaces

Twelve Palaces

twelvepalaces

Planet: Sun

Planet: Sun

planet-sun

Planet: Moon

Planet: Moon

planet-moon

Planet: Mars

Planet: Mars

planet-mars

Planet: Mercury

Planet: Mercury

planet-mercury

Planet: Jupiter

Planet: Jupiter

planet-jupiter

Planet: Venus

Planet: Venus

planet-venus

Planet: Saturn

Planet: Saturn

planet-saturn

Planet: Rahu

Planet: Rahu

planet-rahu

Error Reference

All errors follow a consistent JSON envelope. The error.code field is a machine-readable string you can switch on; error.message is a human-readable description safe to surface in logs.

Error envelope

{
  "error": {
    "code": "UNAUTHORIZED",
    "message": "You must be logged in to access this resource.",
    "data": {
      "httpStatus": 401,
      "path": "divination.draw"
    }
  }
}

Error codes

Code
HTTP
When it occurs
UNAUTHORIZED
401
No valid session cookie or Bearer API key was provided. Authenticate and retry.
FORBIDDEN
403
The authenticated user lacks permission — e.g. calling an admin procedure, accessing another user's data, or using a revoked API key.
TOO_MANY_REQUESTS
429
Monthly quota exhausted (check X-RateLimit-Remaining) or IP rate limit hit (check Retry-After). Upgrade plan or wait for the window to reset.
BAD_REQUEST
400
Input validation failed — a required field is missing, a value is out of range, or a string exceeds the allowed length. Fix the request payload and retry.
NOT_FOUND
404
The requested resource does not exist or has been deleted (e.g. an API key ID that was revoked).
CONFLICT
409
The operation conflicts with existing state — e.g. submitting a transaction hash that has already been processed.
INTERNAL_SERVER_ERROR
500
An unexpected server-side error occurred. These are logged automatically. Retry with exponential backoff; if the error persists, contact support.

Handling errors — Python example

import requests

def call_api(endpoint, payload, api_key):
    resp = requests.post(
        f"https://api.asktian.com/api/trpc/{endpoint}",
        json={"json": payload},
        headers={"Authorization": f"Bearer {api_key}"},
    )
    body = resp.json()
    if "error" in body:
        code = body["error"]["code"]
        if code == "UNAUTHORIZED":
            raise Exception("Invalid or missing API key")
        elif code == "TOO_MANY_REQUESTS":
            retry_after = int(resp.headers.get("Retry-After", 60))
            raise Exception(f"Quota exhausted. Retry in {retry_after}s")
        elif code == "BAD_REQUEST":
            raise ValueError(f"Bad input: {body['error']['message']}")
        else:
            raise Exception(f"API error {code}: {body['error']['message']}")
    return body["result"]["data"]["json"]

Streaming (SSE)

⚡ TIAN Blended only

All 7 TIAN Blended endpoints support Server-Sent Events (SSE) via a dedicated streaming route. Instead of waiting for the full payload, each sub-system result is emitted as it completes, and the LLM synthesis streams token-by-token. This dramatically reduces perceived latency for blended readings that fan out across 2–26 systems.

Endpoint format

GET https://api.asktian.com/api/stream/tian/{tradition}

# Supported traditions:
# eastern | western | african | islamic | indian | eastwest | global

# Query parameters (same as the tRPC endpoint):
# ?question=...  &year=...  &month=...  &day=...  &birthdate=...

# Required header:
# Authorization: Bearer at_live_xxxx

SSE event schema

Event typePayload fieldsDescription
systemname, result, score, error?Emitted once per sub-system as it completes. score is 0–100.
synthesis_chunkchunkOne or more tokens of the LLM synthesis narrative. Append to build the full text.
doneblendedScore, synthesis, traditionScores, creditsUsed, responseTimeMsFinal event. Close the SSE connection after receiving this.
errormessage, codeEmitted on auth failure, quota exhaustion, or internal error. Connection closes immediately after.

traditionScores — done event

The done event includes a traditionScores object with per-tradition averages. Use this to render per-tradition score bars without averaging individual system events client-side.

// done event payload (tian.global example)
{
  "type": "done",
  "blendedScore": 74,
  "traditionScores": {
    "eastern": 76,
    "western": 73,
    "african": 67,
    "islamic": 79,
    "indian": 66
  },
  "synthesis": "The Qimen palace of Tian Ying aligns with...",
  "creditsUsed": 135,
  "responseTimeMs": 4821
}

SDK — async-iterator stream()

import { AskTian } from 'asktian-sdk';

const client = new AskTian({ apiKey: 'at_live_xxxx' });

for await (const event of client.tian.eastern.stream({ question: 'Should I change careers?' })) {
  if (event.type === 'system') {
    console.log(event.name + ': score ' + event.score);
  }
  if (event.type === 'synthesis_chunk') {
    process.stdout.write(event.chunk);
  }
  if (event.type === 'done') {
    console.log('Tradition scores:', event.traditionScores);
  }
}
Star on GitHub · github.com/douglasgan/asktian-sdk

Webhooks

🔔 Predict Oracle

When you register a webhook URL on your API key, askTIAN posts a signed JSON payload to that URL whenever a prediction event fires. Every outbound request includes an X-Signature-256 header so you can verify the payload has not been tampered with in transit.

Webhook events

EventTriggerKey fields
predict.completedA predict.binary or predict.multi call finishespredictionId, question, outcome, confidence, creditsUsed, timestamp
predict.batch.completedA predict.binaryBatch call finishes (one event for the whole batch)batchId, results[ ], totalCreditsUsed, timestamp

X-Signature-256 header

The header value is sha256=<hex-digest> where the digest is an HMAC-SHA256 of the raw request body bytes, keyed with your webhook secret. The secret is shown once when you register the webhook URL.

POST /your-webhook-endpoint HTTP/1.1
Content-Type: application/json
X-Signature-256: sha256=b94d27b9934d3e08a52e52d7da7dabfac484efe04294e576d4b4b4b4b4b4b4b4

{"event":"predict.completed","predictionId":"pred_abc123",...}

Verification — Node.js / Express

import crypto from 'crypto';

// IMPORTANT: use express.raw() (not express.json()) for this route
// so req.body is a Buffer containing the raw bytes.
app.post('/webhook', express.raw({ type: 'application/json' }), (req, res) => {
  const secret = process.env.ASKTIAN_WEBHOOK_SECRET; // your webhook secret
  const sigHeader = req.headers['x-signature-256'] ?? '';

  // 1. Compute expected signature
  const expected = 'sha256=' + crypto
    .createHmac('sha256', secret)
    .update(req.body)          // req.body must be raw Buffer
    .digest('hex');

  // 2. Constant-time comparison to prevent timing attacks
  const trusted = Buffer.from(expected);
  const received = Buffer.from(sigHeader);
  if (trusted.length !== received.length ||
      !crypto.timingSafeEqual(trusted, received)) {
    return res.status(401).json({ error: 'Invalid signature' });
  }

  // 3. Parse and handle the verified payload
  const payload = JSON.parse(req.body.toString());
  console.log('Verified event:', payload.event);
  res.sendStatus(200);
});

Verification — Python / FastAPI

import hmac, hashlib, os
from fastapi import FastAPI, Request, HTTPException

app = FastAPI()
WEBHOOK_SECRET = os.environ['ASKTIAN_WEBHOOK_SECRET']

@app.post('/webhook')
async def handle_webhook(request: Request):
    body = await request.body()          # raw bytes
    sig_header = request.headers.get('x-signature-256', '')

    # 1. Compute expected signature
    expected = 'sha256=' + hmac.new(
        WEBHOOK_SECRET.encode(),
        body,
        hashlib.sha256
    ).hexdigest()

    # 2. Constant-time comparison
    if not hmac.compare_digest(expected, sig_header):
        raise HTTPException(status_code=401, detail='Invalid signature')

    # 3. Parse verified payload
    payload = await request.json()
    print('Verified event:', payload['event'])
    return {'ok': True}

🔑 Secret key rotation procedure

Each registered webhook has its own per-endpoint secret (shown once at registration time). If you suspect a secret has been compromised, you can rotate it from the DashboardWebhooksRotate Secret. A new secret is generated immediately; the old secret is invalidated. All subsequent deliveries will be signed with the new secret.

Zero-downtime rotation: To avoid dropping events during the transition, implement a grace-period window on your receiver — accept payloads signed with either the old or the new secret for a short overlap period (e.g. 60 seconds), then remove the old secret once you have confirmed the new one is working.

// Grace-period rotation handler (Node.js)
const OLD_SECRET = process.env.ASKTIAN_WEBHOOK_SECRET_OLD;
const NEW_SECRET = process.env.ASKTIAN_WEBHOOK_SECRET;

function verifySignature(body, sigHeader) {
  const verify = (secret) =>
    'sha256=' + crypto.createHmac('sha256', secret).update(body).digest('hex');
  const trusted = verify(NEW_SECRET);
  const fallback = OLD_SECRET ? verify(OLD_SECRET) : null;
  return (
    crypto.timingSafeEqual(Buffer.from(trusted), Buffer.from(sigHeader)) ||
    (fallback && crypto.timingSafeEqual(Buffer.from(fallback), Buffer.from(sigHeader)))
  );
}

After confirming the new secret is live, remove ASKTIAN_WEBHOOK_SECRET_OLD from your environment and redeploy.

Replay protection & best practices

The payload includes a timestamp field (Unix ms). Reject events where |Date.now() - timestamp| > 300_000 (5 minutes) to prevent replay attacks.

Each event also carries a unique predictionId (or batchId). Store processed IDs in a set and skip duplicates to make your handler idempotent — askTIAN may retry delivery up to 3 times on non-2xx responses.

Always return 200 OK quickly (within 10 seconds) and process the payload asynchronously. Slow responses cause retries and duplicate events.

Predict Oracle — Quick-Start

🔮 Enterprise

The Predict Oracle consults 10 metaphysical systems in parallel and returns a confidence-weighted outcome for any binary or multi-option question. Follow these three steps to make your first prediction call.

1

Get an API key

Log in to the Dashboard, navigate to API Keys, and create a new key. Predict Oracle endpoints require an Enterprise subscription — activate one by sending TIAN Points to the treasury address shown on the Pricing page. Your key will look like at_live_xxxxxxxxxxxx.

Verify your key

curl 'https://api.asktian.com/api/trpc/auth.me' \
  -H 'Authorization: Bearer at_live_xxxx'
2

Call predict.binary

POST a question, two outcome labels, and a resolution date. The oracle runs 10 systems in parallel and returns the predicted outcome, a confidence score (0–100), and a per-system breakdown — all in a single synchronous response. Costs 100 TIAN Points.

curl -X POST https://api.asktian.com/api/trpc/predict.binary \
  -H 'Authorization: Bearer at_live_xxxx' \
  -H 'Content-Type: application/json' \
  -d '{ "json": {
    "question": "Will Bitcoin reach $150,000 by end of 2025?",
    "optionYes": "Yes",
    "optionNo":  "No",
    "resolutionDate": "2025-12-31"
  } }'

Response

{
  "result": { "data": { "json": {
    "predictedOption": "Yes",
    "confidence": 67.4,
    "thesis": "Seven of ten metaphysical systems align on a favorable outcome...",
    "systemBreakdown": [
      { "system": "Qimen Dunjia", "vote": "Yes", "confidence": 78,
        "rationale": "Open Gate in Metal palace" },
      { "system": "Tarot",        "vote": "Yes", "confidence": 71,
        "rationale": "The Star card — hope and long-term gain" }
    ],
    "systemsConsulted": 10,
    "creditsUsed": 100
  } } }
}
No TIAN Points consumed — sample mode by default
3

Read the confidence field

confidence is a 0–100 float representing the weighted aggregate agreement across all 10 systems. A score above 65 indicates strong cross-tradition consensus; below 50 means the systems are split and the prediction is low-confidence. Use systemBreakdown to inspect per-system votes and surface the most influential traditions in your UI.

Confidence thresholds — suggested display logic

≥ 75
Strong consensus
All or nearly all systems agree. Safe to display as a high-confidence signal.
65–74
Moderate consensus
Majority agreement with some dissent. Display with a confidence bar.
50–64
Weak consensus
Slim majority. Recommend displaying both options with their scores.
< 50
No consensus
Systems are split. Surface as inconclusive — do not display a winner.

Next steps

  • → Score up to 20 questions in one call with predict.binaryBatch (20% discount vs individual calls)
  • → Rank multiple candidates with predict.multi — see example below
  • → Register a webhook to receive predict.batch.completed events instead of polling
  • → Re-fetch any batch result by batchId using predict.batchResult
predict.multi — rank 9 candidates (150 TIAN Points, up to 500)
curl -X POST https://api.asktian.com/api/trpc/predict.multi \
  -H 'Authorization: Bearer at_live_xxxx' \
  -H 'Content-Type: application/json' \
  -d '{ "json": {
    "question": "Which crypto will have the highest market cap on 31 Dec 2026?",
    "options": ["Bitcoin","Ethereum","Solana","BNB","XRP","Cardano","Avalanche","Polkadot","Chainlink"],
    "resolutionDate": "2026-12-31"
  } }'

Response — ranked by optionScores

{
  "result": { "data": { "json": {
    "predictedOption": "Bitcoin",
    "confidence": 28.6,
    "optionScores": { "Bitcoin": 74.1, "Ethereum": 64.7, "Solana": 58.3, "BNB": 54.2, "XRP": 51.8, "Cardano": 48.6, "Avalanche": 46.1, "Polkadot": 42.5, "Chainlink": 44.9 },
    "thesis": "Bitcoin retains the strongest metaphysical signal across all 7 systems — Open Gate in Metal palace (Qimen), 11th house lord with Jupiter aspect (Jyotish)...",
    "systemsConsulted": 7,
    "creditsUsed": 150
  } } }
}

Palace Lookup — Quick-Start

🏯 Eastern

The Twelve Palaces system derives a life palace (1–14) and degree (0°, 2°, 4°, 6°, 8°) by summing four lunar birth scores. The example below uses a Dragon-year birth, Lunar Month 3, Lunar Day 15, and Hour Si (09:00–11:00) — a combination that resolves to Palace 9 · Wit (九宮).

Step 1 — Call the endpoint

curl -X POST https://api.asktian.com/api/trpc/twelvepalaces.calculate \
  -H "X-API-Key: at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"zodiacYear":"Dragon","lunarMonth":3,"lunarDay":15,"birthHour":"Si"}}'

Step 2 — Read the response

{
  "result": { "data": { "json": {
    "palace": 9,
    "degree": 0,
    "palaceName": "九宮",
    "palaceTitle": "九宮",
    "fortuneTitle": "聪明之命",
    "poem": "詩曰:...",
    "marriage": "...",
    "wealth": "...",
    "synthesis": "Palace 9 (九宮) — Wit & Cleverness: born with a sharp, adaptive mind...",
    "creditsUsed": 5
  } } }
}
Scoring: Dragon (1.6) + Month 3 (3.6) + Day 15 (2.0) + Si (1.6) = 8.8 → Palace 9, Degree 0. See the twelvepalaces.calculate reference for all 12 zodiac and 12 hour branch scores.

System Catalogue

3 endpoints
GET/trpc/catalogue.list
▶ Try in Playground

Returns all 60 endpoints including 40 core traditions and 7 blended endpoints. Each entry includes the system name, Chinese name, tradition, API endpoint path, TIAN Points cost per call, icon image URL, plain-English description, and a systemUrl linking to the system's dedicated information page. Use this to build system pickers, icon grids, or 'Learn More' links in your app.

curl "https://api.asktian.com/api/trpc/catalogue.list"

Example Response

{"result":{"data":{"json":[{"id":"qimen","name":"Qimen Dunjia","zh":"奇門頓甲","tradition":"Eastern","endpoint":"/qimen/calculate","credits":1,"iconUrl":"https://cdn.manus.space/.../icon-qimen.png","description":"Mysterious Door Escaping Technique...","systemUrl":"https://api.asktian.com/systems/qimen"},{"...":"36 entries total"}]}}}
GET/api/v1/systems
▶ Try in Playground

REST alternative to catalogue.list — returns the same 36-entry array as plain JSON without the tRPC envelope. No authentication required. Ideal for developers who prefer REST over tRPC or need a simple fetch-and-cache catalogue. Response is cached at the CDN layer for 5 minutes (Cache-Control: public, s-maxage=300).

curl "https://api.asktian.com/api/v1/systems"

Example Response

[{"id":"qimen","name":"Qimen Dunjia","zh":"奇門頓甲","tradition":"Eastern","endpoint":"/qimen/calculate","credits":1,"iconUrl":"https://d2xsxph8kpxj0f.cloudfront.net/.../icon-qimen.png","description":"Mysterious Door Escaping Technique...","systemUrl":"https://api.asktian.com/systems/qimen"}, ... 36 entries total]
POST/trpc/catalogue.publishVersion
▶ Try in Playground

Admin-only procedure that publishes a new API version entry to the public CHANGELOG and automatically fires a `changelog.release` webhook to all registered partner endpoints. Requires an active session with the `admin` role — partner API keys cannot call this endpoint. Use this from the Admin Panel UI or a secure CI/CD pipeline after deploying a new release. The procedure prepends the new entry to the top of the CHANGELOG so the most recent version always appears first.

Parameters

version
string
Semantic version string, e.g. "v3.46.0"
date
string
Release date in YYYY-MM-DD format, e.g. "2026-04-15"
entries
string[]
Array of changelog bullet strings describing what changed in this release
curl -X POST "https://api.asktian.com/api/trpc/catalogue.publishVersion" \
  -H "Content-Type: application/json" \
  -H "Cookie: session=<admin-session-cookie>" \
  -d '{ "json": { "version": "v3.46.0", "date": "2026-04-15", "entries": ["Added 4,018-day almanac database with accurate 干支/納音/宜忌 data", "Upgraded almanac.daily to DB-backed lookup"] } }'

Example Response

{"result":{"data":{"json":{"ok":true,"version":"v3.46.0","webhooksFired":3}}}}

TIAN Blended Readings

7 endpoints
GET/trpc/tian.eastern
▶ Try in Playground

Runs all 14 Eastern divination systems in parallel and synthesises a unified reading via LLM. Covers Qimen Dunjia, BaZi, Zi Wei Dou Shu, Liu Yao, Da Liu Ren, Tai Yi, Qi Zheng Si Yu, Meihua Yishu, Xuan Kong, Dong Yi Shu, Anka Shastra, Mahabote မဟာဘုတ် (Burmese — one of the 28 systems, calls mahabote.calculate internally), Feng Shui, and Luo Shu. Costs 70 TIAN Points (14 systems × 5). Requires Premium or Enterprise subscription.

Parameters

year
number
Current year for time-based calculations (e.g. 2026)
month
number
Current month 1–12
day
number
Current day 1–31
hour
number
Current hour 0–23
birthDate
string
Subject birth date in YYYY-MM-DD format
surname
string
Chinese surname (姓) for name analysis
givenName
string
Chinese given name (名) for name analysis
luckyNumber
string
A number to analyse for auspiciousness (e.g. phone number)
partnerBirthDate
string?
Partner birth date YYYY-MM-DD for compatibility (optional)
question
string?
Optional question to guide the LLM synthesis
curl "https://api.asktian.com/api/trpc/tian.eastern?input=%7B%22json%22%3A%7B%22year%22%3A2026%2C%22month%22%3A3%2C%22day%22%3A11%2C%22hour%22%3A10%2C%22birthDate%22%3A%221990-01-15%22%2C%22surname%22%3A%22%E6%9D%8E%22%2C%22givenName%22%3A%22%E5%BF%97%E6%98%8E%22%2C%22luckyNumber%22%3A%2288888888%22%7D%7D"

Example Response

{"result":{"data":{"json":{"systems":{"qimen":{"score":72},"liuyao":{"score":65},"...":"..."},"synthesis":"The Qimen chart places the Day Stem in the Rest Gate...","overallScore":71,"creditsUsed":70}}}}
GET/trpc/tian.western
▶ Try in Playground

Runs all 5 Western divination systems in parallel and synthesises a unified reading via LLM. Costs 25 TIAN Points (5 systems × 5). Requires Premium or Enterprise subscription.

Parameters

birthdate
string
Birth date in YYYY-MM-DD format
fullName
string
Full legal name for Pythagorean numerology
question
string?
Optional question to guide the LLM synthesis
curl "https://api.asktian.com/api/trpc/tian.western?input=%7B%22json%22%3A%7B%22birthdate%22%3A%221990-01-15%22%2C%22fullName%22%3A%22John+Smith%22%7D%7D"

Example Response

{"result":{"data":{"json":{"systems":{"tarot":{"score":68},"runes":{"score":72},"numerology":{"score":83},"astrology":{"score":77}},"synthesis":"The Star card resonates with your Life Path 7...","overallScore":71,"creditsUsed":25}}}}
GET/trpc/tian.eastwest
▶ Try in Playground

Runs all 14 Eastern and 5 Western divination systems (19 total) and synthesises a cross-tradition reading via LLM. Note: Indian systems (Jyotish, Anka Shastra) are covered by tian.indian, not this endpoint. Costs 95 TIAN Points (19 systems × 5). Requires Enterprise subscription.

Parameters

year
number
Current year
month
number
Current month 1–12
day
number
Current day 1–31
hour
number
Current hour 0–23
birthDate
string
Subject birth date YYYY-MM-DD
surname
string
Chinese surname (姓)
givenName
string
Chinese given name (名)
luckyNumber
string
Number for auspiciousness analysis
fullName
string
Full legal name for Western numerology
partnerBirthDate
string?
Partner birth date for compatibility (optional)
question
string?
Optional question to guide the LLM synthesis
curl "https://api.asktian.com/api/trpc/tian.eastwest?input=%7B%22json%22%3A%7B%22year%22%3A2026%2C%22month%22%3A3%2C%22day%22%3A11%2C%22hour%22%3A10%2C%22birthDate%22%3A%221990-01-15%22%2C%22surname%22%3A%22%E6%9D%8E%22%2C%22givenName%22%3A%22%E5%BF%97%E6%98%8E%22%2C%22luckyNumber%22%3A%2288888888%22%2C%22fullName%22%3A%22John+Smith%22%7D%7D"

Example Response

{"result":{"data":{"json":{"eastern":{"overallScore":71},"western":{"overallScore":71},"eastwestSynthesis":"Across both traditions, a clear theme of transition emerges...","overallScore":71,"creditsUsed":95}}}}
GET/trpc/tian.african
▶ Try in Playground

Runs Ifá, Fa/Vodun, and Hakata in parallel and synthesises a unified African divination reading via LLM. Costs 15 TIAN Points (3 systems × 5). Requires Premium or Enterprise subscription.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to guide the LLM synthesis
curl "https://api.asktian.com/api/trpc/tian.african?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"systems":{"ifa":{"score":84,"odu":"Ogbe"},"vodun":{"score":79,"du":"Gbe"},"hakata":{"score":80,"configuration":"Nhau"}},"synthesis":"Three African traditions speak in unison...","blendedScore":81,"creditsUsed":15}}}}
GET/trpc/tian.islamic
▶ Try in Playground

Runs Rammal and Khatt al-Raml in parallel and synthesises a unified Islamic geomantic reading via LLM. Costs 10 TIAN Points (2 systems × 5). Requires Premium or Enterprise subscription.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to guide the LLM synthesis
curl "https://api.asktian.com/api/trpc/tian.islamic?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"systems":{"rammal":{"score":72,"figure":"Nusra"},"khatt":{"score":74,"qadi":"Nusra"}},"synthesis":"The two Islamic geomantic traditions speak with remarkable accord...","blendedScore":73,"creditsUsed":10}}}}
GET/trpc/tian.indian
▶ Try in Playground

Runs Jyotish (Vedic Astrology) and Anka Shastra (Indian Numerology) in parallel and synthesises a unified Indian metaphysical reading via LLM. Costs 10 TIAN Points (2 systems × 5). Requires Premium or Enterprise subscription.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to guide the LLM synthesis
curl "https://api.asktian.com/api/trpc/tian.indian?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"systems":{"jyotish":{"score":79,"lagna":"Sagittarius","nakshatra":"Purva Ashadha"},"anka":{"score":77,"lifePath":9,"moolank":3}},"synthesis":"Jyotish and Anka Shastra speak in philosophical accord...","blendedScore":78,"creditsUsed":10}}}}
GET/trpc/tian.global
▶ Try in Playground

Fans out across 28 individual divination systems (17 Eastern incl. Mahabote မဟာဘုတ်, 2 Indian, 6 Western incl. Horoscope, 3 African, 2 Islamic) and synthesises a fully cross-civilisational reading via LLM. Each tradition calls its own dedicated endpoint internally — for example, the Mahabote sub-result is produced by mahabote.calculate, and the Twelve Palaces sub-result by twelvepalaces.calculate. Life Blueprint excluded (requires gender). Costs 145 TIAN Points. Requires Enterprise subscription.

Parameters

year
number
Current year
month
number
Current month 1–12
day
number
Current day 1–31
hour
number
Current hour 0–23
birthDate
string
Subject birth date YYYY-MM-DD
surname
string
Chinese surname (姓)
givenName
string
Chinese given name (名)
luckyNumber
string
Number for auspiciousness analysis
fullName
string
Full legal name for Western numerology
question
string?
Optional question to guide the LLM synthesis

Response Fields

tradition
string
"global" — identifies this as a cross-civilisational reading
blendedScore
number
Composite score 0–100 across all 28 systems
synthesis
string
LLM-generated cross-civilisational narrative
signProfile.westernSign
string
Subject's Western zodiac sign (e.g. "capricorn")
signProfile.mantra
string
Sign mantra (e.g. "I Use") — use as LLM personality anchor
signProfile.majorArcana
string
Tarot Major Arcana archetype for the sign (e.g. "The Devil")
compatProfile.chineseAnimal
string
Subject's Chinese zodiac animal
compatProfile.partnerAnimal
string
Partner's Chinese zodiac animal (derived from partnerBirthDate if provided)
compatProfile.loveDimensionLabel
string
"Positive", "Neutral", or "Challenging" — love compatibility label for the pair
eastern / western / african / islamic / indian
object
Per-tradition sub-result with overallScore and tradition-specific fields
creditsUsed
number
TIAN Points deducted for this call (140 base + sub-endpoint costs)
curl "https://api.asktian.com/api/trpc/tian.global?input=%7B%22json%22%3A%7B%22year%22%3A2026%2C%22month%22%3A3%2C%22day%22%3A13%2C%22hour%22%3A10%2C%22birthDate%22%3A%221990-01-15%22%2C%22surname%22%3A%22%E6%9D%8E%22%2C%22givenName%22%3A%22%E5%BF%97%E6%98%8E%22%2C%22luckyNumber%22%3A%2288%22%2C%22fullName%22%3A%22John+Smith%22%7D%7D"

Example Response

{"result":{"data":{"json":{"tradition":"global","blendedScore":77,"synthesis":"Across 28 systems...","signProfile":{"westernSign":"capricorn","mantra":"I Use","majorArcana":"The Devil"},"compatProfile":{"chineseAnimal":"rat","partnerAnimal":"dragon","loveDimensionLabel":"Positive"},"eastern":{"overallScore":76},"western":{"overallScore":74},"african":{"overallScore":81},"islamic":{"overallScore":78},"creditsUsed":145}}}}

Predict Oracle

5 endpoints
POST/trpc/predict.binary
▶ Try in Playground

Prediction Market Oracle — binary outcome. Consults 10 metaphysical systems (Qimen Dunjia, Da Liu Ren, Tai Yi, Liuyao, Meihua Yi Shu, Jyotish Prashna, Rammal, Western Horary, Tarot, Runes) and returns the predicted option, a per-system confidence-weighted aggregate score, and an LLM-synthesised analyst thesis. Costs 100 TIAN Points per call. Requires Premium or Enterprise subscription. Non-Enterprise callers must include privyToken for TIAN Points deduction.

Parameters

question
string
The market question, e.g. "Will Bitcoin hit $100k in 2025?"
optionYes
string
Label for the positive outcome, e.g. "Yes"
optionNo
string
Label for the negative outcome, e.g. "No"
resolutionDate
string
ISO date when the market resolves, e.g. "2025-12-31"
context
string?
Optional additional context to guide the oracle
privyToken
string?
Required for Premium (non-Enterprise) callers — Privy access token from getAccessToken(). Used to verify identity and deduct 100 TIAN Points from wallet.asktian.com. Enterprise users may omit this field.
idempotencyKey
string? (UUID v4)
Optional client-supplied UUID v4 for safe retries. Pass the same UUID on a retry and wallet.asktian.com will not charge a second time — the deduction is deduplicated for 24 hours. If omitted, the server generates a key scoped to userId + endpoint + request timestamp. Recommended for any caller that implements automatic retry logic. Generate with crypto.randomUUID() or the uuid npm package.
curl -X POST https://api.asktian.com/api/trpc/predict.binary \
  -H 'Content-Type: application/json' \
  -d '{ "json": { "question": "Will Bitcoin reach $150,000 by end of 2025?", "optionYes": "Yes", "optionNo": "No", "resolutionDate": "2025-12-31" } }'

Example Response

{"result":{"data":{"json":{"predictedOption":"Yes","confidence":67.4,"thesis":"Seven of ten metaphysical systems align on a favorable outcome...","systemBreakdown":[{"system":"Qimen Dunjia","vote":"Yes","confidence":78,"rationale":"Open Gate in Metal palace"}],"systemsConsulted":10,"creditsUsed":100}}}}
POST/trpc/predict.multi
▶ Try in Playground

Prediction Market Oracle — multi-option outcome. Consults 7 metaphysical systems best suited for multi-candidate ranking (Da Liu Ren, Jyotish Prashna, Western Horary, Tarot, Runes, Meihua Yi Shu, Qimen Dunjia). Each system scores every candidate independently; scores are aggregated into a per-option composite. Returns the predicted winner, a confidence score reflecting the margin between the top two options, per-option scores, and an LLM-synthesised analyst thesis. Accepts 3–500 options. Costs 150 TIAN Points per call. Requires Premium or Enterprise subscription. Non-Enterprise callers must include privyToken for TIAN Points deduction. Response time scales with option count: ~2–4 s for 3–20 options, ~5–10 s for 21–100 options, ~15–30 s for 100+ options. For 200+ options, set a client timeout of at least 60 s.

Parameters

question
string
The market question, e.g. "Which team will win the 2026 World Cup?"
options
string[]
Array of 3–500 option labels
resolutionDate
string
ISO date when the market resolves
context
string?
Optional additional context to guide the oracle
privyToken
string?
Required for Premium (non-Enterprise) callers — Privy access token from getAccessToken(). Used to verify identity and deduct 150 TIAN Points from wallet.asktian.com. Enterprise users may omit this field.
idempotencyKey
string? (UUID v4)
Optional client-supplied UUID v4 for safe retries. Pass the same UUID on a retry and wallet.asktian.com will not charge a second time — the deduction is deduplicated for 24 hours. If omitted, the server generates a key scoped to userId + endpoint + request timestamp. Recommended for any caller that implements automatic retry logic. Generate with crypto.randomUUID() or the uuid npm package.
curl -X POST https://api.asktian.com/api/trpc/predict.multi \
  -H 'Authorization: Bearer at_live_xxxx' \
  -H 'Content-Type: application/json' \
  -d '{ "json": { "question": "Which crypto will have the highest market cap on 31 Dec 2026?", "options": ["Bitcoin","Ethereum","Solana","BNB","XRP","Cardano","Avalanche","Polkadot","Chainlink"], "resolutionDate": "2026-12-31" } }'

Example Response

{"result":{"data":{"json":{"predictedOption":"Bitcoin","confidence":28.6,"thesis":"Bitcoin retains the strongest metaphysical signal across all 7 systems...","optionScores":{"Bitcoin":74.1,"Ethereum":64.7,"Solana":58.3,"BNB":54.2,"XRP":51.8,"Cardano":48.6,"Avalanche":46.1,"Polkadot":42.5,"Chainlink":44.9},"systemBreakdown":[{"system":"Da Liu Ren","scores":{"Bitcoin":82,"Ethereum":67}}],"systemsConsulted":7,"creditsUsed":150}}}}
POST/trpc/predict.binaryBatch
▶ Try in Playground

Prediction Market Oracle — batch binary scoring. Accepts up to 20 binary questions in a single call and runs each through the full 10-system oracle in parallel. Returns an array of results in the same order as the input questions. Each result contains the predicted outcome, confidence score, per-system breakdown, and LLM-synthesised thesis. Costs 80 TIAN Points per question (vs 100 TIAN Points individually — 20% discount). Requires Premium or Enterprise subscription. Non-Enterprise callers must include privyToken for TIAN Points deduction.

Parameters

questions
Array<{question, optionA, optionB, resolutionDate, context?}>
Array of 1–20 binary question objects. Each must include question text, optionA, optionB, and resolutionDate (ISO date string). context is optional additional grounding.
privyToken
string?
Required for Premium (non-Enterprise) callers — Privy access token from getAccessToken(). Used to verify identity and deduct 80 TIAN Points × N questions from wallet.asktian.com. Enterprise users may omit this field.
idempotencyKey
string? (UUID v4)
Optional client-supplied UUID v4 for safe retries. Pass the same UUID on a retry and wallet.asktian.com will not charge a second time — the entire batch deduction is deduplicated for 24 hours. If omitted, the server generates a key scoped to userId + endpoint + request timestamp. Strongly recommended for batch calls since a timeout may leave the deduction state ambiguous. Generate with crypto.randomUUID() or the uuid npm package.
curl -X POST https://api.asktian.com/api/trpc/predict.binaryBatch \
  -H 'Content-Type: application/json' \
  -d '{ "json": { "questions": [ { "question": "Will BTC exceed $120k by end of 2026?", "optionA": "Yes", "optionB": "No", "resolutionDate": "2026-12-31" }, { "question": "Will ETH flip BTC in market cap by 2027?", "optionA": "Yes", "optionB": "No", "resolutionDate": "2027-01-01" } ] } }'

Example Response

{"result":{"data":{"json":{"results":[{"question":"Will BTC exceed $120k by end of 2026?","predictedOption":"Yes","confidence":67.3,"thesis":"The Qimen chart places the wealth star in the Open Gate...","systemBreakdown":[{"system":"Qimen Dunjia","predictedOption":"Yes","score":72}],"systemsConsulted":10,"creditsUsed":80},{"question":"Will ETH flip BTC...","predictedOption":"No","confidence":58.1,"creditsUsed":80}],"totalCreditsUsed":160,"batchId":"pbb_1711929600000_42","responseTimeMs":4821}}}}
GET/trpc/predict.batchResult
▶ Try in Playground

Re-fetch a completed binaryBatch result by its batchId. Use this endpoint when the original predict.binaryBatch HTTP response was lost (e.g. client timeout, network error) but the predict.batch.completed webhook has already fired. Results are stored server-side and scoped to the authenticated user — a different user's batchId returns NOT_FOUND. Requires Premium or Enterprise subscription.

Parameters

batchId
string
The batchId returned by predict.binaryBatch (format: pbb_{timestamp}_{userId}). Stored in the predict.batch.completed webhook payload as batchId.
curl 'https://api.asktian.com/api/trpc/predict.batchResult?input=%7B%22json%22%3A%7B%22batchId%22%3A%22pbb_1711929600000_42%22%7D%7D' \
  -H 'Authorization: Bearer at_live_xxxx'

Example Response

{"result":{"data":{"json":{"id":1,"batchId":"pbb_1711929600000_42","userId":42,"totalQuestions":2,"successCount":2,"totalCreditsUsed":160,"results":[{"question":"Will BTC exceed $120k by end of 2026?","predictedOption":"Yes","confidence":67.3,"thesis":"...","systemBreakdown":[...],"creditsUsed":80},{"question":"Will ETH flip BTC...","predictedOption":"No","confidence":58.1,"creditsUsed":80}],"createdAt":"2026-04-01T12:00:00.000Z"}}}}
GET/trpc/predict.batchHistory
▶ Try in Playground

Returns the last N completed binaryBatch jobs for the authenticated user, ordered by creation time descending. Use this endpoint to build an audit trail, reconcile TIAN Points usage across batch jobs, or populate a batch history dashboard. Each row includes the batchId, question count, success count, total credits used, full results array, and creation timestamp. Free — no TIAN Points cost. Requires authentication.

Parameters

limit
integer (1–100, default 50)
Number of most-recent batch jobs to return. Maximum 100.
curl 'https://api.asktian.com/api/trpc/predict.batchHistory?input=%7B%22json%22%3A%7B%22limit%22%3A10%7D%7D' \
  -H 'Authorization: Bearer at_live_xxxx'

Example Response

{"result":{"data":{"json":[{"id":1,"batchId":"pbb_1711929600000_42","userId":42,"totalQuestions":20,"successCount":19,"totalCreditsUsed":1520,"results":[...],"createdAt":"2026-04-01T12:00:00.000Z"},{"id":2,"batchId":"pbb_1711843200000_42","totalQuestions":5,"successCount":5,"totalCreditsUsed":400,"createdAt":"2026-03-31T12:00:00.000Z"}]}}}

Divination Lots

3 endpoints
GET/trpc/divination.systems
▶ Try in Playground

List all 49 active temple lot systems. Returns an array of system objects with slug, Chinese name, English name, description, total lot count, origin, and active status. Use the slug value as the systemSlug parameter in divination.draw and divination.list. No authentication required.

curl https://api.asktian.com/api/trpc/divination.systems

Example Response

{"result":{"data":{"json":[{"id":1,"slug":"guanyin100","nameZh":"觀音一百籤","nameEn":"Guanyin 100 Lots","description":"Traditional 100-lot oracle from Guanyin temples across Taiwan and Southeast Asia.","totalLots":100,"origin":"Taiwan / Southeast Asia","isActive":true},{"id":2,"slug":"leiyushi","nameZh":"雷雨師一百籤","nameEn":"Lei Yu Shi 100 Lots","description":null,"totalLots":101,"origin":null,"isActive":true}]}}}
GET/trpc/divination.draw
▶ Try in Playground

Draw a random or specific divination lot

Parameters

systemSlug
string
e.g. guanyin, leiyushi
lotNumber
string?
Optional specific lot number
curl "https://api.asktian.com/api/trpc/divination.draw?input=%7B%22json%22%3A%7B%22systemSlug%22%3A%22guanyin%22%7D%7D"

Example Response

{"result":{"data":{"json":{"lotNumber":"42","title":"第四十二籤","fortuneLevel":"good_fortune","poemText":"...","interpretation":"..."}}}}
GET/trpc/divination.list
▶ Try in Playground

List all lots in a system with optional fortune level filter

Parameters

systemSlug
string
System identifier
fortuneLevel
string?
great_fortune | good_fortune | neutral | caution | bad_fortune
page
number
Page number (default: 1)
limit
number
Items per page (default: 20, max: 100)
curl "https://api.asktian.com/api/trpc/divination.list?input=%7B%22json%22%3A%7B%22systemSlug%22%3A%22guanyin%22%2C%22fortuneLevel%22%3A%22good_fortune%22%7D%7D"

Example Response

{"result":{"data":{"json":{"lots":[...],"total":45,"system":{...}}}}}

Qimen Dunjia 奇門遁甲

2 endpoints
GET/trpc/qimen.calculate
▶ Try in Playground

Calculate a Qimen Dunjia chart for a given date and time

Parameters

year
number
Year (1900-2100)
month
number
Month (1-12)
day
number
Day (1-31)
hour
number
Hour (0-23)
question
string?
Optional question for context
curl "https://api.asktian.com/api/trpc/qimen.calculate?input=%7B%22json%22%3A%7B%22year%22%3A2024%2C%22month%22%3A3%2C%22day%22%3A15%2C%22hour%22%3A10%7D%7D"

Example Response

{"result":{"data":{"json":{"palaces":[...],"rotationNumber":5,"escapeType":"yang","gates":[...],"stars":[...],"deities":[...]}}}}
GET/trpc/qimen.elements
▶ Try in Playground

Get reference data for Qimen elements (gates, stars, deities, stems, palaces)

Parameters

elementType
string?
gate | star | deity | stem | palace
curl "https://api.asktian.com/api/trpc/qimen.elements?input=%7B%22json%22%3A%7B%22elementType%22%3A%22gate%22%7D%7D"

Example Response

{"result":{"data":{"json":[{"name":"休門","element":"water","nature":"auspicious","meaning":"..."}]}}}

Liuyao 六爻

1 endpoint
GET/trpc/liuyao.calculate
▶ Try in Playground

Generate a Liuyao hexagram reading

Parameters

method
string
coin | time | number
coinFlips
number[]?
Array of 6 coin flip results (3=yang, 2=yin)
question
string?
Optional question
numbers
number[]?
Numbers for number method
curl "https://api.asktian.com/api/trpc/liuyao.calculate?input=%7B%22json%22%3A%7B%22method%22%3A%22time%22%7D%7D"

Example Response

{"result":{"data":{"json":{"hexagram":"乾","lines":[...],"changingLines":[...],"resultHexagram":"...","interpretation":"..."}}}}

Meihua Yishu 梅花易數

1 endpoint
GET/trpc/meihua.calculate
▶ Try in Playground

Calculate a Meihua Yishu hexagram from numbers

Parameters

upperNumber
number
Upper trigram number
lowerNumber
number
Lower trigram number
changingLine
number?
Changing line (1-6)
question
string?
Optional question
curl "https://api.asktian.com/api/trpc/meihua.calculate?input=%7B%22json%22%3A%7B%22upperNumber%22%3A7%2C%22lowerNumber%22%3A3%7D%7D"

Example Response

{"result":{"data":{"json":{"upperTrigram":"...","lowerTrigram":"...","hexagram":"...","interpretation":"..."}}}}

Name Analysis 姓名學

2 endpoints
GET/trpc/nameAnalysis.analyze
▶ Try in Playground

Analyze a Chinese name using numerology and Five Elements

Parameters

surname
string
Surname (姓)
givenName
string
Given name (名)
gender
string?
male | female
curl "https://api.asktian.com/api/trpc/nameAnalysis.analyze?input=%7B%22json%22%3A%7B%22surname%22%3A%22%E6%9D%8E%22%2C%22givenName%22%3A%22%E5%BF%97%E6%98%8E%22%7D%7D"

Example Response

{"result":{"data":{"json":{"tianGe":{"number":8,"element":"metal","fortune":"good"},"renGe":{"number":15,"element":"earth"},"totalScore":82,"recommendation":"..."}}}}
GET/trpc/nameAnalysis.numerology
▶ Try in Playground

Look up the meaning of a specific numerology number (1-81)

Parameters

number
number
Numerology number (1-81)
curl "https://api.asktian.com/api/trpc/nameAnalysis.numerology?input=%7B%22json%22%3A%7B%22number%22%3A81%7D%7D"

Example Response

{"result":{"data":{"json":{"number":81,"fortune":"great_fortune","meaning":"Supreme achievement"}}}}

Compatibility 配對系統

3 endpoints
GET/trpc/compatibility.zodiac
▶ Try in Playground

Chinese zodiac compatibility analysis. Returns score, auspiciousness, description, and 4-dimension YouApp data (dimensions.love/career/wealth/health/marriage — each with label and text).

Parameters

animal1
string
e.g. rat, ox, tiger, rabbit, dragon, snake, horse, goat, monkey, rooster, dog, pig
animal2
string
Second zodiac animal

Response Fields

score
number
Overall compatibility score 0–100
level
string
"excellent", "good", "neutral", or "challenging"
description
string
Classical Chinese compatibility description
dimensions.love
object
Love dimension: { label, text } from YouApp ZodiacCompatibility dataset
dimensions.career
object
Career dimension: { label, text }
dimensions.wealth
object
Wealth dimension: { label, text }
dimensions.health
object
Health dimension: { label, text }
dimensions.marriage
object
Marriage dimension: { label, text }
curl "https://api.asktian.com/api/trpc/compatibility.zodiac?input=%7B%22json%22%3A%7B%22animal1%22%3A%22rat%22%2C%22animal2%22%3A%22dragon%22%7D%7D"

Example Response

{"result":{"data":{"json":{"score":92,"level":"excellent","description":"...","dimensions":{"love":{"label":"Positive","text":"..."},"career":{"label":"Positive","text":"..."},"wealth":{"label":"Neutral","text":"..."},"health":{"label":"Positive","text":"..."},"marriage":{"label":"Positive","text":"..."}}}}}}
GET/trpc/compatibility.birthday
▶ Try in Playground

Birthday-based compatibility using Chinese numerology and Western astrology. Returns score, romanceScore, friendshipScore, marriageScore, dimensions (Chinese zodiac 4D: marriage/love/career/wealth/health with label + text from YouApp ZodiacCompatibility dataset), and horoscopeDimensions (Western 4D: love/career/wealth/health with label + text from YouApp HoroscopeCompatibility dataset). Both dimension layers are returned simultaneously.

Parameters

date1
string
First person birth date YYYY-MM-DD
date2
string
Second person birth date YYYY-MM-DD

Response Fields

score
number
Overall compatibility score 0–100
romanceScore
number
Romance compatibility sub-score
friendshipScore
number
Friendship compatibility sub-score
marriageScore
number
Marriage compatibility sub-score
dimensions.overallScore
string
"Positive", "Neutral", or "Challenging" — Chinese zodiac overall label
dimensions.marriage
object
Chinese zodiac marriage dimension: { label, text }
dimensions.love
object
Chinese zodiac love dimension: { label, text }
dimensions.career
object
Chinese zodiac career dimension: { label, text }
dimensions.wealth
object
Chinese zodiac wealth dimension: { label, text }
dimensions.health
object
Chinese zodiac health dimension: { label, text }
horoscopeDimensions.intro
string
Western horoscope compatibility intro sentence
horoscopeDimensions.love
object
Western horoscope love dimension: { label, text }
horoscopeDimensions.career
object
Western horoscope career dimension: { label, text }
horoscopeDimensions.wealth
object
Western horoscope wealth dimension: { label, text }
horoscopeDimensions.health
object
Western horoscope health dimension: { label, text }
curl "https://api.asktian.com/api/trpc/compatibility.birthday?input=%7B%22json%22%3A%7B%22date1%22%3A%221990-01-15%22%2C%22date2%22%3A%221992-06-20%22%7D%7D"

Example Response

{"result":{"data":{"json":{"score":78,"romanceScore":82,"friendshipScore":75,"marriageScore":79,"dimensions":{"overallScore":"Positive","marriage":{"label":"Positive","text":"..."},"love":{"label":"Positive","text":"..."},"career":{"label":"Positive","text":"..."},"wealth":{"label":"Neutral","text":"..."},"health":{"label":"Positive","text":"..."}},"horoscopeDimensions":{"intro":"...","love":{"label":"Negative","text":"..."},"career":{"label":"Neutral","text":"..."},"wealth":{"label":"Neutral","text":null},"height":{"label":"Positive","text":"..."}}}}}}}
GET/trpc/compatibility.bloodType
▶ Try in Playground

Blood type compatibility analysis

Parameters

bloodType1
string
A | B | AB | O
bloodType2
string
A | B | AB | O
curl "https://api.asktian.com/api/trpc/compatibility.bloodType?input=%7B%22json%22%3A%7B%22bloodType1%22%3A%22A%22%2C%22bloodType2%22%3A%22O%22%7D%7D"

Example Response

{"result":{"data":{"json":{"score":85,"level":"great","description":"...","advice":"..."}}}}

Auspicious Number 吉祥數字

1 endpoint
GET/trpc/auspicious.analyzeNumber
▶ Try in Playground

Analyses a number for auspiciousness using Chinese numerological principles. Returns the number's element, phonetic associations (e.g. 8 sounds like 發 "prosper"), fortune rating, and recommended domains. 1 TIAN Points per call.

Parameters

number
string
The number to analyse (e.g. phone number, address, business registration number)
curl "https://api.asktian.com/api/trpc/auspicious.analyzeNumber?input=%7B%22json%22%3A%7B%22number%22%3A%228888%22%7D%7D"

Example Response

{"result":{"data":{"json":{"number":"8888","overallScore":95,"fortune":"Highly Auspicious","element":"Earth","phonetic":"Sounds like 發發發發 (prosper repeatedly)","domains":["Wealth","Business","Career"],"interpretation":"Four 8s is the most auspicious phone number configuration in Chinese culture — each digit resonates with prosperity.","creditsUsed":1}}}}

Almanac 農曆

2 endpoints
GET/trpc/almanac.daily
▶ Try in Playground

Get daily almanac data including twelve values, deities, and auspicious activities

Parameters

date
string
Date in YYYY-MM-DD format
curl "https://api.asktian.com/api/trpc/almanac.daily?input=%7B%22json%22%3A%7B%22date%22%3A%222024-03-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"date":"2024-03-15","twelveValue":"成","deity":"青龍","overallFortune":"good_fortune","auspiciousActivities":[...],"inauspiciousActivities":[...]}}}}
GET/trpc/almanac.zodiacSign
▶ Try in Playground

Get Western and Chinese zodiac signs for a birth date. Now includes chineseProfile (60-element Chinese zodiac: personality, strengths, career, love, compatibility) and westernProfile (Medical Astrology, body parts, herbal allies, symbolism, house rulership, mantra, Tarot major/minor arcana, famous people).

Parameters

birthDate
string
Birth date in YYYY-MM-DD format

Response Fields

western.sign
string
Western zodiac sign (e.g. "taurus")
western.element
string
Western element (fire / earth / air / water)
chinese.animal
string
Chinese zodiac animal (e.g. "horse")
chinese.element
string
Chinese element (metal / water / wood / fire / earth)
chinese.year
number
Birth year used to derive the Chinese zodiac
chineseProfile.zodiac
string
Full 60-element zodiac label (e.g. "Metal Horse")
chineseProfile.personality
string
Personality overview from YouApp 60-profile dataset
chineseProfile.strengths
string
Key strengths of this element-animal combination
chineseProfile.weakness
string
Key weaknesses of this element-animal combination
chineseProfile.career
string
Career tendencies and recommended paths
chineseProfile.love
string
Love and relationship tendencies
chineseProfile.compatibility
string
Compatible and incompatible animals
westernProfile.medical
string
Medical Astrology: body systems governed by this sign
westernProfile.bodyParts
string
Body parts associated with this sign
westernProfile.herbalAllies
string
Herbs and plants associated with this sign
westernProfile.symbolism
string
Symbolic associations (colours, stones, metals)
westernProfile.houseRulership
string
Natural house this sign rules
westernProfile.mantra
string
Sign mantra (e.g. "I Use") — use as LLM personality anchor
westernProfile.majorArcana
string
Tarot Major Arcana archetype (e.g. "The Devil")
westernProfile.minorArcana
string
Tarot Minor Arcana suit associated with this sign
westernProfile.famousPeople
string
Notable people born under this sign
curl "https://api.asktian.com/api/trpc/almanac.zodiacSign?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-05-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"western":{"sign":"Taurus","element":"earth"},"chinese":{"animal":"horse","element":"metal","year":1990},"chineseProfile":{"zodiac":"Metal Horse","personality":"...","career":"...","love":"..."},"westernProfile":{"sign":"taurus","medical":"...","mantra":"...","majorArcana":"...","minorArcana":"..."}}}}}}

Xiao Liu Ren 小六壬

1 endpoint
GET/trpc/xiaoLiuRen.calculate
▶ Try in Playground

Six Gods cycle divination — the most widely used folk divination method in Chinese culture

Parameters

month
number
Month (1–12)
day
number
Day of month (1–31)
hour
number
Hour in 24h format (0–23)
aspect
string?
general | career | wealth | health | relationship | travel | lost
question
string?
Optional question for context
curl "https://api.asktian.com/api/trpc/xiaoLiuRen.calculate?input=%7B%22json%22%3A%7B%22month%22%3A3%2C%22day%22%3A3%2C%22hour%22%3A10%2C%22aspect%22%3A%22career%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Xiao Liu Ren (小六壬)","result":{"god":"速喜","number":2,"nature":"auspicious","meaning":"..."},"reading":{"aspect":"career","interpretation":"...","advice":"..."}}}}}

Da Liu Ren 大六壬

1 endpoint
GET/trpc/daLiuRen.calculate
▶ Try in Playground

Four Courses (四課) and Three Transmissions (三傳) — one of the Three Styles of classical Chinese divination

Parameters

year
number
Year (1900–2100)
month
number
Month (1–12)
day
number
Day of month (1–31)
hour
number
Hour in 24h format (0–23)
subject
string?
career | relationship | health | wealth | travel | general
question
string?
Optional question for context
curl "https://api.asktian.com/api/trpc/daLiuRen.calculate?input=%7B%22json%22%3A%7B%22year%22%3A2026%2C%22month%22%3A3%2C%22day%22%3A3%2C%22hour%22%3A10%2C%22subject%22%3A%22career%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Da Liu Ren (大六壬)","fourCourses":[{"position":"First Course","upper":"子","lower":"寅","meaning":"..."}],"threeTransmissions":{"initial":{"branch":"子"},"middle":{"branch":"亥"},"final":{"branch":"戌"}},"overallAssessment":{"nature":"mixed","summary":"..."}}}}}

Tai Yi Shen Shu 太乙神數

1 endpoint
GET/trpc/taiYi.calculate
▶ Try in Playground

72-year Grand Cycle cosmic forecasting — macro-level state, era, and natural event predictions

Parameters

year
number
Year (1900–2100)
month
number
Month (1–12)
day
number
Day of month (1–31)
scope
string?
annual | monthly | era
question
string?
Optional question for context
curl "https://api.asktian.com/api/trpc/taiYi.calculate?input=%7B%22json%22%3A%7B%22year%22%3A2026%2C%22month%22%3A3%2C%22day%22%3A3%2C%22scope%22%3A%22annual%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Tai Yi Shen Shu (太乙神數)","taiYiNumber":9,"rulingGod":{"nameZh":"太乙","nameEn":"Grand Unity","nature":"auspicious"},"cycleInfo":{"cycleNumber":28,"cyclePosition":18},"domainForecasts":{"governance":"...","military":"...","agriculture":"..."},"cosmicWeather":{"assessment":"favorable","message":"..."}}}}}

Tarot 塔羅牌

1 endpoint
GET/trpc/tarot.draw
▶ Try in Playground

Draw a Tarot spread from the 78-card Rider-Waite deck — Major & Minor Arcana with full interpretations

Parameters

spread
string?
single | three_card | celtic_cross (default: single)
question
string?
Optional question for context (max 500 chars)
seed
number?
Optional seed for reproducible draws
curl "https://api.asktian.com/api/trpc/tarot.draw?input=%7B%22json%22%3A%7B%22spread%22%3A%22three_card%22%2C%22question%22%3A%22What+should+I+focus+on%3F%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Tarot","spread":"three_card","cards":[{"position":"Past","card":"The High Priestess","arcana":"major","reversed":false,"interpretation":"Intuition, sacred knowledge..."},{"position":"Present","card":"Three of Wands","arcana":"minor","suit":"Wands","reversed":false},{"position":"Future","card":"The Star","arcana":"major","reversed":false}],"overallTheme":"...","advice":"..."}}}}

Coin Flip Oracle 銅錢占卜

1 endpoint
GET/trpc/coinFlip.flip
▶ Try in Playground

Classic yes/no oracle with weighted probability and 7 domain-specific interpretations

Parameters

question
string?
Optional question for context
aspect
string?
general | career | love | wealth | health | travel | question
flips
number?
Number of flips 1–9 (default: 1)
seed
number?
Optional seed for reproducible results
curl "https://api.asktian.com/api/trpc/coinFlip.flip?input=%7B%22json%22%3A%7B%22aspect%22%3A%22career%22%2C%22flips%22%3A3%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Coin Flip Oracle","aspect":"career","flips":[{"flip":1,"result":"heads"},{"flip":2,"result":"heads"},{"flip":3,"result":"tails"}],"summary":{"majority":"heads","certainty":"moderate"},"interpretation":"A green light for professional decisions...","advice":"Trust the signal. Act with intention."}}}}

Runes 盧恩文字

1 endpoint
GET/trpc/runes.cast
▶ Try in Playground

Cast Elder Futhark runes — 24 runes with full meanings, elements, and deity associations

Parameters

spread
string?
single | three_rune | five_rune (default: single)
question
string?
Optional question for context
seed
number?
Optional seed for reproducible casts
curl "https://api.asktian.com/api/trpc/runes.cast?input=%7B%22json%22%3A%7B%22spread%22%3A%22three_rune%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Elder Futhark Runes","spread":"three_rune","cast":[{"position":"Past","rune":"Fehu","letter":"F","meaning":"Cattle, wealth, abundance","element":"Fire","deity":"Freyr","reversed":false},{"position":"Present","rune":"Ansuz","letter":"A"},{"position":"Future","rune":"Sowilo","letter":"S"}],"overallMessage":"...","advice":"..."}}}}

Numerology 西方數字學

1 endpoint
GET/trpc/numerology.calculate
▶ Try in Playground

Pythagorean numerology — Life Path, Expression, Soul Urge, Personality, and Birthday numbers from name and birthdate

Parameters

fullName
string
Full name as on birth certificate (required)
birthdate
string
Birthdate in YYYY-MM-DD format (required)
curl "https://api.asktian.com/api/trpc/numerology.calculate?input=%7B%22json%22%3A%7B%22fullName%22%3A%22John+Smith%22%2C%22birthdate%22%3A%221990-06-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Pythagorean Numerology","numbers":{"lifePath":{"number":3,"title":"The Creative","traits":["expressive","optimistic","creative"]},"expression":{"number":7,"title":"The Seeker"},"soulUrge":{"number":5,"title":"The Adventurer"},"personality":{"number":2,"title":"The Diplomat"},"birthday":{"number":6,"title":"The Nurturer"}},"summary":"..."}}}}

Western Astrology 西洋占星

1 endpoint
GET/trpc/astrology.calculate
▶ Try in Playground

Sun, Moon, and Rising sign analysis with decanates, element profile, modalities, and ruling planets

Parameters

birthdate
string
Birthdate in YYYY-MM-DD format (required)
birthHour
number?
Birth hour 0–23 for Rising sign accuracy (optional)
question
string?
Optional question for context
curl "https://api.asktian.com/api/trpc/astrology.calculate?input=%7B%22json%22%3A%7B%22birthdate%22%3A%221990-06-15%22%2C%22birthHour%22%3A14%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Western Astrology","placements":{"sun":{"sign":"Gemini","symbol":"♐","element":"Air","modality":"Mutable","ruling":"Mercury","decan":2,"traits":["curious","adaptable","witty"]},"moon":{"sign":"Scorpio","symbol":"♏"},"rising":{"sign":"Libra","symbol":"♎"}},"elementProfile":{"dominant":"Air"},"synthesis":"..."}}}}

Ifá Divination 伊法占卜

1 endpoint
GET/trpc/ifa.draw
▶ Try in Playground

Yoruba Ifá oracle — casts a 16-cowrie or opèlè chain to determine an Odù (one of 256 signs), returns the Odù name, its associated proverbs, taboos (ewɔ), and domain-specific guidance for health, love, and career. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to focus the reading
curl "https://api.asktian.com/api/trpc/ifa.draw?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Ifá","odu":"Ogbe","odunNumber":1,"proverb":"The elder who does not speak truth is no elder","ewo":"Do not eat pork on Fridays","guidance":{"health":"Attend to your left side","love":"Patience brings the right partner","career":"Leadership is your path"},"score":84,"creditsUsed":1}}}}

Fa/Vodun Divination 法左占卜

1 endpoint
GET/trpc/vodun.calculate
▶ Try in Playground

West African Fa/Vodun oracle from the Fon and Ewe corpus — generates a Du sign (one of 256) via the opele chain, returns the Du name, associated Vodun deity, Hwe myths, Ebo (sacrifice) prescriptions, and Legba guidance. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to focus the reading
curl "https://api.asktian.com/api/trpc/vodun.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Fa/Vodun","du":"Gbe","vodun":"Mawu-Lisa","hwe":"The creator twins speak of duality and balance","ebo":"Offer white cloth and palm oil","legbaGuidance":"Open the crossroads with patience","score":79,"creditsUsed":1}}}}

Hakata Bone Throwing 哈卡塔骨占

1 endpoint
GET/trpc/hakata.calculate
▶ Try in Playground

Southern African Hakata bone throwing oracle from the Shona tradition — throws 4 carved bones (Hakata set), interprets the 16 possible configurations, and returns ancestral guidance, Nganga prescriptions, and domain-specific advice. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to focus the reading
curl "https://api.asktian.com/api/trpc/hakata.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Hakata","configuration":"Nhau","configurationNumber":7,"ancestralMessage":"Your ancestors call for reconciliation","ngangaPrescription":"Burn impepho at dawn","guidance":{"health":"Rest and restore","relationships":"Seek forgiveness","prosperity":"Patience precedes harvest"},"score":80,"creditsUsed":1}}}}

Rammal Islamic Geomancy 拉马尔地占

1 endpoint
GET/trpc/rammal.calculate
▶ Try in Playground

Islamic Geomancy (Darb al-Raml / علم الرمل) — generates a full 16-figure shield chart from 4 Mother figures, derives Daughters, Nieces, Witnesses, and the Judge. Returns the Judge figure, its Islamic interpretation, domain guidance, and a synthesis. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to guide the synthesis
curl "https://api.asktian.com/api/trpc/rammal.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Rammal","judge":"Nusra","judgeInterpretation":"Victory and divine support — the matter will succeed with effort","mothers":["Tristitia","Puer","Acquisitio","Fortuna Minor"],"daughters":["Cauda Draconis","Rubeus","Amissio","Albus"],"witnesses":{"right":"Caput Draconis","left":"Fortuna Major"},"guidance":{"career":"Advance boldly","health":"Strength is with you","relationships":"Trust is the foundation"},"score":72,"creditsUsed":1}}}}

Khatt al-Raml North African Geomancy 北非地占

1 endpoint
GET/trpc/khatt.calculate
▶ Try in Playground

North African Khatt al-Raml (خط الرمل) geomancy — draws sand lines, derives 4 base figures, generates the full 16-figure tableau, and returns the Qādī (Judge) figure with Maghrebi-tradition interpretation, domain guidance, and synthesis. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional question to guide the synthesis
curl "https://api.asktian.com/api/trpc/khatt.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Khatt al-Raml","qadi":"Nusra","qadiInterpretation":"The sand lines converge on success — the path is clear","baseFigures":["Tristitia","Acquisitio","Puer","Fortuna Minor"],"guidance":{"career":"The way forward is open","health":"Vitality is strong","relationships":"Harmony is near"},"score":74,"creditsUsed":1}}}}

Jyotish Vedic Astrology 吹托封占星

1 endpoint
GET/trpc/jyotish.calculate
▶ Try in Playground

Vedic Astrology (Jyotish / ज्योतिष) — calculates the Lagna (Ascendant), Moon sign, Nakshatra (lunar mansion), Dasha period, and planetary positions using the sidereal zodiac. Returns a Prashna (horary) reading if a question is provided. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
question
string?
Optional Prashna question for horary reading
curl "https://api.asktian.com/api/trpc/jyotish.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Jyotish","lagna":"Sagittarius","moonSign":"Scorpio","nakshatra":"Purva Ashadha","nakshatraLord":"Venus","dasha":{"current":"Venus","yearsRemaining":4.2},"planetaryPositions":{"sun":"Capricorn","moon":"Scorpio","mars":"Aries"},"synthesis":"Venus Dasha amplifies creative and relational themes...","score":79,"creditsUsed":1}}}}

Anka Shastra Indian Numerology 印度数字学

1 endpoint
GET/trpc/anka.calculate
▶ Try in Playground

Indian Numerology (Anka Shastra / अंक शास्त्र) — calculates Moolank (root number / Psychic number), Bhagyank (destiny number), Namank (name number), and Lo Shu grid analysis with Navagraha planetary ruler interpretations. 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
fullName
string?
Full name for Namank calculation (optional)
question
string?
Optional question for context
curl "https://api.asktian.com/api/trpc/anka.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"system":"Anka Shastra","moolank":6,"bhagyank":8,"namank":3,"planetaryRuler":"Venus","loShuGrid":{"missingNumbers":[4,7],"strongNumbers":[1,6,8]},"synthesis":"Moolank 6 (Venus) brings harmony and creativity; Bhagyank 8 (Saturn) demands discipline for material success.","score":77,"creditsUsed":1}}}}

Western Horoscope 西洋星座

1 endpoint
GET/trpc/horoscope.calculate
▶ Try in Playground

Western Horoscope — calculates the full natal chart from a Gregorian birth date and optional birth hour. Returns Sun sign, Moon sign, Ascendant, all planetary positions, planetary dignities, element profile, modality profile, LLM synthesis, and signProfile (Medical Astrology, body parts, herbal allies, symbolism, house rulership, mantra, Tarot major/minor arcana, famous people for the sun sign). 1 TIAN Points per call.

Parameters

birthDate
string
Subject birth date YYYY-MM-DD
birthHour
number?
Birth hour 0–23 (optional, improves Ascendant accuracy)
question
string?
Optional question to focus the synthesis

Response Fields

sunSign
string
Western sun sign (e.g. Capricorn, Aries)
moonSign
string
Moon sign based on birth date
ascendant
string
Rising sign — requires birthHour for accuracy
elementProfile
object
{ dominant, secondary } element distribution across all placements
placements
array
All 10 planetary positions: { planet, sign, house, dignity }
synthesis
string
LLM-generated natal chart interpretation
signProfile.medical
string
Medical Astrology — body systems and health tendencies for the sun sign
signProfile.bodyParts
string
Body parts ruled by the sun sign
signProfile.herbalAllies
string
Herbs and plants associated with the sun sign
signProfile.symbolism
string
Mythological and symbolic associations
signProfile.houseRulership
string
Natural house ruled by the sun sign
signProfile.mantra
string
Affirmation mantra for the sun sign
signProfile.majorArcana
string
Tarot Major Arcana card associated with the sun sign
signProfile.minorArcana
string
Tarot Minor Arcana suit and cards for the sun sign
signProfile.famousPeople
string
Notable people born under the sun sign
creditsUsed
number
TIAN Points consumed (1 per call)
curl "https://api.asktian.com/api/trpc/horoscope.calculate?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-01-15%22%7D%7D"

Example Response

{"result":{"data":{"json":{"sunSign":"Capricorn","moonSign":"Scorpio","ascendant":"Virgo","elementProfile":{"dominant":"earth"},"synthesis":"The Capricorn Sun...","signProfile":{"sign":"capricorn","medical":"...","bodyParts":"...","herbalAllies":"...","mantra":"...","majorArcana":"...","minorArcana":"..."},"creditsUsed":1}}}}}

Twelve Palaces 十二宮命理

1 endpoint
POST/trpc/twelvepalaces.calculate
▶ Try in Playground

十二宮命理 (Twelve Palaces Destiny) — Cantonese lunar birth fortune system. Derives the life palace (1–14) and degree (0,2,4,6,8) from four lunar birth components: zodiac year (12 animals), lunar month (1–12), lunar day (1–30), and birth hour (12 Chinese time branches). Returns the palace name, classical poem (詩曰), marriage fortune (婚姻), wealth fortune (財運), and an LLM-generated synthesis. 5 TIAN Points per call.

Parameters

zodiacYear
string
Chinese zodiac animal of the birth year. One of: Rat, Ox, Tiger, Rabbit, Dragon, Snake, Horse, Goat, Monkey, Rooster, Dog, Pig.
lunarMonth
number
Lunar birth month (1–12). Use the Chinese lunar calendar month, not the Gregorian month.
lunarDay
number
Lunar birth day (1–30). Use the Chinese lunar calendar day.
birthHour
string
Chinese time branch for birth hour. One of: Zi (23:00–01:00), Chou (01:00–03:00), Yin (03:00–05:00), Mao (05:00–07:00), Chen (07:00–09:00), Si (09:00–11:00), Wu (11:00–13:00), Wei (13:00–15:00), Shen (15:00–17:00), You (17:00–19:00), Xu (19:00–21:00), Hai (21:00–23:00).
question
string?
Optional question to focus the LLM synthesis on marriage, wealth, or life path (max 500 chars).
curl -X POST https://api.asktian.com/api/trpc/twelvepalaces.calculate \
  -H "Content-Type: application/json" \
  -H "X-API-Key: your_api_key" \
  -d '{"json":{"zodiacYear":"Dragon","lunarMonth":3,"lunarDay":15,"birthHour":"Wu","question":"What is my wealth destiny?"}}'

Example Response

{"result":{"data":{"json":{"palace":12,"degree":6,"palaceName":"官祿之命","palaceTitle":"十二宮六度","poem":"詩曰:命主為宮福祿長,富貴得來實非常,名題金塔傳金榜,定中高科天下揚。","marriage":"男命中一妻一妾,早經註定,二十之外,有高親可攀。女命賢淡,有事共商,四德俱備,幫夫有緣。","wealth":"正財十是,偉財亦多,初限之間,大展鴻業,作事到處順手,中限以至暮運,財帛口進紛紛。","totalScore":"12宮6度","componentScores":{"zodiacYear":"1宮6度","lunarMonth":"3宮6度","lunarDay":"3宮4度","birthHour":"1宮8度"},"synthesis":"Your birth palace is the 12th Palace, 6th Degree — 官祿之命 (Palace of Official Prosperity). This is one of the most auspicious palace-degree combinations in the Twelve Palaces system...","creditsUsed":5}}}}}

Mahabote 羅甸占星

1 endpoint
POST/trpc/mahabote.calculate
▶ Try in Playground

Mahabote (မဟာဘုတ်) — Burmese planetary house system. Derives the birth planet from day of week, constructs a 7-house natal chart from the Burmese calendar year, calculates the current major and minor period from the 108-year cycle, assesses the Grand Trine and Minor Trine quality, and generates a year chart for the query date. Returns all chart data plus an LLM-generated synthesis. 5 TIAN Points per call.

Parameters

birthDate
string
ISO date string YYYY-MM-DD (e.g. 1990-01-15).
isPM
boolean?
Set true for Wednesday PM births (assigns Rahu instead of Mercury). Defaults to false.
📅 Real-world example: 1990-03-14 was a Wednesday. Passing isPM: true for this date assigns Rahu (ကျက်) as the birth planet instead of Mercury (ဗုဓ). Wednesday is the only day in Burmese astrology that splits into two birth planets depending on whether the person was born before or after noon.
queryDate
string?
ISO date for year-chart analysis. Defaults to today.
question
string?
Optional question to focus the LLM synthesis (max 500 chars).
curl -X POST https://api.asktian.com/api/trpc/mahabote.calculate \
  -H "Content-Type: application/json" \
  -H "X-API-Key: your_api_key" \
  -d '{"json":{"birthDate":"1990-03-14","isPM":true,"question":"What does my Rahu birth planet reveal about my destiny?"}}'

Example Response

{"result":{"data":{"json":{"birthPlanet":"Rahu","natalHouse":{"planet":"Rahu","house":7,"theme":"Transformation & Hidden Power"},"houseChart":[{"house":1,"planet":"Sun"},{"house":2,"planet":"Moon"},{"house":3,"planet":"Mars"},{"house":4,"planet":"Mercury"},{"house":5,"planet":"Jupiter"},{"house":6,"planet":"Venus"},{"house":7,"planet":"Rahu"}],"currentMajorPeriod":{"planet":"Rahu","years":17,"startAge":0,"endAge":17},"currentMinorPeriod":{"planet":"Jupiter","months":22},"grandTrine":{"planets":["Jupiter","Venus","Rahu"],"quality":"Powerful"},"minorTrine":{"planets":["Sun","Moon","Mars"],"quality":"Mixed"},"yearChart":[{"house":1,"planet":"Jupiter"}],"fortuneScore":82,"planetIcons":{"Rahu":{"default":"https://d2xsxph8kpxj0f.cloudfront.net/...planet-rahu-default.png","shiny":"https://d2xsxph8kpxj0f.cloudfront.net/...planet-rahu-shiny.png"}},"synthesis":"Born on a Wednesday afternoon, your birth planet is Rahu (Kyat) — the shadow dragon of Burmese cosmology. Rahu in House 7 bestows an intense, transformative energy: you are drawn to hidden knowledge, unconventional paths, and deep psychological insight...","creditsUsed":5}}}}}

Life Blueprint 稱骨算命

1 endpoint
POST/trpc/life.boneWeight
▶ Try in Playground

袁天罡稱骨算命 (Bone Weight Fortune Reading) — calculates a person's life blueprint from their Gregorian birth date (auto-converted to lunar) and birth hour using the classical 稱骨 weight table attributed to Tang dynasty astrologer Yuan Tiangang. Returns bone weight score (in 兩), fortune category (命格), classical poem, wealth outlook (財運), longevity indicator (壽元), marriage timing (適婚年齡), and an LLM-generated life narrative focused on career, wealth, relationships, and health. 5 TIAN Points per call.

Parameters

solarYear
number
Birth year (Gregorian, e.g. 1990). Auto-converted to lunar.
solarMonth
number
Birth month (1–12, Gregorian).
solarDay
number
Birth day (1–31, Gregorian).
birthHour
string
Chinese earthly branch birth hour: zi/chou/yin/mao/chen/si/wu/wei/shen/you/xu/hai.
gender
string
"male" or "female" — affects fortune interpretation.
question
string?
Optional life question to focus the LLM narrative (max 500 chars).
privyToken
string?
Privy JWT for wallet deduction (required for non-Enterprise plans).
curl -X POST https://api.asktian.com/api/trpc/life.boneWeight \
  -H "Content-Type: application/json" \
  -H "X-API-Key: your_api_key" \
  -d '{"json":{"solarYear":1990,"solarMonth":3,"solarDay":15,"birthHour":"wu","gender":"male","question":"What does my life path hold?"}}' 

Example Response

{"result":{"data":{"json":{"boneWeight":15.5,"category":"大富","poem":"此命生來骨格輕,...","wealthOutlook":"財運亨通,中年後大富","longevity":"壽元較長,注意保養","marriageAge":"適婚年齡在25-30歲","narrative":"Your life blueprint reveals a path of gradual accumulation and late-blooming prosperity...","lunarDate":{"year":1990,"month":2,"day":19},"creditsUsed":5}}}}

I Ching Numerology 易经数字学

4 endpoints
POST/trpc/iching.numberReading
▶ Try in Playground

I Ching Numerology number analysis — analyses any number string (phone, IC, car plate, house number) by extracting consecutive digit pairs and mapping each pair to one of the eight I Ching Numerology stars (1-Water, 2-Earth, 3-Wood, 4-Wood, 5-Earth, 6-Metal, 7-Metal, 8-Earth, 9-Fire). Returns star name, element, personality traits, career guidance, and a ranked best-to-worst assessment for each pair. 5 TIAN Points per call.

Parameters

number
string
The number string to analyse (e.g. phone number, IC number, car plate). Digits only, max 20 characters.
question
string?
Optional question to focus the reading (max 300 chars).
curl -X POST https://api.asktian.com/api/trpc/iching.numberReading \
  -H "Authorization: Bearer at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"number":"91234567","question":"Is this a good phone number?"}}'

Example Response

{"result":{"data":{"json":{"number":"91234567","pairs":[{"pair":"91","star":"9-1","starName":"Fire-Water","element":"Fire meets Water","traits":"Conflict and tension, water extinguishes fire","career":"Avoid partnerships; independent work preferred","rank":"Challenging"},{"pair":"12","starName":"Water-Earth","element":"Water meets Earth","traits":"Nurturing, stable, good for family","rank":"Favourable"}],"overallAssessment":"Mixed number — strong water element with some conflict pairs","creditsUsed":5}}}}
POST/trpc/iching.rootNumber
▶ Try in Playground

I Ching Numerology root number profile — computes a root number (1–9) from a birth date using I Ching Numerology digit-sum reduction (sum all digits of YYYYMMDD repeatedly until single digit), then returns a full personality and life-path profile including strengths, weaknesses, career fit, and relationship style. 5 TIAN Points per call.

Parameters

birthDate
string
Birth date in YYYY-MM-DD format.
question
string?
Optional question to focus the reading (max 300 chars).
curl -X POST https://api.asktian.com/api/trpc/iching.rootNumber \
  -H "Authorization: Bearer at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"birthDate":"1990-05-15"}}'

Example Response

{"result":{"data":{"json":{"birthDate":"1990-05-15","rootNumber":3,"starName":"3-Wood","element":"Wood","personality":"Creative, expressive, growth-oriented","strengths":["Innovative","Communicative","Optimistic"],"weaknesses":["Scattered","Impulsive"],"careerFit":"Arts, media, education, entrepreneurship","relationshipStyle":"Warm and expressive but needs freedom","creditsUsed":5}}}}
POST/trpc/iching.partnerCompat
▶ Try in Playground

I Ching Numerology partner compatibility — compares two root numbers (1–9) and returns a compatibility analysis covering harmony reasons, conflict reasons, and a compatibility score. All 81 pairings covered. 5 TIAN Points per call.

Parameters

birthDateA
string
First person's birth date in YYYY-MM-DD format. Root number is derived automatically.
birthDateB
string
Second person's birth date in YYYY-MM-DD format.
language
string?
"en" (default) or "zh" — controls language of synthesis text.
curl -X POST https://api.asktian.com/api/trpc/iching.partnerCompat \
  -H "Authorization: Bearer at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"birthDateA":"1990-05-15","birthDateB":"1988-08-22"}}'

Example Response

{"result":{"data":{"json":{"personA":{"birthDate":"1990-05-15","rootNumber":3,"keywords":["Creative","Expressive","Growth-oriented"]},"personB":{"birthDate":"1988-08-22","rootNumber":7,"keywords":["Analytical","Precise","Intuitive"]},"harmony":"Wood feeds Fire energy; both are expressive and social","conflict":"Metal (7) cuts Wood (3) — 7 can be critical of 3's spontaneity","synthesis":"Person A (Root 3): Creative, Expressive. Person B (Root 7): Analytical, Precise. Harmony: Wood feeds Fire | Tension: Metal cuts Wood","creditsUsed":5}}}}
POST/trpc/iching.personalYear
▶ Try in Playground

I Ching Numerology personal year forecast — calculates the current personal year number (1–9) from a birth date and the current year using I Ching Numerology cycle rules, then returns a full forecast covering the year's theme, opportunities, challenges, and recommended actions. 5 TIAN Points per call.

Parameters

birthDate
string
Birth date in YYYY-MM-DD format.
year
number?
Year to forecast (defaults to current year if omitted).
curl -X POST https://api.asktian.com/api/trpc/iching.personalYear \
  -H "Authorization: Bearer at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"birthDate":"1990-05-15","year":2026}}'

Example Response

{"result":{"data":{"json":{"birthDate":"1990-05-15","year":2026,"personalYearNumber":5,"theme":"Change and transformation","opportunities":"Major life shifts, new directions, travel","challenges":"Instability, scattered energy, overcommitting","recommendedActions":"Embrace change, avoid rigid plans, focus on adaptability","creditsUsed":5}}}}

I Ching Coin Toss 易經擲錢卦

1 endpoint
GET/trpc/iching.coinToss
▶ Try in Playground

I Ching Coin Toss Oracle — simulates the traditional 3-coin toss method to generate one of the 64 hexagrams and returns the hexagram symbol, title, summary, full description, line values, and an LLM oracle reading for the querent's question. 2 TIAN Points per call — the lowest-cost endpoint on the platform.

Parameters

question
string?
Optional question for the oracle (max 500 chars). If omitted, a general reading is returned.
language
string?
Response language: "en" (default) or "zh".
curl -X GET "https://api.asktian.com/api/trpc/iching.coinToss?input=%7B%22json%22%3A%7B%22question%22%3A%22Should%20I%20take%20this%20new%20job%3F%22%7D%7D" \
  -H "Authorization: Bearer at_live_xxxx"

Example Response

{"result":{"data":{"json":{"hexagramNumber":1,"symbol":"☰","title":"The Creative","summary":"Pure yang energy — initiative, strength, and creative force.","lines":[7,9,7,8,7,9],"question":"Should I take this new job?","interpretation":"The Creative hexagram signals a powerful time for bold action...","creditsUsed":2}}}}

I Ching House Number 易經門牌號碼

1 endpoint
GET/trpc/iching.houseNumber
▶ Try in Playground

I Ching House Number Feng Shui — analyses a house or unit number by extracting consecutive digit pairs and mapping each to one of the 8 feng shui stars (生气 Sheng Qi, 延年 Yan Nian, 天医 Tian Yi, 伏位 Fu Wei, 祸害 Huo Hai, 六煞 Liu Sha, 五鬼 Wu Gui, 绝命 Jue Ming). Returns star type, romance/career/wealth/health/family influences, overall rating (1–5), and an LLM feng shui assessment. 5 TIAN Points per call.

Parameters

houseNumber
string
House or unit number to analyse (e.g. '123', '8A', '88-3'). Letters and hyphens are stripped; only digits are used.
language
string?
Response language: "en" (default) or "zh".
curl -X GET "https://api.asktian.com/api/trpc/iching.houseNumber?input=%7B%22json%22%3A%7B%22houseNumber%22%3A%22168%22%7D%7D" \
  -H "Authorization: Bearer at_live_xxxx"

Example Response

{"result":{"data":{"json":{"houseNumber":"168","digits":"168","pairs":[{"pair":"16","star":"Sheng Qi","starZh":"生气","symbol":"生","type":"great_auspicious","typeZh":"大吉","romance":"成熟稳定","career":"左右逢源,向苦后甜","wealth":"额外收入","health":"健康快乐","family":"双喜临门"},{"pair":"68","star":"Liu Sha","starZh":"六煞","symbol":"煞","type":"inauspicious","typeZh":"凶"}],"overallRating":5,"dominantStar":"Sheng Qi","dominantStarZh":"生气","interpretation":"House 168 carries strong Sheng Qi (生气) energy from the 1-6 pair...","creditsUsed":5}}}}

I Ching Car Plate 易經車牌號碼

1 endpoint
GET/trpc/iching.carPlate
▶ Try in Playground

I Ching Car Plate Feng Shui — analyses a vehicle registration number by extracting the numeric digits and mapping consecutive pairs to one of the 8 feng shui stars (生气 Sheng Qi, 延年 Yan Nian, 天医 Tian Yi, 伏位 Fu Wei, 祸害 Huo Hai, 六煞 Liu Sha, 五鬼 Wu Gui, 绝命 Jue Ming). Returns star type, romance/career/wealth/health/family influences, overall rating (1–5), and an LLM feng shui assessment. 5 TIAN Points per call.

Parameters

plateNumber
string
Vehicle registration number to analyse (e.g. 'SKB1234', 'WXY 5678', 'ABC-999'). Letters and non-digit characters are stripped; only digits are used.
language
string?
Response language: "en" (default) or "zh".
curl -X GET "https://api.asktian.com/api/trpc/iching.carPlate?input=%7B%22json%22%3A%7B%22plateNumber%22%3A%22SKB1234%22%7D%7D" \
  -H "Authorization: Bearer at_live_xxxx"

Example Response

{"result":{"data":{"json":{"plateNumber":"SKB1234","digits":"1234","pairs":[{"pair":"12","star":"Wu Gui","starZh":"五鬼","symbol":"鬼","type":"inauspicious"},{"pair":"23","star":"Tian Yi","starZh":"天医","symbol":"天","type":"auspicious"},{"pair":"34","star":"Wu Gui","starZh":"五鬼","symbol":"鬼","type":"inauspicious"}],"overallRating":2,"dominantStar":"Wu Gui","dominantStarZh":"五鬼","interpretation":"Plate SKB1234 carries mixed energy...","creditsUsed":5}}}}

I Ching Phone Number 易經手機號碼

1 endpoint
GET/trpc/iching.phoneNumber
▶ Try in Playground

I Ching Phone Number Feng Shui — analyses a mobile or landline number by extracting digits and mapping consecutive pairs to one of the 8 feng shui stars (生气 Sheng Qi, 延年 Yan Nian, 天医 Tian Yi, 伏位 Fu Wei, 祸害 Huo Hai, 六煞 Liu Sha, 五鬼 Wu Gui, 绝命 Jue Ming). Returns star type, romance/career/wealth/health/family influences, overall rating (1–5), and an LLM feng shui assessment. 5 TIAN Points per call.

Parameters

phoneNumber
string
Phone or mobile number to analyse (e.g. '91234567', '+65 9123 4567'). Non-digit characters are stripped; only digits are used.
language
string?
Response language: "en" (default) or "zh".
curl -X GET "https://api.asktian.com/api/trpc/iching.phoneNumber?input=%7B%22json%22%3A%7B%22phoneNumber%22%3A%2291234567%22%7D%7D" \
  -H "Authorization: Bearer at_live_xxxx"

Example Response

{"result":{"data":{"json":{"phoneNumber":"91234567","digits":"91234567","pairs":[{"pair":"91","star":"Sheng Qi","starZh":"生气","symbol":"生","type":"great_auspicious"},{"pair":"12","star":"Wu Gui","starZh":"五鬼","symbol":"鬼","type":"inauspicious"},{"pair":"23","star":"Tian Yi","starZh":"天医","symbol":"天","type":"auspicious"}],"overallRating":3,"dominantStar":"Sheng Qi","dominantStarZh":"生气","interpretation":"Phone 91234567 opens with strong Sheng Qi energy...","creditsUsed":5}}}}

I Ching IC / NRIC Number 易經身份證號碼

1 endpoint
GET/trpc/iching.icNumber
▶ Try in Playground

I Ching IC / NRIC Number Feng Shui — analyses a national identity card, NRIC, or passport number by extracting its digits and mapping consecutive pairs to one of the 8 feng shui stars. Returns star type, romance/career/wealth/health/family influences, overall rating (1–5), dominant star, and an LLM feng shui assessment. 5 TIAN Points per call.

Parameters

icNumber
string
IC, NRIC, or passport number to analyse (e.g. 'S1234567A', 'G1234567X'). Non-digit characters are stripped; only digits are used.
language
string?
Response language: "en" (default) or "zh".
curl -X GET "https://api.asktian.com/api/trpc/iching.icNumber?input=%7B%22json%22%3A%7B%22icNumber%22%3A%22S1234567A%22%7D%7D" \
  -H "Authorization: Bearer at_live_xxxx"

Example Response

{"result":{"data":{"json":{"icNumber":"S1234567A","digits":"1234567","pairs":[{"pair":"12","star":"Wu Gui","starZh":"五鬼","symbol":"鬼","type":"inauspicious"},{"pair":"23","star":"Tian Yi","starZh":"天医","symbol":"天","type":"auspicious"},{"pair":"34","star":"Wu Gui","starZh":"五鬼","symbol":"鬼","type":"inauspicious"}],"overallRating":2,"dominantStar":"Wu Gui","dominantStarZh":"五鬼","interpretation":"IC number S1234567A carries mixed energy...","creditsUsed":5}}}}

I Ching Business Name 易經公司名稱

1 endpoint
POST/trpc/iching.businessName
▶ Try in Playground

I Ching Business Name Feng Shui — analyses a Chinese or English business name using stroke-count numerology. Each character's stroke count is summed and reduced to a single digit, then mapped to one of the 8 feng shui stars. Returns stroke counts, star mappings, overall rating (1–5), and an LLM feng shui assessment. 5 TIAN Points per call.

Parameters

businessName
string
Business or brand name to analyse (e.g. '阿里巴巴', 'Apple', 'DBS Bank'). Chinese characters use stroke count; English letters use their ordinal position reduced to a single digit.
language
string?
Response language: "en" (default) or "zh".
curl -X POST https://api.asktian.com/api/trpc/iching.businessName \
  -H "Authorization: Bearer at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"businessName":"阿里巴巴"}}'

Example Response

{"result":{"data":{"json":{"businessName":"阿里巴巴","characters":[{"char":"阿","strokes":8,"digit":8,"star":"Fu Wei","starZh":"伏位"},{"char":"里","strokes":7,"digit":7,"star":"Huo Hai","starZh":"祸害"},{"char":"巴","strokes":4,"digit":4,"star":"Tian Yi","starZh":"天医"},{"char":"巴","strokes":4,"digit":4,"star":"Tian Yi","starZh":"天医"}],"overallRating":3,"dominantStar":"Tian Yi","dominantStarZh":"天医","interpretation":"Business name 阿里巴巴 carries healing and wealth energy from Tian Yi...","creditsUsed":5}}}}

I Ching Batch Numbers 易經批量號碼分析

1 endpoint
POST/trpc/iching.batchNumbers
▶ Try in Playground

I Ching Batch Numbers — analyse up to 10 numbers in a single API call using the 8-star feng shui pair system. Each number is independently scored; results are returned sorted by overall rating (highest first). Ideal for comparing multiple phone numbers, house numbers, or car plates before making a selection. 5 TIAN Points per number.

Parameters

numbers
string[]
Array of 1–10 number strings to analyse (e.g. ['168', '888', '123']). Each entry is processed independently.
type
string?
Number type hint for the LLM context: "houseNumber" | "carPlate" | "phoneNumber" | "icNumber" | "general" (default).
language
string?
Response language: "en" (default) or "zh".
curl -X POST https://api.asktian.com/api/trpc/iching.batchNumbers \
  -H "Authorization: Bearer at_live_xxxx" \
  -H "Content-Type: application/json" \
  -d '{"json":{"numbers":["168","888","123"],"type":"houseNumber"}}'

Example Response

{"result":{"data":{"json":{"results":[{"number":"888","overallRating":5,"dominantStar":"Sheng Qi","dominantStarZh":"生气","rank":1},{"number":"168","overallRating":4,"dominantStar":"Yan Nian","dominantStarZh":"延年","rank":2},{"number":"123","overallRating":2,"dominantStar":"Wu Gui","dominantStarZh":"五鬼","rank":3}],"totalNumbers":3,"creditsUsed":15}}}}

Bazi 神煞

1 endpoint
GET/trpc/bazi.shenSha
▶ Try in Playground

Bazi 神煞 (ShenSha) — identifies the auspicious and inauspicious divine spirits active in a Bazi chart based on the birth date. Looks up 42 spirits from the 问真神煞大全 reference and returns which ones are present with their classical formulas, summaries, and LLM interpretation. 5 TIAN Points per call.

Parameters

birthDate
string
Birth date in YYYY-MM-DD format.
birthHour
number?
Birth hour (0–23, 24-hour). Optional but improves accuracy.
language
string?
Response language: "en" (default) or "zh".
curl -X GET "https://api.asktian.com/api/trpc/bazi.shenSha?input=%7B%22json%22%3A%7B%22birthDate%22%3A%221990-05-15%22%7D%7D" \
  -H "Authorization: Bearer at_live_xxxx"

Example Response

{"result":{"data":{"json":{"birthDate":"1990-05-15","yearPillar":"庚午","monthBranch":"申","dayBranch":"巳","shenshaPresent":[{"name":"天乙贵人","type":"auspicious","summary":"天乙贵人是最吉的神煞之一,主得贵人相助、化凶为吉"}],"auspiciousCount":3,"inauspiciousCount":2,"neutralCount":1,"interpretation":"...","creditsUsed":5}}}}

Try the API Playground

Test any endpoint interactively — no code required.