|
464 | 464 | <pre class="example nohighlight"><?= htmlspecialchars( |
465 | 465 | 'POST https://example.org/auth |
466 | 466 | Content-type: application/x-www-form-urlencoded |
| 467 | +Accept: application/json |
467 | 468 |
|
468 | 469 | code=xxxxxxxx |
469 | 470 | &client_id=https://app.example.com/ |
|
617 | 618 | <pre class="example nohighlight"><?= htmlspecialchars( |
618 | 619 | 'POST https://example.org/token |
619 | 620 | Content-type: application/x-www-form-urlencoded |
| 621 | +Accept: application/json |
620 | 622 |
|
621 | 623 | grant_type=authorization_code |
622 | 624 | &code=xxxxxxxx |
|
644 | 646 | <pre class="example nohighlight"><?= htmlspecialchars( |
645 | 647 | 'POST https://example.org/auth |
646 | 648 | Content-type: application/x-www-form-urlencoded |
| 649 | +Accept: application/json |
647 | 650 |
|
648 | 651 | code=xxxxxxxx |
649 | 652 | &client_id=https://app.example.com/ |
|
695 | 698 | <p>If an external endpoint needs to verify that an access token is valid, it MUST make a GET request to the token endpoint containing an HTTP <code>Authorization</code> header with the Bearer Token according to [[!RFC6750]]. Note that the request to the endpoint will not contain any user-identifying information, so the external endpoint (e.g. Micropub endpoint) will need to know via out-of-band methods which token endpoint is in use.</p> |
696 | 699 |
|
697 | 700 | <pre class="example nohighlight">GET https://example.org/token |
698 | | -Authorization: Bearer xxxxxxxx</pre> |
| 701 | +Authorization: Bearer xxxxxxxx |
| 702 | +Accept: application/json</pre> |
699 | 703 |
|
700 | 704 | <p>The token endpoint verifies the access token using (how this verification is done is up to the implementation), and returns information about the token:</p> |
701 | 705 |
|
|
734 | 738 |
|
735 | 739 | <pre class="example nohighlight">POST https://example.org/token HTTP/1.1 |
736 | 740 | Content-Type: application/x-www-form-urlencoded |
| 741 | +Accept: application/json |
737 | 742 |
|
738 | 743 | action=revoke |
739 | 744 | &token=xxxxxxxx</pre> |
|
0 commit comments