package userdebug

// UserDebugFeatureList user debug feature list
type UserDebugFeatureList struct {
	Features []*UserDebugFeatureListFeaturesItems `json:"features"`
	OrgID    string                               `json:"org_id,omitempty"`
}

// UserDebugFeatureListFeaturesItems user debug feature list features items
type UserDebugFeatureListFeaturesItems struct {
	Key    string `json:"key,omitempty"`
	Status string `json:"status,omitempty"`
}

// UserDebugAuthorizationList user debug authorization list
type UserDebugAuthorizationList struct {
	Items []*UserDebugAuthorizationDetail `json:"items"`
	Total int64                           `json:"total"`
}

// UserDebugAuthorizationDetail user debug authorization detail
type UserDebugAuthorizationDetail struct {
	ID           string                 `json:"id,omitempty"`
	AuthorizedBy *UserDebugAuthorizedBy `json:"authorized_by,omitempty"`
	ClusterID    string                 `json:"cluster_id,omitempty"`
	ClusterName  string                 `json:"cluster_name,omitempty"`
	CreatedAt    int64                  `json:"created_at,omitempty"`
	ExpiresAt    int64                  `json:"expires_at,omitempty"`
	ProjectID    string                 `json:"project_id,omitempty"`
	ProjectName  string                 `json:"project_name,omitempty"`
	Status       string                 `json:"status,omitempty"`
	UpdatedAt    int64                  `json:"updated_at,omitempty"`
}

// UserDebugAuthorizedBy user debug authorized by
type UserDebugAuthorizedBy struct {
	ID        string `json:"id"`
	Email     string `json:"email"`
	FirstName string `json:"first_name"`
	LastName  string `json:"last_name"`
}

// UserDebugAuthorization user debug authorization
type UserDebugAuthorization struct {
	Token string `json:"token,omitempty"`
	Valid bool   `json:"valid,omitempty"`
}

// UserDebugAuthorizationRecords user debug authorization records
type UserDebugAuthorizationRecords struct {
	Items []*UserDebugAuthorizationRecordItem `json:"items"`
	Total int64                               `json:"total"`
}

// UserDebugAuthorizationRecordItem user debug authorization record item
type UserDebugAuthorizationRecordItem struct {
	AuthID    string                 `json:"auth_id,omitempty"`
	CreatedAt int64                  `json:"created_at,omitempty"`
	ExpiresAt int64                  `json:"expires_at,omitempty"`
	Operation string                 `json:"operation,omitempty"`
	TimeSpan  int64                  `json:"time_span,omitempty"`
	User      *UserDebugAuthorizedBy `json:"user,omitempty"`
}
