Primary interface for the AutoSync VVS Express library. Provides a complete API for vehicle visualization including:

  • Vehicle data loading and management
  • Wheel and tire configuration
  • Color customization
  • Suspension height adjustments
  • Image rendering and export

The class can be instantiated multiple times via initVvsExpress function as long as a different element is passed each time.

Hierarchy

  • VvsExpress

Constructors

Methods

  • Gets a copy of the current tire data fetched from the API

    Returns

    Tire data response object

    Throws

    Error if no tire is loaded

    Returns TiresResponse

  • Gets the current vehicle angle availability

    Returns

    VehicleAngleAvailability

    Returns VehicleAngleAvailability

  • Gets all the colors available for the current vehicle checing availability with the vehicle, tires and wheel images

    Returns

    Current set of colors for the vehicle

    Returns undefined | VehicleColor[]

  • Gets a copy of the current vehicle data fetched from the API

    Returns

    Vehicle data response object

    Throws

    Error if no vehicle is loaded

    Returns VehiclesApiResponse

  • Gets the current vehicle suspension height

    Returns

    Current suspension height or null if not available

    Returns null | number

  • Gets the current vehicle suspension heights

    Returns

    Suspension heights or null if not available

    Returns null | number[]

  • Gets a copy of the current wheel data fetched from the API

    Returns

    Wheel data response object

    Throws

    Error if no wheel is loaded

    Returns WheelsResponse

  • Transition to the next available vehicle angle

    Returns void

  • Transition to the previous available vehicle angle

    Returns void

  • Loads a tire by description

    Returns

    Promise resolving to success state

    Parameters

    • tireDesc: string

      Tire description

    Returns Promise<void>

  • Loads a tire by AutoSync tire ID

    Returns

    Promise resolving to success state

    Parameters

    • tireId: any

      AutoSync tire identifier

    Returns Promise<void>

  • Loads a tire by vendor part number

    Returns

    Promise resolving to success state

    Parameters

    • tirePn: string

      Tire part number

    Returns Promise<void>

  • Loads and processes tire data using the provided TiresResponse.

    Returns

    A promise that resolves to an array of void upon successful processing.

    Parameters

    • tireData: TiresResponse

      The response object containing tire-related data.

    Returns Promise<void[]>

  • Loads a vehicle by ACES vehicle ID Note: ACES IDs don't uniquely identify AutoSync vehicles

    Parameters

    • acesVehicleId: any

      ACES vehicle identifier

    • options: any = {}

      Additional configuration options

    Returns Promise<void>

  • Loads a vehicle by description Note: For ambiguous queries, first result is selected

    Parameters

    • vehicleDesc: string

      Vehicle description (e.g. "2022 Ford Mustang GT")

    • options: any = {}

      Additional configuration options

    Returns Promise<void>

  • Loads a vehicle by DT vehicle trim ID

    Parameters

    • dtTrimId: any

      DT trim identifier

    • options: any = {}

      Additional configuration options

    Returns Promise<void>

  • Loads a vehicle by AutoSync vehicle ID

    Example

    vvse.loadVehicleById(5853, { colorId: 130669, suspension: true });
    

    Parameters

    • vehicleId: any

      AutoSync vehicle identifier

    • options: any = {}

      Additional options (colorId, suspension)

    Returns Promise<void>

  • Loads a vehicle receiving an Autosync vehicle Object

    Example

    vvse.loadVehicleData({ ... });
    

    Parameters

    • data: VehiclesApiResponse

      AutoSync vehicle Object

    Returns Promise<void[]>

  • Loads a wheel by description

    Returns

    Promise resolving to success state

    Parameters

    • wheelDesc: string

      Wheel description

    Returns Promise<void>

  • Loads a wheel by DT article number

    Returns

    Promise resolving to success state

    Parameters

    • dtArticleNumber: any

      DT article identifier

    Returns Promise<void>

  • Loads a wheel by AutoSync wheel ID

    Returns

    Promise resolving to success state

    Parameters

    • wheelId: any

      AutoSync wheel identifier

    Returns Promise<void>

  • Loads a wheel by vendor part number

    Returns

    Promise resolving to success state

    Parameters

    • wheelPn: string

      Wheel part number

    Returns Promise<void>

  • Loads and processes wheel data using the provided WheelsResponse.

    Returns

    A promise that resolves to an array of void upon successful processing.

    Parameters

    • wheelData: WheelsResponse

      The response object containing wheel-related data.

    Returns Promise<void[]>

  • Sets callback for vehicle color change events

    Parameters

    • callback: AppCallback

      Function to call when color changes

    Returns void

  • Sets the default tire. The selected tire will be applied to the vehicle and will bypass the automatic evaluation used to select a default tire.

    Parameters

    • name: undefined | "street" | "street_wide" | "offroad" | "offroad_wide" = undefined

      The default tire name. Valid options are: 'street', 'street_wide', 'offroad', 'offroad_wide'.

    Returns Promise<void[]>

  • Sets the container height

    Parameters

    • height: string

      Any valid CSS height value

    Returns void

  • Sets the Tire diameter for the current tire image The new diameter will be applied to the current tire image scaling it to the new size Tire Diameter and Width will be affected by the new value If tire diameter is set, then the tire width will be set to the default value

    Parameters

    • diameter: undefined | number = undefined

      Tire diameter to set on inches

    Returns Promise<void[]>

  • Sets the Tire diameter rear for the current tire image The new diameter will be applied to the current tire image scaling it to the new size Tire Diameter and Width will be affected by the new value If tire diameter is set, then the tire width will be set to the default value

    Parameters

    • diameter: undefined | number = undefined

      Tire diameter to set on inches

    Returns Promise<void[]>

  • Sets the vehicle angle view

    Parameters

    • angle: VehicleAngle

      Any valid VehicleAngle value

    Returns void

  • Sets the vehicle color by ID

    Throws

    Error if color ID is invalid

    Parameters

    • colorId: any

      ID of the color to apply

    Returns void

  • Sets the vehicle suspension height Suspension is limited to the range configured on AutoSync admin portal. For more information contact with your AutoSync representative.

    Parameters

    • height: number

      Suspension height level to set

    Returns Promise<void>

  • Sets the Wheel diameter for the current wheel image The new Rim Diameter will be applied to the current wheel image scaling it to the new size

    Parameters

    • diameter: undefined | number = undefined

      Wheel diameter to set on inches

    Returns Promise<void[]>

  • Sets the Wheel diameter rear for the current wheel image The new Rim Diameter will be applied to the current wheel image scaling it to the new size

    Parameters

    • diameter: undefined | number = undefined

      Wheel diameter to set on inches

    Returns Promise<void[]>

  • Sets the Wheel offset for the current tire and wheel package The new offset wil be applied to the current package, moving it to the negative offsets to the left or positive offset to the right

    Parameters

    • offset: undefined | number = undefined

      Wheel offset to set in mm

    Returns Promise<void[]>

  • Sets the Wheel offset for the current tire and wheel rear package The new offset wil be applied to the current package, moving it to the negative offsets to the left or positive offset to the right

    Parameters

    • offset: undefined | number = undefined

      Wheel offset to set in mm

    Returns Promise<void[]>

  • Gets a URL representation of the current visualization

    Returns

    Data URL containing the image

    Returns string

Generated using TypeDoc