SSO Unable to do SAML registration

I try to fill in the data for registerSSOProvider according to this guide https://www.better-auth.com/docs/plugins/sso#register-a-saml-provider, But I get 401 Unauthorized. please help me with this

this is just a flow I'm currently testing on local environment. As I understand I need to call this function before my app is deployed, so it will know which SAML provider that my app is working with, but for local I just call it every time user need to authenticated. Is my approach correct?
Screenshot_2025-08-06_at_20.56.59.png
Was this page helpful?