curl --request PUT \
--url https://apiweb.mile.app/api/v3/export-config/{exportConfigId}/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"_id": "67459c0b9778e36baa076802",
"name": "Report Daily",
"description": "Template for daily report with bill item detail",
"collection": "task",
"fields": [
{
"component": "input",
"id": "flow",
"inputType": "string",
"source": "reservedKey",
"title": "Flow",
"uniqueTitle": "Flow"
},
{
"component": "input",
"id": "_id",
"inputType": "string",
"source": "reservedKey",
"title": "Id",
"uniqueTitle": "Id"
},
{
"component": "input",
"id": "hub",
"inputType": "string",
"source": "reservedKey",
"title": "Hub",
"uniqueTitle": "Hub"
},
{
"component": "input",
"id": "title",
"inputType": "string",
"source": "reservedKey",
"title": "Title",
"uniqueTitle": "Title"
},
{
"component": "input",
"id": "status",
"inputType": "string",
"source": "reservedKey",
"title": "Status",
"uniqueTitle": "Status"
},
{
"component": "input",
"id": "orderNumber",
"title": "Order Number",
"inputType": "string",
"default": null,
"routeAs": null,
"showAs": "title",
"required": false,
"visible": true,
"page": "page0",
"flowId": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"flowName": [
"Export Bill",
"Flow A",
"Flow B",
"Flow C"
],
"uniqueTitle": "Order Number"
},
{
"component": "bill",
"id": "billItem",
"title": "Bill Item",
"addNew": true,
"required": false,
"value": null,
"editable": [],
"costs": [
"Discount",
"Shipping Cost"
],
"visible": true,
"masterItems": [
{
"name": "Snack",
"unit_price": 10000
},
{
"name": "Cold Drink",
"unit_price": 5000
},
{
"name": "Bread",
"unit_price": 7000
},
{
"name": "Egg",
"unit_price": 2500
}
],
"masterCosts": [
{
"type": "number",
"name": "Discount",
"amount": 10000
},
{
"type": "number",
"name": "Shipping Cost",
"amount": 7000
}
],
"qtyRule": null,
"page": "page1",
"flowId": [
"66a988d53ae08a7ab52867c2"
],
"flowName": [
"Export Bill"
],
"additionalField": [
"billItem.Discount",
"billItem.Shipping Cost",
"billItem.totalCost"
],
"uniqueTitle": "Bill Item"
}
],
"flowIds": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"organizationId": "66791b2bf001a712b77b3622",
"updatedTime": "2024-11-26T09:59:39.860000Z",
"createdTime": "2024-11-26T09:59:39.860000Z"
}
'{
"status": true,
"code": 200,
"message": "Export Config has been updated successfully.",
"data": {
"_id": "67459c0b9778e36baa076802",
"name": "Report Daily",
"description": "Template for daily report with bill item detail",
"collection": "task",
"fields": [
{
"component": "input",
"id": "flow",
"inputType": "string",
"source": "reservedKey",
"title": "Flow",
"uniqueTitle": "Flow"
},
{
"component": "input",
"id": "_id",
"inputType": "string",
"source": "reservedKey",
"title": "Id",
"uniqueTitle": "Id"
},
{
"component": "input",
"id": "hub",
"inputType": "string",
"source": "reservedKey",
"title": "Hub",
"uniqueTitle": "Hub"
},
{
"component": "input",
"id": "title",
"inputType": "string",
"source": "reservedKey",
"title": "Title",
"uniqueTitle": "Title"
},
{
"component": "input",
"id": "status",
"inputType": "string",
"source": "reservedKey",
"title": "Status",
"uniqueTitle": "Status"
},
{
"component": "input",
"id": "orderNumber",
"title": "Order Number",
"inputType": "string",
"default": null,
"routeAs": null,
"showAs": "title",
"required": false,
"visible": true,
"page": "page0",
"flowId": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"flowName": [
"Export Bill",
"Flow A",
"Flow B",
"Flow C"
],
"uniqueTitle": "Order Number"
},
{
"component": "bill",
"id": "billItem",
"title": "Bill Item",
"addNew": true,
"required": false,
"value": null,
"editable": [],
"costs": [
"Discount",
"Shipping Cost"
],
"visible": true,
"masterItems": [
{
"name": "Snack",
"unit_price": 10000
},
{
"name": "Cold Drink",
"unit_price": 5000
},
{
"name": "Bread",
"unit_price": 7000
},
{
"name": "Egg",
"unit_price": 2500
}
],
"masterCosts": [
{
"type": "number",
"name": "Discount",
"amount": 10000
},
{
"type": "number",
"name": "Shipping Cost",
"amount": 7000
}
],
"qtyRule": null,
"page": "page1",
"flowId": [
"66a988d53ae08a7ab52867c2"
],
"flowName": [
"Export Bill"
],
"additionalField": [
"billItem.Discount",
"billItem.Shipping Cost",
"billItem.totalCost"
],
"uniqueTitle": "Bill Item"
}
],
"flowIds": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"organizationId": "66791b2bf001a712b77b3622",
"updatedTime": "2024-11-26T10:06:27.615000Z",
"createdTime": "2024-11-26T09:59:39.860000Z"
}
}curl --request PUT \
--url https://apiweb.mile.app/api/v3/export-config/{exportConfigId}/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"_id": "67459c0b9778e36baa076802",
"name": "Report Daily",
"description": "Template for daily report with bill item detail",
"collection": "task",
"fields": [
{
"component": "input",
"id": "flow",
"inputType": "string",
"source": "reservedKey",
"title": "Flow",
"uniqueTitle": "Flow"
},
{
"component": "input",
"id": "_id",
"inputType": "string",
"source": "reservedKey",
"title": "Id",
"uniqueTitle": "Id"
},
{
"component": "input",
"id": "hub",
"inputType": "string",
"source": "reservedKey",
"title": "Hub",
"uniqueTitle": "Hub"
},
{
"component": "input",
"id": "title",
"inputType": "string",
"source": "reservedKey",
"title": "Title",
"uniqueTitle": "Title"
},
{
"component": "input",
"id": "status",
"inputType": "string",
"source": "reservedKey",
"title": "Status",
"uniqueTitle": "Status"
},
{
"component": "input",
"id": "orderNumber",
"title": "Order Number",
"inputType": "string",
"default": null,
"routeAs": null,
"showAs": "title",
"required": false,
"visible": true,
"page": "page0",
"flowId": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"flowName": [
"Export Bill",
"Flow A",
"Flow B",
"Flow C"
],
"uniqueTitle": "Order Number"
},
{
"component": "bill",
"id": "billItem",
"title": "Bill Item",
"addNew": true,
"required": false,
"value": null,
"editable": [],
"costs": [
"Discount",
"Shipping Cost"
],
"visible": true,
"masterItems": [
{
"name": "Snack",
"unit_price": 10000
},
{
"name": "Cold Drink",
"unit_price": 5000
},
{
"name": "Bread",
"unit_price": 7000
},
{
"name": "Egg",
"unit_price": 2500
}
],
"masterCosts": [
{
"type": "number",
"name": "Discount",
"amount": 10000
},
{
"type": "number",
"name": "Shipping Cost",
"amount": 7000
}
],
"qtyRule": null,
"page": "page1",
"flowId": [
"66a988d53ae08a7ab52867c2"
],
"flowName": [
"Export Bill"
],
"additionalField": [
"billItem.Discount",
"billItem.Shipping Cost",
"billItem.totalCost"
],
"uniqueTitle": "Bill Item"
}
],
"flowIds": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"organizationId": "66791b2bf001a712b77b3622",
"updatedTime": "2024-11-26T09:59:39.860000Z",
"createdTime": "2024-11-26T09:59:39.860000Z"
}
'{
"status": true,
"code": 200,
"message": "Export Config has been updated successfully.",
"data": {
"_id": "67459c0b9778e36baa076802",
"name": "Report Daily",
"description": "Template for daily report with bill item detail",
"collection": "task",
"fields": [
{
"component": "input",
"id": "flow",
"inputType": "string",
"source": "reservedKey",
"title": "Flow",
"uniqueTitle": "Flow"
},
{
"component": "input",
"id": "_id",
"inputType": "string",
"source": "reservedKey",
"title": "Id",
"uniqueTitle": "Id"
},
{
"component": "input",
"id": "hub",
"inputType": "string",
"source": "reservedKey",
"title": "Hub",
"uniqueTitle": "Hub"
},
{
"component": "input",
"id": "title",
"inputType": "string",
"source": "reservedKey",
"title": "Title",
"uniqueTitle": "Title"
},
{
"component": "input",
"id": "status",
"inputType": "string",
"source": "reservedKey",
"title": "Status",
"uniqueTitle": "Status"
},
{
"component": "input",
"id": "orderNumber",
"title": "Order Number",
"inputType": "string",
"default": null,
"routeAs": null,
"showAs": "title",
"required": false,
"visible": true,
"page": "page0",
"flowId": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"flowName": [
"Export Bill",
"Flow A",
"Flow B",
"Flow C"
],
"uniqueTitle": "Order Number"
},
{
"component": "bill",
"id": "billItem",
"title": "Bill Item",
"addNew": true,
"required": false,
"value": null,
"editable": [],
"costs": [
"Discount",
"Shipping Cost"
],
"visible": true,
"masterItems": [
{
"name": "Snack",
"unit_price": 10000
},
{
"name": "Cold Drink",
"unit_price": 5000
},
{
"name": "Bread",
"unit_price": 7000
},
{
"name": "Egg",
"unit_price": 2500
}
],
"masterCosts": [
{
"type": "number",
"name": "Discount",
"amount": 10000
},
{
"type": "number",
"name": "Shipping Cost",
"amount": 7000
}
],
"qtyRule": null,
"page": "page1",
"flowId": [
"66a988d53ae08a7ab52867c2"
],
"flowName": [
"Export Bill"
],
"additionalField": [
"billItem.Discount",
"billItem.Shipping Cost",
"billItem.totalCost"
],
"uniqueTitle": "Bill Item"
}
],
"flowIds": [
"66a988d53ae08a7ab52867c2",
"66c6a05440d39b2616275622",
"66c6a05c40d39b2616275624",
"66c6a06412d3f54e2f425e22"
],
"organizationId": "66791b2bf001a712b77b3622",
"updatedTime": "2024-11-26T10:06:27.615000Z",
"createdTime": "2024-11-26T09:59:39.860000Z"
}
}Use a valid Bearer token to authenticate.
Unique identifier for the export config that generated by system.
Example: 642634bde1428d414838c882
The name of export config. Name must be unique.
Example: Report Daily
The collection from which the data will be exported.
Example: task
The flow identifier used to filter the components refers only to the selected flow IDs. Use Flow /flows API to get the list of flow id.
Example: ['66a988d53ae08a7ab52867c2']
The optional fields to be included in the exported data that ref to Flow reserved key and User fields. To see the details of reserved key of task, please follow this link