Skip to content

feat(xaa): add cross-app access (ID-JAG) mapping types - #1664

Merged
dorsha merged 10 commits into
mainfrom
feat/xaa-mapping
Aug 23, 2026
Merged

feat(xaa): add cross-app access (ID-JAG) mapping types#1664
dorsha merged 10 commits into
mainfrom
feat/xaa-mapping

Conversation

@dorsha

@dorsha dorsha commented Aug 17, 2026

Copy link
Copy Markdown
Member

Required for:
https://github.com/descope/etc/issues/17573

Adds Cross-App Access (ID-JAG) per-issuer JIT + attribute/group-role mapping types.

Adds XAAIssuerSettings + XAAJWTBearerSettings describing the per-issuer JIT +
attribute/group-role mapping returned under a tenant's idJagSettings.

Required for: descope/etc#17573

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shuni-bot

shuni-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot

shuni-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🐕 Suggested Reviewers

This PR adds Cross-App Access (ID-JAG) mapping types to the SSO settings management module. All three candidate reviewers have direct experience with the affected file (descope/management/sso_settings.py), making them well-suited to review this change. Since the changes are localized to a single file and all candidates have relevant commit history, we recommend including the most active contributors to ensure thorough review coverage.

Reviewer Reason
LioriE LioriE has prior commits in descope/management/sso_settings.py and can provide valuable context on existing SSO settings implementation and ensure consistency with the current architecture.
omercnet omercnet has direct experience with descope/management/sso_settings.py and can review the new ID-JAG mapping types for correctness and integration with existing SSO configurations.
itaihanski itaihanski has commits in the same SSO settings file and can ensure the new Cross-App Access types align with overall system design patterns and provide domain expertise on IAM/SSO functionality.

Suggested by Shuni based on git history and PR context. Names are not @-mentioned to avoid notifying anyone — request a review from whoever fits best.

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni's Review

Small, clean addition of two new type-only classes (XAAIssuerSettings, XAAJWTBearerSettings) for Cross-App Access (ID-JAG) trust config, mirroring the existing SAML/OIDC mapping types.

Sniffed out 1 issue:

  • 1 🟡 MEDIUM: new types aren't exported from descope/__init__.py like every sibling type in this file

See inline comment for details. Woof!


Declared coverage: FULL — 1/1 changed files reviewed.

Comment thread descope/management/sso_settings.py
@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown

Coverage report

The coverage rate went from 98.23% to 98.25% ⬆️

100% of new lines are covered.

Diff Coverage details (click to unfold)

descope/management/_sso_settings_base.py

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

descope/management/common.py

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

descope/management/sso_settings_async.py

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

descope/management/sso_settings.py

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

@dorsha dorsha changed the title feat(xaa): Cross-App Access (ID-JAG) mapping types feat(xaa): add cross-app access (ID-JAG) mapping types Aug 17, 2026
…ackage root

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shuni-bot

shuni-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni's Review

Follow-up pass: the only change since the last review is commit 5b8e8b6, which re-exports XAAIssuerSettings and XAAJWTBearerSettings from descope/__init__.py.

Previous 🟡 MEDIUM finding (missing export) is now fixed and confirmed in-thread — no new issues found.

Good bones! Woof! 🐕


Declared coverage: PARTIAL — 1/2 changed files reviewed.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shuni-bot

shuni-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni's Review

Big follow-up push: this PR now wires up the actual configure_xaa_settings / load_xaa_settings / load_all_xaa_settings / delete_xaa_settings API (sync + async), plus README docs, a sample app, and thorough request-body tests.

No new issues found — the wire-format composers, tests, README, and sample app are all internally consistent, and the async module correctly mirrors the sync one. The only prior finding (missing __init__.py export) was already fixed and confirmed resolved.

Good bones! Woof! 🐕


Declared coverage: FULL — 8/8 changed files reviewed.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shuni-bot

shuni-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni's Review

Latest push is just ruff format (line-wrapping) on _sso_settings_base.py and test_sso_settings.py — no logic changes.

No new issues found. The prior finding remains fixed and resolved.

Clean paws, nothing to fetch here. Woof! 🐕


Declared coverage: PARTIAL — 2/8 changed files reviewed.

@dorsha

dorsha commented Aug 17, 2026

Copy link
Copy Markdown
Member Author

@shuni review

@shuni-bot

shuni-bot Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni's Review

Adds Cross-App Access (ID-JAG) trust config: two new type-only classes plus the full configure/load/load_all/delete_xaa_settings API (sync + async), wire-format composers, README docs, a sample app, and thorough request-body tests.

No new issues found. The wire-format composers correctly reuse existing _role_mapping_to_dict/_attribute_mapping_to_dict/_fga_mappings_to_dict helpers, sso_id omission is handled consistently across configure/load/delete, and the sync/async modules mirror each other. The prior 🟡 MEDIUM finding (missing __init__.py export) is already fixed and confirmed resolved; the latest commit is formatting-only.

Good bones! Woof! 🐕


Declared coverage: FULL — 8/8 changed files reviewed.

Add provider_id to XAASettings and emit providerID on the XAA configure body
when set, mirroring SSO SAML/OIDC so the chosen IdP round-trips.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shuni-bot

shuni-bot Bot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni Review

No new issues found.


Declared coverage: PARTIAL — 3/8 changed files reviewed.

@shuni-bot

shuni-bot Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni Review

No new issues found.


Declared coverage: PARTIAL — 1/8 changed files reviewed.

Update the XAAIssuerSettings/XAAJWTBearerSettings docstrings + README to drop
the "returned by the tenant get-settings API" claim - XAA is no longer surfaced
on tenant load; read it via load_xaa_settings / load_all_xaa_settings.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shuni-bot

shuni-bot Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni Review

No new issues found.


Declared coverage: PARTIAL — 2/8 changed files reviewed.

@dorsha

dorsha commented Aug 21, 2026

Copy link
Copy Markdown
Member Author

@shuni fix coverage comments

@shuni-bot

shuni-bot Bot commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

🐕 Done! Updated PR: #1664

View Shuni run

📋 Actions Taken

View AI response

The coverage bot flagged two uncovered lines in descope/management/_sso_settings_base.py (178, 196) — the is None guard branches in _issuer_settings_to_dict and _jwt_bearer_settings_to_dict. Added two tests to tests/management/test_sso_settings.py:

  • test_configure_xaa_settings_without_jwt_bearer_settingsXAASettings(enabled=False) with no settings, hitting the settings is None guard.
  • test_configure_xaa_settings_with_none_issuer_entry — an issuer entry mapped to None in the issuers dict, hitting the issuer is None guard.

Full suite: 1057 passed, coverage 98.27% (was 98.23%), _sso_settings_base.py now fully covered. Committed as e80d264e.


View session on Shuni Portal 🐾

Adds cases for configure_xaa_settings with no jwt-bearer settings and
with an issuer entry left at defaults (None), covering the two guard
clauses flagged as missing by the coverage bot.
@shuni-bot

shuni-bot Bot commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

🐕 Review complete — View session on Shuni Portal 🐾

@dorsha
dorsha requested a review from ruvenzx August 21, 2026 12:44

@shuni-bot shuni-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🐕 Shuni Review

No new issues found.


Declared coverage: PARTIAL — 1/8 changed files reviewed.

@dorsha
dorsha enabled auto-merge (squash) August 21, 2026 12:46
@dorsha
dorsha merged commit 5fb78ec into main Aug 23, 2026
38 checks passed
@dorsha
dorsha deleted the feat/xaa-mapping branch August 23, 2026 06:03
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