FEAT: update deleteTable endpoint to use pipelineId in path and refactor parameters

This commit is contained in:
viniciusgadea
2026-04-02 17:28:42 -03:00
parent 8a9b58b612
commit efb0b58648
2 changed files with 13 additions and 20 deletions
+9 -17
View File
@@ -4705,11 +4705,19 @@
]
}
},
"/platform/inputs/{inputId}/tables/{tableName}": {
"/platform/pipelines/{pipelineId}/inputs/{inputId}": {
"delete": {
"operationId": "PlatformApiController_deleteTable",
"summary": "Mark a table as deleted and delete its associated job via platform-api",
"parameters": [
{
"name": "pipelineId",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "inputId",
"required": true,
@@ -4717,22 +4725,6 @@
"schema": {
"type": "string"
}
},
{
"name": "tableName",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "pipelineId",
"required": true,
"in": "query",
"schema": {
"type": "string"
}
}
],
"responses": {
@@ -965,15 +965,16 @@ export class PlatformApiController {
);
}
@Delete('inputs/:inputId/tables/:tableName')
@Delete('pipelines/:pipelineId/inputs/:inputId')
@ApiOperation({ summary: 'Mark a table as deleted and delete its associated job via platform-api' })
@RequireAllPermissions(PERMISSIONS_GROUPS.PIPELINE.permissions.DELETE)
async deleteTable(
@Param('pipelineId') pipelineId: string,
@Param('inputId') inputId: string,
@Param('tableName') tableName: string,
@Query('pipelineId') pipelineId: string,
@Body() body: { table_name: string },
@User() user: RequestUser,
) {
const tableName = body.table_name;
const info = {
customer_id: user.customer_id,
customer: user.customer_name,