> For the complete documentation index, see [llms.txt](https://docs.geniesolutions.io/genie-partner-api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.geniesolutions.io/genie-partner-api/tutorials-and-examples/connecting-with-postman/your-account-details.md).

# Your Account Details

### Adding your Account Details

The Partner API requires a JWT access token along with your API\_KEY to authenticate and authorise your access to the API. The token can be retrieved using the built in OAuth2 form within Postman.

#### Add your account details to the OAuth form

To add your Partner API account details to Postman click on the topmost folder in your collection called **Genie FHIRworks.**

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2FQjOdTb5fkVPt7ZMfG2gi%2FScreen%20Shot%202022-07-04%20at%2012.48.05%20pm.png?alt=media\&token=9b651635-83c7-42f8-8e96-8a74402b5a1c)

#### Configure Authorisation

You should now see a page listing Authorisation options. From the **Type** dropdown select **OAuth2**.

Selecting OAuth2 will display a large form which needs a few values added to allow your Postman to retrieve a token for use in the Partner API.

Insert the values below until your form has all required values:

| Field                 | Value                           |
| --------------------- | ------------------------------- |
| Token Name            | COGNITO\_TOKEN                  |
| Grant Type            | Authorization Code (with PKCE)  |
| Callback URL          | <http://localhost>              |
| Auth URL              | {{ AUTH\_URL }}                 |
| Access Token URL      | {{ TOKEN\_URL }}                |
| Client ID             | {{ CLIENT\_ID }}                |
| Client Secret         |                                 |
| Code Challenge Method | SHA-256                         |
| Code Verifier         |                                 |
| Scope                 | openid email profile            |
| State                 |                                 |
| Client Authentication | Send client credentials in body |

#### Retrieve your access token

You should now have all the details in place you need to retrieve an access token.

Click on the **Get Access Token** button to bring up the login dialog

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2F2ToGRwbDaliKRjN97ulv%2FScreen%20Shot%202022-03-02%20at%202.11.36%20pm.png?alt=media\&token=07bc1b88-a6d0-48ad-a81b-9d669f115fa7)

Enter in the **username** and **password** you used to create your Partner API account, click **Login**, and after a short time you should see the screen below. Click proceed.

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2FPCadcESHax795EO4nKne%2FScreen%20Shot%202022-03-02%20at%202.12.53%20pm.png?alt=media\&token=8b416aa8-a756-4a4d-a5ad-448e16a84c70)

When you click Proceed a screen displaying your new token will be visible. On this page you need to scroll down until you see the **id\_token** section. This is the token that we need. Click and drag to select the token being careful to include the whole block of text. Copy the text you have selected and then close the popup window.

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2F0kv5LjJ3Gh9dOgwck9iG%2FScreen%20Shot%202022-03-02%20at%202.13.50%20pm.png?alt=media\&token=c7ce8dcd-a761-4c06-bd94-74b254b7211d)

Next we have to paste the text you have copied in to our token field. To do this click on the input box below the **Available Tokens** drop down that has "**Access Token**" as a placeholder.

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2FbF6I8u1BQzHpBIeGZ4d2%2FScreen%20Shot%202022-03-02%20at%202.14.17%20pm.png?alt=media\&token=c1879a1f-cbba-45a7-8677-3519689836b0)

Select all the text in this window and press your backspace key. Next paste in the token we copied in the previous step.

And lastly click on the **Sync** button next to the input field.

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2FCMSmkSRbANvC6UKjOyVT%2FScreen%20Shot%202022-03-02%20at%202.14.45%20pm.png?alt=media\&token=3bbeb129-636a-4803-934c-3b0c03fb05a1)

And finally click on **Sync Token** in the confirmation window.

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2FuuvOxBz8Om89YyiYlXUz%2FScreen%20Shot%202022-03-02%20at%202.14.56%20pm.png?alt=media\&token=7d5a1762-8d25-4cc7-9227-b1706227c2bb)

The **Sync** button should now be green indicating the value is available to your requests.

![](https://3515076773-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FttPXu7KkPJyal5N8Wjfa%2Fuploads%2FrcrcPgCGvqZifRH8GyZe%2FScreen%20Shot%202022-03-02%20at%202.15.03%20pm.png?alt=media\&token=fc1c49cc-c5e8-4058-bedc-0a54735b916f)
