sgr_commhandler.declaration_library

Provides a client for the declaration library’s REST API.

Attributes

LIB_BASE_URL

The base URL of the library REST API.

Functions

get_product_eid_xml(name)

Gets the XML data of a product EID.

get_product_info(name)

Gets information about a product EID.

Module Contents

sgr_commhandler.declaration_library.LIB_BASE_URL = 'https://library.smartgridready.ch'

The base URL of the library REST API.

sgr_commhandler.declaration_library.get_product_eid_xml(name)

Gets the XML data of a product EID.

Parameters:

name (str) – the EID name

Returns:

an XML string

Return type:

str

sgr_commhandler.declaration_library.get_product_info(name)

Gets information about a product EID.

Parameters:

name (str) – the EID name

Returns:

a JSON object

Return type:

str