authlib / authlib/example-oauth2-server

What is the full curl command to get access token with request token?

オープン
#86 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Python
スター
705
フォーク
279
PR マージ指標
30日以内にマージされた PR はありません

説明

Hi,
The sample in this repo is pretty straightforward and clear. Thanks.

One thing is not mentioned in tutorial is getting new access_token with refresh_token as way of renewing an access_token.

I tried below command and the other which had auth tuple and both failed.

```sh
$ curl -XPOST http://127.0.0.1:8000/oauth/token -F grant_type=refresh_token -F refresh_token=NogJYgBFjH3NmTBDHdDYTCUQBQaMXBFZThdjaHtjraEuT9HM
{"error": "invalid_client"}
```

The other test is adding client_id and cilent_secret:
```sh
curl -u ${client_id}:${client_secret} -XPOST http://127.0.0.1:8000/oauth/token -F grant_type=refresh_token -F scope=profile -F refresh_token=${refresh_token}
{"error": "unauthorized_client"}
```

What is the correct curl command to get access token with refresh token?

Thanks

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

リポジトリの OAuth チュートリアルと、issue に示されている /oauth/token リクエストを、refresh_token フローから確認します。サポートされているリクエスト形式を確認し、動作する curl コマンドでチュートリアルを更新します。refresh-token の更新手順と必須パラメーターが明確にドキュメント化されれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
authentication, documentation
issue の種類
ドキュメント
難易度
2/5
見積もり時間
1〜3時間
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
42/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。