---
updatedAt: 2026-04-16T22:25:09.000Z
agentTools:
  projectIndex: https://devportal.fintensy.com/llms.txt
---

# Get an access_token

## Endpoint

```text
POST https://[idpurl]/connect/token
```

***

## Authentication

Use **Basic Authentication** with your client credentials:

```text
Authorization: Basic base64(client_id:client_secret)
```

***

## Request Parameters (application/x-www-form-urlencoded)

| Parameter   | Value                                 | Description      |
| ----------- | ------------------------------------- | ---------------- |
| grant\_type | client\_credentials                   | OAuth2 flow type |
| scope       | \[scope you received, default=public] | Requested scope  |

***

## cURL Example

```bash
curl -X POST "https://[idpurl]/connect/token" \
  -H "Authorization: Basic BASE64_ENCODED_CLIENTID_SECRET" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "grant_type=client_credentials&scope=public"
```

***

## PowerShell Example

```powershell
$clientId = "your_client_id"
$clientSecret = "your_client_secret"
$pair = "$clientId`:$clientSecret"
$encoded = [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes($pair))

$headers = @{
    Authorization = "Basic $encoded"
}

$body = @{
    grant_type = "client_credentials"
    scope      = "public"
}

$response = Invoke-RestMethod -Method Post `
    -Uri "https://[idpurl]/connect/token" `
    -Headers $headers `
    -Body $body `
    -ContentType "application/x-www-form-urlencoded"

$response
```

***

## Expected Response

```json
{
  "access_token": "eyJhbGciOiJSUzI1NiIs...",
  "expires_in": 3600,
  "token_type": "Bearer",
  "scope": "public"
}
```

***

## Notes

* The `Authorization` header must be **Base64-encoded**
  * Content-Type must be: application/x-www-form-urlencoded

    ***

<br />