Redirection for SAML Client

Hi,

I’m now integrating Gitlab with Keycloak SSO using SAML (I have to use SAML instead of OIDC).

I set up correctly, so I am able to login to gitlab using keycloak login page. But, I need to use REST API for login.

As I investigate, getting access token api exists only for OIDC not for SAML.

As I observe the behavior of keycloak login page, it seems that it redirect to below address.

https://{outkeycloakserver.com}/auth/realms/{my-realm}/login-actions/authenticate?session_code=2CvQwcbD0vHQ-a4OfJ6UC7uKkoJ8oO1g2cOllu5ZEBA&execution=b3a2fa08-0674-4d2b-8170-8a3590aa2eea&client_id=my_client_id

Question 1. How could I get session_code and execution through REST API?

Question 2. Is there any way to redirect to the service for SAML client?

Thanks in advance.