Project¶
- class Project(json_data, linked_user: User)¶
Contains all the data regarding a project.
- update_data()¶
Updates the project’s information.
- delete()¶
Deletes the project.
- convert()¶
Begins the conversion of the project into a snapshot.
- get_snapshots() List[ProjectSnapshot] ¶
Gets the project’s snapshots (audio versions).
- get_snapshot_by_id(project_snapshot_id: str) ProjectSnapshot ¶
Gets a snapshot of the project by ID.
- class Chapter(json_data, parent_project: Project)¶
- update_data()¶
Updates the chapter’s data.
- delete()¶
Deletes the chapter.
- convert()¶
Begins the conversion of the chapter into a snapshot.
- get_snapshots() List[ChapterSnapshot] ¶
Gets the chapter’s snapshots (audio versions).
- get_snapshot_by_id(chapter_snapshot_id: str) ChapterSnapshot ¶
Gets a snapshot of the chapter by ID.
- class ProjectSnapshot(json_data, parent_project: Project)¶
Bases:
_PlayableItem
- created_at_unix: str¶
The UNIX timestamp for when the snapshot was created.
- get_audio_bytes() bytes ¶
Retrieves the audio bytes associated with this object. .. note:: The audio will be cached so that it’s not downloaded every time this is called.
- Returns:
a bytes object containing the audio in whatever format it was originally uploaded in.
- Return type:
bytes
- class ChapterSnapshot(json_data, parent_chapter: Chapter)¶
Bases:
_PlayableItem
- created_at_unix: str¶
The UNIX timestamp for when the snapshot was created.
- get_audio_bytes() bytes ¶
Retrieves the audio bytes associated with this object. .. note:: The audio will be cached so that it’s not downloaded every time this is called.
- Returns:
a bytes object containing the audio in whatever format it was originally uploaded in.
- Return type:
bytes
- class PronunciationDictionary(pronunciation_dictionary_id: str, version_id: str)¶
Represents a pronunciation dictionary. Can be created manually from stored IDs by using pronunciation_dictionary_from_ids.
- static pdict_json_factory(json_data)¶
Creates a complete PronunciationDictionary from the JSON data.