---
title: "List trailer assignments for all trailers"
method: GET
path: "/v1/fleet/trailers/assignments"
tags: ["Trailer Assignments"]
---

# List trailer assignments for all trailers

`GET /v1/fleet/trailers/assignments`

## Request

- Base URL: `https://api.samsara.com`
- URL: `https://api.samsara.com/v1/fleet/trailers/assignments`
- Auth: HTTP bearer

> 🚧 This endpoint is still on our legacy API.

Fetch trailer assignment data for all trailers in your organization. 

 <b>Rate limit:</b> 25 requests/sec (learn more about rate limits <a href="https://developers.samsara.com/docs/rate-limits" target="_blank">here</a>). 

 **Submit Feedback**: Likes, dislikes, and API feature requests should be filed as feedback in our <a href="https://forms.gle/zkD4NCH7HjKb7mm69" target="_blank">API feedback form</a>. If you encountered an issue or noticed inaccuracies in the API documentation, please <a href="https://www.samsara.com/help" target="_blank">submit a case</a> to our support team.

To use this endpoint, select **Read Assignments** under the Assignments category when creating or editing an API token. <a href="https://developers.samsara.com/docs/authentication#scopes-for-api-tokens" target="_blank">Learn More.</a>

## Query parameters

- `startMs` integer
- `endMs` integer
- `limit` number
- `startingAfter` string
- `endingBefore` string

## Response `200`

Returns trailer assignment data for all trailers in your organization

- InlineResponse2007
  - `pagination` V1Pagination
    - `endCursor` string, required: Cursor identifier representing the last element in the response. This value should be used in conjunction with a subsequent request's 'startingAfter' query parameter.
    - `hasNextPage` boolean, required: True if there are more pages of results after this response.
    - `hasPrevPage` boolean, required: True if there are more pages of results before this response.
    - `startCursor` string, required: Cursor identifier representing the first element in the response. This value should be used in conjunction with a subsequent request's 'ending_before' query parameter.
  - `trailers` V1TrailerAssignmentsResponse[]
    - `id` integer, required: ID of the trailer
    - `name` string, string, required: Assignment trailer name (given when creating trailer via the trailer portal)
    - `trailerAssignments` V1TrailerAssignmentResponse[]
      - `driverId` integer: The ID of the driver associated with this trailer.
      - `endMs` integer: The time at which the driver ended the assignment. If the assignment is current, this value will be omitted.
      - `startMs` integer: The time at which the driver started the assignment

## Other responses

- `default`: Unexpected error.

---

[API](https://skmtc.dev/samsara/apis/samsara-api.md) - [All operations](https://skmtc.dev/samsara/apis/samsara-api/llms.txt) - [OpenAPI document](https://skmtc.dev/samsara/apis/samsara-api/revisions/a9e35d4999be?raw)
