POSTalphaExperience APIs

Oracle Ask

Answer a direct spiritual question through the paid Lady Avalon API path with strict JSON output, usage metering, and no legacy MCP dependency.

POST /v1/oracle/askQuickstartOpenAPI JSON
Credits

2 credits per answer

Minimum Plan

Basic+

Billing Lane

Light AI

SDK Helper

oracleAsk / oracle_ask

Inputs
  • +question
  • +topic
  • +optional birth date
  • +situation context
  • +desired tone
Outputs
  • +direct answer
  • +insight
  • +support signals
  • +next action
  • +caution
Tool Functions

Capabilities behind this endpoint

3 functions
oracle.ask.generate

Generates a direct display-ready answer.

sun.sign.derive

Derives sun sign when birth_date is supplied.

quality.experience.enforce

Blocks malformed or fallback-looking JSON.

Oracle Question request
{
  "question": "What is the real opportunity in front of me right now?",
  "birth_date": "1990-07-23",
  "topic": "career",
  "context": { "desired_tone": "direct and grounded" }
}
Oracle Question response
{
  "request_id": "req_...",
  "data": {
    "answer": "The opportunity is to take the visible role instead of staying behind the buildout.",
    "insight": "The pattern is asking for leadership with cleaner boundaries.",
    "next_action": "Make the direct offer this week and remove the backup option."
  },
  "usage": { "lane": "ai", "credits": 2, "billableUnits": 1 }
}
curl
curl https://theleokingai.com/api/v1/oracle/ask \
  -X POST \
  -H "Accept: application/json" \
  -H "x-api-key: $LEOKING_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: oracle-ask-subject-123-v1" \
  -d '{
  "question": "What is the real opportunity in front of me right now?",
  "birth_date": "1990-07-23",
  "topic": "career",
  "context": { "desired_tone": "direct and grounded" }
}'
Node SDK
import { TheLeoKingApi } from "@theleoking/ai-api";

const api = new TheLeoKingApi({
  apiKey: process.env.LEOKING_API_KEY,
  baseUrl: "https://theleokingai.com/api"
});

const result = await api.oracleAsk(
  {
  "question": "What is the real opportunity in front of me right now?",
  "birth_date": "1990-07-23",
  "topic": "career",
  "context": { "desired_tone": "direct and grounded" }
},
  "oracle-ask-subject-123-v1"
);

console.log(result.request_id);
console.log(result.usage.credits);
Python SDK
import os
from theleoking_ai_api import TheLeoKingApi

api = TheLeoKingApi(
    api_key=os.environ["LEOKING_API_KEY"],
    base_url="https://theleokingai.com/api",
)

result = api.oracle_ask(
    {
        "question": "What is the real opportunity in front of me right now?",
        "birth_date": "1990-07-23",
        "topic": "career",
        "context": {
            "desired_tone": "direct and grounded",
        },
    },
    idempotency_key="oracle-ask-subject-123-v1",
)

print(result["request_id"])
print(result["usage"]["credits"])
Error Behavior
HTTPCodePartner Action
400INVALID_REQUESTFix the payload shape, enum value, required field, or request body before retrying.
401AUTH_REQUIREDSend x-api-key from a trusted server environment. Do not expose keys in browser code.
401AUTH_INVALIDCheck the key prefix, rotate compromised keys, and verify the target environment.
402CREDITS_EXHAUSTEDUpgrade the plan, add credits, or switch to a lower-cost Core Compute route.
403AUTH_FORBIDDENUse a key scoped for this endpoint or upgrade to the required plan.
404NOT_FOUNDVerify the job id, environment, API key, and whether the job belongs to the same workspace.
409IDEMPOTENCY_CONFLICTReuse idempotency keys only for the same logical operation and identical request payload.
429RATE_LIMITEDBack off, retry later, reduce concurrency, or request enterprise limits.
Related Endpoints