File tree Expand file tree Collapse file tree 2 files changed +38
-0
lines changed Expand file tree Collapse file tree 2 files changed +38
-0
lines changed Original file line number Diff line number Diff line change @@ -60,3 +60,35 @@ Then set up the database by running the following commands on the command line:
60
60
./yii migrate/up
61
61
./yii faker
62
62
63
+ ## Try it
64
+
65
+ cd api
66
+ make start
67
+
68
+ Your API is now available at ` http://localhost:8337/ ` . Try to access an endpoint of your spec via ` curl ` :
69
+
70
+ $ curl http://localhost:8337/pets
71
+ [
72
+ {
73
+ "name": "Eos rerum modi et quaerat voluptatibus.",
74
+ "tag": "Totam in commodi in est nisi nihil aut et."
75
+ },
76
+ {
77
+ "name": "Voluptas quia eos nisi deleniti itaque aspernatur aspernatur.",
78
+ "tag": "Temporibus id culpa dolorem sequi aut."
79
+ },
80
+ {
81
+ "name": "Facere aut similique laboriosam omnis perferendis et.",
82
+ "tag": "Quo harum quo et ea distinctio non quam."
83
+ },
84
+ ...
85
+ ]
86
+
87
+
88
+ # Support
89
+
90
+ Professional support, consulting as well as software development services are available:
91
+
92
+ https://www.cebe.cc/en/contact
93
+
94
+ Development of this library is sponsored by [ cebe.:cloud : "Your Professional Deployment Platform"] ( https://cebe.cloud ) .
Original file line number Diff line number Diff line change 19
19
'response ' => [
20
20
'class ' => yii \web \Response::class,
21
21
'format ' => yii \web \Response::FORMAT_JSON ,
22
+ 'formatters ' => [
23
+ yii \web \Response::FORMAT_JSON => [
24
+ 'class ' => \yii \web \JsonResponseFormatter::class,
25
+ 'prettyPrint ' => YII_DEBUG ,
26
+ ],
27
+ ],
22
28
],
23
29
'urlManager ' => [
24
30
'enablePrettyUrl ' => true ,
You can’t perform that action at this time.
0 commit comments