@itentialopensource/mongo-crud-operations
Version:
Perform CRUD operations on MongoDB
956 lines • 27.3 kB
JSON
{
"id": "600f181d5a09e2458596a7ae",
"bindingSchema": {
"properties": {
"adapterName": {
"binding:method": "GET",
"binding:link": {
"$ref": "/links",
"rel": "collection"
},
"binding:target": {
"propertyPointer": "/enum"
},
"binding:hyperSchema": {
"type": "object",
"base": "/health",
"links": [
{
"rel": "collection",
"href": "/adapters",
"targetMediaType": "application/json",
"targetSchema": {
"$ref": "#"
},
"variables": []
}
]
},
"binding:source": {
"transformation": {
"name": "Mongo_CRUD_Filter",
"description": "",
"incoming": [
{
"$id": "results",
"type": "array",
"required": []
}
],
"outgoing": [
{
"$id": "output",
"type": "array"
}
],
"steps": [
{
"id": 1,
"type": "method",
"library": "Array",
"method": "map",
"args": [
null,
"ƒ_map_1"
],
"view": {
"row": 1,
"col": 1
}
},
{
"id": 7,
"type": "assign",
"from": {
"location": "incoming",
"name": "results",
"ptr": ""
},
"to": {
"location": "method",
"name": 1,
"ptr": "/args/0/value"
}
},
{
"id": 8,
"type": "method",
"library": "Array",
"method": "filter",
"args": [
null,
"ƒ_query_1"
],
"view": {
"row": 1,
"col": 2
}
},
{
"id": 9,
"type": "assign",
"from": {
"location": "method",
"name": 1,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 8,
"ptr": "/args/0/value"
}
},
{
"id": 10,
"type": "assign",
"from": {
"location": "method",
"name": 8,
"ptr": "/return"
},
"to": {
"location": "outgoing",
"name": "output",
"ptr": ""
}
}
],
"functions": [
{
"incoming": [
{
"type": [
"array",
"boolean",
"number",
"integer",
"string",
"object",
"null"
],
"$id": "currentValue"
},
{
"title": "index",
"type": "number",
"optional": true,
"$id": "index"
},
{
"$id": "array",
"type": "array",
"required": [],
"optional": true
},
{
"$id": "thisArg",
"type": "object",
"properties": {},
"isContext": true,
"isThis": true,
"isIndexed": true
}
],
"outgoing": [
{
"title": "newValue",
"type": [
"array",
"boolean",
"number",
"integer",
"string",
"object",
"null"
],
"editable": true,
"$id": "newValue"
}
],
"functions": [],
"name": "ƒ_map_1",
"steps": [
{
"id": 1,
"type": "method",
"library": "Object",
"method": "getProperty",
"args": [
null,
"id"
],
"view": {
"row": 1,
"col": 1
}
},
{
"id": 2,
"type": "assign",
"from": {
"location": "incoming",
"name": "currentValue",
"ptr": ""
},
"to": {
"location": "method",
"name": 1,
"ptr": "/args/0/value"
}
},
{
"id": 12,
"type": "method",
"library": "Object",
"method": "getProperty",
"args": [
null,
"package_id"
],
"view": {
"row": 2,
"col": 1
}
},
{
"id": 13,
"type": "assign",
"from": {
"location": "incoming",
"name": "currentValue",
"ptr": ""
},
"to": {
"location": "method",
"name": 12,
"ptr": "/args/0/value"
}
},
{
"id": 14,
"type": "method",
"library": "Equality",
"method": "identity",
"args": [
null,
"@itentialopensource/adapter-db_mongo"
],
"view": {
"row": 3,
"col": 1
}
},
{
"id": 15,
"type": "assign",
"from": {
"location": "method",
"name": 12,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 14,
"ptr": "/args/0/value"
}
},
{
"id": 16,
"type": "method",
"library": "Conditional",
"method": "ternary",
"args": [
null,
null,
"nope"
],
"view": {
"row": 4,
"col": 1
}
},
{
"id": 17,
"type": "assign",
"from": {
"location": "method",
"name": 1,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 16,
"ptr": "/args/1/value"
}
},
{
"id": 18,
"type": "assign",
"from": {
"location": "method",
"name": 14,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 16,
"ptr": "/args/0/value"
}
},
{
"id": 19,
"type": "assign",
"from": {
"location": "method",
"name": 16,
"ptr": "/return"
},
"to": {
"location": "outgoing",
"name": "newValue",
"ptr": ""
}
}
],
"view": {
"col": 1,
"row": 6
},
"id": "ƒ_map_1",
"comments": []
},
{
"incoming": [
{
"type": [
"array",
"boolean",
"number",
"integer",
"string",
"object",
"null"
],
"$id": "element"
},
{
"title": "index",
"type": "number",
"optional": true,
"$id": "index"
},
{
"type": "array",
"$id": "array",
"optional": true
},
{
"$id": "thisArg",
"type": "object",
"properties": {},
"isContext": true,
"isThis": true,
"isIndexed": true
}
],
"outgoing": [
{
"title": "return",
"type": "boolean",
"$id": "return"
}
],
"functions": [],
"name": "ƒ_query_1",
"steps": [
{
"id": 3,
"type": "method",
"library": "Equality",
"method": "nonidentity",
"args": [
null,
"nope"
],
"view": {
"row": 1,
"col": 1
}
},
{
"id": 4,
"type": "assign",
"from": {
"location": "incoming",
"name": "element",
"ptr": ""
},
"to": {
"location": "method",
"name": 3,
"ptr": "/args/0/value"
}
},
{
"id": 5,
"type": "assign",
"from": {
"location": "method",
"name": 3,
"ptr": "/return"
},
"to": {
"location": "outgoing",
"name": "return",
"ptr": ""
}
}
],
"view": {
"col": 2,
"row": 6
},
"id": "ƒ_query_1",
"comments": []
}
],
"comments": [],
"view": {
"col": 2,
"row": 5
},
"created": "2023-06-13T18:36:42.839Z",
"createdBy": {
"_id": "638a63855d6a4bf97a05ecb1",
"provenance": "local_aaa",
"username": "admin@pronghorn"
},
"lastUpdated": "2023-06-13T18:36:42.839Z",
"lastUpdatedBy": {
"_id": "638a63855d6a4bf97a05ecb1",
"provenance": "local_aaa",
"username": "admin@pronghorn"
},
"version": "3.23.3-2022.1.14",
"tags": []
},
"transformationUrl": "/automation-studio/json-forms/runtransformation/618d452e813dfb015e6300e0"
}
}
}
},
"created": "2020-03-11T12:55:13.123Z",
"createdBy": "admin@pronghorn",
"description": null,
"lastUpdated": "2023-06-13T18:37:32.736Z",
"lastUpdatedBy": "admin@pronghorn",
"name": "Mongo_CRUD_Form",
"schema": {
"title": "Mongo_CRUD_Form",
"description": "",
"type": "object",
"required": [
"adapterName",
"collection",
"selectACrudOperation"
],
"properties": {
"adapterName": {
"type": "string",
"title": "Adapter Name",
"_id": "/properties/adapterName",
"description": "Please select your adapter mongo instance name",
"enum": []
},
"collection": {
"type": "string",
"title": "Collection",
"_id": "/properties/collection",
"description": "Collection Name"
},
"selectACrudOperation": {
"type": "string",
"title": "Select a CRUD operation",
"_id": "/properties/selectACrudOperation",
"description": "Select a CRUD operation",
"enum": [
"Create",
"Read",
"Update",
"Delete"
]
}
}
},
"struct": {
"nodeId": "91818615-cfa3-4e9e-833b-0ff1b80fc1cb",
"type": "array",
"items": [
{
"nodeId": "7a529b4c-fd0d-4671-b123-ba3c6a58422d",
"type": "string",
"title": "Adapter Name",
"description": "Please select your adapter mongo instance name",
"placeholder": "",
"required": true,
"enum": [],
"binding": true,
"rel": "collection",
"targetPointer": "/enum",
"method": "GET",
"base": "/health",
"href": "/adapters",
"sourcePointer": "",
"sourceKeyPointer": "",
"additionalBinding": [],
"transformation": {
"name": "Mongo_CRUD_Filter",
"description": "",
"incoming": [
{
"$id": "results",
"type": "array",
"required": []
}
],
"outgoing": [
{
"$id": "output",
"type": "array"
}
],
"steps": [
{
"id": 1,
"type": "method",
"library": "Array",
"method": "map",
"args": [
null,
"ƒ_map_1"
],
"view": {
"row": 1,
"col": 1
}
},
{
"id": 7,
"type": "assign",
"from": {
"location": "incoming",
"name": "results",
"ptr": ""
},
"to": {
"location": "method",
"name": 1,
"ptr": "/args/0/value"
}
},
{
"id": 8,
"type": "method",
"library": "Array",
"method": "filter",
"args": [
null,
"ƒ_query_1"
],
"view": {
"row": 1,
"col": 2
}
},
{
"id": 9,
"type": "assign",
"from": {
"location": "method",
"name": 1,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 8,
"ptr": "/args/0/value"
}
},
{
"id": 10,
"type": "assign",
"from": {
"location": "method",
"name": 8,
"ptr": "/return"
},
"to": {
"location": "outgoing",
"name": "output",
"ptr": ""
}
}
],
"functions": [
{
"incoming": [
{
"type": [
"array",
"boolean",
"number",
"integer",
"string",
"object",
"null"
],
"$id": "currentValue"
},
{
"title": "index",
"type": "number",
"optional": true,
"$id": "index"
},
{
"$id": "array",
"type": "array",
"required": [],
"optional": true
},
{
"$id": "thisArg",
"type": "object",
"properties": {},
"isContext": true,
"isThis": true,
"isIndexed": true
}
],
"outgoing": [
{
"title": "newValue",
"type": [
"array",
"boolean",
"number",
"integer",
"string",
"object",
"null"
],
"editable": true,
"$id": "newValue"
}
],
"functions": [],
"name": "ƒ_map_1",
"steps": [
{
"id": 1,
"type": "method",
"library": "Object",
"method": "getProperty",
"args": [
null,
"id"
],
"view": {
"row": 1,
"col": 1
}
},
{
"id": 2,
"type": "assign",
"from": {
"location": "incoming",
"name": "currentValue",
"ptr": ""
},
"to": {
"location": "method",
"name": 1,
"ptr": "/args/0/value"
}
},
{
"id": 12,
"type": "method",
"library": "Object",
"method": "getProperty",
"args": [
null,
"package_id"
],
"view": {
"row": 2,
"col": 1
}
},
{
"id": 13,
"type": "assign",
"from": {
"location": "incoming",
"name": "currentValue",
"ptr": ""
},
"to": {
"location": "method",
"name": 12,
"ptr": "/args/0/value"
}
},
{
"id": 14,
"type": "method",
"library": "Equality",
"method": "identity",
"args": [
null,
"@itentialopensource/adapter-db_mongo"
],
"view": {
"row": 3,
"col": 1
}
},
{
"id": 15,
"type": "assign",
"from": {
"location": "method",
"name": 12,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 14,
"ptr": "/args/0/value"
}
},
{
"id": 16,
"type": "method",
"library": "Conditional",
"method": "ternary",
"args": [
null,
null,
"nope"
],
"view": {
"row": 4,
"col": 1
}
},
{
"id": 17,
"type": "assign",
"from": {
"location": "method",
"name": 1,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 16,
"ptr": "/args/1/value"
}
},
{
"id": 18,
"type": "assign",
"from": {
"location": "method",
"name": 14,
"ptr": "/return"
},
"to": {
"location": "method",
"name": 16,
"ptr": "/args/0/value"
}
},
{
"id": 19,
"type": "assign",
"from": {
"location": "method",
"name": 16,
"ptr": "/return"
},
"to": {
"location": "outgoing",
"name": "newValue",
"ptr": ""
}
}
],
"view": {
"col": 1,
"row": 6
},
"id": "ƒ_map_1",
"comments": []
},
{
"incoming": [
{
"type": [
"array",
"boolean",
"number",
"integer",
"string",
"object",
"null"
],
"$id": "element"
},
{
"title": "index",
"type": "number",
"optional": true,
"$id": "index"
},
{
"type": "array",
"$id": "array",
"optional": true
},
{
"$id": "thisArg",
"type": "object",
"properties": {},
"isContext": true,
"isThis": true,
"isIndexed": true
}
],
"outgoing": [
{
"title": "return",
"type": "boolean",
"$id": "return"
}
],
"functions": [],
"name": "ƒ_query_1",
"steps": [
{
"id": 3,
"type": "method",
"library": "Equality",
"method": "nonidentity",
"args": [
null,
"nope"
],
"view": {
"row": 1,
"col": 1
}
},
{
"id": 4,
"type": "assign",
"from": {
"location": "incoming",
"name": "element",
"ptr": ""
},
"to": {
"location": "method",
"name": 3,
"ptr": "/args/0/value"
}
},
{
"id": 5,
"type": "assign",
"from": {
"location": "method",
"name": 3,
"ptr": "/return"
},
"to": {
"location": "outgoing",
"name": "return",
"ptr": ""
}
}
],
"view": {
"col": 2,
"row": 6
},
"id": "ƒ_query_1",
"comments": []
}
],
"comments": [],
"view": {
"col": 2,
"row": 5
},
"created": "2023-06-13T18:36:42.839Z",
"createdBy": {
"_id": "638a63855d6a4bf97a05ecb1",
"provenance": "local_aaa",
"username": "admin@pronghorn"
},
"lastUpdated": "2023-06-13T18:36:42.839Z",
"lastUpdatedBy": {
"_id": "638a63855d6a4bf97a05ecb1",
"provenance": "local_aaa",
"username": "admin@pronghorn"
},
"version": "3.23.3-2022.1.14",
"tags": []
}
},
{
"nodeId": "3572d822-02f1-46b2-8995-d28b49e0e19c",
"type": "string",
"title": "Collection",
"description": "Collection Name",
"placeholder": "",
"required": true
},
{
"nodeId": "fd0e03e7-68c4-42d7-9f36-7ae42787d6ed",
"type": "string",
"title": "Select a CRUD operation",
"description": "Select a CRUD operation",
"placeholder": "",
"required": true,
"enum": [
{
"id": "2f70c8f4-5052-45a2-8e82-5eaee80c3a1f",
"value": "Create"
},
{
"id": "ed0c372f-49cd-47c7-b8ec-eb40496af4a1",
"value": "Read"
},
{
"id": "d3760afa-ce18-4090-a936-a22a8aa07a68",
"value": "Update"
},
{
"id": "6e8f359a-6aff-4f62-82fe-750b4957f929",
"value": "Delete"
}
],
"binding": false,
"rel": "collection",
"targetPointer": "/enum"
}
]
},
"uiSchema": {},
"validationSchema": {},
"version": "2020.1"
}