Skip to content

Commit 8d723db

Browse files
update
1 parent 3b22bce commit 8d723db

File tree

1 file changed

+58
-54
lines changed

1 file changed

+58
-54
lines changed

README.md

Lines changed: 58 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,43 @@
11
---
2-
description: Bhagavad-Gita-API is An opensource lightweight Node.js based rest API on Vedic Scripture Shrimad Bhagavad Gita
2+
description: Bhagavad-Gita-API is an open-source lightweight Node.js-based REST API for the Vedic Scripture Shrimad Bhagavad Gita.
33
---
44

55
<div align="center"><h1>Bhagavad Gita API</h1></div>
66
<p align="center"><img alt="Bhagavad Gita API" src="https://repository-images.githubusercontent.com/314205765/0bb18d80-2b22-11eb-8f6f-ccf20c0c2679" width="400vw"/></p>
77

8-
## 🚀 Api Reference
8+
## 🚀 API Reference
99

1010
1. GET [/slok/:ch/:sl](#get-slokchsl)
1111
2. GET [/chapters](#get-chapters)
1212
3. GET [/chapter/:ch](#get-chapterch)
13-
14-
1513

1614
## GET /slok/:ch/:sl
1715

18-
**api-method** : get
16+
**api-method**: get
17+
18+
**url**: https://vedicscriptures.github.io/slok/:ch/:sl
19+
20+
**description**: Retrieve specific slok and chapter from Shreemad Bhagavad Gita.
1921

20-
**url** : https://vedicscriptures.github.io/slok/:ch/:sl
22+
**Query parameters**:
23+
- **ch** (_Chapter Number_)
24+
- **type**: _integer_
25+
- **description**: _specific chapter number from any of the 18 chapters_
26+
- **required**: _optional_
27+
- **example**: _1 to 18_
28+
- **sl** (_Slok Number_)
29+
- **type**: _integer_
30+
- **description**: _specific slok number available in that particular chapter_
31+
- **required**: _optional_
32+
- **example**: _1_
2133

22-
**description** : This endpoint allows you to GET data from Particuler slok & chapter of Shreemad Bhagavad Gita
34+
### Example (JSON Fetch)
2335

24-
**Query parameter** :
25-
- **ch** - (_Chapter Number_)
26-
- **type** : _integer_
27-
- **description** : _specfic chapter number from any of 18 chapters_
28-
- **required** : _optional_
29-
- **example** : _1 to 18_
30-
- **sl** - (_Slok Number_)
31-
- **type** : _integer_
32-
- **description** : _specfic slok number avilable in that particuler chapters_
33-
- **required** : _optional_
34-
- **example** : _1_
36+
```json
37+
fetch('https://vedicscriptures.github.io/slok/1/1')
38+
.then(response => response.json())
39+
.then(data => console.log(data));
40+
```
3541

3642
### Output
3743

@@ -134,33 +140,32 @@ description: Bhagavad-Gita-API is An opensource lightweight Node.js based rest A
134140
}
135141
}
136142
```
143+
137144
## GET /chapters
138145

139-
**api-method** : get
146+
**api-method**: get
140147

141-
**url** : https://vedicscriptures.github.io/chapters
148+
**url**: https://vedicscriptures.github.io/chapters
142149

143-
**description** : This endpoint allows you to get all Chapters details of Shreemad Bhagavad Gita.
150+
**description**: Retrieve details of all chapters in Shreemad Bhagavad Gita.
151+
152+
### Example (JSON Fetch)
153+
154+
```json
155+
fetch('https://vedicscriptures.github.io/chapters')
156+
.then(response => response.json())
157+
.then(data => console.log(data));
158+
```
144159

145160
### Output
161+
146162
```json
147163
[
148164
{
149165
"chapter_number": 1,
150166
"verses_count": 47,
151-
"name": "अर्जुनविषादयोग",
152-
"translation": "Arjuna Visada Yoga",
153-
"transliteration": "Arjun Viṣhād Yog",
154-
"meaning": {
155-
"en": "Arjuna's Dilemma",
156-
"hi": "अर्जुन विषाद योग"
157-
},
158-
"summary": {
159-
"en": "The first chapter of the Bhagavad Gita - Arjuna Vishada Yoga introduces the setup, the setting, the characters and the circumstances that led to the epic battle of Mahabharata, fought between the Pandavas and the Kauravas. It outlines the reasons that led to the revelation of the of Bhagavad Gita.\nAs both armies stand ready for the battle, the mighty warrior Arjuna, on observing the warriors on both sides becomes increasingly sad and depressed due to the fear of losing his relatives and friends and the consequent sins attributed to killing his own relatives. So, he surrenders to Lord Krishna, seeking a solution. Thus, follows the wisdom of the Bhagavad Gita.",
160-
"hi": "भगवद गीता का पहला अध्याय अर्जुन विशाद योग उन पात्रों और परिस्थितियों का परिचय कराता है जिनके कारण पांडवों और कौरवों के बीच महाभारत का महासंग्राम हुआ। यह अध्याय उन कारणों का वर्णन करता है जिनके कारण भगवद गीता का ईश्वरावेश हुआ। जब महाबली योद्धा अर्जुन दोनों पक्षों पर युद्ध के लिए तैयार खड़े योद्धाओं को देखते हैं तो वह अपने ही रिश्तेदारों एवं मित्रों को खोने के डर तथा फलस्वरूप पापों के कारण दुखी और उदास हो जाते हैं। इसलिए वह श्री कृष्ण को पूरी तरह से आत्मसमर्पण करते हैं। इस प्रकार, भगवद गीता के ज्ञान का प्रकाश होता है।"
161-
}
167+
"name": "अर्जुनविषादयोग"
162168
},
163-
{"chapter 2": "chapter 17"},
164169
{
165170
"chapter_number": 18,
166171
"verses_count": 78,
@@ -178,38 +183,37 @@ description: Bhagavad-Gita-API is An opensource lightweight Node.js based rest A
178183
}
179184
]
180185
```
186+
181187
## GET /chapter/:ch
182188

183-
**api-method** : get
189+
**api-method**: get
190+
191+
**url**: https://vedicscriptures.github.io/chapter/:ch
184192

185-
**url** : https://vedicscriptures.github.io/chapter/:ch
193+
**description**: Retrieve details of a specific chapter in Shreemad Bhagavad Gita.
186194

187-
**description** : GET Particular Chapters details of Shreemad Bhagavad Gita
195+
**Parameter**:
196+
- **:ch** (_Chapter Number_)
197+
- **type**: _integer_
198+
- **description**: _specific chapter number from any of the 18 chapters_
199+
- **required**: _true_
200+
- **example**: _1 to 18_
188201

189-
**parameter** :
190-
- **:ch** - (_Chapter Number_)
191-
- **type** : _integer_
192-
- **description** : _specfic chapter number from any of 18 chapters_
193-
- **required** : _true_
194-
- **default** : _null_
195-
- **example** : _1 to 18_
202+
### Example (JSON Fetch)
203+
204+
```json
205+
fetch('https://vedicscriptures.github.io/chapter/1')
206+
.then(response => response.json())
207+
.then(data => console.log(data));
208+
```
196209

197210
### Output
211+
198212
```json
199213
{
200214
"chapter_number": 1,
201215
"verses_count": 47,
202-
"name": "अर्जुनविषादयोग",
203-
"translation": "Arjuna Visada Yoga",
204-
"transliteration": "Arjun Viṣhād Yog",
205-
"meaning": {
206-
"en": "Arjuna's Dilemma",
207-
"hi": "अर्जुन विषाद योग"
208-
},
209-
"summary": {
210-
"en": "The first chapter of the Bhagavad Gita - Arjuna Vishada Yoga introduces the setup, the setting, the characters and the circumstances that led to the epic battle of Mahabharata, fought between the Pandavas and the Kauravas. It outlines the reasons that led to the revelation of the of Bhagavad Gita.\nAs both armies stand ready for the battle, the mighty warrior Arjuna, on observing the warriors on both sides becomes increasingly sad and depressed due to the fear of losing his relatives and friends and the consequent sins attributed to killing his own relatives. So, he surrenders to Lord Krishna, seeking a solution. Thus, follows the wisdom of the Bhagavad Gita.",
211-
"hi": "भगवद गीता का पहला अध्याय अर्जुन विशाद योग उन पात्रों और परिस्थितियों का परिचय कराता है जिनके कारण पांडवों और कौरवों के बीच महाभारत का महासंग्राम हुआ। यह अध्याय उन कारणों का वर्णन करता है जिनके कारण भगवद गीता का ईश्वरावेश हुआ। जब महाबली योद्धा अर्जुन दोनों पक्षों पर युद्ध के लिए तैयार खड़े योद्धाओं को देखते हैं तो वह अपने ही रिश्तेदारों एवं मित्रों को खोने के डर तथा फलस्वरूप पापों के कारण दुखी और उदास हो जाते हैं। इसलिए वह श्री कृष्ण को पूरी तरह से आत्मसमर्पण करते हैं। इस प्रकार, भगवद गीता के ज्ञान का प्रकाश होता है।"
212-
}
216+
"name": "अर्जुनविषादयोग"
213217
}
214218
```
215219

0 commit comments

Comments
 (0)