Make sure that you are not setting the registration feature/options in the config of the embedded widget.
With Profile Enrollment all configuration will be done on the Okta Org side. Once configured correctly the sign up link will be displayed on the widget without any specific widget configuration.
Adding the classic widget registration feature flag will cause the widget to behave as if it is a classic Org and make a call to a register route which does not exist in OIE Orgs.
@erik Thanks for the update.
We had to change few settings after that is started working fine. Like updated JS versions and pkce is set to true in widget config.
We are able to register and login now, but I am not able to get idToken in form post. While I am getting interaction_code and state query string. Can you please guide me to generate idToken from interaction code or I need to do something else for this.