MFA as a Service - Sample Implementation

Hello,

Looking at implementing MFA as a Service to perform ad-hoc or step-up authentication using the Okta widget infrastructure (for a user already logged in to Okta). I’ve read a number of different ways to do this (from using the api exclusively to stuffing the stateToken and calling the widget directly) and need to know if the advice here is the most current and accurate: https://help.okta.com/en/prod/Content/Topics/integrations/oidc-based-mfa-as-a-service.htm

Has anyone developed any sample code for this scenario? It would be /most/ helpful.