Skip to content

docs(ocm): enforce notification payload schemas - #434

Open
MahdiBaghbani wants to merge 7 commits into
ocm-spec-share-state-bindingfrom
ocm-spec-schema-consistency
Open

MahdiBaghbani wants to merge 7 commits into
ocm-spec-share-state-bindingfrom
ocm-spec-schema-consistency

Conversation

@MahdiBaghbani

Copy link
Copy Markdown
Member

This PR is part of cs3org/OCM-STA#57.

Summary

Enforce the payload requirements for built-in notifications while accepting valid unknown types. Correct the examples and add focused payload checks to CI.

@MahdiBaghbani

Copy link
Copy Markdown
Member Author

@mickenordin

I deleted the

mlsWelcome:
          notificationType: MLS_WELCOME
          shareType: federation
          senderDomain: cloud.example.org
          notification:
            federation:
              mlsGroupId: 51dc30ddc473d43a6011e9ebba6ca770
              userId: [email protected]
              content: base64 MLS welcome

from the OpenAPI file based on the idea that the IP and MLS should have their own spec.<name>.yaml file, I can restore it if you like

@glpatcern

Copy link
Copy Markdown
Member

Great! I had in mind exactly something like this yesterday when commenting on Micke's PR for the collections!

@MahdiBaghbani

Copy link
Copy Markdown
Member Author

I hope that we don't get into lots of conflicts when merging 😄

@glpatcern

Copy link
Copy Markdown
Member

from the OpenAPI file based on the idea that the IP and MLS should have their own spec.<name>.yaml file, I can restore it if you like

On that though I'm not sure I agree: OCM-IP likely does not need any spec.yaml, given that it's all about the semantic of the token, and OCM-MLS is based on standard notifications. Until really necessary, I think it's best if we keep all of them in the same spec.yaml: after all the Drafts stand on their own, and refer to the OpenAPI as a complementary information.

@MahdiBaghbani

MahdiBaghbani commented Nov 15, 2026 •

Copy link
Copy Markdown
Member Author

I concur, I actually created the #435 in hopes to come back to it later if I have time, both the IP and MLS can be managed inside the spec.yaml but need clear identifiers and labels to distinguish them between the drafts

@MahdiBaghbani MahdiBaghbani linked an issue Nov 15, 2026 that may be closed by this pull request
2 tasks
@MahdiBaghbani
MahdiBaghbani force-pushed the ocm-spec-schema-consistency branch from 07a895b to 1df3dc5 Compare November 16, 2026 06:52
@mickenordin
mickenordin force-pushed the ocm-spec-schema-consistency branch from 1df3dc5 to 499aab9 Compare November 16, 2026 08:54
@MahdiBaghbani
MahdiBaghbani force-pushed the ocm-spec-schema-consistency branch from 499aab9 to 8b786a1 Compare November 16, 2026 11:38
@MahdiBaghbani
MahdiBaghbani removed this pull request from stack #429 November 17, 2026 19:59
@MahdiBaghbani
MahdiBaghbani force-pushed the ocm-spec-schema-consistency branch from 8b786a1 to cafba35 Compare November 17, 2026 20:01
@MahdiBaghbani
MahdiBaghbani added this pull request to stack #446 November 17, 2026 20:03
@glpatcern
glpatcern force-pushed the ocm-spec-schema-consistency branch from cafba35 to 26e776e Compare November 18, 2026 13:50

@glpatcern glpatcern left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

A few changes, but I'd love this be merged soon!

Comment thread spec.yaml
resourceType: file
senderDomain: sender.example.org
notification:
message: Something happened

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
message: Something happened
message: Something happened
file:
customKey: customValue

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Applied your suggested example

Comment thread spec.yaml Outdated
- GROUP_REMOVED
- OCM_SERVER_ADDED
- OCM_SERVER_REMOVED
NotificationPermission:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

What about factoring this out between here and the NewShare payload?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Factored the values into SharePermission and reused it in notifications and NewShare, with view restricted to webapp

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: In review

Development

Successfully merging this pull request may close these issues.

Develop OCM specifications from M11 and M12

2 participants