Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .stoplight/styleguide.json

Large diffs are not rendered by default.

56 changes: 56 additions & 0 deletions ebl/v3/issuance/EBL_ISS_v3.0.4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -475,6 +475,8 @@ components:
properties:
document:
$ref: '#/components/schemas/TransportDocument'
transportDocumentReplacements:
$ref: '#/components/schemas/TransportDocumentReplacements'
issueTo:
$ref: '#/components/schemas/IssueToParty'
eBLVisualisationByCarrier:
Expand All @@ -489,6 +491,60 @@ components:
- document
- issueTo
- issuanceManifestSignedContent

TransportDocumentReplacements:
type: object
title: Transport Document Replacements
description: |
This object provides the possibility to link the issued `Transport Document` to one or more previously issued `Transport Document(s)`.
Comment thread
HenrikHL marked this conversation as resolved.

If this issuance request is the result of a previous **Surrender for Amendments** (because of an update to the `Transport Document`), the `oldTransportDocumentReferences` list would contain a single `transportDocumentReference` (and optionally a `transportDocumentSubReference`).

If the issued `Transport Document` is a "combine" of multiple `Transport Documents`, the `oldTransportDocumentReferences` list would contain the `transportDocumentReferences` being combined into the issued `Transport Document`.

The issued `Transport Document` can also be part of a split. In this case, the `newTransportDocumentReferences` list would contain all `transportDocumentReferences` that the `Transport Document(s)` specified in `oldTransportDocumentReferences` have been split into.

**Note:** If provided it should be considered as metadata and is not part of the `issuanceManifestSignedContent`.
Comment thread
HenrikHL marked this conversation as resolved.
properties:
oldTransportDocumentReferences:
type: array
description: |
A list of `transportDocumentReference` values and optional `transportDocumentSubReference` values from which the issued `Transport Document` originated.
If the list contains more than one item, the issuance is the result of a "combine" of multiple `Transport Documents`.
This property is only relevant if a previous **Surrender for Amendments** has been performed.
Comment thread
HenrikHL marked this conversation as resolved.
items:
$ref: '#/components/schemas/TransportDocumentRelation'
newTransportDocumentReferences:
type: array
description: |
A list of `transportDocumentReference` values and optional `transportDocumentSubReference` values into which the issued `Transport Document` has been split.
This property is only relevant if a previous **Surrender for Amendments** has resulted in a split of `Transport Documents`.
items:
$ref: '#/components/schemas/TransportDocumentRelation'
Comment on lines +495 to +523
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Action required

1. Empty replacements allowed 🐞 Bug ≡ Correctness

TransportDocumentReplacements has no required properties and no minItems, so
transportDocumentReplacements: {} or empty arrays validate even though the description says it
links to one or more Transport Documents, producing ambiguous/invalid lineage data.
Agent Prompt
### Issue description
`TransportDocumentReplacements` currently permits an empty object and empty reference lists. This contradicts the schema’s own description (“link … to one or more previously issued Transport Document(s)”) and makes the new field semantically unreliable.

### Issue Context
The spec already uses `minItems: 1` to prevent meaningless empty arrays (e.g., `Response.errors`). The new replacement-correlation structure should follow the same practice.

### Fix Focus Areas
- ebl/v3/issuance/EBL_ISS_v3.0.4.yaml[495-519]

### Suggested change
- Add `required: [oldTransportDocumentReferences]` to `TransportDocumentReplacements`.
- Add `minItems: 1` to `oldTransportDocumentReferences`.
- Add `minItems: 1` to `newTransportDocumentReferences` (so if it is provided, it cannot be empty).
- (Optional) Clarify in descriptions that `oldTransportDocumentReferences` is mandatory when `transportDocumentReplacements` is present.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


TransportDocumentRelation:
type: object
title: Transport Document Relation
description: |
An object linking a `transportDocumentReference` with an optional `transportDocumentSubReference`.
properties:
transportDocumentReference:
type: string
pattern: ^\S(?:.*\S)?$
maxLength: 20
description: |
Comment thread
HenrikHL marked this conversation as resolved.
A unique number allocated by the shipping line to the `Transport Document` and the main number used for the tracking of the status of the shipment.
example: HHL71800000
transportDocumentSubReference:
type: string
pattern: ^\S(?:.*\S)?$
maxLength: 100
description: |
Additional reference that can be optionally used alongside the `transportDocumentReference` in order to distinguish between versions of the same `Transport Document`.
example: Version_1
required:
- transportDocumentReference

SupportingDocument:
type: object
title: Supporting Document
Expand Down
Loading