Skip to content

docs: document group-sync mapping API filter and patch-by-project-key - #485

Closed
pablohashescobar wants to merge 1 commit into
masterfrom
add-groupsyncing-query-params
Closed

docs: document group-sync mapping API filter and patch-by-project-key#485
pablohashescobar wants to merge 1 commit into
masterfrom
add-groupsyncing-query-params

Conversation

@pablohashescobar

@pablohashescobar pablohashescobar commented Aug 7, 2026

Copy link
Copy Markdown
Member

Description

Documents the group-sync external API capabilities added in makeplane/plane-ee#8476 (WEB-8354) on the IdP Group Sync page.

Adds a Manage project mappings with the API section covering:

  • Filtering project role mappings by project with the project_identifier query parameter on GET /api/v1/workspaces/:slug/group-sync/project-mappings/ (case-insensitive, empty list on no match).
  • Updating a mapping by project identifier + IdP group name via PATCH /api/v1/workspaces/:slug/group-sync/project-mappings/:project_key/:idp_group_name/, including the writable fields (idp_group_name, project, all_projects, role) and 404 behavior.
  • Case sensitivity rules (project identifier case-insensitive, IdP group name exact match) and the new 400 response for empty PATCH bodies on all group-mapping endpoints.

Behavior was verified against the merged plane-ee implementation before writing.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Documentation
    • Added API documentation for managing project role mappings.
    • Documented listing, filtering, and updating mappings.
    • Clarified supported fields, authentication requirements, and common error responses.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Aug 7, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs Ready Ready Preview Aug 7, 2026 6:34am

Request Review

@coderabbitai

coderabbitai Bot commented Aug 7, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The group-sync documentation now describes APIs for listing and updating project role mappings, including authentication, filtering, matching rules, supported fields, validation, and error responses.

Changes

Project role mapping API

Layer / File(s) Summary
List project role mappings
docs/authentication/group-sync.md
Documents API-token authentication, group-sync requirements, optional project filtering, case-insensitive lookup, and empty results.
Update project role mappings
docs/authentication/group-sync.md
Documents PATCH requests, supported fields, exact IdP group-name matching, uniqueness requirements, and 404/400 responses.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

Suggested reviewers: danciaclara

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the documented group-sync mapping API filter and project-key-based PATCH endpoint.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch add-groupsyncing-query-params

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@makeplane

makeplane Bot commented Aug 7, 2026

Copy link
Copy Markdown

Linked to Plane Work Item(s)

References

This comment was auto-generated by Plane

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/authentication/group-sync.md`:
- Around line 149-153: Update the group-sync PATCH example documentation to
state that both path parameters must be percent-encoded, and illustrate an
encoded IdP group name such as Platform%20Engineering. Preserve the explanation
that both the project identifier and group name identify the mapping.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: aac3140b-3fd0-48f6-8a4a-522588eeb7e9

📥 Commits

Reviewing files that changed from the base of the PR and between a006a5d and 2ed16e0.

📒 Files selected for processing (1)
  • docs/authentication/group-sync.md

Comment on lines +149 to +153
```bash
curl -X PATCH "https://api.plane.so/api/v1/workspaces/my-workspace/group-sync/project-mappings/ENG/eng-team/" \
-H "x-api-key: $PLANE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"role": "admin"}'

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Document URL encoding for path parameters.

Line 150 places idp_group_name directly in the URL path. IdP group names can contain spaces or reserved characters. URI path segments use / as separators, and reserved characters require percent-encoding. (rfc-editor.org)

Add encoding guidance and an example such as Platform%20Engineering.

Proposed documentation change
 curl -X PATCH "https://api.plane.so/api/v1/workspaces/my-workspace/group-sync/project-mappings/ENG/eng-team/" \
   -H "x-api-key: $PLANE_API_KEY" \
   -H "Content-Type: application/json" \
   -d '{"role": "admin"}'

+Percent-encode both path parameters. For example, use Platform%20Engineering for Platform Engineering.
+
A project can have one mapping per IdP group, so both the project identifier and the group name are needed to identify a single mapping.

</details>

<!-- suggestion_start -->

<details>
<summary>📝 Committable suggestion</summary>

> ‼️ **IMPORTANT**
> Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

```suggestion

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/authentication/group-sync.md` around lines 149 - 153, Update the
group-sync PATCH example documentation to state that both path parameters must
be percent-encoded, and illustrate an encoded IdP group name such as
Platform%20Engineering. Preserve the explanation that both the project
identifier and group name identify the mapping.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant