Application Programming Interface (API)

Software Development Kits (SDKs)

To assist with the implementation of the Share My Data platform, PG&E developed SDKs in both JavasScript and Python. These SDKs provide samples to help guide you through the process of development, but are not intended to provide functioning code.

Download Supported APIs (PDF, 217 KB)
The Supported APIs document shows the APIs supported by PG&E’s implementation of Share My Data, as well as the PG&E specific API URL.


Download Supported Function Blocks (PDF, 108 KB)
The Supported Function Blocks document lists which ESPI standard function blocks PG&E’s Share My Data implementation supports.


Download Supported Relational Data Model (PG&E Implementation of ESPI) (PDF, 278 KB)
In conjunction with the Supported Data Elements document, the Supported Relational Data Model illustrates how the relationship between the different PG&E data elements is captured by the ESPI standard.


Download Supported Data Elements (PDF, 244 KB)
The Supported Data Elements document provides a mapping between the ESPI standard data elements and PG&E’s data elements.


Download XSDs (ZIP, 42 KB)
These XSDs correspond to the version of the ESPI schema definition that our Share My Data implementation uses (XSDs provide ESPI standard defined data elements).

Share My Data implementation follows the national Energy Service Provider Interface (ESPI) standard. The standard has also been branded as the Green Button Connect My Data initiative (GBCMD) as promoted by the White House Chief Technology Officer and Presidential Innovation Fellows. The ESPI standard outlines the technical framework for delivering functionality around customer authorization, data exchange and the format of the authorized data that is exchanged. These details are covered in the ESPI standard and GBCMD documentation found on greenbuttondata.org.


Prior to registering to use Share My Data, we highly recommend that you and your organization familiarize yourselves with the following resources:


Visit the Green Button Document Library
Documents providing background on the Green Button initiative, as well as important reference documents for Green Button implementers. These references represent the principle technical documents that define and describe Green Button technology.


Visit the Green Button Implementation Agreement
Details of interoperability and implementation agreement for those deploying GBCMD. Key specifications included in this document are API definition, OAuth 2.0 protocol, and Cyber-security and privacy requirements.


Visit the Green Button Data SDK
Tools for creating, testing, and displaying Green Button data files. Find the SDKs developed by PG&E: JavaScript | Python)


Visit the Green Button API Sandbox
This API sandbox allows developers full access, in Green Button Format, to Energy Usage Information for the purpose of developing new Green Button applications.

Due to system limitations as well as to allow PG&E to prevent malicious attacks, we recommend limiting your rate of requests to no more than:

  • 2 concurrent requests per millisecond
  • 50 requests per second

Please be aware that our rate limit is subject to change, as the Share My Data team is continually evaluating our ability to support third party requests as the platform grows and more users integrate with the system. However, we will be certain to communicate any such change in advance of implementation. We are not able to adjust or otherwise modify our rate limit for any individual third party.

general info

Need more information? Contact us

If you have questions or comments, please email our team at ShareMyData@pge.com.