Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: fix curl samples #743

Merged
merged 1 commit into from
Jul 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,12 @@ const fetchLogtoApplications = async () => {

```bash
curl --location \
--request GET 'https://your.logto.endpoint/api/applications' \ # Replace with your Logto endpoint
--header 'Authorization: Bearer eyJhbG...2g' # Access Token
--request GET 'https://your.logto.endpoint/api/applications' \
--header 'Authorization: Bearer eyJhbG...2g'
```

Remember to replace the actual values with your own. The value after `Bearer` should be the access token (JWT) you received.

</TabItem>

</Tabs>
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,16 @@ const fetchAccessToken = async () => {

```bash
curl --location \
--request POST 'https://your.logto.endpoint' \ # Replace with your Logto endpoint
--request POST 'https://your.logto.endpoint' \
--header 'Authorization: Basic ${your_auth_string}' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'resource=https://${tenantId}.logto.app/api' \
--data-urlencode 'scope=all'
```

Remember to replace the actual values with your own.

</TabItem>

</Tabs>
Expand Down
Loading