Skip to content

homematicip.connection.rest_connection

RestConnection dataclass

__init__

__init__

Initialize the RestConnection object.

@param context: The connection context @param httpx_client_session: The httpx client session if you want to use a custom one @param log_status_exceptions: If status exceptions should be logged

async_post async

async_post

Send an async post request to cloud with json data. Returns a json result. @param url: The path of the url to send the request to @param data: The data to send as json @param custom_header: A custom header to send. Replaces the default header @return: The result as a RestResult object @raises HmipThrottlingError: If the cloud returns a 429 status code (throttling active)

get_header

get_header

If headers must be manipulated use this method to get the current headers.