Exceptions¶
pyfamilysafety.exceptions.HttpException ¶
HttpException(*args)
Bases: Exception
Base exception for HTTP errors from the Family Safety API.
Raised by :meth:pyfamilysafety.api.FamilySafetyAPI.send_request for
non-success status codes not mapped to a specific subclass.
Source code in pyfamilysafety/exceptions.py
10 11 | |
pyfamilysafety.exceptions.Unauthorized ¶
Unauthorized()
Bases: HttpException
HTTP 401 or failed token exchange.
Raised when authentication fails during login, refresh, or API calls.
Source code in pyfamilysafety/exceptions.py
19 20 | |
pyfamilysafety.exceptions.RequestDenied ¶
RequestDenied(message='HTTP Access Denied')
Bases: HttpException
HTTP 403 access denied.
Raised when the authenticated user lacks permission for the requested action.
Source code in pyfamilysafety/exceptions.py
28 29 | |
pyfamilysafety.exceptions.AggregatorException ¶
AggregatorException()
Bases: HttpException
Transient Microsoft aggregator failure (HTTP 500).
Raised when the response body contains the known aggregator error message.
:meth:pyfamilysafety.FamilySafety.update catches this and skips the refresh.
Source code in pyfamilysafety/exceptions.py
38 39 | |