Skip to content

Commit 0956f9b

Browse files
authored
Reconcile release candidate scope with main (#107)
* Create initial MVP Trust Domain API spec + Shared Schema Bundling (#86) * feat: Added baseline scaffolding for trust domain management endpoints * feat: added flexible Policy component model for binding policies to Trust Domains * feat: ported AccessDetail to Trust Domain model as-is but with ability for multiple to be specified * refactor: changed Policy model to discriminator pattern in order to make usage clearer. Added example uses to trust domain creation POST * chore: replace descriptions referring to Isolated Networks to Trust Domains * fix: addressed rendering issue with example objects * fix: typo fix * refactor: changed policies from list of policy objects to keyed map in order to flatten structure and prevent policy duplication * refactor: move Policy models to Policy.yaml * refactor: moved AccessDetails and relate models into own file * refactor: change resource ids from string to UUID * refactor: simplified security scopes * fix: removed 'scopes' from securityScheme definition * refactor: change downstream/upstream rate policies to accept a enum of units instead of being restricted to Kbps * refactor: add README for shared component structure and bundling process * fix: remove committed file * fix: resolve most linter warnings * fix/refactor: reduced AccesDetail down to single point of discrimination in order to addres linter warnings * refactor: update isolated networks user story to trust domains * feat: update default API_documentation/README.md to include where find guidance on creating user stories * feat: added trust domains capability discovery endpoint/model * fix: removed file accidentally committed * refactor: replaced NAM openapi spec with new bundled trust domain centric version * refactor: update docs to use labels API Consumers and API Providers instead of alternative labels (#88) * Port Network Access Device + Reboot models and endpoints (#93) * refactor: move security schemems definition to Common.yaml * refactor: add CAMARA_common.yaml from Commonalities and update to Generic response to reference the Commonalities definitions. * refactor(take two): add CAMARA_common.yaml from Commonalities and update to Generic response to reference the Commonalities definitions. * refactor: convert 'Common' to point to either NAM_Common.yaml or CAMARA_common.yaml * feat: add initial skeleton of NetworkAccessDevices-linting good * feat: ported existing Reboot + NetworkAccessDevice from former API spec * refactor: add readonly: true to response only schemas * refactor: tighten schema with 'additionalProperites: false' and remove redundant 'type: object' from AccessDetail discriminator * refactor: remove 401 responses * refactor: misc AI review updates * refactor: adjust scopes and normalize descriptions * refactor: improved schema/parameter descriptions * refactor: update info description with reboot usage * refactor: update the API definitions README folder layout * feat: apply generated openapi spec to primary yaml file * fix: addressed duplicate uuid in examples * fix: minor review fixes * Add service schema endpoints (#99) * feat: add structure for Service schemas + endpoints * refactor: add serviceId to TrustDomainCreate as required parameter * fix: address contextual description of fields that use to common schemas in order to provide contextual descriptions * docs: improve rendered descriptions and non-rendered inline comments * chore: update .gitignore to exclude .vscode folders * update nam openapi spec with Service changes * 85 alpha release checklist (#100) * fix: reset versions back to 'wip' * fix: remove info.contact field per section 5.3.5 of API Design Guide * fix: add missing externalDocs stanza per section 5.4 of API Design Guide * fix: update CAMARA_common.yaml to v0.7.1 from r3.4 tag and remove placeholders * chore: update API Readiness Checklist * fix: removed duplicate Generic404 response schema * fix: addressed broken schema for experimental API * fix: reset versions in yaml files to 'wip' (#98) (#106) * fix: resolve yamllint and spectral linter errors * fix: address spectral and yamllint linting errors * fix: address spectral and yamllint linting errors(again)
1 parent 99062cc commit 0956f9b

22 files changed

Lines changed: 5068 additions & 2973 deletions

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
.DS_Store
2+
.vscode/
3+
*-bundled.yaml
Lines changed: 225 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,225 @@
1+
# This file defines the AccessDetail schema model for different network access types.
2+
# It includes Wi-Fi and Thread access details with various security modes.
3+
4+
components:
5+
schemas:
6+
# Base security mode schemas (unchanged)
7+
WpaPersonalDetail:
8+
type: object
9+
description: WPA Personal security mode configuration for Wi-Fi networks.
10+
properties:
11+
password:
12+
type: string
13+
writeOnly: true
14+
minLength: 8
15+
maxLength: 255
16+
pattern: "^[\\x20-\\x7E]{8,63}$"
17+
description: The password for the WPA Personal Wi-Fi network
18+
example: &wpa-personal-password "my-password"
19+
securityModeType:
20+
type: string
21+
enum:
22+
- WPA2-Personal
23+
- WPA2-WPA3-Personal
24+
- WPA3-Personal
25+
description: |
26+
The security mode type for the WPA Personal Wi-Fi network.
27+
Leave blank to auto-select.
28+
example: &wpa-personal-security-mode-type "WPA3-Personal"
29+
additionalProperties: false
30+
required:
31+
- password
32+
example: &wpa-personal
33+
password: *wpa-personal-password
34+
securityModeType: *wpa-personal-security-mode-type
35+
36+
WpaEnterpriseDetail:
37+
type: object
38+
description: WPA Enterprise security mode configuration for Wi-Fi networks.
39+
properties:
40+
authServer:
41+
type: string
42+
maxLength: 255
43+
description: The authentication server for the WPA Enterprise Wi-Fi network
44+
example: &wpa-enterprise-auth-server "1.2.3.4"
45+
securityModeType:
46+
type: string
47+
enum:
48+
- WPA2-Enterprise
49+
- WPA3-Enterprise
50+
description: The security mode type for the WPA Enterprise Wi-Fi network
51+
example: &wpa-enterprise-security-mode-type "WPA3-Enterprise"
52+
additionalProperties: false
53+
required:
54+
- securityModeType
55+
example: &wpa-enterprise
56+
authServer: *wpa-enterprise-auth-server
57+
securityModeType: *wpa-enterprise-security-mode-type
58+
59+
# Flattened concrete implementations for Wi-Fi
60+
WiFiWpaPersonalAccessDetail:
61+
type: object
62+
description: Complete access details for Wi-Fi networks using WPA Personal security mode.
63+
properties:
64+
accessType:
65+
type: string
66+
description: The type of network access.
67+
enum:
68+
- "Wi-Fi:WPA_PERSONAL"
69+
example: "Wi-Fi:WPA_PERSONAL"
70+
ssid:
71+
type: string
72+
minLength: 2
73+
maxLength: 32
74+
pattern: "^(?! )[\\x20-\\x7E]{2,32}(?<! )$"
75+
description: |
76+
SSID (2-32 printable ASCII characters). No leading or trailing space.
77+
Pattern enforces:
78+
- Printable ASCII only (0x20-0x7E)
79+
- First character not space
80+
- Last character not space
81+
example: &wifi-ssid "my-ssid"
82+
securityMode:
83+
allOf:
84+
- $ref: "#/components/schemas/WpaPersonalDetail"
85+
description: WPA Personal security mode details
86+
example: *wpa-personal
87+
additionalProperties: false
88+
required:
89+
- accessType
90+
- securityMode
91+
example: &wifi-wpa-personal-access-detail
92+
accessType: "Wi-Fi:WPA_PERSONAL"
93+
ssid: *wifi-ssid
94+
securityMode: *wpa-personal
95+
96+
WiFiWpaEnterpriseAccessDetail:
97+
type: object
98+
description: Complete access details for Wi-Fi networks using WPA Enterprise security mode.
99+
properties:
100+
accessType:
101+
type: string
102+
description: The type of network access.
103+
enum:
104+
- "Wi-Fi:WPA_ENTERPRISE"
105+
example: "Wi-Fi:WPA_ENTERPRISE"
106+
ssid:
107+
type: string
108+
minLength: 2
109+
maxLength: 32
110+
pattern: "^(?! )[\\x20-\\x7E]{2,32}(?<! )$"
111+
description: |
112+
SSID (2-32 printable ASCII characters). No leading or trailing space.
113+
Pattern enforces:
114+
- Printable ASCII only (0x20-0x7E)
115+
- First character not space
116+
- Last character not space
117+
example: *wifi-ssid
118+
securityMode:
119+
allOf:
120+
- $ref: "#/components/schemas/WpaEnterpriseDetail"
121+
description: WPA Enterprise security mode details
122+
example: *wpa-enterprise
123+
additionalProperties: false
124+
required:
125+
- accessType
126+
- securityMode
127+
example: &wifi-wpa-enterprise-access-detail
128+
accessType: "Wi-Fi:WPA_ENTERPRISE"
129+
ssid: *wifi-ssid
130+
securityMode: *wpa-enterprise
131+
132+
ThreadStructuredAccessDetail:
133+
type: object
134+
description: Complete access details for Thread networks using structured (individual parameter) format.
135+
properties:
136+
accessType:
137+
type: string
138+
description: The type of network access.
139+
enum:
140+
- "Thread:STRUCTURED"
141+
example: "Thread:STRUCTURED"
142+
channel:
143+
type: integer
144+
minimum: 11
145+
maximum: 26
146+
description: The Thread channel (IEEE 802.15.4 channel number)
147+
example: 13
148+
extendedPanId:
149+
type: string
150+
pattern: "^[0-9a-fA-F]{16}$"
151+
description: The Extended PAN ID (16 hex digits)
152+
example: "d63e8e3e495ebbc3"
153+
networkKey:
154+
type: string
155+
pattern: "^[0-9a-fA-F]{32}$"
156+
description: The Thread Network Key (32 hex digits)
157+
example: "dfd34f0f05cad978ec4e32b0413038ff"
158+
networkName:
159+
type: string
160+
minLength: 1
161+
maxLength: 16
162+
description: The Thread Network Name (1-16 ASCII characters)
163+
example: "Spec-Thread-B3AF"
164+
panId:
165+
type: string
166+
pattern: "^[0-9a-fA-F]{4}$"
167+
description: The PAN ID (4 hex digits)
168+
example: "d63e"
169+
additionalProperties: false
170+
required:
171+
- accessType
172+
- channel
173+
- extendedPanId
174+
- networkKey
175+
- networkName
176+
- panId
177+
example: &thread-structured-access-detail
178+
accessType: "Thread:STRUCTURED"
179+
channel: 13
180+
extendedPanId: "d63e8e3e495ebbc3"
181+
networkKey: "dfd34f0f05cad978ec4e32b0413038ff"
182+
networkName: "Spec-Thread-B3AF"
183+
panId: "d63e"
184+
185+
ThreadTlvAccessDetail:
186+
type: object
187+
description: Complete access details for Thread networks using TLV (Type-Length-Value) encoded operational dataset format.
188+
properties:
189+
accessType:
190+
type: string
191+
description: The type of network access.
192+
enum:
193+
- "Thread:TLV"
194+
example: "Thread:TLV"
195+
operationalDataset:
196+
type: string
197+
maxLength: 255
198+
description: The Thread network credentials (operational dataset) encoded as a TLV hex string
199+
example: "0e08000000000000010010000102030405060708090a0b0c0d0e0f"
200+
additionalProperties: false
201+
required:
202+
- accessType
203+
- operationalDataset
204+
example: &thread-tlv-access-detail
205+
accessType: "Thread:TLV"
206+
operationalDataset: "0e08000000000000010010000102030405060708090a0b0c0d0e0f"
207+
208+
# Single discriminated union with namespaced values
209+
AccessDetail:
210+
oneOf:
211+
- $ref: "#/components/schemas/WiFiWpaPersonalAccessDetail"
212+
- $ref: "#/components/schemas/WiFiWpaEnterpriseAccessDetail"
213+
- $ref: "#/components/schemas/ThreadStructuredAccessDetail"
214+
- $ref: "#/components/schemas/ThreadTlvAccessDetail"
215+
discriminator:
216+
propertyName: accessType
217+
mapping:
218+
"Wi-Fi:WPA_PERSONAL": "#/components/schemas/WiFiWpaPersonalAccessDetail"
219+
"Wi-Fi:WPA_ENTERPRISE": "#/components/schemas/WiFiWpaEnterpriseAccessDetail"
220+
"Thread:STRUCTURED": "#/components/schemas/ThreadStructuredAccessDetail"
221+
"Thread:TLV": "#/components/schemas/ThreadTlvAccessDetail"
222+
required:
223+
- accessType
224+
description: Network access details for different network types and variants
225+
example: *wifi-wpa-personal-access-detail

0 commit comments

Comments
 (0)