Coverage for abb_rws_client_python_rw6/rws/retcode.py: 100%
5 statements
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-13 22:17 +0000
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-13 22:17 +0000
1# This file is AUTO-GENERATED by utils/generator/main.py
2# DO NOT EDIT MANUALLY — run the generator to regenerate.
3# Generator author: Clement RACINET
4"""
5RWS module: RobotWare Services → RobotWare return codes service → Get a list of RobotWare retu...
71:1 mirror of the ABB RobotWare 6 REST API.
8Each function maps to exactly one HTTP endpoint.
9No composed logic — see highlevel/ for wrappers.
10"""
12from __future__ import annotations
14import httpx
16from abb_rws_client_python_rw6.core.client import RWSClient
19async def get_list_of_robotware_return_codes(
20 client: RWSClient,
21 code: str | None = None,
22) -> httpx.Response:
23 """
24 Get a list of RobotWare return codes.
26 Route: ``GET /rw/retcode``
27 ABB constraints: Error description are only available in English and XML is the only
28 supported format. Not supported in bootserver mode
30 Args:
31 client: Open RWSClient instance.
32 code: Query parameter. Optional.
34 Returns:
35 Raw HTTP response. Expected success: HTTP 200.
37 Raises:
38 RWSAuthenticationError: On HTTP 401.
39 RWSNotFoundError: On HTTP 404.
40 RWSHTTPError: On any other HTTP >= 400.
42 Example:
43 ```python
44 >>> await get_list_of_robotware_return_codes(client)
45 <Response [200]>
46 ```
47 """
48 return await client.get(
49 "/rw/retcode",
50 params={k: v for k, v in {"code": code}.items() if v is not None},
51 )