---
agentTools:
  projectIndex: https://developer-docs.gomotive.com/llms.txt
---

# Create a new asset

**Purpose**:  The asset can be a Reefer, a Lowboy, or even a Auto hauler. Any piece of equipment that is used along with your vehicle is called an asset.  Use this API to create a new asset for your organisation.

> 📘 NOTE
>
> In order to use this API, you must provide the following details in the body of the API:
>
> * Name
> * Type
> * Make
> * Model
> * Year
>
> Here is an article that will help you find the asset details on the Motive Dashboard. [Find asset details](https://helpcenter.gomotive.com/hc/en-us/articles/6190748477853-How-to-find-Make-and-Model-of-an-Asset)

## Add external IDs

To add an external ID to the asset, take the following steps:

1. Add the following request to the request body:

```json Add external ID to the asset
{
  "number":"toyota_32",
  # other attributes for a asset
  ...
  ...
  ...
  # add external id for asset
  "external_ids_attributes":[
    {    
    "id": "9876",    
    "external_id": "987",
    "integration_name": "generic_tms"
}
  ]
}
```

```ruby Ruby (OAuth 2.0)
require 'uri'
require 'net/http'
require 'json'

url = URI('https://api.gomotive.com/v1/assets')

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request['Authorization'] = "Bearer <OAUTH_TOKEN>"
request['Content-Type'] = 'application/json'

params = {
    external_id_attributes: [{external_id: 456, integration_name: 'tmw_tmt'}]
  }
request.body = params.to_json

response = http.request(request)
puts response.read_body
```

<br />

## Response Parameters

### asset

* Type: Object
* Description: Denotes the object that contains the details of the asset that we are creating.

***

### id

* **Type**: Number
* **Description**: The unique identifier assigned to the asset.

### name

* **Type**: String
* **Description**: The name of the asset.

### status

* **Type**: String
* **Description**: The status of the asset (e.g., "active").

### type

* **Type**: String
* **Description**: The type of the asset (e.g., "flatbed").

### custom\_type

* **Type**: String
* **Description**: The custom type of the asset, if any.

### vin

* **Type**: String
* **Description**: The Vehicle Identification Number (VIN) of the asset.

### license\_plate\_state

* **Type**: String
* **Description**: The state of the asset's license plate.

### license\_plate\_number

* **Type**: String
* **Description**: The license plate number of the asset.

### make

* **Type**: String
* **Description**: The manufacturer of the asset.

### model

* **Type**: String
* **Description**: The model of the asset.

### year

* **Type**: String
* **Description**: The year the asset was manufactured.

### axle

* **Type**: String
* **Description**: The axle information of the asset, if any.

### weight\_metric\_units

* **Type**: Boolean
* **Description**: Indicates if the asset's weight is measured in metric units.

### length\_metric\_units

* **Type**: Boolean
* **Description**: Indicates if the asset's length is measured in metric units.

### leased

* **Type**: Boolean
* **Description**: Indicates if the asset is leased.

### notes

* **Type**: String
* **Description**: Additional notes about the asset.

### group\_ids

* **Type**: Array
* **Description**: A list of all the group IDs assigned to the asset.

### length

* **Type**: String
* **Description**: The length of the asset.

### gvwr

* **Type**: String
* **Description**: Gross Vehicle Weight Rating of the asset.

### gawr

* **Type**: String
* **Description**: Gross Axle Weight Rating of the asset.

### asset\_gateway

* **Type**: String
* **Description**: Information about the asset gateway, if any.

### external\_ids

* **Type**: Array
* **Description**: A list of external identifiers associated with the asset.

### integration\_name

* Type: String
* Description: The name of the integration with which the external ID is associated.

### availability\_details

* **Type**: Object
* **Description**: Contains the availability details object. This object denotes the availability of the asset for a dispatch.

### availability\_status

* **Type**: String
* **Description**: Denotes the availability status of the asset. Allowed values are “out\_of\_service” or “in\_service”.

### out\_of\_service\_reason

* **Type**: String
* **Description**: Denotes the reason for the asset being out of service.

### updated\_at

* **Type**: DateTime
* **Description**: Denotes the date and time when the availability status of the asset was updated.

### additional\_note

* **Type**: String
* **Description**: Denotes any comments or notes added for updating the availability of the asset. For example, “This asset is scheduled for maintenance.”

### custom\_driver\_app\_warning\_prompt

* **Type**: String
* **Description**: This denotes the prompt message that drivers see on their driver\_app. This prompt can be used to inform the driver about the status of the asset or communicate any specific instructions. For example, “Asset is under maintenance, do not operate.”

### updated\_by\_user

* **Type**: Object
* **Description**: Object containing the details of the user who updated the availability status of the asset.

### id

* **Type**: Int
* **Description**: The ID of the user who updated the availability status of the asset.

### first\_name

* **Type**: String
* **Description**: First name of the user who updated the status of the asset.

### last\_name

* **Type**: String
* **Description**: Last name of the user who updated the status of the asset.

### user\_name

* **Type**: String
* **Description**: Company username of the person who updated the status.

### email

* **Type**: String
* **Description**: Email address of the user.

### company\_reference\_id

* **Type**: Int
* **Description**: The company ID of the user as per the internal company records.

### status

* **Type**: String
* **Description**: The status of the user who updated the availability of the asset.

### role

* **Type**: String
* **Description**: The role of the user who updated the availability status of the asset.

***

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Motive",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.gomotive.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "in": "header",
        "name": "x-api-key"
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/v1/assets": {
      "post": {
        "summary": "Create a new asset",
        "description": "",
        "operationId": "create-a-new-asset",
        "parameters": [
          {
            "name": "X-Time-Zone",
            "in": "header",
            "description": "Specify the timezone for formatting the timestamps.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-User-Id",
            "in": "header",
            "description": "Specify the ID of the Fleet Admin or the Fleet Manager who is accessing this endpoint.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "name",
                  "type",
                  "make",
                  "model",
                  "year"
                ],
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "Denotes the name of the asset that you are creating."
                  },
                  "type": {
                    "type": "string",
                    "description": "Denotes the type of the asset that you are creating. Allowed values are [\"dry_box\", \"reefer\", \"flatbed\", \"step_deck\", \"tanker\", \"low_boy\", \"intermodal_chassis\", \"auto_hauler\", \"livestock\", \"dump_tipper\", \"curtain_side\", \"stake\", \"construction\", \"other\"]"
                  },
                  "custom_type": {
                    "type": "string",
                    "description": "Specify the custom type of the asset. If not available, mention it as \"Other\"."
                  },
                  "make": {
                    "type": "string",
                    "description": "Denotes make of the asset that you are creating."
                  },
                  "model": {
                    "type": "string",
                    "description": "Denotes the model of the asset that you are creating."
                  },
                  "year": {
                    "type": "string",
                    "description": "Denotes the year of manufacturing of the asset."
                  },
                  "subtype": {
                    "type": "string",
                    "description": "Specify the sub type of the asset. Allowed values are: [\"backhoe\", \"boom_truck\", \"bulldozer\", \"crane\", \"dump_truck\", \"excavator\", \"forklift\", \"front_loader\", \"grader\", \"trencher\", \"other\"]"
                  },
                  "vin": {
                    "type": "string",
                    "description": "Specify the VIN number of the asset."
                  },
                  "length": {
                    "type": "number",
                    "description": "Specify the length of the asset.",
                    "format": "float"
                  },
                  "axle": {
                    "type": "integer",
                    "description": "Provide the axle information of the asset.",
                    "format": "int32"
                  },
                  "gvwr": {
                    "type": "integer",
                    "description": "Gross Vehicle Weight Rating (GVWR) of the asset.",
                    "format": "int32"
                  },
                  "gawr": {
                    "type": "integer",
                    "description": "Gross Axle Weight Rating (GAWR) of the asset.",
                    "format": "int32"
                  },
                  "length_metric_units": {
                    "type": "boolean",
                    "description": "Specify if length is in metric units."
                  },
                  "weight_metric_units": {
                    "type": "boolean",
                    "description": "Specify if the weight is in metric units."
                  },
                  "license_plate_state": {
                    "type": "string",
                    "description": "Mention the state where the license place was installed."
                  },
                  "license_plate_number": {
                    "type": "string",
                    "description": "Mention the number of license plate."
                  },
                  "leased": {
                    "type": "boolean",
                    "description": "Mention if the asset is leased or not."
                  },
                  "notes": {
                    "type": "string",
                    "description": "Specify any notes for the asset."
                  },
                  "asset_gateway_id": {
                    "type": "string",
                    "description": "Mention the ID of the asset gateway with which the asset with linked."
                  },
                  "external_ids_attributes": {
                    "type": "object",
                    "description": "Specify the external Id attributes for the asset.",
                    "required": [
                      "external_id",
                      "integration_name",
                      "external_id_holder_id",
                      "external_id_holder_type"
                    ],
                    "properties": {
                      "external_id": {
                        "type": "string",
                        "description": "Denotes the external ID of the entity."
                      },
                      "integration_name": {
                        "type": "string",
                        "description": "The integration with which the external_id is associated."
                      },
                      "external_id_holder_id": {
                        "type": "integer",
                        "description": "The unique identifier assigned to the entity such as a user, vehicle, asset, or a group. If your entity is a user, then enter the user ID here. If a vehicle, enter the vehicle ID. Similarly for asset (asset ID), and group (group ID).",
                        "format": "int32"
                      },
                      "external_id_holder_type": {
                        "type": "string",
                        "description": "Type of the external ID holder. Allowed values are <ul><li><b>User</b></li><li><b>Vehicle</b></li><li><b>Asset</b></li><li><b>Group</b></ul>"
                      }
                    }
                  },
                  "group_ids": {
                    "type": "array",
                    "description": "Specify the group IDs for the assets.",
                    "items": {
                      "type": "integer",
                      "format": "int32"
                    }
                  },
                  "availability_details": {
                    "type": "object",
                    "properties": {
                      "availability_status": {
                        "type": "string",
                        "description": "Denotes the availability status of the vehicle/asset. Allowed values are <ul><li><b>out_of_service</b></li> or <li><b>in_service</b></li></ul>"
                      },
                      "additional_note": {
                        "type": "string",
                        "description": "Denotes any comments or notes added for updating the availability of the vehicle/asset. For example, “This vehicle/asset is scheduled for maintenance”."
                      },
                      "custom_driver_app_warning_prompt": {
                        "type": "string",
                        "description": "This denotes the prompt message that drivers see on their driver_app. This prompt can be used to inform the driver about the status of the vehicle/asset or communicate any specific instructions. For example, “Vehicle/Asset is under maintenance, do not operate. ”"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Create a new asset": {
                    "value": "{\n  \"assets\": [\n    {\n      \"asset\": {\n        \"id\": 635,\n        \"name\": \"def\",\n        \"status\": \"active\",\n        \"type\": \"low_boy\",\n        \"custom_type\": null,\n        \"vin\": null,\n        \"license_plate_state\": null,\n        \"license_plate_number\": null,\n        \"make\": \"HYUNDAI MOTOR CO LTD\",\n        \"model\": \"ZAKLAD BUDOWY I REMONTOW NACZEP WIE\",\n        \"year\": \"2013\",\n        \"axle\": null,\n        \"weight_metric_units\": false,\n        \"length_metric_units\": false,\n        \"leased\": null,\n        \"notes\": null,\n        \"length\": null,\n        \"gvwr\": null,\n        \"gawr\": null,\n        \"asset_gateway\": {\n          \"id\": 698,\n          \"identifier\": \"ATE-3NG-DDQ\",\n          \"active\": true\n        },\n        \"external_ids\": [],\n        \"availability_details\": {\n          \"availability_status\": \"out_of_service\",\n          \"out_of_service_reason\": \"Asset Maintenance\",\n          \"updated_at\": \"2024-07-31T05:30:53Z\",\n          \"additional_note\": \"This asset sheduled for maintenance\",\n          \"custom_driver_app_warning_prompt\": \"This asset is scheduled for maintenance, please don't operate\",\n          \"updated_by_user\": {\n            \"id\": 123,\n            \"first_name\": \"First\",\n            \"last_name\": \"Last\",\n            \"user_name\": \"demo_dispatcher\",\n            \"email\": \"demo.dispatcher@gmail.com\",\n            \"company_reference_id\": 1234,\n            \"status\": \"active\",\n            \"role\": \"dispatcher\"\n          }\n        }\n      }\n    },\n    {\n      \"asset\": {\n        \"id\": 634,\n        \"name\": \"abc\",\n        \"status\": \"deactivated\",\n        \"type\": \"dry_box\",\n        \"custom_type\": null,\n        \"vin\": null,\n        \"license_plate_state\": null,\n        \"license_plate_number\": null,\n        \"make\": \"AEON MOTOR CO., LTD.\",\n        \"model\": \"ZAKLAD BUDOWY I REMONTOW NACZEP WIE\",\n        \"year\": \"2010\",\n        \"axle\": null,\n        \"weight_metric_units\": false,\n        \"length_metric_units\": false,\n        \"leased\": null,\n        \"notes\": null,\n        \"length\": null,\n        \"gvwr\": null,\n        \"gawr\": null,\n        \"asset_gateway\": null,\n        \"external_ids\": [\n          {\n            \"external_id\": \"123\",\n            \"integration_name\": \"tmw_tmt\"\n          }\n        ],\n        \"availability_details\": {\n          \"availability_status\": \"out_of_service\",\n          \"out_of_service_reason\": \"Asset Maintenance\",\n          \"updated_at\": \"2024-07-31T05:30:53Z\",\n          \"additional_note\": \"This asset sheduled for maintenance\",\n          \"custom_driver_app_warning_prompt\": \"This asset is scheduled for maintenance, please don't operate\",\n          \"updated_by_user\": {\n            \"id\": 123,\n            \"first_name\": \"First\",\n            \"last_name\": \"Last\",\n            \"user_name\": \"demo_dispatcher\",\n            \"email\": \"demo.dispatcher@gmail.com\",\n            \"company_reference_id\": 1234,\n            \"status\": \"active\",\n            \"role\": \"dispatcher\"\n          }\n        }\n      }\n    }\n  ],\n  \"pagination\": {\n    \"per_page\": 25,\n    \"page_no\": 1,\n    \"total\": 2\n  }\n}\n"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "assets": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "asset": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "integer",
                                "example": 635,
                                "default": 0
                              },
                              "name": {
                                "type": "string",
                                "example": "def"
                              },
                              "status": {
                                "type": "string",
                                "example": "active"
                              },
                              "type": {
                                "type": "string",
                                "example": "low_boy"
                              },
                              "custom_type": {},
                              "vin": {},
                              "license_plate_state": {},
                              "license_plate_number": {},
                              "make": {
                                "type": "string",
                                "example": "HYUNDAI MOTOR CO LTD"
                              },
                              "model": {
                                "type": "string",
                                "example": "ZAKLAD BUDOWY I REMONTOW NACZEP WIE"
                              },
                              "year": {
                                "type": "string",
                                "example": "2013"
                              },
                              "axle": {},
                              "weight_metric_units": {
                                "type": "boolean",
                                "example": false,
                                "default": true
                              },
                              "length_metric_units": {
                                "type": "boolean",
                                "example": false,
                                "default": true
                              },
                              "leased": {},
                              "notes": {},
                              "length": {},
                              "gvwr": {},
                              "gawr": {},
                              "asset_gateway": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "integer",
                                    "example": 698,
                                    "default": 0
                                  },
                                  "identifier": {
                                    "type": "string",
                                    "example": "ATE-3NG-DDQ"
                                  },
                                  "active": {
                                    "type": "boolean",
                                    "example": true,
                                    "default": true
                                  }
                                }
                              },
                              "external_ids": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {}
                                }
                              },
                              "availability_details": {
                                "type": "object",
                                "properties": {
                                  "availability_status": {
                                    "type": "string",
                                    "example": "out_of_service"
                                  },
                                  "out_of_service_reason": {
                                    "type": "string",
                                    "example": "Asset Maintenance"
                                  },
                                  "updated_at": {
                                    "type": "string",
                                    "example": "2024-07-31T05:30:53Z"
                                  },
                                  "additional_note": {
                                    "type": "string",
                                    "example": "This asset sheduled for maintenance"
                                  },
                                  "custom_driver_app_warning_prompt": {
                                    "type": "string",
                                    "example": "This asset is scheduled for maintenance, please don't operate"
                                  },
                                  "updated_by_user": {
                                    "type": "object",
                                    "properties": {
                                      "id": {
                                        "type": "integer",
                                        "example": 123,
                                        "default": 0
                                      },
                                      "first_name": {
                                        "type": "string",
                                        "example": "First"
                                      },
                                      "last_name": {
                                        "type": "string",
                                        "example": "Last"
                                      },
                                      "user_name": {
                                        "type": "string",
                                        "example": "demo_dispatcher"
                                      },
                                      "email": {
                                        "type": "string",
                                        "example": "demo.dispatcher@gmail.com"
                                      },
                                      "company_reference_id": {
                                        "type": "integer",
                                        "example": 1234,
                                        "default": 0
                                      },
                                      "status": {
                                        "type": "string",
                                        "example": "active"
                                      },
                                      "role": {
                                        "type": "string",
                                        "example": "dispatcher"
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    },
                    "pagination": {
                      "type": "object",
                      "properties": {
                        "per_page": {
                          "type": "integer",
                          "example": 25,
                          "default": 0
                        },
                        "page_no": {
                          "type": "integer",
                          "example": 1,
                          "default": 0
                        },
                        "total": {
                          "type": "integer",
                          "example": 2,
                          "default": 0
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "403",
            "content": {
              "application/json": {
                "examples": {
                  "Invalid API Key": {
                    "value": "{\n  \"error_message\": \"invalid API key\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error_message": {
                      "type": "string",
                      "example": "invalid API key"
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true,
  "_id": "66acf64a829e88001980fbf2:66b13512b1d4dc004d9179ab"
}
```