# MeshVI API

API documentation for MeshVI services. Protected routes use application authorization ([APIAuthorize]): a valid Bearer JWT is validated by the API. Calls to the hosted base URL also require an API key in the `apiKey` header, enforced at the API edge. Includes Acord certificate verification and retrieval, client, document (Document Manager v1 list/upload/update/download/delete), driver, policy, vehicle, vehicle and driver coverage assignment, and policy premium report operations for real-time insurance verification and fleet management.

Version: 1.0.0

## Servers

Staging (UAT)
```
https://uat-verified.meshvi.com
```

## Security

### BearerAuth

Type: http
Scheme: bearer
Bearer Format: JWT

### ApiKeyAuth

[object Object]

Type: apiKey
In: header
Name: apiKey

## Download OpenAPI description

 - [MeshVI API](https://docs.meshvi.com/_bundle/apis/meshvi.yaml)

## meshVerified

 - [GET /v1/certificates/clients](https://docs.meshvi.com/apis/meshvi/meshverified/paths/~1v1~1certificates~1clients/get.md): Retrieves the Acord certificate for a client. Provide either client id or DOT number (exactly one).
 - [GET /v1/coverages/clients](https://docs.meshvi.com/apis/meshvi/meshverified/paths/~1v1~1coverages~1clients/get.md): Verifies active certificates of insurance across DOT numbers. Provide exactly one of: dots (array), dot (single), or id (client ID).
 - [GET /v1/coverages/vehicles](https://docs.meshvi.com/apis/meshvi/meshverified/paths/~1v1~1coverages~1vehicles/get.md): Verifies certificate of insurance for a vehicle. Provide either vin or licensePlate (exactly one).
 - [GET /v1/certificates/vehicles](https://docs.meshvi.com/apis/meshvi/meshverified/paths/~1v1~1certificates~1vehicles/get.md): Retrieves the Acord certificate for a vehicle. Provide exactly one of: id, vin, or licensePlate. clientId may be used in some contexts.
## Clients

 - [GET /v1/clients](https://docs.meshvi.com/apis/meshvi/clients/paths/~1v1~1clients/get.md): Paginated search of clients with filtering and sorting. Supports page, limit, sort, and filters (name, dot, agencyId, producerId, parentClientId, deleted, clientTypeId, acordEnabled).
 - [POST /v1/clients](https://docs.meshvi.com/apis/meshvi/clients/paths/~1v1~1clients/post.md): Creates a new client. Required: clientName, agencyId. Name-based fields (state, city, mailingState, mailingCity) are resolved to IDs via master data lookup. If parentClientId is provided, the parent m
 - [GET /v1/clients/{id}](https://docs.meshvi.com/apis/meshvi/clients/paths/~1v1~1clients~1%7Bid%7D/get.md): Retrieves client details by ID.
 - [PUT /v1/clients/{id}](https://docs.meshvi.com/apis/meshvi/clients/paths/~1v1~1clients~1%7Bid%7D/put.md): Updates an existing client. All fields are optional (partial update). If agencyId is provided, the token must be authorized for it. If parentClientId is provided, it must belong to the same agency as
## Documents

 - [GET /v1/documents/clients](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1clients/get.md): Returns document file names and time-limited download URLs (S3 pre-signed) for a client. Requires Document Manager **View** permission scoped to the **client** module. When `dot` is provided, the API
 - [POST /v1/documents/clients](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1clients/post.md): Multipart upload of a file for a client. Requires Document Manager **Create/Edit** scoped to the **client** module. Max request size ~25 MB. Optional `Idempotency-Key` header: duplicate key returns HT
 - [GET /v1/documents/policies](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1policies/get.md): Returns document file names and time-limited download URLs for a policy. Requires Document Manager **View** permission scoped to the **policy** module.
 - [POST /v1/documents/policies](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1policies/post.md): Multipart upload for a policy. Requires Document Manager **Create/Edit** scoped to the **policy** module. Same limits and idempotency behavior as POST /v1/documents/clients.
 - [PUT /v1/documents/{id}/client](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1%7Bid%7D~1client/put.md): Replaces/updates an existing document that belongs to a client (multipart). Requires Document Manager **Create/Edit** for the **client** module. Path `id` is the document ID.
 - [DELETE /v1/documents/{id}/client](https://docs.meshvi.com/apis/meshvi/documents/deleteclientdocument.md): Deletes a document that belongs to a client. Requires Document Manager **Delete** for the **client** module. Path `id` is the document ID. Returns **422** if the document is already deleted.
 - [GET /v1/documents/{id}/client/download](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1%7Bid%7D~1client~1download/get.md): Returns a wrapped payload with `documentId`, `downloadUrl`, and `expiresAtUtc`. Requires Document Manager **View** for the **client** module.
 - [PUT /v1/documents/{id}/policy](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1%7Bid%7D~1policy/put.md): Updates an existing document tied to a policy. Requires Document Manager **Create/Edit** for the **policy** module.
 - [DELETE /v1/documents/{id}/policy](https://docs.meshvi.com/apis/meshvi/documents/deletepolicydocument.md): Deletes a document tied to a policy. Requires Document Manager **Delete** for the **policy** module. Path `id` is the document ID. Returns **422** if the document is already deleted.
 - [GET /v1/documents/{id}/policy/download](https://docs.meshvi.com/apis/meshvi/documents/paths/~1v1~1documents~1%7Bid%7D~1policy~1download/get.md): Same as GET /v1/documents/{id}/client/download but authorization is scoped to the **policy** module.
## Drivers

 - [GET /v1/drivers](https://docs.meshvi.com/apis/meshvi/drivers/paths/~1v1~1drivers/get.md): Paginated search of drivers with filtering and sorting. Supports query parameters for pagination, sorting, and filtering by client, status, license, and search text.
 - [POST /v1/drivers](https://docs.meshvi.com/apis/meshvi/drivers/paths/~1v1~1drivers/post.md): Creates a new driver. Required: clientId, firstName, lastName, driverType. Date fields use MM-dd-yyyy format. Name-based fields (state, city, driverType, dlType) are resolved to IDs via master data lo
 - [POST /v1/drivers/search](https://docs.meshvi.com/apis/meshvi/drivers/paths/~1v1~1drivers~1search/post.md): Paginated driver search using the legacy `CommonPagingFilterRequest` body (pageIndex, pageSize, sortBy, sortOrder, filter). Prefer GET `/v1/drivers` for new integrations; this endpoint remains for bac
 - [GET /v1/drivers/{id}](https://docs.meshvi.com/apis/meshvi/drivers/paths/~1v1~1drivers~1%7Bid%7D/get.md): Retrieves driver details by ID.
 - [PUT /v1/drivers/{id}](https://docs.meshvi.com/apis/meshvi/drivers/paths/~1v1~1drivers~1%7Bid%7D/put.md): Updates an existing driver. Uses the same request body as create. Only provided fields are updated.
 - [POST /v1/drivers/vehicles](https://docs.meshvi.com/apis/meshvi/drivers/associatedrivertovehicle.md): Associates an existing driver with the specified vehicle, or creates a new driver and associates them. If driverId is provided (>0), the driver must exist. If driverId is 0, firstName and lastName are
 - [POST /v1/drivers/coverages](https://docs.meshvi.com/apis/meshvi/drivers/assigndrivercoverage.md): Assigns a driver to an OA or DD policy coverage (sponsored scheduled driver). Requires Driver **Create/Edit**. For active policies, provide `policyAddedDate`; for future policies the server uses the p
 - [PUT /v1/drivers/coverages](https://docs.meshvi.com/apis/meshvi/drivers/updatedrivercoverage.md): Updates an already-assigned driver OA/DD coverage. `coverageStatus`: **1** = response needed (remove), **2** = coverage declined, **7** = sponsored scheduled driver (change policy added date). Status
## Policies

 - [GET /v1/policies](https://docs.meshvi.com/apis/meshvi/policies/paths/~1v1~1policies/get.md): Paginated search of policies. Query params: page, limit, sort, q, policy, clientId, deleted, status, coverageType.
 - [POST /v1/policies](https://docs.meshvi.com/apis/meshvi/policies/paths/~1v1~1policies/post.md): Creates a new policy. Required: clientId, effectiveDate, expirationDate, and either coverageType or fullCoverageTypeName. Name-based fields (insurerName, stateName, producerName, etc.) are resolved to
 - [POST /v1/policies/search](https://docs.meshvi.com/apis/meshvi/policies/paths/~1v1~1policies~1search/post.md): Paginated policy search using the legacy `CommonPagingFilterRequest` body (pageIndex, pageSize, sortBy, sortOrder, filter). Prefer GET `/v1/policies` for new integrations; this endpoint remains for ba
 - [GET /v1/policies/{id}](https://docs.meshvi.com/apis/meshvi/policies/paths/~1v1~1policies~1%7Bid%7D/get.md): Retrieves policy details by ID.
 - [PUT /v1/policies/{id}](https://docs.meshvi.com/apis/meshvi/policies/paths/~1v1~1policies~1%7Bid%7D/put.md): Updates an existing policy. Only properties present in the request body are updated (partial update). Supports the same fields as create. Name-based fields are resolved via master data lookup.
 - [GET /v1/policies/{id}/vehicles](https://docs.meshvi.com/apis/meshvi/policies/paths/~1v1~1policies~1%7Bid%7D~1vehicles/get.md): Retrieves a paginated list of vehicles associated with a policy. Supports optional filters for make, value, and status.
## Vehicles

 - [GET /v1/certificates/vehicles](https://docs.meshvi.com/apis/meshvi/vehicles/paths/~1v1~1certificates~1vehicles/get.md): Retrieves the Acord certificate for a vehicle. Provide exactly one of: id, vin, or licensePlate. clientId may be used in some contexts.
 - [GET /v1/vehicles](https://docs.meshvi.com/apis/meshvi/vehicles/paths/~1v1~1vehicles/get.md): Paginated search of vehicles with filtering and sorting. Supports query parameters for pagination, sorting, and filtering by VIN, unit, make, owner, garaging address, value, and status.
 - [POST /v1/vehicles](https://docs.meshvi.com/apis/meshvi/vehicles/paths/~1v1~1vehicles/post.md): Creates a new vehicle. Required: clientId, unitType/unitTypeName, unit, modelYear, makes/makeCompanyName, serialNumber (VIN, 17 characters). Name-based fields are resolved to IDs via master data looku
 - [GET /v1/vehicles/{id}](https://docs.meshvi.com/apis/meshvi/vehicles/paths/~1v1~1vehicles~1%7Bid%7D/get.md): Retrieves complete vehicle details by ID including driver assignments, coverage types, policy associations, lienholder information, billing details, and audit information.
 - [PUT /v1/vehicles/{id}](https://docs.meshvi.com/apis/meshvi/vehicles/paths/~1v1~1vehicles~1%7Bid%7D/put.md): Updates an existing vehicle. Only provided fields are updated (partial update). Name-based fields (makeCompanyName, unitTypeName, licensePlateStateName) are resolved to IDs via master data lookup.
 - [POST /v1/vehicles/coverages](https://docs.meshvi.com/apis/meshvi/vehicles/assignvehiclecoverage.md): Assigns a vehicle to an existing policy as a scheduled unit coverage. Requires Vehicle **Create/Edit**. For active policies, provide `policyAddedDate`; for future policies the server uses the policy e
 - [PUT /v1/vehicles/coverages](https://docs.meshvi.com/apis/meshvi/vehicles/updatevehiclecoverage.md): Updates an already-assigned scheduled-unit vehicle coverage. `coverageStatus`: **1** = response needed (remove), **2** = coverage declined, **4** = sponsored scheduled unit (change policy added date).
 - [GET /v1/vehicles/lienholders/{id}](https://docs.meshvi.com/apis/meshvi/vehicles/paths/~1v1~1vehicles~1lienholders~1%7Bid%7D/get.md): Retrieves lienholder detail with associated vehicles. Returns lienholder info (lienholderId, lienholderName, phone, address, agency, vehicleTotalCount, vehicleValueTotalCount, powerUnit, nonPowerUnit)
## Reports

 - [GET /v1/reports/{id}/raw-data](https://docs.meshvi.com/apis/meshvi/reports/paths/~1v1~1reports~1%7Bid%7D~1raw-data/get.md): Returns the template mapping payload (fixedData, tableData, premium mapping) for a policy premium report (`Client.PolicyPremiumReport.id`). Uses stored snapshot when available; otherwise computes mapp
