Documentation ¶
Index ¶
- Variables
- type AuthorizedKeycloak
- func (k *AuthorizedKeycloak) Clients(ctx context.Context, realm string) *Clients
- func (k *AuthorizedKeycloak) Create(ctx context.Context, realm string, draft ClientDraft) (string, error)
- func (k *AuthorizedKeycloak) Delete(ctx context.Context, realm, id string) error
- func (k *AuthorizedKeycloak) Error() error
- func (k *AuthorizedKeycloak) Get(ctx context.Context, realm string, id string) (*ClientDetails, error)
- func (k *AuthorizedKeycloak) Update(ctx context.Context, id string, realm string, draft ClientDraft) error
- type Client
- type ClientDetails
- type ClientDraft
- type Clients
- type Keycloak
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrClientNotFound = errors.New("client not found")
Functions ¶
This section is empty.
Types ¶
type AuthorizedKeycloak ¶
type AuthorizedKeycloak struct {
// contains filtered or unexported fields
}
func (*AuthorizedKeycloak) Clients ¶
func (k *AuthorizedKeycloak) Clients(ctx context.Context, realm string) *Clients
func (*AuthorizedKeycloak) Create ¶
func (k *AuthorizedKeycloak) Create(ctx context.Context, realm string, draft ClientDraft) (string, error)
Create new client and return ID.
func (*AuthorizedKeycloak) Delete ¶
func (k *AuthorizedKeycloak) Delete(ctx context.Context, realm, id string) error
func (*AuthorizedKeycloak) Error ¶
func (k *AuthorizedKeycloak) Error() error
func (*AuthorizedKeycloak) Get ¶
func (k *AuthorizedKeycloak) Get(ctx context.Context, realm string, id string) (*ClientDetails, error)
func (*AuthorizedKeycloak) Update ¶
func (k *AuthorizedKeycloak) Update(ctx context.Context, id string, realm string, draft ClientDraft) error
type Client ¶
type Client struct { ID string `json:"id"` ClientID string `json:"clientId"` Name string `json:"name"` Description string `json:"description,omitempty"` AdminURL string `json:"adminUrl,omitempty"` RootURL string `json:"rootUrl"` BaseURL string `json:"baseUrl"` SurrogateAuthRequired bool `json:"surrogateAuthRequired"` Enabled bool `json:"enabled"` AlwaysDisplayInConsole bool `json:"alwaysDisplayInConsole"` ClientAuthenticatorType string `json:"clientAuthenticatorType"` RedirectURIs []string `json:"redirectUris"` WebOrigins []string `json:"webOrigins"` NotBefore int `json:"notBefore"` BearerOnly bool `json:"bearerOnly"` ConsentRequired bool `json:"consentRequired"` StandardFlowEnabled bool `json:"standardFlowEnabled"` ImplicitFlowEnabled bool `json:"implicitFlowEnabled"` DirectAccessGrantsEnabled bool `json:"directAccessGrantsEnabled"` ServiceAccountsEnabled bool `json:"serviceAccountsEnabled"` PublicClient bool `json:"publicClient"` FrontChannelLogout bool `json:"frontchannelLogout"` Protocol string `json:"protocol"` Attributes struct { PostLogoutRedirectUris string `json:"post.logout.redirect.uris"` } `json:"attributes"` FullScopeAllowed bool `json:"fullScopeAllowed"` NodeReRegistrationTimeout int `json:"nodeReRegistrationTimeout"` DefaultClientScopes []string `json:"defaultClientScopes"` OptionalClientScopes []string `json:"optionalClientScopes"` Access struct { View bool `json:"view"` Configure bool `json:"configure"` Manage bool `json:"manage"` } `json:"access"` }
type ClientDetails ¶
func Find ¶
func Find(ctx context.Context, kClient *AuthorizedKeycloak, realm string, id, name string) (*ClientDetails, error)
type ClientDraft ¶
type ClientDraft struct { ClientID string `json:"clientId,omitempty"` ClientSecret string `json:"secret,omitempty"` RootURL string `json:"rootUrl,omitempty"` AdminURL string `json:"adminUrl,omitempty"` RedirectURIs []string `json:"redirectUris,omitempty"` WebOrigins []string `json:"webOrigins,omitempty"` Name string `json:"name,omitempty"` ID string `json:"id,omitempty"` Description string `json:"description,omitempty"` }
func Generate ¶
func Generate(domain string) ClientDraft
Click to show internal directories.
Click to hide internal directories.