@portpowered/reference-data 0.4.3 → 0.4.4
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.
- package/README.md +1 -1
- package/generated/guides.json +1 -1
- package/generated/openapi.json +5 -5
- package/generated/public/docs/for-ai/guides/quickstart.md +4 -2
- package/generated/public/docs/for-ai/operations/sendMessage.md +4 -2
- package/generated/public/docs/for-ai/operations/sendMessageLegacyAlias.md +4 -2
- package/generated/public/docs/references/manifest.json +14 -14
- package/generated/public/docs/references/openapi.yaml +12 -5
- package/generated/public/docs/references/schemas/CreateMessageResponse.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
package/generated/guides.json
CHANGED
|
@@ -104,7 +104,7 @@
|
|
|
104
104
|
{
|
|
105
105
|
"id": "quickstart",
|
|
106
106
|
"title": "Verify the connection and control one light",
|
|
107
|
-
"content": "# Verify the connection and control one light\n\nFirst complete [OAuth setup](/docs/for-ai/guides/authentication-and-dcr.md). Keep the discovered API issuer and credentials in client configuration.\n\n1. GET /endpoints?owner=~caller&maxResults=25 with Authorization: Bearer <access_token>. Read [enumerateEndpoints](/docs/for-ai/operations/enumerateEndpoints.md) for the exact pagination and response fields. A filter such as owner is required. Follow the returned continuation metadata until the authorized enumeration is complete. An empty list means valid access with no visible devices; guide the user to [add devices](/docs/for-ai/guides/adding-devices.md).\n2. Select one light by full endpoint ID and group/room context. If the target is ambiguous, ask the user before acting.\n3. Inspect its declared capability namespace and version. A light declaring power 1.0 uses the [power guide](/docs/for-ai/capability-interfaces/power/1.0.md) and [turn-on payload schema](/docs/references/capability-interfaces/power/1.0/messages/turn-on.yaml). For other versions or capabilities, follow [the capability directory](/docs/for-ai/capability-interfaces.md).\n4. With the user's intended action, POST /messages. Read [sendMessage](/docs/for-ai/operations/sendMessage.md) and its linked request schema. Use the endpoint ID and message version you discovered, not the illustrative ID below.\n\n```json\n{\"target\":{\"type\":\"ENDPOINT\",\"id\":\"port1/principals/example/endpoints/example-light\"},\"message\":{\"header\":{\"namespace\":\"port1/systems/zero/capability-interfaces/power\",\"name\":\"turn-on\",\"version\":\"1.0\"},\"body\":{}}}\n```\n\
|
|
107
|
+
"content": "# Verify the connection and control one light\n\nFirst complete [OAuth setup](/docs/for-ai/guides/authentication-and-dcr.md). Keep the discovered API issuer and credentials in client configuration.\n\n1. GET /endpoints?owner=~caller&maxResults=25 with Authorization: Bearer <access_token>. Read [enumerateEndpoints](/docs/for-ai/operations/enumerateEndpoints.md) for the exact pagination and response fields. A filter such as owner is required. Follow the returned continuation metadata until the authorized enumeration is complete. An empty list means valid access with no visible devices; guide the user to [add devices](/docs/for-ai/guides/adding-devices.md).\n2. Select one light by full endpoint ID and group/room context. If the target is ambiguous, ask the user before acting.\n3. Inspect its declared capability namespace and version. A light declaring power 1.0 uses the [power guide](/docs/for-ai/capability-interfaces/power/1.0.md) and [turn-on payload schema](/docs/references/capability-interfaces/power/1.0/messages/turn-on.yaml). For other versions or capabilities, follow [the capability directory](/docs/for-ai/capability-interfaces.md).\n4. With the user's intended action, POST /messages with Authorization: Bearer <access_token> and Content-Type: application/json. Send the request object below as the JSON body, without a surrounding `body` field or a JSON string. Read [sendMessage](/docs/for-ai/operations/sendMessage.md) and its linked request schema. Use the endpoint ID and message version you discovered, not the illustrative ID below.\n\n```json\n{\"target\":{\"type\":\"ENDPOINT\",\"id\":\"port1/principals/example/endpoints/example-light\"},\"message\":{\"header\":{\"namespace\":\"port1/systems/zero/capability-interfaces/power\",\"name\":\"turn-on\",\"version\":\"1.0\"},\"body\":{}}}\n```\n\nHTTP 200 acknowledges acceptance. An asynchronous request can return `{\"messageId\":\"\"}` without a `message`; the empty ID is valid and does not provide a durable receipt or retry deduplication. When a unary response message is present, `messageId` identifies that response. Neither response proves physical state. After a lost response, treat the outcome as unknown and inspect state before deciding whether another action is safe.\n\nDo not cut JSON with head -c. GET /endpoints?id=<URL-encoded-endpoint-id>&expand=interfaces.attributes&forceDeviceAttributeQuery=true to request permitted device-backed state. Inspect attributes and partial errors. Check sampledAt against the command time and the capability version. sampledAt is the source-reported time, not the fetch time; an absent timestamp means freshness is unknown. Use [enumerateEndpoints and its linked components](/docs/for-ai/operations/enumerateEndpoints.md) for exact response shapes. Report returned device state separately from dispatch acceptance. Stale/unavailable state means unknown, and user confirmation may be necessary for a physical device.\n\nFor first setup, test one explicitly selected safe light. Do not turn off all homes as a connectivity check. See [lighting](/docs/for-ai/guides/lighting.md), [first setup](/docs/for-ai/guides/first-setup.md) and [authorization rules](/docs/for-ai/guides/authorization-rules.md).\n",
|
|
108
108
|
"setupPrompt": null
|
|
109
109
|
},
|
|
110
110
|
{
|
package/generated/openapi.json
CHANGED
|
@@ -9826,14 +9826,14 @@
|
|
|
9826
9826
|
},
|
|
9827
9827
|
"responses": {
|
|
9828
9828
|
"200": {
|
|
9829
|
-
"description": "
|
|
9829
|
+
"description": "Request accepted; an asynchronous acknowledgment may have an empty messageId and no message. Verify device state separately.",
|
|
9830
9830
|
"content": {
|
|
9831
9831
|
"application/json": {
|
|
9832
9832
|
"schema": {
|
|
9833
9833
|
"$ref": "#/components/schemas/CreateMessageResponse"
|
|
9834
9834
|
},
|
|
9835
9835
|
"example": {
|
|
9836
|
-
"messageId": "
|
|
9836
|
+
"messageId": ""
|
|
9837
9837
|
}
|
|
9838
9838
|
}
|
|
9839
9839
|
}
|
|
@@ -10106,14 +10106,14 @@
|
|
|
10106
10106
|
},
|
|
10107
10107
|
"responses": {
|
|
10108
10108
|
"200": {
|
|
10109
|
-
"description": "
|
|
10109
|
+
"description": "Request accepted; an asynchronous acknowledgment may have an empty messageId and no message. Verify device state separately.",
|
|
10110
10110
|
"content": {
|
|
10111
10111
|
"application/json": {
|
|
10112
10112
|
"schema": {
|
|
10113
10113
|
"$ref": "#/components/schemas/CreateMessageResponse"
|
|
10114
10114
|
},
|
|
10115
10115
|
"example": {
|
|
10116
|
-
"messageId": "
|
|
10116
|
+
"messageId": ""
|
|
10117
10117
|
}
|
|
10118
10118
|
}
|
|
10119
10119
|
}
|
|
@@ -26762,7 +26762,7 @@
|
|
|
26762
26762
|
"properties": {
|
|
26763
26763
|
"messageId": {
|
|
26764
26764
|
"type": "string",
|
|
26765
|
-
"description": "
|
|
26765
|
+
"description": "Identifies the unary response message when one is returned. An accepted asynchronous request can return an empty string with no message. This field does not provide a durable dispatch receipt, retry deduplication or proof of observed device state."
|
|
26766
26766
|
},
|
|
26767
26767
|
"message": {
|
|
26768
26768
|
"$ref": "#/components/schemas/Message",
|
|
@@ -5,12 +5,14 @@ First complete [OAuth setup](/docs/for-ai/guides/authentication-and-dcr.md). Kee
|
|
|
5
5
|
1. GET /endpoints?owner=~caller&maxResults=25 with Authorization: Bearer <access_token>. Read [enumerateEndpoints](/docs/for-ai/operations/enumerateEndpoints.md) for the exact pagination and response fields. A filter such as owner is required. Follow the returned continuation metadata until the authorized enumeration is complete. An empty list means valid access with no visible devices; guide the user to [add devices](/docs/for-ai/guides/adding-devices.md).
|
|
6
6
|
2. Select one light by full endpoint ID and group/room context. If the target is ambiguous, ask the user before acting.
|
|
7
7
|
3. Inspect its declared capability namespace and version. A light declaring power 1.0 uses the [power guide](/docs/for-ai/capability-interfaces/power/1.0.md) and [turn-on payload schema](/docs/references/capability-interfaces/power/1.0/messages/turn-on.yaml). For other versions or capabilities, follow [the capability directory](/docs/for-ai/capability-interfaces.md).
|
|
8
|
-
4. With the user's intended action, POST /messages. Read [sendMessage](/docs/for-ai/operations/sendMessage.md) and its linked request schema. Use the endpoint ID and message version you discovered, not the illustrative ID below.
|
|
8
|
+
4. With the user's intended action, POST /messages with Authorization: Bearer <access_token> and Content-Type: application/json. Send the request object below as the JSON body, without a surrounding `body` field or a JSON string. Read [sendMessage](/docs/for-ai/operations/sendMessage.md) and its linked request schema. Use the endpoint ID and message version you discovered, not the illustrative ID below.
|
|
9
9
|
|
|
10
10
|
```json
|
|
11
11
|
{"target":{"type":"ENDPOINT","id":"port1/principals/example/endpoints/example-light"},"message":{"header":{"namespace":"port1/systems/zero/capability-interfaces/power","name":"turn-on","version":"1.0"},"body":{}}}
|
|
12
12
|
```
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
HTTP 200 acknowledges acceptance. An asynchronous request can return `{"messageId":""}` without a `message`; the empty ID is valid and does not provide a durable receipt or retry deduplication. When a unary response message is present, `messageId` identifies that response. Neither response proves physical state. After a lost response, treat the outcome as unknown and inspect state before deciding whether another action is safe.
|
|
15
|
+
|
|
16
|
+
Do not cut JSON with head -c. GET /endpoints?id=<URL-encoded-endpoint-id>&expand=interfaces.attributes&forceDeviceAttributeQuery=true to request permitted device-backed state. Inspect attributes and partial errors. Check sampledAt against the command time and the capability version. sampledAt is the source-reported time, not the fetch time; an absent timestamp means freshness is unknown. Use [enumerateEndpoints and its linked components](/docs/for-ai/operations/enumerateEndpoints.md) for exact response shapes. Report returned device state separately from dispatch acceptance. Stale/unavailable state means unknown, and user confirmation may be necessary for a physical device.
|
|
15
17
|
|
|
16
18
|
For first setup, test one explicitly selected safe light. Do not turn off all homes as a connectivity check. See [lighting](/docs/for-ai/guides/lighting.md), [first setup](/docs/for-ai/guides/first-setup.md) and [authorization rules](/docs/for-ai/guides/authorization-rules.md).
|
|
@@ -114,13 +114,15 @@ post:
|
|
|
114
114
|
body: {}
|
|
115
115
|
responses:
|
|
116
116
|
'200':
|
|
117
|
-
description:
|
|
117
|
+
description: >-
|
|
118
|
+
Request accepted; an asynchronous acknowledgment may have an empty messageId and no message.
|
|
119
|
+
Verify device state separately.
|
|
118
120
|
content:
|
|
119
121
|
application/json:
|
|
120
122
|
schema:
|
|
121
123
|
$ref: /docs/references/schemas/CreateMessageResponse.json
|
|
122
124
|
example:
|
|
123
|
-
messageId:
|
|
125
|
+
messageId: ''
|
|
124
126
|
'400':
|
|
125
127
|
description: Invalid request payload or plugin dispatch request error
|
|
126
128
|
content:
|
|
@@ -114,13 +114,15 @@ post:
|
|
|
114
114
|
body: {}
|
|
115
115
|
responses:
|
|
116
116
|
'200':
|
|
117
|
-
description:
|
|
117
|
+
description: >-
|
|
118
|
+
Request accepted; an asynchronous acknowledgment may have an empty messageId and no message.
|
|
119
|
+
Verify device state separately.
|
|
118
120
|
content:
|
|
119
121
|
application/json:
|
|
120
122
|
schema:
|
|
121
123
|
$ref: /docs/references/schemas/CreateMessageResponse.json
|
|
122
124
|
example:
|
|
123
|
-
messageId:
|
|
125
|
+
messageId: ''
|
|
124
126
|
'400':
|
|
125
127
|
description: Invalid request payload or plugin dispatch request error
|
|
126
128
|
content:
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "@portpowered/reference-data",
|
|
3
3
|
"goModule": "github.com/portpowered/portos-reference-data",
|
|
4
|
-
"version": "0.4.
|
|
5
|
-
"sourceCommit": "
|
|
4
|
+
"version": "0.4.4",
|
|
5
|
+
"sourceCommit": "ddab20777e6044b21db0f0c1c525bf59ff4f31f0",
|
|
6
6
|
"sourceInputState": "committed",
|
|
7
|
-
"sourceInputSHA256": "
|
|
7
|
+
"sourceInputSHA256": "8a1f7e267ecac60eaf7a4e7ded150b2ff86ac59760c11b5251b52e4a78db40ca",
|
|
8
8
|
"sourceInputCount": 735,
|
|
9
|
-
"assetSetSHA256": "
|
|
9
|
+
"assetSetSHA256": "d101a7e55686035b22ab0b4e5cc2839c8e9c835db31d6ef329c6e801f53c848b",
|
|
10
10
|
"files": [
|
|
11
11
|
{
|
|
12
12
|
"path": "/docs/for-ai/capability-interfaces.md",
|
|
@@ -1401,8 +1401,8 @@
|
|
|
1401
1401
|
{
|
|
1402
1402
|
"path": "/docs/for-ai/guides/quickstart.md",
|
|
1403
1403
|
"contentType": "text/plain; charset=utf-8",
|
|
1404
|
-
"bytes":
|
|
1405
|
-
"sha256": "
|
|
1404
|
+
"bytes": 3180,
|
|
1405
|
+
"sha256": "a230400fa9f48bd5b629bad119bf079cbdf2faabee6270137ae0e9b2fa0b0fce",
|
|
1406
1406
|
"links": [
|
|
1407
1407
|
"/docs/for-ai/capability-interfaces.md",
|
|
1408
1408
|
"/docs/for-ai/capability-interfaces/power/1.0.md",
|
|
@@ -2649,8 +2649,8 @@
|
|
|
2649
2649
|
{
|
|
2650
2650
|
"path": "/docs/for-ai/operations/sendMessage.md",
|
|
2651
2651
|
"contentType": "text/plain; charset=utf-8",
|
|
2652
|
-
"bytes":
|
|
2653
|
-
"sha256": "
|
|
2652
|
+
"bytes": 9743,
|
|
2653
|
+
"sha256": "e9c1092a4809c9298d03d3bf0baec094125ea2f28ce2eddea031d2d8252e4f6d",
|
|
2654
2654
|
"links": [
|
|
2655
2655
|
"/docs/for-ai/guides/authentication-and-dcr.md",
|
|
2656
2656
|
"/docs/for-ai/schemas.md",
|
|
@@ -2662,8 +2662,8 @@
|
|
|
2662
2662
|
{
|
|
2663
2663
|
"path": "/docs/for-ai/operations/sendMessageLegacyAlias.md",
|
|
2664
2664
|
"contentType": "text/plain; charset=utf-8",
|
|
2665
|
-
"bytes":
|
|
2666
|
-
"sha256": "
|
|
2665
|
+
"bytes": 10014,
|
|
2666
|
+
"sha256": "0194b7b87f6ead4e405250f0e3710d89447e7d56e0df8efad9b57f800bf9a8af",
|
|
2667
2667
|
"links": [
|
|
2668
2668
|
"/docs/for-ai/guides/authentication-and-dcr.md",
|
|
2669
2669
|
"/docs/for-ai/schemas.md",
|
|
@@ -7350,8 +7350,8 @@
|
|
|
7350
7350
|
{
|
|
7351
7351
|
"path": "/docs/references/openapi.yaml",
|
|
7352
7352
|
"contentType": "application/yaml; charset=utf-8",
|
|
7353
|
-
"bytes":
|
|
7354
|
-
"sha256": "
|
|
7353
|
+
"bytes": 757609,
|
|
7354
|
+
"sha256": "a6db7cfd7943b4298c07af9dbf1078bcccc15725fa3a4e7a329f92c18e19c89c",
|
|
7355
7355
|
"links": []
|
|
7356
7356
|
},
|
|
7357
7357
|
{
|
|
@@ -8407,8 +8407,8 @@
|
|
|
8407
8407
|
{
|
|
8408
8408
|
"path": "/docs/references/schemas/CreateMessageResponse.json",
|
|
8409
8409
|
"contentType": "application/json",
|
|
8410
|
-
"bytes":
|
|
8411
|
-
"sha256": "
|
|
8410
|
+
"bytes": 798,
|
|
8411
|
+
"sha256": "d97a132f4abb5f70006e0f1340dd04a8d76e954c19b5bb557e86360a68071be5",
|
|
8412
8412
|
"links": []
|
|
8413
8413
|
},
|
|
8414
8414
|
{
|
|
@@ -7136,13 +7136,15 @@ paths:
|
|
|
7136
7136
|
body: {}
|
|
7137
7137
|
responses:
|
|
7138
7138
|
'200':
|
|
7139
|
-
description:
|
|
7139
|
+
description: >-
|
|
7140
|
+
Request accepted; an asynchronous acknowledgment may have an empty messageId and no
|
|
7141
|
+
message. Verify device state separately.
|
|
7140
7142
|
content:
|
|
7141
7143
|
application/json:
|
|
7142
7144
|
schema:
|
|
7143
7145
|
$ref: '#/components/schemas/CreateMessageResponse'
|
|
7144
7146
|
example:
|
|
7145
|
-
messageId:
|
|
7147
|
+
messageId: ''
|
|
7146
7148
|
'400':
|
|
7147
7149
|
description: Invalid request payload or plugin dispatch request error
|
|
7148
7150
|
content:
|
|
@@ -7366,13 +7368,15 @@ paths:
|
|
|
7366
7368
|
body: {}
|
|
7367
7369
|
responses:
|
|
7368
7370
|
'200':
|
|
7369
|
-
description:
|
|
7371
|
+
description: >-
|
|
7372
|
+
Request accepted; an asynchronous acknowledgment may have an empty messageId and no
|
|
7373
|
+
message. Verify device state separately.
|
|
7370
7374
|
content:
|
|
7371
7375
|
application/json:
|
|
7372
7376
|
schema:
|
|
7373
7377
|
$ref: '#/components/schemas/CreateMessageResponse'
|
|
7374
7378
|
example:
|
|
7375
|
-
messageId:
|
|
7379
|
+
messageId: ''
|
|
7376
7380
|
'400':
|
|
7377
7381
|
description: Invalid request payload or plugin dispatch request error
|
|
7378
7382
|
content:
|
|
@@ -20851,7 +20855,10 @@ components:
|
|
|
20851
20855
|
properties:
|
|
20852
20856
|
messageId:
|
|
20853
20857
|
type: string
|
|
20854
|
-
description:
|
|
20858
|
+
description: >-
|
|
20859
|
+
Identifies the unary response message when one is returned. An accepted asynchronous
|
|
20860
|
+
request can return an empty string with no message. This field does not provide a
|
|
20861
|
+
durable dispatch receipt, retry deduplication or proof of observed device state.
|
|
20855
20862
|
message:
|
|
20856
20863
|
$ref: '#/components/schemas/Message'
|
|
20857
20864
|
description: >-
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
"properties": {
|
|
8
8
|
"messageId": {
|
|
9
9
|
"type": "string",
|
|
10
|
-
"description": "
|
|
10
|
+
"description": "Identifies the unary response message when one is returned. An accepted asynchronous request can return an empty string with no message. This field does not provide a durable dispatch receipt, retry deduplication or proof of observed device state."
|
|
11
11
|
},
|
|
12
12
|
"message": {
|
|
13
13
|
"$ref": "/docs/references/schemas/Message.json",
|
package/package.json
CHANGED