Files
2026-06-05 01:35:35 +08:00

173 lines
5.2 KiB
JSON

{
"contract": "m0-capability-topology",
"project": {
"projectId": "prj_01J00000000000000000000010",
"name": "M0 Contract Project",
"status": "active",
"environment": "dev",
"createdBy": "usr_01J00000000000000000000010",
"createdAt": "2026-05-21T00:00:00.000Z",
"updatedAt": "2026-05-21T00:00:00.000Z"
},
"gatewaySession": {
"gatewaySessionId": "gws_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"serviceId": "hwlab-gateway-simu",
"gatewayId": "gtw_01J00000000000000000000010",
"endpoint": "http://127.0.0.1:7101",
"status": "connected",
"environment": "dev",
"startedAt": "2026-05-21T00:00:00.000Z",
"lastSeenAt": "2026-05-21T00:00:02.000Z",
"labels": {
"mode": "simulated"
}
},
"resources": [
{
"resourceId": "res_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"gatewaySessionId": "gws_01J00000000000000000000010",
"boxId": "box_01J00000000000000000000010",
"resourceType": "power_supply",
"name": "simulated power supply",
"state": "available",
"environment": "dev",
"metadata": {
"ports": [
"out0"
]
},
"createdAt": "2026-05-21T00:00:00.000Z",
"updatedAt": "2026-05-21T00:00:00.000Z"
},
{
"resourceId": "res_01J00000000000000000000011",
"projectId": "prj_01J00000000000000000000010",
"gatewaySessionId": "gws_01J00000000000000000000010",
"boxId": "box_01J00000000000000000000010",
"resourceType": "board",
"name": "simulated dut board",
"state": "reserved",
"environment": "dev",
"metadata": {
"ports": [
"vin",
"uart0"
]
},
"createdAt": "2026-05-21T00:00:00.000Z",
"updatedAt": "2026-05-21T00:00:00.000Z"
}
],
"capabilities": [
{
"capabilityId": "cap_01J00000000000000000000010",
"resourceId": "res_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"name": "power.cycle",
"description": "Cycle simulated DUT power through the gateway.",
"direction": "bidirectional",
"valueType": "object",
"constraints": {
"holdMs": {
"minimum": 100,
"maximum": 5000
}
},
"mutatesState": true,
"createdAt": "2026-05-21T00:00:00.000Z",
"updatedAt": "2026-05-21T00:00:00.000Z"
},
{
"capabilityId": "cap_01J00000000000000000000011",
"resourceId": "res_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"name": "power.set_voltage",
"description": "Set simulated output voltage.",
"direction": "input",
"valueType": "number",
"unit": "V",
"constraints": {
"minimum": 0,
"maximum": 12
},
"mutatesState": true,
"createdAt": "2026-05-21T00:00:00.000Z",
"updatedAt": "2026-05-21T00:00:00.000Z"
}
],
"wiringConfig": {
"wiringConfigId": "wir_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"gatewaySessionId": "gws_01J00000000000000000000010",
"name": "M0 simulated DUT power wiring",
"status": "active",
"connections": [
{
"from": {
"resourceId": "res_01J00000000000000000000010",
"port": "out0",
"capabilityId": "cap_01J00000000000000000000011"
},
"to": {
"resourceId": "res_01J00000000000000000000011",
"port": "vin"
},
"mode": "exclusive"
}
],
"constraints": {
"oneActiveConfigPerResourceGroup": true,
"cyclesAllowed": false
},
"createdAt": "2026-05-21T00:00:00.000Z",
"updatedAt": "2026-05-21T00:00:00.000Z"
},
"patchPanelStatus": {
"patchPanelStatusId": "pps_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"gatewaySessionId": "gws_01J00000000000000000000010",
"wiringConfigId": "wir_01J00000000000000000000010",
"serviceId": "hwlab-patch-panel",
"state": "active",
"environment": "dev",
"activeConnections": [
{
"fromResourceId": "res_01J00000000000000000000010",
"fromPort": "out0",
"toResourceId": "res_01J00000000000000000000011",
"toPort": "vin"
}
],
"observedAt": "2026-05-21T00:00:01.000Z",
"metadata": {
"connectionCount": 1
}
},
"hardwareOperation": {
"operationId": "op_01J00000000000000000000010",
"projectId": "prj_01J00000000000000000000010",
"gatewaySessionId": "gws_01J00000000000000000000010",
"agentSessionId": "ags_01J00000000000000000000010",
"workerSessionId": "wks_01J00000000000000000000010",
"resourceId": "res_01J00000000000000000000010",
"capabilityId": "cap_01J00000000000000000000010",
"requestedBy": "usr_01J00000000000000000000010",
"input": {
"cycle": true,
"holdMs": 250
},
"output": {
"powerState": "on"
},
"status": "succeeded",
"environment": "dev",
"requestedAt": "2026-05-21T00:00:03.000Z",
"startedAt": "2026-05-21T00:00:04.000Z",
"completedAt": "2026-05-21T00:00:05.000Z",
"updatedAt": "2026-05-21T00:00:05.000Z"
},
"traceEvents": []
}