Recipes

Recipes

Dealerware API Authentication

Learn how to authenticate with Dealerware’s API using M2M credentials.

Follow the step-by-step guide to securely access user data and integrate with our system.

In this Recipe

  1. Before You Start
  2. Authenticating Your Application
  3. Validate by Checking Your User

🔐Open Recipe

ShellNodeRuby

xxxxxxxxxx

1

# Get the Auth token

2

AuthResponse=curl POST 'https://dealerware.auth0.com/oauth/token' \

3

  --header 'content-type: application/json' \

4

  --data '{

5

    "client_id": "[Your Client ID]",

6

    "client_secret": "[Your Client Secret]",

7

    "audience": "https://api.dealerware.com",

8

    "grant_type": "client_credentials"

9

  }'

10

11

# Extract the access token from the response

12

ACCESS_TOKEN=$(echo $AuthResponse | grep -o '"access_token":"[^"]*' | grep -o '[^"]*$')

13

14

# Check if the access token was obtained

15

if [ -z "$ACCESS_TOKEN" ]; then

16

  echo "Error: No access token obtained."

17

  exit 1

18

fi

19

20

<<comment

21

Your Authentication request will respond with your access token:

22

{

23

    "access_token": "[Your Access Token]",

24

    "expires_in": 86400,

25

    "token_type": "Bearer"

26

}

27

comment

28

29

30

# Use the access token to make an API request

31

UserResponse=$(curl --request GET 'https://api.dealerware.com/admin/user' \

32

  --header 'Content-Type: application/json' \

33

  --header "Authorization: Bearer $ACCESS_TOKEN")

34

35

# Print the user data response

36

echo $UserResponse

Future Vehicle Availability

Check vehicle availability for a specified fleet or program within a defined date range.

Use this guide to fetch availability data for future scheduling and fleet management.

Dealership Settings

Efficiently manage dealership configurations, including contact information, operating hours, addresses, and other settings.

This guide ensures streamlined dealership management and operational consistency.

Dealership Employee Configuration

Create, activate, and manage employee accounts, assign roles, and retrieve employee details for effective dealership operations.

This guide ensures accurate and efficient management of employee information.

Retrieve Dealership Data

Learn how to retrieve dealership information through Dealerware's API.

This guide helps administrators manage dealership data and select the correct dealer context for subsequent requests.

Vehicle Management

Add or update dealership and vehicle information to maintain accurate inventory records.

This guide ensures streamlined and effective fleet management within the dealership.

Interval-Based Vehicle Availability

Retrieve vehicle availability for a specified fleet or program, organized by specific time intervals within a chosen timeframe.

This guide helps you manage availability checks with defined time slots.

Customer Profile Management

Find, create, or update a customer profile for a dealership location.

This guide helps manage customer records efficiently.

Customer Driver's License

Submit or retrieve driver’s license information for a customer at a dealership.

This guide helps verify and manage customer identification details.

Customer Credit Card Management

Add or retrieve a customer’s credit card details for verification and secure storage.

This guide ensures accurate and secure credit card management.

Customer Insurance Management

Add or retrieve a customer’s insurance information, including carrier, policy number, and expiration details.

This guide ensures accurate insurance data management.

Dealership Settings (Fleet Settings)

Configure and retrieve various fleet settings, including billing, rates, and allowances.

This guide ensures efficient fleet management within the dealership.

Contactless Reservation Management

Efficiently manage customer reservations with contactless interactions, including vehicle assignment, contract messages, and driver contactless details.

This guide ensures a seamless, touch-free experience for both staff and customers.

Contract-Ready Customer Profile

Ensure a customer is ready to rent or borrow a vehicle by updating driver's license and insurance information.

For added security, contact [ partnersupport@dealerware.com] for details on insurance verification.