We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1507c18 commit ddbabc5Copy full SHA for ddbabc5
transforms/filter/api.graphql
@@ -26,3 +26,17 @@ type Query {
26
"""
27
)
28
}
29
+
30
+# jsonata transforms provdes an alternate method for filtering
31
+# customer_1 uses the [ ... ] filter to return all "customers" ($) that
32
+# contain name = the argument name
33
+# jsonata has quirks: if you leave out the outer []
34
35
+extend type Query {
36
+ customer_1(name: String!): [Customer]
37
+ @rest(
38
+ endpoint: "https://sample-api.us-east-a.apiconnect.automation.ibm.com/api/customers"
39
+ transforms: [ { editor:"""jsonata:$[name = $get("name") ]"""}
40
+])
41
42
+}
0 commit comments