Skip to main content

How to Get Your Samsara API Key

Create an API token in Samsara named Easy Truck Shop, keep the Read scopes Samsara picks, tick Write Webhooks, and copy the key.

Written by Vladimir

In short: in Samsara go to Settings → API Tokens → + Add an API Token. Name it Easy Truck Shop, leave the Read scopes Samsara picks, tick Write Webhooks, click Save and copy the key.

All of this happens in Samsara, not in Easy Truck Shop. You need to be a Samsara admin. If you're not, ask whoever manages your Samsara account.

Step 1: Open API Tokens in Samsara

  1. Log in to Samsara and click the Settings gear at the bottom left.

  2. Scroll the left menu down to Developer and click API Tokens.

  3. Click + Add an API Token.

In the picture below: 1 = Settings gear. 2 = API Tokens. 3 = Add an API Token.

Samsara API Tokens page with the Settings gear at the bottom left, API Tokens under Developer in the left menu, and the Add an API Token button at the top right

Step 2: Name it Easy Truck Shop

In Name, type Easy Truck Shop (1). This makes it clear later which token belongs to Easy Truck Shop, so nobody deletes it by mistake.

Samsara Add API Token window with Easy Truck Shop typed in the Name box

Step 3: Tick Write Webhooks

  1. Under Scopes, Samsara already ticks the Read scopes for you. Leave them as they are.

  2. Scroll down to Setup & Administration, open it (1) and tick Write Webhooks (2). It now says 7 Read, 1 Write Selected.

  3. Scroll to the bottom and click Save.

Setup and Administration scopes in Samsara showing 7 Read, 1 Write Selected with Write Webhooks ticked

Don't skip Write Webhooks. It's the only box you tick yourself. Without it the token still saves, but the connection won't work.

Step 4: Copy the key

Click Copy To Clipboard (1). Samsara shows the key only once, so paste it into Easy Truck Shop right away.

New Easy Truck Shop API token in Samsara with the Copy To Clipboard button

Next: paste it in Easy Truck Shop

In Easy Truck Shop go to Settings → Integrations → Samsara → + Add Connection, paste the key and click Save. Then add the companies (fleets) you want to sync. The full steps are in How to Connect Samsara.

Quick answers

  • "Where do I get the Samsara API key?" In Samsara: Settings → API Tokens → + Add an API Token.

  • "Which scopes do I need?" Keep the Read scopes Samsara ticks for you, and tick Write Webhooks under Setup & Administration.

  • "Can I use a read-only token?" No. Write Webhooks is required.

  • "What should I name the token?" Easy Truck Shop.

  • "I closed the window and lost the key." Samsara won't show it again. Create a new token the same way and use that one.

  • "I have more than one shop. Do I need a new key for each?" No. You can paste the same key into each shop.

  • "Who can create the token?" A Samsara admin.

Related articles

Did this answer your question?