Is possibile SAML authentication with login form in our sp page?

Hello, I think this scenario :
Authentication with OKTA IDP by rest api passing username, password and a saml request , Is it possibile?
I would like to have my web application which have the page with login and password, on submit we invoke OKTA rest api (send username, password, saml request)
s possible to have login form in our page and “invoke” an IDP (OKTA) via rest api and receive saml response by IDP endpoint?
Will Single Sing on work in this way?
Thanks :slight_smile: