@openfn/language-msgraph 0.7.6 → 0.7.7
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/ast.json +13 -2
- package/package.json +2 -2
package/ast.json
CHANGED
|
@@ -734,7 +734,7 @@
|
|
|
734
734
|
"operation"
|
|
735
735
|
],
|
|
736
736
|
"docs": {
|
|
737
|
-
"description": "
|
|
737
|
+
"description": "Iterates over an array of items and invokes an operation upon each one, where the state\nobject is _scoped_ so that state.data is the item under iteration.\nThe rest of the state object is untouched and can be referenced as usual.\nYou can pass an array directly, or use lazy state or a JSONPath string to\nreference a slice of state.",
|
|
738
738
|
"tags": [
|
|
739
739
|
{
|
|
740
740
|
"title": "public",
|
|
@@ -748,7 +748,18 @@
|
|
|
748
748
|
},
|
|
749
749
|
{
|
|
750
750
|
"title": "example",
|
|
751
|
-
"description": "each(\
|
|
751
|
+
"description": "each(\n $.data,\n // Inside the callback operation, `$.data` is scoped to the item under iteration\n insert(\"patient\", {\n patient_name: $.data.properties.case_name,\n patient_id: $.data.case_id,\n })\n);",
|
|
752
|
+
"caption": "Using lazy state ($) to iterate over items in state.data and pass each into an \"insert\" operation"
|
|
753
|
+
},
|
|
754
|
+
{
|
|
755
|
+
"title": "example",
|
|
756
|
+
"description": "each(\n $.data,\n insert(\"patient\", (state) => ({\n patient_id: state.data.case_id,\n ...state.data\n }))\n);",
|
|
757
|
+
"caption": "Iterate over items in state.data and pass each one into an \"insert\" operation"
|
|
758
|
+
},
|
|
759
|
+
{
|
|
760
|
+
"title": "example",
|
|
761
|
+
"description": "each(\n \"$.data[*]\",\n insert(\"patient\", (state) => ({\n patient_name: state.data.properties.case_name,\n patient_id: state.data.case_id,\n }))\n);",
|
|
762
|
+
"caption": "Using JSON path to iterate over items in state.data and pass each one into an \"insert\" operation"
|
|
752
763
|
},
|
|
753
764
|
{
|
|
754
765
|
"title": "param",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openfn/language-msgraph",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.7",
|
|
4
4
|
"description": "Microsoft Graph Language Pack for OpenFn",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"undici": "^5.28.4",
|
|
24
24
|
"xlsx": "https://cdn.sheetjs.com/xlsx-0.20.0/xlsx-0.20.0.tgz",
|
|
25
|
-
"@openfn/language-common": "2.1.
|
|
25
|
+
"@openfn/language-common": "2.1.1"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@openfn/simple-ast": "0.4.1",
|