Sub-client for reporting and export endpoints.
Accessed via HomeboxClient.reporting.
Source code in homebox/client.py
| class ReportingClient:
"""Sub-client for reporting and export endpoints.
Accessed via ``HomeboxClient.reporting``.
"""
def __init__(self, client: HomeboxClient):
"""Initialise the reporting sub-client with the shared root client."""
self.client = client
def export_bill_of_materials(self) -> str:
"""Export a Bill of Materials (BOM) report for all items in the group.
Returns:
str: Raw CSV-formatted Bill of Materials report.
"""
return self.client._get("/v1/reporting/bill-of-materials", binary=False)
|
__init__
__init__(client: HomeboxClient)
Initialise the reporting sub-client with the shared root client.
Source code in homebox/client.py
| def __init__(self, client: HomeboxClient):
"""Initialise the reporting sub-client with the shared root client."""
self.client = client
|
export_bill_of_materials
export_bill_of_materials() -> str
Export a Bill of Materials (BOM) report for all items in the group.
Returns:
| Name | Type |
Description |
str |
str
|
Raw CSV-formatted Bill of Materials report.
|
Source code in homebox/client.py
| def export_bill_of_materials(self) -> str:
"""Export a Bill of Materials (BOM) report for all items in the group.
Returns:
str: Raw CSV-formatted Bill of Materials report.
"""
return self.client._get("/v1/reporting/bill-of-materials", binary=False)
|