Documentation
¶
Index ¶
- func NewMultipartGQLWriter(req GraphQLRequestPayload) (*bytes.Buffer, *multipart.Writer, error)
- func NewMultipartWriter(req interface{}) (*bytes.Buffer, *multipart.Writer, error)
- type APIKey
- type APIKeyQueryParams
- type Asset
- type AssetParams
- type AssetVersion
- type AssetsResponse
- type Client
- type ControlType
- type CourseData
- type CreateAPIKeyResponse
- type CreateAssetResponse
- type CreateAssetVersionResponse
- type CreateEventResponse
- type CreateModuleResponse
- type CreateModuleVersionResponse
- type CreateOrgResponse
- type CreateSessionResponse
- type CreateUserResponse
- type CreateWebhookResponse
- type DeleteAPIKeyResponse
- type DeleteOrgResponse
- type DeleteUserResponse
- type DeleteWebhookResponse
- type Error
- type Event
- type EventResponse
- type EventResult
- type ExpiringModule
- type GetAPIKeysResponse
- type GetAssetResponse
- type GetAssetsResponse
- type GetControlTypesResponse
- type GetCourseDataResponse
- type GetExpiringModulesResponse
- type GetLearningHistoryResponse
- type GetModulesResponse
- type GetOrgResponse
- type GetOrgsResponse
- type GetPlatformsResponse
- type GetRolesResponse
- type GetUserResponse
- type GetWebhookResponse
- type GetWebhooksResponse
- type GitConfig
- type GraphQLRequestPayload
- type GraphQLResponse
- type LearningHistory
- type LearningHistoryParams
- type LoginRequest
- type LoginResponse
- type MockClient
- func (m *MockClient) ActiveOrgID() int
- func (m *MockClient) ActiveUserID() int
- func (m *MockClient) CheckAuth(ctx context.Context) (User, error)
- func (m *MockClient) CreateAPIKey(ctx context.Context, input APIKey) (*APIKey, error)
- func (m *MockClient) CreateAsset(ctx context.Context, asset *Asset) error
- func (m *MockClient) CreateAssetVersion(ctx context.Context, assetVersion *AssetVersion) error
- func (m *MockClient) CreateEvent(ctx context.Context, event *Event) error
- func (m *MockClient) CreateModuleVersion(ctx context.Context, input ModuleVersion) (*ModuleVersion, error)
- func (m *MockClient) CreateMultiplayerServerVersion(ctx context.Context, input MultiplayerServerVersion) (*MultiplayerServerVersion, error)
- func (m *MockClient) CreateOrg(ctx context.Context, org Org) (*Org, error)
- func (m *MockClient) CreateSession(ctx context.Context, session *Session) error
- func (m *MockClient) CreateUser(ctx context.Context, user *User) error
- func (m *MockClient) CreateWebhook(ctx context.Context, input Webhook) (*Webhook, error)
- func (m *MockClient) DeleteAPIKey(ctx context.Context, id int) error
- func (m *MockClient) DeleteOrg(ctx context.Context, id int) error
- func (m *MockClient) DeleteUser(ctx context.Context, id int) error
- func (m *MockClient) DeleteWebhook(ctx context.Context, id int) error
- func (m *MockClient) GetAPIKeys(ctx context.Context, params *APIKeyQueryParams) ([]APIKey, error)
- func (m *MockClient) GetAsset(ctx context.Context, id int) (*Asset, error)
- func (m *MockClient) GetAssets(ctx context.Context, params AssetParams) ([]Asset, error)
- func (m *MockClient) GetControlTypes(ctx context.Context) ([]ControlType, error)
- func (m *MockClient) GetCourseDataRecords(ctx context.Context, orgID int) ([]CourseData, error)
- func (m *MockClient) GetExpiringModules(ctx context.Context) ([]ExpiringModule, error)
- func (m *MockClient) GetLearningHistoryRecords(ctx context.Context, params LearningHistoryParams) ([]LearningHistory, error)
- func (m *MockClient) GetModules(ctx context.Context, params ...ModuleParams) ([]Module, error)
- func (m *MockClient) GetMultiplayerServerConfigs(ctx context.Context, params *MultiplayerServerConfigParams) ([]MultiplayerServerConfigQueryParams, error)
- func (m *MockClient) GetMultiplayerServerVersion(ctx context.Context, versionID int) (*MultiplayerServerVersion, error)
- func (m *MockClient) GetMultiplayerServerVersions(ctx context.Context, params *MultiplayerServerVersionParams) ([]MultiplayerServerVersion, error)
- func (m *MockClient) GetMultiplayerServerVersionsWithConfig(ctx context.Context, params *MultiplayerServerVersionParams) ([]MultiplayerServerVersion, error)
- func (m *MockClient) GetOrg(ctx context.Context, id int) (*Org, error)
- func (m *MockClient) GetOrgSuccessFactors(ctx context.Context) ([]OrgSuccessFactor, error)
- func (m *MockClient) GetOrgs(ctx context.Context, params ...*OrgParams) ([]Org, error)
- func (m *MockClient) GetPlatforms(ctx context.Context) ([]Platform, error)
- func (m *MockClient) GetRoles(ctx context.Context) ([]Role, error)
- func (m *MockClient) GetSession(ctx context.Context, id int) (*Session, error)
- func (m *MockClient) GetUser(ctx context.Context, id int) (*User, error)
- func (m *MockClient) GetUserByUsername(ctx context.Context, username string) (*User, error)
- func (m *MockClient) GetWebhook(ctx context.Context, id int) (*Webhook, error)
- func (m *MockClient) GetWebhooks(ctx context.Context, params *WebhookParams) ([]Webhook, error)
- func (m *MockClient) Path() string
- func (m *MockClient) PostAsset(ctx context.Context, assetVersion *AssetVersion) error
- func (m *MockClient) Reset()
- func (m *MockClient) RetrieveAssets(ctx context.Context, params AssetParams) ([]Asset, error)
- func (m *MockClient) UpdateAssetVersion(ctx context.Context, assetVersion *AssetVersion) error
- func (m *MockClient) UpdateMultiplayerServerVersion(ctx context.Context, input MultiplayerServerVersion) (*MultiplayerServerVersion, error)
- func (m *MockClient) UpdateOrg(ctx context.Context, org Org) (*Org, error)
- func (m *MockClient) UpdateSession(ctx context.Context, session Session) (*Session, error)
- func (m *MockClient) UpdateUser(ctx context.Context, user *User) error
- func (m *MockClient) UpdateWebhook(ctx context.Context, input Webhook) (*Webhook, error)
- type Module
- type ModuleParams
- type ModuleVersion
- type MultiplayerServerConfig
- type MultiplayerServerConfigParams
- type MultiplayerServerConfigQuery
- type MultiplayerServerConfigQueryParams
- type MultiplayerServerTrigger
- type MultiplayerServerVersion
- type MultiplayerServerVersionParams
- type MultiplayerServerVersionQuery
- type Org
- type OrgColors
- type OrgParams
- type OrgSuccessFactor
- type OrgSuccessFactorsResponse
- type Platform
- type PostAssetVersionResponse
- type Role
- type Session
- type SessionResponse
- type UpdateAssetVersionResponse
- type UpdateEventResponse
- type UpdateOrgResponse
- type UpdateSessionResponse
- type UpdateUserResponse
- type UpdateWebhookResponse
- type User
- type Webhook
- type WebhookParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMultipartGQLWriter ¶
Types ¶
type APIKeyQueryParams ¶
type APIKeyQueryParams struct {
UserID *int `json:"userId" graphql:"userId"`
}
type Asset ¶
type Asset struct {
ID int `json:"id,omitempty"`
Name string `json:"name,omitempty" yaml:"name,omitempty"`
Type string `json:"type,omitempty"`
Tags []string `json:"tags,omitempty"`
ModuleID int `json:"moduleId,omitempty"`
Module *Module `json:"module,omitempty"`
Versions []AssetVersion `json:"versions,omitempty" yaml:"versions,omitempty"`
Checksum string `json:"checksum,omitempty"`
DownloadLink string `json:"downloadLink,omitempty"`
CreatedAt time.Time `json:"createdAt,omitempty"`
UpdatedAt time.Time `json:"updatedAt,omitempty"`
}
type AssetParams ¶
type AssetParams struct {
ModuleID int `json:"moduleId,omitempty"`
ExternalModuleID string `json:"externalModuleId,omitempty"`
Name string `json:"name,omitempty"`
Type string `json:"type,omitempty"`
Status string `json:"status,omitempty"`
LanguageCode string `json:"languageCode,omitempty"`
Tags []string `json:"tags,omitempty"`
WithVersions bool `json:"withVersions,omitempty"`
WithChecksum bool `json:"withChecksum,omitempty"`
}
type AssetVersion ¶
type AssetVersion struct {
ID int `json:"id,omitempty"`
Status string `json:"status,omitempty"`
LanguageCode string `json:"languageCode,omitempty"`
Language string `json:"language,omitempty"`
FileLink string `json:"fileLink,omitempty"`
LocalFilePath string `json:"-"`
AssetID int `json:"assetId,omitempty"`
Asset *Asset `json:"asset,omitempty"`
CreatedAt time.Time `json:"createdAt,omitempty"`
UpdatedAt time.Time `json:"updatedAt,omitempty"`
}
type AssetsResponse ¶
type Client ¶
type Client interface {
abstract.AbstractClient
CheckAuth(ctx context.Context) (User, error)
ActiveUserID() int
ActiveOrgID() int
GetUser(ctx context.Context, id int) (*User, error)
GetUserByUsername(ctx context.Context, username string) (*User, error)
CreateUser(ctx context.Context, user *User) error
UpdateUser(ctx context.Context, user *User) error
DeleteUser(ctx context.Context, id int) error
GetAPIKeys(ctx context.Context, params *APIKeyQueryParams) ([]APIKey, error)
CreateAPIKey(ctx context.Context, input APIKey) (*APIKey, error)
DeleteAPIKey(ctx context.Context, id int) error
GetWebhooks(ctx context.Context, params *WebhookParams) ([]Webhook, error)
GetWebhook(ctx context.Context, id int) (*Webhook, error)
CreateWebhook(ctx context.Context, input Webhook) (*Webhook, error)
UpdateWebhook(ctx context.Context, input Webhook) (*Webhook, error)
DeleteWebhook(ctx context.Context, id int) error
GetRoles(ctx context.Context) ([]Role, error)
// GetPlatforms retrieves platforms from the platform using the GraphQL interface
GetPlatforms(ctx context.Context) ([]Platform, error)
// GetControlTypes retrieves control types from the platform using the GraphQL interface
GetControlTypes(ctx context.Context) ([]ControlType, error)
// GetModules retrieves modules from the platform using the GraphQL interface
GetModules(ctx context.Context, params ...ModuleParams) ([]Module, error)
// CreateModuleVersion retrieves a module from the platform using the GraphQL interface
CreateModuleVersion(ctx context.Context, input ModuleVersion) (*ModuleVersion, error)
// GetOrgs retrieves orgs from the platform using the GraphQL interface
GetOrgs(ctx context.Context, params ...*OrgParams) ([]Org, error)
// GetOrg retrieves an org from the platform using the GraphQL interface
GetOrg(ctx context.Context, id int) (*Org, error)
// CreateOrg creates an org on the platform using the GraphQL interface
CreateOrg(ctx context.Context, org Org) (*Org, error)
// UpdateOrg updates an org on the platform using the GraphQL interface
UpdateOrg(ctx context.Context, org Org) (*Org, error)
// DeleteOrg deletes an org on the platform using the GraphQL interface
DeleteOrg(ctx context.Context, id int) error
// GetAsset retrieves an asset from the platform using the GraphQL interface
GetAsset(ctx context.Context, id int) (*Asset, error)
// GetAssets retrieves assets from the platform using the GraphQL interface
GetAssets(ctx context.Context, params AssetParams) ([]Asset, error)
// CreateAsset creates an asset on the platform using the GraphQL interface
CreateAsset(ctx context.Context, asset *Asset) error
// CreateAssetVersion creates an asset version on the platform using the GraphQL interface
CreateAssetVersion(ctx context.Context, assetVersion *AssetVersion) error
// UpdateAssetVersion updates an asset version on the platform using the GraphQL interface
UpdateAssetVersion(ctx context.Context, assetVersion *AssetVersion) error
// PostAsset posts an asset to the platform using the REST API
PostAsset(ctx context.Context, assetVersion *AssetVersion) error
// RetrieveAssets retrieves assets from the platform using the REST API
RetrieveAssets(ctx context.Context, params AssetParams) ([]Asset, error)
// GetSession retrieves a session from the platform using the GraphQL interface
GetSession(ctx context.Context, id int) (*Session, error)
// CreateSession creates a session on the platform using the GraphQL interface
CreateSession(ctx context.Context, session *Session) error
// UpdateSession updates a session on the platform using the GraphQL interface
UpdateSession(ctx context.Context, session Session) (*Session, error)
// CreateEvent creates an event on the platform using the GraphQL interface
CreateEvent(ctx context.Context, event *Event) error
// GetMultiplayerServerConfigs retrieves multiplayer server configs from the platform using the GraphQL interface
GetMultiplayerServerConfigs(ctx context.Context, params *MultiplayerServerConfigParams) ([]MultiplayerServerConfigQueryParams, error)
// GetMultiplayerServerVersions retrieves multiplayer server versions from the platform using the GraphQL interface
GetMultiplayerServerVersions(ctx context.Context, params *MultiplayerServerVersionParams) ([]MultiplayerServerVersion, error)
// GetMultiplayerServerVersionsWithConfig retrieves multiplayer server versions with config from the platform using the GraphQL interface
GetMultiplayerServerVersionsWithConfig(ctx context.Context, params *MultiplayerServerVersionParams) ([]MultiplayerServerVersion, error)
// GetMultiplayerServerVersion retrieves a multiplayer server version from the platform using the GraphQL interface
GetMultiplayerServerVersion(ctx context.Context, id int) (*MultiplayerServerVersion, error)
// CreateMultiplayerServerVersion creates a multiplayer server version on the platform using the GraphQL interface
CreateMultiplayerServerVersion(ctx context.Context, input MultiplayerServerVersion) (*MultiplayerServerVersion, error)
// UpdateMultiplayerServerVersion updates a multiplayer server version on the platform using the GraphQL interface
UpdateMultiplayerServerVersion(ctx context.Context, input MultiplayerServerVersion) (*MultiplayerServerVersion, error)
// GetLearningHistoryRecords retrieves success factors learning history records from the platform using the GraphQL interface
GetLearningHistoryRecords(ctx context.Context, params LearningHistoryParams) ([]LearningHistory, error)
// GetCourseData retrieves success factors course data from the platform using the GraphQL interface
GetCourseDataRecords(ctx context.Context, orgID int) ([]CourseData, error)
// GetOrgSuccessFactors retrieves success factors org success factors from the platform using the GraphQL interface
GetOrgSuccessFactors(ctx context.Context) ([]OrgSuccessFactor, error)
// GetExpiringModules retrieves expiring modules from the platform using the GraphQL interface
GetExpiringModules(ctx context.Context) ([]ExpiringModule, error)
}
func NewClient ¶
func NewClient(config urlfinder.ClientConfig) Client
NewClient is a function that returns a clientImpl
func NewClientWithBasicAuth ¶
func NewClientWithBasicAuth(username, password string, config urlfinder.ClientConfig) (Client, error)
NewClientWithBasicAuth is a function that returns a clientImpl with basic auth performed
type ControlType ¶
type CourseData ¶
type CourseData struct {
ID int `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
ImageName string `json:"imageName"`
ImagePath string `json:"imagePath"`
ThumbnailPath string `json:"thumbnailPath"`
PDFPath string `json:"pdfPath"`
PDFName string `json:"pdfName"`
ShortDesc string `json:"shortDesc"`
LongDesc string `json:"longDesc"`
Details string `json:"details"`
Public bool `json:"public"`
Demo bool `json:"demo"`
Status string `json:"status"`
Deleted bool `json:"deleted"`
Industry string `json:"industry"`
DistributorID int `json:"distributorId"`
Developer string `json:"developer"`
UpdatedBy string `json:"updatedBy"`
IsMultiplayer bool `json:"isMultiplayer"`
PassingScoreEnabled bool `json:"passingScoreEnabled"`
ExternalID string `json:"externalId"`
LearningType string `json:"learningType"`
CompleteStatus string `json:"completeStatus"`
CreatedAt string `json:"createdAt"`
UpdatedAt string `json:"updatedAt"`
}
type CreateAPIKeyResponse ¶
type CreateAPIKeyResponse struct {
APIKey APIKey `json:"createApiKey"`
}
type CreateAssetResponse ¶
type CreateAssetResponse struct {
Asset Asset `json:"createAsset"`
}
type CreateAssetVersionResponse ¶
type CreateAssetVersionResponse struct {
AssetVersion AssetVersion `json:"createAssetVersion"`
}
type CreateEventResponse ¶
type CreateEventResponse struct {
Event Event `json:"createEvent"`
}
type CreateModuleResponse ¶
type CreateModuleResponse struct {
Module Module `json:"createModule"`
}
type CreateModuleVersionResponse ¶
type CreateModuleVersionResponse struct {
ModuleVersion ModuleVersion `json:"createModuleVersion"`
}
type CreateOrgResponse ¶
type CreateOrgResponse struct {
Org Org `json:"createOrg"`
}
type CreateSessionResponse ¶
type CreateSessionResponse struct {
Session Session `json:"createSession"`
}
type CreateUserResponse ¶
type CreateUserResponse struct {
User User `json:"createUser"`
}
type CreateWebhookResponse ¶
type CreateWebhookResponse struct {
Webhook Webhook `json:"createWebhook"`
}
type DeleteAPIKeyResponse ¶
type DeleteAPIKeyResponse struct {
Success bool `json:"deleteApiKey"`
}
type DeleteOrgResponse ¶
type DeleteOrgResponse struct {
Success bool `json:"deleteOrg"`
}
type DeleteUserResponse ¶
type DeleteUserResponse struct {
Success bool `json:"deleteUser"`
}
type DeleteWebhookResponse ¶
type DeleteWebhookResponse struct {
Success bool `json:"deleteWebhook"`
}
type Event ¶
type Event struct {
ID int `json:"id,omitempty"`
SessionID *int `json:"sessionId,omitempty"`
SessionUUID *string `json:"sessionUuid,omitempty"`
Session *Session `json:"session,omitempty"`
Type string `json:"type,omitempty"`
Payload string `json:"payload,omitempty"`
PayloadMap map[string]interface{} `json:"-"`
CreatedAt time.Time `json:"createdAt,omitempty"`
UpdatedAt time.Time `json:"updatedAt,omitempty"`
}
type EventResponse ¶
type EventResponse struct {
Event Event `json:"event"`
}
type EventResult ¶
type ExpiringModule ¶
type ExpiringModule struct {
OrgModuleID int `json:"orgModuleId"`
ExpiresAt time.Time `json:"expiresAt"`
ModuleName string `json:"moduleName"`
Description string `json:"description"`
ShortDesc string `json:"shortDesc"`
OrgID int `json:"orgId"`
OrgName string `json:"orgName"`
Type string `json:"type"`
}
type GetAPIKeysResponse ¶
type GetAPIKeysResponse struct {
APIKeys []APIKey `json:"apiKeys"`
}
type GetAssetResponse ¶
type GetAssetResponse struct {
Asset Asset `json:"asset"`
}
type GetAssetsResponse ¶
type GetAssetsResponse struct {
Assets []Asset `json:"assets"`
}
type GetControlTypesResponse ¶
type GetControlTypesResponse struct {
ControlTypes []ControlType `json:"controls,omitempty"`
}
type GetCourseDataResponse ¶
type GetCourseDataResponse struct {
CourseDataRecords []CourseData `json:"courseData"`
}
type GetExpiringModulesResponse ¶
type GetExpiringModulesResponse struct {
ExpiringModules []ExpiringModule `json:"expiringModules"`
}
type GetLearningHistoryResponse ¶
type GetLearningHistoryResponse struct {
LearningHistoryRecords []LearningHistory `json:"learningHistory"`
}
type GetModulesResponse ¶
type GetModulesResponse struct {
Modules []Module `json:"modules"`
}
type GetOrgResponse ¶
type GetOrgResponse struct {
Org Org `json:"org"`
}
type GetOrgsResponse ¶
type GetOrgsResponse struct {
Orgs []Org `json:"orgs"`
}
type GetPlatformsResponse ¶
type GetPlatformsResponse struct {
Platforms []Platform `json:"platforms,omitempty"`
}
type GetRolesResponse ¶
type GetRolesResponse struct {
Roles []Role `json:"roles"`
}
type GetUserResponse ¶
type GetUserResponse struct {
User User `json:"user"`
}
type GetWebhookResponse ¶
type GetWebhookResponse struct {
Webhook Webhook `json:"webhook"`
}
type GetWebhooksResponse ¶
type GetWebhooksResponse struct {
Webhooks []Webhook `json:"webhooks"`
}
type GraphQLRequestPayload ¶
type GraphQLResponse ¶
type GraphQLResponse struct {
Messages []string `json:"messages"`
Errors []Error `json:"errors"`
Data json.RawMessage `json:"data"`
}
type LearningHistory ¶
type LearningHistory struct {
ID int `json:"id"`
UserID int `json:"userId"`
ModuleID int `json:"moduleId"`
OrgID int `json:"orgId"`
UserEmail string `json:"userEmail"`
ModuleExternalID string `json:"moduleExternalId"`
ModuleLearningType string `json:"moduleLearningType"`
ModuleCompleteStatus string `json:"moduleCompleteStatus"`
Score float64 `json:"score"`
SessionDuration int `json:"sessionDuration"`
CreatedAt string `json:"createdAt"`
}
type LearningHistoryParams ¶
type LoginRequest ¶
type LoginResponse ¶
type MockClient ¶
type MockClient struct {
abstract.MockAbstractClient
NumCalledGetUser int
GetUserResponse *User
GetUserError error
NumCalledGetUserByUsername int
GetUserByUsernameError error
NumCalledGetUsers int
GetUsersError error
NumCalledCreateUser int
CreateUserError error
NumCalledUpdateUser int
UpdateUserError error
NumCalledDeleteUser int
DeleteUserError error
NumCalledGetRoles int
GetRolesError error
NumCalledGetOrgs int
GetOrgsError error
NumCalledGetOrg int
GetOrgError error
NumCalledCreateOrg int
CreateOrgError error
NumCalledUpdateOrg int
UpdateOrgError error
NumCalledDeleteOrg int
DeleteOrgError error
NumCalledGetWebhooks int
GetWebhooksError error
NumCalledGetWebhook int
GetWebhookError error
NumCalledCreateWebhook int
CreateWebhookError error
NumCalledUpdateWebhook int
UpdateWebhookError error
NumCalledDeleteWebhook int
DeleteWebhookError error
NumCalledGetModules int
GetModulesEmpty bool
GetModulesError error
NumCalledGetAPIKeys int
GetAPIKeysEmpty bool
GetAPIKeysError error
NumCalledCreateAPIKey int
CreateAPIKeyError error
NumCalledDeleteAPIKey int
DeleteAPIKeyError error
NumCalledGetSession int
GetSessionError error
CalledGetAssetWith []*Asset
GetAssetReturns *Asset
GetAssetError error
CalledGetAssetsWith []*AssetParams
GetAssetsReturns []Asset
GetAssetsError error
CalledCreateAssetWith []*Asset
CreateAssetError error
CalledCreateAssetVersionWith []*AssetVersion
CreateAssetVersionError error
CalledUpdateAssetVersionWith []AssetVersion
UpdateAssetVersionError error
CalledPostAssetWith []AssetVersion
PostAssetError error
CalledRetrieveAssetsWith []AssetParams
RetrieveAssetsReturns []Asset
RetrieveAssetsError error
CalledCreateSessionWith []*Session
CreateSessionError error
CalledUpdateSessionWith []*Session
UpdateSessionError error
CalledCreateEventWith []*Event
CreateEventError error
NumCalledGetPlatforms int
GetPlatformsError error
NumCalledGetControlTypes int
GetControlTypesError error
NumCalledCreateModuleVersion int
CreateModuleVersionError error
NumCalledGetMultiplayerServerConfigs int
GetMultiplayerServerConfigsError error
GetMultiplayerServerConfigsEmpty bool
GetMultiplayerServerConfigsEmptyVersions bool
NumCalledGetMultiplayerServerVersionsWithConfig int
GetMultiplayerServerVersionsWithConfigError error
GetMultiplayerServerVersionsWithConfigEmpty bool
NumCalledGetMultiplayerServerVersions int
GetMultiplayerServerVersionsError error
GetMultiplayerServerVersionsEmpty bool
GetMultiplayerServerVersionsResponse []MultiplayerServerVersion
NumCalledGetMultiplayerServerVersion int
GetMultiplayerServerVersionError error
GetMultiplayerServerVersionEmpty bool
NumCalledCreateMultiplayerServerVersion int
CreateMultiplayerServerVersionError error
NumCalledUpdateMultiplayerServerVersion int
UpdateMultiplayerServerVersionError error
NumCalledGetLearningHistoryRecords int
GetLearningHistoryRecordsError error
LearningHistoryRecordsToReturn []LearningHistory
NumCalledGetCourseDataRecords int
GetCourseDataRecordsError error
CourseDataRecordsToReturn []CourseData
NumCalledGetOrgSuccessFactors int
GetOrgSuccessFactorsError error
OrgSuccessFactorsToReturn []OrgSuccessFactor
NumCalledGetExpiringModules int
GetExpiringModulesError error
ExpiringModulesToReturn []ExpiringModule
}
func (*MockClient) ActiveOrgID ¶
func (m *MockClient) ActiveOrgID() int
func (*MockClient) ActiveUserID ¶
func (m *MockClient) ActiveUserID() int
func (*MockClient) CreateAPIKey ¶
func (*MockClient) CreateAsset ¶
func (m *MockClient) CreateAsset(ctx context.Context, asset *Asset) error
func (*MockClient) CreateAssetVersion ¶
func (m *MockClient) CreateAssetVersion(ctx context.Context, assetVersion *AssetVersion) error
func (*MockClient) CreateEvent ¶
func (m *MockClient) CreateEvent(ctx context.Context, event *Event) error
func (*MockClient) CreateModuleVersion ¶
func (m *MockClient) CreateModuleVersion(ctx context.Context, input ModuleVersion) (*ModuleVersion, error)
func (*MockClient) CreateMultiplayerServerVersion ¶
func (m *MockClient) CreateMultiplayerServerVersion(ctx context.Context, input MultiplayerServerVersion) (*MultiplayerServerVersion, error)
func (*MockClient) CreateSession ¶
func (m *MockClient) CreateSession(ctx context.Context, session *Session) error
func (*MockClient) CreateUser ¶
func (m *MockClient) CreateUser(ctx context.Context, user *User) error
func (*MockClient) CreateWebhook ¶
func (*MockClient) DeleteAPIKey ¶
func (m *MockClient) DeleteAPIKey(ctx context.Context, id int) error
func (*MockClient) DeleteUser ¶
func (m *MockClient) DeleteUser(ctx context.Context, id int) error
func (*MockClient) DeleteWebhook ¶
func (m *MockClient) DeleteWebhook(ctx context.Context, id int) error
func (*MockClient) GetAPIKeys ¶
func (m *MockClient) GetAPIKeys(ctx context.Context, params *APIKeyQueryParams) ([]APIKey, error)
func (*MockClient) GetAssets ¶
func (m *MockClient) GetAssets(ctx context.Context, params AssetParams) ([]Asset, error)
func (*MockClient) GetControlTypes ¶
func (m *MockClient) GetControlTypes(ctx context.Context) ([]ControlType, error)
func (*MockClient) GetCourseDataRecords ¶
func (m *MockClient) GetCourseDataRecords(ctx context.Context, orgID int) ([]CourseData, error)
func (*MockClient) GetExpiringModules ¶
func (m *MockClient) GetExpiringModules(ctx context.Context) ([]ExpiringModule, error)
func (*MockClient) GetLearningHistoryRecords ¶
func (m *MockClient) GetLearningHistoryRecords(ctx context.Context, params LearningHistoryParams) ([]LearningHistory, error)
func (*MockClient) GetModules ¶
func (m *MockClient) GetModules(ctx context.Context, params ...ModuleParams) ([]Module, error)
func (*MockClient) GetMultiplayerServerConfigs ¶
func (m *MockClient) GetMultiplayerServerConfigs(ctx context.Context, params *MultiplayerServerConfigParams) ([]MultiplayerServerConfigQueryParams, error)
func (*MockClient) GetMultiplayerServerVersion ¶
func (m *MockClient) GetMultiplayerServerVersion(ctx context.Context, versionID int) (*MultiplayerServerVersion, error)
func (*MockClient) GetMultiplayerServerVersions ¶
func (m *MockClient) GetMultiplayerServerVersions(ctx context.Context, params *MultiplayerServerVersionParams) ([]MultiplayerServerVersion, error)
func (*MockClient) GetMultiplayerServerVersionsWithConfig ¶
func (m *MockClient) GetMultiplayerServerVersionsWithConfig(ctx context.Context, params *MultiplayerServerVersionParams) ([]MultiplayerServerVersion, error)
func (*MockClient) GetOrgSuccessFactors ¶
func (m *MockClient) GetOrgSuccessFactors(ctx context.Context) ([]OrgSuccessFactor, error)
func (*MockClient) GetPlatforms ¶
func (m *MockClient) GetPlatforms(ctx context.Context) ([]Platform, error)
func (*MockClient) GetSession ¶
func (*MockClient) GetUserByUsername ¶
func (*MockClient) GetWebhook ¶
func (*MockClient) GetWebhooks ¶
func (m *MockClient) GetWebhooks(ctx context.Context, params *WebhookParams) ([]Webhook, error)
func (*MockClient) Path ¶
func (m *MockClient) Path() string
func (*MockClient) PostAsset ¶
func (m *MockClient) PostAsset(ctx context.Context, assetVersion *AssetVersion) error
func (*MockClient) Reset ¶
func (m *MockClient) Reset()
func (*MockClient) RetrieveAssets ¶
func (m *MockClient) RetrieveAssets(ctx context.Context, params AssetParams) ([]Asset, error)
func (*MockClient) UpdateAssetVersion ¶
func (m *MockClient) UpdateAssetVersion(ctx context.Context, assetVersion *AssetVersion) error
func (*MockClient) UpdateMultiplayerServerVersion ¶
func (m *MockClient) UpdateMultiplayerServerVersion(ctx context.Context, input MultiplayerServerVersion) (*MultiplayerServerVersion, error)
func (*MockClient) UpdateSession ¶
func (*MockClient) UpdateUser ¶
func (m *MockClient) UpdateUser(ctx context.Context, user *User) error
func (*MockClient) UpdateWebhook ¶
type Module ¶
type Module struct {
ID int `json:"id,omitempty"`
Name string `json:"name,omitempty"`
Abbreviation string `json:"abbreviation,omitempty"`
Description string `json:"description,omitempty"`
ImageLink string `json:"imageLink,omitempty"`
ShortDesc string `json:"shortDesc,omitempty"`
ExternalID string `json:"externalId,omitempty"`
GitConfigID int `json:"gitConfigId,omitempty"`
GitConfig GitConfig `json:"gitConfig,omitempty"`
CreatedAt time.Time `json:"createdAt,omitempty"`
UpdatedAt time.Time `json:"updatedAt,omitempty"`
}
type ModuleParams ¶
type ModuleParams struct {
Name string `json:"name"`
}
type ModuleVersion ¶
type ModuleVersion struct {
ID int `json:"id,omitempty"`
ModuleID int `json:"moduleId,omitempty"`
Module Module `json:"module,omitempty"`
Status string `json:"status,omitempty"`
FileLink string `json:"fileLink,omitempty"`
SemanticVersion string `json:"version,omitempty"`
Notes string `json:"notes,omitempty"`
Package string `json:"package,omitempty"`
ExternalID string `json:"externalId,omitempty"`
LocalFilePath string `json:"-"`
ControlIds []int `json:"controlIds,omitempty"`
PlatformIds []int `json:"platformIds,omitempty"`
}
type MultiplayerServerConfig ¶
type MultiplayerServerConfig struct {
ID int `json:"id"`
Capacity int `json:"capacity,omitempty"`
StandbyReplicas string `json:"standbyReplicas,omitempty"`
Disabled bool `json:"disabled,omitempty"`
ModuleID int `json:"moduleId,omitempty"`
Module *Module `json:"module,omitempty"`
ServerVersions []MultiplayerServerVersion `json:"serverVersions,omitempty"`
CreatedBy string `json:"createdBy,omitempty"`
UpdatedBy string `json:"updatedBy,omitempty"`
CreatedAt *time.Time `json:"createdAt,omitempty"`
UpdatedAt *time.Time `json:"updatedAt,omitempty"`
}
type MultiplayerServerConfigParams ¶
type MultiplayerServerConfigParams struct {
ModuleID int `json:"moduleId,omitempty"`
OrgID int `json:"orgId,omitempty"`
ServerVersion string `json:"serverVersion,omitempty"`
Capacity int `json:"capacity,omitempty"`
ServerVersions []MultiplayerServerVersion `json:"serverVersions,omitempty"`
}
type MultiplayerServerConfigQuery ¶
type MultiplayerServerConfigQuery struct {
MultiplayerServerConfigs []MultiplayerServerConfigQueryParams `graphql:"multiplayerServerConfigs(params: $params)"`
}
type MultiplayerServerConfigQueryParams ¶
type MultiplayerServerConfigQueryParams struct {
ID int `json:"id" graphql:"id"`
ModuleID int `json:"moduleId" graphql:"moduleId"`
Capacity int `json:"capacity" graphql:"capacity"`
Disabled bool `json:"disabled" graphql:"disabled"`
Module struct {
ID int `json:"id" graphql:"id"`
Name string `json:"name" graphql:"name"`
}
ServerVersions []MultiplayerServerVersion `json:"serverVersions" graphql:"serverVersions"`
}
type MultiplayerServerTrigger ¶
type MultiplayerServerTrigger struct {
ID int `json:"id,omitempty"`
Revision string `json:"revision,omitempty"`
Dockerfile string `json:"dockerfile,omitempty"`
Context string `json:"context,omitempty"`
Config string `json:"config,omitempty"`
Module *Module `json:"module,omitempty"`
ModuleID int `json:"moduleId,omitempty"`
CreatedBy string `json:"createdBy,omitempty"`
UpdatedBy string `json:"updatedBy,omitempty"`
CreatedAt *time.Time `json:"createdAt,omitempty"`
UpdatedAt *time.Time `json:"updatedAt,omitempty"`
}
type MultiplayerServerVersion ¶
type MultiplayerServerVersion struct {
ID int `json:"id,omitempty" graphql:"id"`
Engine string `json:"engine,omitempty" graphql:"engine"`
Status string `json:"status,omitempty" graphql:"status"`
ImageRegistry string `json:"imageRegistry,omitempty" graphql:"imageRegistry"`
SemanticVersion string `json:"semanticVersion,omitempty" graphql:"semanticVersion"`
FileLink string `json:"fileLink,omitempty" graphql:"fileLink"`
FilePath string `json:"filePath,omitempty" graphql:"filePath"`
LocalFilePath string `json:"-" graphql:"-"`
ModuleID int `json:"moduleId,omitempty" graphql:"moduleId"`
Module *Module `json:"module,omitempty" graphql:"module"`
CreatedBy string `json:"createdBy,omitempty" graphql:"createdBy"`
UpdatedBy string `json:"updatedBy,omitempty" graphql:"updatedBy"`
CreatedAt *time.Time `json:"createdAt,omitempty" graphql:"createdAt"`
UpdatedAt *time.Time `json:"updatedAt,omitempty" graphql:"updatedAt"`
}
type MultiplayerServerVersionQuery ¶
type MultiplayerServerVersionQuery struct {
MultiplayerServerVersions []MultiplayerServerVersion `graphql:"multiplayerServerVersions(params: $params)"`
}
type Org ¶
type Org struct {
ID int `json:"id"`
Name string `json:"name"`
Type string `json:"type"`
Status string `json:"enabled"`
LogoLink string `json:"logoLink"`
HubLogoLink string `json:"hubLogoLink"`
PrimaryColor string `json:"primaryColor"`
SecondaryColor string `json:"secondaryColor"`
InheritedColors OrgColors `json:"inheritedColors"`
OpenAccess bool `json:"openAccess"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
}
type OrgSuccessFactor ¶
type OrgSuccessFactorsResponse ¶
type OrgSuccessFactorsResponse struct {
OrgSuccessFactors []OrgSuccessFactor `json:"orgSuccessFactors"`
}
type PostAssetVersionResponse ¶
type PostAssetVersionResponse struct {
Message string `json:"message"`
Error string `json:"error"`
Asset Asset `json:"asset"`
AssetVersion AssetVersion `json:"version"`
}
type Session ¶
type Session struct {
ID int `json:"id,omitempty"`
UUID *string `json:"uuid,omitempty"`
IPAddress string `json:"ipAddress,omitempty"`
DeviceID string `json:"deviceId,omitempty"`
RawScore float64 `json:"rawScore,omitempty"`
MaxScore float64 `json:"maxScore,omitempty"`
ScaledScore float64 `json:"scaledScore,omitempty"`
Status string `json:"status,omitempty"`
LessonStatus string `json:"lessonStatus,omitempty"`
Scenario string `json:"scenario,omitempty"`
Mode string `json:"mode,omitempty"`
Focus string `json:"focus,omitempty"`
Specialization string `json:"specialization,omitempty"`
Completed bool `json:"completed,omitempty"`
CompletedAt string `json:"completedAt,omitempty"`
Duration string `json:"duration,omitempty"`
UserID int `json:"userId,omitempty"`
User User `json:"user,omitempty"`
OrgID int `json:"orgId,omitempty"`
Org Org `json:"org,omitempty"`
ModuleID int `json:"moduleId,omitempty"`
Module Module `json:"module,omitempty"`
ModuleVersion string `json:"moduleVersion,omitempty"`
Events []Event `json:"events,omitempty"`
CreatedAt time.Time `json:"createdAt,omitempty"`
UpdatedAt time.Time `json:"updatedAt,omitempty"`
JoinExtensions *string `json:"joinExtensions,omitempty"`
CompleteExtensions *string `json:"completeExtensions,omitempty"`
EventResult *EventResult `json:"eventResult,omitempty"`
}
type SessionResponse ¶
type SessionResponse struct {
Session Session `json:"session"`
}
type UpdateAssetVersionResponse ¶
type UpdateAssetVersionResponse struct {
AssetVersion AssetVersion `json:"updateAssetVersion"`
}
type UpdateEventResponse ¶
type UpdateEventResponse struct {
Event Event `json:"updateEvent"`
}
type UpdateOrgResponse ¶
type UpdateOrgResponse struct {
Org Org `json:"updateOrg"`
}
type UpdateSessionResponse ¶
type UpdateSessionResponse struct {
Session Session `json:"updateSession"`
}
type UpdateUserResponse ¶
type UpdateUserResponse struct {
User User `json:"updateUser"`
}
type UpdateWebhookResponse ¶
type UpdateWebhookResponse struct {
Webhook Webhook `json:"updateWebhook"`
}
type User ¶
type User struct {
ID int `json:"id,omitempty"`
Role string `json:"role,omitempty"`
OrgID int `json:"orgId,omitempty"`
Org Org `json:"org,omitempty"`
Username string `json:"username,omitempty"`
Password string `json:"-"`
FirstName string `json:"firstName,omitempty"`
LastName string `json:"lastName,omitempty"`
Email string `json:"email,omitempty"`
ExternalID string `json:"externalId,omitempty"`
CreatedAt time.Time `json:"createdAt,omitempty"`
UpdatedAt time.Time `json:"updatedAt,omitempty"`
}
type Webhook ¶
type Webhook struct {
ID int `json:"id,omitempty"`
URL string `json:"url,omitempty"`
EventTypes []string `json:"eventTypes,omitempty"`
Description string `json:"description,omitempty"`
Token string `json:"token,omitempty"`
GenerateToken *bool `json:"generateToken,omitempty"`
OrgID int `json:"orgId,omitempty"`
Org *Org `json:"org,omitempty"`
}
type WebhookParams ¶
type WebhookParams struct {
OrgID int `json:"orgId"`
}
Click to show internal directories.
Click to hide internal directories.