Repository navigation
OBJ-96 — Permission grants (viewer/commenter/editor) - #37
Merged
objectgyan merged 1 commit intoMay 17, 2026
Merged
objectgyan merged 1 commit into
objectgyan merged 1 commit into
Conversation
Adds document_shares table with role-check constraint (viewer/commenter/editor),
owner-only IAuthorizationPolicy Share action authz, and three endpoints:
POST /api/documents/{id}/shares (201), GET (200), DELETE (204).
Adds created_by column to documents for ownership tracking.
Migration: AddDocumentShares. Tests: 97 integration + 159 unit, all passing.
OBJ-96 M9b.1 — Permission grants (viewer / commenter / editor)
Milestone: M9 · Wave: 3 SummaryAdd Acceptance
Validation
Branch / PRBranch from |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
document_sharestable with role-check constraint (viewer,commenter,editor) andcreated_bycolumn ondocumentsPOST /api/documents/{id}/shares(201),GET /api/documents/{id}/shares(200),DELETE /api/documents/{id}/shares/{shareId}(204)IAuthorizationPolicy.AuthorizeAsync(userId, document, AuthorizationAction.Share); non-owner → 403Test plan
ShareApiTests)scripts/validate-obj-96.ps1exits 0 — full grant/list/revoke cycle verified live + DBvalidation/obj-96-db.txt— DB row presence/absence confirmedvalidation/obj-96-api.txt— all API assertions logged