-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathfront-api-specification.json
More file actions
75 lines (75 loc) · 2.66 KB
/
Copy pathfront-api-specification.json
File metadata and controls
75 lines (75 loc) · 2.66 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
{
"openapi": "3.0.2",
"info": {
"title": "Frontend Interview",
"version": "1.0.0"
},
"paths": {
"/d1055cef-c469-49ed-835f-3a55d06f86f1": {
"summary": "Products API",
"servers": [
{
"url": "https://run.mocky.io/v3",
"description": "Mock server"
}
],
"post": {
"requestBody": {
"description": "The product to be created",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Product"
},
"examples": {
"Valid product": {
"value": {
"title": "دورس مدل کلاسیک ۳۲۰ (کرمی)",
"price_tomans": 320000,
"description": "دارای یقه برگردان ساده و آستین بلند"
}
}
}
}
},
"required": true
},
"responses": {
"204": {
"description": "The product was created"
}
},
"summary": "Submit a product"
}
}
},
"components": {
"schemas": {
"Product": {
"title": "Root Type for Product",
"description": "",
"type": "object",
"properties": {
"title": {
"type": "string",
"example": "دارای یقه برگردان ساده و آستین بلند"
},
"price_tomans": {
"format": "int32",
"type": "integer",
"example": "320000"
},
"description": {
"type": "string",
"example": "دورس مدل کلاسیک ۳۲۰ (کرمی)"
}
},
"example": {
"title": "دورس مدل کلاسیک ۳۲۰ (کرمی)",
"price_tomans": 320000,
"description": "دارای یقه برگردان ساده و آستین بلند"
}
}
}
}
}