Authentication
Authentication is how you prove your identity to the eCourtDate API — it's how the system knows which agency you represent and that you're authorized to access its data. Without authentication, the API would have no way to verify who is making a request.
eCourtDate uses the OAuth2 Client Credentials flow for API authentication. This grants your application a Bearer token — think of it as a temporary password that the API gives you after you prove who you are with your Client ID and Client Secret. You include this token with every request, and it expires after a set period. When it expires, simply request a new one using the same credentials.
Obtaining API Credentials
- Log in to the eCourtDate Console.
- Navigate to APIs.
- Create or locate your API client to retrieve your
client_idandclient_secret.
Requesting an Access Token
Exchange your credentials for an access token:
curl -X POST https://staging.api.ecourtdate.com/oauth/token \
-H "Content-Type: application/json" \
-d '{
"client_id": "{client_id}",
"client_secret": "{client_secret}",
"grant_type": "client_credentials"
}'
Response (201)
{
"access_token": "{access_token}",
"token_type": "Bearer"
}
Using the Token
Include the access token in the Authorization header of every API request:
Authorization: Bearer {access_token}
Multi-Agency Access
If your API client has access to multiple agencies, specify which agency to operate under by adding the agency_reference query parameter to your requests:
GET /v1/clients?agency_reference=demo
Verifying Access
To confirm your token is valid and check which agency you are connected to, call:
GET /v1/settings
A successful response indicates your token is active and properly scoped.