Package io.quarkus.test.oidc.client
Class OidcTestClient
- java.lang.Object
-
- io.quarkus.test.oidc.client.OidcTestClient
-
public class OidcTestClient extends Object
-
-
Constructor Summary
Constructors Constructor Description OidcTestClient()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()static io.vertx.core.buffer.BufferencodeForm(io.vertx.core.MultiMap form)StringgetAccessToken(String userName, String userSecret)Get an access token from the default tenant realm using a password grant with the provided user name, user secret.StringgetAccessToken(String clientId, String clientSecret, String userName, String userSecret)Get an access token from the default tenant realm using a password grant with the provided client id, client secret, user name, user secret, client id and user secret.StringgetAccessToken(String clientId, String clientSecret, String userName, String userSecret, Map<String,String> extraProps)Get an access token using a password grant with the provided user name, user secret, client id and secret, and scopes.StringgetAccessToken(String userName, String userSecret, Map<String,String> extraProps)Get an access token from the default tenant realm using a password grant with the provided user name, user secret, and additional properties.StringgetAuthServerUrl()Return URL string configured with a 'quarkus.oidc.auth-server' property.StringgetClientAccessToken()Get an access token a client_credentials grant.StringgetClientAccessToken(String clientId, String clientSecret)Get an access token from the default tenant realm using a client_credentials grant with a the provided client id and secret.StringgetClientAccessToken(String clientId, String clientSecret, Map<String,String> extraProps)Get an access token using a client_credentials grant with the provided client id and secret, and additional properties.StringgetClientAccessToken(Map<String,String> extraProps)Get an access token a client_credentials grant with additional properties.StringgetTokenUrl()Return URL string configured with a 'quarkus.oidc.auth-server' property.
-
-
-
Method Detail
-
getClientAccessToken
public String getClientAccessToken()
Get an access token a client_credentials grant. Client id must be configured with the `quarkus.oidc.client-id` property. Client secret must be configured with the `quarkus.oidc.credentials.secret` property.
-
getClientAccessToken
public String getClientAccessToken(Map<String,String> extraProps)
Get an access token a client_credentials grant with additional properties. Client id must be configured with the `quarkus.oidc.client-id` property. Client secret must be configured with the `quarkus.oidc.credentials.secret` property.
-
getClientAccessToken
public String getClientAccessToken(String clientId, String clientSecret)
Get an access token from the default tenant realm using a client_credentials grant with a the provided client id and secret.
-
getClientAccessToken
public String getClientAccessToken(String clientId, String clientSecret, Map<String,String> extraProps)
Get an access token using a client_credentials grant with the provided client id and secret, and additional properties.
-
getAccessToken
public String getAccessToken(String userName, String userSecret)
Get an access token from the default tenant realm using a password grant with the provided user name, user secret. Client id must be configured with the `quarkus.oidc.client-id` property. Client secret must be configured with the `quarkus.oidc.credentials.secret` property.
-
getAccessToken
public String getAccessToken(String userName, String userSecret, Map<String,String> extraProps)
Get an access token from the default tenant realm using a password grant with the provided user name, user secret, and additional properties. Client id must be configured with the `quarkus.oidc.client-id` property. Client secret must be configured with the `quarkus.oidc.credentials.secret` property.
-
getAccessToken
public String getAccessToken(String clientId, String clientSecret, String userName, String userSecret)
Get an access token from the default tenant realm using a password grant with the provided client id, client secret, user name, user secret, client id and user secret.
-
getAccessToken
public String getAccessToken(String clientId, String clientSecret, String userName, String userSecret, Map<String,String> extraProps)
Get an access token using a password grant with the provided user name, user secret, client id and secret, and scopes.
-
getAuthServerUrl
public String getAuthServerUrl()
Return URL string configured with a 'quarkus.oidc.auth-server' property.
-
getTokenUrl
public String getTokenUrl()
Return URL string configured with a 'quarkus.oidc.auth-server' property.
-
encodeForm
public static io.vertx.core.buffer.Buffer encodeForm(io.vertx.core.MultiMap form)
-
close
public void close()
-
-