Skip to content

Commit d03b04e

Browse files
author
abzokhattab
committed
readme
1 parent f0bc391 commit d03b04e

File tree

2 files changed

+187
-1
lines changed

2 files changed

+187
-1
lines changed

verylinkedin/mypost/README.md

Lines changed: 187 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,187 @@
1+
# Project: Scalable
2+
3+
## End-point: createPost
4+
### Method: POST
5+
>```
6+
>http://127.0.0.1:8080/api/v1/posts/createPost
7+
>```
8+
### Body (**raw**)
9+
10+
```json
11+
{
12+
"userId": "1",
13+
"content": "hi hamada",
14+
"label":"AI"
15+
}
16+
```
17+
18+
19+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
20+
21+
## End-point: Recommend Posts
22+
### Method: GET
23+
>```
24+
>127.0.0.1:8080/api/v1/posts/recommend?label=AI&curUserId=1
25+
>```
26+
### Query Params
27+
28+
|Param|value|
29+
|---|---|
30+
|label|AI|
31+
|curUserId|1|
32+
33+
34+
35+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
36+
37+
## End-point: Edit post
38+
### Method: PUT
39+
>```
40+
>localhost:8080/api/v1/posts/editPost
41+
>```
42+
### Body (**raw**)
43+
44+
```json
45+
{
46+
"curUserId":"1",
47+
"postId": "629fe09e63dca132f287cf14",
48+
"content": "hello world new"
49+
}
50+
```
51+
52+
53+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
54+
55+
## End-point: Like post
56+
### Method: PUT
57+
>```
58+
>localhost:8080/api/v1/posts/likePost
59+
>```
60+
### Body (**raw**)
61+
62+
```json
63+
{
64+
65+
"postId": "629fe09e63dca132f287cf14",
66+
"curUserId":"3"
67+
}
68+
```
69+
70+
71+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
72+
73+
## End-point: Ban user
74+
### Method: PUT
75+
>```
76+
>localhost:8080/api/v1/posts/banUser
77+
>```
78+
### Body (**raw**)
79+
80+
```json
81+
{ "curUserId":"1",
82+
"postId": "629fe09e63dca132f287cf14",
83+
"userId": "2"
84+
}
85+
```
86+
87+
88+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
89+
90+
## End-point: Add comment
91+
### Method: PUT
92+
>```
93+
>localhost:8080/api/v1/posts/addComment
94+
>```
95+
### Body (**raw**)
96+
97+
```json
98+
{
99+
"postId": "629fe09e63dca132f287cf14",
100+
"curUserId": "3",
101+
"content":"test"
102+
}
103+
```
104+
105+
106+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
107+
108+
## End-point: Unlike post
109+
### Method: PUT
110+
>```
111+
>localhost:8080/api/v1/posts/unlikePost
112+
>```
113+
### Body (**raw**)
114+
115+
```json
116+
{
117+
118+
"postId": "629fe09e63dca132f287cf14",
119+
"curUserId":"3"
120+
}
121+
```
122+
123+
124+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
125+
126+
## End-point: get post
127+
Create chat
128+
### Method: GET
129+
>```
130+
>localhost:8080/api/v1/posts/629fe09e63dca132f287cf14?curUserId=2
131+
>```
132+
### Query Params
133+
134+
|Param|value|
135+
|---|---|
136+
|curUserId|2|
137+
138+
139+
140+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
141+
142+
## End-point: get post without login
143+
Create chat
144+
### Method: GET
145+
>```
146+
>localhost:8080/api/v1/posts/629fe09e63dca132f287cf14
147+
>```
148+
149+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
150+
151+
## End-point: get posts
152+
Create chat
153+
### Method: GET
154+
>```
155+
>localhost:8080/api/v1/posts?userId=1
156+
>```
157+
### Query Params
158+
159+
|Param|value|
160+
|---|---|
161+
|userId|1|
162+
163+
164+
165+
⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃ ⁃
166+
167+
## End-point: upload media
168+
### Method: POST
169+
>```
170+
>http://localhost:8080/api/v1/posts/upload?postId=629fe09e63dca132f287cf14&curUserId=1
171+
>```
172+
### Body formdata
173+
174+
|Param|value|Type|
175+
|---|---|---|
176+
|file|/C:/Users/Lenovo/Downloads/Screenshot 2022-06-07 230935.png|file|
177+
178+
179+
### Query Params
180+
181+
|Param|value|
182+
|---|---|
183+
|postId|629fe09e63dca132f287cf14|
184+
|curUserId|1|
185+
186+
187+

verylinkedin/mypost/src/main/java/README.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)