Lunar Energy Devices API

List, get, and partially update customer devices

Operations 7

GET /api/v2/devices List Devices #
GET /api/v2/devices/{synthId} Get Device #
PATCH /api/v2/devices/{synthId} Partially Update Device #
GET /api/v1/devices List Devices #
POST /api/v1/devices Create Device #
GET /api/v1/devices/{synthId} Get Device #
PUT /api/v1/devices/{synthId} Replace Or Create Device #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/lunar-energy-devices-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

lunar-energy-devices-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Lunar Energy Devices API
  version: v1.0
  contact:
    name: Lunar Energy
    url: https://www.gridshare.com
    email: developers@gridshare.com
  x-logo:
    url: https://www.lunarenergy.com/favicon.ico
  description: 'Operations tagged Devices across 2 of this provider''s published API definitions: gridshare-customer-api-openapi.yml, gridshare-partner-api-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://developer-api.customer.mygridshare.com
  description: Production server
- url: https://developer-api.customer.dev0.mygridshare.com
  description: Development server
- url: https://developer-api.partner.us.mygridshare.com
  description: Production server (US)
- url: https://developer-api.partner.mygridshare.com
  description: Production server (Rest of World)
- url: https://developer-api.partner.dev0.us.mygridshare.com
  description: Development server (US)
- url: https://developer-api.partner.dev0.mygridshare.com
  description: Development server (Rest of World)
security:
- bearerAuth: []
tags:
- name: Devices
  description: List, get, and partially update customer devices
paths:
  /api/v2/devices:
    get:
      operationId: listDevices
      summary: List Devices
      description: List all devices the authenticated customer has access to.
      tags:
      - Devices
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeviceList'
        '400':
          $ref: '#/components/responses/Malformed'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '422':
          $ref: '#/components/responses/Unprocessable'
    servers:
    - url: https://developer-api.customer.mygridshare.com
      description: Production server
    - url: https://developer-api.customer.dev0.mygridshare.com
      description: Development server
  /api/v2/devices/{synthId}:
    parameters:
    - $ref: '#/components/parameters/SynthId'
    get:
      operationId: getDevice
      summary: Get Device
      description: Get a device by ID along with its static properties.
      tags:
      - Devices
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Device'
    patch:
      operationId: patchDevice
      summary: Partially Update Device
      description: Update a device.
      tags:
      - Devices
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Device'
      responses:
        '200':
          description: OK
    servers:
    - url: https://developer-api.customer.mygridshare.com
      description: Production server
    - url: https://developer-api.customer.dev0.mygridshare.com
      description: Development server
  /api/v1/devices:
    get:
      operationId: listDevices
      summary: List Devices
      description: List all devices in the partner fleet.
      tags:
      - Devices
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeviceList'
    post:
      operationId: createDevice
      summary: Create Device
      description: Create a new device.
      tags:
      - Devices
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Device_2'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Device_2'
    servers:
    - url: https://developer-api.partner.us.mygridshare.com
      description: Production server (US)
    - url: https://developer-api.partner.mygridshare.com
      description: Production server (Rest of World)
    - url: https://developer-api.partner.dev0.us.mygridshare.com
      description: Development server (US)
    - url: https://developer-api.partner.dev0.mygridshare.com
      description: Development server (Rest of World)
  /api/v1/devices/{synthId}:
    parameters:
    - $ref: '#/components/parameters/SynthId'
    get:
      operationId: getDevice
      summary: Get Device
      description: Get a device by ID with its static properties.
      tags:
      - Devices
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Device_2'
    put:
      operationId: replaceOrCreateDevice
      summary: Replace Or Create Device
      description: Override an existing device with new properties or create one if it does not yet exist.
      tags:
      - Devices
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Device_2'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Device_2'
    servers:
    - url: https://developer-api.partner.us.mygridshare.com
      description: Production server (US)
    - url: https://developer-api.partner.mygridshare.com
      description: Production server (Rest of World)
    - url: https://developer-api.partner.dev0.us.mygridshare.com
      description: Development server (US)
    - url: https://developer-api.partner.dev0.mygridshare.com
      description: Development server (Rest of World)
components:
  schemas:
    DeviceList:
      type: object
      required:
      - entries
      properties:
        entries:
          type: array
          items:
            $ref: '#/components/schemas/DeviceListItem'
    MalformedInputResponse:
      type: object
      properties:
        message:
          type: string
        code:
          type: string
    Device:
      type: object
      required:
      - synthId
      properties:
        synthId:
          type: string
        kind:
          type: string
          enum:
          - inverter
          - battery_pack
          - PV
          - EV
          - meter
          - load_control_relay
        siteId:
          type: string
        manufacturer:
          type: string
        model:
          type: string
        serialNumber:
          type: string
    DeviceListItem:
      type: object
      required:
      - synthId
      properties:
        synthId:
          type: string
    UnauthorizedResponse:
      type: object
      properties:
        message:
          type: string
        code:
          type: string
    UnprocessableResponse:
      type: object
      properties:
        message:
          type: string
        code:
          type: string
    ForbiddenResponse:
      type: object
      properties:
        message:
          type: string
        code:
          type: string
    Device_2:
      type: object
      required:
      - synthId
      properties:
        synthId:
          type: string
        deviceId:
          type: string
        kind:
          type: string
          enum:
          - inverter
          - battery_pack
          - PV
          - EV
          - meter
          - load_control_relay
        type:
          type: string
        siteId:
          type: string
        manufacturer:
          type: string
        model:
          type: string
        serialNumber:
          type: string
        properties:
          type: object
          additionalProperties: true
  parameters:
    SynthId:
      in: path
      name: synthId
      required: true
      schema:
        type: string
      description: A device ID or a sensor ID from the site topology.
  responses:
    Unauthorized:
      description: 401 Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/UnauthorizedResponse'
    Malformed:
      description: 400 Malformed Input
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/MalformedInputResponse'
    Unprocessable:
      description: 422 Unprocessable
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/UnprocessableResponse'
    Forbidden:
      description: 403 Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ForbiddenResponse'
  securitySchemes:
    bearerAuth:
      type: oauth2
      description: 'OAuth 2.0 Authorization Code flow against the lunar-customer

        Amazon Cognito user pool.

        '
      flows:
        authorizationCode:
          authorizationUrl: https://lunar-customer-prod-us-west-1.auth.us-west-1.amazoncognito.com/oauth2/authorize
          tokenUrl: https://lunar-customer-prod-us-west-1.auth.us-west-1.amazoncognito.com/oauth2/token
          refreshUrl: https://lunar-customer-prod-us-west-1.auth.us-west-1.amazoncognito.com/oauth2/token
          scopes:
            lunar/device.read: Read device metadata and telemetry (excluding plans)
            lunar/device.write: Modify devices including operation mode
            lunar/plan.read: Read existing device plans
            lunar/plan.write: Send plans to a device
x-refined-from:
- gridshare-customer-api-openapi.yml
- gridshare-partner-api-openapi.yml