One thing I know is when you reply you will reply with honesty. :) When doing low-code API it is hard to describe but I did a bit more online Googling and found a video by Brian May which showed how to see the source code for the low-code. Hope this is what you are asking to see.
Code: Select all
{
"apiFileID": "baa4b272-05eb-4747-bda2-c85466520de2",
"routes": [
{
"apiRouteID": "d97772a2-f012-4d7e-9126-92bda16d681b",
"name": "Get List",
"enableCors": true,
"method": "get",
"path": "/shoppingLists",
"inputs": [
{
"type": "string",
"from": "query",
"name": "countOnly",
"description": "Send yes to only return the total count of the matching records",
"example": "",
"multipleValues": false
},
{
"type": "date",
"from": "query",
"name": "needByDate",
"description": "Filter by due by date.",
"example": "",
"required": false
}
],
"summary": "Get shopping lists",
"tag": "ShoppingList",
"description": "Get shopping lists by criteria",
"outputdescription": "Returns an array of shopping list and count if requested.",
"outputs": [
{
"type": "integer",
"name": "totalCount"
},
{
"type": "object",
"name": "data",
"multipleValues": true,
"children": [
{
"type": "integer",
"name": "cartID"
},
{
"type": "string",
"name": "description"
},
{
"type": "string",
"name": "type"
},
{
"type": "string",
"name": "plant"
},
{
"type": "string",
"name": "user"
},
{
"type": "date",
"name": "needByDate"
}
]
},
{
"type": "string",
"name": "buyerCode"
}
],
"subcategory": "",
"steps": [
{
"text": "if needByDate passed",
"answers": {
"plugin": "Conditions:comparison",
"variable": "input[\"needByDate\"]",
"type": "truthy",
"and-or": ""
},
"isStructureStart": true
},
{
"text": "Get count of needbyDate list rows",
"answers": {
"plugin": "Database:get-record-count",
"tables": "shopping_cart_header",
"criteria": "needByDate = ? AND type = 'L'",
"parameter": "input[\"needByDate\"]",
"destination": "API output",
"api_output": "output[\"totalCount\"]"
}
},
{
"isStructureEnd": true
},
{
"text": "Otherwise",
"answers": {
"plugin": "Conditions:else"
},
"isStructureStart": true
},
{
"text": "Get count of all list rows",
"answers": {
"plugin": "Database:get-record-count",
"tables": "shopping_cart_header",
"criteria": "type = 'L'",
"destination": "API output",
"api_output": "output[\"totalCount\"]"
}
},
{
"isStructureEnd": true
},
{
"text": "if not requested countOnly",
"answers": {
"plugin": "Conditions:comparison",
"variable": "input[\"countOnly\"]",
"type": "!=",
"value": "'yes'",
"and-or": ""
},
"isStructureStart": true
},
{
"text": "if needByDate passed",
"answers": {
"plugin": "Conditions:comparison",
"variable": "input[\"needByDate\"]",
"type": "truthy",
"and-or": ""
},
"isStructureStart": true
},
{
"text": "Get list rows by needByDate",
"answers": {
"plugin": "Database:get-records",
"tables": "shopping_cart_header",
"columns": "cartID,description,type,plant,user,buyerCode,needByDate",
"criteria": "needByDate = ? AND type = 'L'",
"parameter": "input[\"needByDate\"]",
"add_order_by": false,
"limit": "",
"skip": "",
"destination": "API output",
"api_output": "output[\"data\"]"
}
},
{
"isStructureEnd": true
},
{
"text": "Otherwise",
"answers": {
"plugin": "Conditions:else"
},
"isStructureStart": true
},
{
"text": "Get all list rows",
"answers": {
"plugin": "Database:get-records",
"tables": "shopping_cart_header",
"columns": "cartID,description,type,plant,user,buyerCode,needByDate",
"criteria": "type = 'L'",
"add_order_by": false,
"limit": "100",
"skip": "",
"destination": "API output",
"api_output": "output[\"data\"]"
}
},
{
"isStructureEnd": true
},
{
"isStructureEnd": true
}
]
},
{
"apiRouteID": "c20979db-330b-48d1-bb28-3be203be087f",
"name": "Get List by number",
"enableCors": true,
"method": "get",
"path": "/shoppinglist/:cartid",
"inputs": [
{
"name": "cartid",
"type": "string",
"from": "path",
"required": true
}
],
"summary": "Get list by number",
"outputs": [
{
"type": "object",
"name": "data",
"children": [
{
"type": "integer",
"name": "cartID"
},
{
"type": "string",
"name": "description"
},
{
"type": "string",
"name": "type"
},
{
"type": "string",
"name": "plant"
},
{
"type": "string",
"name": "user"
},
{
"type": "string",
"name": "buyerCode"
},
{
"type": "date",
"name": "needByDate"
}
]
}
],
"subcategory": "",
"steps": [
{
"text": "Get record",
"answers": {
"plugin": "Database:get-record",
"tables": "shopping_cart_header",
"columns": "cartID,description,type,plant,user,buyerCode,needByDate",
"criteria": "cartID = ?",
"parameter": "input[\"cartid\"]",
"destination": "API output",
"api_output": "output[\"data\"]"
}
}
]
}
]
}