Documentation ¶
Index ¶
- type Client
- type Config
- type ContactInfo
- type DeleteGroupsRequest
- type DeleteInvitesRequest
- type EmptyStruct
- type Error
- type Errors
- type EventsReply
- type EventsRequest
- type EventsService
- type GetEventRequest
- type GetGroupsRequest
- type GetInvitesRequest
- type GetUsersRequest
- type Group
- type GroupsReply
- type GroupsRequest
- type GroupsService
- func (s *GroupsService) Delete(ctx context.Context, req *DeleteGroupsRequest) (*EmptyStruct, *http.Response, error)
- func (s *GroupsService) Get(ctx context.Context, req *GetGroupsRequest) (*GroupsReply, *http.Response, error)
- func (s *GroupsService) GetAll(ctx context.Context) (*GroupsReply, *http.Response, error)
- func (s *GroupsService) Post(ctx context.Context, req *PostGroupsRequest) (*GroupsReply, *http.Response, error)
- func (s *GroupsService) Put(ctx context.Context, req *PutGroupsRequest) (*GroupsReply, *http.Response, error)
- func (s *GroupsService) Search(ctx context.Context, req *SearchGroupsRequest) (*SearchReply, *http.Response, error)
- type HTTPSScimEduidSeSchemaNutidEventV1
- type HTTPSScimEduidSeSchemaNutidGroupV1
- type HTTPSScimEduidSeSchemaNutidUserV1
- type HealthyReply
- type InvitesRequest
- type InvitesService
- func (s *InvitesService) Delete(ctx context.Context, req *DeleteInvitesRequest) (*EmptyStruct, *http.Response, error)
- func (s *InvitesService) Get(ctx context.Context, req *GetInvitesRequest) (*UsersReply, *http.Response, error)
- func (s *InvitesService) Post(ctx context.Context, req *PostInvitesRequest) (*UsersReply, *http.Response, error)
- func (s *InvitesService) Search(ctx context.Context, req *SearchInvitesRequest) (*SearchReply, *http.Response, error)
- type LinkedAccount
- type LoginRequest
- type Member
- type Meta
- type Name
- type PostEventsRequest
- type PostGroupsRequest
- type PostInvitesRequest
- type PostUsersRequest
- type Profiles
- type Prop
- type PutGroupsRequest
- type PutUsersRequest
- type Resource
- type SearchGroupsRequest
- type SearchInvitesRequest
- type SearchReply
- type SearchRequest
- type SearchUsersRequest
- type StatusService
- type TokenConfig
- type UsersReply
- type UsersRequest
- type UsersService
- func (s *UsersService) Get(ctx context.Context, req *GetUsersRequest) (*UsersReply, *http.Response, error)
- func (s *UsersService) Post(ctx context.Context, req *PostUsersRequest) (*UsersReply, *http.Response, error)
- func (s *UsersService) Put(ctx context.Context, req *PutUsersRequest) (*UsersReply, *http.Response, error)
- func (s *UsersService) Search(ctx context.Context, req *SearchUsersRequest) (*SearchReply, *http.Response, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { SunetJWT *sunetjwt.Client Events *EventsService Groups *GroupsService Invites *InvitesService Status *StatusService Users *UsersService // contains filtered or unexported fields }
Client holds the object
type Config ¶
type Config struct { URL string Token TokenConfig }
Config holds the configuration for New
type ContactInfo ¶
type ContactInfo struct { Value string `json:"value"` Display string `json:"display"` Type string `json:"type"` Primary bool `json:"primary"` }
ContactInfo type
type DeleteGroupsRequest ¶ added in v0.0.8
type DeleteGroupsRequest struct {
ScimID string `validate:"required" json:"scim_id"`
}
DeleteGroupsRequest type
type DeleteInvitesRequest ¶ added in v0.0.8
type DeleteInvitesRequest struct {
ScimID string `validate:"required" json:"scim_id"`
}
DeleteInvitesRequest type
type Errors ¶ added in v0.0.3
type Errors struct { Detail []struct { Loc []string `json:"loc"` Msg string `json:"msg"` Type string `json:"type"` } `json:"detail"` }
Errors is a general error reply
type EventsReply ¶
type EventsReply struct { ID string `json:"id"` Meta Meta `json:"meta"` EventsRequest }
EventsReply type
type EventsRequest ¶
type EventsRequest struct { Schemas []string `json:"schemas"` ExternalID string `json:"externalId"` HTTPSScimEduidSeSchemaNutidEventV1 HTTPSScimEduidSeSchemaNutidEventV1 `json:"https://scim.eduid.se/schema/nutid/event/v1"` }
EventsRequest type
type EventsService ¶
type EventsService struct {
// contains filtered or unexported fields
}
EventsService holds events object
func (*EventsService) Get ¶
func (s *EventsService) Get(ctx context.Context, req *GetEventRequest) (*EventsReply, *http.Response, error)
Get gets one event
func (*EventsService) Post ¶
func (s *EventsService) Post(ctx context.Context, req *PostEventsRequest) (*EventsReply, *http.Response, error)
Post create a new event
type GetEventRequest ¶ added in v0.0.8
type GetEventRequest struct { ScimID string `validate:"required" json:"scim_id"` Data EventsRequest `validate:"required" json:"data"` }
GetEventRequest type
type GetGroupsRequest ¶ added in v0.0.8
type GetGroupsRequest struct {
ScimID string `validate:"required" json:"scim_id"`
}
GetGroupsRequest type
type GetInvitesRequest ¶ added in v0.0.8
type GetInvitesRequest struct {
ScimID string `validate:"required" json:"scim_id"`
}
GetInvitesRequest type
type GetUsersRequest ¶ added in v0.0.8
type GetUsersRequest struct {
ScimID string `validate:"required" json:"scim_id"`
}
GetUsersRequest holds the request for user
type Group ¶
type Group struct { Value string `json:"value"` Ref string `json:"$ref"` Display string `json:"display"` }
Group type
type GroupsReply ¶
type GroupsReply struct { ID string `json:"id"` Meta Meta `json:"meta"` GroupsRequest }
GroupsReply type
type GroupsRequest ¶
type GroupsRequest struct { Schemas []string `validate:"required" json:"schemas"` ExternalID string `validate:"required" json:"externalId"` DisplayName string `validate:"required" json:"displayName"` Members []Member `validate:"required" json:"members"` HTTPSScimEduidSeSchemaNutidGroupV1 HTTPSScimEduidSeSchemaNutidGroupV1 `validate:"required" json:"https://scim.eduid.se/schema/nutid/group/v1"` }
GroupsRequest type
type GroupsService ¶
type GroupsService struct {
// contains filtered or unexported fields
}
GroupsService holds the service for groups
func (*GroupsService) Delete ¶
func (s *GroupsService) Delete(ctx context.Context, req *DeleteGroupsRequest) (*EmptyStruct, *http.Response, error)
Delete deletes a group
func (*GroupsService) Get ¶
func (s *GroupsService) Get(ctx context.Context, req *GetGroupsRequest) (*GroupsReply, *http.Response, error)
Get gets one group
func (*GroupsService) GetAll ¶
func (s *GroupsService) GetAll(ctx context.Context) (*GroupsReply, *http.Response, error)
GetAll return all groups
func (*GroupsService) Post ¶
func (s *GroupsService) Post(ctx context.Context, req *PostGroupsRequest) (*GroupsReply, *http.Response, error)
Post posts a group
func (*GroupsService) Put ¶
func (s *GroupsService) Put(ctx context.Context, req *PutGroupsRequest) (*GroupsReply, *http.Response, error)
Put puts group
func (*GroupsService) Search ¶
func (s *GroupsService) Search(ctx context.Context, req *SearchGroupsRequest) (*SearchReply, *http.Response, error)
Search group
type HTTPSScimEduidSeSchemaNutidEventV1 ¶
type HTTPSScimEduidSeSchemaNutidEventV1 struct { Resource Resource `json:"resource"` Level string `json:"level"` Data struct { } `json:"data"` ExpiresAt time.Time `json:"expiresAt"` Timestamp time.Time `json:"timestamp"` Source string `json:"source"` }
HTTPSScimEduidSeSchemaNutidEventV1 type
type HTTPSScimEduidSeSchemaNutidGroupV1 ¶
type HTTPSScimEduidSeSchemaNutidGroupV1 struct {
Data struct {
} `json:"data"`
}
HTTPSScimEduidSeSchemaNutidGroupV1 type
type HTTPSScimEduidSeSchemaNutidUserV1 ¶
type HTTPSScimEduidSeSchemaNutidUserV1 struct { Profiles Profiles `json:"profiles"` LinkedAccounts []LinkedAccount `json:"linked_accounts"` }
HTTPSScimEduidSeSchemaNutidUserV1 type
type HealthyReply ¶ added in v0.0.3
type HealthyReply struct { Status string `json:"status"` Hostname string `json:"hostname"` Reason string `json:"reason"` }
HealthyReply type
type InvitesService ¶
type InvitesService struct {
// contains filtered or unexported fields
}
InvitesService holds the object for Invites
func (*InvitesService) Delete ¶
func (s *InvitesService) Delete(ctx context.Context, req *DeleteInvitesRequest) (*EmptyStruct, *http.Response, error)
Delete deletes one invite
func (*InvitesService) Get ¶
func (s *InvitesService) Get(ctx context.Context, req *GetInvitesRequest) (*UsersReply, *http.Response, error)
Get gets one invite
func (*InvitesService) Post ¶
func (s *InvitesService) Post(ctx context.Context, req *PostInvitesRequest) (*UsersReply, *http.Response, error)
Post creates a new invite
func (*InvitesService) Search ¶
func (s *InvitesService) Search(ctx context.Context, req *SearchInvitesRequest) (*SearchReply, *http.Response, error)
Search searches for an invite
type LinkedAccount ¶
type LinkedAccount struct { Issuer string `json:"issuer"` Value string `json:"value"` Parameters struct { } `json:"parameters"` }
LinkedAccount type
type LoginRequest ¶ added in v0.0.3
type LoginRequest struct {
DataOwner string `json:"data_owner"`
}
LoginRequest type
type Member ¶
type Member struct { Value string `json:"value"` Ref string `json:"$ref"` Display string `json:"display"` }
Member type
type Meta ¶
type Meta struct { Location string `json:"location"` LastModified time.Time `json:"lastModified"` ResourceType string `json:"resourceType"` Created time.Time `json:"created"` Version string `json:"version"` }
Meta type
type Name ¶
type Name struct { FamilyName string `json:"familyName"` GivenName string `json:"givenName"` Formatted string `json:"formatted"` MiddleName string `json:"middleName"` HonorificPrefix string `json:"honorificPrefix"` HonorificSuffix string `json:"honorificSuffix"` }
Name type
type PostEventsRequest ¶ added in v0.0.8
type PostEventsRequest struct {
Data EventsRequest `validate:"required" json:"data"`
}
PostEventsRequest type
type PostGroupsRequest ¶ added in v0.0.8
type PostGroupsRequest struct {
Data GroupsRequest `validate:"required" json:"data"`
}
PostGroupsRequest type
type PostInvitesRequest ¶ added in v0.0.8
type PostInvitesRequest struct {
Data InvitesRequest `validate:"required" json:"data"`
}
PostInvitesRequest type
type PostUsersRequest ¶ added in v0.0.8
type PostUsersRequest struct {
Data UsersRequest `validate:"required" json:"data"`
}
PostUsersRequest holds request for user
type Profiles ¶
type Profiles struct { AdditionalProp1 Prop `json:"additionalProp1"` AdditionalProp2 Prop `json:"additionalProp2"` AdditionalProp3 Prop `json:"additionalProp3"` }
Profiles type
type Prop ¶
type Prop struct { Attributes struct { } `json:"attributes"` Data struct { } `json:"data"` }
Prop type
type PutGroupsRequest ¶ added in v0.0.8
type PutGroupsRequest struct { ScimID string `validate:"required" json:"scim_id"` Data GroupsRequest `validate:"required" json:"data"` }
PutGroupsRequest type
type PutUsersRequest ¶ added in v0.0.8
type PutUsersRequest struct { ScimID string `validate:"required" json:"scim_id"` Data UsersRequest `validate:"required" json:"data"` }
PutUsersRequest holds request for user
type Resource ¶
type Resource struct { ResourceType string `json:"resourceType"` ID string `json:"id"` LastModified time.Time `json:"lastModified"` Version string `json:"version"` ExternalID string `json:"externalId"` Location string `json:"location"` }
Resource type
type SearchGroupsRequest ¶ added in v0.0.8
type SearchGroupsRequest struct {
Data SearchRequest `validate:"required" json:"data"`
}
SearchGroupsRequest type
type SearchInvitesRequest ¶ added in v0.0.8
type SearchInvitesRequest struct {
Data SearchRequest `validate:"required" json:"data"`
}
SearchInvitesRequest type
type SearchReply ¶
type SearchReply struct { Schemas []string `json:"schemas"` Resources []struct { } `json:"Resources"` TotalResults int `json:"totalResults"` }
SearchReply type
type SearchRequest ¶
type SearchRequest struct { Schemas []string `json:"schemas"` Filter string `json:"filter"` StartIndex int `json:"startIndex"` Count int `json:"count"` Attributes []string `json:"attributes"` }
SearchRequest type
type SearchUsersRequest ¶ added in v0.0.8
type SearchUsersRequest struct {
Data SearchRequest `validate:"required" json:"data"`
}
SearchUsersRequest type
type StatusService ¶ added in v0.0.3
type StatusService struct {
// contains filtered or unexported fields
}
StatusService holds the object for Status
func (*StatusService) GetHealthy ¶ added in v0.0.3
func (s *StatusService) GetHealthy(ctx context.Context) (*HealthyReply, *http.Response, error)
GetHealthy gets health status
type TokenConfig ¶ added in v0.0.8
type TokenConfig struct { Certificate []byte PrivateKey []byte Password string Scope string Type string URL string Key string Client string }
TokenConfig configs token renew
type UsersReply ¶
type UsersReply struct { ID string `json:"id"` Meta Meta `json:"meta"` UsersRequest }
UsersReply type
type UsersRequest ¶
type UsersRequest struct { Schemas []string `json:"schemas"` ExternalID string `json:"externalId"` Name Name `json:"name"` Emails []ContactInfo `json:"emails"` PhoneNumbers []ContactInfo `json:"phoneNumbers"` PreferredLanguage string `json:"preferredLanguage"` Groups []Group `json:"groups"` HTTPSScimEduidSeSchemaNutidUserV1 HTTPSScimEduidSeSchemaNutidUserV1 `json:"https://scim.eduid.se/schema/nutid/user/v1"` }
UsersRequest type
type UsersService ¶
type UsersService struct {
// contains filtered or unexported fields
}
UsersService holds the object for Users
func (*UsersService) Get ¶
func (s *UsersService) Get(ctx context.Context, req *GetUsersRequest) (*UsersReply, *http.Response, error)
Get gets users from eduidIAM
func (*UsersService) Post ¶
func (s *UsersService) Post(ctx context.Context, req *PostUsersRequest) (*UsersReply, *http.Response, error)
Post posts user
func (*UsersService) Put ¶
func (s *UsersService) Put(ctx context.Context, req *PutUsersRequest) (*UsersReply, *http.Response, error)
Put puts on user
func (*UsersService) Search ¶
func (s *UsersService) Search(ctx context.Context, req *SearchUsersRequest) (*SearchReply, *http.Response, error)
Search searching for user