.. _everest_api_session_cost_consumer_API: ############################ session\_cost\_consumer\_API ############################ .. container:: everest-api overview .. raw:: html
version 1.1.0AsyncAPI 3.0.0 content type application/jsonlicense Apache-2.0EVerestSessionCost
.. container:: lead EVerest API definition for session cost consumer API for EVerest API clients that consume session cost and tariff information from the ``session_cost`` interface. See the Integrate Tariff and Cost how-to guide for OCPP-specific configuration and message flow details. .. raw:: html

Specification: session_cost_consumer_API.yaml · pionix:de:everest:session_cost_consumer_API

send the client publishes, EVerest consumes (4) receive EVerest publishes, the client consumes (7)
Servers ======= .. container:: everest-api .. raw:: html

default mqtt

default local MQTT

Host
localhost:1883
Topic prefix
everest_api/1/session_cost_consumer/{module_id}
{module_id}

The ID of the module as defined in the EVerest config file.

Operations ========== .. container:: everest-api .. raw:: html
Client to EVerest ----------------- .. _everest_api_session_cost_consumer_API_op_send_request_get_default_price: send\_request\_get\_default\_price ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op send .. raw:: html
send Request current Default Price
Topic
everest_api/1/session_cost_consumer/{module_id}/m2e/default_price/get
Reply
Sent to $message.header#/replyTo as receive_reply_get_default_price.
Request the most recently published (latched) Default Price. The reply will be sent to the replyTo address specified in the message headers. If no latched value is available yet, a null payload will be sent. .. raw:: html
Message Request current Default Price application/json

Message send_request_get_default_price

Request the most recently published (latched) Default Price.

Payload

object
  • headersobject
    • replyTostring

      Address to send the response to. Omit it to discard the response. An invalid address, see the EVerest API explanation, rejects the request.

      min length 1

Example

Example 1
{
        "headers": {
          "replyTo": "everest_api/1/{interface_type}/{module_id}/e2m/{operation_name}/{uuid}"
        }
      }
.. _everest_api_session_cost_consumer_API_op_send_request_get_tariff_message: send\_request\_get\_tariff\_message ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op send .. raw:: html
send Request current Tariff Message
Topic
everest_api/1/session_cost_consumer/{module_id}/m2e/tariff_message/get
Reply
Sent to $message.header#/replyTo as receive_reply_get_tariff_message.
Request the most recently published (latched) Tariff Message. The reply will be sent to the replyTo address specified in the message headers. If no latched value is available yet, a null payload will be sent. .. raw:: html
Message Request current Tariff Message application/json

Message send_request_get_tariff_message

Request the most recently published (latched) Tariff Message.

Payload

object
  • headersobject
    • replyTostring

      Address to send the response to. Omit it to discard the response. An invalid address, see the EVerest API explanation, rejects the request.

      min length 1

Example

Example 1
{
        "headers": {
          "replyTo": "everest_api/1/{interface_type}/{module_id}/e2m/{operation_name}/{uuid}"
        }
      }
.. _everest_api_session_cost_consumer_API_op_send_request_get_session_cost: send\_request\_get\_session\_cost ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op send .. raw:: html
send Request current Session Cost
Topic
everest_api/1/session_cost_consumer/{module_id}/m2e/session_cost/get
Reply
Sent to $message.header#/replyTo as receive_reply_get_session_cost.
Request the most recently published (latched) Session Cost. The reply will be sent to the replyTo address specified in the message headers. If no latched value is available yet, a null payload will be sent. .. raw:: html
Message Request current Session Cost application/json

Message send_request_get_session_cost

Request the most recently published (latched) Session Cost.

Payload

object
  • headersobject
    • replyTostring

      Address to send the response to. Omit it to discard the response. An invalid address, see the EVerest API explanation, rejects the request.

      min length 1

Example

Example 1
{
        "headers": {
          "replyTo": "everest_api/1/{interface_type}/{module_id}/e2m/{operation_name}/{uuid}"
        }
      }
.. _everest_api_session_cost_consumer_API_op_send_communication_check: send\_communication\_check ~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op send .. raw:: html
send Send communication check
Topic
everest_api/1/session_cost_consumer/{module_id}/m2e/communication_check
.. raw:: html
Message Send communication check application/json

Message send_communication_check

Signal to EVerest that communication is good or check shall be stopped

Payload

Send true at least every cfg_communication_check_to_s seconds to signal that the client is alive, otherwise EVerest raises a CommunicationFault, which the next message clears. Send false to stop the check until the module restarts.

Example

CommunicationCheck
true
EVerest to client ----------------- .. _everest_api_session_cost_consumer_API_op_receive_default_price: receive\_default\_price ~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Receive default price
Topic
everest_api/1/session_cost_consumer/{module_id}/e2m/default_price
Published once on startup and again whenever the applicable default price changes (e.g. after a connectivity state change or a configuration update). Contains human-readable price text in one or more languages. Absent if no default price is configured. .. raw:: html
Message Receive default price application/json

Message receive_default_price

Currently applicable default pricing text for this charger

Payload

object DefaultPrice

The currently applicable default pricing text for this charger, independent of any active session. Contains human-readable text only — no computed cost amounts are included. Published once on startup and again whenever the applicable price changes (e.g. after a connectivity state change or a configuration update).

Definition of DefaultPrice

Example

Minimal payload generated from the schema generated
{
        "messages": [
          {
            "content": "string"
          }
        ]
      }
.. _everest_api_session_cost_consumer_API_op_receive_tariff_message: receive\_tariff\_message ~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Receive tariff message
Topic
everest_api/1/session_cost_consumer/{module_id}/e2m/tariff_message
Published at authorization time and whenever the CSMS sends updated pricing during a session. Contains human-readable price text in one or more languages. .. raw:: html
Message Receive tariff message application/json

Message receive_tariff_message

Tariff and pricing information for a charging session

Payload

object TariffMessage ↗

Message containing cost information

Definition of TariffMessage

Example

Minimal payload generated from the schema generated
{
        "messages": [
          {
            "content": "string"
          }
        ]
      }
.. _everest_api_session_cost_consumer_API_op_receive_session_cost: receive\_session\_cost ~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Receive session cost
Topic
everest_api/1/session_cost_consumer/{module_id}/e2m/session_cost
Published periodically during a session and once when it ends. Contains session cost broken down into chunks, current and upcoming pricing, and optional display messages. .. raw:: html
Message Receive session cost application/json

Message receive_session_cost

Running or final cost of a charging session

Payload

object SessionCost ↗

Session cost object containing the total cost of the session and a list of chunks

Definition of SessionCost

Example

Minimal payload generated from the schema generated
{
        "session_id": "string",
        "currency": {
          "code": "AED",
          "decimals": 0
        },
        "status": "Running"
      }
.. _everest_api_session_cost_consumer_API_op_receive_reply_get_default_price: receive\_reply\_get\_default\_price ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Reply to get Default Price request
Topic
Dynamic: the replyTo address from the request's headers. Answers send_request_get_default_price.
.. raw:: html
Message Reply to get Default Price request application/json

Message receive_reply_get_default_price

The most recently published Default Price.

Payload

oneOf

Exactly one of:

  • #1object DefaultPrice

    The currently applicable default pricing text for this charger, independent of any active session. Contains human-readable text only — no computed cost amounts are included. Published once on startup and again whenever the applicable price changes (e.g. after a connectivity state change or a configuration update).

    Definition of DefaultPrice

  • #2null

Example

Minimal payload generated from the schema generated
{
        "messages": [
          {
            "content": "string"
          }
        ]
      }
.. _everest_api_session_cost_consumer_API_op_receive_reply_get_tariff_message: receive\_reply\_get\_tariff\_message ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Reply to get Tariff Message request
Topic
Dynamic: the replyTo address from the request's headers. Answers send_request_get_tariff_message.
.. raw:: html
Message Reply to get Tariff Message request application/json

Message receive_reply_get_tariff_message

The most recently published Tariff Message.

Payload

oneOf

Exactly one of:

Example

Minimal payload generated from the schema generated
{
        "messages": [
          {
            "content": "string"
          }
        ]
      }
.. _everest_api_session_cost_consumer_API_op_receive_reply_get_session_cost: receive\_reply\_get\_session\_cost ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Reply to get Session Cost request
Topic
Dynamic: the replyTo address from the request's headers. Answers send_request_get_session_cost.
.. raw:: html
Message Reply to get Session Cost request application/json

Message receive_reply_get_session_cost

The most recently published Session Cost.

Payload

oneOf

Exactly one of:

Example

Minimal payload generated from the schema generated
{
        "session_id": "string",
        "currency": {
          "code": "AED",
          "decimals": 0
        },
        "status": "Running"
      }
.. _everest_api_session_cost_consumer_API_op_receive_heartbeat: receive\_heartbeat ~~~~~~~~~~~~~~~~~~ .. container:: everest-api op receive .. raw:: html
receive Receive heartbeat
Topic
everest_api/1/session_cost_consumer/{module_id}/e2m/heartbeat
.. raw:: html
Message Receive heartbeat application/json

Message receive_heartbeat

Heartbeat produced by EVerest as configured via cfg_heartbeat_interval_ms in the EVerest configuration

Payload

integer HeartBeatId

64bit unsigned integer. The id of every heartbeat increases by 1 and overflows when the maximum representable value is reached

Example

Heartbeat
42
Messages ======== .. container:: everest-api .. raw:: html
MessageSummaryUsed by
receive_default_price
Receive default price

Currently applicable default pricing text for this charger

receive_default_price
receive_tariff_message
Receive tariff message

Tariff and pricing information for a charging session

receive_tariff_message
receive_session_cost
Receive session cost

Running or final cost of a charging session

receive_session_cost
send_request_get_default_price
Request current Default Price

Request the most recently published (latched) Default Price.

send_request_get_default_price
receive_reply_get_default_price
Reply to get Default Price request

The most recently published Default Price.

receive_reply_get_default_price
send_request_get_tariff_message
Request current Tariff Message

Request the most recently published (latched) Tariff Message.

send_request_get_tariff_message
receive_reply_get_tariff_message
Reply to get Tariff Message request

The most recently published Tariff Message.

receive_reply_get_tariff_message
send_request_get_session_cost
Request current Session Cost

Request the most recently published (latched) Session Cost.

send_request_get_session_cost
receive_reply_get_session_cost
Reply to get Session Cost request

The most recently published Session Cost.

receive_reply_get_session_cost
receive_heartbeat
Receive heartbeat

Heartbeat produced by EVerest as configured via cfg_heartbeat_interval_ms in the EVerest configuration

receive_heartbeat
send_communication_check
Send communication check

Signal to EVerest that communication is good or check shall be stopped

send_communication_check
Schemas ======= .. container:: everest-api .. raw:: html
DefaultPrice object
object

The currently applicable default pricing text for this charger, independent of any active session. Contains human-readable text only — no computed cost amounts are included. Published once on startup and again whenever the applicable price changes (e.g. after a connectivity state change or a configuration update).

Additional properties forbidden.

CommunicationCheck boolean
boolean

Send true at least every cfg_communication_check_to_s seconds to signal that the client is alive, otherwise EVerest raises a CommunicationFault, which the next message clears. Send false to stop the check until the module restarts.

HeartBeatId integer
integer

64bit unsigned integer. The id of every heartbeat increases by 1 and overflows when the maximum representable value is reached

Schemas from other APIs ----------------------- .. container:: everest-api .. raw:: html
CertificateHashDataInfo object defined in auth_consumer_API.yaml ↗
object

Contains the certificate information

Additional properties allowed.

CustomIdToken object defined in auth_consumer_API.yaml ↗
object

Type for a custom id token with a free-form type

Additional properties allowed.

IdToken object defined in auth_consumer_API.yaml ↗
object

Type for an id token

Additional properties allowed.

ProvidedIdToken object defined in auth_consumer_API.yaml ↗
object

Type for IdToken provided by auth token providers. Contains additional information about the IdToken like the source and purpose

Additional properties allowed.

MessageContent object defined in display_message_API.yaml ↗
object

Contains message details

Additional properties allowed.

ChargingPriceComponent object defined in session_cost_API.yaml ↗
object

Charging price for a category

Additional properties allowed.

Currency object defined in session_cost_API.yaml ↗
object

Currency object containing the currency code and the accuracy of the minor unit according to ISO 4217.

Additional properties allowed.

IdlePrice object defined in session_cost_API.yaml ↗
object

Price components when idle

Additional properties allowed.

MoneyAmount object defined in session_cost_API.yaml ↗
object

'Money amount is expressed as an amount of minor units of the currency. Example price of 1.23 EUR is expressed as { value: 123 }'

Additional properties allowed.

NextPeriodPrice object defined in session_cost_API.yaml ↗
object

Pricing for the next period

Additional properties allowed.

Price object defined in session_cost_API.yaml ↗
object

Price object containing the currency and the value of money.

Additional properties allowed.

SessionCost object defined in session_cost_API.yaml ↗
object

Session cost object containing the total cost of the session and a list of chunks

Additional properties allowed.

SessionCostChunk object defined in session_cost_API.yaml ↗
object

A chunk of the session cost. The total cost of the session is the sum of all chunks.

Additional properties allowed.

TariffMessage object defined in session_cost_API.yaml ↗
object

Message containing cost information

Additional properties allowed.