Skip to content

Conversation

@dorsha
Copy link
Member

@dorsha dorsha commented Jan 17, 2026

Description

Recalculate SSO Mappings
https://github.com/descope/etc/issues/13548

Must

  • Tests
  • Documentation (if applicable)

Copilot AI review requested due to automatic review settings January 17, 2026 14:41
@dorsha dorsha enabled auto-merge (squash) January 17, 2026 14:42
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds a new method to recalculate SSO group-to-role mappings for users in a tenant. The functionality allows updating user roles based on current SSO group mappings configuration, either for all SSO configurations in a tenant or for a specific SSO configuration.

Changes:

  • Added recalculate_sso_mappings() method to the SSO settings management API
  • Added comprehensive test coverage for the new method including error and success scenarios
  • Updated sample application with usage example

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
descope/management/common.py Added API path constant for the recalculate mappings endpoint
descope/management/sso_settings.py Implemented the recalculate_sso_mappings() method with proper documentation and error handling
tests/management/test_sso_settings.py Added comprehensive unit tests covering error cases and both optional parameter scenarios
samples/management/sso_sample_app.py Added usage example demonstrating how to call the new method

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link

github-actions bot commented Jan 17, 2026

Coverage report

The coverage rate went from 98.36% to 98.36% ⬆️

100% of new lines are covered.

Diff Coverage details (click to unfold)

descope/management/sso_settings.py

100% of new lines are covered (100% of the complete file).

descope/management/common.py

100% of new lines are covered (99.73% of the complete file).

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.

2 participants