backend.schemas
Pydantic schemas for request validation and response serialisation.
Every schema is a pydantic.BaseModel subclass. Schemas are
grouped by domain:
Auth –
LoginRequest,RefreshRequest,LogoutRequestUser –
UserOut,UserCreate,UserUpdate,UserListElem,UserTodo,UserTodoListSong –
SongIn,SongOut,SongCandidateOut,SongFeedbackBase,SongFeedbackIn,SongStatisticsRehearsal –
RehListElem,NewRehDict,RehTodoOutGig –
GigIn,GigOut,GigSetlistOut,GigStatistics,SeasonStatisticsSurvey –
SurveyIn,SurveyList,SurveyQuestionOut,SurveyFeedbackOutPassword –
PasswordUpdateRequest,PasswordResetRequest
- class backend.schemas.LoginRequest(*, username, password)[Quellcode]
Bases:
BaseModel- classmethod strip_username(v)[Quellcode]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.TokenResponse(*, access_token, token_type='bearer')[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.RefreshRequest(*, refresh_token)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.LogoutRequest(*, refresh_token=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.UserGroup(*values)[Quellcode]
-
- admin = 'admin'
- editor = 'editor'
- user = 'user'
- class backend.schemas.UserStatus(*values)[Quellcode]
-
- active = 'active'
- deactivated = 'deactivated'
- class backend.schemas.UserCreate(*, user_name, clear_name=None, email, user_pw, user_group, musician=False, is_singer=False, status=UserStatus.active)[Quellcode]
Bases:
BaseModel- status: UserStatus
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.UserOut(*, id, user_name, user_group, email, clear_name, musician, is_singer, mm_username='', status=UserStatus.active)[Quellcode]
Bases:
BaseModel- status: UserStatus
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.UserTodo(*, id, todo, user_name, song_title, song_interpret, done, dt)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongForFeedback(*, id, title, interpret, status)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyForFeedback(*, id, kind_of_survey, rf_survey, release_date=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.UserTodoList(*, todo=<factory>, songs_to_feedback=<factory>, surveys_to_feedback=<factory>)[Quellcode]
Bases:
BaseModel- songs_to_feedback: List[SongForFeedback]
- surveys_to_feedback: List[SurveyForFeedback]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.PasswordUpdateRequest(*, user_id, old_password, new_password)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.PasswordResetRequest(*, new_password)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SoftConfigOption(*, key=None, label)[Quellcode]
Bases:
BaseModel- model_config = {'extra': 'forbid'}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SoftConfigUpdateIn(*, genres, gigTypes, songStatuses, gigStatuses, tonekeys, rehearsalSongStatuses, setlist_timing)[Quellcode]
Bases:
BaseModel- genres: List[str | SoftConfigOption]
- gigTypes: List[str | SoftConfigOption]
- songStatuses: List[str | SoftConfigOption]
- gigStatuses: List[str | SoftConfigOption]
- tonekeys: List[str | SoftConfigOption]
- rehearsalSongStatuses: List[str | SoftConfigOption]
- model_config = {'extra': 'forbid'}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SoftConfigOut(*, genres, gigTypes, songStatuses, gigStatuses, tonekeys, rehearsalSongStatuses, setlist_timing)[Quellcode]
Bases:
BaseModel- genres: List[SoftConfigOption]
- gigTypes: List[SoftConfigOption]
- songStatuses: List[SoftConfigOption]
- gigStatuses: List[SoftConfigOption]
- tonekeys: List[SoftConfigOption]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SoftConfigMeta(*, editableKeys, updatedAt)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SoftConfigAdminResponse(*, data, meta)[Quellcode]
Bases:
BaseModel- data: SoftConfigOut
- meta: SoftConfigMeta
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SoftConfigUpdateResponse(*, message, updatedKeys, data)[Quellcode]
Bases:
BaseModel- data: SoftConfigOut
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongIn(*, title, interpret, genre, singer_background=None, singer_lead=None, composer=None, texter=None, publisher=None, arrangement=None, tone_key=None, status, comment=None, ytlink=None, brass=None, text=None, id=None, duration=None)[Quellcode]
Bases:
BaseModel- classmethod parse_duration(v)[Quellcode]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongFeedbackIn(*, song_id, user_id, feedback)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongFeedbackBase(*, song_id, user_id, feedback)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongFeedbackSummary(*, song_id, total_votes=0, yes_votes=0, no_votes=0, abstain_votes=0, unknown_votes=0)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongCandidateOut(*, id, title, interpret, genre=None, singer_lead=None, singer_background=None, composer=None, tone_key=None, status=None, ytlink=None, brass=None, duration=None, feedbacks=<factory>)[Quellcode]
Bases:
BaseModel- feedbacks: list[SongFeedbackBase]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongOut(*, title=None, interpret=None, genre=None, singer_background=None, singer_lead=None, composer=None, texter=None, publisher=None, arrangement=None, tone_key=None, status=None, comment=None, ytlink=None, duration=None, brass=None, id=None)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongScrawlOut(*, recording_id=None, work_id=None, duration=None, ytlink=None, composers=<factory>, lyricists=<factory>, composer=None, texter=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigIn(*, name, datum, venue=None, kind_of_gig, doors=None, begin=None, end=None, organizer=None, status=None, id=None, publish=None)[Quellcode]
Bases:
BaseModel- classmethod parse_date(v)[Quellcode]
- classmethod parse_time_field(v)[Quellcode]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.NewGig(*, name, datum, venue=None, kind_of_gig, begin, doors=None, end=None, organizer=None, status=None, publish=0)[Quellcode]
Bases:
BaseModel- classmethod set_default_times(values)[Quellcode]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigOut(*, name=None, datum=None, venue=None, organizer=None, kind_of_gig=None, doors=None, begin=None, end=None, status=None, id=None, publish=None)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigScheduleItemIn(*, item_datetime, was, wer, wo)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigScheduleItemOut(*, id=None, gig_id, item_datetime, was, wer, wo, is_fixed=False)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigScheduleOut(*, items=<factory>)[Quellcode]
Bases:
BaseModel- items: List[GigScheduleItemOut]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigScheduleBulkItemIn(*, id=None, item_datetime, was, wer, wo)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigScheduleBulkUpdateIn(*, items=<factory>)[Quellcode]
Bases:
BaseModel- items: List[GigScheduleBulkItemIn]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SetOut(*, id, position, pause, setlist_name, songs)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongInSetOut(*, id, setsong_id=None, song_id, position=None, title, duration, singer_lead, singer_background, interpret, genre=None, tone_key=None, ytlink=None, comment=None, brass, status=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SetInGigOut(*, id=None, gigset_id=None, set_id=None, set_name='', pause=None, setlist_name='', songs)[Quellcode]
Bases:
BaseModel- songs: List[SongInSetOut]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigSetlistTimingOut(*, schedule=<factory>, pause_before=<factory>, set_end=<factory>)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigSetlistOut(*, id, name, datum, organizer=None, kind_of_gig=None, venue=None, doors=None, begin=None, end=None, status=None, publish=None, sets, timing=None)[Quellcode]
Bases:
BaseModel- sets: List[SetInGigOut]
- timing: GigSetlistTimingOut | None
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongInSetLM(*, id, title, interpret, position, tone_key=None, comment=None, uebersprungen=None, eingeschoben=None, feedback=None)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongInSetLMUpdate(*, id, uebersprungen=None, eingeschoben=None, feedback=None)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SetInGigLM(*, id, position, pause=None, setlist_name=None, songs)[Quellcode]
Bases:
BaseModel- songs: List[SongInSetLM]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigSetListLiveMode(*, id, name, datum, doors=None, begin=None, end=None, sets)[Quellcode]
Bases:
BaseModel- sets: List[SetInGigLM]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GetSetlistIn(*, id, name, datum, organizer=None, kind_of_gig=None, venue=None, doors=None, begin=None, end=None, status=None, publish=None, sets)[Quellcode]
Bases:
BaseModel- sets: List[SetInGigOut]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongToSetIn[Quellcode]
Bases:
object
- class backend.schemas.TodoInSong(*, id, id_song, id_reh, id_user, todo, dt, done)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongInReh(*, id=None, id_rehearsal, id_song, interpret, title, status, comment, setlist_comment, todo, song_todos=<factory>, done)[Quellcode]
Bases:
BaseModel- song_todos: List[TodoInSong] | None
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongRehearsalHistoryTodo(*, id, id_user, todo, done)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongRehearsalHistoryEntry(*, rehearsal_id, rehearsal_date, comment=None, todo=None, done=False, rehearsal_comment=None, todos=<factory>)[Quellcode]
Bases:
BaseModel- todos: List[SongRehearsalHistoryTodo]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigPlayedEntry(*, gig_id, gig_name, gig_date, feedback=None, uebersprungen=None, eingeschoben=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.CompanionSong(*, song_id, title, interpret, count)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SongStatistics(*, rehearsal_count=0, first_rehearsal=None, last_rehearsal=None, gig_count=0, gigs_played=<factory>, feedback_count=0, feedback_avg=None, feedback_distribution=<factory>, skipped_count=0, inserted_count=0, companion_songs=<factory>)[Quellcode]
Bases:
BaseModel- gigs_played: List[GigPlayedEntry]
- companion_songs: List[CompanionSong]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigOverviewEntry(*, gig_id, gig_name, gig_date, song_count, skipped_count, inserted_count, feedback_avg=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.TopSongEntry(*, song_id, title, interpret, count)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GenreTimelinePoint(*, label, date=None, kind_of_gig=None, genre_counts=<factory>, total=0)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GenrePaletteOut(*, palette=<factory>)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SeasonStatistics(*, jahr=None, gig_count=0, played_gig_count=0, total_songs=0, unique_songs=0, skipped_count=0, inserted_count=0, feedback_count=0, feedback_avg=None, feedback_distribution=<factory>, genre_distribution=<factory>, genre_timeline=<factory>, top_songs=<factory>, gigs_overview=<factory>)[Quellcode]
Bases:
BaseModel- genre_timeline: List[GenreTimelinePoint]
- top_songs: List[TopSongEntry]
- gigs_overview: List[GigOverviewEntry]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigStatsSongEntry(*, song_id, title, interpret, position, feedback=None, uebersprungen=None, eingeschoben=None)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigStatsSetEntry(*, set_name, feedback_avg=None, songs=<factory>)[Quellcode]
Bases:
BaseModel- songs: List[GigStatsSongEntry]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.GigStatistics(*, gig_id, gig_name, gig_date, song_count=0, skipped_count=0, inserted_count=0, feedback_count=0, feedback_avg=None, feedback_distribution=<factory>, genre_distribution=<factory>, genre_timeline=<factory>, sets=<factory>)[Quellcode]
Bases:
BaseModel- genre_timeline: List[GenreTimelinePoint]
- sets: List[GigStatsSetEntry]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.RehListElem(*, id, begin, end=None, comment=None, ical='', songs=<factory>)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.NewRehDict(*, begin, end=None, comment)[Quellcode]
Bases:
BaseModel- validate_time_range()[Quellcode]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.UserListElem(*, id, user_name, clear_name, email)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyFeedbackOut(*, id=-1, id_sv_field, id_user, value=None, comment='')[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyFieldsOut(*, id, id_survey, field_text, feedbacks=<factory>)[Quellcode]
Bases:
BaseModel- feedbacks: List[SurveyFeedbackOut]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyQuestionOut(*, id, kind_of_survey, rf_survey, released, release_date, closed, fields, user_created)[Quellcode]
Bases:
BaseModel- fields: List[SurveyFieldsOut]
- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyList(*, id, kind_of_survey, rf_survey, released, closed, release_date, user_created)[Quellcode]
Bases:
BaseModel- model_config = {'from_attributes': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyFieldIn(*, field_text)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.SurveyIn(*, kind_of_survey, rf_survey, released, closed, fields)[Quellcode]
Bases:
BaseModel- fields: List[SurveyFieldIn]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.PublicSongHistogram(*, genre, count)[Quellcode]
Bases:
BaseModel- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class backend.schemas.PublicDate(*, Datum, Name, Ort, Einlass=None, Beginn=None, Ende=None, Veranstalter=None, Art=None)[Quellcode]
Bases:
BaseModel- classmethod from_gig(gig)[Quellcode]
- model_config = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].