This is a development version of the documentation. Content may change without notice.
Voke Documentation
ReferenceREST API

Voke E S M ( Admin)

Voke ESM sandbox administration

Disable Voke ESM for an organization

POST
/api/v1/voke-esm/admin/disable

Query Parameters

orgId*string

Response Body

application/json

application/json

application/json

curl -X POST "https://loading/api/v1/voke-esm/admin/disable?orgId=string"
{
  "message": "string"
}
{
  "code": "INVALID_UUID",
  "details": {},
  "error": "Bad Request",
  "message": "Invalid UUID",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

Enable Voke ESM for an organization (generates fresh credentials)

POST
/api/v1/voke-esm/admin/enable

Query Parameters

orgId*string

Response Body

application/json

application/json

application/json

curl -X POST "https://loading/api/v1/voke-esm/admin/enable?orgId=string"
{
  "clientId": "string",
  "clientSecret": "string",
  "esmApiUrl": "string"
}
{
  "code": "INVALID_UUID",
  "details": {},
  "error": "Bad Request",
  "message": "Invalid UUID",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

List all Voke ESM plants across all clients

GET
/api/v1/voke-esm/admin/plants

Response Body

application/json

application/json

curl -X GET "https://loading/api/v1/voke-esm/admin/plants"
{
  "capacityKwh": 0,
  "clientId": "string",
  "configEnabled": true,
  "createdAt": "2019-08-24T14:15:22Z",
  "description": "string",
  "esiState": "string",
  "externalPlantId": "string",
  "fvePeakPowerKwp": 0,
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "name": "string",
  "plantWithLoad": true,
  "timeConfigs": [
    {
      "from": "00:00",
      "pBatMax": 10,
      "pBatMin": -10,
      "socMax": 95,
      "socMin": 20,
      "to": "23:59"
    }
  ],
  "updatedAt": "2019-08-24T14:15:22Z"
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

Create a Voke ESM plant

POST
/api/v1/voke-esm/admin/plants

Request Body

application/json

capacityKwh?number
Default0
clientId*string

Client identifier this plant belongs to

Length1 <= length <= 120
configEnabled?boolean
Defaulttrue
description?|
externalPlantId*string

External plant id (the id the real ESM would expose)

Length1 <= length <= 120
fvePeakPowerKwp?number
Default0
name*string
Length1 <= length <= 255
timeConfigs?array<>
Itemsitems <= 96

Response Body

application/json

application/json

application/json

curl -X POST "https://loading/api/v1/voke-esm/admin/plants" \  -H "Content-Type: application/json" \  -d '{    "clientId": "string",    "externalPlantId": "string",    "name": "string"  }'
{
  "capacityKwh": 0,
  "clientId": "string",
  "configEnabled": true,
  "createdAt": "2019-08-24T14:15:22Z",
  "description": "string",
  "esiState": "string",
  "externalPlantId": "string",
  "fvePeakPowerKwp": 0,
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "name": "string",
  "plantWithLoad": true,
  "timeConfigs": [
    {
      "from": "00:00",
      "pBatMax": 10,
      "pBatMin": -10,
      "socMax": 95,
      "socMin": 20,
      "to": "23:59"
    }
  ],
  "updatedAt": "2019-08-24T14:15:22Z"
}
{
  "code": "VALIDATION_ERROR",
  "details": {},
  "error": "Bad Request",
  "message": "Validation error or unbound clientId",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

Get a single Voke ESM plant by id

GET
/api/v1/voke-esm/admin/plants/{id}

Path Parameters

id*string

Response Body

application/json

application/json

application/json

application/json

curl -X GET "https://loading/api/v1/voke-esm/admin/plants/string"
{
  "capacityKwh": 0,
  "clientId": "string",
  "configEnabled": true,
  "createdAt": "2019-08-24T14:15:22Z",
  "description": "string",
  "esiState": "string",
  "externalPlantId": "string",
  "fvePeakPowerKwp": 0,
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "name": "string",
  "plantWithLoad": true,
  "timeConfigs": [
    {
      "from": "00:00",
      "pBatMax": 10,
      "pBatMin": -10,
      "socMax": 95,
      "socMin": 20,
      "to": "23:59"
    }
  ],
  "updatedAt": "2019-08-24T14:15:22Z"
}
{
  "code": "INVALID_UUID",
  "details": {},
  "error": "Bad Request",
  "message": "Invalid UUID",
  "statusCode": 400
}
{
  "code": "NOT_FOUND",
  "details": {},
  "error": "Not Found",
  "message": "Voke ESM plant not found",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

Update a Voke ESM plant

PATCH
/api/v1/voke-esm/admin/plants/{id}

Path Parameters

id*string

Request Body

application/json

capacityKwh?number
configEnabled?boolean
description?|
fvePeakPowerKwp?number
name?string
Lengthlength <= 255
timeConfigs?array<>
Itemsitems <= 96

Response Body

application/json

application/json

application/json

application/json

curl -X PATCH "https://loading/api/v1/voke-esm/admin/plants/string" \  -H "Content-Type: application/json" \  -d '{}'
{
  "capacityKwh": 0,
  "clientId": "string",
  "configEnabled": true,
  "createdAt": "2019-08-24T14:15:22Z",
  "description": "string",
  "esiState": "string",
  "externalPlantId": "string",
  "fvePeakPowerKwp": 0,
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "name": "string",
  "plantWithLoad": true,
  "timeConfigs": [
    {
      "from": "00:00",
      "pBatMax": 10,
      "pBatMin": -10,
      "socMax": 95,
      "socMin": 20,
      "to": "23:59"
    }
  ],
  "updatedAt": "2019-08-24T14:15:22Z"
}
{
  "code": "INVALID_UUID",
  "details": {},
  "error": "Bad Request",
  "message": "Invalid UUID or validation error",
  "statusCode": 400
}
{
  "code": "NOT_FOUND",
  "details": {},
  "error": "Not Found",
  "message": "Voke ESM plant not found",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

Delete a Voke ESM plant

DELETE
/api/v1/voke-esm/admin/plants/{id}

Path Parameters

id*string

Response Body

application/json

application/json

application/json

application/json

curl -X DELETE "https://loading/api/v1/voke-esm/admin/plants/string"
{
  "message": "string"
}
{
  "code": "INVALID_UUID",
  "details": {},
  "error": "Bad Request",
  "message": "Invalid UUID",
  "statusCode": 400
}
{
  "code": "NOT_FOUND",
  "details": {},
  "error": "Not Found",
  "message": "Voke ESM plant not found",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}

Check Voke ESM status for an organization

GET
/api/v1/voke-esm/admin/status

Query Parameters

orgId*string

Response Body

application/json

application/json

application/json

curl -X GET "https://loading/api/v1/voke-esm/admin/status?orgId=string"
{
  "message": "string"
}
{
  "code": "INVALID_UUID",
  "details": {},
  "error": "Bad Request",
  "message": "Invalid UUID",
  "statusCode": 400
}
{
  "code": "INTERNAL_SERVER_ERROR",
  "details": {},
  "error": "Internal Server Error",
  "message": "Internal server error",
  "statusCode": 400
}