Skip to content

Commit bef4a4e

Browse files
author
popey2700
committedApr 24, 2024
Made fields depcreciated rather than deleted
1 parent d0637b9 commit bef4a4e

File tree

3 files changed

+29
-0
lines changed

3 files changed

+29
-0
lines changed
 

‎openapi.yml

+16
Original file line numberDiff line numberDiff line change
@@ -1294,6 +1294,16 @@ components:
12941294
CaseSentence:
12951295
type: object
12961296
properties:
1297+
date:
1298+
type: string
1299+
format: date
1300+
description: This field is depreciated and will be removed from the response soon.
1301+
sentencingCourt:
1302+
$ref: '#/components/schemas/Court'
1303+
releaseDate:
1304+
type: string
1305+
format: date
1306+
description: This field is depreciated and will be removed from the response soon.
12971307
expectedReleaseDate:
12981308
type: string
12991309
format: date
@@ -1331,6 +1341,12 @@ components:
13311341
type: string
13321342
example: "leslie.knope@pawnee.gov"
13331343
description: A list of email addresses
1344+
Court:
1345+
type: object
1346+
properties:
1347+
name:
1348+
type: string
1349+
description: This field is depreciated and will be removed from the response soon.
13341350
Disability:
13351351
type: object
13361352
properties:

‎src/main/kotlin/uk/gov/justice/digital/hmpps/hmppsintegrationapi/models/hmpps/CaseDetail.kt

+10
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,19 @@ data class Name(
2020
)
2121

2222
data class CaseSentence(
23+
@Deprecated("This field is depreciated and will be removed from the endpoint /v1/epf/person-details/{hmppsId}/{eventNumber} response soon.")
24+
val date: String? = null,
25+
@Deprecated("This field is depreciated and will be removed from the endpoint /v1/epf/person-details/{hmppsId}/{eventNumber} response soon.")
26+
val sentencingCourt: SentencingCourt? = null,
27+
@Deprecated("This field is depreciated and will be removed from the endpoint /v1/epf/person-details/{hmppsId}/{eventNumber} response soon.")
28+
val releaseDate: String? = null,
2329
val expectedReleaseDate: String? = null,
2430
)
2531

32+
data class SentencingCourt(
33+
val name: String? = null,
34+
)
35+
2636
data class ResponsibleProvider(
2737
val code: String? = null,
2838
val name: String? = null,

‎src/test/kotlin/uk/gov/justice/digital/hmpps/hmppsintegrationapi/smoke/EPFPersonDetailSmokeTest.kt

+3
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ class EPFPersonDetailSmokeTest : DescribeSpec(
3838
}
3939
},
4040
"sentence": {
41+
"date": null,
42+
"sentencingCourt": null,
43+
"releaseDate": null,
4144
"expectedReleaseDate": "2019-08-24"
4245
},
4346
"responsibleProvider": {

0 commit comments

Comments
 (0)