From cae752ac954c83a30ec9d1a1547188652a6da989 Mon Sep 17 00:00:00 2001 From: Ross Jones Date: Tue, 14 Jan 2025 15:15:46 +0000 Subject: [PATCH] Update API models --- src/main/resources/static/_shared.yml | 61 ++++++++++++++++++- .../static/codegen/built-api-spec.yml | 61 ++++++++++++++++++- .../static/codegen/built-cas1-api-spec.yml | 61 ++++++++++++++++++- .../static/codegen/built-cas2-api-spec.yml | 61 ++++++++++++++++++- .../static/codegen/built-cas2v2-api-spec.yml | 61 ++++++++++++++++++- .../static/codegen/built-cas3-api-spec.yml | 61 ++++++++++++++++++- 6 files changed, 354 insertions(+), 12 deletions(-) diff --git a/src/main/resources/static/_shared.yml b/src/main/resources/static/_shared.yml index 74f1bbd1f9b..fb3eb1a4d02 100644 --- a/src/main/resources/static/_shared.yml +++ b/src/main/resources/static/_shared.yml @@ -2072,7 +2072,7 @@ components: status: $ref: '#/components/schemas/ApplicationStatus' latestStatusUpdate: - $ref: '#/components/schemas/LatestCas2StatusUpdate' + $ref: '#/components/schemas/LatestCas2v2StatusUpdate' risks: $ref: '#/components/schemas/PersonRisks' hdcEligibilityDate: @@ -2241,6 +2241,63 @@ components: - personName - crn - nomsNumber + Cas2v2StatusUpdate: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + description: + type: string + example: 'More information about the application has been requested from the HMPPS user.' + updatedBy: + $ref: '#/components/schemas/Cas2v2User' + updatedAt: + type: string + format: date-time + statusUpdateDetails: + type: array + items: + $ref: '#/components/schemas/Cas2v2StatusUpdateDetail' + required: + - id + - name + - label + - description + Cas2v2StatusUpdateDetail: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + required: + - id + - name + - label + LatestCas2v2StatusUpdate: + type: object + properties: + statusId: + type: string + format: uuid + label: + type: string + example: 'More information requested' + required: + - statusId + - label Cas2StatusUpdate: type: object properties: @@ -2865,7 +2922,7 @@ components: statusUpdates: type: array items: - $ref: '_shared.yml#/components/schemas/Cas2StatusUpdate' + $ref: '_shared.yml#/components/schemas/Cas2v2StatusUpdate' required: - id UpdateCas2Assessment: diff --git a/src/main/resources/static/codegen/built-api-spec.yml b/src/main/resources/static/codegen/built-api-spec.yml index c6e09b62580..83973ed9a74 100644 --- a/src/main/resources/static/codegen/built-api-spec.yml +++ b/src/main/resources/static/codegen/built-api-spec.yml @@ -6373,7 +6373,7 @@ components: status: $ref: '#/components/schemas/ApplicationStatus' latestStatusUpdate: - $ref: '#/components/schemas/LatestCas2StatusUpdate' + $ref: '#/components/schemas/LatestCas2v2StatusUpdate' risks: $ref: '#/components/schemas/PersonRisks' hdcEligibilityDate: @@ -6542,6 +6542,63 @@ components: - personName - crn - nomsNumber + Cas2v2StatusUpdate: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + description: + type: string + example: 'More information about the application has been requested from the HMPPS user.' + updatedBy: + $ref: '#/components/schemas/Cas2v2User' + updatedAt: + type: string + format: date-time + statusUpdateDetails: + type: array + items: + $ref: '#/components/schemas/Cas2v2StatusUpdateDetail' + required: + - id + - name + - label + - description + Cas2v2StatusUpdateDetail: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + required: + - id + - name + - label + LatestCas2v2StatusUpdate: + type: object + properties: + statusId: + type: string + format: uuid + label: + type: string + example: 'More information requested' + required: + - statusId + - label Cas2StatusUpdate: type: object properties: @@ -7166,7 +7223,7 @@ components: statusUpdates: type: array items: - $ref: '#/components/schemas/Cas2StatusUpdate' + $ref: '#/components/schemas/Cas2v2StatusUpdate' required: - id UpdateCas2Assessment: diff --git a/src/main/resources/static/codegen/built-cas1-api-spec.yml b/src/main/resources/static/codegen/built-cas1-api-spec.yml index ce07a9882c4..7fa591b45f6 100644 --- a/src/main/resources/static/codegen/built-cas1-api-spec.yml +++ b/src/main/resources/static/codegen/built-cas1-api-spec.yml @@ -3294,7 +3294,7 @@ components: status: $ref: '#/components/schemas/ApplicationStatus' latestStatusUpdate: - $ref: '#/components/schemas/LatestCas2StatusUpdate' + $ref: '#/components/schemas/LatestCas2v2StatusUpdate' risks: $ref: '#/components/schemas/PersonRisks' hdcEligibilityDate: @@ -3463,6 +3463,63 @@ components: - personName - crn - nomsNumber + Cas2v2StatusUpdate: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + description: + type: string + example: 'More information about the application has been requested from the HMPPS user.' + updatedBy: + $ref: '#/components/schemas/Cas2v2User' + updatedAt: + type: string + format: date-time + statusUpdateDetails: + type: array + items: + $ref: '#/components/schemas/Cas2v2StatusUpdateDetail' + required: + - id + - name + - label + - description + Cas2v2StatusUpdateDetail: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + required: + - id + - name + - label + LatestCas2v2StatusUpdate: + type: object + properties: + statusId: + type: string + format: uuid + label: + type: string + example: 'More information requested' + required: + - statusId + - label Cas2StatusUpdate: type: object properties: @@ -4087,7 +4144,7 @@ components: statusUpdates: type: array items: - $ref: '#/components/schemas/Cas2StatusUpdate' + $ref: '#/components/schemas/Cas2v2StatusUpdate' required: - id UpdateCas2Assessment: diff --git a/src/main/resources/static/codegen/built-cas2-api-spec.yml b/src/main/resources/static/codegen/built-cas2-api-spec.yml index 11bb602ef43..936705a0040 100644 --- a/src/main/resources/static/codegen/built-cas2-api-spec.yml +++ b/src/main/resources/static/codegen/built-cas2-api-spec.yml @@ -2663,7 +2663,7 @@ components: status: $ref: '#/components/schemas/ApplicationStatus' latestStatusUpdate: - $ref: '#/components/schemas/LatestCas2StatusUpdate' + $ref: '#/components/schemas/LatestCas2v2StatusUpdate' risks: $ref: '#/components/schemas/PersonRisks' hdcEligibilityDate: @@ -2832,6 +2832,63 @@ components: - personName - crn - nomsNumber + Cas2v2StatusUpdate: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + description: + type: string + example: 'More information about the application has been requested from the HMPPS user.' + updatedBy: + $ref: '#/components/schemas/Cas2v2User' + updatedAt: + type: string + format: date-time + statusUpdateDetails: + type: array + items: + $ref: '#/components/schemas/Cas2v2StatusUpdateDetail' + required: + - id + - name + - label + - description + Cas2v2StatusUpdateDetail: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + required: + - id + - name + - label + LatestCas2v2StatusUpdate: + type: object + properties: + statusId: + type: string + format: uuid + label: + type: string + example: 'More information requested' + required: + - statusId + - label Cas2StatusUpdate: type: object properties: @@ -3456,7 +3513,7 @@ components: statusUpdates: type: array items: - $ref: '#/components/schemas/Cas2StatusUpdate' + $ref: '#/components/schemas/Cas2v2StatusUpdate' required: - id UpdateCas2Assessment: diff --git a/src/main/resources/static/codegen/built-cas2v2-api-spec.yml b/src/main/resources/static/codegen/built-cas2v2-api-spec.yml index d18a22c79c5..4e37a228574 100644 --- a/src/main/resources/static/codegen/built-cas2v2-api-spec.yml +++ b/src/main/resources/static/codegen/built-cas2v2-api-spec.yml @@ -2663,7 +2663,7 @@ components: status: $ref: '#/components/schemas/ApplicationStatus' latestStatusUpdate: - $ref: '#/components/schemas/LatestCas2StatusUpdate' + $ref: '#/components/schemas/LatestCas2v2StatusUpdate' risks: $ref: '#/components/schemas/PersonRisks' hdcEligibilityDate: @@ -2832,6 +2832,63 @@ components: - personName - crn - nomsNumber + Cas2v2StatusUpdate: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + description: + type: string + example: 'More information about the application has been requested from the HMPPS user.' + updatedBy: + $ref: '#/components/schemas/Cas2v2User' + updatedAt: + type: string + format: date-time + statusUpdateDetails: + type: array + items: + $ref: '#/components/schemas/Cas2v2StatusUpdateDetail' + required: + - id + - name + - label + - description + Cas2v2StatusUpdateDetail: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + required: + - id + - name + - label + LatestCas2v2StatusUpdate: + type: object + properties: + statusId: + type: string + format: uuid + label: + type: string + example: 'More information requested' + required: + - statusId + - label Cas2StatusUpdate: type: object properties: @@ -3456,7 +3513,7 @@ components: statusUpdates: type: array items: - $ref: '#/components/schemas/Cas2StatusUpdate' + $ref: '#/components/schemas/Cas2v2StatusUpdate' required: - id UpdateCas2Assessment: diff --git a/src/main/resources/static/codegen/built-cas3-api-spec.yml b/src/main/resources/static/codegen/built-cas3-api-spec.yml index b1a76552289..3c4ca83af50 100644 --- a/src/main/resources/static/codegen/built-cas3-api-spec.yml +++ b/src/main/resources/static/codegen/built-cas3-api-spec.yml @@ -2171,7 +2171,7 @@ components: status: $ref: '#/components/schemas/ApplicationStatus' latestStatusUpdate: - $ref: '#/components/schemas/LatestCas2StatusUpdate' + $ref: '#/components/schemas/LatestCas2v2StatusUpdate' risks: $ref: '#/components/schemas/PersonRisks' hdcEligibilityDate: @@ -2340,6 +2340,63 @@ components: - personName - crn - nomsNumber + Cas2v2StatusUpdate: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + description: + type: string + example: 'More information about the application has been requested from the HMPPS user.' + updatedBy: + $ref: '#/components/schemas/Cas2v2User' + updatedAt: + type: string + format: date-time + statusUpdateDetails: + type: array + items: + $ref: '#/components/schemas/Cas2v2StatusUpdateDetail' + required: + - id + - name + - label + - description + Cas2v2StatusUpdateDetail: + type: object + properties: + id: + type: string + format: uuid + name: + type: string + example: 'moreInfoRequested' + label: + type: string + example: 'More information requested' + required: + - id + - name + - label + LatestCas2v2StatusUpdate: + type: object + properties: + statusId: + type: string + format: uuid + label: + type: string + example: 'More information requested' + required: + - statusId + - label Cas2StatusUpdate: type: object properties: @@ -2964,7 +3021,7 @@ components: statusUpdates: type: array items: - $ref: '#/components/schemas/Cas2StatusUpdate' + $ref: '#/components/schemas/Cas2v2StatusUpdate' required: - id UpdateCas2Assessment: