Skip to content

Commit d1a6542

Browse files
committed
docs: update README
1 parent 96eed9b commit d1a6542

File tree

1 file changed

+44
-14
lines changed

1 file changed

+44
-14
lines changed

README.md

Lines changed: 44 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,55 @@
11
# Random Sentence API
22

3-
## based on
3+
## 🗂️ Data Source
44

55
- traditional korean proverbs, more than 4,000
6+
- from https://www.krpia.co.kr/product/main?plctId=PLCT00004626#none
67
- famous saying (soon)
78
- maxim (soon)
89

910
---
1011

11-
## direction
12+
## 📚 Specification
1213

13-
### api url
14+
(No author information is provided for traditional Korean proverbs.)
1415

15-
💡`https://sentence.udtk.site/random/{count}`
16+
### 1. `https://sentence.udtk.site/{id}`
1617

17-
- count : number of sentences to get
18-
- count range : 1 ~ 20
18+
- **description** : return a sentence by id
19+
20+
### 2. `https://sentence.udtk.site/random?count=`
21+
22+
- **description** : return several random sentences
23+
- request parameter : `count`
24+
- count : number of sentences to get
25+
- range : 1 ~ 20
26+
- default : 1
27+
28+
### 3. `https://sentence.udtk.site/language?language=&count=`
29+
30+
- **description** : return random sentences in chosen language
31+
- request parameter : language, count
32+
- language : `kor`, `eng`
33+
- default : `kor`
34+
- count : number of sentences to get
35+
- range : 1 ~ 20
36+
- default : 1
37+
38+
### 4. `https://sentence.udtk.site/sort?sort=&count=`
39+
40+
- **description** : return random sentences in chosen sort
41+
- request parameter : `sort`, `count`
42+
- sort : `가1`, `가2`, ``, ``, ``, ``, `사1`, `사2`, `아1`, `아2`, `자1`, `자2`, ``, ``, ``, ``, ``, `quote`
43+
- default : `가1`
44+
- count : number of sentences to get
45+
- range : 1 ~ 20
46+
- default : 1
47+
48+
---
1949

2050
### response example
2151

22-
`https://sentence.udtk.site/random/2`
52+
ex) https://sentence.udtk.site/random?count=2
2353

2454
```json
2555
[
@@ -34,15 +64,15 @@
3464
]
3565
```
3666

37-
### request limit
67+
### ❗️request limit
3868

39-
- 20 requests per 5 minutes
40-
- when the limit is exceeded, the response will be `429 Too Many Requests`
41-
- time left to reset the limit will be included in the response header `X-Rate-Limit-Retry-After-Seconds`
69+
- **<U>20 requests per 5 minutes</U>**
70+
- when the limit is exceeded, the response will be 429 Too Many Requests
71+
- time left to reset the limit will be included in the response header X-Rate-Limit-Retry-After-Seconds
4272

4373
---
4474

45-
## stack
75+
## 🛠️ Stack
4676

4777
- Java 17
4878
- Spring Boot 3.3.3
@@ -57,6 +87,6 @@
5787

5888
---
5989

60-
## architecture
90+
## 🏗️ Architecture
6191

62-
<img src="./assets/sentence-architecture.jpg" alt="architecture">
92+
<img src="./assets/sentence-architecture.jpg" alt="architecture" width=600>

0 commit comments

Comments
 (0)