డాక్స్
మీ మొదటి Mantrilo API రిక్వెస్ట్ చేయండి
మంత్రాలు, పవిత్ర ఆడియో, గ్రంథాలు, జ్యోతిషం కోసం ఒకే REST API. మీరు నిర్మిస్తున్న దానికి సంబంధించిన గైడ్తో ప్రారంభించండి, లేదా ఏ endpoint నైనా చూడండి. ఉదాహరణలు రెస్పాన్స్ ఫార్మాట్ను చూపిస్తాయి. కొన్ని భాగాలను లేదా ప్లేస్హోల్డర్లను ఉపయోగిస్తాయి.
క్విక్స్టార్ట్
- key పొందండి. ప్రతి ఖాతా శాండ్బాక్స్ key తో మొదలవుతుంది. శాండ్బాక్స్ క్విక్స్టార్ట్ను తెరవండి
- దానిని మీ సర్వర్లోనే ఉంచండి. మీ బ్యాకెండ్ ఎన్విరాన్మెంట్లో
MANTRILO_API_KEY,MANTRILO_API_URLసెట్ చేయండి. - రిక్వెస్ట్ చేయండి. ఒక మంత్రాన్ని జాబితా చేసి, ఆపై endpoint రిఫరెన్స్ ను లేదా మీ లక్ష్యానికి తగిన గైడ్ ను అనుసరించండి.
curl "https://api.mantrilo.com/v1/mantras?limit=1" \
-H "Authorization: Bearer $MANTRILO_API_KEY"మీ లక్ష్యంతో ప్రారంభించండి
ప్రతి గైడ్ మీరు రన్ చేయగల రిక్వెస్ట్తో మొదలై, ఆపై సర్వర్ కోడ్, పేజినేషన్, కోటాను చూపిస్తుంది.
ఉపనిషత్తులను లోడ్ చేయండి
ఒక కలెక్షన్ను నేరుగా పిలిచి, దాని పేజీల గుండా వెళ్లి, ఆపై ఒక గ్రంథాన్ని, అధ్యాయాన్ని లేదా శ్లోకాన్ని తెరవండి.
గైడ్ తెరవండిశోధించగలిగే శ్లోకాల లైబ్రరీని నిర్మించండి
మంత్రాలు, శ్లోకాలను జాబితా చేయండి, దేవత ఆధారంగా ఫిల్టర్ చేయండి, మీరు లోడ్ చేసిన శీర్షికలలో శోధించండి.
గైడ్ తెరవండిపవిత్ర ఆడియోను ప్లే చేయండి
రికార్డింగ్ ఉన్న ఎంట్రీ కోసం తాత్కాలిక ప్లేబ్యాక్ URL ను రిక్వెస్ట్ చేయండి.
గైడ్ తెరవండిగ్రంథ రీడర్ను నిర్మించండి
రామాయణం, మహాభారతాల సంస్కృత శ్లోకాలను లేదా ఆంగ్ల పునఃకథనాలను చదవండి.
గైడ్ తెరవండిజాతక చక్రాలను జోడించండి
ఐచ్ఛిక దశా కాలాలతో లాహిరి జాతక చక్రాన్ని నిర్మించండి.
గైడ్ తెరవండిరోజువారీ పంచాంగాన్ని జోడించండి
స్థానిక రోజువారీ పంచాంగ క్యాలెండర్ను నిర్మించండి.
గైడ్ తెరవండిరోజువారీ మంత్రాన్ని చూపించండి
ఎంచుకున్న మంత్రాన్ని తెచ్చి, దాని మూల సంస్కృతాన్ని, లిప్యంతరీకరణను చూపించండి.
గైడ్ తెరవండిజ్యోతిషంలో ప్రతి సామర్థ్యానికీ ఒక గైడ్ ఉంది. జ్యోతిష సామర్థ్యాలను బ్రౌజ్ చేయండి
ప్రామాణీకరణ
ప్రతి రిక్వెస్ట్లో మీ key ను Authorization: Bearer YOUR_KEY గా పంపండి. API బ్రౌజర్ నుంచి వచ్చే cross-origin కాల్స్ను నిరోధిస్తుంది, కాబట్టి దానిని మీ సర్వర్ నుంచి పిలిచి, కంటెంట్ను మాత్రమే మీ యాప్కు పంపండి. key ను ఎప్పుడూ వెబ్ బండిల్, మొబైల్ యాప్ లేదా రిపోజిటరీలో పెట్టకండి. key లీక్ అయితే, కన్సోల్లో దానిని మళ్లీ రూపొందించండి; పాత key ఒక నిమిషంలో పనిచేయడం ఆగిపోతుంది.
శాండ్బాక్స్, లైవ్
| ఎన్విరాన్మెంట్ | key ప్రిఫిక్స్ | ఇది ఏమి చదువుతుంది |
|---|---|---|
| శాండ్బాక్స్ | mtr_sbx_ | నమూనా మంత్రాలు, నమూనా గ్రంథాల ప్రారంభ శ్లోకాలు, అందుబాటులో ఉన్న జ్యోతిష ఆపరేషన్లు. ప్రతి ఖాతాకు ఒకటి ఉంటుంది. |
| లైవ్ | mtr_live_ | అందుబాటులో ఉన్న పూర్తి కేటలాగ్. పెయిడ్ ప్లాన్తో జారీ చేయబడుతుంది. |
శాండ్బాక్స్, లైవ్ వినియోగాన్ని వేర్వేరుగా లెక్కిస్తాయి. నమూనాలో లేని అంశం కోసం శాండ్బాక్స్ రిక్వెస్ట్ 403 sandbox_sample_only ను ఇస్తుంది.
పేజినేషన్
జాబితా endpoints nextCursor ను ఇస్తాయి. తదుపరి పేజీని చదవడానికి దానిని cursor గా తిరిగి పంపండి. చివరి పేజీలో అది null. పేజీ పరిమాణాన్ని limit (1–100) తో సెట్ చేయండి.
అధ్యాయ పేజీలు nextOffset ను ఇస్తాయి. అదే అధ్యాయంలో మరిన్ని శ్లోకాలు చదవడానికి దానిని offset గా తిరిగి పంపండి.
curl "$MANTRILO_API_URL/v1/books?collection=upanishads&limit=3&cursor={nextCursor}" \
-H "Authorization: Bearer $MANTRILO_API_KEY"ఎర్రర్లు
ప్రతి ఎర్రర్కు ఒకే ఆకృతి ఉంటుంది. code స్థిరంగా ఉంటుంది; ఏమి సరిచేయాలో message వివరిస్తుంది. విజయవంతమైన రెస్పాన్స్లు మాత్రమే మీ ప్లాన్లో లెక్కించబడతాయి.
{
"error": {
"code": "invalid_api_key",
"message": "Send a valid API key."
},
"requestId": "request-id"
}| స్థితి | కోడ్ | ఏమి చేయాలి |
|---|---|---|
400 | invalid_limit, invalid_cursor, invalid_deity, invalid_collection, invalid_offset | మెసేజ్లో పేర్కొన్న query పారామీటర్ను సరిచేయండి. |
400 | invalid_operation, invalid_input, invalid_datetime, invalid_timezone, … | మెసేజ్లో పేర్కొన్న జ్యోతిష ఇన్పుట్ను సరిచేయండి. |
401 | invalid_api_key, revoked_api_key | key లేదు, తప్పుగా ఉంది, లేదా రద్దు చేయబడింది. |
403 | plan_inactive | లైవ్ keys కు యాక్టివ్ పెయిడ్ ప్లాన్ అవసరం. |
403 | sandbox_sample_only | ఆ అంశం శాండ్బాక్స్ నమూనాలో లేదు. మీ లైవ్ key ని ఉపయోగించండి. |
404 | not_found, audio_unavailable | అలాంటి అంశం లేదు, లేదా దానికి రికార్డింగ్ లేదు. |
405 | method_not_allowed | endpoint కోసం పేర్కొన్న method ను ఉపయోగించండి. |
429 | rate_limited | Retry-After హెడర్లో ఉన్నంత సేపు ఆగి, మళ్లీ ప్రయత్నించండి. |
429 | quota_exceeded, audio_quota_exceeded | నెలవారీ కోటా అయిపోయింది. |
429 | too_many_failed_attempts | ఒకే అడ్రస్ నుంచి చాలా తప్పు keys వచ్చాయి. తర్వాత మళ్లీ ప్రయత్నించండి. |
500 | internal_error | మళ్లీ ప్రయత్నించండి, సమస్య కొనసాగితే requestId ను పేర్కొనండి. |
503 | books_unavailable, astrology_unavailable, astrology_operation_unavailable | సేవ లేదా ఆపరేషన్ తాత్కాలికంగా అందుబాటులో లేదు. తర్వాత మళ్లీ ప్రయత్నించండి. |
504 | astrology_timeout | గణనకు చాలా సమయం పట్టింది. మళ్లీ ప్రయత్నించండి. ఏమీ ఛార్జ్ చేయబడదు. |
వినియోగ పరిమితులు
కోటాలు ప్రతి key కు కాకుండా మీ మొత్తం వర్క్స్పేస్కు వర్తిస్తాయి, UTC ప్రకారం నెలనెలా రీసెట్ అవుతాయి. ప్రతి విజయవంతమైన కంటెంట్ రెస్పాన్స్ లేదా జ్యోతిష గణన ఒక రిక్వెస్ట్. ప్రతి ఆడియో లింక్ ఫైల్ పరిమాణాన్ని కూడా లెక్కిస్తుంది.
| ప్లాన్ | నెలకు రిక్వెస్ట్లు | ఆడియో | రేట్ | బర్స్ట్ |
|---|---|---|---|---|
| ఉచితం | 500 | నమూనా ఆడియో మాత్రమే | సెకనుకు 2 | 10 |
| Starter | 50,000 | 10 GB | సెకనుకు 10 | 20 |
| Growth | 2,50,000 | 50 GB | సెకనుకు 25 | 50 |
| Business | 10,00,000 | 200 GB | సెకనుకు 50 | 100 |
రెస్పాన్స్లలో X-RateLimit-Limit, X-RateLimit-Remaining, X-Quota-Requests-Remaining, X-Request-Id ఉంటాయి. rate_limited రెస్పాన్స్లో Retry-After కూడా ఉంటుంది. శాండ్బాక్స్ keys ఎప్పుడూ ఉచిత ప్లాన్ రేట్ను ఉపయోగిస్తాయి. మీ వర్క్స్పేస్కు నెలవారీ రిక్వెస్ట్ పరిమితి లేకపోతే, X-Quota-Requests-Remaining విలువ unlimited. ప్లాన్లను పోల్చండి
రామాయణం, మహాభారతం
ఈ ఆంగ్ల గద్య పునఃకథనాలను చదవడానికి లైవ్ key ని ఉపయోగించండి. అధ్యాయ సూచిక కోసం గ్రంథాన్ని తెరిచి, ఆపై ఒక అధ్యాయ సంఖ్యతో పూర్తి అధ్యాయాన్ని ఒకే రిక్వెస్ట్లో లోడ్ చేయండి.
Ramayana
22 అధ్యాయాలు
curl "$MANTRILO_API_URL/v1/books/ramayana" \
-H "Authorization: Bearer $MANTRILO_API_KEY"
curl "$MANTRILO_API_URL/v1/books/ramayana/chapters/1" \
-H "Authorization: Bearer $MANTRILO_API_KEY"Mahabharata
62 అధ్యాయాలు
curl "$MANTRILO_API_URL/v1/books/mahabharata" \
-H "Authorization: Bearer $MANTRILO_API_KEY"
curl "$MANTRILO_API_URL/v1/books/mahabharata/chapters/1" \
-H "Authorization: Bearer $MANTRILO_API_KEY"గ్రంథాలు format: "prose", language: "en" ను ఇస్తాయి. ఒక అధ్యాయం కోసం, data.source ను చూపించి data.sections పై iterate చేయండి. ప్రతి విభాగం యొక్క title, paragraphs ను క్రమంలో రెండర్ చేయండి. గద్య అధ్యాయాలు ఖాళీ verses array ను, nextOffset: null ను ఇస్తాయి.
Endpoint రిఫరెన్స్
GET /v1
API పేరు, వెర్షన్, రిసోర్స్ జాబితా. హెల్త్ చెక్గా ఉపయోగపడుతుంది.
key అవసరం లేదుపారామీటర్లు లేవు.
curl "$MANTRILO_API_URL/v1"{
"name": "Mantrilo API",
"version": "1",
"authentication": "Authorization: Bearer <your Mantrilo API key>",
"resources": [
"/v1/mantras",
"/v1/books?collection={collection}",
"…"
]
}GET /v1/mantras
మంత్రాలు, శ్లోకాలు, స్థిరమైన క్రమంలో. ప్రతి అంశం శ్లోకాలు లేని సారాంశం.
limitquery- పూర్ణాంకం, 1–100. డిఫాల్ట్ 20.
cursorquery- మునుపటి పేజీలోని nextCursor.
deityquery- shiva లేదా annapurna వంటి దేవత id. ఖచ్చితమైన సరిపోలిక.
curl "$MANTRILO_API_URL/v1/mantras?limit=1" \
-H "Authorization: Bearer $MANTRILO_API_KEY"{
"data": [
{
"id": "annapurna-aham-vaishvanaro-bhuthva",
"title": "Aham Vaishvanaro Bhuthva",
"deity": {
"id": "annapurna",
"name": "Lord Annapurna"
},
"category": "Annapurna Stotras",
"source": "Sanatana Shastras",
"description": "Aham Vaishvanaro Bhutva means \"I, having become the universal fire,\" and in Bhagavad Gita 15.14 Krishna says he lives in every body and digests its food. United with the prana and apana breaths, this inner fire cooks the four kinds of food: chewed, swallowed, licked and sucked. Families often say it before a meal to treat eating as an offering.",
"verseCount": 1,
"audio": {
"href": "/v1/mantras/annapurna-aham-vaishvanaro-bhuthva/audio"
}
}
],
"nextCursor": "YW5uYXB1cm5hLWFoYW0tdmFpc2h2YW5hcm8tYmh1dGh2YQ",
"requestId": "request-id"
}GET /v1/mantras/{id}
శ్లోకాలతో కూడిన ఒక మంత్రం. ఏ పాఠ్య ఫీల్డ్ అయినా null కావచ్చు, కాబట్టి ఉన్నవాటిని మాత్రమే రెండర్ చేయండి.
idpath- జాబితా రెస్పాన్స్లోని మంత్రం id.
description అనేది మంత్రం యొక్క చిన్న పబ్లిక్ సారాంశం. రికార్డ్లో అది లేనప్పుడు null గా ఉంటుంది.
curl "$MANTRILO_API_URL/v1/mantras/annapurna-aham-vaishvanaro-bhuthva" \
-H "Authorization: Bearer $MANTRILO_API_KEY"{
"data": {
"id": "annapurna-aham-vaishvanaro-bhuthva",
"title": "Aham Vaishvanaro Bhuthva",
"deity": {
"id": "annapurna",
"name": "Lord Annapurna"
},
"category": "Annapurna Stotras",
"source": "Sanatana Shastras",
"description": "Aham Vaishvanaro Bhutva means \"I, having become the universal fire,\" and in Bhagavad Gita 15.14 Krishna says he lives in every body and digests its food. United with the prana and apana breaths, this inner fire cooks the four kinds of food: chewed, swallowed, licked and sucked. Families often say it before a meal to treat eating as an offering.",
"verseCount": 1,
"audio": {
"href": "/v1/mantras/annapurna-aham-vaishvanaro-bhuthva/audio"
},
"verses": [
{
"number": 1,
"title": "Aham Vaishvanaro Bhuthva – Verse 1",
"sanskrit": "अहं वैश्वानरो भूत्वा प्राणिनां देहमाश्रितः\nप्राणापान समायुक्तः पचाम्यन्नं चतुर्विधम्",
"transliteration": "ahaṃ vaiśvānaro bhūtvā prāṇināṃ dehamāśritaḥ\nprāṇāpāna samāyuktaḥ pacāmyannaṃ caturvidham",
"translation": null,
"wordMeanings": []
}
]
},
"requestId": "request-id"
}GET /v1/mantras/{id}/audio
audio ఫీల్డ్ null కాని మంత్రం యొక్క రికార్డింగ్. format=json లేకుండా రెస్పాన్స్ ఫైల్కు 302 రీడైరెక్ట్ అవుతుంది.
idpath- మంత్రం id.
formatquery- json రీడైరెక్ట్ చేయకుండా signed లింక్ను JSON గా ఇస్తుంది.
లింక్లు 15 నిమిషాలు పనిచేస్తాయి. ప్రతి లింక్ దాని ఫైల్ పరిమాణాన్ని మీ ఆడియో కోటాలో లెక్కిస్తుంది.
curl "$MANTRILO_API_URL/v1/mantras/annapurna-aham-vaishvanaro-bhuthva/audio?format=json" \
-H "Authorization: Bearer $MANTRILO_API_KEY"{
"data": {
"url": "https://storage.googleapis.com/mantrilo-media/…?X-Goog-Signature=…",
"expiresAt": "2026-11-10T06:45:00.000Z",
"bytes": 123077,
"contentType": "audio/x-m4a"
},
"requestId": "request-id"
}GET /v1/books
కేటలాగ్ క్రమంలో లైవ్ గ్రంథాలు. ఉపనిషత్తుల వంటి సమూహాన్ని నేరుగా పిలవడానికి collection ఆధారంగా ఫిల్టర్ చేయండి.
collectionquery- ఒక కలెక్షన్ id: upanishads, bhagavad-gita, advaita-vedanta-prakarana-granthas, vedanta, yoga.
limitquery- పూర్ణాంకం, 1–100. డిఫాల్ట్ 24.
cursorquery- మునుపటి పేజీలోని nextCursor.
శాండ్బాక్స్ keys ఈశావాస్య ఉపనిషత్తును, భగవద్గీతను జాబితా చేస్తాయి. ఇతర కలెక్షన్లు శాండ్బాక్స్ శీర్షికలను ఇవ్వకపోవచ్చు.
curl "$MANTRILO_API_URL/v1/books?collection=upanishads&limit=3" \
-H "Authorization: Bearer $MANTRILO_API_KEY"{
"data": [
{
"id": "ishaUpanishad",
"title": "Īśāvāsya Upaniṣad",
"author": "Vedic Rishis",
"category": null,
"subcategory": null,
"collection": {
"id": "upanishads",
"name": "Upanishads"
},
"description": "One of the shortest and most profound Upanishads, revealing the nature of the Supreme Lord who pervades all.",
"verseCount": 18
}
],
"nextCursor": null,
"sandbox": true,
"requestId": "request-id"
}GET /v1/books/{id}
అధ్యాయ సూచికతో కూడిన గ్రంథ సారాంశం. పాఠాన్ని రిక్వెస్ట్ చేయడానికి అధ్యాయ సంఖ్యలను ఉపయోగించండి.
idpath- జాబితా రెస్పాన్స్లోని గ్రంథం id.
శాండ్బాక్స్ keys కు preview true గా ఉంటుంది, అవి ప్రారంభ అధ్యాయాన్ని మాత్రమే చూస్తాయి.
curl "$MANTRILO_API_URL/v1/books/ishaUpanishad" \
-H "Authorization: Bearer $MANTRILO_API_KEY"{
"data": {
"id": "ishaUpanishad",
"title": "…",
"collection": {
"id": "upanishads",
"name": "Upanishads"
},
"description": "…",
"chapters": [
{
"number": 1,
"title": "…",
"description": null,
"verseCount": 18
}
],
"preview": false
},
"requestId": "request-id"
}GET /v1/books/{id}/chapters/{chapter}
గరిష్ఠంగా 30 శ్లోకాల పేజీ లేదా గద్య పునఃకథనంలోని పూర్తి అధ్యాయం.
idpath- గ్రంథం id.
chapterpath- గ్రంథ అధ్యాయ సూచికలోని అధ్యాయ సంఖ్య.
offsetquery- శ్లోకాల కోసం, మునుపటి పేజీలోని nextOffset ను పంపండి. గద్యానికి వదిలేయండి.
శాండ్బాక్స్ keys నమూనా గ్రంథాల ప్రారంభ అధ్యాయంలోని మొదటి మూడు శ్లోకాలను చదువుతాయి. రామాయణం, మహాభారతం కు లైవ్ key అవసరం.
curl "$MANTRILO_API_URL/v1/books/ishaUpanishad/chapters/1" \
-H "Authorization: Bearer $MANTRILO_API_KEY"{
"data": {
"number": 1,
"title": "…",
"verseCount": 18,
"verses": [
{
"number": 1,
"sanskrit": "…",
"transliteration": "…",
"translation": null,
"translator": "…",
"wordMeaning": null,
"commentary": null
}
],
"nextOffset": null
},
"requestId": "request-id"
}GET /v1/astrology
ప్రస్తుత ఆపరేషన్ కేటలాగ్, IDలు, వర్గాలు, అందుబాటులో ఉన్న చోట నమూనా ఇన్పుట్లతో.
key అవసరం లేదుపారామీటర్లు లేవు.
curl "$MANTRILO_API_URL/v1/astrology"{
"data": [
{
"id": "positions",
"name": "Planetary positions",
"description": "…"
},
{
"id": "vedic-panchang",
"name": "Panchang",
"category": "Vedic",
"availability": "available",
"example": {
"…": "…"
}
}
]
}POST /v1/astrology/calculate
ఒక ఆపరేషన్ను రన్ చేయండి. operation ను, ఆ ఆపరేషన్ ఇన్పుట్లను JSON గా పంపండి. ప్రతి ఆపరేషన్ ఇన్పుట్లు జ్యోతిష పేజీలో ఉన్నాయి.
operationbody- GET /v1/astrology లోని ఒక ఆపరేషన్ id.
datetimebody- positions, panchang కోసం: సెకన్లు, UTC ఆఫ్సెట్తో ISO 8601.
…body- ఇతర ఇన్పుట్లు ఆపరేషన్పై ఆధారపడతాయి.
విఫలమైన గణనలకు ఛార్జ్ చేయబడదు.
Hindi responses: five operations answer in Hindi when you add "lang": "hi" or "language": "hi" under parameters. These are Daily Rashifal, Daily Rashifal for all signs, the Western daily sign horoscope, Daily Muhurat lookup and Moon sign compatibility. Codes and scores stay the same in both languages. Every other operation answers in English. The list is on the Astrology page.
curl -X POST "$MANTRILO_API_URL/v1/astrology/calculate" \
-H "Authorization: Bearer $MANTRILO_API_KEY" \
-H "Content-Type: application/json" \
-d '{"operation":"positions","datetime":"2026-11-10T12:00:00+05:30"}'{
"data": {
"engineVersion": "mantrilo-astro-1",
"datetimeUtc": "2026-11-10T06:30:00.000Z",
"referenceFrame": "geocentric_true_ecliptic_of_date",
"ayanamsa": {
"model": "lahiri_linear_approximation",
"degrees": 24.232277,
"approximate": true
},
"operation": "positions",
"planets": [
{
"body": "Moon",
"tropicalLongitudeDegrees": 238.933105,
"siderealLongitudeDegrees": 214.700828,
"latitudeDegrees": -4.987681,
"distanceAU": 0.00267702,
"motion": {
"degreesPerDay": 12.232549,
"retrograde": false
},
"rashi": {
"number": 8,
"name": "Vrishchika",
"degreesWithin": 4.700828
},
"nakshatra": {
"number": 17,
"name": "Anuradha",
"pada": 1
}
}
]
},
"calculated": true,
"requestId": "request-id"
}