Okta SDK Java - Is it possible to create a Routing Rule for a given Identity Provider?

Hello,

I’m trying to create a routing rule for a specific Identity provider using the Okta SDK.
I was trying to create it using some of the sub-classes of the PolicyRule class, but I couldn’t find one that is dedicated to the IdPDiscovery Policies.

My question is whether there is an existent class for this specific reason?
If that’s not the case, is the invokeAPI method of the ApiClient class suitable alternative for doing that?

Thanks in advance!

Hi, you can use the PolicyBuilder interface in the SDK to handle this .

Alternatively, you can also use the PolicyRule, with the PolicyType set to IDP_DISCOVERY. IDP Discovery has a single Policy and each Routing Rule is just a policy rule underneath it.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.