-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmesg.yml
30 lines (30 loc) · 908 Bytes
/
mesg.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name: GraphQL Fields to MongoDB Selections
description: Convert GraphQL fields to MongoDB selections
# this service is compatible with the following services:
# - https://github.com/ilgooz/service-graphql
# - https://github.com/ilgooz/service-mongo
sid: graphql-fields-to-mongo-selections
tasks:
convert:
description: Convert GraphQL fields to MongoDB selections
inputs:
fields:
description: "GraphQL fields. e.g.: '[ { name: 'a', fields: [ { name: 'b' } ] }, { name: 'c' } ]'"
type: Object
repeated: true
object:
name:
type: String
fields:
type: Any
optional: true
outputs:
success:
data:
data:
description: "MongoDB selection format. e.g.: '{ a: { b: 1 }, c: 2 }'"
type: Object
failure:
data:
message:
type: String