mirror of
https://github.com/zitadel/zitadel.git
synced 2024-12-12 11:04:25 +00:00
7451ed58f2
* feat: user meta data events * feat: user meta data set tests * feat: user meta data tests * feat: user meta data in protos * feat: user meta data command api * feat: user meta data query side * feat: proto correct order, fix handlers * feat: proto correct order * feat: fixes of pr comments * feat: fixes of pr comments * feat: value as byte array * feat: metadata feature * Update internal/auth/repository/eventsourcing/handler/meta_data.go Co-authored-by: Silvan <silvan.reusser@gmail.com> * Update internal/command/user_meta_data.go Co-authored-by: Silvan <silvan.reusser@gmail.com> * Update proto/zitadel/metadata.proto Co-authored-by: Silvan <silvan.reusser@gmail.com> * Update proto/zitadel/metadata.proto Co-authored-by: Silvan <silvan.reusser@gmail.com> * fix: rename metadata files and table * fix: rename meta data to metadat in protos * Update internal/domain/metadata.go Co-authored-by: Silvan <silvan.reusser@gmail.com> * fix: rename vars * fix: rebiuld docs * Update internal/iam/repository/view/metadata_view.go Co-authored-by: Silvan <silvan.reusser@gmail.com> Co-authored-by: Silvan <silvan.reusser@gmail.com>
50 lines
1.7 KiB
Go
50 lines
1.7 KiB
Go
package repository
|
|
|
|
import (
|
|
"context"
|
|
"time"
|
|
|
|
"github.com/caos/zitadel/internal/domain"
|
|
key_model "github.com/caos/zitadel/internal/key/model"
|
|
|
|
"github.com/caos/zitadel/internal/user/model"
|
|
)
|
|
|
|
type UserRepository interface {
|
|
myUserRepo
|
|
|
|
UserSessionUserIDsByAgentID(ctx context.Context, agentID string) ([]string, error)
|
|
|
|
UserByID(ctx context.Context, userID string) (*model.UserView, error)
|
|
UserByLoginName(ctx context.Context, loginName string) (*model.UserView, error)
|
|
|
|
MachineKeyByID(ctx context.Context, keyID string) (*key_model.AuthNKeyView, error)
|
|
|
|
SearchUsers(ctx context.Context, request *model.UserSearchRequest) (*model.UserSearchResponse, error)
|
|
}
|
|
|
|
type myUserRepo interface {
|
|
MyUser(ctx context.Context) (*model.UserView, error)
|
|
|
|
MyProfile(ctx context.Context) (*model.Profile, error)
|
|
|
|
MyEmail(ctx context.Context) (*model.Email, error)
|
|
|
|
MyPhone(ctx context.Context) (*model.Phone, error)
|
|
|
|
MyAddress(ctx context.Context) (*model.Address, error)
|
|
|
|
SearchMyExternalIDPs(ctx context.Context, request *model.ExternalIDPSearchRequest) (*model.ExternalIDPSearchResponse, error)
|
|
|
|
MyUserMFAs(ctx context.Context) ([]*model.MultiFactor, error)
|
|
|
|
GetMyPasswordless(ctx context.Context) ([]*model.WebAuthNView, error)
|
|
|
|
MyUserChanges(ctx context.Context, lastSequence uint64, limit uint64, sortAscending bool, retention time.Duration) (*model.UserChanges, error)
|
|
|
|
SearchMyUserMemberships(ctx context.Context, request *model.UserMembershipSearchRequest) (*model.UserMembershipSearchResponse, error)
|
|
|
|
GetMyMetadataByKey(ctx context.Context, key string) (*domain.Metadata, error)
|
|
SearchMyMetadata(ctx context.Context, req *domain.MetadataSearchRequest) (*domain.MetadataSearchResponse, error)
|
|
}
|