Documentation ¶
Overview ¶
Package serviceaccount package
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateServiceAccountInput ¶
type CreateServiceAccountInput struct { Scope models.ScopeType OrgID *string ProjectID *string Name string Description string OIDCTrustPolicies []models.OIDCTrustPolicy }
CreateServiceAccountInput is the input for creating a service account
type CreateTokenInput ¶
CreateTokenInput for logging into a service account
type CreateTokenResponse ¶
CreateTokenResponse returned after logging into a service account
type DeleteServiceAccountInput ¶
DeleteServiceAccountInput is the input for deleting a service account
type GetServiceAccountsInput ¶
type GetServiceAccountsInput struct { // Sort specifies the field to sort on and direction Sort *db.ServiceAccountSortableField // PaginationOptions supports cursor based pagination PaginationOptions *pagination.Options // AgentID will filter service accounts that are assigned to the specified agent AgentID *string // OrganizationID will filter service accounts that are assigned to the specified organization OrganizationID *string // ProjectID will filter service accounts that are assigned to the specified project ProjectID *string // Search will filter service accounts that match the specified search string Search *string // ServiceAccountScopes will filter service accounts that are scope to specific level ServiceAccountScopes []models.ScopeType }
GetServiceAccountsInput is the input for querying a list of service accounts
type Service ¶
type Service interface { GetServiceAccountByID(ctx context.Context, id string) (*models.ServiceAccount, error) GetServiceAccountByPRN(ctx context.Context, prn string) (*models.ServiceAccount, error) GetServiceAccounts(ctx context.Context, input *GetServiceAccountsInput) (*db.ServiceAccountsResult, error) GetServiceAccountsByIDs(ctx context.Context, idList []string) ([]*models.ServiceAccount, error) CreateServiceAccount(ctx context.Context, input *CreateServiceAccountInput) (*models.ServiceAccount, error) UpdateServiceAccount(ctx context.Context, input *UpdateServiceAccountInput) (*models.ServiceAccount, error) DeleteServiceAccount(ctx context.Context, input *DeleteServiceAccountInput) error CreateToken(ctx context.Context, input *CreateTokenInput) (*CreateTokenResponse, error) }
Service implements all service account related functionality
func NewService ¶
func NewService( logger logger.Logger, dbClient *db.Client, limitChecker limits.LimitChecker, idp *auth.IdentityProvider, openIDConfigFetcher *auth.OpenIDConfigFetcher, activityService activityevent.Service, ) Service
NewService creates an instance of Service
type UpdateServiceAccountInput ¶
type UpdateServiceAccountInput struct { ID string Description *string MetadataVersion *int OIDCTrustPolicies []models.OIDCTrustPolicy }
UpdateServiceAccountInput is the input for updating a service account
Click to show internal directories.
Click to hide internal directories.