> ## Documentation Index
> Fetch the complete documentation index at: https://developer.energy-hub.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Charger data for user

> Returns general data of a single charger for the user.



## OpenAPI

````yaml get /v1.0.0/users/{userId}/chargers/{chargerId}
openapi: 3.0.1
info:
  description: A service used for chargers
  title: charger-service
  version: 1.0.0
servers:
  - description: Generated server url
    url: https://api.energy-hub.io
security: []
paths:
  /v1.0.0/users/{userId}/chargers/{chargerId}:
    get:
      tags:
        - User Charger Controller
      summary: Charger data for user
      description: Returns general data of a single charger for the user.
      operationId: getChargerByUserIdAndChargerUuid
      parameters:
        - schema:
            type: string
          in: path
          name: userId
          description: User ID
          required: true
        - schema:
            format: uuid
            type: string
          in: path
          name: chargerId
          description: Charger ID
          required: true
      responses:
        '200':
          description: Successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ChargerResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorMessageDto'
              examples:
                UNAUTHORIZED:
                  $ref: '#/components/examples/UNAUTHORIZED'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorMessageDto'
              examples:
                CHARGER_NOT_FOUND:
                  $ref: '#/components/examples/CHARGER_NOT_FOUND'
      security:
        - API_Key: []
components:
  schemas:
    ChargerResponse:
      description: Object of charger response.
      type: object
      required:
        - id
        - isOnline
        - userId
      properties:
        lastUpdated:
          format: date-time
          description: The timestamp of the last update of any field in the charger data.
          type: string
        chargeState:
          $ref: '#/components/schemas/ChargeState'
        locationId:
          format: uuid
          description: Object of the location of the charger.
          type: string
        isOnline:
          description: Indicates if the charger is reachable trough the vendor system.
          type: boolean
          example: true
        id:
          format: uuid
          description: The ID of the charger.
          type: string
        userId:
          description: The ID of the user.
          type: string
          example: 896f9d5a-b618-48a2-98ae-957059bf1bc9
        staticData:
          $ref: '#/components/schemas/StaticData'
    ErrorMessageDto:
      type: object
      required:
        - errorCode
        - id
        - message
      properties:
        errorCode:
          description: The error code
          type: string
          example: EXAMPLE_ERROR_CODE
        id:
          format: uuid
          description: The error identifier
          type: string
          example: 7958818d-64d2-4ede-b12b-4786dd2f348b
        message:
          description: The error message
          type: string
          example: Example error message
    ChargeState:
      description: Object of charge state data of a charger.
      type: object
      required:
        - lastUpdated
      properties:
        chargeRate:
          format: double
          description: The rate of the charge while the charger is charging in kW.
          type: number
          example: 6.512
        lastUpdated:
          format: date-time
          description: The timestamp of the last update of the charge state data.
          type: string
        chargeCurrentMax:
          format: double
          description: The maximum charging current in amperes.
          type: number
          example: 12
        isPlugged:
          description: Indicates if the charger is plugged in.
          type: boolean
          example: true
        activePhases:
          format: double
          description: The number of active phases during the charging process.
          type: number
          example: 1
        chargingState:
          description: The current charging state.
          type: string
          enum:
            - UNPLUGGED
            - CHARGING
            - PREPARING
            - FINISHED
            - STOPPED
            - FAULT
    StaticData:
      description: Object of static data of a charger.
      type: object
      required:
        - lastUpdated
        - model
        - vendor
      properties:
        lastUpdated:
          format: date-time
          description: The timestamp of the last update of the static data.
          type: string
        vendor:
          description: The vendor of the charger.
          type: string
          enum:
            - EASEE
            - GO_E
            - ZAPTEC
        name:
          description: The name of the charger.
          type: string
          example: My charger
        model:
          description: The model of the charger.
          type: string
          example: Wallbox
  examples:
    UNAUTHORIZED:
      value:
        errorCode: UNAUTHORIZED
        id: 9f68c660-b11c-4531-8f0d-b0864117ecbe
        message: Unauthorized
    CHARGER_NOT_FOUND:
      value:
        errorCode: CHARGER_NOT_FOUND
        id: 9f68c660-b11c-4531-8f0d-b0864117ecbe
        message: '[CHARGER] Requested Charger not found'
  securitySchemes:
    API_Key:
      in: header
      name: X-API-KEY
      description: API key used for authorization and authentication.
      type: apiKey

````