Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

Proposal for New Api definition #42

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add files via upload
  • Loading branch information
ivomp authored Nov 19, 2021
commit 3725f596aeab98a4c0ff3fefb85f7381978e3ead
64 changes: 64 additions & 0 deletions api/BrowseNodes_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "browseNodes",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"startNodeId": "ns=2;i=16397",
"browseDepth": 1
}
/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "browseNodes",
"status":{
"isSuccessfull": false,
"message": "One or more nodes does not exists"
},
"discoveredNode": {
"nodeId": "ns=2;i=16397",
"childNodes": [
{
"nodeId": "ns=4;i=16395",
"nodeType": null,
"nodeClass": null,
"dataType": null,
"value": null,
"valueRank": null,
"accessLevel": null,
"userAccessLevel": null,
"minimumSamplingInterval": null,
"historizing": null,
"arrayDimensions": {
"dataType": null,
"values": [ ]
},
"childNodes": [
{
"nodeId": "ns=5;i=16393",
"nodeType": null,
"nodeClass": null,
"dataType": null,
"value": null,
"valueRank": null,
"accessLevel": null,
"userAccessLevel": null,
"minimumSamplingInterval": null,
"historizing": null,
"arrayDimensions": {
"dataType": null,
"values": [ ]
}
"childNodes": [

]
}
]
}
]
}
}
71 changes: 71 additions & 0 deletions api/Call_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "call",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"nodes": [
{
"nodeId": "ns=2;i=16397",
"inputArguments": [
{
"key": "argumentName1",
"value": "Value"
}
]
},
{
"nodeId": "ns=3;i=16398",
"inputArguments": [
{
"key": "argumentName2",
"value": "Value"
}
]
}
]
}

/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "call",
"status":{
"isSuccessfull": false,
"message": "One or more nodes does not exists"
},
"nodeValues": [
{
"nodeId":"ns=2;i=16397",
"status": {
"isSuccessfull": true,
"message": null
},
"outputArguments": [
{
"key": "argumentName1",
"value": "Value",
"dataType": "String | Int32 | Boolean etc."
}
]
},
{
"nodeId":"ns=3;i=16398",
"status": {
"isSuccessfull": false,
"message": "No such node exists"
},
"outputArguments": [
{
"key": "argumentName2",
"value": "Value",
"dataType": "String | Int32 | Boolean etc."
}
]
}
]
}
27 changes: 27 additions & 0 deletions api/DiscoveryEndpoints_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "discoverEndpoints",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/"
}
/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "discoverEndpoints",
"status":{
"isSuccessfull": false,
"message": "Endpoint does not exists"
},
"endpoints":[
{
"EndpointUrl":"",
"SecurityMode":" Invalid" /* None, Sign, SignAndEncrypt */,
"SecurityLevel": 1
}
]
}
10 changes: 10 additions & 0 deletions api/NotificationMessage.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamp": "2021-10-26T09:52:03+00:00",
"messageType": "notification",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"nodeId":"ns=2;i=16397",
"data": {
/*Not defined yet*/
}
}
53 changes: 53 additions & 0 deletions api/ReadNodes_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "readNodes", /* Always does a read on the 'Value' attribute */
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"nodeIds":[
"ns=2;i=16397",
"ns=2;i=16398"
]
}
/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "readNodes",
"status":{
"isSuccessfull": false,
"message": "One or more nodes does not exists"
},
"nodes": [
{
"nodeId": "ns=2;i=16397",
"status": {
"isSuccessfull": true,
"message": null
},
"nodeType": null,
"nodeClass": null,
"dataType": null,
"value": null,
"valueRank": null,
"accessLevel": null,
"userAccessLevel": null,
"minimumSamplingInterval": null,
"historizing": null,
"arrayDimensions": {
"dataType": null,
"values": [ ]
}
},
{
"nodeId": "ns=2;i=16398",
"status": {
"isSuccessfull": false,
"message": "Node does not exists"
}
}
]
}
44 changes: 44 additions & 0 deletions api/ReadValues_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "readValues", /* Always does a read on the 'Value' attribute */
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"nodeIds": [
"ns=2;i=16397",
"ns=3;i=16398"
]
}
/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "readValues",
"status":{
"isSuccessfull": false,
"message": "One or more nodes does not exists"
},
"nodeValues": [
{
"nodeId":"ns=2;i=16397",
"status": {
"isSuccessfull": true,
"message": null
},
"value" : "What will be a good example?",
"dataType": "string"
},
{
"nodeId":"ns=3;i=16398",
"status": {
"isSuccessfull": false,
"message": "No such node exists"
},
"value" : null,
"dataType": null
}
]
}
1 change: 1 addition & 0 deletions api/ServerDiscovery_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
GDS is Not implemented yet
48 changes: 48 additions & 0 deletions api/SubscribeToNodes_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "subscribeToNodes",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"monitoredItems": [
{
"nodeId": "ns=2;i=16397",
"samplingInterval": 100,
"publishingInterval": 200
},
{
"nodeId": "ns=3;i=16398",
"samplingInterval": 10,
"publishingInterval": 1000
}
]
}
/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "subscribeToNodes",
"status":{
"isSuccessfull": false,
"message": "One or more nodes does not exists"
},
"monitoredItems": [
{
"nodeId":"ns=2;i=16397",
"status": {
"isSuccessfull": true,
"message": null
}
},
{
"nodeId":"ns=3;i=16398",
"status": {
"isSuccessfull": false,
"message": "No such node exists"
}
}
]
}
15 changes: 15 additions & 0 deletions api/TelemetaryMessage.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamp": "2021-10-26T09:52:03+00:00",
"messageType": "telemetry",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"nodeId":"ns=2;i=16397",
"data": {
"value": { ... },/* dynamic type */
"statusCode": "",
"dataType": "",
"sequenceNr": 2,
"sourceTimestamp": "2021-10-26T09:52:00+00:00", /* Time plc made the reading */
"serverTimestamp": "2021-10-26T09:52:02+00:00" /* Time the server sent the reading */
}
}
40 changes: 40 additions & 0 deletions api/UnSubscribeFromNodes_Request_And_Response.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"id": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"requestType": "unsubscribeFromNodes",
"endpointUrl": "opc.tcp://opcuaserverintegration:52210/",
"monitoredItems": [
"ns=2;i=16397",
"ns=3;i=16398"
]
}
/* Response */
{
"requestId": "7cd70b85-2939-480d-917f-5d62c7f6b1b2", // requestId
"connectorId": "AA2A77F6-2246-4A60-BF3B-E2B322BEDAE5",
"timestamps": {
"receivedTime": "2021-10-26T09:50:29+00:00",/* Time we received the command*/
"responseTime": "2021-10-26T09:51:00+00:00" /* Time we are responding with a result*/
},
"requestType": "unsubscribeFromNodes",
"status":{
"isSuccessfull": false,
"message": "One or more nodes does not exists"
},
"monitoredItems": [
{
"nodeId":"ns=2;i=16397",
"status": {
"isSuccessfull": true,
"message": null
}
},
{
"nodeId":"ns=3;i=16398",
"status": {
"isSuccessfull": false,
"message": "Unable to unsubscribe node"
}
}
]
}
Loading