You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -87,7 +87,7 @@ The available grants by default are:
87
87
- Password Grant
88
88
- Refresh Token Grant
89
89
90
-
First you will need to create a client in the `oauth_clients` table, you can refer tho the test [here](https://github.com/joselfonseca/laravel-api/blob/master/tests/Auth/OAuthServerTest.php#L71) for an example. Once you have a client you can send the request to authenticate using this grant to the endpoint `/api/oauth/authorize`
90
+
First you will need to create a client in the `oauth_clients` table, you can refer to the test [here](https://github.com/joselfonseca/laravel-api/blob/master/tests/Auth/OAuthServerTest.php#L71) for an example. Once you have a client you can send the request to authenticate using this grant to the endpoint `/api/oauth/authorize`
91
91
92
92
```
93
93
POST /api/oauth/authorize HTTP/1.1
@@ -142,16 +142,35 @@ if the credentials are incorrect it should return the appropriate 401 response
142
142
}
143
143
```
144
144
145
-
For more information please visit [The oAuth2 repository](https://github.com/lucadegasperi/oauth2-server-laravel/tree/master/docs)
145
+
For more information please visit [The oAuth2 repository](https://github.com/lucadegasperi/oauth2-server-laravel/tree/master/docs)
146
146
147
-
## Dingo/Api
147
+
## Routing
148
148
149
-
This started kit has already set up [dingo/api](https://github.com/dingo/api) to manage routes, requests, responses, protecting endpoint, versioning and much more, for more details please visit [https://github.com/dingo/api](https://github.com/dingo/api)
149
+
We use Dingo/Api for routing, this means you have all the methods available [here](https://github.com/dingo/api/wiki/Creating-API-Endpoints)
150
+
151
+
### Example routes
152
+
153
+
```php
154
+
$api = app('Dingo\Api\Routing\Router');
155
+
$api->version('v1', function ($api) {
156
+
$api->group(['prefix' => 'oauth'], function ($api) {
0 commit comments