Authentication
Authenticate with an API token and tell dealerMe which organization a request is for.
The dealerMe API uses API tokens. Send yours as a bearer token on every request.
Create an API token
- Sign in to app.dealerme.com.
- Open your profile menu and select API Tokens.
- Name the token and create it. Copy it right away, because it's only shown once.
Treat tokens like passwords. Keep them on your server, never in browser code or a public repository. If a token leaks, delete it on the same page and create a new one.
Authorization: Bearer YOUR_API_TOKEN
Choose the organization
A token can have access to more than one organization, so every request also says which one it's for.
| Header | Value |
|---|---|
X-DealerMe-Organization-Id | Your dealerMe organization ID. |
A request without this header is rejected, and the token's user must be a member of the organization.
DEALERME_TOKEN="your API token"
DEALERME_ORG_ID="your organization id"
curl "https://api.dealerme.com/v1/consent-management/email/consent?contact_value=jane@example.com" \
-H "Authorization: Bearer $DEALERME_TOKEN" \
-H "X-DealerMe-Organization-Id: $DEALERME_ORG_ID" \
-H 'Accept: application/json'
