Exemplo n.º 1
0
def get_connection():
    """API endpoint to get the user's connections as entity addresses ordered from newest to oldest.

    .. :quickref: User; Retrieve entity addresses of connections


    **Example request**

    .. code-block:: json

        {
            "type": "GetConnectionRequest",
        }

    **Example response**

    This "GetConnectionResponse" message indicates that the user had access rights to retrieve four entity addresses
    owned by three different users.

    .. sourcecode:: json

        {
            "type": "GetConnectionResponse",
            "connections": [
                "ea1.2018-06.io.flexmeasures.company:3:4",
                "ea1.2018-06.io.flexmeasures.company:8:3",
                "ea1.2018-06.io.flexmeasures.company:9:2",
                "ea1.2018-06.io.flexmeasures.company:3:1"
            ],
            "names": [
                "CS 4",
                "CS 3",
                "CS 2",
                "CS 1"
            ]
        }

    :reqheader Authorization: The authentication token
    :reqheader Content-Type: application/json
    :resheader Content-Type: application/json
    :status 200: PROCESSED
    :status 400: INVALID_MESSAGE_TYPE
    :status 401: UNAUTHORIZED
    :status 403: INVALID_SENDER
    :status 405: INVALID_METHOD
    """
    return v1_1_implementations.get_connection_response()
Exemplo n.º 2
0
def get_connection():
    return v1_1_implementations.get_connection_response()