Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.picnic.services Namespace Reference

Classes

class  PicnicServiceException
 

Functions

None async_register_services (HomeAssistant hass)
 
PicnicAPI get_api_client (HomeAssistant hass, str config_entry_id)
 
None handle_add_product (HomeAssistant hass, PicnicAPI api_client, ServiceCall call)
 
str|None product_search (PicnicAPI api_client, str|None product_name)
 

Detailed Description

Services for the Picnic integration.

Function Documentation

◆ async_register_services()

None homeassistant.components.picnic.services.async_register_services ( HomeAssistant  hass)
Register services for the Picnic integration, if not registered yet.

Definition at line 29 of file services.py.

◆ get_api_client()

PicnicAPI homeassistant.components.picnic.services.get_api_client ( HomeAssistant  hass,
str  config_entry_id 
)
Get the right Picnic API client based on the device id, else get the default one.

Definition at line 54 of file services.py.

◆ handle_add_product()

None homeassistant.components.picnic.services.handle_add_product ( HomeAssistant  hass,
PicnicAPI  api_client,
ServiceCall   call 
)
Handle the call for the add_product service.

Definition at line 61 of file services.py.

◆ product_search()

str | None homeassistant.components.picnic.services.product_search ( PicnicAPI  api_client,
str | None  product_name 
)
Query the api client for the product name.

Definition at line 79 of file services.py.