Skip to content

Commit

Permalink
docs: add kwargs to parse_jwt_token() in README
Browse files Browse the repository at this point in the history
  • Loading branch information
hsluoyz authored Jul 27, 2023
1 parent 4954dd7 commit 2d69644
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ The general process is as follows:
```python
token = sdk.get_oauth_token(code=code)
access_token = token.get("access_token")
decoded_msg = sdk.parse_jwt_token(access_token)
decoded_msg = sdk.parse_jwt_token(access_token) # or sdk.parse_jwt_token(access_token, kwargs)
```

`decoded_msg` is the JSON data decoded from the `access_token`, which contains user info and other useful stuff.
Expand All @@ -125,7 +125,7 @@ If your application doesn't have a frontend that redirects users to Casdoor and
```python
token = sdk.get_oauth_token(username=username, password=password)
access_token = token.get("access_token")
decoded_msg = sdk.parse_jwt_token(access_token)
decoded_msg = sdk.parse_jwt_token(access_token) # or sdk.parse_jwt_token(access_token, kwargs)
```

`decoded_msg` is the JSON data decoded from the `access_token`, which contains user info and other useful stuff.
Expand All @@ -138,7 +138,7 @@ It is important to note that the AccessToken obtained in this way differs from o
```python
token = sdk.get_oauth_token()
access_token = token.get("access_token")
decoded_msg = sdk.parse_jwt_token(access_token)
decoded_msg = sdk.parse_jwt_token(access_token) # or sdk.parse_jwt_token(access_token, kwargs)
```

`decoded_msg` is the JSON data decoded from the `access_token`.
`decoded_msg` is the JSON data decoded from the `access_token`.

0 comments on commit 2d69644

Please sign in to comment.