Skip to content

Commit 156dfaa

Browse files
committed
Fixed json example in overview
1 parent 2ac8d2a commit 156dfaa

File tree

1 file changed

+36
-13
lines changed

1 file changed

+36
-13
lines changed

docs/Overview.md

+36-13
Original file line numberDiff line numberDiff line change
@@ -115,26 +115,26 @@ curl -X POST "https://your.server.com/iot/logic/flow/create" \
115115
-H "Content-Type: application/json" \
116116
-H "Authorization: NVX hash_value" \
117117
-d '{
118-
"flow": { # Flow entity creation
118+
"flow": {
119119
"title": "Basic Temperature Monitoring",
120-
"enabled": true, # If true, the flow starts to process data immediately after creation
121-
"nodes": [ # Node entity creation right inside new flow
120+
"enabled": true,
121+
"nodes": [
122122
{
123-
"id": 1, # First node creation with an ID unique within a flow
123+
"id": 1,
124124
"type": "data_source",
125125
"enabled": true,
126-
"data": { # Node-specific parameters, depend on node type
126+
"data": {
127127
"title": "Fleet Vehicles",
128-
"sources": [394892, 394893, 394894] # Actual data sources from your accountm can be found in Devices and Settings
128+
"sources": [394892, 394893, 394894]
129129
},
130-
"view": { # First node postion, defining the display in UI
130+
"view": {
131131
"position": {
132132
"x": 50,
133133
"y": 100
134134
}
135135
}
136136
},
137-
{ # Second node creation
137+
{
138138
"id": 2,
139139
"type": "initiate_attributes",
140140
"data": {
@@ -148,32 +148,32 @@ curl -X POST "https://your.server.com/iot/logic/flow/create" \
148148
}
149149
]
150150
},
151-
"view": { # Second node postion, defining the display in UI
151+
"view": {
152152
"position": {
153153
"x": 300,
154154
"y": 100
155155
}
156156
}
157157
},
158158
{
159-
"id": 3, # third node creation
159+
"id": 3,
160160
"type": "output_endpoint",
161161
"enabled": true,
162162
"data": {
163163
"title": "Navixy Platform",
164164
"output_endpoint_type": "output_navixy"
165165
},
166-
"view": { # Third node postion, defining the display in UI
166+
"view": {
167167
"position": {
168168
"x": 550,
169169
"y": 100
170170
}
171171
}
172172
}
173173
],
174-
"edges": [ # Transitions that connect nodes in a flow
174+
"edges": [
175175
{
176-
"from": 1, # Notice, that nodes are referenced by their IDs
176+
"from": 1,
177177
"to": 2
178178
},
179179
{
@@ -192,6 +192,29 @@ Response (example):
192192
"id": 123
193193
}
194194
```
195+
196+
### Parameters explained
197+
198+
* **Flow entity**: The main container defining a complete data processing pipeline
199+
* `title`: Names your flow for easier identification
200+
* `enabled`: When true, flow begins processing data immediately after creation
201+
* **Nodes**: Functional components that each handle a specific step in data processing
202+
* **Node 1 (data_source)**:
203+
* Entry point collecting data from devices (IDs: 394892, 394893, 394894)
204+
* Unique ID within the flow for connection references
205+
* Position coordinates control UI display location
206+
* **Node 2 (initiate_attributes)**:
207+
* Transforms data with custom calculations
208+
* Creates new "temperature_f" attribute using formula
209+
* Uses timestamps for data validity tracking
210+
* **Node 3 (output_endpoint)**:
211+
* Destination for processed data
212+
* Type "output_navixy" sends to Navixy platform
213+
* Final step in the processing pipeline
214+
* **Edges**: Define connections between nodes
215+
* Reference nodes by their IDs to create the processing sequence
216+
* Create a clear path for data to follow from source to destination
217+
195218
<!-- theme: success -->
196219
> This single request creates a complete flow that:
197220
> 1. Collects data from three specific devices (IDs: 394892, 394893, 394894)

0 commit comments

Comments
 (0)