Create WPC GET Versions Method for Fluid Model schema
As an OSDU data definitions member, I want the GET VERSIONS method to be created to support the Fluid Model WPC. The method must get all the versions numbers from the record id provided and throw the corresponding messages, (Check AC section).
Dependencies before start the development :
| Task | Status (Y / N) |
|---|---|
| Proposal document revised | Y |
| Multi – company review | Y |
| OSDU Forum approval | Y |
Acceptance criteria:
| AC | Completed |
|---|---|
| The user can send a GET request to the endpoint /{record_id}. | |
| Path parameter validation: Valid record_id passes, Invalid record_id returns 422 Unprocessable Entity. | |
| Response: 200 OK with JSON body. | |
| Caching: Same response within TTL. Postman Tests:- Valid GET ® 200 OK. Invalid record_id ® 422. Repeat GET ® identical cached response. | |
| If the specified ID does not exist, the system should return a 404 Not Found status. | |
| If the user is not authorized to access the version information, the system should return a 403 Forbidden status. |
End point:
/api/rafs-ddms/v2/fluidmodel/{record_id}/versions
SCHEMA and reference links
You can access the json example file here: https://gitlab.opengroup.org/osdu/subcommittees/data-def/work-products/schema/-/blob/master/Generated/work-product-component/FluidModel.1.0.0.json
Source data sample:
Reference list(s):
Edited by Raul Isunza