> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aiyoti.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Log in

> We recommend creating a dedicated Aiyoti user for each integration, with only the account access and permissions it needs. Use that user's credentials instead of a person's everyday login so the integration's access can be managed independently.

Submit `Email` and `Password`. The response contains `access` and `refresh` values plus user and account information. Keep these values in secure server-side storage and out of public code and logs.

Both `access` and `refresh` tokens are accepted in the `AccessKey` header used by asset endpoints. Use `access` for asset requests and reserve `refresh` for credential renewal.



## OpenAPI

````yaml /openapi/openapi.json post /Users/Login
openapi: 3.1.0
info:
  title: Aiyoti Integration API Basic
  description: Create, retrieve, update, and manage the tracking lifecycle of assets.
  version: 0.0.1
servers:
  - url: https://api.aiyoticloud.com
security: []
tags:
  - name: Users
    description: Log in and refresh credentials.
  - name: Carriers
    description: Look up the carriers available to an account.
  - name: Labels
    description: Look up the labels available for new assets.
  - name: Assets / Shipments
    description: Create, list, retrieve, edit, annotate, and delete assets.
paths:
  /Users/Login:
    post:
      tags:
        - Users
      summary: Log in
      description: >-
        We recommend creating a dedicated Aiyoti user for each integration, with
        only the account access and permissions it needs. Use that user's
        credentials instead of a person's everyday login so the integration's
        access can be managed independently.


        Submit `Email` and `Password`. The response contains `access` and
        `refresh` values plus user and account information. Keep these values in
        secure server-side storage and out of public code and logs.


        Both `access` and `refresh` tokens are accepted in the `AccessKey`
        header used by asset endpoints. Use `access` for asset requests and
        reserve `refresh` for credential renewal.
      operationId: user_login_Users_Login_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UserLogin'
            examples:
              login:
                summary: Log in
                value:
                  Email: user@example.com
                  Password: YOUR_PASSWORD
        required: true
      responses:
        '200':
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LoginResponse'
              example:
                access: YOUR_ACCESS_TOKEN
                refresh: YOUR_REFRESH_TOKEN
                TimeZone: America/Chicago
                DateTimeFormat: '%m/%d/%Y %h:%i:%S %p'
                Metric: 1
                Units: km/h
                UserID: '00000000000000000000000000000001'
                UserRole: Customer Admin
                AccountID: '00000000000000000000000000000002'
                AccountType: End Customer
        '400':
          description: >-
            Request rejected. Check your credentials, account access, and
            request parameters.
        '422':
          description: Request validation failed. Check required fields and value types.
      security: []
components:
  schemas:
    UserLogin:
      properties:
        Email:
          type: string
          description: Email address of the user.
        Password:
          type: string
          description: Password of the user. Keep it out of logs and public code.
      type: object
      required:
        - Email
        - Password
    LoginResponse:
      type: object
      properties:
        access:
          type: string
          description: Access credential returned at login.
        refresh:
          type: string
          description: Refresh credential returned at login.
        TimeZone:
          type: string
          description: Time zone associated with the user.
        DateTimeFormat:
          type: string
          description: Date-time format pattern associated with the user.
        Metric:
          type: integer
          description: Measurement preference indicator.
        Units:
          type: string
          description: Speed unit label.
        UserID:
          type: string
          description: Unique identifier of the user.
        UserRole:
          type: string
          description: Role of the user.
        AccountID:
          type: string
          description: Unique identifier of the account.
        AccountType:
          type: string
          description: Type of the account.
      description: Fields returned by Login.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.