Versions in this module Expand all Collapse all v0 v0.27.1 Apr 24, 2025 Changes in this version + const CollectionNameAuthOrigins + const CollectionNameExternalAuths + const CollectionNameMFAs + const CollectionNameOTPs + const CollectionNameSuperusers + const CollectionTypeAuth + const CollectionTypeBase + const CollectionTypeView + const DefaultAuxMaxIdleConns + const DefaultAuxMaxOpenConns + const DefaultDataMaxIdleConns + const DefaultDataMaxOpenConns + const DefaultEditorFieldMaxSize + const DefaultFileFieldMaxSize + const DefaultIdAlphabet + const DefaultIdLength + const DefaultInstallerEmail + const DefaultJSONFieldMaxSize + const DefaultMigrationsTable + const DefaultQueryTimeout + const EmailPlaceholderAppName + const EmailPlaceholderAppURL + const EmailPlaceholderOTP + const EmailPlaceholderOTPId + const EmailPlaceholderToken + const FieldNameCollectionId + const FieldNameCollectionName + const FieldNameEmail + const FieldNameEmailVisibility + const FieldNameExpand + const FieldNameId + const FieldNamePassword + const FieldNameTokenKey + const FieldNameVerified + const FieldTypeAutodate + const FieldTypeBool + const FieldTypeDate + const FieldTypeEditor + const FieldTypeEmail + const FieldTypeFile + const FieldTypeGeoPoint + const FieldTypeJSON + const FieldTypeNumber + const FieldTypePassword + const FieldTypeRelation + const FieldTypeSelect + const FieldTypeText + const FieldTypeURL + const InterceptorActionAfterCreate + const InterceptorActionAfterCreateError + const InterceptorActionAfterDelete + const InterceptorActionAfterDeleteError + const InterceptorActionAfterUpdate + const InterceptorActionAfterUpdateError + const InterceptorActionCreate + const InterceptorActionCreateExecute + const InterceptorActionDelete + const InterceptorActionDeleteExecute + const InterceptorActionUpdate + const InterceptorActionUpdateExecute + const InterceptorActionValidate + const LocalAutocertCacheDirName + const LocalBackupsDirName + const LocalStorageDirName + const LocalTempDirName + const LogsTableName + const MFAMethodOAuth2 + const MFAMethodOTP + const MFAMethodPassword + const ModelEventTypeCreate + const ModelEventTypeDelete + const ModelEventTypeUpdate + const ModelEventTypeValidate + const RateLimitRuleAudienceAll + const RateLimitRuleAudienceAuth + const RateLimitRuleAudienceGuest + const RequestEventKeyInfoContext + const RequestInfoContextBatch + const RequestInfoContextDefault + const RequestInfoContextExpand + const RequestInfoContextOAuth2 + const RequestInfoContextOTP + const RequestInfoContextPasswordAuth + const RequestInfoContextProtectedFile + const RequestInfoContextRealtime + const StoreKeyActiveBackup + const StoreKeyCachedCollections + const TokenClaimCollectionId + const TokenClaimEmail + const TokenClaimId + const TokenClaimNewEmail + const TokenClaimRefreshable + const TokenClaimType + const TokenTypeAuth + const TokenTypeEmailChange + const TokenTypeFile + const TokenTypePasswordReset + const TokenTypeVerification + var DefaultIdRegex = regexp.MustCompile(`^\w+$`) + var ErrInvalidFieldValue = validation.NewError("validation_invalid_field_value", "Invalid field value.") + var ErrMissingSigningKey = errors.New("missing or invalid signing key") + var ErrMustBeSystem = validation.NewError("validation_must_be_system", `The field must be marked as "System".`) + var ErrMustBeSystemAndHidden = validation.NewError("validation_must_be_system_and_hidden", ...) + var ErrNotAuthRecord = errors.New("not an auth collection record") + var ErrUnknownField = validation.NewError("validation_unknown_field", "Unknown or invalid field.") + var Fields = map[string]FieldFactoryFunc + var SystemDynamicFieldNames = []string + func DefaultDBConnect(dbPath string) (*dbx.DB, error) + func DefaultFieldIdValidationRule(value any) error + func DefaultFieldNameValidationRule(value any) error + func GenerateDefaultRandomId() string + type App interface + AuxDB func() dbx.Builder + AuxDelete func(model Model) error + AuxDeleteWithContext func(ctx context.Context, model Model) error + AuxHasTable func(tableName string) bool + AuxModelQuery func(model Model) *dbx.SelectQuery + AuxNonconcurrentDB func() dbx.Builder + AuxRunInTransaction func(fn func(txApp App) error) error + AuxSave func(model Model) error + AuxSaveNoValidate func(model Model) error + AuxSaveNoValidateWithContext func(ctx context.Context, model Model) error + AuxSaveWithContext func(ctx context.Context, model Model) error + AuxVacuum func() error + Bootstrap func() error + CanAccessRecord func(record *Record, requestInfo *RequestInfo, accessRule *string) (bool, error) + CollectionQuery func() *dbx.SelectQuery + CountRecords func(collectionModelOrIdentifier any, exprs ...dbx.Expression) (int64, error) + CreateBackup func(ctx context.Context, name string) error + CreateViewFields func(selectQuery string) (FieldsList, error) + Cron func() *cron.Cron + DB func() dbx.Builder + DataDir func() string + Delete func(model Model) error + DeleteAllAuthOriginsByRecord func(authRecord *Record) error + DeleteAllMFAsByRecord func(authRecord *Record) error + DeleteAllOTPsByRecord func(authRecord *Record) error + DeleteExpiredMFAs func() error + DeleteExpiredOTPs func() error + DeleteOldLogs func(createdBefore time.Time) error + DeleteTable func(tableName string) error + DeleteView func(name string) error + DeleteWithContext func(ctx context.Context, model Model) error + EncryptionEnv func() string + ExpandRecord func(record *Record, expands []string, optFetchFunc ExpandFetchFunc) map[string]error + ExpandRecords func(records []*Record, expands []string, optFetchFunc ExpandFetchFunc) map[string]error + FindAllAuthOriginsByCollection func(collection *Collection) ([]*AuthOrigin, error) + FindAllAuthOriginsByRecord func(authRecord *Record) ([]*AuthOrigin, error) + FindAllCollections func(collectionTypes ...string) ([]*Collection, error) + FindAllExternalAuthsByCollection func(collection *Collection) ([]*ExternalAuth, error) + FindAllExternalAuthsByRecord func(authRecord *Record) ([]*ExternalAuth, error) + FindAllMFAsByCollection func(collection *Collection) ([]*MFA, error) + FindAllMFAsByRecord func(authRecord *Record) ([]*MFA, error) + FindAllOTPsByCollection func(collection *Collection) ([]*OTP, error) + FindAllOTPsByRecord func(authRecord *Record) ([]*OTP, error) + FindAllRecords func(collectionModelOrIdentifier any, exprs ...dbx.Expression) ([]*Record, error) + FindAuthOriginById func(id string) (*AuthOrigin, error) + FindAuthOriginByRecordAndFingerprint func(authRecord *Record, fingerprint string) (*AuthOrigin, error) + FindAuthRecordByEmail func(collectionModelOrIdentifier any, email string) (*Record, error) + FindAuthRecordByToken func(token string, validTypes ...string) (*Record, error) + FindCachedCollectionByNameOrId func(nameOrId string) (*Collection, error) + FindCachedCollectionReferences func(collection *Collection, excludeIds ...string) (map[*Collection][]Field, error) + FindCollectionByNameOrId func(nameOrId string) (*Collection, error) + FindCollectionReferences func(collection *Collection, excludeIds ...string) (map[*Collection][]Field, error) + FindFirstExternalAuthByExpr func(expr dbx.Expression) (*ExternalAuth, error) + FindFirstRecordByData func(collectionModelOrIdentifier any, key string, value any) (*Record, error) + FindFirstRecordByFilter func(collectionModelOrIdentifier any, filter string, params ...dbx.Params) (*Record, error) + FindLogById func(id string) (*Log, error) + FindMFAById func(id string) (*MFA, error) + FindOTPById func(id string) (*OTP, error) + FindRecordById func(collectionModelOrIdentifier any, recordId string, ...) (*Record, error) + FindRecordByViewFile func(viewCollectionModelOrIdentifier any, fileFieldName string, filename string) (*Record, error) + FindRecordsByFilter func(collectionModelOrIdentifier any, filter string, sort string, limit int, ...) ([]*Record, error) + FindRecordsByIds func(collectionModelOrIdentifier any, recordIds []string, ...) ([]*Record, error) + HasTable func(tableName string) bool + ImportCollections func(toImport []map[string]any, deleteMissing bool) error + ImportCollectionsByMarshaledJSON func(rawSliceOfMaps []byte, deleteMissing bool) error + IsBootstrapped func() bool + IsCollectionNameUnique func(name string, excludeIds ...string) bool + IsDev func() bool + IsTransactional func() bool + LogQuery func() *dbx.SelectQuery + Logger func() *slog.Logger + LogsStats func(expr dbx.Expression) ([]*LogsStatsItem, error) + ModelQuery func(model Model) *dbx.SelectQuery + NewBackupsFilesystem func() (*filesystem.System, error) + NewFilesystem func() (*filesystem.System, error) + NewMailClient func() mailer.Mailer + NonconcurrentDB func() dbx.Builder + OnBackupCreate func() *hook.Hook[*BackupEvent] + OnBackupRestore func() *hook.Hook[*BackupEvent] + OnBatchRequest func() *hook.Hook[*BatchRequestEvent] + OnBootstrap func() *hook.Hook[*BootstrapEvent] + OnCollectionAfterCreateError func(tags ...string) *hook.TaggedHook[*CollectionErrorEvent] + OnCollectionAfterCreateSuccess func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionAfterDeleteError func(tags ...string) *hook.TaggedHook[*CollectionErrorEvent] + OnCollectionAfterDeleteSuccess func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionAfterUpdateError func(tags ...string) *hook.TaggedHook[*CollectionErrorEvent] + OnCollectionAfterUpdateSuccess func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionCreate func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionCreateExecute func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionCreateRequest func() *hook.Hook[*CollectionRequestEvent] + OnCollectionDelete func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionDeleteExecute func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionDeleteRequest func() *hook.Hook[*CollectionRequestEvent] + OnCollectionUpdate func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionUpdateExecute func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionUpdateRequest func() *hook.Hook[*CollectionRequestEvent] + OnCollectionValidate func(tags ...string) *hook.TaggedHook[*CollectionEvent] + OnCollectionViewRequest func() *hook.Hook[*CollectionRequestEvent] + OnCollectionsImportRequest func() *hook.Hook[*CollectionsImportRequestEvent] + OnCollectionsListRequest func() *hook.Hook[*CollectionsListRequestEvent] + OnFileDownloadRequest func(tags ...string) *hook.TaggedHook[*FileDownloadRequestEvent] + OnFileTokenRequest func(tags ...string) *hook.TaggedHook[*FileTokenRequestEvent] + OnMailerRecordAuthAlertSend func(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + OnMailerRecordEmailChangeSend func(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + OnMailerRecordOTPSend func(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + OnMailerRecordPasswordResetSend func(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + OnMailerRecordVerificationSend func(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + OnMailerSend func() *hook.Hook[*MailerEvent] + OnModelAfterCreateError func(tags ...string) *hook.TaggedHook[*ModelErrorEvent] + OnModelAfterCreateSuccess func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelAfterDeleteError func(tags ...string) *hook.TaggedHook[*ModelErrorEvent] + OnModelAfterDeleteSuccess func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelAfterUpdateError func(tags ...string) *hook.TaggedHook[*ModelErrorEvent] + OnModelAfterUpdateSuccess func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelCreate func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelCreateExecute func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelDelete func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelDeleteExecute func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelUpdate func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelUpdateExecute func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnModelValidate func(tags ...string) *hook.TaggedHook[*ModelEvent] + OnRealtimeConnectRequest func() *hook.Hook[*RealtimeConnectRequestEvent] + OnRealtimeMessageSend func() *hook.Hook[*RealtimeMessageEvent] + OnRealtimeSubscribeRequest func() *hook.Hook[*RealtimeSubscribeRequestEvent] + OnRecordAfterCreateError func(tags ...string) *hook.TaggedHook[*RecordErrorEvent] + OnRecordAfterCreateSuccess func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordAfterDeleteError func(tags ...string) *hook.TaggedHook[*RecordErrorEvent] + OnRecordAfterDeleteSuccess func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordAfterUpdateError func(tags ...string) *hook.TaggedHook[*RecordErrorEvent] + OnRecordAfterUpdateSuccess func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordAuthRefreshRequest func(tags ...string) *hook.TaggedHook[*RecordAuthRefreshRequestEvent] + OnRecordAuthRequest func(tags ...string) *hook.TaggedHook[*RecordAuthRequestEvent] + OnRecordAuthWithOAuth2Request func(tags ...string) *hook.TaggedHook[*RecordAuthWithOAuth2RequestEvent] + OnRecordAuthWithOTPRequest func(tags ...string) *hook.TaggedHook[*RecordAuthWithOTPRequestEvent] + OnRecordAuthWithPasswordRequest func(tags ...string) *hook.TaggedHook[*RecordAuthWithPasswordRequestEvent] + OnRecordConfirmEmailChangeRequest func(tags ...string) *hook.TaggedHook[*RecordConfirmEmailChangeRequestEvent] + OnRecordConfirmPasswordResetRequest func(tags ...string) *hook.TaggedHook[*RecordConfirmPasswordResetRequestEvent] + OnRecordConfirmVerificationRequest func(tags ...string) *hook.TaggedHook[*RecordConfirmVerificationRequestEvent] + OnRecordCreate func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordCreateExecute func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordCreateRequest func(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + OnRecordDelete func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordDeleteExecute func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordDeleteRequest func(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + OnRecordEnrich func(tags ...string) *hook.TaggedHook[*RecordEnrichEvent] + OnRecordRequestEmailChangeRequest func(tags ...string) *hook.TaggedHook[*RecordRequestEmailChangeRequestEvent] + OnRecordRequestOTPRequest func(tags ...string) *hook.TaggedHook[*RecordCreateOTPRequestEvent] + OnRecordRequestPasswordResetRequest func(tags ...string) *hook.TaggedHook[*RecordRequestPasswordResetRequestEvent] + OnRecordRequestVerificationRequest func(tags ...string) *hook.TaggedHook[*RecordRequestVerificationRequestEvent] + OnRecordUpdate func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordUpdateExecute func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordUpdateRequest func(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + OnRecordValidate func(tags ...string) *hook.TaggedHook[*RecordEvent] + OnRecordViewRequest func(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + OnRecordsListRequest func(tags ...string) *hook.TaggedHook[*RecordsListRequestEvent] + OnServe func() *hook.Hook[*ServeEvent] + OnSettingsListRequest func() *hook.Hook[*SettingsListRequestEvent] + OnSettingsReload func() *hook.Hook[*SettingsReloadEvent] + OnSettingsUpdateRequest func() *hook.Hook[*SettingsUpdateRequestEvent] + OnTerminate func() *hook.Hook[*TerminateEvent] + RecordQuery func(collectionModelOrIdentifier any) *dbx.SelectQuery + ReloadCachedCollections func() error + ReloadSettings func() error + ResetBootstrapState func() error + Restart func() error + RestoreBackup func(ctx context.Context, name string) error + RunAllMigrations func() error + RunAppMigrations func() error + RunInTransaction func(fn func(txApp App) error) error + RunSystemMigrations func() error + Save func(model Model) error + SaveNoValidate func(model Model) error + SaveNoValidateWithContext func(ctx context.Context, model Model) error + SaveView func(name string, selectQuery string) error + SaveWithContext func(ctx context.Context, model Model) error + Settings func() *Settings + Store func() *store.Store[string, any] + SubscriptionsBroker func() *subscriptions.Broker + SyncRecordTableSchema func(newCollection *Collection, oldCollection *Collection) error + TableColumns func(tableName string) ([]string, error) + TableIndexes func(tableName string) (map[string]string, error) + TableInfo func(tableName string) ([]*TableInfoRow, error) + TruncateCollection func(collection *Collection) error + UnsafeWithoutHooks func() App + Vacuum func() error + Validate func(model Model) error + ValidateWithContext func(ctx context.Context, model Model) error + type AuthAlertConfig struct + EmailTemplate EmailTemplate + Enabled bool + func (c AuthAlertConfig) Validate() error + type AuthOrigin struct + func NewAuthOrigin(app App) *AuthOrigin + func (m *AuthOrigin) CollectionRef() string + func (m *AuthOrigin) Created() types.DateTime + func (m *AuthOrigin) Fingerprint() string + func (m *AuthOrigin) PreValidate(ctx context.Context, app App) error + func (m *AuthOrigin) ProxyRecord() *Record + func (m *AuthOrigin) RecordRef() string + func (m *AuthOrigin) SetCollectionRef(collectionId string) + func (m *AuthOrigin) SetFingerprint(fingerprint string) + func (m *AuthOrigin) SetProxyRecord(record *Record) + func (m *AuthOrigin) SetRecordRef(recordId string) + func (m *AuthOrigin) Updated() types.DateTime + type AutodateField struct + Hidden bool + Id string + Name string + OnCreate bool + OnUpdate bool + Presentable bool + System bool + func (f *AutodateField) ColumnType(app App) string + func (f *AutodateField) FindSetter(key string) SetterFunc + func (f *AutodateField) GetHidden() bool + func (f *AutodateField) GetId() string + func (f *AutodateField) GetName() string + func (f *AutodateField) GetSystem() bool + func (f *AutodateField) Intercept(ctx context.Context, app App, record *Record, actionName string, ...) error + func (f *AutodateField) PrepareValue(record *Record, raw any) (any, error) + func (f *AutodateField) SetHidden(hidden bool) + func (f *AutodateField) SetId(id string) + func (f *AutodateField) SetName(name string) + func (f *AutodateField) SetSystem(system bool) + func (f *AutodateField) Type() string + func (f *AutodateField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *AutodateField) ValidateValue(ctx context.Context, app App, record *Record) error + type BackupEvent struct + App App + Context context.Context + Exclude []string + Name string + type BackupsConfig struct + Cron string + CronMaxKeep int + S3 S3Config + func (c BackupsConfig) Validate() error + type BaseApp struct + func NewBaseApp(config BaseAppConfig) *BaseApp + func (app *BaseApp) AuxDB() dbx.Builder + func (app *BaseApp) AuxDelete(model Model) error + func (app *BaseApp) AuxDeleteWithContext(ctx context.Context, model Model) error + func (app *BaseApp) AuxHasTable(tableName string) bool + func (app *BaseApp) AuxModelQuery(m Model) *dbx.SelectQuery + func (app *BaseApp) AuxNonconcurrentDB() dbx.Builder + func (app *BaseApp) AuxRunInTransaction(fn func(txApp App) error) error + func (app *BaseApp) AuxSave(model Model) error + func (app *BaseApp) AuxSaveNoValidate(model Model) error + func (app *BaseApp) AuxSaveNoValidateWithContext(ctx context.Context, model Model) error + func (app *BaseApp) AuxSaveWithContext(ctx context.Context, model Model) error + func (app *BaseApp) AuxVacuum() error + func (app *BaseApp) Bootstrap() error + func (app *BaseApp) CanAccessRecord(record *Record, requestInfo *RequestInfo, accessRule *string) (bool, error) + func (app *BaseApp) CollectionQuery() *dbx.SelectQuery + func (app *BaseApp) CountRecords(collectionModelOrIdentifier any, exprs ...dbx.Expression) (int64, error) + func (app *BaseApp) CreateBackup(ctx context.Context, name string) error + func (app *BaseApp) CreateViewFields(selectQuery string) (FieldsList, error) + func (app *BaseApp) Cron() *cron.Cron + func (app *BaseApp) DB() dbx.Builder + func (app *BaseApp) DataDir() string + func (app *BaseApp) Delete(model Model) error + func (app *BaseApp) DeleteAllAuthOriginsByRecord(authRecord *Record) error + func (app *BaseApp) DeleteAllMFAsByRecord(authRecord *Record) error + func (app *BaseApp) DeleteAllOTPsByRecord(authRecord *Record) error + func (app *BaseApp) DeleteExpiredMFAs() error + func (app *BaseApp) DeleteExpiredOTPs() error + func (app *BaseApp) DeleteOldLogs(createdBefore time.Time) error + func (app *BaseApp) DeleteTable(tableName string) error + func (app *BaseApp) DeleteView(name string) error + func (app *BaseApp) DeleteWithContext(ctx context.Context, model Model) error + func (app *BaseApp) EncryptionEnv() string + func (app *BaseApp) ExpandRecord(record *Record, expands []string, optFetchFunc ExpandFetchFunc) map[string]error + func (app *BaseApp) ExpandRecords(records []*Record, expands []string, optFetchFunc ExpandFetchFunc) map[string]error + func (app *BaseApp) FindAllAuthOriginsByCollection(collection *Collection) ([]*AuthOrigin, error) + func (app *BaseApp) FindAllAuthOriginsByRecord(authRecord *Record) ([]*AuthOrigin, error) + func (app *BaseApp) FindAllCollections(collectionTypes ...string) ([]*Collection, error) + func (app *BaseApp) FindAllExternalAuthsByCollection(collection *Collection) ([]*ExternalAuth, error) + func (app *BaseApp) FindAllExternalAuthsByRecord(authRecord *Record) ([]*ExternalAuth, error) + func (app *BaseApp) FindAllMFAsByCollection(collection *Collection) ([]*MFA, error) + func (app *BaseApp) FindAllMFAsByRecord(authRecord *Record) ([]*MFA, error) + func (app *BaseApp) FindAllOTPsByCollection(collection *Collection) ([]*OTP, error) + func (app *BaseApp) FindAllOTPsByRecord(authRecord *Record) ([]*OTP, error) + func (app *BaseApp) FindAllRecords(collectionModelOrIdentifier any, exprs ...dbx.Expression) ([]*Record, error) + func (app *BaseApp) FindAuthOriginById(id string) (*AuthOrigin, error) + func (app *BaseApp) FindAuthOriginByRecordAndFingerprint(authRecord *Record, fingerprint string) (*AuthOrigin, error) + func (app *BaseApp) FindAuthRecordByEmail(collectionModelOrIdentifier any, email string) (*Record, error) + func (app *BaseApp) FindAuthRecordByToken(token string, validTypes ...string) (*Record, error) + func (app *BaseApp) FindCachedCollectionByNameOrId(nameOrId string) (*Collection, error) + func (app *BaseApp) FindCachedCollectionReferences(collection *Collection, excludeIds ...string) (map[*Collection][]Field, error) + func (app *BaseApp) FindCollectionByNameOrId(nameOrId string) (*Collection, error) + func (app *BaseApp) FindCollectionReferences(collection *Collection, excludeIds ...string) (map[*Collection][]Field, error) + func (app *BaseApp) FindFirstExternalAuthByExpr(expr dbx.Expression) (*ExternalAuth, error) + func (app *BaseApp) FindFirstRecordByData(collectionModelOrIdentifier any, key string, value any) (*Record, error) + func (app *BaseApp) FindFirstRecordByFilter(collectionModelOrIdentifier any, filter string, params ...dbx.Params) (*Record, error) + func (app *BaseApp) FindLogById(id string) (*Log, error) + func (app *BaseApp) FindMFAById(id string) (*MFA, error) + func (app *BaseApp) FindOTPById(id string) (*OTP, error) + func (app *BaseApp) FindRecordById(collectionModelOrIdentifier any, recordId string, ...) (*Record, error) + func (app *BaseApp) FindRecordByViewFile(viewCollectionModelOrIdentifier any, fileFieldName string, filename string) (*Record, error) + func (app *BaseApp) FindRecordsByFilter(collectionModelOrIdentifier any, filter string, sort string, limit int, ...) ([]*Record, error) + func (app *BaseApp) FindRecordsByIds(collectionModelOrIdentifier any, recordIds []string, ...) ([]*Record, error) + func (app *BaseApp) HasTable(tableName string) bool + func (app *BaseApp) ImportCollections(toImport []map[string]any, deleteMissing bool) error + func (app *BaseApp) ImportCollectionsByMarshaledJSON(rawSliceOfMaps []byte, deleteMissing bool) error + func (app *BaseApp) IsBootstrapped() bool + func (app *BaseApp) IsCollectionNameUnique(name string, excludeIds ...string) bool + func (app *BaseApp) IsDev() bool + func (app *BaseApp) IsTransactional() bool + func (app *BaseApp) LogQuery() *dbx.SelectQuery + func (app *BaseApp) Logger() *slog.Logger + func (app *BaseApp) LogsStats(expr dbx.Expression) ([]*LogsStatsItem, error) + func (app *BaseApp) ModelQuery(m Model) *dbx.SelectQuery + func (app *BaseApp) NewBackupsFilesystem() (*filesystem.System, error) + func (app *BaseApp) NewFilesystem() (*filesystem.System, error) + func (app *BaseApp) NewMailClient() mailer.Mailer + func (app *BaseApp) NonconcurrentDB() dbx.Builder + func (app *BaseApp) OnBackupCreate() *hook.Hook[*BackupEvent] + func (app *BaseApp) OnBackupRestore() *hook.Hook[*BackupEvent] + func (app *BaseApp) OnBatchRequest() *hook.Hook[*BatchRequestEvent] + func (app *BaseApp) OnBootstrap() *hook.Hook[*BootstrapEvent] + func (app *BaseApp) OnCollectionAfterCreateError(tags ...string) *hook.TaggedHook[*CollectionErrorEvent] + func (app *BaseApp) OnCollectionAfterCreateSuccess(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionAfterDeleteError(tags ...string) *hook.TaggedHook[*CollectionErrorEvent] + func (app *BaseApp) OnCollectionAfterDeleteSuccess(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionAfterUpdateError(tags ...string) *hook.TaggedHook[*CollectionErrorEvent] + func (app *BaseApp) OnCollectionAfterUpdateSuccess(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionCreate(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionCreateExecute(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionCreateRequest() *hook.Hook[*CollectionRequestEvent] + func (app *BaseApp) OnCollectionDelete(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionDeleteExecute(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionDeleteRequest() *hook.Hook[*CollectionRequestEvent] + func (app *BaseApp) OnCollectionUpdate(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionUpdateExecute(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionUpdateRequest() *hook.Hook[*CollectionRequestEvent] + func (app *BaseApp) OnCollectionValidate(tags ...string) *hook.TaggedHook[*CollectionEvent] + func (app *BaseApp) OnCollectionViewRequest() *hook.Hook[*CollectionRequestEvent] + func (app *BaseApp) OnCollectionsImportRequest() *hook.Hook[*CollectionsImportRequestEvent] + func (app *BaseApp) OnCollectionsListRequest() *hook.Hook[*CollectionsListRequestEvent] + func (app *BaseApp) OnFileDownloadRequest(tags ...string) *hook.TaggedHook[*FileDownloadRequestEvent] + func (app *BaseApp) OnFileTokenRequest(tags ...string) *hook.TaggedHook[*FileTokenRequestEvent] + func (app *BaseApp) OnMailerRecordAuthAlertSend(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + func (app *BaseApp) OnMailerRecordEmailChangeSend(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + func (app *BaseApp) OnMailerRecordOTPSend(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + func (app *BaseApp) OnMailerRecordPasswordResetSend(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + func (app *BaseApp) OnMailerRecordVerificationSend(tags ...string) *hook.TaggedHook[*MailerRecordEvent] + func (app *BaseApp) OnMailerSend() *hook.Hook[*MailerEvent] + func (app *BaseApp) OnModelAfterCreateError(tags ...string) *hook.TaggedHook[*ModelErrorEvent] + func (app *BaseApp) OnModelAfterCreateSuccess(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelAfterDeleteError(tags ...string) *hook.TaggedHook[*ModelErrorEvent] + func (app *BaseApp) OnModelAfterDeleteSuccess(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelAfterUpdateError(tags ...string) *hook.TaggedHook[*ModelErrorEvent] + func (app *BaseApp) OnModelAfterUpdateSuccess(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelCreate(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelCreateExecute(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelDelete(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelDeleteExecute(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelUpdate(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelUpdateExecute(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnModelValidate(tags ...string) *hook.TaggedHook[*ModelEvent] + func (app *BaseApp) OnRealtimeConnectRequest() *hook.Hook[*RealtimeConnectRequestEvent] + func (app *BaseApp) OnRealtimeMessageSend() *hook.Hook[*RealtimeMessageEvent] + func (app *BaseApp) OnRealtimeSubscribeRequest() *hook.Hook[*RealtimeSubscribeRequestEvent] + func (app *BaseApp) OnRecordAfterCreateError(tags ...string) *hook.TaggedHook[*RecordErrorEvent] + func (app *BaseApp) OnRecordAfterCreateSuccess(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordAfterDeleteError(tags ...string) *hook.TaggedHook[*RecordErrorEvent] + func (app *BaseApp) OnRecordAfterDeleteSuccess(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordAfterUpdateError(tags ...string) *hook.TaggedHook[*RecordErrorEvent] + func (app *BaseApp) OnRecordAfterUpdateSuccess(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordAuthRefreshRequest(tags ...string) *hook.TaggedHook[*RecordAuthRefreshRequestEvent] + func (app *BaseApp) OnRecordAuthRequest(tags ...string) *hook.TaggedHook[*RecordAuthRequestEvent] + func (app *BaseApp) OnRecordAuthWithOAuth2Request(tags ...string) *hook.TaggedHook[*RecordAuthWithOAuth2RequestEvent] + func (app *BaseApp) OnRecordAuthWithOTPRequest(tags ...string) *hook.TaggedHook[*RecordAuthWithOTPRequestEvent] + func (app *BaseApp) OnRecordAuthWithPasswordRequest(tags ...string) *hook.TaggedHook[*RecordAuthWithPasswordRequestEvent] + func (app *BaseApp) OnRecordConfirmEmailChangeRequest(tags ...string) *hook.TaggedHook[*RecordConfirmEmailChangeRequestEvent] + func (app *BaseApp) OnRecordConfirmPasswordResetRequest(tags ...string) *hook.TaggedHook[*RecordConfirmPasswordResetRequestEvent] + func (app *BaseApp) OnRecordConfirmVerificationRequest(tags ...string) *hook.TaggedHook[*RecordConfirmVerificationRequestEvent] + func (app *BaseApp) OnRecordCreate(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordCreateExecute(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordCreateRequest(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + func (app *BaseApp) OnRecordDelete(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordDeleteExecute(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordDeleteRequest(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + func (app *BaseApp) OnRecordEnrich(tags ...string) *hook.TaggedHook[*RecordEnrichEvent] + func (app *BaseApp) OnRecordRequestEmailChangeRequest(tags ...string) *hook.TaggedHook[*RecordRequestEmailChangeRequestEvent] + func (app *BaseApp) OnRecordRequestOTPRequest(tags ...string) *hook.TaggedHook[*RecordCreateOTPRequestEvent] + func (app *BaseApp) OnRecordRequestPasswordResetRequest(tags ...string) *hook.TaggedHook[*RecordRequestPasswordResetRequestEvent] + func (app *BaseApp) OnRecordRequestVerificationRequest(tags ...string) *hook.TaggedHook[*RecordRequestVerificationRequestEvent] + func (app *BaseApp) OnRecordUpdate(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordUpdateExecute(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordUpdateRequest(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + func (app *BaseApp) OnRecordValidate(tags ...string) *hook.TaggedHook[*RecordEvent] + func (app *BaseApp) OnRecordViewRequest(tags ...string) *hook.TaggedHook[*RecordRequestEvent] + func (app *BaseApp) OnRecordsListRequest(tags ...string) *hook.TaggedHook[*RecordsListRequestEvent] + func (app *BaseApp) OnServe() *hook.Hook[*ServeEvent] + func (app *BaseApp) OnSettingsListRequest() *hook.Hook[*SettingsListRequestEvent] + func (app *BaseApp) OnSettingsReload() *hook.Hook[*SettingsReloadEvent] + func (app *BaseApp) OnSettingsUpdateRequest() *hook.Hook[*SettingsUpdateRequestEvent] + func (app *BaseApp) OnTerminate() *hook.Hook[*TerminateEvent] + func (app *BaseApp) RecordQuery(collectionModelOrIdentifier any) *dbx.SelectQuery + func (app *BaseApp) ReloadCachedCollections() error + func (app *BaseApp) ReloadSettings() error + func (app *BaseApp) ResetBootstrapState() error + func (app *BaseApp) Restart() error + func (app *BaseApp) RestoreBackup(ctx context.Context, name string) error + func (app *BaseApp) RunAllMigrations() error + func (app *BaseApp) RunAppMigrations() error + func (app *BaseApp) RunInTransaction(fn func(txApp App) error) error + func (app *BaseApp) RunSystemMigrations() error + func (app *BaseApp) Save(model Model) error + func (app *BaseApp) SaveNoValidate(model Model) error + func (app *BaseApp) SaveNoValidateWithContext(ctx context.Context, model Model) error + func (app *BaseApp) SaveView(name string, selectQuery string) error + func (app *BaseApp) SaveWithContext(ctx context.Context, model Model) error + func (app *BaseApp) Settings() *Settings + func (app *BaseApp) Store() *store.Store[string, any] + func (app *BaseApp) SubscriptionsBroker() *subscriptions.Broker + func (app *BaseApp) SyncRecordTableSchema(newCollection *Collection, oldCollection *Collection) error + func (app *BaseApp) TableColumns(tableName string) ([]string, error) + func (app *BaseApp) TableIndexes(tableName string) (map[string]string, error) + func (app *BaseApp) TableInfo(tableName string) ([]*TableInfoRow, error) + func (app *BaseApp) TruncateCollection(collection *Collection) error + func (app *BaseApp) UnsafeWithoutHooks() App + func (app *BaseApp) Vacuum() error + func (app *BaseApp) Validate(model Model) error + func (app *BaseApp) ValidateWithContext(ctx context.Context, model Model) error + type BaseAppConfig struct + AuxMaxIdleConns int + AuxMaxOpenConns int + DBConnect DBConnectFunc + DataDir string + DataMaxIdleConns int + DataMaxOpenConns int + EncryptionEnv string + IsDev bool + QueryTimeout time.Duration + type BaseModel struct + Id string + func (m *BaseModel) IsNew() bool + func (m *BaseModel) LastSavedPK() any + func (m *BaseModel) MarkAsNew() + func (m *BaseModel) MarkAsNotNew() + func (m *BaseModel) PK() any + func (m *BaseModel) PostScan() error + type BaseRecordProxy struct + func (m *BaseRecordProxy) ProxyRecord() *Record + func (m *BaseRecordProxy) SetProxyRecord(record *Record) + type BatchConfig struct + Enabled bool + MaxBodySize int64 + MaxRequests int + Timeout int64 + func (c BatchConfig) Validate() error + type BatchRequestEvent struct + Batch []*InternalRequest + type BoolField struct + Hidden bool + Id string + Name string + Presentable bool + Required bool + System bool + func (f *BoolField) ColumnType(app App) string + func (f *BoolField) GetHidden() bool + func (f *BoolField) GetId() string + func (f *BoolField) GetName() string + func (f *BoolField) GetSystem() bool + func (f *BoolField) PrepareValue(record *Record, raw any) (any, error) + func (f *BoolField) SetHidden(hidden bool) + func (f *BoolField) SetId(id string) + func (f *BoolField) SetName(name string) + func (f *BoolField) SetSystem(system bool) + func (f *BoolField) Type() string + func (f *BoolField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *BoolField) ValidateValue(ctx context.Context, app App, record *Record) error + type BootstrapEvent struct + App App + type Collection struct + func NewAuthCollection(name string, optId ...string) *Collection + func NewBaseCollection(name string, optId ...string) *Collection + func NewCollection(typ, name string, optId ...string) *Collection + func NewViewCollection(name string, optId ...string) *Collection + func (m *Collection) AddIndex(name string, unique bool, columnsExpr string, optWhereExpr string) + func (m *Collection) BaseFilesPath() string + func (m *Collection) DBExport(app App) (map[string]any, error) + func (m *Collection) GetIndex(name string) string + func (m *Collection) IntegrityChecks(enable bool) + func (m *Collection) IsAuth() bool + func (m *Collection) IsBase() bool + func (m *Collection) IsView() bool + func (m *Collection) PostScan() error + func (m *Collection) RemoveIndex(name string) + func (m *Collection) TableName() string + func (m *Collection) UnmarshalJSON(b []byte) error + func (m Collection) MarshalJSON() ([]byte, error) + func (m Collection) String() string + type CollectionErrorEvent struct + Error error + func (e *CollectionErrorEvent) Tags() []string + type CollectionEvent struct + App App + Context context.Context + Type string + func (e *CollectionEvent) Tags() []string + type CollectionRequestEvent struct + func (e *CollectionRequestEvent) Tags() []string + type CollectionsImportRequestEvent struct + CollectionsData []map[string]any + DeleteMissing bool + type CollectionsListRequestEvent struct + Collections []*Collection + Result *search.Result + type DBConnectFunc func(dbPath string) (*dbx.DB, error) + type DBExporter interface + DBExport func(app App) (map[string]any, error) + type DateField struct + Hidden bool + Id string + Max types.DateTime + Min types.DateTime + Name string + Presentable bool + Required bool + System bool + func (f *DateField) ColumnType(app App) string + func (f *DateField) GetHidden() bool + func (f *DateField) GetId() string + func (f *DateField) GetName() string + func (f *DateField) GetSystem() bool + func (f *DateField) PrepareValue(record *Record, raw any) (any, error) + func (f *DateField) SetHidden(hidden bool) + func (f *DateField) SetId(id string) + func (f *DateField) SetName(name string) + func (f *DateField) SetSystem(system bool) + func (f *DateField) Type() string + func (f *DateField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *DateField) ValidateValue(ctx context.Context, app App, record *Record) error + type DriverValuer interface + DriverValue func(record *Record) (driver.Value, error) + type EditorField struct + ConvertURLs bool + Hidden bool + Id string + MaxSize int64 + Name string + Presentable bool + Required bool + System bool + func (f *EditorField) CalculateMaxBodySize() int64 + func (f *EditorField) ColumnType(app App) string + func (f *EditorField) GetHidden() bool + func (f *EditorField) GetId() string + func (f *EditorField) GetName() string + func (f *EditorField) GetSystem() bool + func (f *EditorField) PrepareValue(record *Record, raw any) (any, error) + func (f *EditorField) SetHidden(hidden bool) + func (f *EditorField) SetId(id string) + func (f *EditorField) SetName(name string) + func (f *EditorField) SetSystem(system bool) + func (f *EditorField) Type() string + func (f *EditorField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *EditorField) ValidateValue(ctx context.Context, app App, record *Record) error + type EmailField struct + ExceptDomains []string + Hidden bool + Id string + Name string + OnlyDomains []string + Presentable bool + Required bool + System bool + func (f *EmailField) ColumnType(app App) string + func (f *EmailField) GetHidden() bool + func (f *EmailField) GetId() string + func (f *EmailField) GetName() string + func (f *EmailField) GetSystem() bool + func (f *EmailField) PrepareValue(record *Record, raw any) (any, error) + func (f *EmailField) SetHidden(hidden bool) + func (f *EmailField) SetId(id string) + func (f *EmailField) SetName(name string) + func (f *EmailField) SetSystem(system bool) + func (f *EmailField) Type() string + func (f *EmailField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *EmailField) ValidateValue(ctx context.Context, app App, record *Record) error + type EmailTemplate struct + Body string + Subject string + func (t EmailTemplate) Resolve(placeholders map[string]any) (subject, body string) + func (t EmailTemplate) Validate() error + type ExpandFetchFunc func(relCollection *Collection, relIds []string) ([]*Record, error) + type ExternalAuth struct + func NewExternalAuth(app App) *ExternalAuth + func (m *ExternalAuth) CollectionRef() string + func (m *ExternalAuth) Created() types.DateTime + func (m *ExternalAuth) PreValidate(ctx context.Context, app App) error + func (m *ExternalAuth) Provider() string + func (m *ExternalAuth) ProviderId() string + func (m *ExternalAuth) ProxyRecord() *Record + func (m *ExternalAuth) RecordRef() string + func (m *ExternalAuth) SetCollectionRef(collectionId string) + func (m *ExternalAuth) SetProvider(provider string) + func (m *ExternalAuth) SetProviderId(providerId string) + func (m *ExternalAuth) SetProxyRecord(record *Record) + func (m *ExternalAuth) SetRecordRef(recordId string) + func (m *ExternalAuth) Updated() types.DateTime + type Field interface + ColumnType func(app App) string + GetHidden func() bool + GetId func() string + GetName func() string + GetSystem func() bool + PrepareValue func(record *Record, raw any) (any, error) + SetHidden func(hidden bool) + SetId func(id string) + SetName func(name string) + SetSystem func(system bool) + Type func() string + ValidateSettings func(ctx context.Context, app App, collection *Collection) error + ValidateValue func(ctx context.Context, app App, record *Record) error + type FieldFactoryFunc func() Field + type FieldsList []Field + func NewFieldsList(fields ...Field) FieldsList + func (l *FieldsList) Add(fields ...Field) + func (l *FieldsList) AddAt(pos int, fields ...Field) + func (l *FieldsList) AddMarshaledJSON(rawJSON []byte) error + func (l *FieldsList) AddMarshaledJSONAt(pos int, rawJSON []byte) error + func (l *FieldsList) RemoveById(fieldId string) + func (l *FieldsList) RemoveByName(fieldName string) + func (l *FieldsList) Scan(value any) error + func (l *FieldsList) UnmarshalJSON(data []byte) error + func (l FieldsList) AsMap() map[string]Field + func (l FieldsList) Clone() (FieldsList, error) + func (l FieldsList) FieldNames() []string + func (l FieldsList) GetById(fieldId string) Field + func (l FieldsList) GetByName(fieldName string) Field + func (l FieldsList) MarshalJSON() ([]byte, error) + func (l FieldsList) String() string + func (l FieldsList) Value() (driver.Value, error) + type FileDownloadRequestEvent struct + FileField *FileField + Record *Record + ServedName string + ServedPath string + func (e *FileDownloadRequestEvent) Tags() []string + type FileField struct + Hidden bool + Id string + MaxSelect int + MaxSize int64 + MimeTypes []string + Name string + Presentable bool + Protected bool + Required bool + System bool + Thumbs []string + func (f *FileField) CalculateMaxBodySize() int64 + func (f *FileField) ColumnType(app App) string + func (f *FileField) DriverValue(record *Record) (driver.Value, error) + func (f *FileField) FindGetter(key string) GetterFunc + func (f *FileField) FindSetter(key string) SetterFunc + func (f *FileField) GetHidden() bool + func (f *FileField) GetId() string + func (f *FileField) GetName() string + func (f *FileField) GetSystem() bool + func (f *FileField) Intercept(ctx context.Context, app App, record *Record, actionName string, ...) error + func (f *FileField) IsMultiple() bool + func (f *FileField) PrepareValue(record *Record, raw any) (any, error) + func (f *FileField) SetHidden(hidden bool) + func (f *FileField) SetId(id string) + func (f *FileField) SetName(name string) + func (f *FileField) SetSystem(system bool) + func (f *FileField) Type() string + func (f *FileField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *FileField) ValidateValue(ctx context.Context, app App, record *Record) error + type FileTokenRequestEvent struct + Token string + func (e *FileTokenRequestEvent) Tags() []string + type FilesManager interface + BaseFilesPath func() string + type GeoPointField struct + Hidden bool + Id string + Name string + Presentable bool + Required bool + System bool + func (f *GeoPointField) ColumnType(app App) string + func (f *GeoPointField) GetHidden() bool + func (f *GeoPointField) GetId() string + func (f *GeoPointField) GetName() string + func (f *GeoPointField) GetSystem() bool + func (f *GeoPointField) PrepareValue(record *Record, raw any) (any, error) + func (f *GeoPointField) SetHidden(hidden bool) + func (f *GeoPointField) SetId(id string) + func (f *GeoPointField) SetName(name string) + func (f *GeoPointField) SetSystem(system bool) + func (f *GeoPointField) Type() string + func (f *GeoPointField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *GeoPointField) ValidateValue(ctx context.Context, app App, record *Record) error + type GetterFinder interface + FindGetter func(key string) GetterFunc + type GetterFunc func(record *Record) any + type HookTagger interface + HookTags func() []string + type InternalRequest struct + Body map[string]any + Headers map[string]string + Method string + URL string + func (br InternalRequest) Validate() error + type JSONField struct + Hidden bool + Id string + MaxSize int64 + Name string + Presentable bool + Required bool + System bool + func (f *JSONField) CalculateMaxBodySize() int64 + func (f *JSONField) ColumnType(app App) string + func (f *JSONField) GetHidden() bool + func (f *JSONField) GetId() string + func (f *JSONField) GetName() string + func (f *JSONField) GetSystem() bool + func (f *JSONField) PrepareValue(record *Record, raw any) (any, error) + func (f *JSONField) SetHidden(hidden bool) + func (f *JSONField) SetId(id string) + func (f *JSONField) SetName(name string) + func (f *JSONField) SetSystem(system bool) + func (f *JSONField) Type() string + func (f *JSONField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *JSONField) ValidateValue(ctx context.Context, app App, record *Record) error + type Log struct + Created types.DateTime + Data types.JSONMap[any] + Level int + Message string + func (m *Log) TableName() string + type LogsConfig struct + LogAuthId bool + LogIP bool + MaxDays int + MinLevel int + func (c LogsConfig) Validate() error + type LogsStatsItem struct + Date types.DateTime + Total int + type MFA struct + func NewMFA(app App) *MFA + func (m *MFA) CollectionRef() string + func (m *MFA) Created() types.DateTime + func (m *MFA) HasExpired(maxElapsed time.Duration) bool + func (m *MFA) Method() string + func (m *MFA) PreValidate(ctx context.Context, app App) error + func (m *MFA) ProxyRecord() *Record + func (m *MFA) RecordRef() string + func (m *MFA) SetCollectionRef(collectionId string) + func (m *MFA) SetMethod(method string) + func (m *MFA) SetProxyRecord(record *Record) + func (m *MFA) SetRecordRef(recordId string) + func (m *MFA) Updated() types.DateTime + type MFAConfig struct + Duration int64 + Enabled bool + Rule string + func (c MFAConfig) DurationTime() time.Duration + func (c MFAConfig) Validate() error + type MailerEvent struct + App App + Mailer mailer.Mailer + Message *mailer.Message + type MailerRecordEvent struct + Meta map[string]any + func (e *MailerRecordEvent) Tags() []string + type MaxBodySizeCalculator interface + CalculateMaxBodySize func() int64 + type MetaConfig struct + AppName string + AppURL string + HideControls bool + SenderAddress string + SenderName string + func (c MetaConfig) Validate() error + type Migration struct + Down func(txApp App) error + File string + ReapplyCondition func(txApp App, runner *MigrationsRunner, fileName string) (bool, error) + Up func(txApp App) error + type MigrationsList struct + var AppMigrations MigrationsList + var SystemMigrations MigrationsList + func (l *MigrationsList) Add(m *Migration) + func (l *MigrationsList) Copy(list MigrationsList) + func (l *MigrationsList) Item(index int) *Migration + func (l *MigrationsList) Items() []*Migration + func (l *MigrationsList) Register(up func(txApp App) error, down func(txApp App) error, optFilename ...string) + type MigrationsRunner struct + func NewMigrationsRunner(app App, migrationsList MigrationsList) *MigrationsRunner + func (r *MigrationsRunner) Down(toRevertCount int) ([]string, error) + func (r *MigrationsRunner) RemoveMissingAppliedMigrations() error + func (r *MigrationsRunner) Run(args ...string) error + func (r *MigrationsRunner) Up() ([]string, error) + type Model interface + IsNew func() bool + LastSavedPK func() any + MarkAsNew func() + MarkAsNotNew func() + PK func() any + TableName func() string + type ModelErrorEvent struct + Error error + func (e *ModelErrorEvent) Tags() []string + type ModelEvent struct + App App + Context context.Context + Type string + func (e *ModelEvent) Tags() []string + type MultiValuer interface + IsMultiple func() bool + type NumberField struct + Hidden bool + Id string + Max *float64 + Min *float64 + Name string + OnlyInt bool + Presentable bool + Required bool + System bool + func (f *NumberField) ColumnType(app App) string + func (f *NumberField) FindSetter(key string) SetterFunc + func (f *NumberField) GetHidden() bool + func (f *NumberField) GetId() string + func (f *NumberField) GetName() string + func (f *NumberField) GetSystem() bool + func (f *NumberField) PrepareValue(record *Record, raw any) (any, error) + func (f *NumberField) SetHidden(hidden bool) + func (f *NumberField) SetId(id string) + func (f *NumberField) SetName(name string) + func (f *NumberField) SetSystem(system bool) + func (f *NumberField) Type() string + func (f *NumberField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *NumberField) ValidateValue(ctx context.Context, app App, record *Record) error + type OAuth2Config struct + Enabled bool + MappedFields OAuth2KnownFields + Providers []OAuth2ProviderConfig + func (c OAuth2Config) GetProviderConfig(name string) (config OAuth2ProviderConfig, exists bool) + func (c OAuth2Config) Validate() error + type OAuth2KnownFields struct + AvatarURL string + Id string + Name string + Username string + type OAuth2ProviderConfig struct + AuthURL string + ClientId string + ClientSecret string + DisplayName string + Extra map[string]any + Name string + PKCE *bool + TokenURL string + UserInfoURL string + func (c OAuth2ProviderConfig) InitProvider() (auth.Provider, error) + func (c OAuth2ProviderConfig) Validate() error + type OTP struct + func NewOTP(app App) *OTP + func (m *OTP) CollectionRef() string + func (m *OTP) Created() types.DateTime + func (m *OTP) HasExpired(maxElapsed time.Duration) bool + func (m *OTP) PreValidate(ctx context.Context, app App) error + func (m *OTP) ProxyRecord() *Record + func (m *OTP) RecordRef() string + func (m *OTP) SentTo() string + func (m *OTP) SetCollectionRef(collectionId string) + func (m *OTP) SetProxyRecord(record *Record) + func (m *OTP) SetRecordRef(recordId string) + func (m *OTP) SetSentTo(val string) + func (m *OTP) Updated() types.DateTime + type OTPConfig struct + Duration int64 + EmailTemplate EmailTemplate + Enabled bool + Length int + func (c OTPConfig) DurationTime() time.Duration + func (c OTPConfig) Validate() error + type Param struct + Created types.DateTime + Updated types.DateTime + Value types.JSONRaw + func (m *Param) TableName() string + type PasswordAuthConfig struct + Enabled bool + IdentityFields []string + func (c PasswordAuthConfig) Validate() error + type PasswordField struct + Cost int + Hidden bool + Id string + Max int + Min int + Name string + Pattern string + Presentable bool + Required bool + System bool + func (f *PasswordField) ColumnType(app App) string + func (f *PasswordField) DriverValue(record *Record) (driver.Value, error) + func (f *PasswordField) FindGetter(key string) GetterFunc + func (f *PasswordField) FindSetter(key string) SetterFunc + func (f *PasswordField) GetHidden() bool + func (f *PasswordField) GetId() string + func (f *PasswordField) GetName() string + func (f *PasswordField) GetSystem() bool + func (f *PasswordField) Intercept(ctx context.Context, app App, record *Record, actionName string, ...) error + func (f *PasswordField) PrepareValue(record *Record, raw any) (any, error) + func (f *PasswordField) SetHidden(hidden bool) + func (f *PasswordField) SetId(id string) + func (f *PasswordField) SetName(name string) + func (f *PasswordField) SetSystem(system bool) + func (f *PasswordField) Type() string + func (f *PasswordField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *PasswordField) ValidateValue(ctx context.Context, app App, record *Record) error + type PasswordFieldValue struct + Hash string + LastError error + Plain string + func (pv PasswordFieldValue) Validate(pass string) bool + type PostValidator interface + PostValidate func(ctx context.Context, app App) error + type PreValidator interface + PreValidate func(ctx context.Context, app App) error + type RateLimitRule struct + Audience string + Duration int64 + Label string + MaxRequests int + func (c RateLimitRule) DurationTime() time.Duration + func (c RateLimitRule) Validate() error + type RateLimitsConfig struct + Enabled bool + Rules []RateLimitRule + func (c *RateLimitsConfig) FindRateLimitRule(searchLabels []string, optOnlyAudience ...string) (RateLimitRule, bool) + func (c RateLimitsConfig) MarshalJSON() ([]byte, error) + func (c RateLimitsConfig) Validate() error + type RealtimeConnectRequestEvent struct + Client subscriptions.Client + IdleTimeout time.Duration + type RealtimeMessageEvent struct + Client subscriptions.Client + Message *subscriptions.Message + type RealtimeSubscribeRequestEvent struct + Client subscriptions.Client + Subscriptions []string + type Record struct + func NewRecord(collection *Collection) *Record + func (m *Record) BaseFilesPath() string + func (m *Record) Clone() *Record + func (m *Record) Collection() *Collection + func (m *Record) CustomData() map[string]any + func (m *Record) DBExport(app App) (map[string]any, error) + func (m *Record) Email() string + func (m *Record) EmailVisibility() bool + func (m *Record) Expand() map[string]any + func (m *Record) ExpandedAll(relField string) []*Record + func (m *Record) ExpandedOne(relField string) *Record + func (m *Record) FieldsData() map[string]any + func (m *Record) FindFileFieldByFile(filename string) *FileField + func (m *Record) Fresh() *Record + func (m *Record) Get(key string) any + func (m *Record) GetBool(key string) bool + func (m *Record) GetDateTime(key string) types.DateTime + func (m *Record) GetFloat(key string) float64 + func (m *Record) GetGeoPoint(key string) types.GeoPoint + func (m *Record) GetInt(key string) int + func (m *Record) GetRaw(key string) any + func (m *Record) GetString(key string) string + func (m *Record) GetStringSlice(key string) []string + func (m *Record) GetUnsavedFiles(key string) []*filesystem.File + func (m *Record) GetUploadedFiles(key string) []*filesystem.File + func (m *Record) HookTags() []string + func (m *Record) IgnoreEmailVisibility(state bool) *Record + func (m *Record) IgnoreUnchangedFields(state bool) *Record + func (m *Record) IsSuperuser() bool + func (m *Record) Load(data map[string]any) + func (m *Record) MergeExpand(expand map[string]any) + func (m *Record) NewAuthToken() (string, error) + func (m *Record) NewEmailChangeToken(newEmail string) (string, error) + func (m *Record) NewFileToken() (string, error) + func (m *Record) NewPasswordResetToken() (string, error) + func (m *Record) NewStaticAuthToken(duration time.Duration) (string, error) + func (m *Record) NewVerificationToken() (string, error) + func (m *Record) Original() *Record + func (m *Record) PostScan() error + func (m *Record) RefreshTokenKey() + func (m *Record) ReplaceModifiers(data map[string]any) map[string]any + func (m *Record) Set(key string, value any) + func (m *Record) SetEmail(email string) + func (m *Record) SetEmailVisibility(visible bool) + func (m *Record) SetExpand(expand map[string]any) + func (m *Record) SetIfFieldExists(key string, value any) Field + func (m *Record) SetPassword(password string) + func (m *Record) SetRandomPassword() string + func (m *Record) SetRaw(key string, value any) + func (m *Record) SetTokenKey(key string) + func (m *Record) SetVerified(verified bool) + func (m *Record) TableName() string + func (m *Record) TokenKey() string + func (m *Record) UnmarshalJSON(data []byte) error + func (m *Record) UnmarshalJSONField(key string, result any) error + func (m *Record) ValidatePassword(password string) bool + func (m *Record) Verified() bool + func (m *Record) WithCustomData(state bool) *Record + func (m Record) MarshalJSON() ([]byte, error) + func (record *Record) Hide(fieldNames ...string) *Record + func (record *Record) PublicExport() map[string]any + func (record *Record) Unhide(fieldNames ...string) *Record + type RecordAuthRefreshRequestEvent struct + Record *Record + func (e *RecordAuthRefreshRequestEvent) Tags() []string + type RecordAuthRequestEvent struct + AuthMethod string + Meta any + Record *Record + Token string + func (e *RecordAuthRequestEvent) Tags() []string + type RecordAuthWithOAuth2RequestEvent struct + CreateData map[string]any + IsNewRecord bool + OAuth2User *auth.AuthUser + ProviderClient auth.Provider + ProviderName string + Record *Record + func (e *RecordAuthWithOAuth2RequestEvent) Tags() []string + type RecordAuthWithOTPRequestEvent struct + OTP *OTP + Record *Record + func (e *RecordAuthWithOTPRequestEvent) Tags() []string + type RecordAuthWithPasswordRequestEvent struct + Identity string + IdentityField string + Password string + Record *Record + func (e *RecordAuthWithPasswordRequestEvent) Tags() []string + type RecordConfirmEmailChangeRequestEvent struct + NewEmail string + Record *Record + func (e *RecordConfirmEmailChangeRequestEvent) Tags() []string + type RecordConfirmPasswordResetRequestEvent struct + Record *Record + func (e *RecordConfirmPasswordResetRequestEvent) Tags() []string + type RecordConfirmVerificationRequestEvent struct + Record *Record + func (e *RecordConfirmVerificationRequestEvent) Tags() []string + type RecordCreateOTPRequestEvent struct + Password string + Record *Record + func (e *RecordCreateOTPRequestEvent) Tags() []string + type RecordEnrichEvent struct + App App + RequestInfo *RequestInfo + func (e *RecordEnrichEvent) Tags() []string + type RecordErrorEvent struct + Error error + func (e *RecordErrorEvent) Tags() []string + type RecordEvent struct + App App + Context context.Context + Type string + func (e *RecordEvent) Tags() []string + type RecordFieldResolver struct + func NewRecordFieldResolver(app App, baseCollection *Collection, requestInfo *RequestInfo, ...) *RecordFieldResolver + func (r *RecordFieldResolver) AllowHiddenFields() bool + func (r *RecordFieldResolver) AllowedFields() []string + func (r *RecordFieldResolver) Resolve(fieldName string) (*search.ResolverResult, error) + func (r *RecordFieldResolver) SetAllowHiddenFields(allowHiddenFields bool) + func (r *RecordFieldResolver) SetAllowedFields(newAllowedFields []string) + func (r *RecordFieldResolver) UpdateQuery(query *dbx.SelectQuery) error + type RecordInterceptor interface + Intercept func(ctx context.Context, app App, record *Record, actionName string, ...) error + type RecordProxy interface + ProxyRecord func() *Record + SetProxyRecord func(record *Record) + type RecordRequestEmailChangeRequestEvent struct + NewEmail string + Record *Record + func (e *RecordRequestEmailChangeRequestEvent) Tags() []string + type RecordRequestEvent struct + Record *Record + func (e *RecordRequestEvent) Tags() []string + type RecordRequestPasswordResetRequestEvent struct + Record *Record + func (e *RecordRequestPasswordResetRequestEvent) Tags() []string + type RecordRequestVerificationRequestEvent struct + Record *Record + func (e *RecordRequestVerificationRequestEvent) Tags() []string + type RecordsListRequestEvent struct + Records []*Record + Result *search.Result + SelectQuery *dbx.SelectQuery + func (e *RecordsListRequestEvent) Tags() []string + type RelationField struct + CascadeDelete bool + CollectionId string + Hidden bool + Id string + MaxSelect int + MinSelect int + Name string + Presentable bool + Required bool + System bool + func (f *RelationField) ColumnType(app App) string + func (f *RelationField) DriverValue(record *Record) (driver.Value, error) + func (f *RelationField) FindSetter(key string) SetterFunc + func (f *RelationField) GetHidden() bool + func (f *RelationField) GetId() string + func (f *RelationField) GetName() string + func (f *RelationField) GetSystem() bool + func (f *RelationField) IsMultiple() bool + func (f *RelationField) PrepareValue(record *Record, raw any) (any, error) + func (f *RelationField) SetHidden(hidden bool) + func (f *RelationField) SetId(id string) + func (f *RelationField) SetName(name string) + func (f *RelationField) SetSystem(system bool) + func (f *RelationField) Type() string + func (f *RelationField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *RelationField) ValidateValue(ctx context.Context, app App, record *Record) error + type RequestEvent struct + App App + Auth *Record + func (e *RequestEvent) HasSuperuserAuth() bool + func (e *RequestEvent) RealIP() string + func (e *RequestEvent) RequestInfo() (*RequestInfo, error) + type RequestInfo struct + Auth *Record + Body map[string]any + Context string + Headers map[string]string + Method string + Query map[string]string + func (info *RequestInfo) Clone() *RequestInfo + func (info *RequestInfo) HasSuperuserAuth() bool + type S3Config struct + AccessKey string + Bucket string + Enabled bool + Endpoint string + ForcePathStyle bool + Region string + Secret string + func (c S3Config) Validate() error + type SMTPConfig struct + AuthMethod string + Enabled bool + Host string + LocalName string + Password string + Port int + TLS bool + Username string + func (c SMTPConfig) Validate() error + type SelectField struct + Hidden bool + Id string + MaxSelect int + Name string + Presentable bool + Required bool + System bool + Values []string + func (f *SelectField) ColumnType(app App) string + func (f *SelectField) DriverValue(record *Record) (driver.Value, error) + func (f *SelectField) FindSetter(key string) SetterFunc + func (f *SelectField) GetHidden() bool + func (f *SelectField) GetId() string + func (f *SelectField) GetName() string + func (f *SelectField) GetSystem() bool + func (f *SelectField) IsMultiple() bool + func (f *SelectField) PrepareValue(record *Record, raw any) (any, error) + func (f *SelectField) SetHidden(hidden bool) + func (f *SelectField) SetId(id string) + func (f *SelectField) SetName(name string) + func (f *SelectField) SetSystem(system bool) + func (f *SelectField) Type() string + func (f *SelectField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *SelectField) ValidateValue(ctx context.Context, app App, record *Record) error + type ServeEvent struct + App App + CertManager *autocert.Manager + InstallerFunc func(app App, systemSuperuser *Record, baseURL string) error + Router *router.Router[*RequestEvent] + Server *http.Server + type SetterFinder interface + FindSetter func(key string) SetterFunc + type SetterFunc func(record *Record, raw any) + type Settings struct + func (s *Settings) Clone() (*Settings, error) + func (s *Settings) DBExport(app App) (map[string]any, error) + func (s *Settings) IsNew() bool + func (s *Settings) LastSavedPK() any + func (s *Settings) MarkAsNew() + func (s *Settings) MarkAsNotNew() + func (s *Settings) MarshalJSON() ([]byte, error) + func (s *Settings) Merge(other *Settings) error + func (s *Settings) PK() any + func (s *Settings) PostScan() error + func (s *Settings) PostValidate(ctx context.Context, app App) error + func (s *Settings) String() string + func (s *Settings) TableName() string + type SettingsListRequestEvent struct + Settings *Settings + type SettingsReloadEvent struct + App App + type SettingsUpdateRequestEvent struct + NewSettings *Settings + OldSettings *Settings + type TableInfoRow struct + DefaultValue sql.NullString + Index int + Name string + NotNull bool + PK int + Type string + type TerminateEvent struct + App App + IsRestart bool + type TextField struct + AutogeneratePattern string + Hidden bool + Id string + Max int + Min int + Name string + Pattern string + Presentable bool + PrimaryKey bool + Required bool + System bool + func (f *TextField) ColumnType(app App) string + func (f *TextField) FindSetter(key string) SetterFunc + func (f *TextField) GetHidden() bool + func (f *TextField) GetId() string + func (f *TextField) GetName() string + func (f *TextField) GetSystem() bool + func (f *TextField) Intercept(ctx context.Context, app App, record *Record, actionName string, ...) error + func (f *TextField) PrepareValue(record *Record, raw any) (any, error) + func (f *TextField) SetHidden(hidden bool) + func (f *TextField) SetId(id string) + func (f *TextField) SetName(name string) + func (f *TextField) SetSystem(system bool) + func (f *TextField) Type() string + func (f *TextField) ValidatePlainValue(value string) error + func (f *TextField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *TextField) ValidateValue(ctx context.Context, app App, record *Record) error + type TokenConfig struct + Duration int64 + Secret string + func (c TokenConfig) DurationTime() time.Duration + func (c TokenConfig) Validate() error + type TrustedProxyConfig struct + Headers []string + UseLeftmostIP bool + func (c TrustedProxyConfig) MarshalJSON() ([]byte, error) + func (c TrustedProxyConfig) Validate() error + type URLField struct + ExceptDomains []string + Hidden bool + Id string + Name string + OnlyDomains []string + Presentable bool + Required bool + System bool + func (f *URLField) ColumnType(app App) string + func (f *URLField) GetHidden() bool + func (f *URLField) GetId() string + func (f *URLField) GetName() string + func (f *URLField) GetSystem() bool + func (f *URLField) PrepareValue(record *Record, raw any) (any, error) + func (f *URLField) SetHidden(hidden bool) + func (f *URLField) SetId(id string) + func (f *URLField) SetName(name string) + func (f *URLField) SetSystem(system bool) + func (f *URLField) Type() string + func (f *URLField) ValidateSettings(ctx context.Context, app App, collection *Collection) error + func (f *URLField) ValidateValue(ctx context.Context, app App, record *Record) error