-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
hosted ghc v2 swagger ui with some ref errors
- Loading branch information
1 parent
67bbec7
commit 9b0790d
Showing
4 changed files
with
353 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,321 @@ | ||
swagger: "2.0" | ||
info: | ||
title: MilMove GHC V2 API | ||
license: | ||
name: MIT | ||
url: 'https://opensource.org/licenses/MIT' | ||
contact: | ||
email: milmove-developers@caci.com | ||
description: > | ||
The GHC V2 API is a RESTful API that enables the Office application for MilMove. | ||
All endpoints are located under `/ghc/v2`. | ||
version: 0.0.1 | ||
basePath: /ghc/v2 | ||
schemes: | ||
- https | ||
paths: | ||
'/move_task_orders/{moveTaskOrderID}/mto_shipments/{shipmentID}': | ||
patch: | ||
summary: updateMTOShipment | ||
description: | | ||
Updates a specified MTO shipment. | ||
Required fields include: | ||
* MTO Shipment ID required in path | ||
* If-Match required in headers | ||
* No fields required in body | ||
Optional fields include: | ||
* New shipment status type | ||
* Shipment Type | ||
* Customer requested pick-up date | ||
* Pick-up Address | ||
* Delivery Address | ||
* Secondary Pick-up Address | ||
* SecondaryDelivery Address | ||
* Delivery Address Type | ||
* Customer Remarks | ||
* Counselor Remarks | ||
* Releasing / Receiving agents | ||
consumes: | ||
- application/json | ||
produces: | ||
- application/json | ||
operationId: updateMTOShipment | ||
tags: | ||
- mtoShipment | ||
parameters: | ||
- in: path | ||
name: moveTaskOrderID | ||
required: true | ||
format: uuid | ||
type: string | ||
description: ID of move task order for mto shipment to use | ||
- in: path | ||
name: shipmentID | ||
type: string | ||
format: uuid | ||
required: true | ||
description: UUID of the MTO Shipment to update | ||
- in: header | ||
name: If-Match | ||
type: string | ||
required: true | ||
description: > | ||
Optimistic locking is implemented via the `If-Match` header. If the ETag header does not match | ||
the value of the resource on the server, the server rejects the change with a `412 Precondition Failed` error. | ||
- in: body | ||
name: body | ||
schema: | ||
$ref: '#/definitions/UpdateShipment' | ||
responses: | ||
'200': | ||
description: Successfully updated the specified MTO shipment. | ||
schema: | ||
$ref: 'definitions/MTOShipment.yaml' | ||
'400': | ||
$ref: '#/responses/InvalidRequest' | ||
'401': | ||
$ref: '#/responses/PermissionDenied' | ||
'403': | ||
$ref: '#/responses/PermissionDenied' | ||
'404': | ||
$ref: '#/responses/NotFound' | ||
'412': | ||
$ref: '#/responses/PreconditionFailed' | ||
'422': | ||
$ref: '#/responses/UnprocessableEntity' | ||
'500': | ||
$ref: '#/responses/ServerError' | ||
definitions: | ||
UpdateShipment: | ||
type: object | ||
properties: | ||
shipmentType: | ||
$ref: 'definitions/MTOShipmentType.yaml' | ||
requestedPickupDate: | ||
format: date | ||
type: string | ||
x-nullable: true | ||
requestedDeliveryDate: | ||
format: date | ||
type: string | ||
x-nullable: true | ||
customerRemarks: | ||
type: string | ||
example: handle with care | ||
x-nullable: true | ||
counselorRemarks: | ||
type: string | ||
example: counselor approved | ||
x-nullable: true | ||
billableWeightCap: | ||
type: integer | ||
description: estimated weight of the shuttle service item provided by the prime | ||
example: 2500 | ||
x-formatting: weight | ||
x-nullable: true | ||
billableWeightJustification: | ||
type: string | ||
example: more weight than expected | ||
x-nullable: true | ||
pickupAddress: | ||
allOf: | ||
- $ref: 'definitions/Address.yaml' | ||
destinationAddress: | ||
allOf: | ||
- $ref: 'definitions/Address.yaml' | ||
secondaryDeliveryAddress: | ||
allOf: | ||
- $ref: 'definitions/Address.yaml' | ||
secondaryPickupAddress: | ||
allOf: | ||
- $ref: 'definitions/Address.yaml' | ||
hasSecondaryPickupAddress: | ||
type: boolean | ||
x-nullable: true | ||
x-omitempty: false | ||
hasSecondaryDeliveryAddress: | ||
type: boolean | ||
x-nullable: true | ||
x-omitempty: false | ||
destinationType: | ||
$ref: 'definitions/DestinationType.yaml' | ||
agents: | ||
$ref: 'definitions/MTOAgents.yaml' | ||
x-nullable: true | ||
tacType: | ||
$ref: 'definitions/LOATypeNullable.yaml' | ||
sacType: | ||
$ref: 'definitions/LOATypeNullable.yaml' | ||
usesExternalVendor: | ||
type: boolean | ||
example: false | ||
x-nullable: true | ||
serviceOrderNumber: | ||
type: string | ||
x-nullable: true | ||
ntsRecordedWeight: | ||
description: The previously recorded weight for the NTS Shipment. Used for NTS Release to know what the previous primeActualWeight or billable weight was. | ||
example: 2000 | ||
type: integer | ||
x-formatting: weight | ||
x-nullable: true | ||
storageFacility: | ||
x-nullable: true | ||
$ref: 'definitions/StorageFacility.yaml' | ||
ppmShipment: | ||
$ref: '#/definitions/UpdatePPMShipment' | ||
UpdatePPMShipment: | ||
type: object | ||
properties: | ||
expectedDepartureDate: | ||
description: > | ||
Date the customer expects to move. | ||
format: date | ||
type: string | ||
x-nullable: true | ||
actualMoveDate: | ||
format: date | ||
type: string | ||
x-nullable: true | ||
pickupPostalCode: | ||
description: zip code | ||
format: zip | ||
type: string | ||
title: ZIP | ||
example: '90210' | ||
pattern: ^(\d{5})$ | ||
x-nullable: true | ||
secondaryPickupPostalCode: | ||
format: zip | ||
type: string | ||
title: ZIP | ||
example: '90210' | ||
pattern: ^(\d{5})$ | ||
x-nullable: true | ||
destinationPostalCode: | ||
format: zip | ||
type: string | ||
title: ZIP | ||
example: '90210' | ||
pattern: ^(\d{5})$ | ||
x-nullable: true | ||
secondaryDestinationPostalCode: | ||
format: zip | ||
type: string | ||
title: ZIP | ||
example: '90210' | ||
pattern: ^(\d{5})$ | ||
x-nullable: true | ||
w2Address: | ||
x-nullable: true | ||
$ref: 'definitions/Address.yaml' | ||
sitExpected: | ||
type: boolean | ||
x-nullable: true | ||
sitLocation: | ||
allOf: | ||
- $ref: 'definitions/SITLocationType.yaml' | ||
- x-nullable: true | ||
sitEstimatedWeight: | ||
type: integer | ||
example: 2000 | ||
x-nullable: true | ||
sitEstimatedEntryDate: | ||
format: date | ||
type: string | ||
x-nullable: true | ||
sitEstimatedDepartureDate: | ||
format: date | ||
type: string | ||
x-nullable: true | ||
estimatedWeight: | ||
type: integer | ||
example: 4200 | ||
x-nullable: true | ||
hasProGear: | ||
description: > | ||
Indicates whether PPM shipment has pro gear. | ||
type: boolean | ||
x-nullable: true | ||
proGearWeight: | ||
type: integer | ||
x-nullable: true | ||
spouseProGearWeight: | ||
type: integer | ||
x-nullable: true | ||
hasRequestedAdvance: | ||
description: > | ||
Indicates whether an advance has been requested for the PPM shipment. | ||
type: boolean | ||
x-nullable: true | ||
advanceAmountRequested: | ||
description: > | ||
The amount request for an advance, or null if no advance is requested | ||
type: integer | ||
format: cents | ||
x-nullable: true | ||
advanceStatus: | ||
$ref: 'definitions/PPMAdvanceStatus.yaml' | ||
x-nullable: true | ||
Error: | ||
properties: | ||
message: | ||
type: string | ||
required: | ||
- message | ||
type: object | ||
ValidationError: | ||
allOf: | ||
- $ref: '#/definitions/ClientError' | ||
- type: object | ||
properties: | ||
invalid_fields: | ||
type: object | ||
additionalProperties: | ||
type: string | ||
required: | ||
- invalid_fields | ||
ClientError: | ||
type: object | ||
properties: | ||
title: | ||
type: string | ||
detail: | ||
type: string | ||
instance: | ||
type: string | ||
format: uuid | ||
required: | ||
- title | ||
- detail | ||
- instance | ||
responses: | ||
InvalidRequest: | ||
description: The request payload is invalid | ||
schema: | ||
$ref: '#/definitions/Error' | ||
NotFound: | ||
description: The requested resource wasn't found | ||
schema: | ||
$ref: '#/definitions/Error' | ||
Conflict: | ||
description: Conflict error | ||
schema: | ||
$ref: '#/definitions/Error' | ||
PermissionDenied: | ||
description: The request was denied | ||
schema: | ||
$ref: '#/definitions/Error' | ||
ServerError: | ||
description: A server error occurred | ||
schema: | ||
$ref: '#/definitions/Error' | ||
PreconditionFailed: | ||
description: Precondition failed | ||
schema: | ||
$ref: '#/definitions/Error' | ||
UnprocessableEntity: | ||
description: The payload was unprocessable. | ||
schema: | ||
$ref: '#/definitions/ValidationError' |