Skip to content

Commit c1dc259

Browse files
dorshaclaude
andcommitted
feat(xaa): add Cross-App Access (ID-JAG) 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>
1 parent 65a2791 commit c1dc259

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

descope/management/sso_settings.py

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,48 @@ def __init__(
5555
self.custom_attributes = custom_attributes
5656

5757

58+
class XAAIssuerSettings:
59+
"""
60+
Cross-App Access (XAA / ID-JAG) trusted-issuer settings, including per-issuer JIT provisioning and
61+
user attribute / group-to-role mapping (parity with the SSO login JIT). Describes the shape of each
62+
entry under a tenant's ``idJagSettings.issuers`` map, as returned by the tenant get-settings API.
63+
"""
64+
65+
def __init__(
66+
self,
67+
jwks_uri: Optional[str] = None,
68+
sign_algorithm: Optional[str] = None,
69+
user_info_uri: Optional[str] = None,
70+
external_id_field_name: Optional[str] = None,
71+
jit_disabled: Optional[bool] = None,
72+
attribute_mapping: Optional[AttributeMapping] = None,
73+
role_mappings: Optional[List[RoleMapping]] = None,
74+
default_sso_roles: Optional[List[str]] = None,
75+
groups_priority: Optional[List[str]] = None,
76+
allow_override_roles: Optional[bool] = None,
77+
):
78+
self.jwks_uri = jwks_uri
79+
self.sign_algorithm = sign_algorithm
80+
self.user_info_uri = user_info_uri
81+
self.external_id_field_name = external_id_field_name
82+
self.jit_disabled = jit_disabled
83+
self.attribute_mapping = attribute_mapping
84+
self.role_mappings = role_mappings
85+
self.default_sso_roles = default_sso_roles
86+
self.groups_priority = groups_priority
87+
self.allow_override_roles = allow_override_roles
88+
89+
90+
class XAAJWTBearerSettings:
91+
"""
92+
A tenant's Cross-App Access (XAA / ID-JAG) trust config: the set of trusted issuers keyed by issuer
93+
URL. Returned as ``idJagSettings`` by the tenant get-settings API.
94+
"""
95+
96+
def __init__(self, issuers: Optional[Dict[str, XAAIssuerSettings]] = None):
97+
self.issuers = issuers
98+
99+
58100
class OIDCAttributeMapping:
59101
"""
60102
Represents tenant OIDC attribute mapping.

0 commit comments

Comments
 (0)