Skip to content

[PM-34429] Create an endpoint to retrieve the InviteBlob#7994

Draft
JimmyVo16 wants to merge 3 commits into
pm-40216/data-protect-invite-link-codesfrom
ac/pm-34429/get-invite-blob-endpoint
Draft

[PM-34429] Create an endpoint to retrieve the InviteBlob#7994
JimmyVo16 wants to merge 3 commits into
pm-40216/data-protect-invite-link-codesfrom
ac/pm-34429/get-invite-blob-endpoint

Conversation

@JimmyVo16

@JimmyVo16 JimmyVo16 commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-38794

📔 Objective

  1. Add an endpoint to retrieve the invite blob.
  2. Use orgId to get the invite blob.
  3. Validations:
    1. Invite link exists
    2. Request code matches database code
    3. Org has the UseInviteLinks ability
  4. Exclude from validations
    1. Policies
    2. Existing org user
  5. Add unit and integration tests.
  6. Feature flag for Milestone 1.

@JimmyVo16 JimmyVo16 self-assigned this Jul 16, 2026
@codecov

codecov Bot commented Jul 16, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.11111% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 62.06%. Comparing base (74ffe65) to head (55c4496).

Files with missing lines Patch % Lines
...Console/Controllers/OrganizationUsersController.cs 81.25% 2 Missing and 1 partial ⚠️
...es/InviteLinks/GetOrganizationInviteBlobRequest.cs 75.00% 1 Missing ⚠️
Additional details and impacted files
@@                             Coverage Diff                             @@
##           pm-40216/data-protect-invite-link-codes    #7994      +/-   ##
===========================================================================
- Coverage                                    66.61%   62.06%   -4.56%     
===========================================================================
  Files                                         2277     2281       +4     
  Lines                                        99556    99600      +44     
  Branches                                      8990     8995       +5     
===========================================================================
- Hits                                         66323    61817    -4506     
- Misses                                       30961    35608    +4647     
+ Partials                                      2272     2175      -97     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@JimmyVo16 JimmyVo16 added ai-review Request a Claude code review t:feature Change Type - Feature Development labels Jul 16, 2026
@github-actions

github-actions Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

🤖 Bitwarden Claude Code Review

Overall Assessment: APPROVE

Reviewed the new GetInviteBlob endpoint and GetOrganizationInviteBlobCommand, which retrieve an organization's opaque invite blob after validating the invite link, organization ability, and email domain. The implementation mirrors the existing Accept/Confirm/Status invite-link commands, uses constant-time code comparison, and returns InviteLinkNotFound uniformly for both missing links and code mismatches to avoid enumeration. Zero-knowledge is preserved: the blob is transported opaquely and decrypted client-side. Unit and integration tests cover all validation branches.

Code Review Details

No findings. The change follows established patterns: CommandResult error mapping via the base controller Handle, TryAddScoped DI registration, nullable reference types, and the RequireFeature(GenerateInviteLink) gate consistent with sibling endpoints. The prior review's dangling doc-comment suggestion was addressed.

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

Labels

ai-review Request a Claude code review t:feature Change Type - Feature Development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant