diff --git a/modules/claims_api/app/swagger/claims_api/v2/production/swagger.json b/modules/claims_api/app/swagger/claims_api/v2/production/swagger.json index 43450b6625d..77631a3752e 100644 --- a/modules/claims_api/app/swagger/claims_api/v2/production/swagger.json +++ b/modules/claims_api/app/swagger/claims_api/v2/production/swagger.json @@ -9451,6 +9451,14 @@ "pointer": "data/attributes/serviceOrganization" } }, + { + "title": "Unprocessable entity", + "detail": "The property /serviceOrganization did not contain the required key registrationNumber", + "status": "422", + "source": { + "pointer": "data/attributes/serviceOrganization" + } + }, { "title": "Unprocessable entity", "detail": "The property / did not contain the required key veteran", @@ -9458,6 +9466,14 @@ "source": { "pointer": "data/attributes/" } + }, + { + "title": "Unprocessable entity", + "detail": "The property /serviceOrganization/withoutPoaCode is not defined on the schema. Additional properties are not allowed", + "status": "422", + "source": { + "pointer": "data/attributes/serviceOrganization/withoutPoaCode" + } } ] }, @@ -9515,7 +9531,7 @@ { "title": "Resource not found", "status": "404", - "detail": "Could not find an Organization with code: 083", + "detail": "Could not retrieve Power of Attorney with registration number: 67890 and poa code: 083", "source": { "pointer": "/modules/claims_api/app/controllers/claims_api/v2/veterans/power_of_attorney/organization_controller.rb:35:in `validate_org_poa_code!'" } @@ -9806,7 +9822,8 @@ "type": "object", "additionalProperties": false, "required": [ - "poaCode" + "poaCode", + "registrationNumber" ], "properties": { "poaCode": { @@ -9819,15 +9836,10 @@ "type": "string", "example": "I help vets LLC." }, - "firstName": { - "description": "First Name of the representative.", - "type": "string", - "example": "John" - }, - "lastName": { - "description": "Last Name of the representative", + "registrationNumber": { + "description": "Registration Number of representative.", "type": "string", - "example": "Doe" + "example": "12345" }, "jobTitle": { "description": "Job title of the representative.", @@ -9888,7 +9900,8 @@ } }, "serviceOrganization": { - "poaCode": "083" + "poaCode": "083", + "registrationNumber": "67890" } } } @@ -10756,6 +10769,14 @@ "pointer": "data/attributes/serviceOrganization" } }, + { + "title": "Unprocessable entity", + "detail": "The property /serviceOrganization did not contain the required key registrationNumber", + "status": "422", + "source": { + "pointer": "data/attributes/serviceOrganization" + } + }, { "title": "Unprocessable entity", "detail": "The property / did not contain the required key veteran", @@ -10763,6 +10784,14 @@ "source": { "pointer": "data/attributes/" } + }, + { + "title": "Unprocessable entity", + "detail": "The property /serviceOrganization/withoutPoaCode is not defined on the schema. Additional properties are not allowed", + "status": "422", + "source": { + "pointer": "data/attributes/serviceOrganization/withoutPoaCode" + } } ] }, @@ -10820,7 +10849,7 @@ { "title": "Resource not found", "status": "404", - "detail": "Could not find an Organization with code: 083", + "detail": "Could not retrieve Power of Attorney with registration number: 67890 and poa code: 083", "source": { "pointer": "/modules/claims_api/app/controllers/claims_api/v2/veterans/power_of_attorney/organization_controller.rb:35:in `validate_org_poa_code!'" } @@ -11111,7 +11140,8 @@ "type": "object", "additionalProperties": false, "required": [ - "poaCode" + "poaCode", + "registrationNumber" ], "properties": { "poaCode": { @@ -11124,15 +11154,10 @@ "type": "string", "example": "I help vets LLC." }, - "firstName": { - "description": "First Name of the representative.", - "type": "string", - "example": "John" - }, - "lastName": { - "description": "Last Name of the representative", + "registrationNumber": { + "description": "Registration Number of representative.", "type": "string", - "example": "Doe" + "example": "12345" }, "jobTitle": { "description": "Job title of the representative.", @@ -11193,7 +11218,8 @@ } }, "serviceOrganization": { - "poaCode": "083" + "poaCode": "083", + "registrationNumber": "67890" } } } diff --git a/modules/claims_api/spec/sidekiq/v2/poa_form_builder_job_spec.rb b/modules/claims_api/spec/sidekiq/v2/poa_form_builder_job_spec.rb index 5b276328069..5394ed5bf78 100644 --- a/modules/claims_api/spec/sidekiq/v2/poa_form_builder_job_spec.rb +++ b/modules/claims_api/spec/sidekiq/v2/poa_form_builder_job_spec.rb @@ -99,6 +99,10 @@ 'y' => 200 } ] + }, + 'serviceOrganization' => { + 'firstName' => 'Bob', + 'lastName' => 'Representative' } } ) @@ -217,6 +221,10 @@ 'y' => 200 } ] + }, + 'serviceOrganization' => { + 'firstName' => 'Bob', + 'lastName' => 'Representative' } } )