eeroctl 3.2.0__tar.gz → 3.4.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. {eeroctl-3.2.0/src/eeroctl.egg-info → eeroctl-3.4.0}/PKG-INFO +2 -2
  2. {eeroctl-3.2.0 → eeroctl-3.4.0}/pyproject.toml +2 -2
  3. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/__init__.py +1 -1
  4. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/updates.py +82 -2
  5. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/security.py +21 -6
  6. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/errors.py +5 -1
  7. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/safety.py +27 -0
  8. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/network.py +24 -1
  9. {eeroctl-3.2.0 → eeroctl-3.4.0/src/eeroctl.egg-info}/PKG-INFO +2 -2
  10. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl.egg-info/requires.txt +1 -1
  11. {eeroctl-3.2.0 → eeroctl-3.4.0}/LICENSE +0 -0
  12. {eeroctl-3.2.0 → eeroctl-3.4.0}/README.md +0 -0
  13. {eeroctl-3.2.0 → eeroctl-3.4.0}/setup.cfg +0 -0
  14. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/_coercion.py +0 -0
  15. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/__init__.py +0 -0
  16. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/account.py +0 -0
  17. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/activity.py +0 -0
  18. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/auth.py +0 -0
  19. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/completion.py +0 -0
  20. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/device.py +0 -0
  21. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/__init__.py +0 -0
  22. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/base.py +0 -0
  23. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/connections.py +0 -0
  24. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/led.py +0 -0
  25. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/nightlight.py +0 -0
  26. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/eero/pppoe.py +0 -0
  27. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/__init__.py +0 -0
  28. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/advanced.py +0 -0
  29. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/backup.py +0 -0
  30. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/base.py +0 -0
  31. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/ddns.py +0 -0
  32. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/dhcp.py +0 -0
  33. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/dns.py +0 -0
  34. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/entitlements.py +0 -0
  35. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/events.py +0 -0
  36. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/forwards.py +0 -0
  37. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/guest.py +0 -0
  38. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/members.py +0 -0
  39. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/notifications.py +0 -0
  40. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/ouicheck.py +0 -0
  41. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/permissions.py +0 -0
  42. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/power_saving.py +0 -0
  43. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/speedtest.py +0 -0
  44. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/sqm.py +0 -0
  45. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/subnets.py +0 -0
  46. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/transfer.py +0 -0
  47. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/usage.py +0 -0
  48. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/wan.py +0 -0
  49. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/network/wpa3.py +0 -0
  50. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/profile.py +0 -0
  51. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/commands/troubleshoot.py +0 -0
  52. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/const.py +0 -0
  53. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/context.py +0 -0
  54. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/exit_codes.py +0 -0
  55. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/__init__.py +0 -0
  56. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/account.py +0 -0
  57. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/activity.py +0 -0
  58. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/backup_access_points.py +0 -0
  59. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/base.py +0 -0
  60. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/data_usage.py +0 -0
  61. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/device.py +0 -0
  62. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/dns_policy.py +0 -0
  63. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/eero.py +0 -0
  64. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/entitlements.py +0 -0
  65. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/events.py +0 -0
  66. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/generic.py +0 -0
  67. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/members.py +0 -0
  68. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/misc.py +0 -0
  69. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/network.py +0 -0
  70. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/notifications.py +0 -0
  71. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/ouicheck.py +0 -0
  72. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/permissions.py +0 -0
  73. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/power_saving.py +0 -0
  74. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/profile.py +0 -0
  75. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/speedtest.py +0 -0
  76. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/subnets.py +0 -0
  77. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/transfer.py +0 -0
  78. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/wan.py +0 -0
  79. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/formatting/wpa3.py +0 -0
  80. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/main.py +0 -0
  81. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/options.py +0 -0
  82. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/output.py +0 -0
  83. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/sdk_private.py +0 -0
  84. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/__init__.py +0 -0
  85. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/account.py +0 -0
  86. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/activity.py +0 -0
  87. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/backup_access_points.py +0 -0
  88. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/base.py +0 -0
  89. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/data_usage.py +0 -0
  90. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/device.py +0 -0
  91. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/dns_policy.py +0 -0
  92. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/eero.py +0 -0
  93. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/entitlements.py +0 -0
  94. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/events.py +0 -0
  95. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/members.py +0 -0
  96. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/notifications.py +0 -0
  97. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/ouicheck.py +0 -0
  98. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/permissions.py +0 -0
  99. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/power_saving.py +0 -0
  100. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/profile.py +0 -0
  101. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/speedtest.py +0 -0
  102. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/subnets.py +0 -0
  103. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/transfer.py +0 -0
  104. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/wan.py +0 -0
  105. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/transformers/wpa3.py +0 -0
  106. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl/utils.py +0 -0
  107. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl.egg-info/SOURCES.txt +0 -0
  108. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl.egg-info/dependency_links.txt +0 -0
  109. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl.egg-info/entry_points.txt +0 -0
  110. {eeroctl-3.2.0 → eeroctl-3.4.0}/src/eeroctl.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eeroctl
3
- Version: 3.2.0
3
+ Version: 3.4.0
4
4
  Summary: Command-line interface for Eero network management
5
5
  Author: Eero CLI Contributors
6
6
  License: MIT
@@ -21,7 +21,7 @@ Classifier: Typing :: Typed
21
21
  Requires-Python: >=3.12
22
22
  Description-Content-Type: text/markdown
23
23
  License-File: LICENSE
24
- Requires-Dist: eero-api==8.0.6
24
+ Requires-Dist: eero-api==8.3.0
25
25
  Requires-Dist: rich>=13.0.0
26
26
  Requires-Dist: click>=8.0.0
27
27
  Requires-Dist: pyyaml>=6.0.0
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "eeroctl"
7
- version = "3.2.0"
7
+ version = "3.4.0"
8
8
  description = "Command-line interface for Eero network management"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.12"
@@ -27,7 +27,7 @@ classifiers = [
27
27
  "Typing :: Typed",
28
28
  ]
29
29
  dependencies = [
30
- "eero-api==8.0.6",
30
+ "eero-api==8.3.0",
31
31
  "rich>=13.0.0",
32
32
  "click>=8.0.0",
33
33
  "pyyaml>=6.0.0",
@@ -7,7 +7,7 @@ Entry point: eeroctl.main:cli
7
7
 
8
8
  from .main import cli, main
9
9
 
10
- __version__ = "3.2.0"
10
+ __version__ = "3.4.0"
11
11
  __version_info__ = tuple(int(x) for x in __version__.split(".")[:3])
12
12
 
13
13
 
@@ -4,11 +4,12 @@ Commands:
4
4
  - eero eero updates show: Show update status
5
5
  - eero eero updates check: Check for updates
6
6
  - eero eero updates apply: Apply a pending update
7
+ - eero eero updates hour set: Set the preferred update hour
7
8
  """
8
9
 
9
10
  import asyncio
10
11
  import sys
11
- from typing import Optional
12
+ from typing import Any, Optional
12
13
 
13
14
  import click
14
15
  from eero import EeroClient
@@ -19,7 +20,7 @@ from ...exit_codes import ExitCode
19
20
  from ...options import apply_options, force_option, network_option
20
21
  from ...safety import SafetyContext, SafetyError, get_write_spec, require_write_confirmation
21
22
  from ...transformers import extract_data
22
- from ...utils import run_with_client
23
+ from ...utils import run_with_client, write_if_changed
23
24
 
24
25
 
25
26
  @click.group(name="updates")
@@ -32,6 +33,7 @@ def updates_group(ctx: click.Context) -> None:
32
33
  show - Show update status
33
34
  check - Check for updates
34
35
  apply - Apply a pending update
36
+ hour - Preferred update hour
35
37
  """
36
38
  pass
37
39
 
@@ -64,6 +66,9 @@ def updates_show(ctx: click.Context) -> None:
64
66
  f"{'[green]Yes[/green]' if has_update else '[dim]No[/dim]'}\n"
65
67
  f"[bold]Target Firmware:[/bold] {target}"
66
68
  )
69
+ hour = updates.get("preferred_update_hour")
70
+ if hour is not None:
71
+ content += f"\n[bold]Preferred Update Hour:[/bold] {hour}"
67
72
  console.print(Panel(content, title="Update Status", border_style="blue"))
68
73
 
69
74
  await run_with_client(get_updates)
@@ -143,3 +148,78 @@ def updates_apply(ctx: click.Context, force: Optional[bool], network_id: Optiona
143
148
  await run_with_client(apply_update)
144
149
 
145
150
  asyncio.run(run_cmd())
151
+
152
+
153
+ @updates_group.group(name="hour")
154
+ @click.pass_context
155
+ def hour_group(ctx: click.Context) -> None:
156
+ """Manage the preferred update hour.
157
+
158
+ \b
159
+ Commands:
160
+ set - Set the hour of day updates are applied
161
+ """
162
+ pass
163
+
164
+
165
+ @hour_group.command(name="set")
166
+ @click.argument("hour", type=click.IntRange(0, 23))
167
+ @force_option
168
+ @network_option
169
+ @click.pass_context
170
+ def hour_set(
171
+ ctx: click.Context, hour: int, force: Optional[bool], network_id: Optional[str]
172
+ ) -> None:
173
+ """Set the hour of day the network applies updates.
174
+
175
+ \b
176
+ Arguments:
177
+ HOUR 0 (midnight to 1am) through 23 (11pm to midnight), in the
178
+ network's timezone
179
+ """
180
+ cli_ctx = apply_options(ctx, network_id=network_id, force=force)
181
+
182
+ spec = get_write_spec("eero updates hour set")
183
+ cli_ctx.active_write_spec = spec
184
+ try:
185
+ require_write_confirmation(
186
+ spec,
187
+ target=f"{hour}:00",
188
+ ctx=SafetyContext(
189
+ force=cli_ctx.force,
190
+ non_interactive=cli_ctx.non_interactive,
191
+ dry_run=cli_ctx.dry_run,
192
+ ),
193
+ console=cli_ctx.err_console,
194
+ )
195
+ except SafetyError as e:
196
+ cli_ctx.renderer.render_error(e.message)
197
+ sys.exit(e.exit_code)
198
+
199
+ async def run_cmd() -> None:
200
+ async def set_hour(client: EeroClient) -> None:
201
+ async def read() -> Optional[int]:
202
+ with cli_ctx.status("Reading current update hour..."):
203
+ raw_network = await client.get_network(cli_ctx.network_id)
204
+ net_data = extract_data(raw_network) if isinstance(raw_network, dict) else {}
205
+ updates = net_data.get("updates")
206
+ return updates.get("preferred_update_hour") if isinstance(updates, dict) else None
207
+
208
+ async def write() -> Any:
209
+ with cli_ctx.status(f"Setting update hour to {hour}..."):
210
+ return await client.set_preferred_update_hour(hour, cli_ctx.network_id)
211
+
212
+ # Typed to match `read`: an unknown current hour (None) never matches.
213
+ desired: Optional[int] = hour
214
+ await write_if_changed(
215
+ read,
216
+ desired,
217
+ write,
218
+ force=cli_ctx.force,
219
+ console=cli_ctx.err_console,
220
+ read_command=spec.read_command,
221
+ )
222
+
223
+ await run_with_client(set_hour)
224
+
225
+ asyncio.run(run_cmd())
@@ -10,11 +10,12 @@ Commands:
10
10
  - eero network security mlo set: Multi-link operation mode
11
11
  - eero network security passpoint: Passpoint
12
12
  - eero network security proxied-nodes: Proxied nodes
13
+ - eero network security hide-5g: Temporarily hide the 5 GHz band
13
14
  """
14
15
 
15
16
  import asyncio
16
17
  import sys
17
- from typing import Any
18
+ from typing import Any, Callable, Dict, Optional, Union
18
19
 
19
20
  import click
20
21
  from eero import EeroClient
@@ -26,6 +27,7 @@ from ...formatting.wpa3 import print_fast_transition
26
27
  from ...options import apply_options, common_options
27
28
  from ...safety import SafetyContext, SafetyError, get_write_spec, require_write_confirmation
28
29
  from ...transformers import extract_data
30
+ from ...transformers.network import extract_hide_5g
29
31
  from ...transformers.wpa3 import extract_fast_transition
30
32
  from ...utils import run_with_client, write_if_changed
31
33
 
@@ -47,6 +49,7 @@ def security_group(ctx: click.Context) -> None:
47
49
  mlo - Multi-link operation mode
48
50
  passpoint - Passpoint
49
51
  proxied-nodes - Proxied nodes
52
+ hide-5g - Temporarily hide the 5 GHz band
50
53
 
51
54
  \b
52
55
  Examples:
@@ -63,7 +66,7 @@ def security_group(ctx: click.Context) -> None:
63
66
  def security_show(ctx: click.Context) -> None:
64
67
  """Show security settings.
65
68
 
66
- Extended with `mlo_mode`, `passpoint`, `proxied_nodes`, and `ddns`, read
69
+ Extended with `mlo_mode`, `passpoint`, `proxied_nodes`, `hide_5g`, and `ddns`, read
67
70
  straight from the `get_network` envelope since no dedicated GETs exist
68
71
  for them (migration plan §4, `network security show` (extend) row).
69
72
  """
@@ -117,7 +120,7 @@ def security_show(ctx: click.Context) -> None:
117
120
  extras_table = Table(title="Extended Security Settings")
118
121
  extras_table.add_column("Field", style="cyan")
119
122
  extras_table.add_column("Value")
120
- for key in ("mlo_mode", "passpoint", "proxied_nodes", "ddns"):
123
+ for key in ("mlo_mode", "passpoint", "proxied_nodes", "hide_5g", "ddns"):
121
124
  extras_table.add_row(key, str(safe_extras.get(key)))
122
125
  console.print(extras_table)
123
126
 
@@ -223,9 +226,14 @@ def _set_security_setting(
223
226
  # `get_network` envelope, the same fields the phase-A extended `security
224
227
  # show` reads (migration plan §2.7). This factory mirrors
225
228
  # `_make_security_toggle` but reads its current state from there instead of
226
- # `get_security_settings`.
229
+ # `get_security_settings`. `state_field` is either a top-level key of the
230
+ # envelope's `data` or a function extracting the current state from it
231
+ # (returning None when the state is unknown).
232
+ NetworkStateField = Union[str, Callable[[Dict[str, Any]], Optional[bool]]]
233
+
234
+
227
235
  def _make_network_field_toggle(
228
- setting_name: str, api_method: str, display_name: str, state_field: str
236
+ setting_name: str, api_method: str, display_name: str, state_field: NetworkStateField
229
237
  ):
230
238
  """Factory for security toggle command groups backed by `get_network`."""
231
239
 
@@ -262,7 +270,7 @@ def _set_network_field_setting(
262
270
  setting_name: str,
263
271
  api_method: str,
264
272
  display_name: str,
265
- state_field: str,
273
+ state_field: NetworkStateField,
266
274
  enable: bool,
267
275
  force: bool,
268
276
  ):
@@ -296,6 +304,9 @@ def _set_network_field_setting(
296
304
  with cli_ctx.status(f"Reading current {display_name} setting..."):
297
305
  raw_network = await client.get_network(cli_ctx.network_id)
298
306
  net_data = extract_data(raw_network) if isinstance(raw_network, dict) else {}
307
+ if callable(state_field):
308
+ state = state_field(net_data)
309
+ return not enable if state is None else state
299
310
  return bool(net_data.get(state_field, not enable))
300
311
 
301
312
  async def write() -> Any:
@@ -399,6 +410,9 @@ passpoint_group = _make_network_field_toggle(
399
410
  proxied_nodes_group = _make_network_field_toggle(
400
411
  "proxied-nodes", "set_proxied_nodes", "proxied nodes", "proxied_nodes"
401
412
  )
413
+ hide_5g_group = _make_network_field_toggle(
414
+ "hide-5g", "set_hide_5g", "5 GHz hiding", extract_hide_5g
415
+ )
402
416
 
403
417
  security_group.add_command(wpa3_group)
404
418
  security_group.add_command(band_steering_group)
@@ -517,3 +531,4 @@ def fast_transition_disable(ctx: click.Context, force: bool) -> None:
517
531
 
518
532
  security_group.add_command(passpoint_group)
519
533
  security_group.add_command(proxied_nodes_group)
534
+ security_group.add_command(hide_5g_group)
@@ -4,6 +4,7 @@ This module provides utilities for translating exceptions to user-friendly
4
4
  error messages and appropriate exit codes.
5
5
  """
6
6
 
7
+ import math
7
8
  from typing import Any, Callable, Optional, TypeVar
8
9
 
9
10
  from eero.exceptions import (
@@ -108,8 +109,11 @@ def _render_rate_limit(e: EeroRateLimitException, prefix: str) -> tuple[str, Exi
108
109
  """Render a rate-limit failure."""
109
110
  # No dedicated exit code for rate limiting (§2.6/Q5 of the v8
110
111
  # migration plan: exit 7 stays TIMEOUT-only); falls to GENERIC_ERROR.
112
+ # `retry_after` (eero-api >= 8.1.2) is the server's Retry-After, in seconds.
113
+ wait = f" {math.ceil(e.retry_after)}s" if e.retry_after is not None else ""
111
114
  return (
112
- f"[yellow]{prefix}Rate limited. Please wait and try again.{_error_code_suffix(e)}[/yellow]",
115
+ f"[yellow]{prefix}Rate limited. Please wait{wait} and try again."
116
+ f"{_error_code_suffix(e)}[/yellow]",
113
117
  ExitCode.GENERIC_ERROR,
114
118
  )
115
119
 
@@ -609,6 +609,24 @@ WRITE_SPECS: Dict[str, WriteSpec] = _build_registry(
609
609
  reboots="none",
610
610
  read_command="eero network security show",
611
611
  ),
612
+ # -- network security hide-5g (eero-api 8.3.0 `set_hide_5g`): hiding
613
+ # drops every 5 GHz client, the same blast radius as `network
614
+ # password set`; un-hiding only brings the band back. Unverified. --
615
+ "network security hide-5g enable": WriteSpec(
616
+ command="network security hide-5g enable",
617
+ risk=OperationRisk.HIGH,
618
+ status=WriteStatus.UNVERIFIED,
619
+ reboots="clients",
620
+ read_command="eero network security show",
621
+ phrase="DISCONNECT",
622
+ ),
623
+ "network security hide-5g disable": WriteSpec(
624
+ command="network security hide-5g disable",
625
+ risk=OperationRisk.MEDIUM,
626
+ status=WriteStatus.UNVERIFIED,
627
+ reboots="clients",
628
+ read_command="eero network security show",
629
+ ),
612
630
  # -- network rename: `set_network_name` is not live-verified and
613
631
  # disconnects clients while the SSID change propagates. --
614
632
  "network rename": WriteSpec(
@@ -967,6 +985,15 @@ WRITE_SPECS: Dict[str, WriteSpec] = _build_registry(
967
985
  read_command="eero eero updates show",
968
986
  phrase="REBOOT",
969
987
  ),
988
+ # -- eero updates hour set (eero-api 8.3.0 `set_preferred_update_hour`):
989
+ # only moves the update window, nothing disrupted. Unverified. --
990
+ "eero updates hour set": WriteSpec(
991
+ command="eero updates hour set",
992
+ risk=OperationRisk.MEDIUM,
993
+ status=WriteStatus.UNVERIFIED,
994
+ reboots="none",
995
+ read_command="eero eero updates show",
996
+ ),
970
997
  # -- network support bundle export: not an SDK write at all -- it is
971
998
  # two reads (`get_support`, `get_diagnostics`) written to a local
972
999
  # file. Confirmed because the bundle can be large and may contain
@@ -66,16 +66,39 @@ def extract_network_security_extras(network_data: Dict[str, Any]) -> Dict[str, A
66
66
  `extract_network`).
67
67
 
68
68
  Returns:
69
- A dict with `mlo_mode`, `passpoint`, `proxied_nodes`, `ddns` keys.
69
+ A dict with `mlo_mode`, `passpoint`, `proxied_nodes`, `hide_5g`,
70
+ `ddns` keys.
70
71
  """
71
72
  return {
72
73
  "mlo_mode": network_data.get("mlo_mode"),
73
74
  "passpoint": network_data.get("passpoint"),
74
75
  "proxied_nodes": network_data.get("proxied_nodes"),
76
+ "hide_5g": extract_hide_5g(network_data),
75
77
  "ddns": network_data.get("ddns"),
76
78
  }
77
79
 
78
80
 
81
+ def extract_hide_5g(network_data: Dict[str, Any]) -> Optional[bool]:
82
+ """Extract whether 5 GHz is temporarily hidden.
83
+
84
+ The flag lives at `temporary_flags.hide_5g.value` on the `get_network`
85
+ envelope (eero-api 8.3.0 `set_hide_5g`). The API drops the entry when the
86
+ flag expires or is cleared, leaving `temporary_flags` as `{}`.
87
+
88
+ Args:
89
+ network_data: Already-unwrapped `data` from `get_network`.
90
+
91
+ Returns:
92
+ The flag, False when `temporary_flags` has no `hide_5g` entry, or
93
+ None when the envelope carries no `temporary_flags` at all.
94
+ """
95
+ flags = network_data.get("temporary_flags")
96
+ if not isinstance(flags, dict):
97
+ return None
98
+ flag = flags.get("hide_5g")
99
+ return bool(flag.get("value")) if isinstance(flag, dict) else False
100
+
101
+
79
102
  def normalize_network_status(status: Optional[str]) -> str:
80
103
  """Normalize network status for display.
81
104
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eeroctl
3
- Version: 3.2.0
3
+ Version: 3.4.0
4
4
  Summary: Command-line interface for Eero network management
5
5
  Author: Eero CLI Contributors
6
6
  License: MIT
@@ -21,7 +21,7 @@ Classifier: Typing :: Typed
21
21
  Requires-Python: >=3.12
22
22
  Description-Content-Type: text/markdown
23
23
  License-File: LICENSE
24
- Requires-Dist: eero-api==8.0.6
24
+ Requires-Dist: eero-api==8.3.0
25
25
  Requires-Dist: rich>=13.0.0
26
26
  Requires-Dist: click>=8.0.0
27
27
  Requires-Dist: pyyaml>=6.0.0
@@ -1,4 +1,4 @@
1
- eero-api==8.0.6
1
+ eero-api==8.3.0
2
2
  rich>=13.0.0
3
3
  click>=8.0.0
4
4
  pyyaml>=6.0.0
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes