fixed server example docs

This commit is contained in:
Zai Shi 2024-07-24 17:02:05 -07:00 committed by Stan Wohlwend
parent 6beed942e9
commit c9f6642c1f

View File

@ -32,6 +32,9 @@ On the server side, you can extract the access token and refresh token from the
```javascript
const url = 'https://api.stack-auth.com/v1/api/users/me';
const headers = {
'x-stack-access-type': 'server',
'x-stack-project-id': 'generated from the Stack dashboard',
'x-stack-server-secret': 'generated from the Stack dashboard',
'x-stack-access-token': 'access token from headers',
'x-stack-refresh-token': 'refresh token from headers'
};
@ -54,6 +57,9 @@ On the server side, you can extract the access token and refresh token from the
url = 'https://api.stack-auth.com/v1/api/users/me'
headers = {
'x-stack-access-type': 'server',
'x-stack-project-id': 'generated from the Stack dashboard',
'x-stack-server-secret': 'generated from the Stack dashboard',
'x-stack-access-token': 'access token from headers',
'x-stack-refresh-token': 'refresh token from headers'
}