Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Required fields for links #818

Closed
m-mohr opened this issue Apr 12, 2023 · 5 comments · Fixed by #819
Closed

Required fields for links #818

m-mohr opened this issue Apr 12, 2023 · 5 comments · Fixed by #819
Assignees
Labels
Part 1: Core Issue related to Part 1 - Core

Comments

@m-mohr
Copy link
Contributor

m-mohr commented Apr 12, 2023

I'm currently comparing STAC, STAC API, OGC API Features and OGC API Records link objects.
STAC API made the type recently a required field due to req 13B in OAFeat, but the schema doesn't list type as being required:
http://schemas.opengis.net/ogcapi/features/part1/1.0/openapi/schemas/link.yaml
Or does 13B only apply to self and alternate links as mentioned in req. 13A?

@pvretano In Records the schema only requires href, I think: https://github.com/opengeospatial/ogcapi-records/blob/master/core/openapi/schemas/common/link.yaml

In Commons the schema requires href and rel: https://github.com/opengeospatial/ogcapi-common/blob/master/19-072/openapi/schemas/link.yaml

I feel like there's a bit of alignment or clarification needed, not only in Features...?

@cportele
Copy link
Member

cportele commented Apr 12, 2023

@m-mohr

Yes, only the self and alternate links must have a type.

In the link object, only href and rel are required. This is consistent with and based on RFC 8288.

@m-mohr
Copy link
Contributor Author

m-mohr commented Apr 12, 2023

Thanks, this was greatly misunderstood by us and even lead to a spec change recently in STAC API where we required the type field in STAC API. I think it should be considered to clarify the wording... something like: "All links with relation type self and alternate SHALL include the ..."

@cportele
Copy link
Member

Thanks for raising this. I will create a pull request (and also check, if we should make similar clarifications in other requirements).

@m-mohr
Copy link
Contributor Author

m-mohr commented Apr 12, 2023

cportele added a commit that referenced this issue Apr 13, 2023
Closes #818

It is also redundant to require that `rel` is included in links which are identified by their `rel` - which only has potential too add to any confusion. Redundant reference to `rel` have been removed.
@cportele
Copy link
Member

@m-mohr - Please have a look at #819. Thanks!

@cportele cportele self-assigned this Apr 13, 2023
@cportele cportele added the Part 1: Core Issue related to Part 1 - Core label Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Part 1: Core Issue related to Part 1 - Core
Projects
Development

Successfully merging a pull request may close this issue.

2 participants