3.1.1. Derivation of primaryDid
A server MUST derive User.primaryDid using the following algorithm:¶
- Collect all IdentityBinding resources whose
user.valuematches the target user and whose binding-levelstatusisactive.¶ - From that set, select the binding for which
bindingRefs.primary=trueis set in the User extension projection. At most one such binding is permitted.¶ - Within that binding, select the
didsentry withprimary=trueandstatus=verified.¶ - Set User.primaryDid to the
valueof that DID entry. If no such entry exists, omit User.primaryDid.¶
A server MUST NOT set User.primaryDid from a
binding that is not in active status, and MUST
clear User.primaryDid when the binding that sourced it transitions
out of active status or is deleted.¶
If multiple active bindings each contain a DID entry with
primary=true, the server MUST reject creation
or PATCH operations that would produce this ambiguous state with HTTP
400 and a SCIM error type of invalidValue.¶