File tree Expand file tree Collapse file tree 1 file changed +62
-0
lines changed Expand file tree Collapse file tree 1 file changed +62
-0
lines changed Original file line number Diff line number Diff line change
1
+ # ARTS
2
+
3
+ | Method | Route | Description |
4
+ | ------ | ----------------------------------------------- | -------------------------------------------------------------- |
5
+ | GET | [ /arts/: userId ] ( #get---arts ) | It will fetch you the user arts based on id. |
6
+
7
+ ## Art Object
8
+ ```
9
+ {
10
+ "id": string,
11
+ "css": string,
12
+ "price": number,
13
+ "title": string,
14
+ "userId": string
15
+ }
16
+ ```
17
+
18
+ ## ** GET /arts/: userId **
19
+
20
+ Returns all the art of the user.
21
+
22
+ - ** Params**
23
+ _ Required:_ ` userId=[string] `
24
+ - ** Query**
25
+ None
26
+ - ** Body**
27
+ None
28
+ - ** Headers**
29
+ Content-Type: application/json
30
+ - ** Cookie**
31
+ rds-session: ` <JWT> `
32
+ - ** Success Response:**
33
+ - ** Code:** 200
34
+ - ** Content:**
35
+
36
+ ```
37
+
38
+ {
39
+ "message": "User Arts of userId <userId> returned successfully",
40
+ "arts": [
41
+ {
42
+ "id": string,
43
+ "css": string,
44
+ "price": number,
45
+ "title": string,
46
+ "userId": string
47
+ }
48
+ {
49
+ }
50
+ ```
51
+
52
+ - **Error Response:**
53
+ - **Code:** 401
54
+ - **Content:**
55
+ `{ 'statusCode': 401, 'error': 'Unauthorized', 'message': 'Unauthenticated User' }`
56
+ - **Code:** 204
57
+ - **Content:**
58
+ `{}`
59
+ - **Code:** 500
60
+ - **Content:**
61
+ `{ 'statusCode': 500, 'error': 'Internal Server Error', 'message': 'An internal server error occurred' }`
62
+
You can’t perform that action at this time.
0 commit comments