JouloDocs

Register a MID charger on an account

Registers a charger on the account and binds it to the account's active connection. Name a MID catalog model with catalog_charger_id, or send the BootNotification pair and Joulo resolves it. An account holds up to 10 active chargers, and serial_number is the idempotency key from the second charger on.

POST
/v1/chargers
AuthorizationBearer <token>

OAuth 2.0 client credentials for a CPO client bound to one partner. Request a token with grant_type client_credentials and send client_id and client_secret in the body, as JSON or form data. The token endpoint does not accept HTTP Basic client authentication. The token lasts one hour and has no refresh token. Omit scope to get every scope your client holds. The /v1 routes refuse user tokens and personal API tokens.

In: header

Scope: cpo:chargers:write

Response Body

curl -X POST "https://api.joulo.nl/functions/v1/api/v1/chargers" \
  -H "Content-Type: application/json" \
  -d '{
    "account_id": "60092124-c768-4191-9c9d-55ef3fc49999",
    "ocpp_vendor": "eNovates",
    "ocpp_model": "0A000T2N0031231",
    "serial_number": "ACE0013982"
  }'
{
  "ok": true,
  "idempotent": true,
  "charger_id": "faa5efff-159a-49fd-8a8f-d55377568a59",
  "catalog": {
    "catalog_charger_id": "45aeec55-e46d-42b6-a990-2b5f65ab05a6",
    "brand": "string",
    "model": "string"
  },
  "mid_eligible": null,
  "account_ere_eligible": true
}
{
  "error": "invalid_json",
  "detail": "string"
}
{
  "error": "Missing or invalid API token"
}
{
  "error": "Insufficient scope",
  "detail": "string",
  "required_scope": "string"
}
{
  "error": "account_not_found",
  "detail": "string"
}
{
  "error": "no_connection",
  "detail": "string"
}
{
  "error": "catalog_unresolved",
  "detail": "string"
}
{
  "error": "Too many requests",
  "retry_after_seconds": 0
}
{
  "error": "catalog_lookup_failed",
  "detail": "string"
}
{
  "error": "string"
}