diff --git a/metadata/src/lib.rs b/metadata/src/lib.rs index d328a7d9..e7595f59 100644 --- a/metadata/src/lib.rs +++ b/metadata/src/lib.rs @@ -359,7 +359,7 @@ impl Metadata for Episode { let country = session.country(); let files = msg - .get_file() + .get_audio() .iter() .filter(|file| file.has_file_id()) .map(|file| { @@ -370,7 +370,7 @@ impl Metadata for Episode { .collect(); let covers = msg - .get_covers() + .get_cover_image() .get_image() .iter() .filter(|image| image.has_file_id()) @@ -412,7 +412,7 @@ impl Metadata for Show { .collect::>(); let covers = msg - .get_covers() + .get_cover_image() .get_image() .iter() .filter(|image| image.has_file_id()) diff --git a/playback/src/player.rs b/playback/src/player.rs index 8cbb4372..d67d2f88 100644 --- a/playback/src/player.rs +++ b/playback/src/player.rs @@ -652,12 +652,9 @@ impl PlayerTrackLoader { FileFormat::MP3_160 => 20 * 1024, FileFormat::MP3_96 => 12 * 1024, FileFormat::MP3_160_ENC => 20 * 1024, - FileFormat::MP4_128_DUAL => 16 * 1024, - FileFormat::OTHER3 => 40 * 1024, // better some high guess than nothing - FileFormat::AAC_160 => 20 * 1024, - FileFormat::AAC_320 => 40 * 1024, - FileFormat::MP4_128 => 16 * 1024, - FileFormat::OTHER5 => 40 * 1024, // better some high guess than nothing + FileFormat::AAC_24 => 3 * 1024, + FileFormat::AAC_48 => 6 * 1024, + FileFormat::FLAC_FLAC => 112 * 1024, // assume 900 kbps on average } } diff --git a/protocol/build.rs b/protocol/build.rs index c65c109a..53e04bc7 100644 --- a/protocol/build.rs +++ b/protocol/build.rs @@ -16,10 +16,11 @@ fn compile() { let proto_dir = Path::new(&env::var("CARGO_MANIFEST_DIR").expect("env")).join("proto"); let files = &[ + proto_dir.join("metadata.proto"), + // TODO: remove these legacy protobufs when we are on the new API completely proto_dir.join("authentication.proto"), proto_dir.join("keyexchange.proto"), proto_dir.join("mercury.proto"), - proto_dir.join("metadata.proto"), proto_dir.join("playlist4changes.proto"), proto_dir.join("playlist4content.proto"), proto_dir.join("playlist4issues.proto"), diff --git a/protocol/proto/AdDecisionEvent.proto b/protocol/proto/AdDecisionEvent.proto new file mode 100644 index 00000000..07a0a940 --- /dev/null +++ b/protocol/proto/AdDecisionEvent.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AdDecisionEvent { + optional string request_id = 1; + optional string decision_request_id = 2; + optional string decision_type = 3; +} diff --git a/protocol/proto/AdError.proto b/protocol/proto/AdError.proto new file mode 100644 index 00000000..1a69e788 --- /dev/null +++ b/protocol/proto/AdError.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AdError { + optional string request_type = 1; + optional string error_message = 2; + optional int64 http_error_code = 3; + optional string request_url = 4; + optional string tracking_event = 5; +} diff --git a/protocol/proto/AdEvent.proto b/protocol/proto/AdEvent.proto new file mode 100644 index 00000000..4b0a3059 --- /dev/null +++ b/protocol/proto/AdEvent.proto @@ -0,0 +1,27 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AdEvent { + optional string request_id = 1; + optional string app_startup_id = 2; + optional string ad_id = 3; + optional string lineitem_id = 4; + optional string creative_id = 5; + optional string slot = 6; + optional string format = 7; + optional string type = 8; + optional bool skippable = 9; + optional string event = 10; + optional string event_source = 11; + optional string event_reason = 12; + optional int32 event_sequence_num = 13; + optional int32 position = 14; + optional int32 duration = 15; + optional bool in_focus = 16; + optional float volume = 17; +} diff --git a/protocol/proto/AdRequestEvent.proto b/protocol/proto/AdRequestEvent.proto new file mode 100644 index 00000000..3ffdf863 --- /dev/null +++ b/protocol/proto/AdRequestEvent.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AdRequestEvent { + optional string feature_identifier = 1; + optional string requested_ad_type = 2; + optional int64 latency_ms = 3; + repeated string requested_ad_types = 4; +} diff --git a/protocol/proto/AdSlotEvent.proto b/protocol/proto/AdSlotEvent.proto new file mode 100644 index 00000000..1f345b69 --- /dev/null +++ b/protocol/proto/AdSlotEvent.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AdSlotEvent { + optional string event = 1; + optional string ad_id = 2; + optional string lineitem_id = 3; + optional string creative_id = 4; + optional string slot = 5; + optional string format = 6; + optional bool in_focus = 7; + optional string app_startup_id = 8; + optional string request_id = 9; +} diff --git a/protocol/proto/AmazonWakeUpTime.proto b/protocol/proto/AmazonWakeUpTime.proto new file mode 100644 index 00000000..25d64c48 --- /dev/null +++ b/protocol/proto/AmazonWakeUpTime.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AmazonWakeUpTime { + optional int64 delay_to_online = 1; +} diff --git a/protocol/proto/AudioDriverError.proto b/protocol/proto/AudioDriverError.proto new file mode 100644 index 00000000..3c97b461 --- /dev/null +++ b/protocol/proto/AudioDriverError.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioDriverError { + optional int64 error_code = 1; + optional string location = 2; + optional string driver_name = 3; + optional string additional_data = 4; +} diff --git a/protocol/proto/AudioDriverInfo.proto b/protocol/proto/AudioDriverInfo.proto new file mode 100644 index 00000000..23bae0a7 --- /dev/null +++ b/protocol/proto/AudioDriverInfo.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioDriverInfo { + optional string driver_name = 1; + optional string output_device_name = 2; + optional string output_device_category = 3; + optional string reason = 4; +} diff --git a/protocol/proto/AudioFileSelection.proto b/protocol/proto/AudioFileSelection.proto new file mode 100644 index 00000000..d99b36f4 --- /dev/null +++ b/protocol/proto/AudioFileSelection.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioFileSelection { + optional bytes playback_id = 1; + optional string strategy_name = 2; + optional int64 bitrate = 3; + optional bytes predict_id = 4; + optional string file_origin = 5; + optional int32 target_bitrate = 6; +} diff --git a/protocol/proto/AudioOffliningSettingsReport.proto b/protocol/proto/AudioOffliningSettingsReport.proto new file mode 100644 index 00000000..71d87f17 --- /dev/null +++ b/protocol/proto/AudioOffliningSettingsReport.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioOffliningSettingsReport { + optional string default_sync_bitrate_product_state = 1; + optional int64 user_selected_sync_bitrate = 2; + optional int64 sync_bitrate = 3; + optional bool sync_over_cellular = 4; + optional string primary_resource_type = 5; +} diff --git a/protocol/proto/AudioRateLimit.proto b/protocol/proto/AudioRateLimit.proto new file mode 100644 index 00000000..0ead830d --- /dev/null +++ b/protocol/proto/AudioRateLimit.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioRateLimit { + optional string driver_name = 1; + optional string output_device_name = 2; + optional string output_device_category = 3; + optional int64 max_size = 4; + optional int64 refill_per_milliseconds = 5; + optional int64 frames_requested = 6; + optional int64 frames_acquired = 7; + optional bytes playback_id = 8; +} diff --git a/protocol/proto/AudioSessionEvent.proto b/protocol/proto/AudioSessionEvent.proto new file mode 100644 index 00000000..c9b1a531 --- /dev/null +++ b/protocol/proto/AudioSessionEvent.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioSessionEvent { + optional string event = 1; + optional string context = 2; + optional string json_data = 3; +} diff --git a/protocol/proto/AudioSettingsReport.proto b/protocol/proto/AudioSettingsReport.proto new file mode 100644 index 00000000..e99ea8ec --- /dev/null +++ b/protocol/proto/AudioSettingsReport.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioSettingsReport { + optional bool offline_mode = 1; + optional string default_play_bitrate_product_state = 2; + optional int64 user_selected_bitrate = 3; + optional int64 play_bitrate = 4; + optional bool low_bitrate_on_cellular = 5; + optional string default_sync_bitrate_product_state = 6; + optional int64 user_selected_sync_bitrate = 7; + optional int64 sync_bitrate = 8; + optional bool sync_over_cellular = 9; + optional string enable_gapless_product_state = 10; + optional bool enable_gapless = 11; + optional string enable_crossfade_product_state = 12; + optional bool enable_crossfade = 13; + optional int64 crossfade_time = 14; + optional bool enable_normalization = 15; + optional int64 playback_speed = 16; + optional string audio_loudness_level = 17; + optional bool enable_automix = 18; + optional bool enable_silence_trimmer = 19; + optional bool enable_mono_downmixer = 20; +} diff --git a/protocol/proto/AudioStreamingSettingsReport.proto b/protocol/proto/AudioStreamingSettingsReport.proto new file mode 100644 index 00000000..ef6e4730 --- /dev/null +++ b/protocol/proto/AudioStreamingSettingsReport.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message AudioStreamingSettingsReport { + optional string default_play_bitrate_product_state = 1; + optional int64 user_selected_play_bitrate_cellular = 2; + optional int64 user_selected_play_bitrate_wifi = 3; + optional int64 play_bitrate_cellular = 4; + optional int64 play_bitrate_wifi = 5; + optional bool allow_downgrade = 6; +} diff --git a/protocol/proto/BoomboxPlaybackInstrumentation.proto b/protocol/proto/BoomboxPlaybackInstrumentation.proto new file mode 100644 index 00000000..01e3f2c7 --- /dev/null +++ b/protocol/proto/BoomboxPlaybackInstrumentation.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message BoomboxPlaybackInstrumentation { + optional bytes playback_id = 1; + optional bool was_playback_paused = 2; + repeated string dimensions = 3; + map total_buffer_size = 4; + map number_of_calls = 5; + map total_duration = 6; + map first_call_time = 7; + map last_call_time = 8; +} diff --git a/protocol/proto/BrokenObject.proto b/protocol/proto/BrokenObject.proto new file mode 100644 index 00000000..3bdb6677 --- /dev/null +++ b/protocol/proto/BrokenObject.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message BrokenObject { + optional string type = 1; + optional string id = 2; + optional int64 error_code = 3; + optional bytes playback_id = 4; +} diff --git a/protocol/proto/CacheError.proto b/protocol/proto/CacheError.proto new file mode 100644 index 00000000..8da6196d --- /dev/null +++ b/protocol/proto/CacheError.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CacheError { + optional int64 error_code = 1; + optional int64 os_error_code = 2; + optional string realm = 3; + optional bytes file_id = 4; + optional int64 num_errors = 5; + optional string cache_path = 6; +} diff --git a/protocol/proto/CachePruningReport.proto b/protocol/proto/CachePruningReport.proto new file mode 100644 index 00000000..3225f1d5 --- /dev/null +++ b/protocol/proto/CachePruningReport.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CachePruningReport { + optional bytes cache_id = 1; + optional int64 time_spent_pruning_ms = 2; + optional int64 size_before_prune_kb = 3; + optional int64 size_after_prune_kb = 4; + optional int64 num_entries_pruned = 5; + optional int64 num_entries_pruned_expired = 6; + optional int64 size_entries_pruned_expired_kb = 7; + optional int64 num_entries_pruned_limit = 8; + optional int64 size_pruned_limit_kb = 9; + optional int64 num_entries_pruned_never_used = 10; + optional int64 size_pruned_never_used_kb = 11; + optional int64 num_entries_pruned_max_realm_size = 12; + optional int64 size_pruned_max_realm_size_kb = 13; + optional int64 num_entries_pruned_min_free_space = 14; + optional int64 size_pruned_min_free_space_kb = 15; +} diff --git a/protocol/proto/CacheRealmPruningReport.proto b/protocol/proto/CacheRealmPruningReport.proto new file mode 100644 index 00000000..479a26a5 --- /dev/null +++ b/protocol/proto/CacheRealmPruningReport.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CacheRealmPruningReport { + optional bytes cache_id = 1; + optional int64 realm_id = 2; + optional int64 num_entries_pruned = 3; + optional int64 num_entries_pruned_expired = 4; + optional int64 size_entries_pruned_expired_kb = 5; + optional int64 num_entries_pruned_limit = 6; + optional int64 size_pruned_limit_kb = 7; + optional int64 num_entries_pruned_never_used = 8; + optional int64 size_pruned_never_used_kb = 9; + optional int64 num_entries_pruned_max_realm_size = 10; + optional int64 size_pruned_max_realm_size_kb = 11; + optional int64 num_entries_pruned_min_free_space = 12; + optional int64 size_pruned_min_free_space_kb = 13; +} diff --git a/protocol/proto/CacheRealmReport.proto b/protocol/proto/CacheRealmReport.proto new file mode 100644 index 00000000..4d3c8a55 --- /dev/null +++ b/protocol/proto/CacheRealmReport.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CacheRealmReport { + optional bytes cache_id = 1; + optional int64 realm_id = 2; + optional int64 num_entries = 3; + optional int64 num_locked_entries = 4; + optional int64 num_locked_entries_current_user = 5; + optional int64 num_full_entries = 6; + optional int64 size_kb = 7; + optional int64 locked_size_kb = 8; +} diff --git a/protocol/proto/CacheReport.proto b/protocol/proto/CacheReport.proto new file mode 100644 index 00000000..c8666ca3 --- /dev/null +++ b/protocol/proto/CacheReport.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CacheReport { + optional bytes cache_id = 1; + optional int64 max_cache_size = 2; + optional int64 free_space = 3; + optional int64 total_space = 4; + optional int64 cache_age = 5; + optional int64 num_users_with_locked_entries = 6; + optional int64 permanent_files = 7; + optional int64 permanent_size_kb = 8; + optional int64 unknown_permanent_files = 9; + optional int64 unknown_permanent_size_kb = 10; + optional int64 volatile_files = 11; + optional int64 volatile_size_kb = 12; + optional int64 unknown_volatile_files = 13; + optional int64 unknown_volatile_size_kb = 14; + optional int64 num_entries = 15; + optional int64 num_locked_entries = 16; + optional int64 num_locked_entries_current_user = 17; + optional int64 num_full_entries = 18; + optional int64 size_kb = 19; + optional int64 locked_size_kb = 20; +} diff --git a/protocol/proto/ClientLocale.proto b/protocol/proto/ClientLocale.proto new file mode 100644 index 00000000..a8e330b3 --- /dev/null +++ b/protocol/proto/ClientLocale.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ClientLocale { + optional string client_default_locale = 1; + optional string user_specified_locale = 2; +} diff --git a/protocol/proto/ColdStartupSequence.proto b/protocol/proto/ColdStartupSequence.proto new file mode 100644 index 00000000..cfeedee9 --- /dev/null +++ b/protocol/proto/ColdStartupSequence.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ColdStartupSequence { + optional string terminal_state = 1; + map steps = 2; + map metadata = 3; + optional string connection_type = 4; + optional string initial_application_state = 5; + optional string terminal_application_state = 6; + optional string view_load_sequence_id = 7; + optional int32 device_year_class = 8; + map subdurations = 9; +} diff --git a/protocol/proto/CollectionLevelDbInfo.proto b/protocol/proto/CollectionLevelDbInfo.proto new file mode 100644 index 00000000..4f222487 --- /dev/null +++ b/protocol/proto/CollectionLevelDbInfo.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CollectionLevelDbInfo { + optional string bucket = 1; + optional bool use_leveldb = 2; + optional bool migration_from_file_ok = 3; + optional bool index_check_ok = 4; + optional bool leveldb_works = 5; + optional bool already_migrated = 6; +} diff --git a/protocol/proto/CollectionOfflineControllerEmptyTrackList.proto b/protocol/proto/CollectionOfflineControllerEmptyTrackList.proto new file mode 100644 index 00000000..ee830433 --- /dev/null +++ b/protocol/proto/CollectionOfflineControllerEmptyTrackList.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message CollectionOfflineControllerEmptyTrackList { + optional string link_type = 1; + optional bool consistent_with_collection = 2; + optional int64 collection_size = 3; +} diff --git a/protocol/proto/ConfigurationApplied.proto b/protocol/proto/ConfigurationApplied.proto new file mode 100644 index 00000000..40aad33c --- /dev/null +++ b/protocol/proto/ConfigurationApplied.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConfigurationApplied { + optional int64 last_rcs_fetch_time = 1; + optional string installation_id = 2; + repeated int32 policy_group_ids = 3; + optional string configuration_assignment_id = 4; + optional string rc_client_id = 5; + optional string rc_client_version = 6; + optional string platform = 7; + optional string fetch_type = 8; +} diff --git a/protocol/proto/ConfigurationFetched.proto b/protocol/proto/ConfigurationFetched.proto new file mode 100644 index 00000000..bb61a2e0 --- /dev/null +++ b/protocol/proto/ConfigurationFetched.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConfigurationFetched { + optional int64 last_rcs_fetch_time = 1; + optional string installation_id = 2; + optional string configuration_assignment_id = 3; + optional string property_set_id = 4; + optional string attributes_set_id = 5; + optional string rc_client_id = 6; + optional string rc_client_version = 7; + optional string rc_sdk_version = 8; + optional string platform = 9; + optional string fetch_type = 10; + optional int64 latency = 11; + optional int64 payload_size = 12; + optional int32 status_code = 13; + optional string error_reason = 14; + optional string error_message = 15; + optional string error_reason_configuration_resolve = 16; + optional string error_message_configuration_resolve = 17; + optional string error_reason_account_attributes = 18; + optional string error_message_account_attributes = 19; + optional int32 error_code_account_attributes = 20; + optional int32 error_code_configuration_resolve = 21; +} diff --git a/protocol/proto/ConfigurationFetchedNonAuth.proto b/protocol/proto/ConfigurationFetchedNonAuth.proto new file mode 100644 index 00000000..e28d1d39 --- /dev/null +++ b/protocol/proto/ConfigurationFetchedNonAuth.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConfigurationFetchedNonAuth { + optional int64 last_rcs_fetch_time = 1; + optional string installation_id = 2; + optional string configuration_assignment_id = 3; + optional string property_set_id = 4; + optional string attributes_set_id = 5; + optional string rc_client_id = 6; + optional string rc_client_version = 7; + optional string rc_sdk_version = 8; + optional string platform = 9; + optional string fetch_type = 10; + optional int64 latency = 11; + optional int64 payload_size = 12; + optional int32 status_code = 13; + optional string error_reason = 14; + optional string error_message = 15; + optional string error_reason_configuration_resolve = 16; + optional string error_message_configuration_resolve = 17; + optional string error_reason_account_attributes = 18; + optional string error_message_account_attributes = 19; + optional int32 error_code_account_attributes = 20; + optional int32 error_code_configuration_resolve = 21; +} diff --git a/protocol/proto/ConnectCredentialsRequest.proto b/protocol/proto/ConnectCredentialsRequest.proto new file mode 100644 index 00000000..d3e91cf3 --- /dev/null +++ b/protocol/proto/ConnectCredentialsRequest.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectCredentialsRequest { + optional string token_type = 1; + optional string client_id = 2; +} diff --git a/protocol/proto/ConnectDeviceDiscovered.proto b/protocol/proto/ConnectDeviceDiscovered.proto new file mode 100644 index 00000000..bb156ff7 --- /dev/null +++ b/protocol/proto/ConnectDeviceDiscovered.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectDeviceDiscovered { + optional string device_id = 1; + optional string discover_method = 2; + optional string discovered_device_id = 3; + optional string discovered_device_type = 4; + optional string discovered_library_version = 5; + optional string discovered_brand_display_name = 6; + optional string discovered_model_display_name = 7; + optional string discovered_client_id = 8; + optional string discovered_product_id = 9; + optional string discovered_device_availablilty = 10; + optional string discovered_device_public_key = 11; + optional bool capabilities_resolved = 12; +} diff --git a/protocol/proto/ConnectDialError.proto b/protocol/proto/ConnectDialError.proto new file mode 100644 index 00000000..90a8f36a --- /dev/null +++ b/protocol/proto/ConnectDialError.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectDialError { + optional string type = 1; + optional string request = 2; + optional string response = 3; + optional int64 error = 4; + optional string context = 5; +} diff --git a/protocol/proto/ConnectMdnsPacketParseError.proto b/protocol/proto/ConnectMdnsPacketParseError.proto new file mode 100644 index 00000000..e7685828 --- /dev/null +++ b/protocol/proto/ConnectMdnsPacketParseError.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectMdnsPacketParseError { + optional string type = 1; + optional string buffer = 2; + optional string ttl = 3; + optional string txt = 4; + optional string host = 5; + optional string discovery_name = 6; + optional string context = 7; +} diff --git a/protocol/proto/ConnectPullFailure.proto b/protocol/proto/ConnectPullFailure.proto new file mode 100644 index 00000000..fc1f9819 --- /dev/null +++ b/protocol/proto/ConnectPullFailure.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectPullFailure { + optional bytes transfer_data = 1; + optional int64 error_code = 2; + map reasons = 3; +} diff --git a/protocol/proto/ConnectTransferResult.proto b/protocol/proto/ConnectTransferResult.proto new file mode 100644 index 00000000..9239e845 --- /dev/null +++ b/protocol/proto/ConnectTransferResult.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectTransferResult { + optional string result = 1; + optional string device_type = 2; + optional string discovery_class = 3; + optional string device_model = 4; + optional string device_brand = 5; + optional string device_software_version = 6; + optional int64 duration = 7; + optional string device_client_id = 8; + optional string transfer_intent_id = 9; + optional string transfer_debug_log = 10; + optional string error_code = 11; + optional int32 http_response_code = 12; + optional string initial_device_state = 13; + optional int32 retry_count = 14; + optional int32 login_retry_count = 15; + optional int64 login_duration = 16; + optional string target_device_id = 17; + optional bool target_device_is_local = 18; + optional string final_device_state = 19; +} diff --git a/protocol/proto/ConnectionError.proto b/protocol/proto/ConnectionError.proto new file mode 100644 index 00000000..8c1c35bd --- /dev/null +++ b/protocol/proto/ConnectionError.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectionError { + optional int64 error_code = 1; + optional string ap = 2; + optional string proxy = 3; +} diff --git a/protocol/proto/ConnectionInfo.proto b/protocol/proto/ConnectionInfo.proto new file mode 100644 index 00000000..2c830ed5 --- /dev/null +++ b/protocol/proto/ConnectionInfo.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ConnectionInfo { + optional string ap = 1; + optional string proxy = 2; + optional bool user_initated_login = 3; + optional string reachability_type = 4; + optional string web_installer_unique_id = 5; + optional string ap_resolve_source = 6; + optional string address_type = 7; + optional bool ipv6_failed = 8; +} diff --git a/protocol/proto/DefaultConfigurationApplied.proto b/protocol/proto/DefaultConfigurationApplied.proto new file mode 100644 index 00000000..9236ecb9 --- /dev/null +++ b/protocol/proto/DefaultConfigurationApplied.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DefaultConfigurationApplied { + optional string installation_id = 1; + optional string configuration_assignment_id = 2; + optional string rc_client_id = 3; + optional string rc_client_version = 4; + optional string platform = 5; + optional string fetch_type = 6; + optional string reason = 7; +} diff --git a/protocol/proto/DesktopAuthenticationFailureNonAuth.proto b/protocol/proto/DesktopAuthenticationFailureNonAuth.proto new file mode 100644 index 00000000..e3b495ec --- /dev/null +++ b/protocol/proto/DesktopAuthenticationFailureNonAuth.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopAuthenticationFailureNonAuth { + optional string action_hash = 1; + optional string error_category = 2; + optional int32 error_code = 3; +} diff --git a/protocol/proto/DesktopAuthenticationSuccess.proto b/protocol/proto/DesktopAuthenticationSuccess.proto new file mode 100644 index 00000000..8814df79 --- /dev/null +++ b/protocol/proto/DesktopAuthenticationSuccess.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopAuthenticationSuccess { + optional string action_hash = 1; +} diff --git a/protocol/proto/DesktopGPUAccelerationInfo.proto b/protocol/proto/DesktopGPUAccelerationInfo.proto new file mode 100644 index 00000000..2fbaed08 --- /dev/null +++ b/protocol/proto/DesktopGPUAccelerationInfo.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopGPUAccelerationInfo { + optional bool is_enabled = 1; +} diff --git a/protocol/proto/DesktopHighMemoryUsage.proto b/protocol/proto/DesktopHighMemoryUsage.proto new file mode 100644 index 00000000..e55106e3 --- /dev/null +++ b/protocol/proto/DesktopHighMemoryUsage.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopHighMemoryUsage { + optional bool is_continuation_event = 1; + optional double sample_time_interval_seconds = 2; + optional int64 win_committed_bytes = 3; + optional int64 win_peak_committed_bytes = 4; + optional int64 win_working_set_bytes = 5; + optional int64 win_peak_working_set_bytes = 6; + optional int64 mac_virtual_size_bytes = 7; + optional int64 mac_resident_size_bytes = 8; + optional int64 mac_footprint_bytes = 9; +} diff --git a/protocol/proto/DesktopUpdateDownloadComplete.proto b/protocol/proto/DesktopUpdateDownloadComplete.proto new file mode 100644 index 00000000..bf1fe4d9 --- /dev/null +++ b/protocol/proto/DesktopUpdateDownloadComplete.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopUpdateDownloadComplete { + optional int64 revision = 1; + optional bool is_critical = 2; + optional string source = 3; + optional bool is_successful = 4; + optional bool is_employee = 5; +} diff --git a/protocol/proto/DesktopUpdateDownloadError.proto b/protocol/proto/DesktopUpdateDownloadError.proto new file mode 100644 index 00000000..8385d4a1 --- /dev/null +++ b/protocol/proto/DesktopUpdateDownloadError.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopUpdateDownloadError { + optional int64 revision = 1; + optional bool is_critical = 2; + optional string error_message = 3; + optional string source = 4; + optional bool is_employee = 5; +} diff --git a/protocol/proto/DesktopUpdateMessageAction.proto b/protocol/proto/DesktopUpdateMessageAction.proto new file mode 100644 index 00000000..3ff5efea --- /dev/null +++ b/protocol/proto/DesktopUpdateMessageAction.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopUpdateMessageAction { + optional bool will_download = 1; + optional int64 this_message_from_revision = 2; + optional int64 this_message_to_revision = 3; + optional bool is_critical = 4; + optional int64 already_downloaded_from_revision = 5; + optional int64 already_downloaded_to_revision = 6; + optional string source = 7; + optional bool is_employee = 8; +} diff --git a/protocol/proto/DesktopUpdateMessageProcessed.proto b/protocol/proto/DesktopUpdateMessageProcessed.proto new file mode 100644 index 00000000..71b2e766 --- /dev/null +++ b/protocol/proto/DesktopUpdateMessageProcessed.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopUpdateMessageProcessed { + optional bool success = 1; + optional string source = 2; + optional int64 revision = 3; + optional bool is_critical = 4; + optional string binary_hash = 5; + optional bool is_employee = 6; +} diff --git a/protocol/proto/DesktopUpdateResponse.proto b/protocol/proto/DesktopUpdateResponse.proto new file mode 100644 index 00000000..683672f2 --- /dev/null +++ b/protocol/proto/DesktopUpdateResponse.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DesktopUpdateResponse { + optional int64 status_code = 1; + optional int64 request_time_ms = 2; + optional int64 payload_size = 3; + optional bool is_employee = 4; + optional string error_message = 5; +} diff --git a/protocol/proto/Download.proto b/protocol/proto/Download.proto new file mode 100644 index 00000000..417236bd --- /dev/null +++ b/protocol/proto/Download.proto @@ -0,0 +1,53 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Download { + optional bytes file_id = 1; + optional bytes playback_id = 2; + optional int64 bytes_from_ap = 3; + optional int64 waste_from_ap = 4; + optional int64 reqs_from_ap = 5; + optional int64 error_from_ap = 6; + optional int64 bytes_from_cdn = 7; + optional int64 waste_from_cdn = 8; + optional int64 bytes_from_cache = 9; + optional int64 content_size = 10; + optional string content_type = 11; + optional int64 ap_initial_latency = 12; + optional int64 ap_max_latency = 13; + optional int64 ap_min_latency = 14; + optional double ap_avg_latency = 15; + optional int64 ap_median_latency = 16; + optional double ap_avg_bw = 17; + optional int64 cdn_initial_latency = 18; + optional int64 cdn_max_latency = 19; + optional int64 cdn_min_latency = 20; + optional double cdn_avg_latency = 21; + optional int64 cdn_median_latency = 22; + optional int64 cdn_64k_initial_latency = 23; + optional int64 cdn_64k_max_latency = 24; + optional int64 cdn_64k_min_latency = 25; + optional double cdn_64k_avg_latency = 26; + optional int64 cdn_64k_median_latency = 27; + optional double cdn_avg_bw = 28; + optional double cdn_initial_bw_estimate = 29; + optional string cdn_uri_scheme = 30; + optional string cdn_domain = 31; + optional string cdn_socket_reuse = 32; + optional int64 num_cache_error = 33; + optional int64 bytes_from_carrier = 34; + optional int64 bytes_from_unknown = 35; + optional int64 bytes_from_wifi = 36; + optional int64 bytes_from_ethernet = 37; + optional string request_type = 38; + optional int64 total_time = 39; + optional int64 bitrate = 40; + optional int64 reqs_from_cdn = 41; + optional int64 error_from_cdn = 42; + optional string file_origin = 43; +} diff --git a/protocol/proto/DrmRequestFailure.proto b/protocol/proto/DrmRequestFailure.proto new file mode 100644 index 00000000..8f7df231 --- /dev/null +++ b/protocol/proto/DrmRequestFailure.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message DrmRequestFailure { + optional string reason = 1; + optional int64 error_code = 2; + optional bool fatal = 3; + optional bytes playback_id = 4; +} diff --git a/protocol/proto/EndAd.proto b/protocol/proto/EndAd.proto new file mode 100644 index 00000000..cff0b7b6 --- /dev/null +++ b/protocol/proto/EndAd.proto @@ -0,0 +1,34 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message EndAd { + optional bytes file_id = 1; + optional bytes playback_id = 2; + optional bytes song_id = 3; + optional string source_start = 4; + optional string reason_start = 5; + optional string source_end = 6; + optional string reason_end = 7; + optional int64 bytes_played = 8; + optional int64 bytes_in_song = 9; + optional int64 ms_played = 10; + optional int64 ms_total_est = 11; + optional int64 ms_rcv_latency = 12; + optional int64 n_seekback = 13; + optional int64 ms_seekback = 14; + optional int64 n_seekfwd = 15; + optional int64 ms_seekfwd = 16; + optional int64 ms_latency = 17; + optional int64 n_stutter = 18; + optional int64 p_lowbuffer = 19; + optional bool skipped = 20; + optional bool ad_clicked = 21; + optional string token = 22; + optional int64 client_ad_count = 23; + optional int64 client_campaign_count = 24; +} diff --git a/protocol/proto/EventSenderInternalErrorNonAuth.proto b/protocol/proto/EventSenderInternalErrorNonAuth.proto new file mode 100644 index 00000000..e6fe182a --- /dev/null +++ b/protocol/proto/EventSenderInternalErrorNonAuth.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message EventSenderInternalErrorNonAuth { + optional string error_message = 1; + optional string error_type = 2; + optional string error_context = 3; + optional int32 error_code = 4; +} diff --git a/protocol/proto/EventSenderStats.proto b/protocol/proto/EventSenderStats.proto new file mode 100644 index 00000000..88be6fe1 --- /dev/null +++ b/protocol/proto/EventSenderStats.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message EventSenderStats { + map storage_size = 1; + map sequence_number_min = 2; + map sequence_number_next = 3; +} diff --git a/protocol/proto/ExternalDeviceInfo.proto b/protocol/proto/ExternalDeviceInfo.proto new file mode 100644 index 00000000..f590df22 --- /dev/null +++ b/protocol/proto/ExternalDeviceInfo.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ExternalDeviceInfo { + optional string type = 1; + optional string subtype = 2; + optional string reason = 3; + optional bool taken_over = 4; + optional int64 num_tracks = 5; + optional int64 num_purchased_tracks = 6; + optional int64 num_playlists = 7; + optional string error = 8; + optional bool full = 9; + optional bool sync_all = 10; +} diff --git a/protocol/proto/GetInfoFailures.proto b/protocol/proto/GetInfoFailures.proto new file mode 100644 index 00000000..868ae5b7 --- /dev/null +++ b/protocol/proto/GetInfoFailures.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message GetInfoFailures { + optional string device_id = 1; + optional int64 error_code = 2; + optional string request = 3; + optional string response_body = 4; + optional string context = 5; +} diff --git a/protocol/proto/HeadFileDownload.proto b/protocol/proto/HeadFileDownload.proto new file mode 100644 index 00000000..acfa87fa --- /dev/null +++ b/protocol/proto/HeadFileDownload.proto @@ -0,0 +1,26 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message HeadFileDownload { + optional bytes file_id = 1; + optional bytes playback_id = 2; + optional string cdn_uri_scheme = 3; + optional string cdn_domain = 4; + optional int64 head_file_size = 5; + optional int64 bytes_downloaded = 6; + optional int64 bytes_wasted = 7; + optional int64 http_latency = 8; + optional int64 http_64k_latency = 9; + optional int64 total_time = 10; + optional int64 http_result = 11; + optional int64 error_code = 12; + optional int64 cached_bytes = 13; + optional int64 bytes_from_cache = 14; + optional string socket_reuse = 15; + optional string request_type = 16; +} diff --git a/protocol/proto/LocalFileSyncError.proto b/protocol/proto/LocalFileSyncError.proto new file mode 100644 index 00000000..0403dba1 --- /dev/null +++ b/protocol/proto/LocalFileSyncError.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message LocalFileSyncError { + optional string error = 1; +} diff --git a/protocol/proto/LocalFilesError.proto b/protocol/proto/LocalFilesError.proto new file mode 100644 index 00000000..49347341 --- /dev/null +++ b/protocol/proto/LocalFilesError.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message LocalFilesError { + optional int64 error_code = 1; + optional string context = 2; +} diff --git a/protocol/proto/LocalFilesImport.proto b/protocol/proto/LocalFilesImport.proto new file mode 100644 index 00000000..4deff70f --- /dev/null +++ b/protocol/proto/LocalFilesImport.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message LocalFilesImport { + optional int64 tracks = 1; + optional int64 duplicate_tracks = 2; + optional int64 failed_tracks = 3; + optional int64 matched_tracks = 4; + optional string source = 5; +} diff --git a/protocol/proto/LocalFilesReport.proto b/protocol/proto/LocalFilesReport.proto new file mode 100644 index 00000000..cd5c99d7 --- /dev/null +++ b/protocol/proto/LocalFilesReport.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message LocalFilesReport { + optional int64 total_tracks = 1; + optional int64 total_size = 2; + optional int64 owned_tracks = 3; + optional int64 owned_size = 4; + optional int64 tracks_not_found = 5; + optional int64 tracks_bad_format = 6; + optional int64 tracks_drm_protected = 7; + optional int64 tracks_unknown_pruned = 8; + optional int64 tracks_reallocated_repaired = 9; + optional int64 enabled_sources = 10; +} diff --git a/protocol/proto/LocalFilesSourceReport.proto b/protocol/proto/LocalFilesSourceReport.proto new file mode 100644 index 00000000..9dbd4bd9 --- /dev/null +++ b/protocol/proto/LocalFilesSourceReport.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message LocalFilesSourceReport { + optional string id = 1; + optional int64 tracks = 2; +} diff --git a/protocol/proto/MdnsLoginFailures.proto b/protocol/proto/MdnsLoginFailures.proto new file mode 100644 index 00000000..cd036561 --- /dev/null +++ b/protocol/proto/MdnsLoginFailures.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message MdnsLoginFailures { + optional string device_id = 1; + optional int64 error_code = 2; + optional string response_body = 3; + optional string request = 4; + optional int64 esdk_internal_error_code = 5; + optional string context = 6; +} diff --git a/protocol/proto/MercuryCacheReport.proto b/protocol/proto/MercuryCacheReport.proto new file mode 100644 index 00000000..4c9e494f --- /dev/null +++ b/protocol/proto/MercuryCacheReport.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message MercuryCacheReport { + optional int64 mercury_cache_version = 1; + optional int64 num_items = 2; + optional int64 num_locked_items = 3; + optional int64 num_expired_items = 4; + optional int64 num_lock_ids = 5; + optional int64 num_expired_lock_ids = 6; + optional int64 max_size = 7; + optional int64 total_size = 8; + optional int64 used_size = 9; + optional int64 free_size = 10; +} diff --git a/protocol/proto/MetadataExtensionClientStatistic.proto b/protocol/proto/MetadataExtensionClientStatistic.proto new file mode 100644 index 00000000..253e0e18 --- /dev/null +++ b/protocol/proto/MetadataExtensionClientStatistic.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message MetadataExtensionClientStatistic { + optional bytes task_id = 1; + optional string feature_id = 2; + optional bool is_online_param = 3; + optional int32 num_extensions_with_etags = 4; + optional int32 num_extensions_requested = 5; + optional int32 num_extensions_needed = 6; + optional int32 num_uris_requested = 7; + optional int32 num_uris_needed = 8; + optional int32 num_prepared_requests = 9; + optional int32 num_sent_requests = 10; +} diff --git a/protocol/proto/ModuleDebug.proto b/protocol/proto/ModuleDebug.proto new file mode 100644 index 00000000..87691cd4 --- /dev/null +++ b/protocol/proto/ModuleDebug.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ModuleDebug { + optional string blob = 1; +} diff --git a/protocol/proto/Offline2ClientError.proto b/protocol/proto/Offline2ClientError.proto new file mode 100644 index 00000000..55c9ca24 --- /dev/null +++ b/protocol/proto/Offline2ClientError.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Offline2ClientError { + optional string error = 1; + optional string device_id = 2; + optional string cache_id = 3; +} diff --git a/protocol/proto/Offline2ClientEvent.proto b/protocol/proto/Offline2ClientEvent.proto new file mode 100644 index 00000000..b45bfd59 --- /dev/null +++ b/protocol/proto/Offline2ClientEvent.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Offline2ClientEvent { + optional string event = 1; + optional string device_id = 2; + optional string cache_id = 3; +} diff --git a/protocol/proto/OfflineError.proto b/protocol/proto/OfflineError.proto new file mode 100644 index 00000000..e669ce43 --- /dev/null +++ b/protocol/proto/OfflineError.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message OfflineError { + optional int64 error_code = 1; + optional string track = 2; +} diff --git a/protocol/proto/OfflineEvent.proto b/protocol/proto/OfflineEvent.proto new file mode 100644 index 00000000..e924f093 --- /dev/null +++ b/protocol/proto/OfflineEvent.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message OfflineEvent { + optional string event = 1; + optional string data = 2; +} diff --git a/protocol/proto/OfflineReport.proto b/protocol/proto/OfflineReport.proto new file mode 100644 index 00000000..2835f77d --- /dev/null +++ b/protocol/proto/OfflineReport.proto @@ -0,0 +1,26 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message OfflineReport { + optional int64 total_num_tracks = 1; + optional int64 num_downloaded_tracks = 2; + optional int64 num_downloaded_tracks_keyless = 3; + optional int64 total_num_links = 4; + optional int64 total_num_links_keyless = 5; + map context_num_links_map = 6; + map linktype_num_tracks_map = 7; + optional int64 track_limit = 8; + optional int64 expiry = 9; + optional string change_reason = 10; + optional int64 offline_keys = 11; + optional int64 cached_keys = 12; + optional int64 total_num_episodes = 13; + optional int64 num_downloaded_episodes = 14; + optional int64 episode_limit = 15; + optional int64 episode_expiry = 16; +} diff --git a/protocol/proto/OfflineUserPwdLoginNonAuth.proto b/protocol/proto/OfflineUserPwdLoginNonAuth.proto new file mode 100644 index 00000000..2932bd56 --- /dev/null +++ b/protocol/proto/OfflineUserPwdLoginNonAuth.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message OfflineUserPwdLoginNonAuth { + optional string connection_type = 1; +} diff --git a/protocol/proto/PlaybackError.proto b/protocol/proto/PlaybackError.proto new file mode 100644 index 00000000..6897490e --- /dev/null +++ b/protocol/proto/PlaybackError.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PlaybackError { + optional bytes file_id = 1; + optional bytes playback_id = 2; + optional string track_id = 3; + optional int64 bitrate = 4; + optional int64 error_code = 5; + optional bool fatal = 6; + optional string audiocodec = 7; + optional bool external_track = 8; + optional int64 position_ms = 9; +} diff --git a/protocol/proto/PlaybackRetry.proto b/protocol/proto/PlaybackRetry.proto new file mode 100644 index 00000000..82b9e9b3 --- /dev/null +++ b/protocol/proto/PlaybackRetry.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PlaybackRetry { + optional string track = 1; + optional bytes playback_id = 2; + optional string method = 3; + optional string status = 4; + optional string reason = 5; +} diff --git a/protocol/proto/PlaybackSegments.proto b/protocol/proto/PlaybackSegments.proto new file mode 100644 index 00000000..bd5026c7 --- /dev/null +++ b/protocol/proto/PlaybackSegments.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PlaybackSegments { + optional bytes playback_id = 1; + optional string track_uri = 2; + optional bool overflow = 3; + optional string segments = 4; +} diff --git a/protocol/proto/PlayerStateRestore.proto b/protocol/proto/PlayerStateRestore.proto new file mode 100644 index 00000000..f9778a7a --- /dev/null +++ b/protocol/proto/PlayerStateRestore.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PlayerStateRestore { + optional string error = 1; + optional int64 size = 2; + optional string context_uri = 3; + optional string state = 4; +} diff --git a/protocol/proto/PlaylistSyncEvent.proto b/protocol/proto/PlaylistSyncEvent.proto new file mode 100644 index 00000000..6f2a23e2 --- /dev/null +++ b/protocol/proto/PlaylistSyncEvent.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PlaylistSyncEvent { + optional string playlist_id = 1; + optional bool is_playlist = 2; + optional int64 timestamp_ms = 3; + optional int32 error_code = 4; + optional string event_description = 5; +} diff --git a/protocol/proto/PodcastAdSegmentReceived.proto b/protocol/proto/PodcastAdSegmentReceived.proto new file mode 100644 index 00000000..036fb6d5 --- /dev/null +++ b/protocol/proto/PodcastAdSegmentReceived.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PodcastAdSegmentReceived { + optional string episode_uri = 1; + optional string playback_id = 2; + optional string slots = 3; + optional bool is_audio = 4; +} diff --git a/protocol/proto/Prefetch.proto b/protocol/proto/Prefetch.proto new file mode 100644 index 00000000..c388668a --- /dev/null +++ b/protocol/proto/Prefetch.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Prefetch { + optional int64 strategies = 1; + optional int64 strategy = 2; + optional bytes file_id = 3; + optional string track = 4; + optional int64 prefetch_index = 5; + optional int64 current_window_size = 6; + optional int64 max_window_size = 7; +} diff --git a/protocol/proto/PrefetchError.proto b/protocol/proto/PrefetchError.proto new file mode 100644 index 00000000..6a1e56b4 --- /dev/null +++ b/protocol/proto/PrefetchError.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PrefetchError { + optional int64 strategy = 1; + optional string description = 2; +} diff --git a/protocol/proto/ProductStateUcsVerification.proto b/protocol/proto/ProductStateUcsVerification.proto new file mode 100644 index 00000000..95257538 --- /dev/null +++ b/protocol/proto/ProductStateUcsVerification.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ProductStateUcsVerification { + map additional_entries = 1; + map missing_entries = 2; + optional string fetch_type = 3; +} diff --git a/protocol/proto/PubSubCountPerIdent.proto b/protocol/proto/PubSubCountPerIdent.proto new file mode 100644 index 00000000..a2d1e097 --- /dev/null +++ b/protocol/proto/PubSubCountPerIdent.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message PubSubCountPerIdent { + optional string ident_filter = 1; + optional int32 no_of_messages_received = 2; + optional int32 no_of_failed_conversions = 3; +} diff --git a/protocol/proto/ReachabilityChanged.proto b/protocol/proto/ReachabilityChanged.proto new file mode 100644 index 00000000..d8e3bc10 --- /dev/null +++ b/protocol/proto/ReachabilityChanged.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ReachabilityChanged { + optional string type = 1; + optional string info = 2; +} diff --git a/protocol/proto/RejectedClientEventNonAuth.proto b/protocol/proto/RejectedClientEventNonAuth.proto new file mode 100644 index 00000000..d592809b --- /dev/null +++ b/protocol/proto/RejectedClientEventNonAuth.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message RejectedClientEventNonAuth { + optional string reject_reason = 1; + optional string event_name = 2; +} diff --git a/protocol/proto/RemainingSkips.proto b/protocol/proto/RemainingSkips.proto new file mode 100644 index 00000000..d6ceebc0 --- /dev/null +++ b/protocol/proto/RemainingSkips.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message RemainingSkips { + optional string interaction_id = 1; + optional int32 remaining_skips_before_skip = 2; + optional int32 remaining_skips_after_skip = 3; + repeated string interaction_ids = 4; +} diff --git a/protocol/proto/RequestAccounting.proto b/protocol/proto/RequestAccounting.proto new file mode 100644 index 00000000..897cffb9 --- /dev/null +++ b/protocol/proto/RequestAccounting.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message RequestAccounting { + optional string request = 1; + optional int64 downloaded = 2; + optional int64 uploaded = 3; + optional int64 num_requests = 4; + optional string connection = 5; + optional string source_identifier = 6; + optional string reason = 7; + optional int64 duration_ms = 8; +} diff --git a/protocol/proto/RequestTime.proto b/protocol/proto/RequestTime.proto new file mode 100644 index 00000000..f0b7134f --- /dev/null +++ b/protocol/proto/RequestTime.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message RequestTime { + optional string type = 1; + optional int64 first_byte = 2; + optional int64 last_byte = 3; + optional int64 size = 4; + optional int64 size_sent = 5; + optional bool error = 6; + optional string url = 7; + optional string verb = 8; + optional int64 payload_size_sent = 9; + optional int32 connection_reuse = 10; + optional double sampling_probability = 11; + optional bool cached = 12; +} diff --git a/protocol/proto/StartTrack.proto b/protocol/proto/StartTrack.proto new file mode 100644 index 00000000..5bbf5273 --- /dev/null +++ b/protocol/proto/StartTrack.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message StartTrack { + optional bytes playback_id = 1; + optional string context_player_session_id = 2; + optional int64 timestamp = 3; +} diff --git a/protocol/proto/Stutter.proto b/protocol/proto/Stutter.proto new file mode 100644 index 00000000..bd0b2980 --- /dev/null +++ b/protocol/proto/Stutter.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Stutter { + optional bytes file_id = 1; + optional bytes playback_id = 2; + optional string track = 3; + optional int64 buffer_size = 4; + optional int64 max_buffer_size = 5; + optional int64 file_byte_offset = 6; + optional int64 file_byte_total = 7; + optional int64 target_buffer = 8; + optional string audio_driver = 9; +} diff --git a/protocol/proto/TierFeatureFlags.proto b/protocol/proto/TierFeatureFlags.proto new file mode 100644 index 00000000..01f4311f --- /dev/null +++ b/protocol/proto/TierFeatureFlags.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message TierFeatureFlags { + optional bool ads = 1; + optional bool high_quality = 2; + optional bool offline = 3; + optional bool on_demand = 4; + optional string max_album_plays_consecutive = 5; + optional string max_album_plays_per_hour = 6; + optional string max_skips_per_hour = 7; + optional string max_track_plays_per_hour = 8; +} diff --git a/protocol/proto/TrackNotPlayed.proto b/protocol/proto/TrackNotPlayed.proto new file mode 100644 index 00000000..58c3ead2 --- /dev/null +++ b/protocol/proto/TrackNotPlayed.proto @@ -0,0 +1,24 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message TrackNotPlayed { + optional bytes playback_id = 1; + optional string source_start = 2; + optional string reason_start = 3; + optional string source_end = 4; + optional string reason_end = 5; + optional string play_context = 6; + optional string play_track = 7; + optional string display_track = 8; + optional string provider = 9; + optional string referer = 10; + optional string referrer_version = 11; + optional string referrer_vendor = 12; + optional string gaia_dev_id = 13; + optional string reason_not_played = 14; +} diff --git a/protocol/proto/TrackStuck.proto b/protocol/proto/TrackStuck.proto new file mode 100644 index 00000000..566d6494 --- /dev/null +++ b/protocol/proto/TrackStuck.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message TrackStuck { + optional string track = 1; + optional bytes playback_id = 2; + optional string source_start = 3; + optional string reason_start = 4; + optional bool offline = 5; + optional int64 position = 6; + optional int64 count = 7; + optional string audio_driver = 8; +} diff --git a/protocol/proto/WindowSize.proto b/protocol/proto/WindowSize.proto new file mode 100644 index 00000000..7860b1e7 --- /dev/null +++ b/protocol/proto/WindowSize.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message WindowSize { + optional int64 width = 1; + optional int64 height = 2; + optional int64 mode = 3; + optional int64 duration = 4; +} diff --git a/protocol/proto/ad-hermes-proxy.proto b/protocol/proto/ad-hermes-proxy.proto deleted file mode 100644 index 219bbcbf..00000000 --- a/protocol/proto/ad-hermes-proxy.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto2"; - -message Rule { - optional string type = 0x1; - optional uint32 times = 0x2; - optional uint64 interval = 0x3; -} - -message AdRequest { - optional string client_language = 0x1; - optional string product = 0x2; - optional uint32 version = 0x3; - optional string type = 0x4; - repeated string avoidAds = 0x5; -} - -message AdQueueResponse { - repeated AdQueueEntry adQueueEntry = 0x1; -} - -message AdFile { - optional string id = 0x1; - optional string format = 0x2; -} - -message AdQueueEntry { - optional uint64 start_time = 0x1; - optional uint64 end_time = 0x2; - optional double priority = 0x3; - optional string token = 0x4; - optional uint32 ad_version = 0x5; - optional string id = 0x6; - optional string type = 0x7; - optional string campaign = 0x8; - optional string advertiser = 0x9; - optional string url = 0xa; - optional uint64 duration = 0xb; - optional uint64 expiry = 0xc; - optional string tracking_url = 0xd; - optional string banner_type = 0xe; - optional string html = 0xf; - optional string image = 0x10; - optional string background_image = 0x11; - optional string background_url = 0x12; - optional string background_color = 0x13; - optional string title = 0x14; - optional string caption = 0x15; - repeated AdFile file = 0x16; - repeated Rule rule = 0x17; -} - diff --git a/protocol/proto/anchor_extended_metadata.proto b/protocol/proto/anchor_extended_metadata.proto new file mode 100644 index 00000000..24d715a3 --- /dev/null +++ b/protocol/proto/anchor_extended_metadata.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.anchor.extension; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option java_outer_classname = "AnchorExtensionProviderProto"; +option java_package = "com.spotify.anchorextensionprovider.proto"; + +message PodcastCounter { + uint32 counter = 1; +} diff --git a/protocol/proto/apiv1.proto b/protocol/proto/apiv1.proto new file mode 100644 index 00000000..deffc3d6 --- /dev/null +++ b/protocol/proto/apiv1.proto @@ -0,0 +1,113 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.offline.proto; + +import "google/protobuf/timestamp.proto"; +import "offline.proto"; + +option optimize_for = CODE_SIZE; + +message ListDevicesRequest { + string user_id = 1; +} + +message ListDevicesResponse { + repeated Device devices = 1; +} + +message PutDeviceRequest { + string user_id = 1; + + Body body = 2; + message Body { + Device device = 1; + } +} + +message BasicDeviceRequest { + DeviceKey key = 1; +} + +message GetDeviceResponse { + Device device = 1; +} + +message RemoveDeviceRequest { + DeviceKey key = 1; + bool is_force_remove = 2; +} + +message RemoveDeviceResponse { + bool pending = 1; + Device device = 2; +} + +message OfflineEnableDeviceResponse { + Restrictions restrictions = 1; +} + +message ListResourcesResponse { + repeated Resource resources = 1; + google.protobuf.Timestamp server_time = 2; +} + +message WriteResourcesRequest { + DeviceKey key = 1; + + Body body = 2; + message Body { + repeated ResourceOperation operations = 1; + string source_device_id = 2; + string source_cache_id = 3; + } +} + +message ResourcesUpdate { + string source_device_id = 1; + string source_cache_id = 2; +} + +message DeltaResourcesRequest { + DeviceKey key = 1; + + Body body = 2; + message Body { + google.protobuf.Timestamp last_known_server_time = 1; + } +} + +message DeltaResourcesResponse { + bool delta_update_possible = 1; + repeated ResourceOperation operations = 2; + google.protobuf.Timestamp server_time = 3; +} + +message GetResourceRequest { + DeviceKey key = 1; + string uri = 2; +} + +message GetResourceResponse { + Resource resource = 1; +} + +message WriteResourcesDetailsRequest { + DeviceKey key = 1; + + Body body = 2; + message Body { + repeated Resource resources = 1; + } +} + +message GetResourceForDevicesRequest { + string user_id = 1; + string uri = 2; +} + +message GetResourceForDevicesResponse { + repeated Device devices = 1; + repeated ResourceForDevice resources = 2; +} diff --git a/protocol/proto/appstore.proto b/protocol/proto/appstore.proto deleted file mode 100644 index bddaaf30..00000000 --- a/protocol/proto/appstore.proto +++ /dev/null @@ -1,95 +0,0 @@ -syntax = "proto2"; - -message AppInfo { - optional string identifier = 0x1; - optional int32 version_int = 0x2; -} - -message AppInfoList { - repeated AppInfo items = 0x1; -} - -message SemanticVersion { - optional int32 major = 0x1; - optional int32 minor = 0x2; - optional int32 patch = 0x3; -} - -message RequestHeader { - optional string market = 0x1; - optional Platform platform = 0x2; - enum Platform { - WIN32_X86 = 0x0; - OSX_X86 = 0x1; - LINUX_X86 = 0x2; - IPHONE_ARM = 0x3; - SYMBIANS60_ARM = 0x4; - OSX_POWERPC = 0x5; - ANDROID_ARM = 0x6; - WINCE_ARM = 0x7; - LINUX_X86_64 = 0x8; - OSX_X86_64 = 0x9; - PALM_ARM = 0xa; - LINUX_SH = 0xb; - FREEBSD_X86 = 0xc; - FREEBSD_X86_64 = 0xd; - BLACKBERRY_ARM = 0xe; - SONOS_UNKNOWN = 0xf; - LINUX_MIPS = 0x10; - LINUX_ARM = 0x11; - LOGITECH_ARM = 0x12; - LINUX_BLACKFIN = 0x13; - ONKYO_ARM = 0x15; - QNXNTO_ARM = 0x16; - BADPLATFORM = 0xff; - } - optional AppInfoList app_infos = 0x6; - optional string bridge_identifier = 0x7; - optional SemanticVersion bridge_version = 0x8; - optional DeviceClass device_class = 0x9; - enum DeviceClass { - DESKTOP = 0x1; - TABLET = 0x2; - MOBILE = 0x3; - WEB = 0x4; - TV = 0x5; - } -} - -message AppItem { - optional string identifier = 0x1; - optional Requirement requirement = 0x2; - enum Requirement { - REQUIRED_INSTALL = 0x1; - LAZYLOAD = 0x2; - OPTIONAL_INSTALL = 0x3; - } - optional string manifest = 0x4; - optional string checksum = 0x5; - optional string bundle_uri = 0x6; - optional string small_icon_uri = 0x7; - optional string large_icon_uri = 0x8; - optional string medium_icon_uri = 0x9; - optional Type bundle_type = 0xa; - enum Type { - APPLICATION = 0x0; - FRAMEWORK = 0x1; - BRIDGE = 0x2; - } - optional SemanticVersion version = 0xb; - optional uint32 ttl_in_seconds = 0xc; - optional IdentifierList categories = 0xd; -} - -message AppList { - repeated AppItem items = 0x1; -} - -message IdentifierList { - repeated string identifiers = 0x1; -} - -message BannerConfig { - optional string json = 0x1; -} - diff --git a/protocol/proto/audio_files_extension.proto b/protocol/proto/audio_files_extension.proto new file mode 100644 index 00000000..32efd995 --- /dev/null +++ b/protocol/proto/audio_files_extension.proto @@ -0,0 +1,27 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.extendedmetadata.audiofiles; + +import "metadata.proto"; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.audiophile.proto"; + +message NormalizationParams { + float loudness_db = 1; + float true_peak_db = 2; +} + +message ExtendedAudioFile { + metadata.AudioFile file = 1; + NormalizationParams file_normalization_params = 2; + NormalizationParams album_normalization_params = 3; +} + +message AudioFilesExtensionResponse { + repeated ExtendedAudioFile files = 1; + NormalizationParams default_file_normalization_params = 2; + NormalizationParams default_album_normalization_params = 3; +} diff --git a/protocol/proto/automix_mode.proto b/protocol/proto/automix_mode.proto new file mode 100644 index 00000000..a4d7d66f --- /dev/null +++ b/protocol/proto/automix_mode.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.automix.proto; + +option optimize_for = CODE_SIZE; + +message AutomixMode { + AutomixStyle style = 1; +} + +enum AutomixStyle { + NONE = 0; + DEFAULT = 1; + REGULAR = 2; + AIRBAG = 3; + RADIO_AIRBAG = 4; + SLEEP = 5; + MIXED = 6; +} diff --git a/protocol/proto/autoplay_context_request.proto b/protocol/proto/autoplay_context_request.proto new file mode 100644 index 00000000..4fa4b0bc --- /dev/null +++ b/protocol/proto/autoplay_context_request.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message AutoplayContextRequest { + required string context_uri = 1; + repeated string recent_track_uri = 2; +} diff --git a/protocol/proto/autoplay_node.proto b/protocol/proto/autoplay_node.proto new file mode 100644 index 00000000..18709f12 --- /dev/null +++ b/protocol/proto/autoplay_node.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "logging_params.proto"; + +option optimize_for = CODE_SIZE; + +message AutoplayNode { + map filler_node = 1; + required bool is_playing_filler = 2; + required LoggingParams logging_params = 3; +} diff --git a/protocol/proto/canvas.proto b/protocol/proto/canvas.proto new file mode 100644 index 00000000..e008618e --- /dev/null +++ b/protocol/proto/canvas.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.context_track_exts.canvas; + +message Artist { + string uri = 1; + string name = 2; + string avatar = 3; +} + +message CanvasRecord { + string id = 1; + string url = 2; + string file_id = 3; + Type type = 4; + string entity_uri = 5; + Artist artist = 6; + bool explicit = 7; + string uploaded_by = 8; + string etag = 9; + string canvas_uri = 11; + string storylines_id = 12; +} + +enum Type { + IMAGE = 0; + VIDEO = 1; + VIDEO_LOOPING = 2; + VIDEO_LOOPING_RANDOM = 3; + GIF = 4; +} diff --git a/protocol/proto/capping_data.proto b/protocol/proto/capping_data.proto new file mode 100644 index 00000000..dca6353a --- /dev/null +++ b/protocol/proto/capping_data.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.capper3; + +option java_multiple_files = true; +option java_package = "com.spotify.capper3.proto"; + +message ConsumeTokensRequest { + uint32 tokens = 1; +} + +message CappingData { + uint32 remaining_tokens = 1; + uint32 capacity = 2; + uint32 seconds_until_next_refill = 3; + uint32 refill_amount = 4; +} + +message ConsumeTokensResponse { + uint32 seconds_until_next_update = 1; + PlayCappingType capping_type = 2; + CappingData capping_data = 3; +} + +enum PlayCappingType { + NONE = 0; + LINEAR = 1; +} diff --git a/protocol/proto/claas.proto b/protocol/proto/claas.proto new file mode 100644 index 00000000..6006c17b --- /dev/null +++ b/protocol/proto/claas.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.claas.v1; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.claas.v1"; + +service ClaasService { + rpc PostLogs(PostLogsRequest) returns (PostLogsResponse); + rpc Watch(WatchRequest) returns (stream WatchResponse); +} + +message WatchRequest { + string user_id = 1; +} + +message WatchResponse { + repeated string logs = 1; +} + +message PostLogsRequest { + repeated string logs = 1; +} + +message PostLogsResponse { + +} diff --git a/protocol/proto/client_update.proto b/protocol/proto/client_update.proto new file mode 100644 index 00000000..fb93c9bd --- /dev/null +++ b/protocol/proto/client_update.proto @@ -0,0 +1,39 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.desktopupdate.proto; + +option java_multiple_files = true; +option java_outer_classname = "ClientUpdateProto"; +option java_package = "com.spotify.desktopupdate.proto"; + +message UpgradeSignedPart { + uint32 platform = 1; + uint64 version_from_from = 2; + uint64 version_from_to = 3; + uint64 target_version = 4; + string http_prefix = 5; + bytes binary_hash = 6; + ClientUpgradeType type = 7; + bytes file_id = 8; + uint32 delay = 9; + uint32 flags = 10; +} + +message UpgradeRequiredMessage { + bytes upgrade_signed_part = 10; + bytes signature = 20; + string http_suffix = 30; +} + +message UpdateQueryResponse { + UpgradeRequiredMessage upgrade_message_payload = 1; + uint32 poll_interval = 2; +} + +enum ClientUpgradeType { + INVALID = 0; + LOGIN_CRITICAL = 1; + NORMAL = 2; +} diff --git a/protocol/proto/clips_cover.proto b/protocol/proto/clips_cover.proto new file mode 100644 index 00000000..b129fb4a --- /dev/null +++ b/protocol/proto/clips_cover.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.clips; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "ClipsCoverProto"; +option java_package = "com.spotify.clips.proto"; + +message ClipsCover { + string image_url = 1; + string video_source_id = 2; +} diff --git a/protocol/proto/cloud_host_messages.proto b/protocol/proto/cloud_host_messages.proto new file mode 100644 index 00000000..49949188 --- /dev/null +++ b/protocol/proto/cloud_host_messages.proto @@ -0,0 +1,152 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.social_listening.cloud_host; + +option objc_class_prefix = "CloudHost"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.social_listening.cloud_host"; + +message LookupSessionRequest { + string token = 1; + JoinType join_type = 2; +} + +message LookupSessionResponse { + oneof response { + Session session = 1; + ErrorCode error = 2; + } +} + +message CreateSessionRequest { + +} + +message CreateSessionResponse { + oneof response { + Session session = 1; + ErrorCode error = 2; + } +} + +message DeleteSessionRequest { + string session_id = 1; +} + +message DeleteSessionResponse { + oneof response { + Session session = 1; + ErrorCode error = 2; + } +} + +message JoinSessionRequest { + string join_token = 1; + Experience experience = 3; +} + +message JoinSessionResponse { + oneof response { + Session session = 1; + ErrorCode error = 2; + } +} + +message LeaveSessionRequest { + string session_id = 1; +} + +message LeaveSessionResponse { + oneof response { + Session session = 1; + ErrorCode error = 2; + } +} + +message GetCurrentSessionRequest { + +} + +message GetCurrentSessionResponse { + oneof response { + Session session = 1; + ErrorCode error = 2; + } +} + +message SessionUpdateRequest { + +} + +message SessionUpdate { + Session session = 1; + SessionUpdateReason reason = 3; + repeated SessionMember updated_session_members = 4; +} + +message SessionUpdateResponse { + oneof response { + SessionUpdate session_update = 1; + ErrorCode error = 2; + } +} + +message Session { + int64 timestamp = 1; + string session_id = 2; + string join_session_token = 3; + string join_session_url = 4; + string session_owner_id = 5; + repeated SessionMember session_members = 6; + string join_session_uri = 7; + bool is_session_owner = 8; +} + +message SessionMember { + int64 timestamp = 1; + string member_id = 2; + string username = 3; + string display_name = 4; + string image_url = 5; + string large_image_url = 6; + bool current_user = 7; +} + +enum JoinType { + NotSpecified = 0; + Scanning = 1; + DeepLinking = 2; + DiscoveredDevice = 3; + Frictionless = 4; + NearbyWifi = 5; +} + +enum ErrorCode { + Unknown = 0; + ParseError = 1; + JoinFailed = 1000; + SessionFull = 1001; + FreeUser = 1002; + ScannableError = 1003; + JoinExpiredSession = 1004; + NoExistingSession = 1005; +} + +enum Experience { + UNKNOWN = 0; + BEETHOVEN = 1; + BACH = 2; +} + +enum SessionUpdateReason { + UNKNOWN_UPDATE_REASON = 0; + NEW_SESSION = 1; + USER_JOINED = 2; + USER_LEFT = 3; + SESSION_DELETED = 4; + YOU_LEFT = 5; + YOU_WERE_KICKED = 6; + YOU_JOINED = 7; +} diff --git a/protocol/proto/collection/album_collection_state.proto b/protocol/proto/collection/album_collection_state.proto new file mode 100644 index 00000000..1258961d --- /dev/null +++ b/protocol/proto/collection/album_collection_state.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message AlbumCollectionState { + optional string collection_link = 1; + optional uint32 num_tracks_in_collection = 2; + optional bool complete = 3; +} diff --git a/protocol/proto/collection/artist_collection_state.proto b/protocol/proto/collection/artist_collection_state.proto new file mode 100644 index 00000000..33ade56a --- /dev/null +++ b/protocol/proto/collection/artist_collection_state.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ArtistCollectionState { + optional string collection_link = 1; + optional bool followed = 2; + optional uint32 num_tracks_in_collection = 3; + optional uint32 num_albums_in_collection = 4; + optional bool is_banned = 5; + optional bool can_ban = 6; +} diff --git a/protocol/proto/collection/episode_collection_state.proto b/protocol/proto/collection/episode_collection_state.proto new file mode 100644 index 00000000..403bfbb4 --- /dev/null +++ b/protocol/proto/collection/episode_collection_state.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message EpisodeCollectionState { + optional bool is_following_show = 1; + optional bool is_new = 2; + optional bool is_in_listen_later = 3; +} diff --git a/protocol/proto/collection/show_collection_state.proto b/protocol/proto/collection/show_collection_state.proto new file mode 100644 index 00000000..d3904b51 --- /dev/null +++ b/protocol/proto/collection/show_collection_state.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ShowCollectionState { + optional bool is_in_collection = 1; +} diff --git a/protocol/proto/collection/track_collection_state.proto b/protocol/proto/collection/track_collection_state.proto new file mode 100644 index 00000000..68e42ed2 --- /dev/null +++ b/protocol/proto/collection/track_collection_state.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message TrackCollectionState { + optional bool is_in_collection = 1; + optional bool can_add_to_collection = 2; + optional bool is_banned = 3; + optional bool can_ban = 4; +} diff --git a/protocol/proto/collection2v2.proto b/protocol/proto/collection2v2.proto new file mode 100644 index 00000000..19530fe8 --- /dev/null +++ b/protocol/proto/collection2v2.proto @@ -0,0 +1,62 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.collection.proto.v2; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.collection2.v2.proto"; + +message PageRequest { + string username = 1; + string set = 2; + string pagination_token = 3; + int32 limit = 4; +} + +message CollectionItem { + string uri = 1; + int32 added_at = 2; + bool is_removed = 3; +} + +message PageResponse { + repeated CollectionItem items = 1; + string next_page_token = 2; + string sync_token = 3; +} + +message DeltaRequest { + string username = 1; + string set = 2; + string last_sync_token = 3; +} + +message DeltaResponse { + bool delta_update_possible = 1; + repeated CollectionItem items = 2; + string sync_token = 3; +} + +message WriteRequest { + string username = 1; + string set = 2; + repeated CollectionItem items = 3; + string client_update_id = 4; +} + +message PubSubUpdate { + string username = 1; + string set = 2; + repeated CollectionItem items = 3; + string client_update_id = 4; +} + +message InitializedRequest { + string username = 1; + string set = 2; +} + +message InitializedResponse { + bool initialized = 1; +} diff --git a/protocol/proto/collection_index.proto b/protocol/proto/collection_index.proto new file mode 100644 index 00000000..5af95a35 --- /dev/null +++ b/protocol/proto/collection_index.proto @@ -0,0 +1,40 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.collection.proto; + +option optimize_for = CODE_SIZE; + +message IndexRepairerState { + bytes last_checked_uri = 1; + int64 last_full_check_finished_at = 2; +} + +message CollectionTrackEntry { + string track_uri = 1; + string track_name = 2; + string album_uri = 3; + string album_name = 4; + int32 disc_number = 5; + int32 track_number = 6; + string artist_uri = 7; + repeated string artist_name = 8; + int64 add_time = 9; +} + +message CollectionAlbumEntry { + string album_uri = 1; + string album_name = 2; + string album_image_uri = 3; + string artist_uri = 4; + string artist_name = 5; + int64 add_time = 6; +} + +message CollectionMetadataMigratorState { + bytes last_checked_key = 1; + bool migrated_tracks = 2; + bool migrated_albums = 3; + bool migrated_album_tracks = 4; +} diff --git a/protocol/proto/collection_platform_requests.proto b/protocol/proto/collection_platform_requests.proto new file mode 100644 index 00000000..efe9a847 --- /dev/null +++ b/protocol/proto/collection_platform_requests.proto @@ -0,0 +1,24 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.collection_platform.proto; + +option optimize_for = CODE_SIZE; + +message CollectionPlatformSimpleRequest { + CollectionSet set = 1; +} + +message CollectionPlatformItemsRequest { + CollectionSet set = 1; + repeated string items = 2; +} + +enum CollectionSet { + UNKNOWN = 0; + SHOW = 1; + BAN = 2; + LISTENLATER = 3; + IGNOREINRECS = 4; +} diff --git a/protocol/proto/collection_platform_responses.proto b/protocol/proto/collection_platform_responses.proto new file mode 100644 index 00000000..fd236c12 --- /dev/null +++ b/protocol/proto/collection_platform_responses.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.collection_platform.proto; + +option optimize_for = CODE_SIZE; + +message CollectionPlatformSimpleResponse { + string error_msg = 1; +} + +message CollectionPlatformItemsResponse { + repeated string items = 1; +} + +message CollectionPlatformContainsResponse { + repeated bool found = 1; +} diff --git a/protocol/proto/collection_storage.proto b/protocol/proto/collection_storage.proto new file mode 100644 index 00000000..1dd4f034 --- /dev/null +++ b/protocol/proto/collection_storage.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto2"; + +package spotify.collection.proto.storage; + +import "collection2.proto"; + +option optimize_for = CODE_SIZE; + +message CollectionHeader { + optional bytes etag = 1; +} + +message CollectionCache { + optional CollectionHeader header = 1; + optional CollectionItems collection = 2; + optional CollectionItems pending = 3; + optional uint32 collection_item_limit = 4; +} diff --git a/protocol/proto/composite_formats_node.proto b/protocol/proto/composite_formats_node.proto new file mode 100644 index 00000000..75717c98 --- /dev/null +++ b/protocol/proto/composite_formats_node.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "track_instance.proto"; +import "track_instantiator.proto"; + +option optimize_for = CODE_SIZE; + +message InjectionSegment { + required string track_uri = 1; + optional int64 start = 2; + optional int64 stop = 3; + required int64 duration = 4; +} + +message InjectionModel { + required string episode_uri = 1; + required int64 total_duration = 2; + repeated InjectionSegment segments = 3; +} + +message CompositeFormatsPrototypeNode { + required string mode = 1; + optional InjectionModel injection_model = 2; + required uint32 index = 3; + required TrackInstantiator instantiator = 4; + optional TrackInstance track = 5; +} diff --git a/protocol/proto/concat_cosmos.proto b/protocol/proto/concat_cosmos.proto new file mode 100644 index 00000000..7fe045a8 --- /dev/null +++ b/protocol/proto/concat_cosmos.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.concat_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message ConcatRequest { + string a = 1; + string b = 2; +} + +message ConcatWithSeparatorRequest { + string a = 1; + string b = 2; + string separator = 3; +} + +message ConcatResponse { + string concatenated = 1; +} diff --git a/protocol/proto/connect.proto b/protocol/proto/connect.proto new file mode 100644 index 00000000..310a5b55 --- /dev/null +++ b/protocol/proto/connect.proto @@ -0,0 +1,235 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.connectstate; + +import "player.proto"; +import "devices.proto"; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.connectstate.model"; + +message ClusterUpdate { + Cluster cluster = 1; + ClusterUpdateReason update_reason = 2; + string ack_id = 3; + repeated string devices_that_changed = 4; +} + +message PostCommandResponse { + string ack_id = 1; +} + +message Device { + DeviceInfo device_info = 1; + PlayerState player_state = 2; + PrivateDeviceInfo private_device_info = 3; + bytes transfer_data = 4; +} + +message Cluster { + int64 changed_timestamp_ms = 1; + string active_device_id = 2; + PlayerState player_state = 3; + map device = 4; + bytes transfer_data = 5; + uint64 transfer_data_timestamp = 6; + int64 not_playing_since_timestamp = 7; + bool need_full_player_state = 8; + int64 server_timestamp_ms = 9; +} + +message PutStateRequest { + string callback_url = 1; + Device device = 2; + MemberType member_type = 3; + bool is_active = 4; + PutStateReason put_state_reason = 5; + uint32 message_id = 6; + string last_command_sent_by_device_id = 7; + uint32 last_command_message_id = 8; + uint64 started_playing_at = 9; + uint64 has_been_playing_for_ms = 11; + uint64 client_side_timestamp = 12; + bool only_write_player_state = 13; +} + +message PrivateDeviceInfo { + string platform = 1; +} + +message SubscribeRequest { + string callback_url = 1; +} + +message DeviceInfo { + bool can_play = 1; + uint32 volume = 2; + string name = 3; + Capabilities capabilities = 4; + repeated DeviceMetadata metadata = 5; + string device_software_version = 6; + devices.DeviceType device_type = 7; + string spirc_version = 9; + string device_id = 10; + bool is_private_session = 11; + bool is_social_connect = 12; + string client_id = 13; + string brand = 14; + string model = 15; + map metadata_map = 16; + string product_id = 17; + string deduplication_id = 18; + uint32 selected_alias_id = 19; + map device_aliases = 20; + bool is_offline = 21; + string public_ip = 22; + string license = 23; + bool is_group = 25; + + oneof _audio_output_device_info { + AudioOutputDeviceInfo audio_output_device_info = 24; + } +} + +message AudioOutputDeviceInfo { + oneof _audio_output_device_type { + AudioOutputDeviceType audio_output_device_type = 1; + } + + oneof _device_name { + string device_name = 2; + } +} + +message DeviceMetadata { + option deprecated = true; + string type = 1; + string metadata = 2; +} + +message Capabilities { + bool can_be_player = 2; + bool restrict_to_local = 3; + bool gaia_eq_connect_id = 5; + bool supports_logout = 6; + bool is_observable = 7; + int32 volume_steps = 8; + repeated string supported_types = 9; + bool command_acks = 10; + bool supports_rename = 11; + bool hidden = 12; + bool disable_volume = 13; + bool connect_disabled = 14; + bool supports_playlist_v2 = 15; + bool is_controllable = 16; + bool supports_external_episodes = 17; + bool supports_set_backend_metadata = 18; + bool supports_transfer_command = 19; + bool supports_command_request = 20; + bool is_voice_enabled = 21; + bool needs_full_player_state = 22; + bool supports_gzip_pushes = 23; + bool supports_set_options_command = 25; + CapabilitySupportDetails supports_hifi = 26; + + reserved 1, 4, 24, "supported_contexts", "supports_lossless_audio"; +} + +message CapabilitySupportDetails { + bool fully_supported = 1; + bool user_eligible = 2; + bool device_supported = 3; +} + +message ConnectCommandOptions { + int32 message_id = 1; + uint32 target_alias_id = 3; +} + +message LogoutCommand { + ConnectCommandOptions command_options = 1; +} + +message SetVolumeCommand { + int32 volume = 1; + ConnectCommandOptions command_options = 2; +} + +message RenameCommand { + string rename_to = 1; + ConnectCommandOptions command_options = 2; +} + +message ConnectPlayerCommand { + string player_command_json = 1; + ConnectCommandOptions command_options = 2; +} + +message SetBackendMetadataCommand { + map metadata = 1; +} + +message CommandAndSourceDevice { + string command = 1; + DeviceInfo source_device_info = 2; +} + +message ActiveDeviceUpdate { + string device_id = 1; +} + +message StartedPlayingEvent { + bytes user_info_header = 1; + string device_id = 2; +} + +enum AudioOutputDeviceType { + UNKNOWN_AUDIO_OUTPUT_DEVICE_TYPE = 0; + BUILT_IN_SPEAKER = 1; + LINE_OUT = 2; + BLUETOOTH = 3; + AIRPLAY = 4; +} + +enum PutStateReason { + UNKNOWN_PUT_STATE_REASON = 0; + SPIRC_HELLO = 1; + SPIRC_NOTIFY = 2; + NEW_DEVICE = 3; + PLAYER_STATE_CHANGED = 4; + VOLUME_CHANGED = 5; + PICKER_OPENED = 6; + BECAME_INACTIVE = 7; + ALIAS_CHANGED = 8; +} + +enum MemberType { + SPIRC_V2 = 0; + SPIRC_V3 = 1; + CONNECT_STATE = 2; + CONNECT_STATE_EXTENDED = 5; + ACTIVE_DEVICE_TRACKER = 6; + PLAY_TOKEN = 7; +} + +enum ClusterUpdateReason { + UNKNOWN_CLUSTER_UPDATE_REASON = 0; + DEVICES_DISAPPEARED = 1; + DEVICE_STATE_CHANGED = 2; + NEW_DEVICE_APPEARED = 3; + DEVICE_VOLUME_CHANGED = 4; + DEVICE_ALIAS_CHANGED = 5; +} + +enum SendCommandResult { + UNKNOWN_SEND_COMMAND_RESULT = 0; + SUCCESS = 1; + DEVICE_NOT_FOUND = 2; + CONTEXT_PLAYER_ERROR = 3; + DEVICE_DISAPPEARED = 4; + UPSTREAM_ERROR = 5; + DEVICE_DOES_NOT_SUPPORT_COMMAND = 6; + RATE_LIMITED = 7; +} diff --git a/protocol/proto/connectivity.proto b/protocol/proto/connectivity.proto new file mode 100644 index 00000000..f7e64a3c --- /dev/null +++ b/protocol/proto/connectivity.proto @@ -0,0 +1,43 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.clienttoken.data.v0; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.clienttoken.data.v0"; + +message ConnectivitySdkData { + PlatformSpecificData platform_specific_data = 1; + string device_id = 2; +} + +message PlatformSpecificData { + oneof data { + NativeAndroidData android = 1; + NativeIOSData ios = 2; + } +} + +message NativeAndroidData { + int32 major_sdk_version = 1; + int32 minor_sdk_version = 2; + int32 patch_sdk_version = 3; + uint32 api_version = 4; + Screen screen_dimensions = 5; +} + +message NativeIOSData { + int32 user_interface_idiom = 1; + bool target_iphone_simulator = 2; + string hw_machine = 3; + string system_version = 4; + string simulator_model_identifier = 5; +} + +message Screen { + int32 width = 1; + int32 height = 2; + int32 density = 3; +} diff --git a/protocol/proto/contains_request.proto b/protocol/proto/contains_request.proto new file mode 100644 index 00000000..cf59c5f5 --- /dev/null +++ b/protocol/proto/contains_request.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message ContainsRequest { + repeated string items = 1; +} + +message ContainsResponse { + repeated bool found = 1; +} diff --git a/protocol/proto/content_access_token_cosmos.proto b/protocol/proto/content_access_token_cosmos.proto new file mode 100644 index 00000000..2c98125b --- /dev/null +++ b/protocol/proto/content_access_token_cosmos.proto @@ -0,0 +1,36 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.contentaccesstoken.proto; + +import "google/protobuf/timestamp.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.contentaccesstoken.proto"; + +message ContentAccessTokenResponse { + Error error = 1; + ContentAccessToken content_access_token = 2; +} + +message ContentAccessToken { + string token = 1; + google.protobuf.Timestamp expires_at = 2; + google.protobuf.Timestamp refresh_at = 3; + repeated string domains = 4; +} + +message ContentAccessRefreshToken { + string token = 1; +} + +message IsEnabledResponse { + bool is_enabled = 1; +} + +message Error { + int32 error_code = 1; + string error_description = 2; +} diff --git a/protocol/proto/context.proto b/protocol/proto/context.proto new file mode 100644 index 00000000..eb022415 --- /dev/null +++ b/protocol/proto/context.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_page.proto"; +import "restrictions.proto"; + +option optimize_for = CODE_SIZE; + +message Context { + optional string uri = 1; + optional string url = 2; + map metadata = 3; + optional Restrictions restrictions = 4; + repeated ContextPage pages = 5; + optional bool loading = 6; +} diff --git a/protocol/proto/context_client_id.proto b/protocol/proto/context_client_id.proto new file mode 100644 index 00000000..bab3b6b8 --- /dev/null +++ b/protocol/proto/context_client_id.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message ClientId { + bytes value = 1; +} diff --git a/protocol/proto/context_core.proto b/protocol/proto/context_core.proto new file mode 100644 index 00000000..1e49afaf --- /dev/null +++ b/protocol/proto/context_core.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Core { + string os_name = 1; + string os_version = 2; + string device_id = 3; + string client_version = 4; +} diff --git a/protocol/proto/context_index.proto b/protocol/proto/context_index.proto new file mode 100644 index 00000000..c7049eac --- /dev/null +++ b/protocol/proto/context_index.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message ContextIndex { + optional uint32 page = 1; + optional uint32 track = 2; +} diff --git a/protocol/proto/context_installation_id.proto b/protocol/proto/context_installation_id.proto new file mode 100644 index 00000000..08fe2580 --- /dev/null +++ b/protocol/proto/context_installation_id.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message InstallationId { + bytes value = 1; +} diff --git a/protocol/proto/context_monotonic_clock.proto b/protocol/proto/context_monotonic_clock.proto new file mode 100644 index 00000000..3ec525ff --- /dev/null +++ b/protocol/proto/context_monotonic_clock.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message MonotonicClock { + int64 id = 1; + int64 value = 2; +} diff --git a/protocol/proto/context_node.proto b/protocol/proto/context_node.proto new file mode 100644 index 00000000..8ff3cb28 --- /dev/null +++ b/protocol/proto/context_node.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_processor.proto"; +import "play_origin.proto"; +import "prepare_play_options.proto"; +import "track_instance.proto"; +import "track_instantiator.proto"; + +option optimize_for = CODE_SIZE; + +message ContextNode { + optional TrackInstance current_track = 2; + optional TrackInstantiator instantiate = 3; + optional PreparePlayOptions prepare_options = 4; + optional PlayOrigin play_origin = 5; + optional ContextProcessor context_processor = 6; + optional string session_id = 7; + optional sint32 iteration = 8; +} diff --git a/protocol/proto/context_page.proto b/protocol/proto/context_page.proto new file mode 100644 index 00000000..b6e8ecdc --- /dev/null +++ b/protocol/proto/context_page.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_track.proto"; + +option optimize_for = CODE_SIZE; + +message ContextPage { + optional string page_url = 1; + optional string next_page_url = 2; + map metadata = 3; + repeated ContextTrack tracks = 4; + optional bool loading = 5; +} diff --git a/protocol/proto/context_player_ng.proto b/protocol/proto/context_player_ng.proto new file mode 100644 index 00000000..e61f011e --- /dev/null +++ b/protocol/proto/context_player_ng.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message ContextPlayerNg { + map player_model = 1; + optional uint64 playback_position = 2; +} diff --git a/protocol/proto/context_player_options.proto b/protocol/proto/context_player_options.proto new file mode 100644 index 00000000..57e069b5 --- /dev/null +++ b/protocol/proto/context_player_options.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message ContextPlayerOptions { + optional bool shuffling_context = 1; + optional bool repeating_context = 2; + optional bool repeating_track = 3; +} + +message ContextPlayerOptionOverrides { + optional bool shuffling_context = 1; + optional bool repeating_context = 2; + optional bool repeating_track = 3; +} diff --git a/protocol/proto/context_processor.proto b/protocol/proto/context_processor.proto new file mode 100644 index 00000000..2d931b0b --- /dev/null +++ b/protocol/proto/context_processor.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context.proto"; +import "context_view.proto"; +import "skip_to_track.proto"; + +option optimize_for = CODE_SIZE; + +message ContextProcessor { + optional Context context = 1; + optional context_view.proto.ContextView context_view = 2; + optional SkipToTrack pending_skip_to = 3; + optional string shuffle_seed = 4; + optional int32 index = 5; +} diff --git a/protocol/proto/context_sdk.proto b/protocol/proto/context_sdk.proto new file mode 100644 index 00000000..dc5d3236 --- /dev/null +++ b/protocol/proto/context_sdk.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Sdk { + string version_name = 1; +} diff --git a/protocol/proto/context_time.proto b/protocol/proto/context_time.proto new file mode 100644 index 00000000..93749b41 --- /dev/null +++ b/protocol/proto/context_time.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message Time { + int64 value = 1; +} diff --git a/protocol/proto/context_track.proto b/protocol/proto/context_track.proto new file mode 100644 index 00000000..e9d06f21 --- /dev/null +++ b/protocol/proto/context_track.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message ContextTrack { + optional string uri = 1; + optional string uid = 2; + optional bytes gid = 3; + map metadata = 4; +} diff --git a/protocol/proto/context_view.proto b/protocol/proto/context_view.proto new file mode 100644 index 00000000..0b78991a --- /dev/null +++ b/protocol/proto/context_view.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.context_view.proto; + +import "context_track.proto"; +import "context_view_cyclic_list.proto"; + +option optimize_for = CODE_SIZE; + +message ContextView { + map patch_map = 1; + optional uint32 iteration_size = 2; + optional cyclic_list.proto.CyclicEntryKeyList cyclic_list = 3; + + reserved 4; +} diff --git a/protocol/proto/context_view_cyclic_list.proto b/protocol/proto/context_view_cyclic_list.proto new file mode 100644 index 00000000..76cde3ed --- /dev/null +++ b/protocol/proto/context_view_cyclic_list.proto @@ -0,0 +1,26 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.context_view.cyclic_list.proto; + +import "context_view_entry_key.proto"; + +option optimize_for = CODE_SIZE; + +message Instance { + optional context_view.proto.EntryKey item = 1; + optional int32 iteration = 2; +} + +message Patch { + optional int32 start = 1; + optional int32 end = 2; + repeated Instance instances = 3; +} + +message CyclicEntryKeyList { + optional context_view.proto.EntryKey delimiter = 1; + repeated context_view.proto.EntryKey items = 2; + optional Patch patch = 3; +} diff --git a/protocol/proto/context_view_entry.proto b/protocol/proto/context_view_entry.proto new file mode 100644 index 00000000..8451f481 --- /dev/null +++ b/protocol/proto/context_view_entry.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.context_view.proto; + +import "context_index.proto"; +import "context_track.proto"; + +option optimize_for = CODE_SIZE; + +message Entry { + optional Type type = 1; + enum Type { + TRACK = 0; + DELIMITER = 1; + PAGE_PLACEHOLDER = 2; + CONTEXT_PLACEHOLDER = 3; + } + + optional player.proto.ContextTrack track = 2; + optional player.proto.ContextIndex index = 3; + optional int32 page_index = 4; + optional int32 absolute_index = 5; +} diff --git a/protocol/proto/context_view_entry_key.proto b/protocol/proto/context_view_entry_key.proto new file mode 100644 index 00000000..6c8a019f --- /dev/null +++ b/protocol/proto/context_view_entry_key.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.context_view.proto; + +import "context_view_entry.proto"; + +option optimize_for = CODE_SIZE; + +message EntryKey { + optional Entry.Type type = 1; + optional string data = 2; +} diff --git a/protocol/proto/core_configuration_applied_non_auth.proto b/protocol/proto/core_configuration_applied_non_auth.proto new file mode 100644 index 00000000..d7c132dc --- /dev/null +++ b/protocol/proto/core_configuration_applied_non_auth.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.proto; + +option optimize_for = CODE_SIZE; + +message CoreConfigurationAppliedNonAuth { + string configuration_assignment_id = 1; +} diff --git a/protocol/proto/cosmos_changes_request.proto b/protocol/proto/cosmos_changes_request.proto new file mode 100644 index 00000000..47cd584f --- /dev/null +++ b/protocol/proto/cosmos_changes_request.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.changes_request.proto; + +option optimize_for = CODE_SIZE; + +message Response { + +} diff --git a/protocol/proto/cosmos_decorate_request.proto b/protocol/proto/cosmos_decorate_request.proto new file mode 100644 index 00000000..2709b30a --- /dev/null +++ b/protocol/proto/cosmos_decorate_request.proto @@ -0,0 +1,70 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.decorate_request.proto; + +import "collection/album_collection_state.proto"; +import "collection/artist_collection_state.proto"; +import "collection/episode_collection_state.proto"; +import "collection/show_collection_state.proto"; +import "collection/track_collection_state.proto"; +import "played_state/episode_played_state.proto"; +import "played_state/show_played_state.proto"; +import "played_state/track_played_state.proto"; +import "sync/album_sync_state.proto"; +import "sync/artist_sync_state.proto"; +import "sync/episode_sync_state.proto"; +import "sync/track_sync_state.proto"; +import "metadata/album_metadata.proto"; +import "metadata/artist_metadata.proto"; +import "metadata/episode_metadata.proto"; +import "metadata/show_metadata.proto"; +import "metadata/track_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Album { + optional cosmos_util.proto.AlbumMetadata album_metadata = 1; + optional cosmos_util.proto.AlbumCollectionState album_collection_state = 2; + optional cosmos_util.proto.AlbumSyncState album_offline_state = 3; + optional string link = 4; +} + +message Artist { + optional cosmos_util.proto.ArtistMetadata artist_metadata = 1; + optional cosmos_util.proto.ArtistCollectionState artist_collection_state = 2; + optional cosmos_util.proto.ArtistSyncState artist_offline_state = 3; + optional string link = 4; +} + +message Episode { + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 1; + optional cosmos_util.proto.EpisodeCollectionState episode_collection_state = 2; + optional cosmos_util.proto.EpisodeSyncState episode_offline_state = 3; + optional cosmos_util.proto.EpisodePlayState episode_play_state = 4; + optional string link = 5; +} + +message Show { + optional cosmos_util.proto.ShowMetadata show_metadata = 1; + optional cosmos_util.proto.ShowCollectionState show_collection_state = 2; + optional cosmos_util.proto.ShowPlayState show_play_state = 3; + optional string link = 4; +} + +message Track { + optional cosmos_util.proto.TrackMetadata track_metadata = 1; + optional cosmos_util.proto.TrackSyncState track_offline_state = 2; + optional cosmos_util.proto.TrackPlayState track_play_state = 3; + optional cosmos_util.proto.TrackCollectionState track_collection_state = 4; + optional string link = 5; +} + +message Response { + repeated Show show = 1; + repeated Episode episode = 2; + repeated Album album = 3; + repeated Artist artist = 4; + repeated Track track = 5; +} diff --git a/protocol/proto/cosmos_get_album_list_request.proto b/protocol/proto/cosmos_get_album_list_request.proto new file mode 100644 index 00000000..741e9f49 --- /dev/null +++ b/protocol/proto/cosmos_get_album_list_request.proto @@ -0,0 +1,37 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.album_list_request.proto; + +import "collection/album_collection_state.proto"; +import "sync/album_sync_state.proto"; +import "metadata/album_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header_field = 1; + optional uint32 index = 2; + optional uint32 add_time = 3; + optional cosmos_util.proto.AlbumMetadata album_metadata = 4; + optional cosmos_util.proto.AlbumCollectionState album_collection_state = 5; + optional cosmos_util.proto.AlbumSyncState album_offline_state = 6; + optional string group_label = 7; +} + +message GroupHeader { + optional string header_field = 1; + optional uint32 index = 2; + optional uint32 length = 3; +} + +message Response { + repeated Item item = 1; + optional uint32 unfiltered_length = 2; + optional uint32 unranged_length = 3; + optional bool loading_contents = 4; + optional string offline = 5; + optional uint32 sync_progress = 6; + repeated GroupHeader group_index = 7; +} diff --git a/protocol/proto/cosmos_get_artist_list_request.proto b/protocol/proto/cosmos_get_artist_list_request.proto new file mode 100644 index 00000000..b8ccb662 --- /dev/null +++ b/protocol/proto/cosmos_get_artist_list_request.proto @@ -0,0 +1,37 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.artist_list_request.proto; + +import "collection/artist_collection_state.proto"; +import "sync/artist_sync_state.proto"; +import "metadata/artist_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header_field = 1; + optional uint32 index = 2; + optional uint32 add_time = 3; + optional cosmos_util.proto.ArtistMetadata artist_metadata = 4; + optional cosmos_util.proto.ArtistCollectionState artist_collection_state = 5; + optional cosmos_util.proto.ArtistSyncState artist_offline_state = 6; + optional string group_label = 7; +} + +message GroupHeader { + optional string header_field = 1; + optional uint32 index = 2; + optional uint32 length = 3; +} + +message Response { + repeated Item item = 1; + optional uint32 unfiltered_length = 2; + optional uint32 unranged_length = 3; + optional bool loading_contents = 4; + optional string offline = 5; + optional uint32 sync_progress = 6; + repeated GroupHeader group_index = 7; +} diff --git a/protocol/proto/cosmos_get_episode_list_request.proto b/protocol/proto/cosmos_get_episode_list_request.proto new file mode 100644 index 00000000..8168fbfe --- /dev/null +++ b/protocol/proto/cosmos_get_episode_list_request.proto @@ -0,0 +1,27 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.episode_list_request.proto; + +import "collection/episode_collection_state.proto"; +import "played_state/episode_played_state.proto"; +import "sync/episode_sync_state.proto"; +import "metadata/episode_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header = 1; + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 2; + optional cosmos_util.proto.EpisodeCollectionState episode_collection_state = 3; + optional cosmos_util.proto.EpisodeSyncState episode_offline_state = 4; + optional cosmos_util.proto.EpisodePlayState episode_play_state = 5; +} + +message Response { + repeated Item item = 1; + optional uint32 unfiltered_length = 2; + optional uint32 unranged_length = 3; + optional bool loading_contents = 4; +} diff --git a/protocol/proto/cosmos_get_show_list_request.proto b/protocol/proto/cosmos_get_show_list_request.proto new file mode 100644 index 00000000..880f7cea --- /dev/null +++ b/protocol/proto/cosmos_get_show_list_request.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.show_list_request.proto; + +import "collection/show_collection_state.proto"; +import "played_state/show_played_state.proto"; +import "metadata/show_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header_field = 1; + optional cosmos_util.proto.ShowMetadata show_metadata = 2; + optional cosmos_util.proto.ShowCollectionState show_collection_state = 3; + optional cosmos_util.proto.ShowPlayState show_play_state = 4; + optional uint32 headerless_index = 5; + optional uint32 add_time = 6; + optional bool has_new_episodes = 7; + optional uint64 latest_published_episode_date = 8; +} + +message Response { + repeated Item item = 1; + optional uint32 num_offlined_episodes = 2; + optional uint32 unfiltered_length = 3; + optional uint32 unranged_length = 4; + optional bool loading_contents = 5; +} diff --git a/protocol/proto/cosmos_get_tags_info_request.proto b/protocol/proto/cosmos_get_tags_info_request.proto new file mode 100644 index 00000000..fe666025 --- /dev/null +++ b/protocol/proto/cosmos_get_tags_info_request.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.collection_cosmos.tags_info_request.proto; + +option optimize_for = CODE_SIZE; + +message Response { + bool is_synced = 1; +} diff --git a/protocol/proto/cosmos_get_track_list_metadata_request.proto b/protocol/proto/cosmos_get_track_list_metadata_request.proto new file mode 100644 index 00000000..8a02c962 --- /dev/null +++ b/protocol/proto/cosmos_get_track_list_metadata_request.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message TrackListMetadata { + optional uint32 unfiltered_length = 1; + optional uint32 length = 2; + optional string offline = 3; + optional uint32 sync_progress = 4; +} diff --git a/protocol/proto/cosmos_get_track_list_request.proto b/protocol/proto/cosmos_get_track_list_request.proto new file mode 100644 index 00000000..c92320f7 --- /dev/null +++ b/protocol/proto/cosmos_get_track_list_request.proto @@ -0,0 +1,39 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.track_list_request.proto; + +import "collection/track_collection_state.proto"; +import "played_state/track_played_state.proto"; +import "sync/track_sync_state.proto"; +import "metadata/track_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header_field = 1; + optional uint32 index = 2; + optional uint32 add_time = 3; + optional cosmos_util.proto.TrackMetadata track_metadata = 4; + optional cosmos_util.proto.TrackSyncState track_offline_state = 5; + optional cosmos_util.proto.TrackPlayState track_play_state = 6; + optional cosmos_util.proto.TrackCollectionState track_collection_state = 7; + optional string group_label = 8; +} + +message GroupHeader { + optional string header_field = 1; + optional uint32 index = 2; + optional uint32 length = 3; +} + +message Response { + repeated Item item = 1; + optional uint32 unfiltered_length = 2; + optional uint32 unranged_length = 3; + optional bool loading_contents = 4; + optional string offline = 5; + optional uint32 sync_progress = 6; + repeated GroupHeader group_index = 7; +} diff --git a/protocol/proto/cosmos_get_unplayed_episodes_request.proto b/protocol/proto/cosmos_get_unplayed_episodes_request.proto new file mode 100644 index 00000000..8957ae56 --- /dev/null +++ b/protocol/proto/cosmos_get_unplayed_episodes_request.proto @@ -0,0 +1,27 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection_cosmos.unplayed_request.proto; + +import "collection/episode_collection_state.proto"; +import "played_state/episode_played_state.proto"; +import "sync/episode_sync_state.proto"; +import "metadata/episode_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header = 1; + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 2; + optional cosmos_util.proto.EpisodeCollectionState episode_collection_state = 3; + optional cosmos_util.proto.EpisodeSyncState episode_offline_state = 4; + optional cosmos_util.proto.EpisodePlayState episode_play_state = 5; +} + +message Response { + repeated Item item = 1; + optional uint32 unfiltered_length = 2; + optional uint32 unranged_length = 3; + optional bool loading_contents = 4; +} diff --git a/protocol/proto/cuepoints.proto b/protocol/proto/cuepoints.proto new file mode 100644 index 00000000..16bfd6a9 --- /dev/null +++ b/protocol/proto/cuepoints.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.automix.proto; + +option optimize_for = CODE_SIZE; + +message Cuepoint { + int64 position_ms = 1; + float tempo_bpm = 2; + Origin origin = 3; +} + +message Cuepoints { + Cuepoint fade_in_cuepoint = 1; + Cuepoint fade_out_cuepoint = 2; +} + +enum Origin { + HUMAN = 0; + ML = 1; +} diff --git a/protocol/proto/decorate_request.proto b/protocol/proto/decorate_request.proto new file mode 100644 index 00000000..cad3f526 --- /dev/null +++ b/protocol/proto/decorate_request.proto @@ -0,0 +1,48 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.show_cosmos.decorate_request.proto; + +import "metadata/episode_metadata.proto"; +import "metadata/show_metadata.proto"; +import "show_access.proto"; +import "show_episode_state.proto"; +import "show_show_state.proto"; +import "podcast_segments.proto"; +import "podcast_virality.proto"; +import "podcastextensions.proto"; +import "podcast_poll.proto"; +import "podcast_qna.proto"; +import "transcripts.proto"; + +option optimize_for = CODE_SIZE; + +message Show { + optional cosmos_util.proto.ShowMetadata show_metadata = 1; + optional show_cosmos.proto.ShowCollectionState show_collection_state = 2; + optional show_cosmos.proto.ShowPlayState show_play_state = 3; + optional string link = 4; + optional podcast_paywalls.ShowAccess access_info = 5; +} + +message Episode { + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 1; + optional show_cosmos.proto.EpisodeCollectionState episode_collection_state = 2; + optional show_cosmos.proto.EpisodeOfflineState episode_offline_state = 3; + optional show_cosmos.proto.EpisodePlayState episode_play_state = 4; + optional string link = 5; + optional podcast_segments.PodcastSegments segments = 6; + optional podcast.extensions.PodcastHtmlDescription html_description = 7; + optional corex.transcripts.metadata.EpisodeTranscript transcripts = 9; + optional podcastvirality.v1.PodcastVirality virality = 10; + optional polls.PodcastPoll podcast_poll = 11; + optional qanda.PodcastQna podcast_qna = 12; + + reserved 8; +} + +message Response { + repeated Show show = 1; + repeated Episode episode = 2; +} diff --git a/protocol/proto/dependencies/session_control.proto b/protocol/proto/dependencies/session_control.proto new file mode 100644 index 00000000..f4e6d744 --- /dev/null +++ b/protocol/proto/dependencies/session_control.proto @@ -0,0 +1,121 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package com.spotify.sessioncontrol.api.v1; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.sessioncontrol.api.v1.proto"; + +service SessionControlService { + rpc GetCurrentSession(GetCurrentSessionRequest) returns (GetCurrentSessionResponse); + rpc GetCurrentSessionOrNew(GetCurrentSessionOrNewRequest) returns (GetCurrentSessionOrNewResponse); + rpc JoinSession(JoinSessionRequest) returns (JoinSessionResponse); + rpc GetSessionInfo(GetSessionInfoRequest) returns (GetSessionInfoResponse); + rpc LeaveSession(LeaveSessionRequest) returns (LeaveSessionResponse); + rpc EndSession(EndSessionRequest) returns (EndSessionResponse); + rpc VerifyCommand(VerifyCommandRequest) returns (VerifyCommandResponse); +} + +message SessionUpdate { + Session session = 1; + SessionUpdateReason reason = 2; + repeated SessionMember updated_session_members = 3; +} + +message GetCurrentSessionRequest { + +} + +message GetCurrentSessionResponse { + Session session = 1; +} + +message GetCurrentSessionOrNewRequest { + string fallback_device_id = 1; +} + +message GetCurrentSessionOrNewResponse { + Session session = 1; +} + +message JoinSessionRequest { + string join_token = 1; + string device_id = 2; + Experience experience = 3; +} + +message JoinSessionResponse { + Session session = 1; +} + +message GetSessionInfoRequest { + string join_token = 1; +} + +message GetSessionInfoResponse { + Session session = 1; +} + +message LeaveSessionRequest { + +} + +message LeaveSessionResponse { + +} + +message EndSessionRequest { + string session_id = 1; +} + +message EndSessionResponse { + +} + +message VerifyCommandRequest { + string session_id = 1; + string command = 2; +} + +message VerifyCommandResponse { + bool allowed = 1; +} + +message Session { + int64 timestamp = 1; + string session_id = 2; + string join_session_token = 3; + string join_session_url = 4; + string session_owner_id = 5; + repeated SessionMember session_members = 6; + string join_session_uri = 7; + bool is_session_owner = 8; +} + +message SessionMember { + int64 timestamp = 1; + string id = 2; + string username = 3; + string display_name = 4; + string image_url = 5; + string large_image_url = 6; +} + +enum SessionUpdateReason { + UNKNOWN_UPDATE_REASON = 0; + NEW_SESSION = 1; + USER_JOINED = 2; + USER_LEFT = 3; + SESSION_DELETED = 4; + YOU_LEFT = 5; + YOU_WERE_KICKED = 6; + YOU_JOINED = 7; +} + +enum Experience { + UNKNOWN = 0; + BEETHOVEN = 1; + BACH = 2; +} diff --git a/protocol/proto/devices.proto b/protocol/proto/devices.proto new file mode 100644 index 00000000..ebfadc1b --- /dev/null +++ b/protocol/proto/devices.proto @@ -0,0 +1,35 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.connectstate.devices; + +option java_package = "com.spotify.common.proto"; + +message DeviceAlias { + uint32 id = 1; + string display_name = 2; + bool is_group = 3; +} + +enum DeviceType { + UNKNOWN = 0; + COMPUTER = 1; + TABLET = 2; + SMARTPHONE = 3; + SPEAKER = 4; + TV = 5; + AVR = 6; + STB = 7; + AUDIO_DONGLE = 8; + GAME_CONSOLE = 9; + CAST_VIDEO = 10; + CAST_AUDIO = 11; + AUTOMOBILE = 12; + SMARTWATCH = 13; + CHROMEBOOK = 14; + UNKNOWN_SPOTIFY = 100; + CAR_THING = 101; + OBSERVER = 102; + HOME_THING = 103; +} diff --git a/protocol/proto/display_segments.proto b/protocol/proto/display_segments.proto new file mode 100644 index 00000000..eb3e02b3 --- /dev/null +++ b/protocol/proto/display_segments.proto @@ -0,0 +1,40 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_segments.display; + +import "podcast_segments.proto"; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "DisplaySegmentsProto"; +option java_package = "com.spotify.podcastsegments.display.proto"; + +message DisplaySegments { + repeated DisplaySegment display_segments = 1; + bool can_upsell = 2; + string album_mosaic_uri = 3; + repeated string artists = 4; + int32 duration_ms = 5; +} + +message DisplaySegment { + string uri = 1; + int32 absolute_start_ms = 2; + int32 absolute_stop_ms = 3; + + Source source = 4; + enum Source { + PLAYBACK = 0; + EMBEDDED = 1; + } + + SegmentType type = 5; + string title = 6; + string subtitle = 7; + string image_url = 8; + string action_url = 9; + bool is_abridged = 10; +} diff --git a/protocol/proto/entity_extension_data.proto b/protocol/proto/entity_extension_data.proto new file mode 100644 index 00000000..e26d735e --- /dev/null +++ b/protocol/proto/entity_extension_data.proto @@ -0,0 +1,39 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.extendedmetadata; + +import "google/protobuf/any.proto"; + +option cc_enable_arenas = true; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.extendedmetadata.proto"; + +message EntityExtensionDataHeader { + int32 status_code = 1; + string etag = 2; + string locale = 3; + int64 cache_ttl_in_seconds = 4; + int64 offline_ttl_in_seconds = 5; +} + +message EntityExtensionData { + EntityExtensionDataHeader header = 1; + string entity_uri = 2; + google.protobuf.Any extension_data = 3; +} + +message PlainListAssoc { + repeated string entity_uri = 1; +} + +message AssocHeader { + +} + +message Assoc { + AssocHeader header = 1; + PlainListAssoc plain_list = 2; +} diff --git a/protocol/proto/es_add_to_queue_request.proto b/protocol/proto/es_add_to_queue_request.proto new file mode 100644 index 00000000..34997731 --- /dev/null +++ b/protocol/proto/es_add_to_queue_request.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_context_track.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message AddToQueueRequest { + ContextTrack track = 1; + CommandOptions options = 2; + LoggingParams logging_params = 3; +} diff --git a/protocol/proto/es_command_options.proto b/protocol/proto/es_command_options.proto new file mode 100644 index 00000000..c261ca27 --- /dev/null +++ b/protocol/proto/es_command_options.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message CommandOptions { + bool override_restrictions = 1; + bool only_for_local_device = 2; + bool system_initiated = 3; +} diff --git a/protocol/proto/es_context.proto b/protocol/proto/es_context.proto new file mode 100644 index 00000000..05962fa7 --- /dev/null +++ b/protocol/proto/es_context.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context_page.proto"; +import "es_restrictions.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message Context { + repeated ContextPage pages = 1; + map metadata = 2; + string uri = 3; + string url = 4; + bool is_loaded = 5; + Restrictions restrictions = 6; +} diff --git a/protocol/proto/es_context_page.proto b/protocol/proto/es_context_page.proto new file mode 100644 index 00000000..f4cc6930 --- /dev/null +++ b/protocol/proto/es_context_page.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ContextPage { + repeated ContextTrack tracks = 1; + map metadata = 2; + string page_url = 3; + string next_page_url = 4; + bool is_loaded = 5; +} diff --git a/protocol/proto/es_context_player_error.proto b/protocol/proto/es_context_player_error.proto new file mode 100644 index 00000000..f332fe8a --- /dev/null +++ b/protocol/proto/es_context_player_error.proto @@ -0,0 +1,55 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ContextPlayerError { + ErrorCode code = 1; + enum ErrorCode { + SUCCESS = 0; + PLAYBACK_STUCK = 1; + PLAYBACK_ERROR = 2; + LICENSE_CHANGE = 3; + PLAY_RESTRICTED = 4; + STOP_RESTRICTED = 5; + UPDATE_RESTRICTED = 6; + PAUSE_RESTRICTED = 7; + RESUME_RESTRICTED = 8; + SKIP_TO_PREV_RESTRICTED = 9; + SKIP_TO_NEXT_RESTRICTED = 10; + SKIP_TO_NON_EXISTENT_TRACK = 11; + SEEK_TO_RESTRICTED = 12; + TOGGLE_REPEAT_CONTEXT_RESTRICTED = 13; + TOGGLE_REPEAT_TRACK_RESTRICTED = 14; + SET_OPTIONS_RESTRICTED = 15; + TOGGLE_SHUFFLE_RESTRICTED = 16; + SET_QUEUE_RESTRICTED = 17; + INTERRUPT_PLAYBACK_RESTRICTED = 18; + ONE_TRACK_UNPLAYABLE = 19; + ONE_TRACK_UNPLAYABLE_AUTO_STOPPED = 20; + ALL_TRACKS_UNPLAYABLE_AUTO_STOPPED = 21; + SKIP_TO_NON_EXISTENT_TRACK_AUTO_STOPPED = 22; + QUEUE_REVISION_MISMATCH = 23; + VIDEO_PLAYBACK_ERROR = 24; + VIDEO_GEOGRAPHICALLY_RESTRICTED = 25; + VIDEO_UNSUPPORTED_PLATFORM_VERSION = 26; + VIDEO_UNSUPPORTED_CLIENT_VERSION = 27; + VIDEO_UNSUPPORTED_KEY_SYSTEM = 28; + VIDEO_MANIFEST_DELETED = 29; + VIDEO_COUNTRY_RESTRICTED = 30; + VIDEO_UNAVAILABLE = 31; + VIDEO_CATALOGUE_RESTRICTED = 32; + INVALID = 33; + TIMEOUT = 34; + PLAYBACK_REPORTING_ERROR = 35; + UNKNOWN = 36; + } + + string message = 2; + map data = 3; +} diff --git a/protocol/proto/es_context_player_options.proto b/protocol/proto/es_context_player_options.proto new file mode 100644 index 00000000..372b53c0 --- /dev/null +++ b/protocol/proto/es_context_player_options.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_optional.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ContextPlayerOptions { + bool shuffling_context = 1; + bool repeating_context = 2; + bool repeating_track = 3; +} + +message ContextPlayerOptionOverrides { + OptionalBoolean shuffling_context = 1; + OptionalBoolean repeating_context = 2; + OptionalBoolean repeating_track = 3; +} diff --git a/protocol/proto/es_context_player_state.proto b/protocol/proto/es_context_player_state.proto new file mode 100644 index 00000000..f1626572 --- /dev/null +++ b/protocol/proto/es_context_player_state.proto @@ -0,0 +1,82 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_restrictions.proto"; +import "es_play_origin.proto"; +import "es_optional.proto"; +import "es_provided_track.proto"; +import "es_context_player_options.proto"; +import "es_prepare_play_options.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ContextIndex { + uint64 page = 1; + uint64 track = 2; +} + +message PlaybackQuality { + BitrateLevel bitrate_level = 1; + enum BitrateLevel { + UNKNOWN = 0; + LOW = 1; + NORMAL = 2; + HIGH = 3; + VERY_HIGH = 4; + HIFI = 5; + } + + BitrateStrategy strategy = 2; + enum BitrateStrategy { + UNKNOWN_STRATEGY = 0; + BEST_MATCHING = 1; + BACKEND_ADVISED = 2; + OFFLINED_FILE = 3; + CACHED_FILE = 4; + LOCAL_FILE = 5; + } + + BitrateLevel target_bitrate_level = 3; + bool target_bitrate_available = 4; + + HiFiStatus hifi_status = 5; + enum HiFiStatus { + NONE = 0; + OFF = 1; + ON = 2; + } +} + +message ContextPlayerState { + uint64 timestamp = 1; + string context_uri = 2; + string context_url = 3; + Restrictions context_restrictions = 4; + PlayOrigin play_origin = 5; + ContextIndex index = 6; + ProvidedTrack track = 7; + bytes playback_id = 8; + PlaybackQuality playback_quality = 9; + OptionalDouble playback_speed = 10; + OptionalInt64 position_as_of_timestamp = 11; + OptionalInt64 duration = 12; + bool is_playing = 13; + bool is_paused = 14; + bool is_buffering = 15; + bool is_system_initiated = 16; + ContextPlayerOptions options = 17; + Restrictions restrictions = 18; + repeated string suppressions = 19; + repeated ProvidedTrack prev_tracks = 20; + repeated ProvidedTrack next_tracks = 21; + map context_metadata = 22; + map page_metadata = 23; + string session_id = 24; + uint64 queue_revision = 25; + PreparePlayOptions.AudioStream audio_stream = 26; +} diff --git a/protocol/proto/es_context_track.proto b/protocol/proto/es_context_track.proto new file mode 100644 index 00000000..cdcbd7c2 --- /dev/null +++ b/protocol/proto/es_context_track.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ContextTrack { + string uri = 1; + string uid = 2; + map metadata = 3; +} diff --git a/protocol/proto/es_delete_session.proto b/protocol/proto/es_delete_session.proto new file mode 100644 index 00000000..e45893c4 --- /dev/null +++ b/protocol/proto/es_delete_session.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message DeleteSessionRequest { + string session_id = 1; +} + +message DeleteSessionResponse { + +} diff --git a/protocol/proto/es_get_error_request.proto b/protocol/proto/es_get_error_request.proto new file mode 100644 index 00000000..3119beaa --- /dev/null +++ b/protocol/proto/es_get_error_request.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message GetErrorRequest { + +} diff --git a/protocol/proto/es_get_play_history.proto b/protocol/proto/es_get_play_history.proto new file mode 100644 index 00000000..08bb053c --- /dev/null +++ b/protocol/proto/es_get_play_history.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message GetPlayHistoryRequest { + +} + +message GetPlayHistoryResponse { + repeated ContextTrack tracks = 1; +} diff --git a/protocol/proto/es_get_position_state.proto b/protocol/proto/es_get_position_state.proto new file mode 100644 index 00000000..6147f0c5 --- /dev/null +++ b/protocol/proto/es_get_position_state.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message GetPositionStateRequest { + +} + +message GetPositionStateResponse { + Error error = 1; + enum Error { + OK = 0; + NOT_FOUND = 1; + } + + uint64 timestamp = 2; + uint64 position = 3; + double playback_speed = 4; +} diff --git a/protocol/proto/es_get_queue_request.proto b/protocol/proto/es_get_queue_request.proto new file mode 100644 index 00000000..68b6830a --- /dev/null +++ b/protocol/proto/es_get_queue_request.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message GetQueueRequest { + +} diff --git a/protocol/proto/es_get_state_request.proto b/protocol/proto/es_get_state_request.proto new file mode 100644 index 00000000..d8cd5335 --- /dev/null +++ b/protocol/proto/es_get_state_request.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_optional.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message GetStateRequest { + OptionalInt64 prev_tracks_cap = 1; + OptionalInt64 next_tracks_cap = 2; +} diff --git a/protocol/proto/es_logging_params.proto b/protocol/proto/es_logging_params.proto new file mode 100644 index 00000000..c508cba2 --- /dev/null +++ b/protocol/proto/es_logging_params.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_optional.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message LoggingParams { + OptionalInt64 command_initiated_time = 1; + OptionalInt64 command_received_time = 2; + repeated string page_instance_ids = 3; + repeated string interaction_ids = 4; +} diff --git a/protocol/proto/es_optional.proto b/protocol/proto/es_optional.proto new file mode 100644 index 00000000..2ca0b01f --- /dev/null +++ b/protocol/proto/es_optional.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message OptionalInt64 { + int64 value = 1; +} + +message OptionalDouble { + double value = 1; +} + +message OptionalBoolean { + bool value = 1; +} diff --git a/protocol/proto/es_pause.proto b/protocol/proto/es_pause.proto new file mode 100644 index 00000000..56378fb5 --- /dev/null +++ b/protocol/proto/es_pause.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message PauseRequest { + CommandOptions options = 1; + LoggingParams logging_params = 2; +} diff --git a/protocol/proto/es_play.proto b/protocol/proto/es_play.proto new file mode 100644 index 00000000..34dca48a --- /dev/null +++ b/protocol/proto/es_play.proto @@ -0,0 +1,28 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; +import "es_play_options.proto"; +import "es_prepare_play.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message PlayRequest { + PreparePlayRequest prepare_play_request = 1; + PlayOptions play_options = 2; + CommandOptions options = 3; + LoggingParams logging_params = 4; +} + +message PlayPreparedRequest { + string session_id = 1; + PlayOptions play_options = 2; + CommandOptions options = 3; + LoggingParams logging_params = 4; +} diff --git a/protocol/proto/es_play_options.proto b/protocol/proto/es_play_options.proto new file mode 100644 index 00000000..f068921b --- /dev/null +++ b/protocol/proto/es_play_options.proto @@ -0,0 +1,32 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message PlayOptions { + Reason reason = 1; + enum Reason { + INTERACTIVE = 0; + REMOTE_TRANSFER = 1; + LICENSE_CHANGE = 2; + } + + Operation operation = 2; + enum Operation { + REPLACE = 0; + ENQUEUE = 1; + PUSH = 2; + } + + Trigger trigger = 3; + enum Trigger { + IMMEDIATELY = 0; + ADVANCED_PAST_TRACK = 1; + ADVANCED_PAST_CONTEXT = 2; + } +} diff --git a/protocol/proto/es_play_origin.proto b/protocol/proto/es_play_origin.proto new file mode 100644 index 00000000..62cff8b7 --- /dev/null +++ b/protocol/proto/es_play_origin.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message PlayOrigin { + string feature_identifier = 1; + string feature_version = 2; + string view_uri = 3; + string external_referrer = 4; + string referrer_identifier = 5; + string device_identifier = 6; + repeated string feature_classes = 7; +} diff --git a/protocol/proto/es_prepare_play.proto b/protocol/proto/es_prepare_play.proto new file mode 100644 index 00000000..6662eb65 --- /dev/null +++ b/protocol/proto/es_prepare_play.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context.proto"; +import "es_play_origin.proto"; +import "es_prepare_play_options.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message PreparePlayRequest { + Context context = 1; + PreparePlayOptions options = 2; + PlayOrigin play_origin = 3; +} diff --git a/protocol/proto/es_prepare_play_options.proto b/protocol/proto/es_prepare_play_options.proto new file mode 100644 index 00000000..b4a4449c --- /dev/null +++ b/protocol/proto/es_prepare_play_options.proto @@ -0,0 +1,40 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context_player_options.proto"; +import "es_optional.proto"; +import "es_skip_to_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message PreparePlayOptions { + bytes playback_id = 1; + bool always_play_something = 2; + SkipToTrack skip_to = 3; + OptionalInt64 seek_to = 4; + bool initially_paused = 5; + bool system_initiated = 6; + ContextPlayerOptionOverrides player_options_override = 7; + repeated string suppressions = 8; + + PrefetchLevel prefetch_level = 9; + enum PrefetchLevel { + NONE = 0; + MEDIA = 1; + } + + AudioStream audio_stream = 10; + enum AudioStream { + DEFAULT = 0; + ALARM = 1; + } + + string session_id = 11; + string license = 12; + map configuration_override = 13; +} diff --git a/protocol/proto/es_provided_track.proto b/protocol/proto/es_provided_track.proto new file mode 100644 index 00000000..6dcffc0d --- /dev/null +++ b/protocol/proto/es_provided_track.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ProvidedTrack { + ContextTrack context_track = 1; + repeated string removed = 2; + repeated string blocked = 3; + string provider = 4; +} diff --git a/protocol/proto/es_queue.proto b/protocol/proto/es_queue.proto new file mode 100644 index 00000000..625b184d --- /dev/null +++ b/protocol/proto/es_queue.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_provided_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message Queue { + uint64 queue_revision = 1; + ProvidedTrack track = 2; + repeated ProvidedTrack next_tracks = 3; + repeated ProvidedTrack prev_tracks = 4; +} diff --git a/protocol/proto/es_response_with_reasons.proto b/protocol/proto/es_response_with_reasons.proto new file mode 100644 index 00000000..6570a177 --- /dev/null +++ b/protocol/proto/es_response_with_reasons.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ResponseWithReasons { + Error error = 1; + enum Error { + OK = 0; + FORBIDDEN = 1; + NOT_FOUND = 2; + CONFLICT = 3; + } + + string reasons = 2; +} diff --git a/protocol/proto/es_restrictions.proto b/protocol/proto/es_restrictions.proto new file mode 100644 index 00000000..3a5c3a0a --- /dev/null +++ b/protocol/proto/es_restrictions.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message Restrictions { + repeated string disallow_pausing_reasons = 1; + repeated string disallow_resuming_reasons = 2; + repeated string disallow_seeking_reasons = 3; + repeated string disallow_peeking_prev_reasons = 4; + repeated string disallow_peeking_next_reasons = 5; + repeated string disallow_skipping_prev_reasons = 6; + repeated string disallow_skipping_next_reasons = 7; + repeated string disallow_toggling_repeat_context_reasons = 8; + repeated string disallow_toggling_repeat_track_reasons = 9; + repeated string disallow_toggling_shuffle_reasons = 10; + repeated string disallow_set_queue_reasons = 11; + repeated string disallow_interrupting_playback_reasons = 12; + repeated string disallow_transferring_playback_reasons = 13; + repeated string disallow_remote_control_reasons = 14; + repeated string disallow_inserting_into_next_tracks_reasons = 15; + repeated string disallow_inserting_into_context_tracks_reasons = 16; + repeated string disallow_reordering_in_next_tracks_reasons = 17; + repeated string disallow_reordering_in_context_tracks_reasons = 18; + repeated string disallow_removing_from_next_tracks_reasons = 19; + repeated string disallow_removing_from_context_tracks_reasons = 20; + repeated string disallow_updating_context_reasons = 21; +} diff --git a/protocol/proto/es_resume.proto b/protocol/proto/es_resume.proto new file mode 100644 index 00000000..1af5980f --- /dev/null +++ b/protocol/proto/es_resume.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message ResumeRequest { + CommandOptions options = 1; + LoggingParams logging_params = 2; +} diff --git a/protocol/proto/es_seek_to.proto b/protocol/proto/es_seek_to.proto new file mode 100644 index 00000000..0ef8aa4b --- /dev/null +++ b/protocol/proto/es_seek_to.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SeekToRequest { + CommandOptions options = 1; + LoggingParams logging_params = 2; + int64 position = 3; +} diff --git a/protocol/proto/es_session_response.proto b/protocol/proto/es_session_response.proto new file mode 100644 index 00000000..692ae30f --- /dev/null +++ b/protocol/proto/es_session_response.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SessionResponse { + string session_id = 1; +} diff --git a/protocol/proto/es_set_options.proto b/protocol/proto/es_set_options.proto new file mode 100644 index 00000000..33faf5f8 --- /dev/null +++ b/protocol/proto/es_set_options.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; +import "es_optional.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SetOptionsRequest { + OptionalBoolean repeating_track = 1; + OptionalBoolean repeating_context = 2; + OptionalBoolean shuffling_context = 3; + CommandOptions options = 4; + LoggingParams logging_params = 5; +} diff --git a/protocol/proto/es_set_queue_request.proto b/protocol/proto/es_set_queue_request.proto new file mode 100644 index 00000000..83715232 --- /dev/null +++ b/protocol/proto/es_set_queue_request.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_provided_track.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SetQueueRequest { + repeated ProvidedTrack next_tracks = 1; + repeated ProvidedTrack prev_tracks = 2; + uint64 queue_revision = 3; + CommandOptions options = 4; + LoggingParams logging_params = 5; +} diff --git a/protocol/proto/es_set_repeating_context.proto b/protocol/proto/es_set_repeating_context.proto new file mode 100644 index 00000000..25667c81 --- /dev/null +++ b/protocol/proto/es_set_repeating_context.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SetRepeatingContextRequest { + bool repeating_context = 1; + CommandOptions options = 2; + LoggingParams logging_params = 3; +} diff --git a/protocol/proto/es_set_repeating_track.proto b/protocol/proto/es_set_repeating_track.proto new file mode 100644 index 00000000..01ae3b56 --- /dev/null +++ b/protocol/proto/es_set_repeating_track.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SetRepeatingTrackRequest { + bool repeating_track = 1; + CommandOptions options = 2; + LoggingParams logging_params = 3; +} diff --git a/protocol/proto/es_set_shuffling_context.proto b/protocol/proto/es_set_shuffling_context.proto new file mode 100644 index 00000000..6eb779e6 --- /dev/null +++ b/protocol/proto/es_set_shuffling_context.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SetShufflingContextRequest { + bool shuffling_context = 1; + CommandOptions options = 2; + LoggingParams logging_params = 3; +} diff --git a/protocol/proto/es_skip_next.proto b/protocol/proto/es_skip_next.proto new file mode 100644 index 00000000..d6b0dc83 --- /dev/null +++ b/protocol/proto/es_skip_next.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; +import "es_context_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SkipNextRequest { + CommandOptions options = 1; + LoggingParams logging_params = 2; + ContextTrack track = 3; +} diff --git a/protocol/proto/es_skip_prev.proto b/protocol/proto/es_skip_prev.proto new file mode 100644 index 00000000..2a6b9a71 --- /dev/null +++ b/protocol/proto/es_skip_prev.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; +import "es_context_track.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SkipPrevRequest { + CommandOptions options = 1; + bool allow_seeking = 2; + LoggingParams logging_params = 3; + ContextTrack track = 4; +} diff --git a/protocol/proto/es_skip_to_track.proto b/protocol/proto/es_skip_to_track.proto new file mode 100644 index 00000000..ecf0d03f --- /dev/null +++ b/protocol/proto/es_skip_to_track.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_optional.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message SkipToTrack { + string page_url = 1; + OptionalInt64 page_index = 2; + string track_uid = 3; + string track_uri = 4; + OptionalInt64 track_index = 5; +} diff --git a/protocol/proto/es_stop.proto b/protocol/proto/es_stop.proto new file mode 100644 index 00000000..068490e0 --- /dev/null +++ b/protocol/proto/es_stop.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_command_options.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message StopRequest { + CommandOptions options = 1; + + Reason reason = 2; + enum Reason { + INTERACTIVE = 0; + REMOTE_TRANSFER = 1; + SHUTDOWN = 2; + } + + LoggingParams logging_params = 3; +} diff --git a/protocol/proto/es_update.proto b/protocol/proto/es_update.proto new file mode 100644 index 00000000..90734b5d --- /dev/null +++ b/protocol/proto/es_update.proto @@ -0,0 +1,38 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.player.esperanto.proto; + +import "es_context.proto"; +import "es_context_page.proto"; +import "es_context_track.proto"; +import "es_logging_params.proto"; + +option objc_class_prefix = "ESP"; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.player.esperanto.proto"; + +message UpdateContextRequest { + string session_id = 1; + Context context = 2; + LoggingParams logging_params = 3; +} + +message UpdateContextPageRequest { + string session_id = 1; + ContextPage context_page = 2; + LoggingParams logging_params = 3; +} + +message UpdateContextTrackRequest { + string session_id = 1; + ContextTrack context_track = 2; + LoggingParams logging_params = 3; +} + +message UpdateViewUriRequest { + string session_id = 1; + string view_uri = 2; + LoggingParams logging_params = 3; +} diff --git a/protocol/proto/event_entity.proto b/protocol/proto/event_entity.proto new file mode 100644 index 00000000..28ec0b5a --- /dev/null +++ b/protocol/proto/event_entity.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message EventEntity { + int32 file_format_version = 1; + string event_name = 2; + bytes sequence_id = 3; + int64 sequence_number = 4; + bytes payload = 5; + string owner = 6; + bool authenticated = 7; + int64 record_id = 8; +} diff --git a/protocol/proto/explicit_content_pubsub.proto b/protocol/proto/explicit_content_pubsub.proto new file mode 100644 index 00000000..1bb45f91 --- /dev/null +++ b/protocol/proto/explicit_content_pubsub.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.explicit_content.proto; + +option optimize_for = CODE_SIZE; + +message KeyValuePair { + required string key = 1; + required string value = 2; +} + +message UserAttributesUpdate { + repeated KeyValuePair pairs = 1; +} diff --git a/protocol/proto/extended_metadata.proto b/protocol/proto/extended_metadata.proto new file mode 100644 index 00000000..2e38d28d --- /dev/null +++ b/protocol/proto/extended_metadata.proto @@ -0,0 +1,62 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.extendedmetadata; + +import "extension_kind.proto"; +import "entity_extension_data.proto"; + +option cc_enable_arenas = true; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.extendedmetadata.proto"; + +message ExtensionQuery { + ExtensionKind extension_kind = 1; + string etag = 2; +} + +message EntityRequest { + string entity_uri = 1; + repeated ExtensionQuery query = 2; +} + +message BatchedEntityRequestHeader { + string country = 1; + string catalogue = 2; + bytes task_id = 3; +} + +message BatchedEntityRequest { + BatchedEntityRequestHeader header = 1; + repeated EntityRequest entity_request = 2; +} + +message EntityExtensionDataArrayHeader { + int32 provider_error_status = 1; + int64 cache_ttl_in_seconds = 2; + int64 offline_ttl_in_seconds = 3; + ExtensionType extension_type = 4; +} + +message EntityExtensionDataArray { + EntityExtensionDataArrayHeader header = 1; + ExtensionKind extension_kind = 2; + repeated EntityExtensionData extension_data = 3; +} + +message BatchedExtensionResponseHeader { + +} + +message BatchedExtensionResponse { + BatchedExtensionResponseHeader header = 1; + repeated EntityExtensionDataArray extended_metadata = 2; +} + +enum ExtensionType { + UNKNOWN = 0; + GENERIC = 1; + ASSOC = 2; +} diff --git a/protocol/proto/extension_descriptor_type.proto b/protocol/proto/extension_descriptor_type.proto new file mode 100644 index 00000000..a2009d68 --- /dev/null +++ b/protocol/proto/extension_descriptor_type.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.descriptorextension; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.descriptorextension.proto"; + +message ExtensionDescriptor { + string text = 1; + float weight = 2; + repeated ExtensionDescriptorType types = 3; +} + +message ExtensionDescriptorData { + repeated ExtensionDescriptor descriptors = 1; +} + +enum ExtensionDescriptorType { + UNKNOWN = 0; + GENRE = 1; + MOOD = 2; + ACTIVITY = 3; + INSTRUMENT = 4; + TIME = 5; + ERA = 6; +} diff --git a/protocol/proto/extension_kind.proto b/protocol/proto/extension_kind.proto new file mode 100644 index 00000000..97768b67 --- /dev/null +++ b/protocol/proto/extension_kind.proto @@ -0,0 +1,46 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.extendedmetadata; + +option cc_enable_arenas = true; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.extendedmetadata.proto"; + +enum ExtensionKind { + UNKNOWN_EXTENSION = 0; + CANVAZ = 1; + STORYLINES = 2; + PODCAST_TOPICS = 3; + PODCAST_SEGMENTS = 4; + AUDIO_FILES = 5; + TRACK_DESCRIPTOR = 6; + ARTIST_V4 = 8; + ALBUM_V4 = 9; + TRACK_V4 = 10; + SHOW_V4 = 11; + EPISODE_V4 = 12; + PODCAST_HTML_DESCRIPTION = 13; + PODCAST_QUOTES = 14; + USER_PROFILE = 15; + CANVAS_V1 = 16; + SHOW_V4_BASE = 17; + SHOW_V4_EPISODES_ASSOC = 18; + TRACK_DESCRIPTOR_SIGNATURES = 19; + PODCAST_AD_SEGMENTS = 20; + EPISODE_TRANSCRIPTS = 21; + PODCAST_SUBSCRIPTIONS = 22; + EXTRACTED_COLOR = 23; + PODCAST_VIRALITY = 24; + IMAGE_SPARKLES_HACK = 25; + PODCAST_POPULARITY_HACK = 26; + AUTOMIX_MODE = 27; + CUEPOINTS = 28; + PODCAST_POLL = 29; + EPISODE_ACCESS = 30; + SHOW_ACCESS = 31; + PODCAST_QNA = 32; + CLIPS = 33; +} diff --git a/protocol/proto/extracted_colors.proto b/protocol/proto/extracted_colors.proto new file mode 100644 index 00000000..999a27ea --- /dev/null +++ b/protocol/proto/extracted_colors.proto @@ -0,0 +1,24 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.context_track_color; + +message ColorResult { + Color color_raw = 1; + Color color_light = 2; + Color color_dark = 3; + Status status = 5; +} + +message Color { + int32 rgb = 1; + bool is_fallback = 2; +} + +enum Status { + OK = 0; + IN_PROGRESS = 1; + INVALID_URL = 2; + INTERNAL = 3; +} diff --git a/protocol/proto/facebook-publish.proto b/protocol/proto/facebook-publish.proto deleted file mode 100644 index 4edef249..00000000 --- a/protocol/proto/facebook-publish.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto2"; - -message EventReply { - optional int32 queued = 0x1; - optional RetryInfo retry = 0x2; -} - -message RetryInfo { - optional int32 retry_delay = 0x1; - optional int32 max_retry = 0x2; -} - -message Id { - optional string uri = 0x1; - optional int64 start_time = 0x2; -} - -message Start { - optional int32 length = 0x1; - optional string context_uri = 0x2; - optional int64 end_time = 0x3; -} - -message Seek { - optional int64 end_time = 0x1; -} - -message Pause { - optional int32 seconds_played = 0x1; - optional int64 end_time = 0x2; -} - -message Resume { - optional int32 seconds_played = 0x1; - optional int64 end_time = 0x2; -} - -message End { - optional int32 seconds_played = 0x1; - optional int64 end_time = 0x2; -} - -message Event { - optional Id id = 0x1; - optional Start start = 0x2; - optional Seek seek = 0x3; - optional Pause pause = 0x4; - optional Resume resume = 0x5; - optional End end = 0x6; -} - diff --git a/protocol/proto/facebook.proto b/protocol/proto/facebook.proto deleted file mode 100644 index 8227c5a1..00000000 --- a/protocol/proto/facebook.proto +++ /dev/null @@ -1,183 +0,0 @@ -syntax = "proto2"; - -message Credential { - optional string facebook_uid = 0x1; - optional string access_token = 0x2; -} - -message EnableRequest { - optional Credential credential = 0x1; -} - -message EnableReply { - optional Credential credential = 0x1; -} - -message DisableRequest { - optional Credential credential = 0x1; -} - -message RevokeRequest { - optional Credential credential = 0x1; -} - -message InspectCredentialRequest { - optional Credential credential = 0x1; -} - -message InspectCredentialReply { - optional Credential alternative_credential = 0x1; - optional bool app_user = 0x2; - optional bool permanent_error = 0x3; - optional bool transient_error = 0x4; -} - -message UserState { - optional Credential credential = 0x1; -} - -message UpdateUserStateRequest { - optional Credential credential = 0x1; -} - -message OpenGraphError { - repeated string permanent = 0x1; - repeated string invalid_token = 0x2; - repeated string retries = 0x3; -} - -message OpenGraphScrobble { - optional int32 create_delay = 0x1; -} - -message OpenGraphConfig { - optional OpenGraphError error = 0x1; - optional OpenGraphScrobble scrobble = 0x2; -} - -message AuthConfig { - optional string url = 0x1; - repeated string permissions = 0x2; - repeated string blacklist = 0x3; - repeated string whitelist = 0x4; - repeated string cancel = 0x5; -} - -message ConfigReply { - optional string domain = 0x1; - optional string app_id = 0x2; - optional string app_namespace = 0x3; - optional AuthConfig auth = 0x4; - optional OpenGraphConfig og = 0x5; -} - -message UserFields { - optional bool app_user = 0x1; - optional bool display_name = 0x2; - optional bool first_name = 0x3; - optional bool middle_name = 0x4; - optional bool last_name = 0x5; - optional bool picture_large = 0x6; - optional bool picture_square = 0x7; - optional bool gender = 0x8; - optional bool email = 0x9; -} - -message UserOptions { - optional bool cache_is_king = 0x1; -} - -message UserRequest { - optional UserOptions options = 0x1; - optional UserFields fields = 0x2; -} - -message User { - optional string spotify_username = 0x1; - optional string facebook_uid = 0x2; - optional bool app_user = 0x3; - optional string display_name = 0x4; - optional string first_name = 0x5; - optional string middle_name = 0x6; - optional string last_name = 0x7; - optional string picture_large = 0x8; - optional string picture_square = 0x9; - optional string gender = 0xa; - optional string email = 0xb; -} - -message FriendsFields { - optional bool app_user = 0x1; - optional bool display_name = 0x2; - optional bool picture_large = 0x6; -} - -message FriendsOptions { - optional int32 limit = 0x1; - optional int32 offset = 0x2; - optional bool cache_is_king = 0x3; - optional bool app_friends = 0x4; - optional bool non_app_friends = 0x5; -} - -message FriendsRequest { - optional FriendsOptions options = 0x1; - optional FriendsFields fields = 0x2; -} - -message FriendsReply { - repeated User friends = 0x1; - optional bool more = 0x2; -} - -message ShareRequest { - optional Credential credential = 0x1; - optional string uri = 0x2; - optional string message_text = 0x3; -} - -message ShareReply { - optional string post_id = 0x1; -} - -message InboxRequest { - optional Credential credential = 0x1; - repeated string facebook_uids = 0x3; - optional string message_text = 0x4; - optional string message_link = 0x5; -} - -message InboxReply { - optional string message_id = 0x1; - optional string thread_id = 0x2; -} - -message PermissionsOptions { - optional bool cache_is_king = 0x1; -} - -message PermissionsRequest { - optional Credential credential = 0x1; - optional PermissionsOptions options = 0x2; -} - -message PermissionsReply { - repeated string permissions = 0x1; -} - -message GrantPermissionsRequest { - optional Credential credential = 0x1; - repeated string permissions = 0x2; -} - -message GrantPermissionsReply { - repeated string granted = 0x1; - repeated string failed = 0x2; -} - -message TransferRequest { - optional Credential credential = 0x1; - optional string source_username = 0x2; - optional string target_username = 0x3; -} - diff --git a/protocol/proto/format.proto b/protocol/proto/format.proto new file mode 100644 index 00000000..3a75b4df --- /dev/null +++ b/protocol/proto/format.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +enum Format { + FORMAT_UNKNOWN = 0; + FORMAT_OGG_VORBIS_96 = 1; + FORMAT_OGG_VORBIS_160 = 2; + FORMAT_OGG_VORBIS_320 = 3; + FORMAT_MP3_256 = 4; + FORMAT_MP3_320 = 5; + FORMAT_MP3_160 = 6; + FORMAT_MP3_96 = 7; + FORMAT_MP3_160_ENCRYPTED = 8; + FORMAT_AAC_24 = 9; + FORMAT_AAC_48 = 10; + FORMAT_MP4_128 = 11; + FORMAT_MP4_128_DUAL = 12; + FORMAT_MP4_128_CBCS = 13; + FORMAT_MP4_256 = 14; + FORMAT_MP4_256_DUAL = 15; + FORMAT_MP4_256_CBCS = 16; + FORMAT_FLAC_FLAC = 17; + FORMAT_MP4_FLAC = 18; +} diff --git a/protocol/proto/frecency.proto b/protocol/proto/frecency.proto new file mode 100644 index 00000000..89c6c7f6 --- /dev/null +++ b/protocol/proto/frecency.proto @@ -0,0 +1,27 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.frecency.v1; + +import "google/protobuf/timestamp.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "FrecencyProto"; +option java_package = "com.spotify.frecency.v1"; + +message FrecencyResponse { + repeated PlayContext play_contexts = 1; +} + +message PlayContext { + string uri = 1; + Frecency frecency = 2; +} + +message Frecency { + double ln_frecency = 1; + int32 event_count = 2; + google.protobuf.Timestamp last_event_time = 3; +} diff --git a/protocol/proto/frecency_storage.proto b/protocol/proto/frecency_storage.proto new file mode 100644 index 00000000..9e32269f --- /dev/null +++ b/protocol/proto/frecency_storage.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.frecency.proto.storage; + +option cc_enable_arenas = true; +option optimize_for = CODE_SIZE; + +message Frecency { + optional double ln_frecency = 1; + optional uint64 event_count = 2; + optional uint32 event_kind = 3; + optional uint64 last_event_time = 4; +} + +message ContextFrecencyInfo { + optional string context_uri = 1; + repeated Frecency context_frecencies = 2; +} + +message ContextFrecencyFile { + repeated ContextFrecencyInfo contexts = 1; + optional uint64 frecency_version = 2; +} diff --git a/protocol/proto/gabito.proto b/protocol/proto/gabito.proto new file mode 100644 index 00000000..b47f4fdd --- /dev/null +++ b/protocol/proto/gabito.proto @@ -0,0 +1,36 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message EventEnvelope { + string event_name = 2; + + repeated EventFragment event_fragment = 3; + message EventFragment { + string name = 1; + bytes data = 2; + } + + bytes sequence_id = 4; + int64 sequence_number = 5; + + reserved 1; +} + +message PublishEventsRequest { + repeated EventEnvelope event = 1; + bool suppress_persist = 2; +} + +message PublishEventsResponse { + repeated EventError error = 1; + message EventError { + int32 index = 1; + bool transient = 2; + int32 reason = 3; + } +} diff --git a/protocol/proto/global_node.proto b/protocol/proto/global_node.proto new file mode 100644 index 00000000..cd6f1b6c --- /dev/null +++ b/protocol/proto/global_node.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_player_options.proto"; +import "player_license.proto"; + +option optimize_for = CODE_SIZE; + +message GlobalNode { + optional ContextPlayerOptions options = 1; + optional PlayerLicense license = 2; + map configuration = 3; +} diff --git a/protocol/proto/google/protobuf/any.proto b/protocol/proto/google/protobuf/any.proto new file mode 100644 index 00000000..bb7f136c --- /dev/null +++ b/protocol/proto/google/protobuf/any.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option go_package = "google.golang.org/protobuf/types/known/anypb"; +option java_multiple_files = true; +option java_outer_classname = "AnyProto"; +option java_package = "com.google.protobuf"; + +message Any { + string type_url = 1; + bytes value = 2; +} diff --git a/protocol/proto/google/protobuf/descriptor.proto b/protocol/proto/google/protobuf/descriptor.proto new file mode 100644 index 00000000..7f91c408 --- /dev/null +++ b/protocol/proto/google/protobuf/descriptor.proto @@ -0,0 +1,301 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.Reflection"; +option objc_class_prefix = "GPB"; +option cc_enable_arenas = true; +option go_package = "google.golang.org/protobuf/types/descriptorpb"; +option optimize_for = SPEED; +option java_outer_classname = "DescriptorProtos"; +option java_package = "com.google.protobuf"; + +message FileDescriptorSet { + repeated FileDescriptorProto file = 1; +} + +message FileDescriptorProto { + optional string name = 1; + optional string package = 2; + repeated string dependency = 3; + repeated int32 public_dependency = 10; + repeated int32 weak_dependency = 11; + repeated DescriptorProto message_type = 4; + repeated EnumDescriptorProto enum_type = 5; + repeated ServiceDescriptorProto service = 6; + repeated FieldDescriptorProto extension = 7; + optional FileOptions options = 8; + optional SourceCodeInfo source_code_info = 9; + optional string syntax = 12; +} + +message DescriptorProto { + optional string name = 1; + repeated FieldDescriptorProto field = 2; + repeated FieldDescriptorProto extension = 6; + repeated DescriptorProto nested_type = 3; + repeated EnumDescriptorProto enum_type = 4; + + repeated ExtensionRange extension_range = 5; + message ExtensionRange { + optional int32 start = 1; + optional int32 end = 2; + optional ExtensionRangeOptions options = 3; + } + + repeated OneofDescriptorProto oneof_decl = 8; + optional MessageOptions options = 7; + + repeated ReservedRange reserved_range = 9; + message ReservedRange { + optional int32 start = 1; + optional int32 end = 2; + } + + repeated string reserved_name = 10; +} + +message ExtensionRangeOptions { + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; +} + +message FieldDescriptorProto { + optional string name = 1; + optional int32 number = 3; + + optional Label label = 4; + enum Label { + LABEL_OPTIONAL = 1; + LABEL_REQUIRED = 2; + LABEL_REPEATED = 3; + } + + optional Type type = 5; + enum Type { + TYPE_DOUBLE = 1; + TYPE_FLOAT = 2; + TYPE_INT64 = 3; + TYPE_UINT64 = 4; + TYPE_INT32 = 5; + TYPE_FIXED64 = 6; + TYPE_FIXED32 = 7; + TYPE_BOOL = 8; + TYPE_STRING = 9; + TYPE_GROUP = 10; + TYPE_MESSAGE = 11; + TYPE_BYTES = 12; + TYPE_UINT32 = 13; + TYPE_ENUM = 14; + TYPE_SFIXED32 = 15; + TYPE_SFIXED64 = 16; + TYPE_SINT32 = 17; + TYPE_SINT64 = 18; + } + + optional string type_name = 6; + optional string extendee = 2; + optional string default_value = 7; + optional int32 oneof_index = 9; + optional string json_name = 10; + optional FieldOptions options = 8; + optional bool proto3_optional = 17; +} + +message OneofDescriptorProto { + optional string name = 1; + optional OneofOptions options = 2; +} + +message EnumDescriptorProto { + optional string name = 1; + repeated EnumValueDescriptorProto value = 2; + optional EnumOptions options = 3; + + repeated EnumReservedRange reserved_range = 4; + message EnumReservedRange { + optional int32 start = 1; + optional int32 end = 2; + } + + repeated string reserved_name = 5; +} + +message EnumValueDescriptorProto { + optional string name = 1; + optional int32 number = 2; + optional EnumValueOptions options = 3; +} + +message ServiceDescriptorProto { + optional string name = 1; + repeated MethodDescriptorProto method = 2; + optional ServiceOptions options = 3; +} + +message MethodDescriptorProto { + optional string name = 1; + optional string input_type = 2; + optional string output_type = 3; + optional MethodOptions options = 4; + optional bool client_streaming = 5 [default = false]; + optional bool server_streaming = 6 [default = false]; +} + +message FileOptions { + optional string java_package = 1; + optional string java_outer_classname = 8; + optional bool java_multiple_files = 10 [default = false]; + optional bool java_generate_equals_and_hash = 20 [deprecated = true]; + optional bool java_string_check_utf8 = 27 [default = false]; + + optional OptimizeMode optimize_for = 9 [default = SPEED]; + enum OptimizeMode { + SPEED = 1; + CODE_SIZE = 2; + LITE_RUNTIME = 3; + } + + optional string go_package = 11; + optional bool cc_generic_services = 16 [default = false]; + optional bool java_generic_services = 17 [default = false]; + optional bool py_generic_services = 18 [default = false]; + optional bool php_generic_services = 42 [default = false]; + optional bool deprecated = 23 [default = false]; + optional bool cc_enable_arenas = 31 [default = true]; + optional string objc_class_prefix = 36; + optional string csharp_namespace = 37; + optional string swift_prefix = 39; + optional string php_class_prefix = 40; + optional string php_namespace = 41; + optional string php_metadata_namespace = 44; + optional string ruby_package = 45; + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; + + reserved 38; +} + +message MessageOptions { + optional bool message_set_wire_format = 1 [default = false]; + optional bool no_standard_descriptor_accessor = 2 [default = false]; + optional bool deprecated = 3 [default = false]; + optional bool map_entry = 7; + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; + + reserved 8, 9; +} + +message FieldOptions { + optional CType ctype = 1 [default = STRING]; + enum CType { + STRING = 0; + CORD = 1; + STRING_PIECE = 2; + } + + optional bool packed = 2; + + optional JSType jstype = 6 [default = JS_NORMAL]; + enum JSType { + JS_NORMAL = 0; + JS_STRING = 1; + JS_NUMBER = 2; + } + + optional bool lazy = 5 [default = false]; + optional bool deprecated = 3 [default = false]; + optional bool weak = 10 [default = false]; + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; + + reserved 4; +} + +message OneofOptions { + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; +} + +message EnumOptions { + optional bool allow_alias = 2; + optional bool deprecated = 3 [default = false]; + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; + + reserved 5; +} + +message EnumValueOptions { + optional bool deprecated = 1 [default = false]; + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; +} + +message ServiceOptions { + optional bool deprecated = 33 [default = false]; + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; +} + +message MethodOptions { + optional bool deprecated = 33 [default = false]; + + optional IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN]; + enum IdempotencyLevel { + IDEMPOTENCY_UNKNOWN = 0; + NO_SIDE_EFFECTS = 1; + IDEMPOTENT = 2; + } + + repeated UninterpretedOption uninterpreted_option = 999; + + extensions 1000 to max; +} + +message UninterpretedOption { + repeated NamePart name = 2; + message NamePart { + required string name_part = 1; + required bool is_extension = 2; + } + + optional string identifier_value = 3; + optional uint64 positive_int_value = 4; + optional int64 negative_int_value = 5; + optional double double_value = 6; + optional bytes string_value = 7; + optional string aggregate_value = 8; +} + +message SourceCodeInfo { + repeated Location location = 1; + message Location { + repeated int32 path = 1 [packed = true]; + repeated int32 span = 2 [packed = true]; + optional string leading_comments = 3; + optional string trailing_comments = 4; + repeated string leading_detached_comments = 6; + } +} + +message GeneratedCodeInfo { + repeated Annotation annotation = 1; + message Annotation { + repeated int32 path = 1 [packed = true]; + optional string source_file = 2; + optional int32 begin = 3; + optional int32 end = 4; + } +} diff --git a/protocol/proto/google/protobuf/duration.proto b/protocol/proto/google/protobuf/duration.proto new file mode 100644 index 00000000..f7d01301 --- /dev/null +++ b/protocol/proto/google/protobuf/duration.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option cc_enable_arenas = true; +option go_package = "google.golang.org/protobuf/types/known/durationpb"; +option java_multiple_files = true; +option java_outer_classname = "DurationProto"; +option java_package = "com.google.protobuf"; + +message Duration { + int64 seconds = 1; + int32 nanos = 2; +} diff --git a/protocol/proto/google/protobuf/field_mask.proto b/protocol/proto/google/protobuf/field_mask.proto new file mode 100644 index 00000000..3ae48712 --- /dev/null +++ b/protocol/proto/google/protobuf/field_mask.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option cc_enable_arenas = true; +option go_package = "google.golang.org/protobuf/types/known/fieldmaskpb"; +option java_multiple_files = true; +option java_outer_classname = "FieldMaskProto"; +option java_package = "com.google.protobuf"; + +message FieldMask { + repeated string paths = 1; +} diff --git a/protocol/proto/google/protobuf/source_context.proto b/protocol/proto/google/protobuf/source_context.proto new file mode 100644 index 00000000..8449fd4b --- /dev/null +++ b/protocol/proto/google/protobuf/source_context.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option go_package = "google.golang.org/protobuf/types/known/sourcecontextpb"; +option java_multiple_files = true; +option java_outer_classname = "SourceContextProto"; +option java_package = "com.google.protobuf"; + +message SourceContext { + string file_name = 1; +} diff --git a/protocol/proto/google/protobuf/timestamp.proto b/protocol/proto/google/protobuf/timestamp.proto new file mode 100644 index 00000000..e402c47a --- /dev/null +++ b/protocol/proto/google/protobuf/timestamp.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option cc_enable_arenas = true; +option go_package = "google.golang.org/protobuf/types/known/timestamppb"; +option java_multiple_files = true; +option java_outer_classname = "TimestampProto"; +option java_package = "com.google.protobuf"; + +message Timestamp { + int64 seconds = 1; + int32 nanos = 2; +} diff --git a/protocol/proto/google/protobuf/type.proto b/protocol/proto/google/protobuf/type.proto new file mode 100644 index 00000000..38d7f2d1 --- /dev/null +++ b/protocol/proto/google/protobuf/type.proto @@ -0,0 +1,91 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +import "google/protobuf/any.proto"; +import "google/protobuf/source_context.proto"; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option cc_enable_arenas = true; +option go_package = "google.golang.org/protobuf/types/known/typepb"; +option java_multiple_files = true; +option java_outer_classname = "TypeProto"; +option java_package = "com.google.protobuf"; + +message Type { + string name = 1; + repeated Field fields = 2; + repeated string oneofs = 3; + repeated Option options = 4; + SourceContext source_context = 5; + Syntax syntax = 6; +} + +message Field { + Kind kind = 1; + enum Kind { + TYPE_UNKNOWN = 0; + TYPE_DOUBLE = 1; + TYPE_FLOAT = 2; + TYPE_INT64 = 3; + TYPE_UINT64 = 4; + TYPE_INT32 = 5; + TYPE_FIXED64 = 6; + TYPE_FIXED32 = 7; + TYPE_BOOL = 8; + TYPE_STRING = 9; + TYPE_GROUP = 10; + TYPE_MESSAGE = 11; + TYPE_BYTES = 12; + TYPE_UINT32 = 13; + TYPE_ENUM = 14; + TYPE_SFIXED32 = 15; + TYPE_SFIXED64 = 16; + TYPE_SINT32 = 17; + TYPE_SINT64 = 18; + } + + Cardinality cardinality = 2; + enum Cardinality { + CARDINALITY_UNKNOWN = 0; + CARDINALITY_OPTIONAL = 1; + CARDINALITY_REQUIRED = 2; + CARDINALITY_REPEATED = 3; + } + + int32 number = 3; + string name = 4; + string type_url = 6; + int32 oneof_index = 7; + bool packed = 8; + repeated Option options = 9; + string json_name = 10; + string default_value = 11; +} + +message Enum { + string name = 1; + repeated EnumValue enumvalue = 2; + repeated Option options = 3; + SourceContext source_context = 4; + Syntax syntax = 5; +} + +message EnumValue { + string name = 1; + int32 number = 2; + repeated Option options = 3; +} + +message Option { + string name = 1; + Any value = 2; +} + +enum Syntax { + SYNTAX_PROTO2 = 0; + SYNTAX_PROTO3 = 1; +} diff --git a/protocol/proto/google/protobuf/wrappers.proto b/protocol/proto/google/protobuf/wrappers.proto new file mode 100644 index 00000000..10e94ee0 --- /dev/null +++ b/protocol/proto/google/protobuf/wrappers.proto @@ -0,0 +1,49 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package google.protobuf; + +option csharp_namespace = "Google.Protobuf.WellKnownTypes"; +option objc_class_prefix = "GPB"; +option cc_enable_arenas = true; +option go_package = "google.golang.org/protobuf/types/known/wrapperspb"; +option java_multiple_files = true; +option java_outer_classname = "WrappersProto"; +option java_package = "com.google.protobuf"; + +message DoubleValue { + double value = 1; +} + +message FloatValue { + float value = 1; +} + +message Int64Value { + int64 value = 1; +} + +message UInt64Value { + uint64 value = 1; +} + +message Int32Value { + int32 value = 1; +} + +message UInt32Value { + uint32 value = 1; +} + +message BoolValue { + bool value = 1; +} + +message StringValue { + string value = 1; +} + +message BytesValue { + bytes value = 1; +} diff --git a/protocol/proto/identity.proto b/protocol/proto/identity.proto new file mode 100644 index 00000000..efd8b9e1 --- /dev/null +++ b/protocol/proto/identity.proto @@ -0,0 +1,37 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.identity.v3; + +import "google/protobuf/field_mask.proto"; +import "google/protobuf/wrappers.proto"; + +option optimize_for = CODE_SIZE; +option java_outer_classname = "IdentityV3"; +option java_package = "com.spotify.identity.proto.v3"; + +message Image { + int32 max_width = 1; + int32 max_height = 2; + string url = 3; +} + +message UserProfile { + google.protobuf.StringValue username = 1; + google.protobuf.StringValue name = 2; + repeated Image images = 3; + google.protobuf.BoolValue verified = 4; + google.protobuf.BoolValue edit_profile_disabled = 5; + google.protobuf.BoolValue report_abuse_disabled = 6; + google.protobuf.BoolValue abuse_reported_name = 7; + google.protobuf.BoolValue abuse_reported_image = 8; + google.protobuf.BoolValue has_spotify_name = 9; + google.protobuf.BoolValue has_spotify_image = 10; + google.protobuf.Int32Value color = 11; +} + +message UserProfileUpdateRequest { + google.protobuf.FieldMask mask = 1; + UserProfile user_profile = 2; +} diff --git a/protocol/proto/image-resolve.proto b/protocol/proto/image-resolve.proto new file mode 100644 index 00000000..d8befe97 --- /dev/null +++ b/protocol/proto/image-resolve.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.imageresolve.proto; + +option java_multiple_files = true; +option java_outer_classname = "ImageResolveProtos"; +option java_package = "com.spotify.imageresolve.proto"; + +message Collection { + bytes id = 1; + + repeated Projection projections = 2; + message Projection { + bytes id = 2; + int32 metadata_index = 3; + int32 url_template_index = 4; + } +} + +message ProjectionMetadata { + int32 width = 2; + int32 height = 3; + bool fetch_online = 4; + bool download_for_offline = 5; +} + +message ProjectionMap { + repeated string url_templates = 1; + repeated ProjectionMetadata projection_metas = 2; + repeated Collection collections = 3; +} diff --git a/protocol/proto/installation_data.proto b/protocol/proto/installation_data.proto new file mode 100644 index 00000000..083fe466 --- /dev/null +++ b/protocol/proto/installation_data.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message InstallationEntity { + int32 file_format_version = 1; + bytes encrypted_part = 2; +} + +message InstallationData { + string installation_id = 1; + string last_seen_device_id = 2; + int64 monotonic_clock_id = 3; +} diff --git a/protocol/proto/instrumentation_params.proto b/protocol/proto/instrumentation_params.proto new file mode 100644 index 00000000..b8e44f4a --- /dev/null +++ b/protocol/proto/instrumentation_params.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto.transfer; + +option optimize_for = CODE_SIZE; + +message InstrumentationParams { + repeated string interaction_ids = 6; + repeated string page_instance_ids = 7; +} diff --git a/protocol/proto/lfs_secret_provider.proto b/protocol/proto/lfs_secret_provider.proto new file mode 100644 index 00000000..0862181e --- /dev/null +++ b/protocol/proto/lfs_secret_provider.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.lfssecretprovider.proto; + +option optimize_for = CODE_SIZE; + +message GetSecretResponse { + bytes secret = 1; +} diff --git a/protocol/proto/liked_songs_tags_sync_state.proto b/protocol/proto/liked_songs_tags_sync_state.proto new file mode 100644 index 00000000..634f9d03 --- /dev/null +++ b/protocol/proto/liked_songs_tags_sync_state.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.collection.proto; + +option optimize_for = CODE_SIZE; + +message TagsSyncState { + string uri = 1; + bool sync_is_complete = 2; +} diff --git a/protocol/proto/listen_later_cosmos_response.proto b/protocol/proto/listen_later_cosmos_response.proto new file mode 100644 index 00000000..f71c577c --- /dev/null +++ b/protocol/proto/listen_later_cosmos_response.proto @@ -0,0 +1,28 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.listen_later_cosmos.proto; + +import "collection/episode_collection_state.proto"; +import "metadata/episode_metadata.proto"; +import "played_state/episode_played_state.proto"; +import "sync/episode_sync_state.proto"; + +option optimize_for = CODE_SIZE; + +message Episode { + optional string header = 1; + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 2; + optional cosmos_util.proto.EpisodeCollectionState episode_collection_state = 3; + optional cosmos_util.proto.EpisodeSyncState episode_offline_state = 4; + optional cosmos_util.proto.EpisodePlayState episode_played_state = 5; +} + +message EpisodesResponse { + optional uint32 unfiltered_length = 1; + optional uint32 unranged_length = 2; + repeated Episode episode = 3; + optional string offline_availability = 5; + optional uint32 offline_progress = 6; +} diff --git a/protocol/proto/local_bans_storage.proto b/protocol/proto/local_bans_storage.proto new file mode 100644 index 00000000..388f05b5 --- /dev/null +++ b/protocol/proto/local_bans_storage.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.collection.proto.storage; + +option optimize_for = CODE_SIZE; + +message BanItem { + required string item_uri = 1; + required string context_uri = 2; + required int64 timestamp = 3; +} + +message Bans { + repeated BanItem items = 1; +} diff --git a/protocol/proto/local_sync_cosmos.proto b/protocol/proto/local_sync_cosmos.proto new file mode 100644 index 00000000..cf6187f7 --- /dev/null +++ b/protocol/proto/local_sync_cosmos.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.local_sync_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message GetDevicesResponse { + repeated Device devices = 1; + message Device { + string name = 1; + string id = 2; + string endpoint = 3; + } +} diff --git a/protocol/proto/local_sync_state.proto b/protocol/proto/local_sync_state.proto new file mode 100644 index 00000000..630f1843 --- /dev/null +++ b/protocol/proto/local_sync_state.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.local_sync_state.proto; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.local_sync_state.proto"; + +message State { + string safe_secret = 1; +} diff --git a/protocol/proto/logging_params.proto b/protocol/proto/logging_params.proto new file mode 100644 index 00000000..1f11809d --- /dev/null +++ b/protocol/proto/logging_params.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message LoggingParams { + optional int64 command_initiated_time = 1; + optional int64 command_received_time = 2; + repeated string page_instance_ids = 3; + repeated string interaction_ids = 4; +} diff --git a/protocol/proto/mdata.proto b/protocol/proto/mdata.proto new file mode 100644 index 00000000..29faad9c --- /dev/null +++ b/protocol/proto/mdata.proto @@ -0,0 +1,43 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.mdata.proto; + +import "extension_kind.proto"; +import "google/protobuf/any.proto"; + +option cc_enable_arenas = true; +option optimize_for = CODE_SIZE; + +message LocalExtensionQuery { + extendedmetadata.ExtensionKind extension_kind = 1; + repeated string entity_uri = 2; +} + +message LocalBatchedEntityRequest { + repeated LocalExtensionQuery extension_query = 1; +} + +message LocalBatchedExtensionResponse { + repeated Extension extension = 1; + message Extension { + extendedmetadata.ExtensionKind extension_kind = 1; + repeated EntityExtension entity_extension = 2; + } + + message ExtensionHeader { + bool cache_valid = 1; + bool offline_valid = 2; + int32 status_code = 3; + bool is_empty = 4; + int64 cache_expiry_timestamp = 5; + int64 offline_expiry_timestamp = 6; + } + + message EntityExtension { + string entity_uri = 1; + ExtensionHeader header = 2; + google.protobuf.Any extension_data = 3; + } +} diff --git a/protocol/proto/mdata_cosmos.proto b/protocol/proto/mdata_cosmos.proto new file mode 100644 index 00000000..3c67357c --- /dev/null +++ b/protocol/proto/mdata_cosmos.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.mdata_cosmos.proto; + +import "extension_kind.proto"; + +option cc_enable_arenas = true; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.mdata.cosmos.proto"; + +message InvalidateCacheRequest { + extendedmetadata.ExtensionKind extension_kind = 1; + repeated string entity_uri = 2; +} + +message InvalidateCacheResponse { + +} diff --git a/protocol/proto/mdata_storage.proto b/protocol/proto/mdata_storage.proto new file mode 100644 index 00000000..8703fe54 --- /dev/null +++ b/protocol/proto/mdata_storage.proto @@ -0,0 +1,38 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.mdata.proto.storage; + +import "extension_kind.proto"; +import "google/protobuf/any.proto"; + +option cc_enable_arenas = true; +option optimize_for = CODE_SIZE; + +message CacheEntry { + extendedmetadata.ExtensionKind kind = 1; + google.protobuf.Any extension_data = 2; +} + +message CacheInfo { + int32 status_code = 1; + bool is_empty = 2; + uint64 cache_expiry = 3; + uint64 offline_expiry = 4; + string etag = 5; + fixed64 cache_checksum_lo = 6; + fixed64 cache_checksum_hi = 7; +} + +message OfflineLock { + uint64 lock_expiry = 1; +} + +message AudioFiles { + string file_id = 1; +} + +message TrackDescriptor { + int32 track_id = 1; +} diff --git a/protocol/proto/media_manifest.proto b/protocol/proto/media_manifest.proto new file mode 100644 index 00000000..a6a97681 --- /dev/null +++ b/protocol/proto/media_manifest.proto @@ -0,0 +1,55 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.media_manifest; + +option optimize_for = CODE_SIZE; + +message AudioFile { + enum Format { + OGG_VORBIS_96 = 0; + OGG_VORBIS_160 = 1; + OGG_VORBIS_320 = 2; + MP3_256 = 3; + MP3_320 = 4; + MP3_160 = 5; + MP3_96 = 6; + MP3_160_ENC = 7; + AAC_24 = 8; + AAC_48 = 9; + FLAC_FLAC = 16; + } +} + +message File { + int32 bitrate = 3; + string mime_type = 4; + + oneof file { + ExternalFile external_file = 1; + FileIdFile file_id_file = 2; + } + + message ExternalFile { + string method = 1; + string url = 2; + bytes body = 3; + bool is_webgate_endpoint = 4; + } + + message FileIdFile { + string file_id_hex = 1; + AudioFile.Format download_format = 2; + EncryptionType encryption = 3; + } +} + +message Files { + repeated File files = 1; +} + +enum EncryptionType { + NONE = 0; + AES = 1; +} diff --git a/protocol/proto/media_type.proto b/protocol/proto/media_type.proto new file mode 100644 index 00000000..5527922f --- /dev/null +++ b/protocol/proto/media_type.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +enum MediaType { + MEDIA_TYPE_UNSET = 0; + AUDIO = 1; + VIDEO = 2; +} diff --git a/protocol/proto/media_type_node.proto b/protocol/proto/media_type_node.proto new file mode 100644 index 00000000..0d0a5964 --- /dev/null +++ b/protocol/proto/media_type_node.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message MediaTypeNode { + optional string current_uri = 1; + optional string media_type = 2; + optional string media_manifest_id = 3; +} diff --git a/protocol/proto/mergedprofile.proto b/protocol/proto/mergedprofile.proto deleted file mode 100644 index e283e1de..00000000 --- a/protocol/proto/mergedprofile.proto +++ /dev/null @@ -1,10 +0,0 @@ -syntax = "proto2"; - -message MergedProfileRequest { -} - -message MergedProfileReply { - optional string username = 0x1; - optional string artistid = 0x2; -} - diff --git a/protocol/proto/metadata.proto b/protocol/proto/metadata.proto index 3812f94e..a6d3aded 100644 --- a/protocol/proto/metadata.proto +++ b/protocol/proto/metadata.proto @@ -1,266 +1,311 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + syntax = "proto2"; -message TopTracks { - optional string country = 0x1; - repeated Track track = 0x2; -} +package spotify.metadata; -message ActivityPeriod { - optional sint32 start_year = 0x1; - optional sint32 end_year = 0x2; - optional sint32 decade = 0x3; -} +option optimize_for = CODE_SIZE; +option java_outer_classname = "Metadata"; +option java_package = "com.spotify.metadata.proto"; message Artist { - optional bytes gid = 0x1; - optional string name = 0x2; - optional sint32 popularity = 0x3; - repeated TopTracks top_track = 0x4; - repeated AlbumGroup album_group = 0x5; - repeated AlbumGroup single_group = 0x6; - repeated AlbumGroup compilation_group = 0x7; - repeated AlbumGroup appears_on_group = 0x8; - repeated string genre = 0x9; - repeated ExternalId external_id = 0xa; - repeated Image portrait = 0xb; - repeated Biography biography = 0xc; - repeated ActivityPeriod activity_period = 0xd; - repeated Restriction restriction = 0xe; - repeated Artist related = 0xf; - optional bool is_portrait_album_cover = 0x10; - optional ImageGroup portrait_group = 0x11; -} - -message AlbumGroup { - repeated Album album = 0x1; -} - -message Date { - optional sint32 year = 0x1; - optional sint32 month = 0x2; - optional sint32 day = 0x3; - optional sint32 hour = 0x4; - optional sint32 minute = 0x5; + optional bytes gid = 1; + optional string name = 2; + optional sint32 popularity = 3; + repeated TopTracks top_track = 4; + repeated AlbumGroup album_group = 5; + repeated AlbumGroup single_group = 6; + repeated AlbumGroup compilation_group = 7; + repeated AlbumGroup appears_on_group = 8; + repeated string genre = 9; + repeated ExternalId external_id = 10; + repeated Image portrait = 11; + repeated Biography biography = 12; + repeated ActivityPeriod activity_period = 13; + repeated Restriction restriction = 14; + repeated Artist related = 15; + optional bool is_portrait_album_cover = 16; + optional ImageGroup portrait_group = 17; + repeated SalePeriod sale_period = 18; + repeated Availability availability = 20; } message Album { - optional bytes gid = 0x1; - optional string name = 0x2; - repeated Artist artist = 0x3; - optional Type typ = 0x4; + optional bytes gid = 1; + optional string name = 2; + repeated Artist artist = 3; + + optional Type type = 4; enum Type { - ALBUM = 0x1; - SINGLE = 0x2; - COMPILATION = 0x3; - EP = 0x4; + ALBUM = 1; + SINGLE = 2; + COMPILATION = 3; + EP = 4; + AUDIOBOOK = 5; + PODCAST = 6; } - optional string label = 0x5; - optional Date date = 0x6; - optional sint32 popularity = 0x7; - repeated string genre = 0x8; - repeated Image cover = 0x9; - repeated ExternalId external_id = 0xa; - repeated Disc disc = 0xb; - repeated string review = 0xc; - repeated Copyright copyright = 0xd; - repeated Restriction restriction = 0xe; - repeated Album related = 0xf; - repeated SalePeriod sale_period = 0x10; - optional ImageGroup cover_group = 0x11; + + optional string label = 5; + optional Date date = 6; + optional sint32 popularity = 7; + repeated string genre = 8; + repeated Image cover = 9; + repeated ExternalId external_id = 10; + repeated Disc disc = 11; + repeated string review = 12; + repeated Copyright copyright = 13; + repeated Restriction restriction = 14; + repeated Album related = 15; + repeated SalePeriod sale_period = 16; + optional ImageGroup cover_group = 17; + optional string original_title = 18; + optional string version_title = 19; + optional string type_str = 20; + repeated Availability availability = 23; } message Track { - optional bytes gid = 0x1; - optional string name = 0x2; - optional Album album = 0x3; - repeated Artist artist = 0x4; - optional sint32 number = 0x5; - optional sint32 disc_number = 0x6; - optional sint32 duration = 0x7; - optional sint32 popularity = 0x8; - optional bool explicit = 0x9; - repeated ExternalId external_id = 0xa; - repeated Restriction restriction = 0xb; - repeated AudioFile file = 0xc; - repeated Track alternative = 0xd; - repeated SalePeriod sale_period = 0xe; - repeated AudioFile preview = 0xf; + optional bytes gid = 1; + optional string name = 2; + optional Album album = 3; + repeated Artist artist = 4; + optional sint32 number = 5; + optional sint32 disc_number = 6; + optional sint32 duration = 7; + optional sint32 popularity = 8; + optional bool explicit = 9; + repeated ExternalId external_id = 10; + repeated Restriction restriction = 11; + repeated AudioFile file = 12; + repeated Track alternative = 13; + repeated SalePeriod sale_period = 14; + repeated AudioFile preview = 15; + repeated string tags = 16; + optional int64 earliest_live_timestamp = 17; + optional bool has_lyrics = 18; + repeated Availability availability = 19; + optional Licensor licensor = 21; + repeated string language_of_performance = 22; + repeated ContentRating content_rating = 25; + optional string original_title = 27; + optional string version_title = 28; + repeated ArtistWithRole artist_with_role = 32; +} + +message ArtistWithRole { + optional bytes artist_gid = 1; + optional string artist_name = 2; + + optional ArtistRole role = 3; + enum ArtistRole { + ARTIST_ROLE_UNKNOWN = 0; + ARTIST_ROLE_MAIN_ARTIST = 1; + ARTIST_ROLE_FEATURED_ARTIST = 2; + ARTIST_ROLE_REMIXER = 3; + ARTIST_ROLE_ACTOR = 4; + ARTIST_ROLE_COMPOSER = 5; + ARTIST_ROLE_CONDUCTOR = 6; + ARTIST_ROLE_ORCHESTRA = 7; + } +} + +message Show { + optional bytes gid = 1; + optional string name = 2; + optional string description = 64; + optional sint32 deprecated_popularity = 65; + optional string publisher = 66; + optional string language = 67; + optional bool explicit = 68; + optional ImageGroup cover_image = 69; + repeated Episode episode = 70; + repeated Copyright copyright = 71; + repeated Restriction restriction = 72; + repeated string keyword = 73; + + optional MediaType media_type = 74; + enum MediaType { + MIXED = 0; + AUDIO = 1; + VIDEO = 2; + } + + optional ConsumptionOrder consumption_order = 75; + enum ConsumptionOrder { + SEQUENTIAL = 1; + EPISODIC = 2; + RECENT = 3; + } + + repeated Availability availability = 78; + optional string trailer_uri = 83; + optional bool music_and_talk = 85; +} + +message Episode { + optional bytes gid = 1; + optional string name = 2; + optional sint32 duration = 7; + repeated AudioFile audio = 12; + optional string description = 64; + optional sint32 number = 65; + optional Date publish_time = 66; + optional sint32 deprecated_popularity = 67; + optional ImageGroup cover_image = 68; + optional string language = 69; + optional bool explicit = 70; + optional Show show = 71; + repeated VideoFile video = 72; + repeated VideoFile video_preview = 73; + repeated AudioFile audio_preview = 74; + repeated Restriction restriction = 75; + optional ImageGroup freeze_frame = 76; + repeated string keyword = 77; + optional bool allow_background_playback = 81; + repeated Availability availability = 82; + optional string external_url = 83; + + optional EpisodeType type = 87; + enum EpisodeType { + FULL = 0; + TRAILER = 1; + BONUS = 2; + } + + optional bool music_and_talk = 91; +} + +message Licensor { + optional bytes uuid = 1; +} + +message TopTracks { + optional string country = 1; + repeated Track track = 2; +} + +message ActivityPeriod { + optional sint32 start_year = 1; + optional sint32 end_year = 2; + optional sint32 decade = 3; +} + +message AlbumGroup { + repeated Album album = 1; +} + +message Date { + optional sint32 year = 1; + optional sint32 month = 2; + optional sint32 day = 3; + optional sint32 hour = 4; + optional sint32 minute = 5; } message Image { - optional bytes file_id = 0x1; - optional Size size = 0x2; + optional bytes file_id = 1; + + optional Size size = 2; enum Size { - DEFAULT = 0x0; - SMALL = 0x1; - LARGE = 0x2; - XLARGE = 0x3; + DEFAULT = 0; + SMALL = 1; + LARGE = 2; + XLARGE = 3; } - optional sint32 width = 0x3; - optional sint32 height = 0x4; + + optional sint32 width = 3; + optional sint32 height = 4; } message ImageGroup { - repeated Image image = 0x1; + repeated Image image = 1; } message Biography { - optional string text = 0x1; - repeated Image portrait = 0x2; - repeated ImageGroup portrait_group = 0x3; + optional string text = 1; + repeated Image portrait = 2; + repeated ImageGroup portrait_group = 3; } message Disc { - optional sint32 number = 0x1; - optional string name = 0x2; - repeated Track track = 0x3; + optional sint32 number = 1; + optional string name = 2; + repeated Track track = 3; } message Copyright { - optional Type typ = 0x1; + optional Type type = 1; enum Type { - P = 0x0; - C = 0x1; + P = 0; + C = 1; } - optional string text = 0x2; + + optional string text = 2; } message Restriction { + repeated Catalogue catalogue = 1; enum Catalogue { - AD = 0; - SUBSCRIPTION = 1; - CATALOGUE_ALL = 2; - SHUFFLE = 3; - COMMERCIAL = 4; + AD = 0; + SUBSCRIPTION = 1; + CATALOGUE_ALL = 2; + SHUFFLE = 3; + COMMERCIAL = 4; } + + optional Type type = 4; enum Type { - STREAMING = 0x0; + STREAMING = 0; + } + + repeated string catalogue_str = 5; + + oneof country_restriction { + string countries_allowed = 2; + string countries_forbidden = 3; } - repeated Catalogue catalogue = 0x1; - optional string countries_allowed = 0x2; - optional string countries_forbidden = 0x3; - optional Type typ = 0x4; - - repeated string catalogue_str = 0x5; } message Availability { - repeated string catalogue_str = 0x1; - optional Date start = 0x2; + repeated string catalogue_str = 1; + optional Date start = 2; } message SalePeriod { - repeated Restriction restriction = 0x1; - optional Date start = 0x2; - optional Date end = 0x3; + repeated Restriction restriction = 1; + optional Date start = 2; + optional Date end = 3; } message ExternalId { - optional string typ = 0x1; - optional string id = 0x2; + optional string type = 1; + optional string id = 2; } message AudioFile { - optional bytes file_id = 0x1; - optional Format format = 0x2; + optional bytes file_id = 1; + + optional Format format = 2; enum Format { - OGG_VORBIS_96 = 0x0; - OGG_VORBIS_160 = 0x1; - OGG_VORBIS_320 = 0x2; - MP3_256 = 0x3; - MP3_320 = 0x4; - MP3_160 = 0x5; - MP3_96 = 0x6; - MP3_160_ENC = 0x7; - // v4 - // AAC_24 = 0x8; - // AAC_48 = 0x9; - MP4_128_DUAL = 0x8; - OTHER3 = 0x9; - AAC_160 = 0xa; - AAC_320 = 0xb; - MP4_128 = 0xc; - OTHER5 = 0xd; + OGG_VORBIS_96 = 0; + OGG_VORBIS_160 = 1; + OGG_VORBIS_320 = 2; + MP3_256 = 3; + MP3_320 = 4; + MP3_160 = 5; + MP3_96 = 6; + MP3_160_ENC = 7; + AAC_24 = 8; + AAC_48 = 9; + FLAC_FLAC = 16; } } message VideoFile { - optional bytes file_id = 1; + optional bytes file_id = 1; } -// Podcast Protos -message Show { - enum MediaType { - MIXED = 0; - AUDIO = 1; - VIDEO = 2; - } - enum ConsumptionOrder { - SEQUENTIAL = 1; - EPISODIC = 2; - RECENT = 3; - } - enum PassthroughEnum { - UNKNOWN = 0; - NONE = 1; - ALLOWED = 2; - } - optional bytes gid = 0x1; - optional string name = 0x2; - optional string description = 0x40; - optional sint32 deprecated_popularity = 0x41; - optional string publisher = 0x42; - optional string language = 0x43; - optional bool explicit = 0x44; - optional ImageGroup covers = 0x45; - repeated Episode episode = 0x46; - repeated Copyright copyright = 0x47; - repeated Restriction restriction = 0x48; - repeated string keyword = 0x49; - optional MediaType media_type = 0x4A; - optional ConsumptionOrder consumption_order = 0x4B; - optional bool interpret_restriction_using_geoip = 0x4C; - repeated Availability availability = 0x4E; - optional string country_of_origin = 0x4F; - repeated Category categories = 0x50; - optional PassthroughEnum passthrough = 0x51; -} - -message Episode { - optional bytes gid = 0x1; - optional string name = 0x2; - optional sint32 duration = 0x7; - optional sint32 popularity = 0x8; - repeated AudioFile file = 0xc; - optional string description = 0x40; - optional sint32 number = 0x41; - optional Date publish_time = 0x42; - optional sint32 deprecated_popularity = 0x43; - optional ImageGroup covers = 0x44; - optional string language = 0x45; - optional bool explicit = 0x46; - optional Show show = 0x47; - repeated VideoFile video = 0x48; - repeated VideoFile video_preview = 0x49; - repeated AudioFile audio_preview = 0x4A; - repeated Restriction restriction = 0x4B; - optional ImageGroup freeze_frame = 0x4C; - repeated string keyword = 0x4D; - // Order of these two flags might be wrong! - optional bool suppress_monetization = 0x4E; - optional bool interpret_restriction_using_geoip = 0x4F; - - optional bool allow_background_playback = 0x51; - repeated Availability availability = 0x52; - optional string external_url = 0x53; - optional OriginalAudio original_audio = 0x54; -} - -message Category { - optional string name = 0x1; - repeated Category subcategories = 0x2; -} - -message OriginalAudio { - optional bytes uuid = 0x1; +message ContentRating { + optional string country = 1; + repeated string tag = 2; } diff --git a/protocol/proto/metadata/album_metadata.proto b/protocol/proto/metadata/album_metadata.proto new file mode 100644 index 00000000..5a7de5f9 --- /dev/null +++ b/protocol/proto/metadata/album_metadata.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "metadata/image_group.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message AlbumArtistMetadata { + optional string link = 1; + optional string name = 2; +} + +message AlbumMetadata { + repeated AlbumArtistMetadata artists = 1; + optional string link = 2; + optional string name = 3; + repeated string copyright = 4; + optional ImageGroup covers = 5; + optional uint32 year = 6; + optional uint32 num_discs = 7; + optional uint32 num_tracks = 8; + optional bool playability = 9; + optional bool is_premium_only = 10; +} diff --git a/protocol/proto/metadata/artist_metadata.proto b/protocol/proto/metadata/artist_metadata.proto new file mode 100644 index 00000000..4e5e9bfe --- /dev/null +++ b/protocol/proto/metadata/artist_metadata.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "metadata/image_group.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ArtistMetadata { + optional string link = 1; + optional string name = 2; + optional bool is_various_artists = 3; + optional ImageGroup portraits = 4; +} diff --git a/protocol/proto/metadata/episode_metadata.proto b/protocol/proto/metadata/episode_metadata.proto new file mode 100644 index 00000000..9f47deee --- /dev/null +++ b/protocol/proto/metadata/episode_metadata.proto @@ -0,0 +1,59 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "metadata/image_group.proto"; +import "podcast_segments.proto"; +import "podcast_subscription.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message EpisodeShowMetadata { + optional string link = 1; + optional string name = 2; + optional string publisher = 3; + optional ImageGroup covers = 4; +} + +message EpisodeMetadata { + optional EpisodeShowMetadata show = 1; + optional string link = 2; + optional string name = 3; + optional uint32 length = 4; + optional ImageGroup covers = 5; + optional string manifest_id = 6; + optional string description = 7; + optional int64 publish_date = 8; + optional ImageGroup freeze_frames = 9; + optional string language = 10; + optional bool available = 11; + + optional MediaType media_type_enum = 12; + enum MediaType { + VODCAST = 0; + AUDIO = 1; + VIDEO = 2; + } + + optional int32 number = 13; + optional bool backgroundable = 14; + optional string preview_manifest_id = 15; + optional bool is_explicit = 16; + optional string preview_id = 17; + + optional EpisodeType episode_type = 18; + enum EpisodeType { + UNKNOWN = 0; + FULL = 1; + TRAILER = 2; + BONUS = 3; + } + + optional bool is_music_and_talk = 19; + optional podcast_segments.PodcastSegments podcast_segments = 20; + optional podcast_paywalls.PodcastSubscription podcast_subscription = 21; +} diff --git a/protocol/proto/metadata/image_group.proto b/protocol/proto/metadata/image_group.proto new file mode 100644 index 00000000..310a408b --- /dev/null +++ b/protocol/proto/metadata/image_group.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ImageGroup { + optional string standard_link = 1; + optional string small_link = 2; + optional string large_link = 3; + optional string xlarge_link = 4; +} diff --git a/protocol/proto/metadata/show_metadata.proto b/protocol/proto/metadata/show_metadata.proto new file mode 100644 index 00000000..8beaf97b --- /dev/null +++ b/protocol/proto/metadata/show_metadata.proto @@ -0,0 +1,28 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "metadata/image_group.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ShowMetadata { + optional string link = 1; + optional string name = 2; + optional string description = 3; + optional uint32 popularity = 4; + optional string publisher = 5; + optional string language = 6; + optional bool is_explicit = 7; + optional ImageGroup covers = 8; + optional uint32 num_episodes = 9; + optional string consumption_order = 10; + optional int32 media_type_enum = 11; + repeated string copyright = 12; + optional string trailer_uri = 13; + optional bool is_music_and_talk = 14; +} diff --git a/protocol/proto/metadata/track_metadata.proto b/protocol/proto/metadata/track_metadata.proto new file mode 100644 index 00000000..08bff401 --- /dev/null +++ b/protocol/proto/metadata/track_metadata.proto @@ -0,0 +1,55 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "metadata/image_group.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message TrackAlbumArtistMetadata { + optional string link = 1; + optional string name = 2; +} + +message TrackAlbumMetadata { + optional TrackAlbumArtistMetadata artist = 1; + optional string link = 2; + optional string name = 3; + optional ImageGroup covers = 4; +} + +message TrackArtistMetadata { + optional string link = 1; + optional string name = 2; + optional ImageGroup portraits = 3; +} + +message TrackDescriptor { + optional string name = 1; +} + +message TrackMetadata { + optional TrackAlbumMetadata album = 1; + repeated TrackArtistMetadata artist = 2; + optional string link = 3; + optional string name = 4; + optional uint32 length = 5; + optional bool playable = 6; + optional uint32 disc_number = 7; + optional uint32 track_number = 8; + optional bool is_explicit = 9; + optional string preview_id = 10; + optional bool is_local = 11; + optional bool playable_local_track = 12; + optional bool has_lyrics = 13; + optional bool is_premium_only = 14; + optional bool locally_playable = 15; + optional string playable_track_link = 16; + optional uint32 popularity = 17; + optional bool is_19_plus_only = 18; + repeated TrackDescriptor track_descriptors = 19; +} diff --git a/protocol/proto/metadata_cosmos.proto b/protocol/proto/metadata_cosmos.proto new file mode 100644 index 00000000..f04e5957 --- /dev/null +++ b/protocol/proto/metadata_cosmos.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.metadata_cosmos.proto; + +import "metadata.proto"; + +option optimize_for = CODE_SIZE; +option java_outer_classname = "MetadataCosmos"; +option java_package = "com.spotify.metadata.cosmos.proto"; + +message MetadataItem { + oneof item { + sint32 error = 1; + metadata.Artist artist = 2; + metadata.Album album = 3; + metadata.Track track = 4; + metadata.Show show = 5; + metadata.Episode episode = 6; + } +} + +message MultiResponse { + repeated MetadataItem items = 1; +} + +message MultiRequest { + repeated string uris = 1; +} diff --git a/protocol/proto/modification_request.proto b/protocol/proto/modification_request.proto new file mode 100644 index 00000000..d35b613c --- /dev/null +++ b/protocol/proto/modification_request.proto @@ -0,0 +1,37 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message ModificationRequest { + optional string operation = 1; + optional string before = 2; + optional string after = 3; + optional string name = 4; + optional bool playlist = 5; + + optional Attributes attributes = 6; + message Attributes { + optional bool published = 1; + optional bool collaborative = 2; + optional string name = 3; + optional string description = 4; + optional string imageUri = 5; + optional string picture = 6; + } + + repeated string uris = 7; + repeated string rows = 8; + optional bool contents = 9; + optional string item_id = 10; +} + +message ModificationResponse { + optional bool success = 1; + optional string uri = 2; +} diff --git a/protocol/proto/net-fortune.proto b/protocol/proto/net-fortune.proto new file mode 100644 index 00000000..dbf476b2 --- /dev/null +++ b/protocol/proto/net-fortune.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.netfortune.proto; + +option optimize_for = CODE_SIZE; + +message NetFortuneResponse { + int32 advised_audio_bitrate = 1; +} + +message NetFortuneV2Response { + string predict_id = 1; + int32 estimated_max_bitrate = 2; +} diff --git a/protocol/proto/offline.proto b/protocol/proto/offline.proto new file mode 100644 index 00000000..b3d12491 --- /dev/null +++ b/protocol/proto/offline.proto @@ -0,0 +1,83 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.offline.proto; + +import "google/protobuf/duration.proto"; +import "google/protobuf/timestamp.proto"; + +option optimize_for = CODE_SIZE; + +message Capacity { + double total_space = 1; + double free_space = 2; + double offline_space = 3; + uint64 track_count = 4; + uint64 episode_count = 5; +} + +message Device { + string device_id = 1; + string cache_id = 2; + string name = 3; + int32 type = 4; + int32 platform = 5; + bool offline_enabled = 6; + Capacity capacity = 7; + google.protobuf.Timestamp updated_at = 9; + google.protobuf.Timestamp last_seen_at = 10; + bool removal_pending = 11; +} + +message Restrictions { + google.protobuf.Duration allowed_duration_tracks = 1; + uint64 max_tracks = 2; + google.protobuf.Duration allowed_duration_episodes = 3; + uint64 max_episodes = 4; +} + +message Resource { + string uri = 1; + ResourceState state = 2; + int32 progress = 3; + google.protobuf.Timestamp updated_at = 4; + string failure_message = 5; +} + +message DeviceKey { + string user_id = 1; + string device_id = 2; + string cache_id = 3; +} + +message ResourceForDevice { + string device_id = 1; + string cache_id = 2; + Resource resource = 3; +} + +message ResourceOperation { + Operation operation = 2; + enum Operation { + INVALID = 0; + ADD = 1; + REMOVE = 2; + } + + string uri = 3; +} + +message ResourceHistoryItem { + repeated ResourceOperation operations = 1; + google.protobuf.Timestamp server_time = 2; +} + +enum ResourceState { + UNSPECIFIED = 0; + REQUESTED = 1; + PENDING = 2; + DOWNLOADING = 3; + DOWNLOADED = 4; + FAILURE = 5; +} diff --git a/protocol/proto/offline_playlists_containing.proto b/protocol/proto/offline_playlists_containing.proto new file mode 100644 index 00000000..19106b0c --- /dev/null +++ b/protocol/proto/offline_playlists_containing.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message OfflinePlaylistContainingItem { + required string playlist_link = 1; + optional string playlist_name = 2; +} + +message OfflinePlaylistsContainingItemResponse { + repeated OfflinePlaylistContainingItem playlists = 1; +} diff --git a/protocol/proto/on_demand_in_free_reason.proto b/protocol/proto/on_demand_in_free_reason.proto new file mode 100644 index 00000000..bf3a820e --- /dev/null +++ b/protocol/proto/on_demand_in_free_reason.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.on_demand_set.proto; + +option optimize_for = CODE_SIZE; + +enum OnDemandInFreeReason { + UNKNOWN = 0; + NOT_ON_DEMAND = 1; + ON_DEMAND = 2; + ON_DEMAND_EPISODES_ONLY = 3; +} diff --git a/protocol/proto/on_demand_set_cosmos_request.proto b/protocol/proto/on_demand_set_cosmos_request.proto new file mode 100644 index 00000000..28b70c16 --- /dev/null +++ b/protocol/proto/on_demand_set_cosmos_request.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.on_demand_set_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message Set { + repeated string uris = 1; +} + +message Temporary { + optional string uri = 1; + optional int64 valid_for_in_seconds = 2; +} diff --git a/protocol/proto/on_demand_set_cosmos_response.proto b/protocol/proto/on_demand_set_cosmos_response.proto new file mode 100644 index 00000000..3e5d708f --- /dev/null +++ b/protocol/proto/on_demand_set_cosmos_response.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.on_demand_set_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message Response { + optional bool success = 1; +} diff --git a/protocol/proto/pin_request.proto b/protocol/proto/pin_request.proto new file mode 100644 index 00000000..23e064ad --- /dev/null +++ b/protocol/proto/pin_request.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +option optimize_for = CODE_SIZE; + +message PinRequest { + string uri = 1; +} + +message PinResponse { + PinStatus status = 1; + enum PinStatus { + UNKNOWN = 0; + PINNED = 1; + NOT_PINNED = 2; + } + + bool has_maximum_pinned_items = 2; + string error = 99; +} + +message PinItem { + string uri = 1; + bool in_library = 2; +} + +message PinList { + repeated PinItem item = 1; + string error = 99; +} diff --git a/protocol/proto/play_origin.proto b/protocol/proto/play_origin.proto new file mode 100644 index 00000000..53bb0706 --- /dev/null +++ b/protocol/proto/play_origin.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message PlayOrigin { + optional string feature_identifier = 1; + optional string feature_version = 2; + optional string view_uri = 3; + optional string external_referrer = 4; + optional string referrer_identifier = 5; + optional string device_identifier = 6; + repeated string feature_classes = 7; +} diff --git a/protocol/proto/play_queue_node.proto b/protocol/proto/play_queue_node.proto new file mode 100644 index 00000000..d79a9825 --- /dev/null +++ b/protocol/proto/play_queue_node.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_track.proto"; +import "track_instance.proto"; +import "track_instantiator.proto"; + +option optimize_for = CODE_SIZE; + +message PlayQueueNode { + repeated ContextTrack queue = 1; + optional TrackInstance instance = 2; + optional TrackInstantiator instantiator = 3; + optional uint32 next_uid = 4; + optional sint32 iteration = 5; +} diff --git a/protocol/proto/play_reason.proto b/protocol/proto/play_reason.proto new file mode 100644 index 00000000..6ebfc914 --- /dev/null +++ b/protocol/proto/play_reason.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +enum PlayReason { + REASON_UNSET = 0; + REASON_APP_LOAD = 1; + REASON_BACK_BTN = 2; + REASON_CLICK_ROW = 3; + REASON_CLICK_SIDE = 4; + REASON_END_PLAY = 5; + REASON_FWD_BTN = 6; + REASON_INTERRUPTED = 7; + REASON_LOGOUT = 8; + REASON_PLAY_BTN = 9; + REASON_POPUP = 10; + REASON_REMOTE = 11; + REASON_SONG_DONE = 12; + REASON_TRACK_DONE = 13; + REASON_TRACK_ERROR = 14; + REASON_PREVIEW = 15; + REASON_PLAY_REASON_UNKNOWN = 16; + REASON_URI_OPEN = 17; + REASON_BACKGROUNDED = 18; + REASON_OFFLINE = 19; + REASON_UNEXPECTED_EXIT = 20; + REASON_UNEXPECTED_EXIT_WHILE_PAUSED = 21; +} diff --git a/protocol/proto/play_source.proto b/protocol/proto/play_source.proto new file mode 100644 index 00000000..e4db2b9a --- /dev/null +++ b/protocol/proto/play_source.proto @@ -0,0 +1,47 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +enum PlaySource { + SOURCE_UNSET = 0; + SOURCE_ALBUM = 1; + SOURCE_ARTIST = 2; + SOURCE_ARTIST_RADIO = 3; + SOURCE_COLLECTION = 4; + SOURCE_DEVICE_SECTION = 5; + SOURCE_EXTERNAL_DEVICE = 6; + SOURCE_EXT_LINK = 7; + SOURCE_INBOX = 8; + SOURCE_LIBRARY = 9; + SOURCE_LIBRARY_COLLECTION = 10; + SOURCE_LIBRARY_COLLECTION_ALBUM = 11; + SOURCE_LIBRARY_COLLECTION_ARTIST = 12; + SOURCE_LIBRARY_COLLECTION_MISSING_ALBUM = 13; + SOURCE_LOCAL_FILES = 14; + SOURCE_PENDAD = 15; + SOURCE_PLAYLIST = 16; + SOURCE_PLAYLIST_OWNED_BY_OTHER_COLLABORATIVE = 17; + SOURCE_PLAYLIST_OWNED_BY_OTHER_NON_COLLABORATIVE = 18; + SOURCE_PLAYLIST_OWNED_BY_SELF_COLLABORATIVE = 19; + SOURCE_PLAYLIST_OWNED_BY_SELF_NON_COLLABORATIVE = 20; + SOURCE_PLAYLIST_FOLDER = 21; + SOURCE_PLAYLISTS = 22; + SOURCE_PLAY_QUEUE = 23; + SOURCE_PLUGIN_API = 24; + SOURCE_PROFILE = 25; + SOURCE_PURCHASES = 26; + SOURCE_RADIO = 27; + SOURCE_RTMP = 28; + SOURCE_SEARCH = 29; + SOURCE_SHOW = 30; + SOURCE_TEMP_PLAYLIST = 31; + SOURCE_TOPLIST = 32; + SOURCE_TRACK_SET = 33; + SOURCE_PLAY_SOURCE_UNKNOWN = 34; + SOURCE_QUICK_MENU = 35; +} diff --git a/protocol/proto/playback.proto b/protocol/proto/playback.proto new file mode 100644 index 00000000..94d8ae7e --- /dev/null +++ b/protocol/proto/playback.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto.transfer; + +import "context_track.proto"; + +option optimize_for = CODE_SIZE; + +message Playback { + optional int64 timestamp = 1; + optional int32 position_as_of_timestamp = 2; + optional double playback_speed = 3; + optional bool is_paused = 4; + optional ContextTrack current_track = 5; +} diff --git a/protocol/proto/playback_cosmos.proto b/protocol/proto/playback_cosmos.proto new file mode 100644 index 00000000..83a905fd --- /dev/null +++ b/protocol/proto/playback_cosmos.proto @@ -0,0 +1,105 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playback_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message VolumeRequest { + oneof source_or_system { + VolumeChangeSource source = 1; + bool system_initiated = 4; + } + + oneof action { + double volume = 2; + Step step = 3; + } + + enum Step { + option allow_alias = true; + up = 0; + UP = 0; + down = 1; + DOWN = 1; + } +} + +message VolumeResponse { + double volume = 1; +} + +message VolumeSubResponse { + double volume = 1; + VolumeChangeSource source = 2; + bool system_initiated = 3; +} + +message PositionResponseV1 { + int32 position = 1; +} + +message PositionResponseV2 { + int64 position = 1; +} + +message InfoResponse { + bool has_info = 1; + uint64 length_ms = 2; + uint64 position_ms = 3; + bool playing = 4; + bool buffering = 5; + int32 error = 6; + string file_id = 7; + string file_type = 8; + string resolved_content_url = 9; + int32 file_bitrate = 10; + string codec_name = 11; + double playback_speed = 12; + float gain_adjustment = 13; + bool has_loudness = 14; + float loudness = 15; + string file_origin = 16; + string strategy = 17; + int32 target_bitrate = 18; + int32 advised_bitrate = 19; + bool target_file_available = 20; +} + +message FormatsResponse { + repeated Format formats = 1; + message Format { + string enum_key = 1; + uint32 enum_value = 2; + bool supported = 3; + uint32 bitrate = 4; + string mime_type = 5; + } +} + +message GetFilesResponse { + repeated File files = 1; + message File { + string file_id = 1; + string format = 2; + uint32 bitrate = 3; + uint32 format_enum = 4; + } +} + +message DuckRequest { + Action action = 2; + enum Action { + START = 0; + STOP = 1; + } + + double volume = 3; + uint32 fade_duration_ms = 4; +} + +enum VolumeChangeSource { + USER = 0; + SYSTEM = 1; +} diff --git a/protocol/proto/playback_segments.proto b/protocol/proto/playback_segments.proto new file mode 100644 index 00000000..1f6f6ea8 --- /dev/null +++ b/protocol/proto/playback_segments.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_segments.playback; + +import "podcast_segments.proto"; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PlaybackSegmentsProto"; +option java_package = "com.spotify.podcastsegments.playback.proto"; + +message PlaybackSegments { + repeated PlaybackSegment playback_segments = 1; +} diff --git a/protocol/proto/played_state.proto b/protocol/proto/played_state.proto new file mode 100644 index 00000000..58990254 --- /dev/null +++ b/protocol/proto/played_state.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.played_state.proto; + +option optimize_for = CODE_SIZE; + +message PlayedStateItem { + optional string show_uri = 1; + optional string episode_uri = 2; + optional int32 resume_point = 3; + optional int32 last_played_at = 4; + optional bool is_latest = 5; + optional bool has_been_fully_played = 6; + optional bool has_been_synced = 7; + optional int32 episode_length = 8; +} + +message PlayedStateItems { + repeated PlayedStateItem item = 1; + optional uint64 last_server_sync_timestamp = 2; +} diff --git a/protocol/proto/played_state/episode_played_state.proto b/protocol/proto/played_state/episode_played_state.proto new file mode 100644 index 00000000..696b2e7a --- /dev/null +++ b/protocol/proto/played_state/episode_played_state.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "played_state/playability_restriction.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message EpisodePlayState { + optional uint32 time_left = 1; + optional bool is_playable = 2; + optional bool is_played = 3; + optional uint32 last_played_at = 4; + optional PlayabilityRestriction playability_restriction = 5 [default = UNKNOWN]; +} diff --git a/protocol/proto/played_state/playability_restriction.proto b/protocol/proto/played_state/playability_restriction.proto new file mode 100644 index 00000000..d6de6f4e --- /dev/null +++ b/protocol/proto/played_state/playability_restriction.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +enum PlayabilityRestriction { + UNKNOWN = 0; + NO_RESTRICTION = 1; + EXPLICIT_CONTENT = 2; + AGE_RESTRICTED = 3; + NOT_IN_CATALOGUE = 4; + NOT_AVAILABLE_OFFLINE = 5; +} diff --git a/protocol/proto/played_state/show_played_state.proto b/protocol/proto/played_state/show_played_state.proto new file mode 100644 index 00000000..08910f93 --- /dev/null +++ b/protocol/proto/played_state/show_played_state.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ShowPlayState { + optional string latest_played_episode_link = 1; +} diff --git a/protocol/proto/played_state/track_played_state.proto b/protocol/proto/played_state/track_played_state.proto new file mode 100644 index 00000000..3a8e4c86 --- /dev/null +++ b/protocol/proto/played_state/track_played_state.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +import "played_state/playability_restriction.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message TrackPlayState { + optional bool is_playable = 1; + optional PlayabilityRestriction playability_restriction = 2 [default = UNKNOWN]; +} diff --git a/protocol/proto/playedstate.proto b/protocol/proto/playedstate.proto new file mode 100644 index 00000000..fefce00f --- /dev/null +++ b/protocol/proto/playedstate.proto @@ -0,0 +1,40 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify_playedstate.proto; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playedstate.proto"; + +message PlayedStateItem { + optional Type type = 1; + optional bytes uri = 2; + optional int64 client_timestamp = 3; + optional int32 play_position = 4; + optional bool played = 5; + optional int32 duration = 6; +} + +message PlayedState { + optional int64 server_timestamp = 1; + optional bool truncated = 2; + repeated PlayedStateItem state = 3; +} + +message PlayedStateItemList { + repeated PlayedStateItem state = 1; +} + +message ContentId { + optional Type type = 1; + optional bytes uri = 2; +} + +message ContentIdList { + repeated ContentId contentIds = 1; +} + +enum Type { + EPISODE = 0; +} diff --git a/protocol/proto/player.proto b/protocol/proto/player.proto new file mode 100644 index 00000000..dfe5e5ab --- /dev/null +++ b/protocol/proto/player.proto @@ -0,0 +1,211 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.connectstate; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.connectstate.model"; + +message PlayerState { + int64 timestamp = 1; + string context_uri = 2; + string context_url = 3; + Restrictions context_restrictions = 4; + PlayOrigin play_origin = 5; + ContextIndex index = 6; + ProvidedTrack track = 7; + string playback_id = 8; + double playback_speed = 9; + int64 position_as_of_timestamp = 10; + int64 duration = 11; + bool is_playing = 12; + bool is_paused = 13; + bool is_buffering = 14; + bool is_system_initiated = 15; + ContextPlayerOptions options = 16; + Restrictions restrictions = 17; + Suppressions suppressions = 18; + repeated ProvidedTrack prev_tracks = 19; + repeated ProvidedTrack next_tracks = 20; + map context_metadata = 21; + map page_metadata = 22; + string session_id = 23; + string queue_revision = 24; + int64 position = 25; + string entity_uri = 26; + repeated ProvidedTrack reverse = 27; + repeated ProvidedTrack future = 28; + string audio_stream = 29; + bool is_optional = 30 [deprecated = true]; + int64 bitrate = 31 [deprecated = true]; + PlaybackQuality playback_quality = 32; +} + +message ProvidedTrack { + string uri = 1; + string uid = 2; + map metadata = 3; + repeated string removed = 4; + repeated string blocked = 5; + string provider = 6; + Restrictions restrictions = 7; + string album_uri = 8; + repeated string disallow_reasons = 9; + string artist_uri = 10; + repeated string disallow_undecided = 11; +} + +message ContextIndex { + uint32 page = 1; + uint32 track = 2; +} + +message Restrictions { + repeated string disallow_pausing_reasons = 1; + repeated string disallow_resuming_reasons = 2; + repeated string disallow_seeking_reasons = 3; + repeated string disallow_peeking_prev_reasons = 4; + repeated string disallow_peeking_next_reasons = 5; + repeated string disallow_skipping_prev_reasons = 6; + repeated string disallow_skipping_next_reasons = 7; + repeated string disallow_toggling_repeat_context_reasons = 8; + repeated string disallow_toggling_repeat_track_reasons = 9; + repeated string disallow_toggling_shuffle_reasons = 10; + repeated string disallow_set_queue_reasons = 11; + repeated string disallow_interrupting_playback_reasons = 12; + repeated string disallow_transferring_playback_reasons = 13; + repeated string disallow_remote_control_reasons = 14; + repeated string disallow_inserting_into_next_tracks_reasons = 15; + repeated string disallow_inserting_into_context_tracks_reasons = 16; + repeated string disallow_reordering_in_next_tracks_reasons = 17; + repeated string disallow_reordering_in_context_tracks_reasons = 18; + repeated string disallow_removing_from_next_tracks_reasons = 19; + repeated string disallow_removing_from_context_tracks_reasons = 20; + repeated string disallow_updating_context_reasons = 21; + repeated string disallow_playing_reasons = 22; + repeated string disallow_stopping_reasons = 23; +} + +message PlayOrigin { + string feature_identifier = 1; + string feature_version = 2; + string view_uri = 3; + string external_referrer = 4; + string referrer_identifier = 5; + string device_identifier = 6; + repeated string feature_classes = 7; +} + +message ContextPlayerOptions { + bool shuffling_context = 1; + bool repeating_context = 2; + bool repeating_track = 3; +} + +message Suppressions { + repeated string providers = 1; +} + +message InstrumentationParams { + repeated string interaction_ids = 6; + repeated string page_instance_ids = 7; +} + +message Playback { + int64 timestamp = 1; + int32 position_as_of_timestamp = 2; + double playback_speed = 3; + bool is_paused = 4; + ContextTrack current_track = 5; +} + +message Queue { + repeated ContextTrack tracks = 1; + bool is_playing_queue = 2; +} + +message Session { + PlayOrigin play_origin = 1; + Context context = 2; + string current_uid = 3; + ContextPlayerOptionOverrides option_overrides = 4; + Suppressions suppressions = 5; + InstrumentationParams instrumentation_params = 6; +} + +message TransferState { + ContextPlayerOptions options = 1; + Playback playback = 2; + Session current_session = 3; + Queue queue = 4; +} + +message ContextTrack { + string uri = 1; + string uid = 2; + bytes gid = 3; + map metadata = 4; +} + +message ContextPlayerOptionOverrides { + bool shuffling_context = 1; + bool repeating_context = 2; + bool repeating_track = 3; +} + +message Context { + string uri = 1; + string url = 2; + map metadata = 3; + Restrictions restrictions = 4; + repeated ContextPage pages = 5; + bool loading = 6; +} + +message ContextPage { + string page_url = 1; + string next_page_url = 2; + map metadata = 3; + repeated ContextTrack tracks = 4; + bool loading = 5; +} + +message PlayerQueue { + string revision = 1; + repeated ProvidedTrack next_tracks = 2; + repeated ProvidedTrack prev_tracks = 3; + ProvidedTrack track = 4; +} + +message PlaybackQuality { + BitrateLevel bitrate_level = 1; + BitrateStrategy strategy = 2; + BitrateLevel target_bitrate_level = 3; + bool target_bitrate_available = 4; + HiFiStatus hifi_status = 5; +} + +enum BitrateLevel { + unknown_bitrate_level = 0; + low = 1; + normal = 2; + high = 3; + very_high = 4; + hifi = 5; +} + +enum BitrateStrategy { + unknown_strategy = 0; + best_matching = 1; + backend_advised = 2; + offlined_file = 3; + cached_file = 4; + local_file = 5; +} + +enum HiFiStatus { + none = 0; + off = 1; + on = 2; +} diff --git a/protocol/proto/player_license.proto b/protocol/proto/player_license.proto new file mode 100644 index 00000000..3d0e905d --- /dev/null +++ b/protocol/proto/player_license.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message PlayerLicense { + optional string identifier = 1; +} diff --git a/protocol/proto/player_model.proto b/protocol/proto/player_model.proto new file mode 100644 index 00000000..6856ca0d --- /dev/null +++ b/protocol/proto/player_model.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "logging_params.proto"; + +option optimize_for = CODE_SIZE; + +message PlayerModel { + optional bool is_paused = 1; + optional uint64 hash = 2; + optional LoggingParams logging_params = 3; + + optional StartReason start_reason = 4; + enum StartReason { + REMOTE_TRANSFER = 0; + COMEBACK = 1; + PLAY_CONTEXT = 2; + PLAY_SPECIFIC_TRACK = 3; + TRACK_FINISHED = 4; + SKIP_TO_NEXT_TRACK = 5; + SKIP_TO_PREV_TRACK = 6; + ERROR = 7; + IGNORED = 8; + UNKNOWN = 9; + } +} diff --git a/protocol/proto/playlist4_external.proto b/protocol/proto/playlist4_external.proto new file mode 100644 index 00000000..0a5d7084 --- /dev/null +++ b/protocol/proto/playlist4_external.proto @@ -0,0 +1,239 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist4.proto; + +option optimize_for = CODE_SIZE; +option java_outer_classname = "Playlist4ApiProto"; +option java_package = "com.spotify.playlist4.proto"; + +message Item { + required string uri = 1; + optional ItemAttributes attributes = 2; +} + +message MetaItem { + optional bytes revision = 1; + optional ListAttributes attributes = 2; + optional int32 length = 3; + optional int64 timestamp = 4; + optional string owner_username = 5; +} + +message ListItems { + required int32 pos = 1; + required bool truncated = 2; + repeated Item items = 3; + repeated MetaItem meta_items = 4; +} + +message FormatListAttribute { + optional string key = 1; + optional string value = 2; +} + +message PictureSize { + optional string target_name = 1; + optional string url = 2; +} + +message ListAttributes { + optional string name = 1; + optional string description = 2; + optional bytes picture = 3; + optional bool collaborative = 4; + optional string pl3_version = 5; + optional bool deleted_by_owner = 6; + optional string client_id = 10; + optional string format = 11; + repeated FormatListAttribute format_attributes = 12; + repeated PictureSize picture_size = 13; +} + +message ItemAttributes { + optional string added_by = 1; + optional int64 timestamp = 2; + optional int64 seen_at = 9; + optional bool public = 10; + repeated FormatListAttribute format_attributes = 11; + optional bytes item_id = 12; +} + +message Add { + optional int32 from_index = 1; + repeated Item items = 2; + optional bool add_last = 4; + optional bool add_first = 5; +} + +message Rem { + optional int32 from_index = 1; + optional int32 length = 2; + repeated Item items = 3; + optional bool items_as_key = 7; +} + +message Mov { + required int32 from_index = 1; + required int32 length = 2; + required int32 to_index = 3; +} + +message ItemAttributesPartialState { + required ItemAttributes values = 1; + repeated ItemAttributeKind no_value = 2; +} + +message ListAttributesPartialState { + required ListAttributes values = 1; + repeated ListAttributeKind no_value = 2; +} + +message UpdateItemAttributes { + required int32 index = 1; + required ItemAttributesPartialState new_attributes = 2; + optional ItemAttributesPartialState old_attributes = 3; +} + +message UpdateListAttributes { + required ListAttributesPartialState new_attributes = 1; + optional ListAttributesPartialState old_attributes = 2; +} + +message Op { + required Kind kind = 1; + enum Kind { + KIND_UNKNOWN = 0; + ADD = 2; + REM = 3; + MOV = 4; + UPDATE_ITEM_ATTRIBUTES = 5; + UPDATE_LIST_ATTRIBUTES = 6; + } + + optional Add add = 2; + optional Rem rem = 3; + optional Mov mov = 4; + optional UpdateItemAttributes update_item_attributes = 5; + optional UpdateListAttributes update_list_attributes = 6; +} + +message OpList { + repeated Op ops = 1; +} + +message ChangeInfo { + optional string user = 1; + optional int64 timestamp = 2; + optional bool admin = 3; + optional bool undo = 4; + optional bool redo = 5; + optional bool merge = 6; + optional bool compressed = 7; + optional bool migration = 8; + optional int32 split_id = 9; + optional SourceInfo source = 10; +} + +message SourceInfo { + optional Client client = 1; + enum Client { + CLIENT_UNKNOWN = 0; + NATIVE_HERMES = 1; + CLIENT = 2; + PYTHON = 3; + JAVA = 4; + WEBPLAYER = 5; + LIBSPOTIFY = 6; + } + + optional string app = 3; + optional string source = 4; + optional string version = 5; +} + +message Delta { + optional bytes base_version = 1; + repeated Op ops = 2; + optional ChangeInfo info = 4; +} + +message Diff { + required bytes from_revision = 1; + repeated Op ops = 2; + required bytes to_revision = 3; +} + +message ListChanges { + optional bytes base_revision = 1; + repeated Delta deltas = 2; + optional bool want_resulting_revisions = 3; + optional bool want_sync_result = 4; + repeated int64 nonces = 6; +} + +message SelectedListContent { + optional bytes revision = 1; + optional int32 length = 2; + optional ListAttributes attributes = 3; + optional ListItems contents = 5; + optional Diff diff = 6; + optional Diff sync_result = 7; + repeated bytes resulting_revisions = 8; + optional bool multiple_heads = 9; + optional bool up_to_date = 10; + repeated int64 nonces = 14; + optional int64 timestamp = 15; + optional string owner_username = 16; + optional bool abuse_reporting_enabled = 17; +} + +message CreateListReply { + required bytes uri = 1; + optional bytes revision = 2; +} + +message ModifyReply { + required bytes uri = 1; + optional bytes revision = 2; +} + +message SubscribeRequest { + repeated bytes uris = 1; +} + +message UnsubscribeRequest { + repeated bytes uris = 1; +} + +message PlaylistModificationInfo { + optional bytes uri = 1; + optional bytes new_revision = 2; + optional bytes parent_revision = 3; + repeated Op ops = 4; +} + +enum ListAttributeKind { + LIST_UNKNOWN = 0; + LIST_NAME = 1; + LIST_DESCRIPTION = 2; + LIST_PICTURE = 3; + LIST_COLLABORATIVE = 4; + LIST_PL3_VERSION = 5; + LIST_DELETED_BY_OWNER = 6; + LIST_CLIENT_ID = 10; + LIST_FORMAT = 11; + LIST_FORMAT_ATTRIBUTES = 12; + LIST_PICTURE_SIZE = 13; +} + +enum ItemAttributeKind { + ITEM_UNKNOWN = 0; + ITEM_ADDED_BY = 1; + ITEM_TIMESTAMP = 2; + ITEM_SEEN_AT = 9; + ITEM_PUBLIC = 10; + ITEM_FORMAT_ATTRIBUTES = 11; + ITEM_ID = 12; +} diff --git a/protocol/proto/playlist_annotate3.proto b/protocol/proto/playlist_annotate3.proto new file mode 100644 index 00000000..3b6b919f --- /dev/null +++ b/protocol/proto/playlist_annotate3.proto @@ -0,0 +1,41 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto2"; + +package spotify_playlist_annotate3.proto; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist_annotate3.proto"; + +message TakedownRequest { + optional AbuseReportState abuse_report_state = 1; +} + +message AnnotateRequest { + optional string description = 1; + optional string image_uri = 2; +} + +message TranscodedPicture { + optional string target_name = 1; + optional string uri = 2; +} + +message PlaylistAnnotation { + optional string description = 1; + optional string picture = 2; + optional RenderFeatures deprecated_render_features = 3 [default = NORMAL_FEATURES, deprecated = true]; + repeated TranscodedPicture transcoded_picture = 4; + optional bool is_abuse_reporting_enabled = 6 [default = true]; + optional AbuseReportState abuse_report_state = 7 [default = OK]; +} + +enum RenderFeatures { + NORMAL_FEATURES = 1; + EXTENDED_FEATURES = 2; +} + +enum AbuseReportState { + OK = 0; + TAKEN_DOWN = 1; +} diff --git a/protocol/proto/playlist_folder_state.proto b/protocol/proto/playlist_folder_state.proto new file mode 100644 index 00000000..a2d32d71 --- /dev/null +++ b/protocol/proto/playlist_folder_state.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message FolderMetadata { + optional string id = 1; + optional string name = 2; + optional uint32 num_folders = 3; + optional uint32 num_playlists = 4; + optional uint32 num_recursive_folders = 5; + optional uint32 num_recursive_playlists = 6; + optional string link = 7; +} diff --git a/protocol/proto/playlist_get_request.proto b/protocol/proto/playlist_get_request.proto new file mode 100644 index 00000000..7e6dd3f0 --- /dev/null +++ b/protocol/proto/playlist_get_request.proto @@ -0,0 +1,26 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist_esperanto.proto; + +import "policy/playlist_request_decoration_policy.proto"; +import "playlist_query.proto"; +import "playlist_request.proto"; +import "response_status.proto"; + +option objc_class_prefix = "ESP"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.playlist.esperanto.proto"; + +message PlaylistGetRequest { + string uri = 1; + PlaylistQuery query = 2; + playlist.cosmos.proto.PlaylistRequestDecorationPolicy policy = 3; +} + +message PlaylistGetResponse { + ResponseStatus status = 1; + playlist.cosmos.playlist_request.proto.Response data = 2; +} diff --git a/protocol/proto/playlist_modification_request.proto b/protocol/proto/playlist_modification_request.proto new file mode 100644 index 00000000..2bdb0146 --- /dev/null +++ b/protocol/proto/playlist_modification_request.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist_esperanto.proto; + +import "modification_request.proto"; +import "response_status.proto"; + +option objc_class_prefix = "ESP"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.playlist.esperanto.proto"; + +message PlaylistModificationRequest { + string uri = 1; + playlist.cosmos.proto.ModificationRequest request = 2; +} + +message PlaylistModificationResponse { + ResponseStatus status = 1; +} diff --git a/protocol/proto/playlist_permission.proto b/protocol/proto/playlist_permission.proto new file mode 100644 index 00000000..babab040 --- /dev/null +++ b/protocol/proto/playlist_permission.proto @@ -0,0 +1,80 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist_permission.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message Permission { + optional bytes revision = 1; + optional PermissionLevel permission_level = 2; +} + +message Capabilities { + optional bool can_view = 1; + optional bool can_administrate_permissions = 2; + repeated PermissionLevel grantable_level = 3; + optional bool can_edit_metadata = 4; + optional bool can_edit_items = 5; +} + +message CapabilitiesMultiRequest { + repeated CapabilitiesRequest request = 1; + optional string fallback_username = 2; + optional string fallback_user_id = 3; + optional string fallback_uri = 4; +} + +message CapabilitiesRequest { + optional string username = 1; + optional string user_id = 2; + optional string uri = 3; + optional bool user_is_owner = 4; +} + +message CapabilitiesMultiResponse { + repeated CapabilitiesResponse response = 1; +} + +message CapabilitiesResponse { + optional ResponseStatus status = 1; + optional Capabilities capabilities = 2; +} + +message SetPermissionLevelRequest { + optional PermissionLevel permission_level = 1; +} + +message SetPermissionResponse { + optional Permission resulting_permission = 1; +} + +message Permissions { + optional Permission base_permission = 1; +} + +message PermissionState { + optional Permissions permissions = 1; + optional Capabilities capabilities = 2; + optional bool is_private = 3; + optional bool is_collaborative = 4; +} + +message PermissionStatePub { + optional PermissionState permission_state = 1; +} + +message ResponseStatus { + optional int32 status_code = 1; + optional string status_message = 2; +} + +enum PermissionLevel { + UNKNOWN = 0; + BLOCKED = 1; + VIEWER = 2; + CONTRIBUTOR = 3; +} diff --git a/protocol/proto/playlist_play_request.proto b/protocol/proto/playlist_play_request.proto new file mode 100644 index 00000000..032b2b2a --- /dev/null +++ b/protocol/proto/playlist_play_request.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist_esperanto.proto; + +import "es_context.proto"; +import "es_play_options.proto"; +import "es_logging_params.proto"; +import "es_prepare_play_options.proto"; +import "es_play_origin.proto"; +import "playlist_query.proto"; +import "response_status.proto"; + +option objc_class_prefix = "ESP"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.playlist.esperanto.proto"; + +message PlaylistPlayRequest { + PlaylistQuery playlist_query = 1; + player.esperanto.proto.Context context = 2; + player.esperanto.proto.PlayOptions play_options = 3; + player.esperanto.proto.LoggingParams logging_params = 4; + player.esperanto.proto.PreparePlayOptions prepare_play_options = 5; + player.esperanto.proto.PlayOrigin play_origin = 6; +} + +message PlaylistPlayResponse { + ResponseStatus status = 1; +} diff --git a/protocol/proto/playlist_playback_request.proto b/protocol/proto/playlist_playback_request.proto new file mode 100644 index 00000000..8cd20257 --- /dev/null +++ b/protocol/proto/playlist_playback_request.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message PlaybackResponse { + bool success = 1; +} diff --git a/protocol/proto/playlist_playlist_state.proto b/protocol/proto/playlist_playlist_state.proto new file mode 100644 index 00000000..4356fe65 --- /dev/null +++ b/protocol/proto/playlist_playlist_state.proto @@ -0,0 +1,50 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +import "metadata/image_group.proto"; +import "playlist_user_state.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message FormatListAttribute { + optional string key = 1; + optional string value = 2; +} + +message Allows { + optional bool can_insert = 1; + optional bool can_remove = 2; +} + +message PlaylistMetadata { + optional string link = 1; + optional string name = 2; + optional User owner = 3; + optional bool owned_by_self = 4; + optional bool collaborative = 5; + optional uint32 total_length = 6; + optional string description = 7; + optional cosmos_util.proto.ImageGroup pictures = 8; + optional bool followed = 9; + optional bool published = 10; + optional bool browsable_offline = 11; + optional bool description_from_annotate = 12; + optional bool picture_from_annotate = 13; + optional string format_list_type = 14; + repeated FormatListAttribute format_list_attributes = 15; + optional bool can_report_annotation_abuse = 16; + optional bool is_loaded = 17; + optional Allows allows = 18; + optional string load_state = 19; + optional User made_for = 20; +} + +message PlaylistOfflineState { + optional string offline = 1; + optional uint32 sync_progress = 2; +} diff --git a/protocol/proto/playlist_query.proto b/protocol/proto/playlist_query.proto new file mode 100644 index 00000000..afd97614 --- /dev/null +++ b/protocol/proto/playlist_query.proto @@ -0,0 +1,63 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.playlist.esperanto.proto"; + +message PlaylistRange { + int32 start = 1; + int32 length = 2; +} + +message PlaylistQuery { + repeated BoolPredicate bool_predicates = 1; + enum BoolPredicate { + NO_FILTER = 0; + AVAILABLE = 1; + AVAILABLE_OFFLINE = 2; + ARTIST_NOT_BANNED = 3; + NOT_BANNED = 4; + NOT_EXPLICIT = 5; + NOT_EPISODE = 6; + } + + string text_filter = 2; + + SortBy sort_by = 3; + enum SortBy { + NO_SORT = 0; + ALBUM_ARTIST_NAME_ASC = 1; + ALBUM_ARTIST_NAME_DESC = 2; + TRACK_NUMBER_ASC = 3; + TRACK_NUMBER_DESC = 4; + DISC_NUMBER_ASC = 5; + DISC_NUMBER_DESC = 6; + ALBUM_NAME_ASC = 7; + ALBUM_NAME_DESC = 8; + ARTIST_NAME_ASC = 9; + ARTIST_NAME_DESC = 10; + NAME_ASC = 11; + NAME_DESC = 12; + ADD_TIME_ASC = 13; + ADD_TIME_DESC = 14; + } + + PlaylistRange range = 4; + int32 update_throttling_ms = 5; + bool group = 6; + PlaylistSourceRestriction source_restriction = 7; + bool show_unavailable = 8; + bool always_show_windowed = 9; + bool load_recommendations = 10; +} + +enum PlaylistSourceRestriction { + NO_RESTRICTION = 0; + RESTRICT_SOURCE_TO_50 = 1; + RESTRICT_SOURCE_TO_500 = 2; +} diff --git a/protocol/proto/playlist_request.proto b/protocol/proto/playlist_request.proto new file mode 100644 index 00000000..cb452f63 --- /dev/null +++ b/protocol/proto/playlist_request.proto @@ -0,0 +1,89 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.playlist_request.proto; + +import "collection/episode_collection_state.proto"; +import "metadata/episode_metadata.proto"; +import "played_state/track_played_state.proto"; +import "played_state/episode_played_state.proto"; +import "sync/episode_sync_state.proto"; +import "metadata/image_group.proto"; +import "on_demand_in_free_reason.proto"; +import "playlist_permission.proto"; +import "playlist_playlist_state.proto"; +import "playlist_track_state.proto"; +import "playlist_user_state.proto"; +import "metadata/track_metadata.proto"; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message Item { + optional string header_field = 1; + optional uint32 add_time = 2; + optional cosmos.proto.User added_by = 3; + optional cosmos_util.proto.TrackMetadata track_metadata = 4; + optional cosmos.proto.TrackCollectionState track_collection_state = 5; + optional cosmos.proto.TrackOfflineState track_offline_state = 6; + optional string row_id = 7; + optional cosmos_util.proto.TrackPlayState track_play_state = 8; + repeated cosmos.proto.FormatListAttribute format_list_attributes = 9; + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 10; + optional cosmos_util.proto.EpisodeSyncState episode_offline_state = 11; + optional cosmos_util.proto.EpisodeCollectionState episode_collection_state = 12; + optional cosmos_util.proto.EpisodePlayState episode_play_state = 13; + optional cosmos_util.proto.ImageGroup display_covers = 14; +} + +message Playlist { + optional cosmos.proto.PlaylistMetadata playlist_metadata = 1; + optional cosmos.proto.PlaylistOfflineState playlist_offline_state = 2; +} + +message RecommendationItem { + optional cosmos_util.proto.TrackMetadata track_metadata = 1; + optional cosmos.proto.TrackCollectionState track_collection_state = 2; + optional cosmos.proto.TrackOfflineState track_offline_state = 3; + optional cosmos_util.proto.TrackPlayState track_play_state = 4; +} + +message Collaborator { + optional cosmos.proto.User user = 1; + optional uint32 number_of_items = 2; + optional uint32 number_of_tracks = 3; + optional uint32 number_of_episodes = 4; + optional bool is_owner = 5; +} + +message Collaborators { + optional uint32 count = 1; + repeated Collaborator collaborator = 2; +} + +message Response { + repeated Item item = 1; + optional Playlist playlist = 2; + optional uint32 unfiltered_length = 3; + optional uint32 unranged_length = 4; + optional uint64 duration = 5; + optional bool loading_contents = 6; + optional uint64 last_modification = 7; + optional uint32 num_followers = 8; + optional bool playable = 9; + repeated RecommendationItem recommendations = 10; + optional bool has_explicit_content = 11; + optional bool contains_spotify_tracks = 12; + optional bool contains_episodes = 13; + optional bool only_contains_explicit = 14; + optional bool contains_audio_episodes = 15; + optional bool contains_tracks = 16; + optional bool is_on_demand_in_free = 17; + optional uint32 number_of_tracks = 18; + optional uint32 number_of_episodes = 19; + optional bool prefer_linear_playback = 20; + optional on_demand_set.proto.OnDemandInFreeReason on_demand_in_free_reason = 21; + optional Collaborators collaborators = 22; + optional playlist_permission.proto.Permission base_permission = 23; +} diff --git a/protocol/proto/playlist_set_base_permission_request.proto b/protocol/proto/playlist_set_base_permission_request.proto new file mode 100644 index 00000000..3e8e1838 --- /dev/null +++ b/protocol/proto/playlist_set_base_permission_request.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist_esperanto.proto; + +import "playlist_set_permission_request.proto"; +import "response_status.proto"; + +option objc_class_prefix = "ESP"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.playlist.esperanto.proto"; + +message PlaylistSetBasePermissionRequest { + string uri = 1; + playlist.cosmos.proto.SetBasePermissionRequest request = 2; +} + +message PlaylistSetBasePermissionResponse { + ResponseStatus status = 1; + playlist.cosmos.proto.SetBasePermissionResponse response = 2; +} diff --git a/protocol/proto/playlist_set_permission_request.proto b/protocol/proto/playlist_set_permission_request.proto new file mode 100644 index 00000000..a410cc23 --- /dev/null +++ b/protocol/proto/playlist_set_permission_request.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +import "playlist_permission.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message SetBasePermissionRequest { + optional playlist_permission.proto.PermissionLevel permission_level = 1; + optional uint32 timeout_ms = 2; +} + +message SetBasePermissionResponse { + optional playlist_permission.proto.Permission base_permission = 1; +} diff --git a/protocol/proto/playlist_track_state.proto b/protocol/proto/playlist_track_state.proto new file mode 100644 index 00000000..5bd64ae2 --- /dev/null +++ b/protocol/proto/playlist_track_state.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message TrackCollectionState { + optional bool is_in_collection = 1; + optional bool can_add_to_collection = 2; + optional bool is_banned = 3; + optional bool can_ban = 4; +} + +message TrackOfflineState { + optional string offline = 1; +} diff --git a/protocol/proto/playlist_user_state.proto b/protocol/proto/playlist_user_state.proto new file mode 100644 index 00000000..510630ca --- /dev/null +++ b/protocol/proto/playlist_user_state.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message User { + optional string link = 1; + optional string username = 2; + optional string display_name = 3; + optional string image_uri = 4; + optional string thumbnail_uri = 5; +} diff --git a/protocol/proto/playlist_v1_uri.proto b/protocol/proto/playlist_v1_uri.proto new file mode 100644 index 00000000..76c9d797 --- /dev/null +++ b/protocol/proto/playlist_v1_uri.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message PlaylistV1UriRequest { + repeated string v2_uris = 1; +} + +message PlaylistV1UriReply { + map v2_uri_to_v1_uri = 1; +} diff --git a/protocol/proto/plugin.proto b/protocol/proto/plugin.proto new file mode 100644 index 00000000..c0e912ce --- /dev/null +++ b/protocol/proto/plugin.proto @@ -0,0 +1,141 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.offline.proto; + +import "google/protobuf/any.proto"; +import "extension_kind.proto"; +import "resource_type.proto"; + +option optimize_for = CODE_SIZE; + +message PluginRegistry { + repeated Entry plugins = 1; + message Entry { + string id = 1; + repeated LinkType supported_link_types = 2; + ResourceType resource_type = 3; + repeated extendedmetadata.ExtensionKind extension_kinds = 4; + } + + enum LinkType { + EMPTY = 0; + TRACK = 1; + EPISODE = 2; + } +} + +message PluginInit { + string id = 1; +} + +message TargetFormat { + int32 bitrate = 1; +} + +message Metadata { + Header header = 1; + message Header { + int32 status_code = 1; + bool is_empty = 2; + } + + google.protobuf.Any extension_data = 2; +} + +message IdentifyCommand { + Header header = 3; + message Header { + TargetFormat target_format = 1; + } + + repeated Query query = 4; + message Query { + string link = 1; + map metadata = 2; + } +} + +message IdentifyResponse { + map results = 1; + + message Result { + Status status = 1; + enum Status { + UNKNOWN = 0; + MISSING = 1; + COMPLETE = 2; + NOT_APPLICABLE = 3; + } + + int64 estimated_file_size = 2; + } +} + +message DownloadCommand { + string link = 1; + TargetFormat target_format = 2; + map metadata = 3; +} + +message DownloadResponse { + string link = 1; + bool complete = 2; + int64 file_size = 3; + int64 bytes_downloaded = 4; + + Error error = 5; + enum Error { + OK = 0; + TEMPORARY_ERROR = 1; + PERMANENT_ERROR = 2; + DISK_FULL = 3; + } +} + +message StopDownloadCommand { + string link = 1; +} + +message StopDownloadResponse { + +} + +message RemoveCommand { + Header header = 2; + message Header { + + } + + repeated Query query = 3; + message Query { + string link = 1; + } +} + +message RemoveResponse { + +} + +message PluginCommand { + string id = 1; + + oneof command { + IdentifyCommand identify = 2; + DownloadCommand download = 3; + RemoveCommand remove = 4; + StopDownloadCommand stop_download = 5; + } +} + +message PluginResponse { + string id = 1; + + oneof response { + IdentifyResponse identify = 2; + DownloadResponse download = 3; + RemoveResponse remove = 4; + StopDownloadResponse stop_download = 5; + } +} diff --git a/protocol/proto/podcast_ad_segments.proto b/protocol/proto/podcast_ad_segments.proto new file mode 100644 index 00000000..ebff7385 --- /dev/null +++ b/protocol/proto/podcast_ad_segments.proto @@ -0,0 +1,34 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.ads.formats; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PodcastAdsProto"; +option java_package = "com.spotify.ads.formats.proto"; + +message PodcastAds { + repeated string file_ids = 1; + repeated string manifest_ids = 2; + repeated Segment segments = 3; +} + +message Segment { + Slot slot = 1; + int32 start_ms = 2; + int32 stop_ms = 3; +} + +enum Slot { + UNKNOWN = 0; + PODCAST_PREROLL = 1; + PODCAST_POSTROLL = 2; + PODCAST_MIDROLL_1 = 3; + PODCAST_MIDROLL_2 = 4; + PODCAST_MIDROLL_3 = 5; + PODCAST_MIDROLL_4 = 6; + PODCAST_MIDROLL_5 = 7; +} diff --git a/protocol/proto/podcast_paywalls_cosmos.proto b/protocol/proto/podcast_paywalls_cosmos.proto new file mode 100644 index 00000000..9b818137 --- /dev/null +++ b/protocol/proto/podcast_paywalls_cosmos.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_paywalls_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message PodcastPaywallsShowSubscriptionRequest { + string show_uri = 1; +} + +message PodcastPaywallsShowSubscriptionResponse { + bool is_user_subscribed = 1; +} diff --git a/protocol/proto/podcast_poll.proto b/protocol/proto/podcast_poll.proto new file mode 100644 index 00000000..60dc04c6 --- /dev/null +++ b/protocol/proto/podcast_poll.proto @@ -0,0 +1,48 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.polls; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PollMetadataProto"; +option java_package = "com.spotify.podcastcreatorinteractivity.v1"; + +message PodcastPoll { + Poll poll = 1; +} + +message Poll { + int32 id = 1; + string opening_date = 2; + string closing_date = 3; + int32 entity_timestamp_ms = 4; + string entity_uri = 5; + string name = 6; + string question = 7; + PollType type = 8; + repeated PollOption options = 9; + PollStatus status = 10; +} + +message PollOption { + string option = 1; + int32 total_votes = 2; + int32 poll_id = 3; + int32 option_id = 4; +} + +enum PollType { + MULTIPLE_CHOICE = 0; + SINGLE_CHOICE = 1; +} + +enum PollStatus { + DRAFT = 0; + SCHEDULED = 1; + LIVE = 2; + CLOSED = 3; + BLOCKED = 4; +} diff --git a/protocol/proto/podcast_qna.proto b/protocol/proto/podcast_qna.proto new file mode 100644 index 00000000..fca3ba55 --- /dev/null +++ b/protocol/proto/podcast_qna.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.qanda; + +import "google/protobuf/timestamp.proto"; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "QnAMetadataProto"; +option java_package = "com.spotify.podcastcreatorinteractivity.v1"; + +message PodcastQna { + Prompt prompt = 1; +} + +message Prompt { + int32 id = 1; + google.protobuf.Timestamp opening_date = 2; + google.protobuf.Timestamp closing_date = 3; + string text = 4; + QAndAStatus status = 5; +} + +enum QAndAStatus { + DRAFT = 0; + SCHEDULED = 1; + LIVE = 2; + CLOSED = 3; + DELETED = 4; +} diff --git a/protocol/proto/podcast_segments.proto b/protocol/proto/podcast_segments.proto new file mode 100644 index 00000000..52a075f3 --- /dev/null +++ b/protocol/proto/podcast_segments.proto @@ -0,0 +1,47 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_segments; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PodcastSegmentsProto"; +option java_package = "com.spotify.podcastsegments.proto"; + +message PodcastSegments { + string episode_uri = 1; + repeated PlaybackSegment playback_segments = 2; + repeated EmbeddedSegment embedded_segments = 3; + bool can_upsell = 4; + string album_mosaic_uri = 5; + repeated string artists = 6; + int32 duration_ms = 7; +} + +message PlaybackSegment { + string uri = 1; + int32 start_ms = 2; + int32 stop_ms = 3; + int32 duration_ms = 4; + SegmentType type = 5; + string title = 6; + string subtitle = 7; + string image_url = 8; + string action_url = 9; + bool is_abridged = 10; +} + +message EmbeddedSegment { + string uri = 1; + int32 absolute_start_ms = 2; + int32 absolute_stop_ms = 3; +} + +enum SegmentType { + UNKNOWN = 0; + TALK = 1; + MUSIC = 2; + UPSELL = 3; +} diff --git a/protocol/proto/podcast_segments_cosmos_request.proto b/protocol/proto/podcast_segments_cosmos_request.proto new file mode 100644 index 00000000..1d5a51f4 --- /dev/null +++ b/protocol/proto/podcast_segments_cosmos_request.proto @@ -0,0 +1,37 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_segments.cosmos.proto; + +import "policy/album_decoration_policy.proto"; +import "policy/artist_decoration_policy.proto"; +import "policy/episode_decoration_policy.proto"; +import "policy/track_decoration_policy.proto"; +import "policy/show_decoration_policy.proto"; + +option optimize_for = CODE_SIZE; + +message SegmentsRequest { + repeated string episode_uris = 1; + TrackDecorationPolicy track_decoration_policy = 2; + SegmentsPolicy segments_policy = 3; + EpisodeDecorationPolicy episode_decoration_policy = 4; +} + +message TrackDecorationPolicy { + cosmos_util.proto.TrackDecorationPolicy track_policy = 1; + cosmos_util.proto.ArtistDecorationPolicy artists_policy = 2; + cosmos_util.proto.AlbumDecorationPolicy album_policy = 3; + cosmos_util.proto.ArtistDecorationPolicy album_artist_policy = 4; +} + +message SegmentsPolicy { + bool playback = 1; + bool embedded = 2; +} + +message EpisodeDecorationPolicy { + cosmos_util.proto.EpisodeDecorationPolicy episode_policy = 1; + cosmos_util.proto.ShowDecorationPolicy show_decoration_policy = 2; +} diff --git a/protocol/proto/podcast_segments_cosmos_response.proto b/protocol/proto/podcast_segments_cosmos_response.proto new file mode 100644 index 00000000..a80f7270 --- /dev/null +++ b/protocol/proto/podcast_segments_cosmos_response.proto @@ -0,0 +1,39 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_segments.cosmos.proto; + +import "metadata/episode_metadata.proto"; +import "podcast_segments.proto"; +import "metadata/track_metadata.proto"; + +option optimize_for = CODE_SIZE; + +message SegmentsResponse { + bool success = 1; + repeated EpisodeSegments episode_segments = 2; +} + +message EpisodeSegments { + string episode_uri = 1; + repeated DecoratedSegment segments = 2; + bool can_upsell = 3; + string album_mosaic_uri = 4; + repeated string artists = 5; + int32 duration_ms = 6; +} + +message DecoratedSegment { + string uri = 1; + int32 start_ms = 2; + int32 stop_ms = 3; + cosmos_util.proto.TrackMetadata track_metadata = 4; + SegmentType type = 5; + string title = 6; + string subtitle = 7; + string image_url = 8; + string action_url = 9; + cosmos_util.proto.EpisodeMetadata episode_metadata = 10; + bool is_abridged = 11; +} diff --git a/protocol/proto/podcast_subscription.proto b/protocol/proto/podcast_subscription.proto new file mode 100644 index 00000000..52b7f8f3 --- /dev/null +++ b/protocol/proto/podcast_subscription.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_paywalls; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PodcastSubscriptionProto"; +option java_package = "com.spotify.podcastsubscription.proto"; + +message PodcastSubscription { + bool is_paywalled = 1; + bool is_user_subscribed = 2; + + UserExplanation user_explanation = 3; + enum UserExplanation { + SUBSCRIPTION_DIALOG = 0; + NONE = 1; + } +} diff --git a/protocol/proto/podcast_virality.proto b/protocol/proto/podcast_virality.proto new file mode 100644 index 00000000..902dca90 --- /dev/null +++ b/protocol/proto/podcast_virality.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcastvirality.v1; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PodcastViralityProto"; +option java_package = "com.spotify.podcastvirality.proto.v1"; + +message PodcastVirality { + bool is_viral = 1; +} diff --git a/protocol/proto/podcastextensions.proto b/protocol/proto/podcastextensions.proto new file mode 100644 index 00000000..4c85e396 --- /dev/null +++ b/protocol/proto/podcastextensions.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast.extensions; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "PodcastExtensionsProto"; +option java_package = "com.spotify.podcastextensions.proto"; + +message PodcastTopics { + repeated PodcastTopic topics = 1; +} + +message PodcastTopic { + string uri = 1; + string title = 2; +} + +message PodcastHtmlDescription { + Header header = 1; + message Header { + + } + + string html_description = 2; +} diff --git a/protocol/proto/policy/album_decoration_policy.proto b/protocol/proto/policy/album_decoration_policy.proto new file mode 100644 index 00000000..a20cf324 --- /dev/null +++ b/protocol/proto/policy/album_decoration_policy.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.policy.proto"; + +message AlbumDecorationPolicy { + bool link = 1; + bool name = 2; + bool copyrights = 3; + bool covers = 4; + bool year = 5; + bool num_discs = 6; + bool num_tracks = 7; + bool playability = 8; + bool is_premium_only = 9; +} diff --git a/protocol/proto/policy/artist_decoration_policy.proto b/protocol/proto/policy/artist_decoration_policy.proto new file mode 100644 index 00000000..f8d8b2cb --- /dev/null +++ b/protocol/proto/policy/artist_decoration_policy.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.policy.proto"; + +message ArtistDecorationPolicy { + bool link = 1; + bool name = 2; + bool is_various_artists = 3; + bool portraits = 4; +} diff --git a/protocol/proto/policy/episode_decoration_policy.proto b/protocol/proto/policy/episode_decoration_policy.proto new file mode 100644 index 00000000..77489834 --- /dev/null +++ b/protocol/proto/policy/episode_decoration_policy.proto @@ -0,0 +1,58 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.policy.proto"; + +message EpisodeDecorationPolicy { + bool link = 1; + bool length = 2; + bool name = 3; + bool manifest_id = 4; + bool preview_id = 5; + bool preview_manifest_id = 6; + bool description = 7; + bool publish_date = 8; + bool covers = 9; + bool freeze_frames = 10; + bool language = 11; + bool available = 12; + bool media_type_enum = 13; + bool number = 14; + bool backgroundable = 15; + bool is_explicit = 16; + bool type = 17; + bool is_music_and_talk = 18; + PodcastSegmentsPolicy podcast_segments = 19; + bool podcast_subscription = 20; +} + +message EpisodeCollectionDecorationPolicy { + bool is_following_show = 1; + bool is_in_listen_later = 2; + bool is_new = 3; +} + +message EpisodeSyncDecorationPolicy { + bool offline = 1; + bool sync_progress = 2; +} + +message EpisodePlayedStateDecorationPolicy { + bool time_left = 1; + bool is_played = 2; + bool playable = 3; + bool playability_restriction = 4; +} + +message PodcastSegmentsPolicy { + bool playback_segments = 1; + bool embedded_segments = 2; + bool can_upsell = 3; + bool album_mosaic_uri = 4; + bool artists = 5; +} diff --git a/protocol/proto/policy/folder_decoration_policy.proto b/protocol/proto/policy/folder_decoration_policy.proto new file mode 100644 index 00000000..0d47e4d6 --- /dev/null +++ b/protocol/proto/policy/folder_decoration_policy.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message FolderDecorationPolicy { + bool row_id = 1; + bool id = 2; + bool link = 3; + bool name = 4; + bool folders = 5; + bool playlists = 6; + bool recursive_folders = 7; + bool recursive_playlists = 8; + bool rows = 9; +} diff --git a/protocol/proto/policy/playlist_album_decoration_policy.proto b/protocol/proto/policy/playlist_album_decoration_policy.proto new file mode 100644 index 00000000..01537c78 --- /dev/null +++ b/protocol/proto/policy/playlist_album_decoration_policy.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +import "policy/album_decoration_policy.proto"; +import "policy/artist_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message PlaylistAlbumDecorationPolicy { + cosmos_util.proto.AlbumDecorationPolicy album = 1; + cosmos_util.proto.ArtistDecorationPolicy artist = 2; +} diff --git a/protocol/proto/policy/playlist_decoration_policy.proto b/protocol/proto/policy/playlist_decoration_policy.proto new file mode 100644 index 00000000..9975279c --- /dev/null +++ b/protocol/proto/policy/playlist_decoration_policy.proto @@ -0,0 +1,60 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +import "policy/user_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message PlaylistAllowsDecorationPolicy { + bool insert = 1; + bool remove = 2; +} + +message PlaylistDecorationPolicy { + bool row_id = 1; + bool link = 2; + bool name = 3; + bool load_state = 4; + bool loaded = 5; + bool collaborative = 6; + bool length = 7; + bool last_modification = 8; + bool total_length = 9; + bool duration = 10; + bool description = 11; + bool picture = 12; + bool playable = 13; + bool description_from_annotate = 14; + bool picture_from_annotate = 15; + bool can_report_annotation_abuse = 16; + bool followed = 17; + bool followers = 18; + bool owned_by_self = 19; + bool offline = 20; + bool sync_progress = 21; + bool published = 22; + bool browsable_offline = 23; + bool format_list_type = 24; + bool format_list_attributes = 25; + bool has_explicit_content = 26; + bool contains_spotify_tracks = 27; + bool contains_tracks = 28; + bool contains_episodes = 29; + bool contains_audio_episodes = 30; + bool only_contains_explicit = 31; + bool is_on_demand_in_free = 32; + UserDecorationPolicy owner = 33; + UserDecorationPolicy made_for = 34; + PlaylistAllowsDecorationPolicy allows = 35; + bool number_of_episodes = 36; + bool number_of_tracks = 37; + bool prefer_linear_playback = 38; + bool on_demand_in_free_reason = 39; + CollaboratingUsersDecorationPolicy collaborating_users = 40; + bool base_permission = 41; +} diff --git a/protocol/proto/policy/playlist_episode_decoration_policy.proto b/protocol/proto/policy/playlist_episode_decoration_policy.proto new file mode 100644 index 00000000..4e038944 --- /dev/null +++ b/protocol/proto/policy/playlist_episode_decoration_policy.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +import "policy/episode_decoration_policy.proto"; +import "policy/show_decoration_policy.proto"; +import "policy/user_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message PlaylistEpisodeDecorationPolicy { + cosmos_util.proto.EpisodeDecorationPolicy episode = 1; + bool row_id = 2; + bool add_time = 3; + bool format_list_attributes = 4; + cosmos_util.proto.EpisodeCollectionDecorationPolicy collection = 5; + cosmos_util.proto.EpisodeSyncDecorationPolicy sync = 6; + cosmos_util.proto.EpisodePlayedStateDecorationPolicy played_state = 7; + UserDecorationPolicy added_by = 8; + cosmos_util.proto.ShowDecorationPolicy show = 9; +} diff --git a/protocol/proto/policy/playlist_request_decoration_policy.proto b/protocol/proto/policy/playlist_request_decoration_policy.proto new file mode 100644 index 00000000..a1663d28 --- /dev/null +++ b/protocol/proto/policy/playlist_request_decoration_policy.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +import "policy/playlist_decoration_policy.proto"; +import "policy/playlist_episode_decoration_policy.proto"; +import "policy/playlist_track_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message PlaylistRequestDecorationPolicy { + PlaylistDecorationPolicy playlist = 1; + PlaylistTrackDecorationPolicy track = 2; + PlaylistEpisodeDecorationPolicy episode = 3; +} diff --git a/protocol/proto/policy/playlist_track_decoration_policy.proto b/protocol/proto/policy/playlist_track_decoration_policy.proto new file mode 100644 index 00000000..97eb0187 --- /dev/null +++ b/protocol/proto/policy/playlist_track_decoration_policy.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +import "policy/artist_decoration_policy.proto"; +import "policy/track_decoration_policy.proto"; +import "policy/playlist_album_decoration_policy.proto"; +import "policy/user_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message PlaylistTrackDecorationPolicy { + cosmos_util.proto.TrackDecorationPolicy track = 1; + bool row_id = 2; + bool add_time = 3; + bool in_collection = 4; + bool can_add_to_collection = 5; + bool is_banned = 6; + bool can_ban = 7; + bool local_file = 8; + bool offline = 9; + bool format_list_attributes = 10; + bool display_covers = 11; + UserDecorationPolicy added_by = 12; + PlaylistAlbumDecorationPolicy album = 13; + cosmos_util.proto.ArtistDecorationPolicy artist = 14; +} diff --git a/protocol/proto/policy/rootlist_folder_decoration_policy.proto b/protocol/proto/policy/rootlist_folder_decoration_policy.proto new file mode 100644 index 00000000..f93888b4 --- /dev/null +++ b/protocol/proto/policy/rootlist_folder_decoration_policy.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +import "policy/folder_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message RootlistFolderDecorationPolicy { + optional bool add_time = 1; + optional FolderDecorationPolicy folder = 2; + optional bool group_label = 3; +} diff --git a/protocol/proto/policy/rootlist_playlist_decoration_policy.proto b/protocol/proto/policy/rootlist_playlist_decoration_policy.proto new file mode 100644 index 00000000..9e8446ab --- /dev/null +++ b/protocol/proto/policy/rootlist_playlist_decoration_policy.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +import "policy/playlist_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message RootlistPlaylistDecorationPolicy { + optional bool add_time = 1; + optional PlaylistDecorationPolicy playlist = 2; + optional bool group_label = 3; +} diff --git a/protocol/proto/policy/rootlist_request_decoration_policy.proto b/protocol/proto/policy/rootlist_request_decoration_policy.proto new file mode 100644 index 00000000..ebad00ca --- /dev/null +++ b/protocol/proto/policy/rootlist_request_decoration_policy.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.proto; + +import "policy/rootlist_folder_decoration_policy.proto"; +import "policy/rootlist_playlist_decoration_policy.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message RootlistRequestDecorationPolicy { + optional bool unfiltered_length = 1; + optional bool unranged_length = 2; + optional bool is_loading_contents = 3; + optional RootlistPlaylistDecorationPolicy playlist = 4; + optional RootlistFolderDecorationPolicy folder = 5; +} diff --git a/protocol/proto/policy/show_decoration_policy.proto b/protocol/proto/policy/show_decoration_policy.proto new file mode 100644 index 00000000..02ae2f3e --- /dev/null +++ b/protocol/proto/policy/show_decoration_policy.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.policy.proto"; + +message ShowDecorationPolicy { + bool link = 1; + bool name = 2; + bool description = 3; + bool popularity = 4; + bool publisher = 5; + bool language = 6; + bool is_explicit = 7; + bool covers = 8; + bool num_episodes = 9; + bool consumption_order = 10; + bool media_type_enum = 11; + bool copyrights = 12; + bool trailer_uri = 13; + bool is_music_and_talk = 14; + bool access_info = 15; +} + +message ShowPlayedStateDecorationPolicy { + bool latest_played_episode_link = 1; +} diff --git a/protocol/proto/policy/track_decoration_policy.proto b/protocol/proto/policy/track_decoration_policy.proto new file mode 100644 index 00000000..45162008 --- /dev/null +++ b/protocol/proto/policy/track_decoration_policy.proto @@ -0,0 +1,36 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.policy.proto"; + +message TrackDecorationPolicy { + bool has_lyrics = 1; + bool link = 2; + bool name = 3; + bool length = 4; + bool playable = 5; + bool is_available_in_metadata_catalogue = 6; + bool locally_playable = 7; + bool playable_local_track = 8; + bool disc_number = 9; + bool track_number = 10; + bool is_explicit = 11; + bool preview_id = 12; + bool is_local = 13; + bool is_premium_only = 14; + bool playable_track_link = 15; + bool popularity = 16; + bool is_19_plus_only = 17; + bool track_descriptors = 18; +} + +message TrackPlayedStateDecorationPolicy { + bool playable = 1; + bool is_currently_playable = 2; + bool playability_restriction = 3; +} diff --git a/protocol/proto/policy/user_decoration_policy.proto b/protocol/proto/policy/user_decoration_policy.proto new file mode 100644 index 00000000..4f72e974 --- /dev/null +++ b/protocol/proto/policy/user_decoration_policy.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.policy.proto"; + +message UserDecorationPolicy { + bool username = 1; + bool link = 2; + bool name = 3; + bool image = 4; + bool thumbnail = 5; +} + +message CollaboratorPolicy { + UserDecorationPolicy user = 1; + bool number_of_items = 2; + bool number_of_tracks = 3; + bool number_of_episodes = 4; + bool is_owner = 5; +} + +message CollaboratingUsersDecorationPolicy { + bool count = 1; + int32 limit = 2; + CollaboratorPolicy collaborator = 3; +} diff --git a/protocol/proto/popcount.proto b/protocol/proto/popcount.proto deleted file mode 100644 index 7a0bac84..00000000 --- a/protocol/proto/popcount.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto2"; - -message PopcountRequest { -} - -message PopcountResult { - optional sint64 count = 0x1; - optional bool truncated = 0x2; - repeated string user = 0x3; - repeated sint64 subscriptionTimestamps = 0x4; - repeated sint64 insertionTimestamps = 0x5; -} - diff --git a/protocol/proto/popcount2_external.proto b/protocol/proto/popcount2_external.proto new file mode 100644 index 00000000..069cdcfd --- /dev/null +++ b/protocol/proto/popcount2_external.proto @@ -0,0 +1,30 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.popcount2.proto; + +option optimize_for = CODE_SIZE; + +message PopcountRequest { + +} + +message PopcountResult { + optional sint64 count = 1; + optional bool truncated = 2; + repeated string user = 3; +} + +message PopcountUserUpdate { + optional string user = 1; + optional sint64 timestamp = 2; + optional bool added = 3; +} + +message PopcountUpdate { + repeated PopcountUserUpdate updates = 1; + optional sint64 common_timestamp = 2; + optional sint64 remove_older_than_timestamp = 3; + optional bool verify_counter = 4; +} diff --git a/protocol/proto/prepare_play_options.proto b/protocol/proto/prepare_play_options.proto new file mode 100644 index 00000000..cfaeab14 --- /dev/null +++ b/protocol/proto/prepare_play_options.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_player_options.proto"; +import "player_license.proto"; + +option optimize_for = CODE_SIZE; + +message PreparePlayOptions { + optional ContextPlayerOptionOverrides player_options_override = 1; + optional PlayerLicense license = 2; + map configuration_override = 3; +} diff --git a/protocol/proto/presence.proto b/protocol/proto/presence.proto deleted file mode 100644 index 5e9be377..00000000 --- a/protocol/proto/presence.proto +++ /dev/null @@ -1,94 +0,0 @@ -syntax = "proto2"; - -message PlaylistPublishedState { - optional string uri = 0x1; - optional int64 timestamp = 0x2; -} - -message PlaylistTrackAddedState { - optional string playlist_uri = 0x1; - optional string track_uri = 0x2; - optional int64 timestamp = 0x3; -} - -message TrackFinishedPlayingState { - optional string uri = 0x1; - optional string context_uri = 0x2; - optional int64 timestamp = 0x3; - optional string referrer_uri = 0x4; -} - -message FavoriteAppAddedState { - optional string app_uri = 0x1; - optional int64 timestamp = 0x2; -} - -message TrackStartedPlayingState { - optional string uri = 0x1; - optional string context_uri = 0x2; - optional int64 timestamp = 0x3; - optional string referrer_uri = 0x4; -} - -message UriSharedState { - optional string uri = 0x1; - optional string message = 0x2; - optional int64 timestamp = 0x3; -} - -message ArtistFollowedState { - optional string uri = 0x1; - optional string artist_name = 0x2; - optional string artist_cover_uri = 0x3; - optional int64 timestamp = 0x4; -} - -message DeviceInformation { - optional string os = 0x1; - optional string type = 0x2; -} - -message GenericPresenceState { - optional int32 type = 0x1; - optional int64 timestamp = 0x2; - optional string item_uri = 0x3; - optional string item_name = 0x4; - optional string item_image = 0x5; - optional string context_uri = 0x6; - optional string context_name = 0x7; - optional string context_image = 0x8; - optional string referrer_uri = 0x9; - optional string referrer_name = 0xa; - optional string referrer_image = 0xb; - optional string message = 0xc; - optional DeviceInformation device_information = 0xd; -} - -message State { - optional int64 timestamp = 0x1; - optional Type type = 0x2; - enum Type { - PLAYLIST_PUBLISHED = 0x1; - PLAYLIST_TRACK_ADDED = 0x2; - TRACK_FINISHED_PLAYING = 0x3; - FAVORITE_APP_ADDED = 0x4; - TRACK_STARTED_PLAYING = 0x5; - URI_SHARED = 0x6; - ARTIST_FOLLOWED = 0x7; - GENERIC = 0xb; - } - optional string uri = 0x3; - optional PlaylistPublishedState playlist_published = 0x4; - optional PlaylistTrackAddedState playlist_track_added = 0x5; - optional TrackFinishedPlayingState track_finished_playing = 0x6; - optional FavoriteAppAddedState favorite_app_added = 0x7; - optional TrackStartedPlayingState track_started_playing = 0x8; - optional UriSharedState uri_shared = 0x9; - optional ArtistFollowedState artist_followed = 0xa; - optional GenericPresenceState generic = 0xb; -} - -message StateList { - repeated State states = 0x1; -} - diff --git a/protocol/proto/profile_cache.proto b/protocol/proto/profile_cache.proto new file mode 100644 index 00000000..8162612f --- /dev/null +++ b/protocol/proto/profile_cache.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.profile.proto; + +import "identity.proto"; + +option optimize_for = CODE_SIZE; + +message CachedProfile { + identity.proto.DecorationData profile = 1; + int64 expires_at = 2; + bool pinned = 3; +} + +message ProfileCacheFile { + repeated CachedProfile cached_profiles = 1; +} diff --git a/protocol/proto/profile_cosmos.proto b/protocol/proto/profile_cosmos.proto new file mode 100644 index 00000000..c6c945db --- /dev/null +++ b/protocol/proto/profile_cosmos.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.profile_cosmos.proto; + +import "identity.proto"; + +option optimize_for = CODE_SIZE; + +message GetProfilesRequest { + repeated string usernames = 1; +} + +message GetProfilesResponse { + repeated identity.v3.UserProfile profiles = 1; +} + +message ChangeDisplayNameRequest { + string username = 1; + string display_name = 2; +} diff --git a/protocol/proto/property_definition.proto b/protocol/proto/property_definition.proto new file mode 100644 index 00000000..4552c1b2 --- /dev/null +++ b/protocol/proto/property_definition.proto @@ -0,0 +1,44 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.ucs.proto; + +option optimize_for = CODE_SIZE; + +message PropertyDefinition { + Identifier id = 1; + message Identifier { + string scope = 1; + string name = 2; + } + + Metadata metadata = 4; + message Metadata { + string component_id = 1; + string description = 2; + } + + oneof specification { + BoolSpec bool_spec = 5; + IntSpec int_spec = 6; + EnumSpec enum_spec = 7; + } + + reserved 2, "hash"; + + message BoolSpec { + bool default = 1; + } + + message IntSpec { + int32 default = 1; + int32 lower = 2; + int32 upper = 3; + } + + message EnumSpec { + string default = 1; + repeated string values = 2; + } +} diff --git a/protocol/proto/protobuf_delta.proto b/protocol/proto/protobuf_delta.proto new file mode 100644 index 00000000..c0a89fec --- /dev/null +++ b/protocol/proto/protobuf_delta.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.protobuf_deltas.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message Delta { + required Type type = 1; + enum Type { + DELETE = 0; + INSERT = 1; + } + + required uint32 index = 2; + required uint32 length = 3; +} diff --git a/protocol/proto/queue.proto b/protocol/proto/queue.proto new file mode 100644 index 00000000..24b45b7c --- /dev/null +++ b/protocol/proto/queue.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto.transfer; + +import "context_track.proto"; + +option optimize_for = CODE_SIZE; + +message Queue { + repeated ContextTrack tracks = 1; + optional bool is_playing_queue = 2; +} diff --git a/protocol/proto/radio.proto b/protocol/proto/radio.proto deleted file mode 100644 index 7a8f3bde..00000000 --- a/protocol/proto/radio.proto +++ /dev/null @@ -1,58 +0,0 @@ -syntax = "proto2"; - -message RadioRequest { - repeated string uris = 0x1; - optional int32 salt = 0x2; - optional int32 length = 0x4; - optional string stationId = 0x5; - repeated string lastTracks = 0x6; -} - -message MultiSeedRequest { - repeated string uris = 0x1; -} - -message Feedback { - optional string uri = 0x1; - optional string type = 0x2; - optional double timestamp = 0x3; -} - -message Tracks { - repeated string gids = 0x1; - optional string source = 0x2; - optional string identity = 0x3; - repeated string tokens = 0x4; - repeated Feedback feedback = 0x5; -} - -message Station { - optional string id = 0x1; - optional string title = 0x2; - optional string titleUri = 0x3; - optional string subtitle = 0x4; - optional string subtitleUri = 0x5; - optional string imageUri = 0x6; - optional double lastListen = 0x7; - repeated string seeds = 0x8; - optional int32 thumbsUp = 0x9; - optional int32 thumbsDown = 0xa; -} - -message Rules { - optional string js = 0x1; -} - -message StationResponse { - optional Station station = 0x1; - repeated Feedback feedback = 0x2; -} - -message StationList { - repeated Station stations = 0x1; -} - -message LikedPlaylist { - optional string uri = 0x1; -} - diff --git a/protocol/proto/rc_dummy_property_resolved.proto b/protocol/proto/rc_dummy_property_resolved.proto new file mode 100644 index 00000000..9c5e2aaf --- /dev/null +++ b/protocol/proto/rc_dummy_property_resolved.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.proto; + +option optimize_for = CODE_SIZE; + +message RcDummyPropertyResolved { + string resolved_value = 1; + string configuration_assignment_id = 2; +} diff --git a/protocol/proto/rcs.proto b/protocol/proto/rcs.proto new file mode 100644 index 00000000..ed8405c2 --- /dev/null +++ b/protocol/proto/rcs.proto @@ -0,0 +1,107 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.proto; + +option optimize_for = CODE_SIZE; + +message GranularConfiguration { + repeated AssignedPropertyValue properties = 1; + message AssignedPropertyValue { + Platform platform = 7; + string client_id = 4; + string component_id = 5; + int64 groupId = 8; + string name = 6; + + oneof structured_value { + BoolValue bool_value = 1; + IntValue int_value = 2; + EnumValue enum_value = 3; + } + + message BoolValue { + bool value = 1; + } + + message IntValue { + int32 value = 1; + } + + message EnumValue { + string value = 1; + } + } + + int64 rcs_fetch_time = 2; + string configuration_assignment_id = 3; +} + +message PolicyGroupId { + int64 policy_id = 1; + int64 policy_group_id = 2; +} + +message ClientPropertySet { + string client_id = 1; + string version = 2; + repeated PropertyDefinition properties = 5; + + repeated ComponentInfo component_infos = 6; + message ComponentInfo { + string name = 3; + + reserved 1, 2, "owner", "tags"; + } + + string property_set_key = 7; + + PublisherInfo publisherInfo = 8; + message PublisherInfo { + string published_for_client_version = 1; + int64 published_at = 2; + } +} + +message PropertyDefinition { + string description = 2; + string component_id = 3; + Platform platform = 8; + + oneof identifier { + string id = 9; + string name = 7; + } + + oneof spec { + BoolSpec bool_spec = 4; + IntSpec int_spec = 5; + EnumSpec enum_spec = 6; + } + + reserved 1; + + message BoolSpec { + bool default = 1; + } + + message IntSpec { + int32 default = 1; + int32 lower = 2; + int32 upper = 3; + } + + message EnumSpec { + string default = 1; + repeated string values = 2; + } +} + +enum Platform { + UNKNOWN_PLATFORM = 0; + ANDROID_PLATFORM = 1; + BACKEND_PLATFORM = 2; + IOS_PLATFORM = 3; + WEB_PLATFORM = 4; +} diff --git a/protocol/proto/recently_played.proto b/protocol/proto/recently_played.proto new file mode 100644 index 00000000..fd22fdd9 --- /dev/null +++ b/protocol/proto/recently_played.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.recently_played.proto; + +option optimize_for = CODE_SIZE; + +message Item { + string link = 1; + int64 timestamp = 2; + bool hidden = 3; +} diff --git a/protocol/proto/recently_played_backend.proto b/protocol/proto/recently_played_backend.proto new file mode 100644 index 00000000..fa137288 --- /dev/null +++ b/protocol/proto/recently_played_backend.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.recently_played_backend.proto; + +option optimize_for = CODE_SIZE; + +message Context { + optional string uri = 1; + optional int64 lastPlayedTime = 2; +} + +message RecentlyPlayed { + repeated Context contexts = 1; + optional int32 offset = 2; + optional int32 total = 3; +} diff --git a/protocol/proto/record_id.proto b/protocol/proto/record_id.proto new file mode 100644 index 00000000..54fa24a3 --- /dev/null +++ b/protocol/proto/record_id.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message RecordId { + int64 value = 1; +} diff --git a/protocol/proto/remote.proto b/protocol/proto/remote.proto new file mode 100644 index 00000000..a81c1c0f --- /dev/null +++ b/protocol/proto/remote.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.shuffle.remote; + +option optimize_for = CODE_SIZE; + +message ServiceRequest { + repeated Track tracks = 1; + message Track { + required string uri = 1; + required string uid = 2; + } +} + +message ServiceResponse { + repeated uint32 order = 1; +} diff --git a/protocol/proto/repeating_track_node.proto b/protocol/proto/repeating_track_node.proto new file mode 100644 index 00000000..d4691cd2 --- /dev/null +++ b/protocol/proto/repeating_track_node.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "track_instance.proto"; +import "track_instantiator.proto"; + +option optimize_for = CODE_SIZE; + +message RepeatingTrackNode { + optional TrackInstance instance = 1; + optional TrackInstantiator instantiator = 2; +} diff --git a/protocol/proto/request_failure.proto b/protocol/proto/request_failure.proto new file mode 100644 index 00000000..10deb1be --- /dev/null +++ b/protocol/proto/request_failure.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.image.proto; + +option optimize_for = CODE_SIZE; + +message RequestFailure { + optional string request = 1; + optional string source = 2; + optional string error = 3; + optional int64 result = 4; +} diff --git a/protocol/proto/resolve.proto b/protocol/proto/resolve.proto new file mode 100644 index 00000000..5f2cd9b8 --- /dev/null +++ b/protocol/proto/resolve.proto @@ -0,0 +1,116 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.ucs.proto; + +import "property_definition.proto"; + +option optimize_for = CODE_SIZE; + +message ResolveRequest { + string property_set_id = 1; + Fetch fetch_type = 2; + Context context = 11; + + oneof resolution_context { + BackendContext backend_context = 12 [deprecated = true]; + } + + reserved 4, 5, "custom_context", "projection"; +} + +message ResolveResponse { + Configuration configuration = 1; +} + +message Configuration { + string configuration_assignment_id = 1; + int64 fetch_time_millis = 2; + + repeated AssignedValue assigned_values = 3; + message AssignedValue { + PropertyDefinition.Identifier property_id = 1; + + Metadata metadata = 2; + message Metadata { + int64 policy_id = 1; + string external_realm = 2; + int64 external_realm_id = 3; + } + + oneof structured_value { + BoolValue bool_value = 3; + IntValue int_value = 4; + EnumValue enum_value = 5; + } + + message BoolValue { + bool value = 1; + } + + message IntValue { + int32 value = 1; + } + + message EnumValue { + string value = 1; + } + } +} + +message Fetch { + Type type = 1; + enum Type { + BLOCKING = 0; + BACKGROUND_SYNC = 1; + ASYNC = 2; + PUSH_INITIATED = 3; + RECONNECT = 4; + } +} + +message Context { + repeated ContextEntry context = 1; + message ContextEntry { + string value = 10; + + oneof context { + DynamicContext.KnownContext known_context = 1; + } + } +} + +message BackendContext { + string system = 1 [deprecated = true]; + string service_name = 2 [deprecated = true]; + + StaticContext static_context = 3; + message StaticContext { + string system = 1; + string service_name = 2; + } + + DynamicContext dynamic_context = 4; + + SurfaceMetadata surface_metadata = 10; + message SurfaceMetadata { + string backend_sdk_version = 1; + } +} + +message DynamicContext { + repeated ContextDefinition context_definition = 1; + message ContextDefinition { + oneof context { + KnownContext known_context = 1; + } + } + + enum KnownContext { + KNOWN_CONTEXT_INVALID = 0; + KNOWN_CONTEXT_USER_ID = 1; + KNOWN_CONTEXT_INSTALLATION_ID = 2; + KNOWN_CONTEXT_VERSION = 3; + } +} diff --git a/protocol/proto/resolve_configuration_error.proto b/protocol/proto/resolve_configuration_error.proto new file mode 100644 index 00000000..22f2e1fb --- /dev/null +++ b/protocol/proto/resolve_configuration_error.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.proto; + +option optimize_for = CODE_SIZE; + +message ResolveConfigurationError { + string error_message = 1; + int64 status_code = 2; + string client_id = 3; + string client_version = 4; +} diff --git a/protocol/proto/resource_type.proto b/protocol/proto/resource_type.proto new file mode 100644 index 00000000..ccea6920 --- /dev/null +++ b/protocol/proto/resource_type.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.offline.proto; + +option optimize_for = CODE_SIZE; + +enum ResourceType { + OTHER = 0; + AUDIO = 1; + DRM = 2; + IMAGE = 3; + VIDEO = 4; +} diff --git a/protocol/proto/response_status.proto b/protocol/proto/response_status.proto new file mode 100644 index 00000000..a9ecadd7 --- /dev/null +++ b/protocol/proto/response_status.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.playlist.esperanto.proto"; + +message ResponseStatus { + int32 status_code = 1; + string reason = 2; +} diff --git a/protocol/proto/restrictions.proto b/protocol/proto/restrictions.proto new file mode 100644 index 00000000..0661858c --- /dev/null +++ b/protocol/proto/restrictions.proto @@ -0,0 +1,31 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message Restrictions { + repeated string disallow_pausing_reasons = 1; + repeated string disallow_resuming_reasons = 2; + repeated string disallow_seeking_reasons = 3; + repeated string disallow_peeking_prev_reasons = 4; + repeated string disallow_peeking_next_reasons = 5; + repeated string disallow_skipping_prev_reasons = 6; + repeated string disallow_skipping_next_reasons = 7; + repeated string disallow_toggling_repeat_context_reasons = 8; + repeated string disallow_toggling_repeat_track_reasons = 9; + repeated string disallow_toggling_shuffle_reasons = 10; + repeated string disallow_set_queue_reasons = 11; + repeated string disallow_interrupting_playback_reasons = 12; + repeated string disallow_transferring_playback_reasons = 13; + repeated string disallow_remote_control_reasons = 14; + repeated string disallow_inserting_into_next_tracks_reasons = 15; + repeated string disallow_inserting_into_context_tracks_reasons = 16; + repeated string disallow_reordering_in_next_tracks_reasons = 17; + repeated string disallow_reordering_in_context_tracks_reasons = 18; + repeated string disallow_removing_from_next_tracks_reasons = 19; + repeated string disallow_removing_from_context_tracks_reasons = 20; + repeated string disallow_updating_context_reasons = 21; +} diff --git a/protocol/proto/resume_points_node.proto b/protocol/proto/resume_points_node.proto new file mode 100644 index 00000000..9f7eed8e --- /dev/null +++ b/protocol/proto/resume_points_node.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify_shows.proto; + +option optimize_for = CODE_SIZE; + +message ResumePointsNode { + optional int64 resume_point = 1; +} diff --git a/protocol/proto/rootlist_request.proto b/protocol/proto/rootlist_request.proto new file mode 100644 index 00000000..80af73f0 --- /dev/null +++ b/protocol/proto/rootlist_request.proto @@ -0,0 +1,43 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.playlist.cosmos.rootlist_request.proto; + +import "playlist_folder_state.proto"; +import "playlist_playlist_state.proto"; +import "protobuf_delta.proto"; + +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message Playlist { + optional string row_id = 1; + optional cosmos.proto.PlaylistMetadata playlist_metadata = 2; + optional cosmos.proto.PlaylistOfflineState playlist_offline_state = 3; + optional uint32 add_time = 4; + optional bool is_on_demand_in_free = 5; + optional string group_label = 6; +} + +message Item { + optional string header_field = 1; + optional Folder folder = 2; + optional Playlist playlist = 3; + optional protobuf_deltas.proto.Delta delta = 4; +} + +message Folder { + repeated Item item = 1; + optional cosmos.proto.FolderMetadata folder_metadata = 2; + optional string row_id = 3; + optional uint32 add_time = 4; + optional string group_label = 5; +} + +message Response { + optional Folder root = 1; + optional int32 unfiltered_length = 2; + optional int32 unranged_length = 3; + optional bool is_loading_contents = 4; +} diff --git a/protocol/proto/search.proto b/protocol/proto/search.proto deleted file mode 100644 index 38b717f7..00000000 --- a/protocol/proto/search.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto2"; - -message SearchRequest { - optional string query = 0x1; - optional Type type = 0x2; - enum Type { - TRACK = 0x0; - ALBUM = 0x1; - ARTIST = 0x2; - PLAYLIST = 0x3; - USER = 0x4; - } - optional int32 limit = 0x3; - optional int32 offset = 0x4; - optional bool did_you_mean = 0x5; - optional string spotify_uri = 0x2; - repeated bytes file_id = 0x3; - optional string url = 0x4; - optional string slask_id = 0x5; -} - -message Playlist { - optional string uri = 0x1; - optional string name = 0x2; - repeated Image image = 0x3; -} - -message User { - optional string username = 0x1; - optional string full_name = 0x2; - repeated Image image = 0x3; - optional sint32 followers = 0x4; -} - -message SearchReply { - optional sint32 hits = 0x1; - repeated Track track = 0x2; - repeated Album album = 0x3; - repeated Artist artist = 0x4; - repeated Playlist playlist = 0x5; - optional string did_you_mean = 0x6; - repeated User user = 0x7; -} - diff --git a/protocol/proto/seek_to_position.proto b/protocol/proto/seek_to_position.proto new file mode 100644 index 00000000..6f426842 --- /dev/null +++ b/protocol/proto/seek_to_position.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message SeekToPosition { + optional uint64 value = 1; + optional uint32 revision = 2; +} diff --git a/protocol/proto/sequence_number_entity.proto b/protocol/proto/sequence_number_entity.proto new file mode 100644 index 00000000..cd97392c --- /dev/null +++ b/protocol/proto/sequence_number_entity.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.event_sender.proto; + +option optimize_for = CODE_SIZE; + +message SequenceNumberEntity { + int32 file_format_version = 1; + string event_name = 2; + bytes sequence_id = 3; + int64 sequence_number_next = 4; +} diff --git a/protocol/proto/session.proto b/protocol/proto/session.proto new file mode 100644 index 00000000..7c4589f3 --- /dev/null +++ b/protocol/proto/session.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto.transfer; + +import "context.proto"; +import "context_player_options.proto"; +import "play_origin.proto"; +import "suppressions.proto"; +import "instrumentation_params.proto"; + +option optimize_for = CODE_SIZE; + +message Session { + optional PlayOrigin play_origin = 1; + optional Context context = 2; + optional string current_uid = 3; + optional ContextPlayerOptionOverrides option_overrides = 4; + optional Suppressions suppressions = 5; + optional InstrumentationParams instrumentation_params = 6; +} diff --git a/protocol/proto/show_access.proto b/protocol/proto/show_access.proto new file mode 100644 index 00000000..3516cdfd --- /dev/null +++ b/protocol/proto/show_access.proto @@ -0,0 +1,33 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.podcast_paywalls; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "ShowAccessProto"; +option java_package = "com.spotify.podcast.access.proto"; + +message ShowAccess { + oneof explanation { + NoExplanation none = 1; + LegacyExplanation legacy = 2; + BasicExplanation basic = 3; + } +} + +message BasicExplanation { + string title = 1; + string body = 2; + string cta = 3; +} + +message LegacyExplanation { + +} + +message NoExplanation { + +} diff --git a/protocol/proto/show_episode_state.proto b/protocol/proto/show_episode_state.proto new file mode 100644 index 00000000..001fafee --- /dev/null +++ b/protocol/proto/show_episode_state.proto @@ -0,0 +1,25 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.show_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message EpisodeCollectionState { + optional bool is_following_show = 1; + optional bool is_new = 2; + optional bool is_in_listen_later = 3; +} + +message EpisodeOfflineState { + optional string offline_state = 1; + optional uint32 sync_progress = 2; +} + +message EpisodePlayState { + optional uint32 time_left = 1; + optional bool is_playable = 2; + optional bool is_played = 3; + optional uint64 last_played_at = 4; +} diff --git a/protocol/proto/show_request.proto b/protocol/proto/show_request.proto new file mode 100644 index 00000000..0f40a1bd --- /dev/null +++ b/protocol/proto/show_request.proto @@ -0,0 +1,66 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.show_cosmos.proto; + +import "metadata/episode_metadata.proto"; +import "metadata/show_metadata.proto"; +import "show_episode_state.proto"; +import "show_show_state.proto"; +import "podcast_virality.proto"; +import "transcripts.proto"; +import "podcastextensions.proto"; +import "clips_cover.proto"; +import "show_access.proto"; + +option optimize_for = CODE_SIZE; + +message Item { + optional string header_field = 1; + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 2; + optional EpisodeCollectionState episode_collection_state = 3; + optional EpisodeOfflineState episode_offline_state = 4; + optional EpisodePlayState episode_play_state = 5; + optional corex.transcripts.metadata.EpisodeTranscript episode_transcripts = 7; + optional podcastvirality.v1.PodcastVirality episode_virality = 8; + + reserved 6; +} + +message Header { + optional cosmos_util.proto.ShowMetadata show_metadata = 1; + optional ShowCollectionState show_collection_state = 2; + optional ShowPlayState show_play_state = 3; +} + +message Response { + repeated Item item = 1; + optional Header header = 2; + optional uint32 unfiltered_length = 4; + optional uint32 length = 5; + optional bool loading_contents = 6; + optional uint32 unranged_length = 7; + optional AuxiliarySections auxiliary_sections = 8; + optional podcast_paywalls.ShowAccess access_info = 9; + + reserved 3, "online_data"; +} + +message AuxiliarySections { + optional ContinueListeningSection continue_listening = 1; + optional podcast.extensions.PodcastTopics topics_section = 2; + optional TrailerSection trailer_section = 3; + optional podcast.extensions.PodcastHtmlDescription html_description_section = 5; + optional clips.ClipsCover clips_section = 6; + + reserved 4; +} + +message ContinueListeningSection { + optional Item item = 1; +} + +message TrailerSection { + optional Item item = 1; +} diff --git a/protocol/proto/show_show_state.proto b/protocol/proto/show_show_state.proto new file mode 100644 index 00000000..ab0d1fe3 --- /dev/null +++ b/protocol/proto/show_show_state.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.show_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message ShowCollectionState { + optional bool is_in_collection = 1; +} + +message ShowPlayState { + optional string latest_played_episode_link = 1; +} diff --git a/protocol/proto/skip_to_track.proto b/protocol/proto/skip_to_track.proto new file mode 100644 index 00000000..67b5f717 --- /dev/null +++ b/protocol/proto/skip_to_track.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message SkipToTrack { + optional string page_url = 1; + optional uint64 page_index = 2; + optional string track_uid = 3; + optional string track_uri = 4; + optional uint64 track_index = 5; +} diff --git a/protocol/proto/social.proto b/protocol/proto/social.proto deleted file mode 100644 index 58d39a18..00000000 --- a/protocol/proto/social.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto2"; - -message DecorationData { - optional string username = 0x1; - optional string full_name = 0x2; - optional string image_url = 0x3; - optional string large_image_url = 0x5; - optional string first_name = 0x6; - optional string last_name = 0x7; - optional string facebook_uid = 0x8; -} - diff --git a/protocol/proto/social_connect_v2.proto b/protocol/proto/social_connect_v2.proto new file mode 100644 index 00000000..265fbee6 --- /dev/null +++ b/protocol/proto/social_connect_v2.proto @@ -0,0 +1,55 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package socialconnect; + +option optimize_for = CODE_SIZE; + +message Session { + int64 timestamp = 1; + string session_id = 2; + string join_session_token = 3; + string join_session_url = 4; + string session_owner_id = 5; + repeated SessionMember session_members = 6; + string join_session_uri = 7; + bool is_session_owner = 9; +} + +message SessionMember { + int64 timestamp = 1; + string id = 2; + string username = 3; + string display_name = 4; + string image_url = 5; + string large_image_url = 6; +} + +message SessionUpdate { + Session session = 1; + SessionUpdateReason reason = 2; + repeated SessionMember updated_session_members = 3; +} + +message DevicesExposure { + int64 timestamp = 1; + map devices_exposure = 2; +} + +enum SessionUpdateReason { + UNKNOWN_UPDATE_TYPE = 0; + NEW_SESSION = 1; + USER_JOINED = 2; + USER_LEFT = 3; + SESSION_DELETED = 4; + YOU_LEFT = 5; + YOU_WERE_KICKED = 6; + YOU_JOINED = 7; +} + +enum DeviceExposureStatus { + NOT_EXPOSABLE = 0; + NOT_EXPOSED = 1; + EXPOSED = 2; +} diff --git a/protocol/proto/socialgraph.proto b/protocol/proto/socialgraph.proto deleted file mode 100644 index 3adc1306..00000000 --- a/protocol/proto/socialgraph.proto +++ /dev/null @@ -1,49 +0,0 @@ -syntax = "proto2"; - -message CountReply { - repeated int32 counts = 0x1; -} - -message UserListRequest { - optional string last_result = 0x1; - optional int32 count = 0x2; - optional bool include_length = 0x3; -} - -message UserListReply { - repeated User users = 0x1; - optional int32 length = 0x2; -} - -message User { - optional string username = 0x1; - optional int32 subscriber_count = 0x2; - optional int32 subscription_count = 0x3; -} - -message ArtistListReply { - repeated Artist artists = 0x1; -} - -message Artist { - optional string artistid = 0x1; - optional int32 subscriber_count = 0x2; -} - -message StringListRequest { - repeated string args = 0x1; -} - -message StringListReply { - repeated string reply = 0x1; -} - -message TopPlaylistsRequest { - optional string username = 0x1; - optional int32 count = 0x2; -} - -message TopPlaylistsReply { - repeated string uris = 0x1; -} - diff --git a/protocol/proto/spotify/clienttoken/v0/clienttoken_http.proto b/protocol/proto/spotify/clienttoken/v0/clienttoken_http.proto new file mode 100644 index 00000000..92d50f42 --- /dev/null +++ b/protocol/proto/spotify/clienttoken/v0/clienttoken_http.proto @@ -0,0 +1,123 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.clienttoken.http.v0; + +import "connectivity.proto"; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "spotify.clienttoken.http.v0"; + +message ClientTokenRequest { + ClientTokenRequestType request_type = 1; + + oneof request { + ClientDataRequest client_data = 2; + ChallengeAnswersRequest challenge_answers = 3; + } +} + +message ClientDataRequest { + string client_version = 1; + string client_id = 2; + + oneof data { + data.v0.ConnectivitySdkData connectivity_sdk_data = 3; + } +} + +message ChallengeAnswersRequest { + string state = 1; + repeated ChallengeAnswer answers = 2; +} + +message ClientTokenResponse { + ClientTokenResponseType response_type = 1; + + oneof response { + GrantedTokenResponse granted_token = 2; + ChallengesResponse challenges = 3; + } +} + +message GrantedTokenResponse { + string token = 1; + int32 expires_after_seconds = 2; + int32 refresh_after_seconds = 3; +} + +message ChallengesResponse { + string state = 1; + repeated Challenge challenges = 2; +} + +message ClientSecretParameters { + string salt = 1; +} + +message EvaluateJSParameters { + string code = 1; + repeated string libraries = 2; +} + +message HashCashParameters { + int32 length = 1; + string prefix = 2; +} + +message Challenge { + ChallengeType type = 1; + + oneof parameters { + ClientSecretParameters client_secret_parameters = 2; + EvaluateJSParameters evaluate_js_parameters = 3; + HashCashParameters evaluate_hashcash_parameters = 4; + } +} + +message ClientSecretHMACAnswer { + string hmac = 1; +} + +message EvaluateJSAnswer { + string result = 1; +} + +message HashCashAnswer { + string suffix = 1; +} + +message ChallengeAnswer { + ChallengeType ChallengeType = 1; + + oneof answer { + ClientSecretHMACAnswer client_secret = 2; + EvaluateJSAnswer evaluate_js = 3; + HashCashAnswer hash_cash = 4; + } +} + +message ClientTokenBadRequest { + string message = 1; +} + +enum ClientTokenRequestType { + REQUEST_UNKNOWN = 0; + REQUEST_CLIENT_DATA_REQUEST = 1; + REQUEST_CHALLENGE_ANSWERS_REQUEST = 2; +} + +enum ClientTokenResponseType { + RESPONSE_UNKNOWN = 0; + RESPONSE_GRANTED_TOKEN_RESPONSE = 1; + RESPONSE_CHALLENGES_RESPONSE = 2; +} + +enum ChallengeType { + CHALLENGE_UNKNOWN = 0; + CHALLENGE_CLIENT_SECRET_HMAC = 1; + CHALLENGE_EVALUATE_JS = 2; + CHALLENGE_HASH_CASH = 3; +} diff --git a/protocol/proto/spotify/login5/v3/challenges/code.proto b/protocol/proto/spotify/login5/v3/challenges/code.proto new file mode 100644 index 00000000..980d3de3 --- /dev/null +++ b/protocol/proto/spotify/login5/v3/challenges/code.proto @@ -0,0 +1,26 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3.challenges; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.challenges.proto"; + +message CodeChallenge { + Method method = 1; + enum Method { + UNKNOWN = 0; + SMS = 1; + } + + int32 code_length = 2; + int32 expires_in = 3; + string canonical_phone_number = 4; +} + +message CodeSolution { + string code = 1; +} diff --git a/protocol/proto/spotify/login5/v3/challenges/hashcash.proto b/protocol/proto/spotify/login5/v3/challenges/hashcash.proto new file mode 100644 index 00000000..3e83981c --- /dev/null +++ b/protocol/proto/spotify/login5/v3/challenges/hashcash.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3.challenges; + +import "google/protobuf/duration.proto"; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.challenges.proto"; + +message HashcashChallenge { + bytes prefix = 1; + int32 length = 2; +} + +message HashcashSolution { + bytes suffix = 1; + google.protobuf.Duration duration = 2; +} diff --git a/protocol/proto/spotify/login5/v3/client_info.proto b/protocol/proto/spotify/login5/v3/client_info.proto new file mode 100644 index 00000000..575891e1 --- /dev/null +++ b/protocol/proto/spotify/login5/v3/client_info.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.proto"; + +message ClientInfo { + string client_id = 1; + string device_id = 2; +} diff --git a/protocol/proto/spotify/login5/v3/credentials/credentials.proto b/protocol/proto/spotify/login5/v3/credentials/credentials.proto new file mode 100644 index 00000000..defab249 --- /dev/null +++ b/protocol/proto/spotify/login5/v3/credentials/credentials.proto @@ -0,0 +1,48 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3.credentials; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.credentials.proto"; + +message StoredCredential { + string username = 1; + bytes data = 2; +} + +message Password { + string id = 1; + string password = 2; + bytes padding = 3; +} + +message FacebookAccessToken { + string fb_uid = 1; + string access_token = 2; +} + +message OneTimeToken { + string token = 1; +} + +message ParentChildCredential { + string child_id = 1; + StoredCredential parent_stored_credential = 2; +} + +message AppleSignInCredential { + string auth_code = 1; + string redirect_uri = 2; + string bundle_id = 3; +} + +message SamsungSignInCredential { + string auth_code = 1; + string redirect_uri = 2; + string id_token = 3; + string token_endpoint_url = 4; +} diff --git a/protocol/proto/spotify/login5/v3/identifiers/identifiers.proto b/protocol/proto/spotify/login5/v3/identifiers/identifiers.proto new file mode 100644 index 00000000..b82e9942 --- /dev/null +++ b/protocol/proto/spotify/login5/v3/identifiers/identifiers.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3.identifiers; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.identifiers.proto"; + +message PhoneNumber { + string number = 1; + string iso_country_code = 2; + string country_calling_code = 3; +} diff --git a/protocol/proto/spotify/login5/v3/login5.proto b/protocol/proto/spotify/login5/v3/login5.proto new file mode 100644 index 00000000..f10ada21 --- /dev/null +++ b/protocol/proto/spotify/login5/v3/login5.proto @@ -0,0 +1,93 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3; + +import "spotify/login5/v3/client_info.proto"; +import "spotify/login5/v3/user_info.proto"; +import "spotify/login5/v3/challenges/code.proto"; +import "spotify/login5/v3/challenges/hashcash.proto"; +import "spotify/login5/v3/credentials/credentials.proto"; +import "spotify/login5/v3/identifiers/identifiers.proto"; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.proto"; + +message Challenges { + repeated Challenge challenges = 1; +} + +message Challenge { + oneof challenge { + challenges.HashcashChallenge hashcash = 1; + challenges.CodeChallenge code = 2; + } +} + +message ChallengeSolutions { + repeated ChallengeSolution solutions = 1; +} + +message ChallengeSolution { + oneof solution { + challenges.HashcashSolution hashcash = 1; + challenges.CodeSolution code = 2; + } +} + +message LoginRequest { + ClientInfo client_info = 1; + bytes login_context = 2; + ChallengeSolutions challenge_solutions = 3; + + oneof login_method { + credentials.StoredCredential stored_credential = 100; + credentials.Password password = 101; + credentials.FacebookAccessToken facebook_access_token = 102; + identifiers.PhoneNumber phone_number = 103; + credentials.OneTimeToken one_time_token = 104; + credentials.ParentChildCredential parent_child_credential = 105; + credentials.AppleSignInCredential apple_sign_in_credential = 106; + credentials.SamsungSignInCredential samsung_sign_in_credential = 107; + } +} + +message LoginOk { + string username = 1; + string access_token = 2; + bytes stored_credential = 3; + int32 access_token_expires_in = 4; +} + +message LoginResponse { + repeated Warnings warnings = 4; + enum Warnings { + UNKNOWN_WARNING = 0; + DEPRECATED_PROTOCOL_VERSION = 1; + } + + bytes login_context = 5; + string identifier_token = 6; + UserInfo user_info = 7; + + oneof response { + LoginOk ok = 1; + LoginError error = 2; + Challenges challenges = 3; + } +} + +enum LoginError { + UNKNOWN_ERROR = 0; + INVALID_CREDENTIALS = 1; + BAD_REQUEST = 2; + UNSUPPORTED_LOGIN_PROTOCOL = 3; + TIMEOUT = 4; + UNKNOWN_IDENTIFIER = 5; + TOO_MANY_ATTEMPTS = 6; + INVALID_PHONENUMBER = 7; + TRY_AGAIN_LATER = 8; +} diff --git a/protocol/proto/spotify/login5/v3/user_info.proto b/protocol/proto/spotify/login5/v3/user_info.proto new file mode 100644 index 00000000..a7e040cc --- /dev/null +++ b/protocol/proto/spotify/login5/v3/user_info.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto3"; + +package spotify.login5.v3; + +option objc_class_prefix = "SPTLogin5"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.login5.v3.proto"; + +message UserInfo { + string name = 1; + string email = 2; + bool email_verified = 3; + string birthdate = 4; + + Gender gender = 5; + enum Gender { + UNKNOWN = 0; + MALE = 1; + FEMALE = 2; + NEUTRAL = 3; + } + + string phone_number = 6; + bool phone_number_verified = 7; + bool email_already_registered = 8; +} diff --git a/protocol/proto/status_code.proto b/protocol/proto/status_code.proto new file mode 100644 index 00000000..8e813d25 --- /dev/null +++ b/protocol/proto/status_code.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +enum StatusCode { + SUCCESS = 0; +} diff --git a/protocol/proto/status_response.proto b/protocol/proto/status_response.proto new file mode 100644 index 00000000..78d15c9a --- /dev/null +++ b/protocol/proto/status_response.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "status_code.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StatusResponse { + StatusCode status_code = 1; + string reason = 2; +} diff --git a/protocol/proto/storage-resolve.proto b/protocol/proto/storage-resolve.proto new file mode 100644 index 00000000..1cb3b673 --- /dev/null +++ b/protocol/proto/storage-resolve.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.download.proto; + +option optimize_for = CODE_SIZE; + +message StorageResolveResponse { + Result result = 1; + enum Result { + CDN = 0; + STORAGE = 1; + RESTRICTED = 3; + } + + repeated string cdnurl = 2; + bytes fileid = 4; +} diff --git a/protocol/proto/storage_cosmos.proto b/protocol/proto/storage_cosmos.proto new file mode 100644 index 00000000..97169850 --- /dev/null +++ b/protocol/proto/storage_cosmos.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.storage_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message GetFileCacheRangesResponse { + bool byte_size_known = 1; + uint64 byte_size = 2; + + repeated Range ranges = 3; + message Range { + uint64 from_byte = 1; + uint64 to_byte = 2; + } +} diff --git a/protocol/proto/storylines.proto b/protocol/proto/storylines.proto new file mode 100644 index 00000000..c9361966 --- /dev/null +++ b/protocol/proto/storylines.proto @@ -0,0 +1,29 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.storylines.v1; + +option java_multiple_files = true; +option java_outer_classname = "StorylinesProto"; +option java_package = "com.spotify.storylines.v1.extended_metadata"; + +message Artist { + string uri = 1; + string name = 2; + string avatar_cdn_url = 3; +} + +message Card { + string id = 1; + string image_cdn_url = 2; + int32 image_width = 3; + int32 image_height = 4; +} + +message Storyline { + string id = 1; + string entity_uri = 2; + Artist artist = 3; + repeated Card cards = 4; +} diff --git a/protocol/proto/stream_end_request.proto b/protocol/proto/stream_end_request.proto new file mode 100644 index 00000000..5ef8be7f --- /dev/null +++ b/protocol/proto/stream_end_request.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "stream_handle.proto"; +import "play_reason.proto"; +import "play_source.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamEndRequest { + StreamHandle stream_handle = 1; + PlaySource source_end = 2; + PlayReason reason_end = 3; +} diff --git a/protocol/proto/stream_handle.proto b/protocol/proto/stream_handle.proto new file mode 100644 index 00000000..b66ed4ce --- /dev/null +++ b/protocol/proto/stream_handle.proto @@ -0,0 +1,12 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamHandle { + string playback_id = 1; +} diff --git a/protocol/proto/stream_prepare_request.proto b/protocol/proto/stream_prepare_request.proto new file mode 100644 index 00000000..ce22e8eb --- /dev/null +++ b/protocol/proto/stream_prepare_request.proto @@ -0,0 +1,39 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "play_reason.proto"; +import "play_source.proto"; +import "streaming_rule.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamPrepareRequest { + string playback_id = 1; + string parent_playback_id = 2; + string parent_play_track = 3; + string video_session_id = 4; + string play_context = 5; + string uri = 6; + string displayed_uri = 7; + string feature_identifier = 8; + string feature_version = 9; + string view_uri = 10; + string provider = 11; + string referrer = 12; + string referrer_version = 13; + string referrer_vendor = 14; + StreamingRule streaming_rule = 15; + string connect_controller_device_id = 16; + string page_instance_id = 17; + string interaction_id = 18; + PlaySource source_start = 19; + PlayReason reason_start = 20; + bool is_live = 22; + bool is_shuffle = 23; + bool is_offlined = 24; + bool is_incognito = 25; +} diff --git a/protocol/proto/stream_prepare_response.proto b/protocol/proto/stream_prepare_response.proto new file mode 100644 index 00000000..2f5a2c4e --- /dev/null +++ b/protocol/proto/stream_prepare_response.proto @@ -0,0 +1,18 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "status_response.proto"; +import "stream_handle.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamPrepareResponse { + oneof response { + StatusResponse status = 1; + StreamHandle stream_handle = 2; + } +} diff --git a/protocol/proto/stream_progress_request.proto b/protocol/proto/stream_progress_request.proto new file mode 100644 index 00000000..63fe9d80 --- /dev/null +++ b/protocol/proto/stream_progress_request.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "stream_handle.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamProgressRequest { + StreamHandle stream_handle = 1; + uint64 current_position = 2; + bool is_paused = 3; + bool is_playing_video = 4; + bool is_overlapping = 5; + bool is_background = 6; + bool is_fullscreen = 7; + bool is_external = 8; + double playback_speed = 9; +} diff --git a/protocol/proto/stream_seek_request.proto b/protocol/proto/stream_seek_request.proto new file mode 100644 index 00000000..3736abf9 --- /dev/null +++ b/protocol/proto/stream_seek_request.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "stream_handle.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamSeekRequest { + StreamHandle stream_handle = 1; +} diff --git a/protocol/proto/stream_start_request.proto b/protocol/proto/stream_start_request.proto new file mode 100644 index 00000000..3c4bfbb6 --- /dev/null +++ b/protocol/proto/stream_start_request.proto @@ -0,0 +1,20 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +import "format.proto"; +import "media_type.proto"; +import "stream_handle.proto"; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +message StreamStartRequest { + StreamHandle stream_handle = 1; + string media_id = 2; + MediaType media_type = 3; + Format format = 4; + uint64 playback_start_time = 5; +} diff --git a/protocol/proto/streaming_rule.proto b/protocol/proto/streaming_rule.proto new file mode 100644 index 00000000..d72d7ca5 --- /dev/null +++ b/protocol/proto/streaming_rule.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.stream_reporting_esperanto.proto; + +option objc_class_prefix = "ESP"; +option java_package = "com.spotify.stream_reporting_esperanto.proto"; + +enum StreamingRule { + RULE_UNSET = 0; + RULE_NONE = 1; + RULE_DMCA_RADIO = 2; + RULE_PREVIEW = 3; + RULE_WIFI = 4; + RULE_SHUFFLE_MODE = 5; +} diff --git a/protocol/proto/suggest.proto b/protocol/proto/suggest.proto deleted file mode 100644 index ef45f1e2..00000000 --- a/protocol/proto/suggest.proto +++ /dev/null @@ -1,43 +0,0 @@ -syntax = "proto2"; - -message Track { - optional bytes gid = 0x1; - optional string name = 0x2; - optional bytes image = 0x3; - repeated string artist_name = 0x4; - repeated bytes artist_gid = 0x5; - optional uint32 rank = 0x6; -} - -message Artist { - optional bytes gid = 0x1; - optional string name = 0x2; - optional bytes image = 0x3; - optional uint32 rank = 0x6; -} - -message Album { - optional bytes gid = 0x1; - optional string name = 0x2; - optional bytes image = 0x3; - repeated string artist_name = 0x4; - repeated bytes artist_gid = 0x5; - optional uint32 rank = 0x6; -} - -message Playlist { - optional string uri = 0x1; - optional string name = 0x2; - optional string image_uri = 0x3; - optional string owner_name = 0x4; - optional string owner_uri = 0x5; - optional uint32 rank = 0x6; -} - -message Suggestions { - repeated Track track = 0x1; - repeated Album album = 0x2; - repeated Artist artist = 0x3; - repeated Playlist playlist = 0x4; -} - diff --git a/protocol/proto/suppressions.proto b/protocol/proto/suppressions.proto new file mode 100644 index 00000000..4ddfaefb --- /dev/null +++ b/protocol/proto/suppressions.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message Suppressions { + repeated string providers = 1; +} diff --git a/protocol/proto/sync/album_sync_state.proto b/protocol/proto/sync/album_sync_state.proto new file mode 100644 index 00000000..7ea90276 --- /dev/null +++ b/protocol/proto/sync/album_sync_state.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message AlbumSyncState { + optional string offline = 1; + optional string inferred_offline = 2; + optional uint32 sync_progress = 3; +} diff --git a/protocol/proto/sync/artist_sync_state.proto b/protocol/proto/sync/artist_sync_state.proto new file mode 100644 index 00000000..03ba32f3 --- /dev/null +++ b/protocol/proto/sync/artist_sync_state.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message ArtistSyncState { + optional string offline = 1; + optional string inferred_offline = 2; + optional uint32 sync_progress = 3; +} diff --git a/protocol/proto/sync/episode_sync_state.proto b/protocol/proto/sync/episode_sync_state.proto new file mode 100644 index 00000000..7dce8424 --- /dev/null +++ b/protocol/proto/sync/episode_sync_state.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message EpisodeSyncState { + optional string offline_state = 1; + optional uint32 sync_progress = 2; +} diff --git a/protocol/proto/sync/track_sync_state.proto b/protocol/proto/sync/track_sync_state.proto new file mode 100644 index 00000000..8873fad5 --- /dev/null +++ b/protocol/proto/sync/track_sync_state.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.cosmos_util.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.cosmos.util.proto"; + +message TrackSyncState { + optional string offline = 1; + optional uint32 sync_progress = 2; +} diff --git a/protocol/proto/sync_request.proto b/protocol/proto/sync_request.proto new file mode 100644 index 00000000..090f8dce --- /dev/null +++ b/protocol/proto/sync_request.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.playlist.cosmos.proto; + +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_package = "com.spotify.playlist.proto"; + +message SyncRequest { + repeated string playlist_uris = 1; +} diff --git a/protocol/proto/techu_core_exercise_cosmos.proto b/protocol/proto/techu_core_exercise_cosmos.proto new file mode 100644 index 00000000..155a303f --- /dev/null +++ b/protocol/proto/techu_core_exercise_cosmos.proto @@ -0,0 +1,16 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.techu_core_exercise_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message TechUCoreExerciseRequest { + string a = 1; + string b = 2; +} + +message TechUCoreExerciseResponse { + string concatenated = 1; +} diff --git a/protocol/proto/test_request_failure.proto b/protocol/proto/test_request_failure.proto new file mode 100644 index 00000000..036e38e1 --- /dev/null +++ b/protocol/proto/test_request_failure.proto @@ -0,0 +1,14 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto2"; + +package spotify.image.proto; + +option optimize_for = CODE_SIZE; + +message TestRequestFailure { + optional string request = 1; + optional string source = 2; + optional string error = 3; + optional int64 result = 4; +} diff --git a/protocol/proto/toplist.proto b/protocol/proto/toplist.proto deleted file mode 100644 index 1a12159f..00000000 --- a/protocol/proto/toplist.proto +++ /dev/null @@ -1,6 +0,0 @@ -syntax = "proto2"; - -message Toplist { - repeated string items = 0x1; -} - diff --git a/protocol/proto/track_instance.proto b/protocol/proto/track_instance.proto new file mode 100644 index 00000000..952f28c8 --- /dev/null +++ b/protocol/proto/track_instance.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "context_index.proto"; +import "context_track.proto"; +import "seek_to_position.proto"; + +option optimize_for = CODE_SIZE; + +message TrackInstance { + optional ContextTrack track = 1; + optional uint64 id = 2; + optional SeekToPosition seek_to_position = 7; + optional bool initially_paused = 4; + optional ContextIndex index = 5; + optional string provider = 6; + + reserved 3; +} diff --git a/protocol/proto/track_instantiator.proto b/protocol/proto/track_instantiator.proto new file mode 100644 index 00000000..3b8b8baf --- /dev/null +++ b/protocol/proto/track_instantiator.proto @@ -0,0 +1,13 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +option optimize_for = CODE_SIZE; + +message TrackInstantiator { + optional uint64 unique = 1; + optional uint64 count = 2; + optional string provider = 3; +} diff --git a/protocol/proto/track_offlining_cosmos_response.proto b/protocol/proto/track_offlining_cosmos_response.proto new file mode 100644 index 00000000..bb650607 --- /dev/null +++ b/protocol/proto/track_offlining_cosmos_response.proto @@ -0,0 +1,24 @@ +// Extracted from: Spotify 1.1.33.569 (Windows) + +syntax = "proto2"; + +package spotify.track_offlining_cosmos.proto; + +option optimize_for = CODE_SIZE; + +message DecoratedTrack { + optional string uri = 1; + optional string title = 2; +} + +message ListResponse { + repeated string uri = 1; +} + +message DecorateResponse { + repeated DecoratedTrack tracks = 1; +} + +message StatusResponse { + optional bool offline = 1; +} diff --git a/protocol/proto/transcripts.proto b/protocol/proto/transcripts.proto new file mode 100644 index 00000000..05ac7fbb --- /dev/null +++ b/protocol/proto/transcripts.proto @@ -0,0 +1,23 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.corex.transcripts.metadata; + +option objc_class_prefix = "SPT"; +option java_multiple_files = true; +option optimize_for = CODE_SIZE; +option java_outer_classname = "TranscriptMetadataProto"; +option java_package = "com.spotify.corex.transcripts.metadata.proto"; + +message EpisodeTranscript { + string episode_uri = 1; + repeated Transcript transcripts = 2; +} + +message Transcript { + string uri = 1; + string language = 2; + bool curated = 3; + string cdn_url = 4; +} diff --git a/protocol/proto/transfer_node.proto b/protocol/proto/transfer_node.proto new file mode 100644 index 00000000..e5bbc03e --- /dev/null +++ b/protocol/proto/transfer_node.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto; + +import "track_instance.proto"; +import "track_instantiator.proto"; + +option optimize_for = CODE_SIZE; + +message TransferNode { + optional TrackInstance instance = 1; + optional TrackInstantiator instantiator = 2; +} diff --git a/protocol/proto/transfer_state.proto b/protocol/proto/transfer_state.proto new file mode 100644 index 00000000..200547c0 --- /dev/null +++ b/protocol/proto/transfer_state.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.player.proto.transfer; + +import "context_player_options.proto"; +import "playback.proto"; +import "session.proto"; +import "queue.proto"; + +option optimize_for = CODE_SIZE; + +message TransferState { + optional ContextPlayerOptions options = 1; + optional Playback playback = 2; + optional Session current_session = 3; + optional Queue queue = 4; +} diff --git a/protocol/proto/tts-resolve.proto b/protocol/proto/tts-resolve.proto new file mode 100644 index 00000000..89956843 --- /dev/null +++ b/protocol/proto/tts-resolve.proto @@ -0,0 +1,49 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.narration_injection.proto; + +option optimize_for = CODE_SIZE; + +service TtsResolveService { + rpc Resolve(ResolveRequest) returns (ResolveResponse); +} + +message ResolveRequest { + AudioFormat audio_format = 3; + enum AudioFormat { + UNSPECIFIED = 0; + WAV = 1; + PCM = 2; + OPUS = 3; + VORBIS = 4; + MP3 = 5; + } + + string language = 4; + + TtsVoice tts_voice = 5; + enum TtsVoice { + UNSET_TTS_VOICE = 0; + VOICE1 = 1; + VOICE2 = 2; + VOICE3 = 3; + } + + TtsProvider tts_provider = 6; + enum TtsProvider { + UNSET_TTS_PROVIDER = 0; + CLOUD_TTS = 1; + READSPEAKER = 2; + } + + oneof prompt { + string text = 1; + string ssml = 2; + } +} + +message ResolveResponse { + string url = 1; +} diff --git a/protocol/proto/ucs.proto b/protocol/proto/ucs.proto new file mode 100644 index 00000000..c5048f8c --- /dev/null +++ b/protocol/proto/ucs.proto @@ -0,0 +1,56 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.ucs.proto; + +import "resolve.proto"; +import "useraccount.proto"; + +option optimize_for = CODE_SIZE; + +message UcsRequest { + CallerInfo caller_info = 1; + message CallerInfo { + string request_origin_id = 1; + string request_orgin_version = 2; + string reason = 3; + } + + ResolveRequest resolve_request = 2; + + AccountAttributesRequest account_attributes_request = 3; + message AccountAttributesRequest { + + } +} + +message UcsResponseWrapper { + oneof result { + UcsResponse success = 1; + Error error = 2; + } + + message UcsResponse { + int64 fetch_time_millis = 5; + + oneof resolve_result { + ResolveResponse resolve_success = 1; + Error resolve_error = 2; + } + + oneof account_attributes_result { + AccountAttributesResponse account_attributes_success = 3; + Error account_attributes_error = 4; + } + } + + message AccountAttributesResponse { + map account_attributes = 1; + } + + message Error { + int32 error_code = 1; + string error_message = 2; + } +} diff --git a/protocol/proto/unfinished_episodes_request.proto b/protocol/proto/unfinished_episodes_request.proto new file mode 100644 index 00000000..1e152bd6 --- /dev/null +++ b/protocol/proto/unfinished_episodes_request.proto @@ -0,0 +1,24 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto2"; + +package spotify.show_cosmos.unfinished_episodes_request.proto; + +import "metadata/episode_metadata.proto"; +import "show_episode_state.proto"; + +option optimize_for = CODE_SIZE; + +message Episode { + optional cosmos_util.proto.EpisodeMetadata episode_metadata = 1; + optional show_cosmos.proto.EpisodeCollectionState episode_collection_state = 2; + optional show_cosmos.proto.EpisodeOfflineState episode_offline_state = 3; + optional show_cosmos.proto.EpisodePlayState episode_play_state = 4; + optional string link = 5; +} + +message Response { + repeated Episode episode = 2; + + reserved 1; +} diff --git a/protocol/proto/useraccount.proto b/protocol/proto/useraccount.proto new file mode 100644 index 00000000..ca8fea90 --- /dev/null +++ b/protocol/proto/useraccount.proto @@ -0,0 +1,15 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.remote_config.ucs.proto; + +option optimize_for = CODE_SIZE; + +message AccountAttribute { + oneof value { + bool bool_value = 2; + int64 long_value = 3; + string string_value = 4; + } +} diff --git a/protocol/proto/your_library_contains_request.proto b/protocol/proto/your_library_contains_request.proto new file mode 100644 index 00000000..33672bad --- /dev/null +++ b/protocol/proto/your_library_contains_request.proto @@ -0,0 +1,11 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +option optimize_for = CODE_SIZE; + +message YourLibraryContainsRequest { + repeated string requested_uri = 3; +} diff --git a/protocol/proto/your_library_contains_response.proto b/protocol/proto/your_library_contains_response.proto new file mode 100644 index 00000000..641d71a5 --- /dev/null +++ b/protocol/proto/your_library_contains_response.proto @@ -0,0 +1,22 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +option optimize_for = CODE_SIZE; + +message YourLibraryContainsResponseHeader { + bool is_loading = 2; +} + +message YourLibraryContainsResponseEntity { + string uri = 1; + bool is_in_library = 2; +} + +message YourLibraryContainsResponse { + YourLibraryContainsResponseHeader header = 1; + repeated YourLibraryContainsResponseEntity entity = 2; + string error = 99; +} diff --git a/protocol/proto/your_library_decorate_request.proto b/protocol/proto/your_library_decorate_request.proto new file mode 100644 index 00000000..e3fccc29 --- /dev/null +++ b/protocol/proto/your_library_decorate_request.proto @@ -0,0 +1,17 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +import "your_library_request.proto"; + +option optimize_for = CODE_SIZE; + +message YourLibraryDecorateRequest { + repeated string requested_uri = 3; + YourLibraryLabelAndImage liked_songs_label_and_image = 201; + YourLibraryLabelAndImage your_episodes_label_and_image = 202; + YourLibraryLabelAndImage new_episodes_label_and_image = 203; + YourLibraryLabelAndImage local_files_label_and_image = 204; +} diff --git a/protocol/proto/your_library_decorate_response.proto b/protocol/proto/your_library_decorate_response.proto new file mode 100644 index 00000000..dab14203 --- /dev/null +++ b/protocol/proto/your_library_decorate_response.proto @@ -0,0 +1,19 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +import "your_library_response.proto"; + +option optimize_for = CODE_SIZE; + +message YourLibraryDecorateResponseHeader { + bool is_loading = 2; +} + +message YourLibraryDecorateResponse { + YourLibraryDecorateResponseHeader header = 1; + repeated YourLibraryResponseEntity entity = 2; + string error = 99; +} diff --git a/protocol/proto/your_library_entity.proto b/protocol/proto/your_library_entity.proto new file mode 100644 index 00000000..acb5afe7 --- /dev/null +++ b/protocol/proto/your_library_entity.proto @@ -0,0 +1,21 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +import "your_library_index.proto"; +import "collection_index.proto"; + +option optimize_for = CODE_SIZE; + +message YourLibraryEntity { + bool pinned = 1; + + oneof entity { + collection.proto.CollectionAlbumEntry album = 2; + YourLibraryArtistEntity artist = 3; + YourLibraryRootlistEntity rootlist_entity = 4; + YourLibraryShowEntity show = 5; + } +} diff --git a/protocol/proto/your_library_index.proto b/protocol/proto/your_library_index.proto new file mode 100644 index 00000000..2d452dd5 --- /dev/null +++ b/protocol/proto/your_library_index.proto @@ -0,0 +1,60 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +option optimize_for = CODE_SIZE; + +message YourLibraryArtistEntity { + string uri = 1; + string name = 2; + string image_uri = 3; + int64 add_time = 4; +} + +message YourLibraryRootlistPlaylist { + string image_uri = 1; + bool is_on_demand_in_free = 2; + bool is_loading = 3; + int32 rootlist_index = 4; +} + +message YourLibraryRootlistFolder { + int32 number_of_playlists = 1; + int32 number_of_folders = 2; + int32 rootlist_index = 3; +} + +message YourLibraryRootlistCollection { + Kind kind = 1; + enum Kind { + LIKED_SONGS = 0; + YOUR_EPISODES = 1; + NEW_EPISODES = 2; + LOCAL_FILES = 3; + } +} + +message YourLibraryRootlistEntity { + string uri = 1; + string name = 2; + string creator_name = 3; + int64 add_time = 4; + + oneof entity { + YourLibraryRootlistPlaylist playlist = 5; + YourLibraryRootlistFolder folder = 6; + YourLibraryRootlistCollection collection = 7; + } +} + +message YourLibraryShowEntity { + string uri = 1; + string name = 2; + string creator_name = 3; + string image_uri = 4; + int64 add_time = 5; + bool is_music_and_talk = 6; + int64 publish_date = 7; +} diff --git a/protocol/proto/your_library_request.proto b/protocol/proto/your_library_request.proto new file mode 100644 index 00000000..a75a0544 --- /dev/null +++ b/protocol/proto/your_library_request.proto @@ -0,0 +1,74 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +option optimize_for = CODE_SIZE; + +message YourLibraryRequestEntityInfo { + +} + +message YourLibraryRequestAlbumExtraInfo { + +} + +message YourLibraryRequestArtistExtraInfo { + +} + +message YourLibraryRequestPlaylistExtraInfo { + +} + +message YourLibraryRequestShowExtraInfo { + +} + +message YourLibraryRequestFolderExtraInfo { + +} + +message YourLibraryLabelAndImage { + string label = 1; + string image = 2; +} + +message YourLibraryRequestLikedSongsExtraInfo { + YourLibraryLabelAndImage label_and_image = 101; +} + +message YourLibraryRequestYourEpisodesExtraInfo { + YourLibraryLabelAndImage label_and_image = 101; +} + +message YourLibraryRequestNewEpisodesExtraInfo { + YourLibraryLabelAndImage label_and_image = 101; +} + +message YourLibraryRequestLocalFilesExtraInfo { + YourLibraryLabelAndImage label_and_image = 101; +} + +message YourLibraryRequestEntity { + YourLibraryRequestEntityInfo entityInfo = 1; + YourLibraryRequestAlbumExtraInfo album = 2; + YourLibraryRequestArtistExtraInfo artist = 3; + YourLibraryRequestPlaylistExtraInfo playlist = 4; + YourLibraryRequestShowExtraInfo show = 5; + YourLibraryRequestFolderExtraInfo folder = 6; + YourLibraryRequestLikedSongsExtraInfo liked_songs = 8; + YourLibraryRequestYourEpisodesExtraInfo your_episodes = 9; + YourLibraryRequestNewEpisodesExtraInfo new_episodes = 10; + YourLibraryRequestLocalFilesExtraInfo local_files = 11; +} + +message YourLibraryRequestHeader { + bool remaining_entities = 9; +} + +message YourLibraryRequest { + YourLibraryRequestHeader header = 1; + YourLibraryRequestEntity entity = 2; +} diff --git a/protocol/proto/your_library_response.proto b/protocol/proto/your_library_response.proto new file mode 100644 index 00000000..124b35b4 --- /dev/null +++ b/protocol/proto/your_library_response.proto @@ -0,0 +1,112 @@ +// Extracted from: Spotify 1.1.61.583 (Windows) + +syntax = "proto3"; + +package spotify.your_library.proto; + +option optimize_for = CODE_SIZE; + +message YourLibraryEntityInfo { + string key = 1; + string name = 2; + string uri = 3; + string group_label = 5; + string image_uri = 6; + bool pinned = 7; + + Pinnable pinnable = 8; + enum Pinnable { + YES = 0; + NO_IN_FOLDER = 1; + } +} + +message Offline { + enum Availability { + UNKNOWN = 0; + NO = 1; + YES = 2; + DOWNLOADING = 3; + WAITING = 4; + } +} + +message YourLibraryAlbumExtraInfo { + string artist_name = 1; + Offline.Availability offline_availability = 3; +} + +message YourLibraryArtistExtraInfo { + int32 num_tracks_in_collection = 1; +} + +message YourLibraryPlaylistExtraInfo { + string creator_name = 1; + Offline.Availability offline_availability = 3; + bool is_loading = 5; +} + +message YourLibraryShowExtraInfo { + string creator_name = 1; + Offline.Availability offline_availability = 3; + int64 publish_date = 4; + bool is_music_and_talk = 5; +} + +message YourLibraryFolderExtraInfo { + int32 number_of_playlists = 2; + int32 number_of_folders = 3; +} + +message YourLibraryLikedSongsExtraInfo { + Offline.Availability offline_availability = 2; + int32 number_of_songs = 3; +} + +message YourLibraryYourEpisodesExtraInfo { + Offline.Availability offline_availability = 2; + int32 number_of_episodes = 3; +} + +message YourLibraryNewEpisodesExtraInfo { + int64 publish_date = 1; +} + +message YourLibraryLocalFilesExtraInfo { + int32 number_of_files = 1; +} + +message YourLibraryResponseEntity { + YourLibraryEntityInfo entityInfo = 1; + + oneof entity { + YourLibraryAlbumExtraInfo album = 2; + YourLibraryArtistExtraInfo artist = 3; + YourLibraryPlaylistExtraInfo playlist = 4; + YourLibraryShowExtraInfo show = 5; + YourLibraryFolderExtraInfo folder = 6; + YourLibraryLikedSongsExtraInfo liked_songs = 8; + YourLibraryYourEpisodesExtraInfo your_episodes = 9; + YourLibraryNewEpisodesExtraInfo new_episodes = 10; + YourLibraryLocalFilesExtraInfo local_files = 11; + } +} + +message YourLibraryResponseHeader { + bool has_albums = 1; + bool has_artists = 2; + bool has_playlists = 3; + bool has_shows = 4; + bool has_downloaded_albums = 5; + bool has_downloaded_artists = 6; + bool has_downloaded_playlists = 7; + bool has_downloaded_shows = 8; + int32 remaining_entities = 9; + bool is_loading = 12; +} + +message YourLibraryResponse { + YourLibraryResponseHeader header = 1; + repeated YourLibraryResponseEntity entity = 2; + string error = 99; +}