Skip to content

Commit 5e4f552

Browse files
authored
docs: replace code.code with code.authorizationCode #216
Merge pull request #222 from menewman/docs-fix-code-parameters thanks to @menewman
2 parents 074e392 + 53bf8d7 commit 5e4f552

File tree

1 file changed

+39
-39
lines changed

1 file changed

+39
-39
lines changed

docs/model/spec.rst

+39-39
Original file line numberDiff line numberDiff line change
@@ -326,25 +326,25 @@ This model function is **required** if the ``authorization_code`` grant is used.
326326

327327
An ``Object`` representing the authorization code and associated data.
328328

329-
+--------------------+--------+--------------------------------------------------------------+
330-
| Name | Type | Description |
331-
+====================+========+==============================================================+
332-
| code | Object | The return value. |
333-
+--------------------+--------+--------------------------------------------------------------+
334-
| code.code | String | The authorization code passed to ``getAuthorizationCode()``. |
335-
+--------------------+--------+--------------------------------------------------------------+
336-
| code.expiresAt | Date | The expiry time of the authorization code. |
337-
+--------------------+--------+--------------------------------------------------------------+
338-
| [code.redirectUri] | String | The redirect URI of the authorization code. |
339-
+--------------------+--------+--------------------------------------------------------------+
340-
| [code.scope] | String | The authorized scope of the authorization code. |
341-
+--------------------+--------+--------------------------------------------------------------+
342-
| code.client | Object | The client associated with the authorization code. |
343-
+--------------------+--------+--------------------------------------------------------------+
344-
| code.client.id | String | A unique string identifying the client. |
345-
+--------------------+--------+--------------------------------------------------------------+
346-
| code.user | Object | The user associated with the authorization code. |
347-
+--------------------+--------+--------------------------------------------------------------+
329+
+------------------------+--------+--------------------------------------------------------------+
330+
| Name | Type | Description |
331+
+========================+========+==============================================================+
332+
| code | Object | The return value. |
333+
+------------------------+--------+--------------------------------------------------------------+
334+
| code.authorizationCode | String | The authorization code passed to ``getAuthorizationCode()``. |
335+
+------------------------+--------+--------------------------------------------------------------+
336+
| code.expiresAt | Date | The expiry time of the authorization code. |
337+
+------------------------+--------+--------------------------------------------------------------+
338+
| [code.redirectUri] | String | The redirect URI of the authorization code. |
339+
+------------------------+--------+--------------------------------------------------------------+
340+
| [code.scope] | String | The authorized scope of the authorization code. |
341+
+------------------------+--------+--------------------------------------------------------------+
342+
| code.client | Object | The client associated with the authorization code. |
343+
+------------------------+--------+--------------------------------------------------------------+
344+
| code.client.id | String | A unique string identifying the client. |
345+
+------------------------+--------+--------------------------------------------------------------+
346+
| code.user | Object | The user associated with the authorization code. |
347+
+------------------------+--------+--------------------------------------------------------------+
348348

349349
``code.client`` and ``code.user`` can carry additional properties that will be ignored by *oauth2-server*.
350350

@@ -364,7 +364,7 @@ An ``Object`` representing the authorization code and associated data.
364364
})
365365
.spread(function(code, client, user) {
366366
return {
367-
code: code.authorization_code,
367+
authorizationCode: code.authorization_code,
368368
expiresAt: code.expires_at,
369369
redirectUri: code.redirect_uri,
370370
scope: code.scope,
@@ -792,25 +792,25 @@ This model function is **required** if the ``authorization_code`` grant is used.
792792

793793
**Arguments:**
794794

795-
+--------------------+----------+---------------------------------------------------------------------+
796-
| Name | Type | Description |
797-
+====================+==========+=====================================================================+
798-
| code | Object | The return value. |
799-
+--------------------+----------+---------------------------------------------------------------------+
800-
| code.code | String | The authorization code. |
801-
+--------------------+----------+---------------------------------------------------------------------+
802-
| code.expiresAt | Date | The expiry time of the authorization code. |
803-
+--------------------+----------+---------------------------------------------------------------------+
804-
| [code.redirectUri] | String | The redirect URI of the authorization code. |
805-
+--------------------+----------+---------------------------------------------------------------------+
806-
| [code.scope] | String | The authorized scope of the authorization code. |
807-
+--------------------+----------+---------------------------------------------------------------------+
808-
| code.client | Object | The client associated with the authorization code. |
809-
+--------------------+----------+---------------------------------------------------------------------+
810-
| code.client.id | String | A unique string identifying the client. |
811-
+--------------------+----------+---------------------------------------------------------------------+
812-
| code.user | Object | The user associated with the authorization code. |
813-
+--------------------+----------+---------------------------------------------------------------------+
795+
+------------------------+----------+---------------------------------------------------------------------+
796+
| Name | Type | Description |
797+
+========================+==========+=====================================================================+
798+
| code | Object | The code to be revoked. |
799+
+------------------------+----------+---------------------------------------------------------------------+
800+
| code.authorizationCode | String | The authorization code. |
801+
+------------------------+----------+---------------------------------------------------------------------+
802+
| code.expiresAt | Date | The expiry time of the authorization code. |
803+
+------------------------+----------+---------------------------------------------------------------------+
804+
| [code.redirectUri] | String | The redirect URI of the authorization code. |
805+
+------------------------+----------+---------------------------------------------------------------------+
806+
| [code.scope] | String | The authorized scope of the authorization code. |
807+
+------------------------+----------+---------------------------------------------------------------------+
808+
| code.client | Object | The client associated with the authorization code. |
809+
+------------------------+----------+---------------------------------------------------------------------+
810+
| code.client.id | String | A unique string identifying the client. |
811+
+------------------------+----------+---------------------------------------------------------------------+
812+
| code.user | Object | The user associated with the authorization code. |
813+
+------------------------+----------+---------------------------------------------------------------------+
814814

815815
**Return value:**
816816

0 commit comments

Comments
 (0)