diff --git a/src/main/resources/swagger.api/mod-fqm-manager.yaml b/src/main/resources/swagger.api/mod-fqm-manager.yaml index 7c44ea66e..0737d5ad0 100644 --- a/src/main/resources/swagger.api/mod-fqm-manager.yaml +++ b/src/main/resources/swagger.api/mod-fqm-manager.yaml @@ -67,7 +67,7 @@ paths: operationId: getFqmVersion tags: - fqmVersion - description: Get version of the fqm. + description: Get version of the fqm responses: '200': description: 'Version of the fqm' @@ -79,6 +79,23 @@ paths: $ref: '#/components/responses/badRequestResponse' '500': $ref: '#/components/responses/internalServerErrorResponse' + /fqm/migrate: + post: + operationId: migrateFqm + tags: + - fqmVersion + description: perform a migration of the FQM from the legacy version to the updated version. + responses: + '200': + description: 'FQM version retrieved successfully' + content: + application/json: + schema: + $ref: '#/components/schemas/fqmMigrateResponse' + '400': + $ref: '#/components/responses/badRequestResponse' + '500': + $ref: '#/components/responses/internalServerErrorResponse' components: parameters: @@ -137,6 +154,8 @@ components: type: array items: type: string + fqmMigrateResponse: + $ref: schemas/FqmMigrate.json responses: badRequestResponse: diff --git a/src/main/resources/swagger.api/schemas/FqmMigrate.json b/src/main/resources/swagger.api/schemas/FqmMigrate.json new file mode 100644 index 000000000..e69de29bb diff --git a/src/main/resources/swagger.api/schemas/PurgedQueries.json b/src/main/resources/swagger.api/schemas/PurgedQueries.json index bf6ed009e..f97ad9566 100644 --- a/src/main/resources/swagger.api/schemas/PurgedQueries.json +++ b/src/main/resources/swagger.api/schemas/PurgedQueries.json @@ -1,19 +1,29 @@ { "$schema": "https://json-schema.org/draft/2020-12/schema", - "title": "IDs of deleted queries", - "description": "IDs of deleted queries", + "title": "Entity Upgrade Request", + "description": "Schema for a request to upgrade an entity payload, including an entity type ID, FQL query, and list of fields.", "type": "object", "properties": { - "deletedQueryIds": { - "description": "Ids of the deleted queries", + "entityTypeId": { + "description": "ID of the entity type to be upgraded", + "type": "string", + "format": "UUID" + }, + "fqlQuery": { + "description": "FQL query string to be used for the upgrade", + "type": "string" + }, + "fields": { + "description": "List of fields to be included in the upgrade", "type": "array", "items": { - "type": "string", - "format": "UUID" + "type": "string" } } }, "required": [ - "deletedQueryIds" + "entityTypeId", + "fqlQuery", + "fields" ] }