Org_id not populating from universal sign-on

I have users who are in one organization and when logging on through universal login with identity first or identity first + biometrics, the claim has no org_id

Hi @ben30

The org_id will not be present inside the access token claims. You will need to set them using custom claims via a PostLogin Action as such:

exports.onExecutePostLogin = async (event, api) => {

  const orgID = event.organization.id;
 
    api.idToken.setCustomClaim("organization_id", orgID);
  }
};

If you have any other questions, feel free to let me know!

Kind Regards,
Nik