PUT

/v2.0/vehicles/{id}/{make}/charge/schedule_by_location

This endpoint is currently available for FORD and LINCOLN

Permission

control_charge

Request

Path

idrequired
string

The vehicle id of the vehicle you are making a request to.

makerequired
string

The make of the vehicle you are making a request to.

Query

longituderequired
number

The longitude of a charging location from GET Charge Schedule by Location

latituderequired
number

The latitude of a charging location from GET Charge Schedule by Location

Body

chargeOnPluginrequired
boolean

Indicates whether the vehicle should immediately charge when plugged in at the location.

chargeLimitrequired
number

The maximum charge limit for the vehicle at the location as a percent between 0.5 and 1).

chargingSchedulesrequired
object

The weekday and weekend charging schedules for the vehicle at the location.

weekdayrequired
[object] | [empty]

The charging schedule for the vehicle on weekdays (Monday - Friday).

startrequired
string

The exact hour a vehicle should start charging in HH:00 e.g. 17:00.

endrequired
string

The exact hour a vehicle should stop charging in HH:00 e.g. 21:00.

weekendrequired
[object] | [empty]

The charging schedule for the vehicle on weekends (Saturday - Sunday).

startrequired
string

The exact hour a vehicle should start charging in HH:00 e.g. 17:00.

endrequired
string

The exact hour a vehicle should stop charging in HH:00 e.g. 21:00.

curl "https://api.smartcar.com/v2.0/vehicles/{id}/{make}/charge/schedule_by_location?longitude=2.3522&latitude=48.8566" \
    -H "Authorization: Bearer {token}" \
    -X "PUT" \
    -H "Content-Type: application/json" \
    -d '{"chargeOnPlugin": true, "chargeLimit": 0.9, "chargingSchedules": {"weekday": [{"start": "09:00", "end": "17:00"}], "weekend": [{"start": "09:00", "end": "17:00"}]}}'

Response

message
string

If the request is successful, Smartcar will return a message.

status
string

If the request is successful, Smartcar will return success.

{
  "message": "Successfully sent request to vehicle",
  "status": "success"
}