{"id":19795055,"url":"https://github.com/skproch/yandexmusicresolver","last_synced_at":"2025-05-01T03:30:18.532Z","repository":{"id":55088112,"uuid":"327693147","full_name":"SKProCH/YandexMusicResolver","owner":"SKProCH","description":"A library aimed at searching, resolving and getting direct links to tracks, playlists or albums in Yandex.Music. Can work without authorization.","archived":false,"fork":false,"pushed_at":"2024-08-23T17:40:01.000Z","size":207,"stargazers_count":6,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-04T16:44:32.274Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SKProCH.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2021-01-07T18:25:39.000Z","updated_at":"2024-08-23T17:39:53.000Z","dependencies_parsed_at":"2024-01-15T00:55:17.454Z","dependency_job_id":null,"html_url":"https://github.com/SKProCH/YandexMusicResolver","commit_stats":{"total_commits":94,"total_committers":2,"mean_commits":47.0,"dds":0.1063829787234043,"last_synced_commit":"012a0644e38bc2bfa7a9348c2aa05febffea09df"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SKProCH%2FYandexMusicResolver","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SKProCH%2FYandexMusicResolver/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SKProCH%2FYandexMusicResolver/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SKProCH%2FYandexMusicResolver/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SKProCH","download_url":"https://codeload.github.com/SKProCH/YandexMusicResolver/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251817796,"owners_count":21648807,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T07:15:17.865Z","updated_at":"2025-05-01T03:30:18.114Z","avatar_url":"https://github.com/SKProCH.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ![](https://raw.githubusercontent.com/SKProCH/YandexMusicResolver/dev/icon.png) YandexMusicResolver\nA library aimed at searching, resolving and getting direct links to tracks, playlists or albums in Yandex.Music.  \nCan work without authorization.\n\n## Getting started\n\n1. Add [nuget package](https://www.nuget.org/packages/YandexMusicResolver/) to your project:\n\n    ```\n    dotnet add package YandexMusicResolver\n    ```\n2. You need somehow to instantiate `YandexMusicMainResolver`.\n   - If you are using dependency injection, use `.AddYandexMusicResolver()` to your `IServiceCollection`. E.g.: \n     ```csharp\n     var serviceCollection = new ServiceCollection();\n     serviceCollection.AddYandexMusicResolver();\n\n     var serviceProvider = serviceCollection.BuildServiceProvider();\n     // Resolve the IYandexMusicMainResolver\n     var yandexMusicMainResolver = serviceProvider.GetRequiredService\u003cIYandexMusicMainResolver\u003e();\n     ```\n   - Or instantiate it as usually:\n     1. Create auth service instance (`YandexMusicAuthService` this is the default implementation):\n         ```csharp#\n         var authService = new YandexMusicAuthService(httpClient);\n         ```\n         Actually, **preferred way is to use `IHttpClientFactory`** to pass it to all services.\n         If you use `IHttpClientFactory` default HttpClient name is `YandexMusic`.\n    \n     2. Create credentials provider instance (`YandexCredentialsProvider` this is the default implementation):\n         ```csharp#\n         var credentialProvider = new YandexMusicAuthService(authService, \"Login\", \"Pass\");\n         ```\n\n     3. Create an instance of `YandexMusicMainResolver` and pass config to it\n         ```csharp\n         var yandexMusicMainResolver = new YandexMusicMainResolver(credentialProvider, httpClient);\n         ```\n     Full example:\n     ```csharp\n     var httpClient = new HttpClient();\n     var authService = new YandexMusicAuthService.Create(httpClient);\n     var credentialProvider = new YandexMusicAuthService.Create(authService, \"Login\", \"Pass\");\n     var yandexMusicMainResolver = new YandexMusicMainResolver.Create(credentialProvider, httpClient);\n     ```\n3. After that you can use different methods and properties of `IYandexMusicMainResolver`.\n   Example code for getting direct track download url:\n   ```c#\n   var directUrl = await yandexMusicMainResolver.DirectUrlLoader.GetDirectUrl(\"55561798\");\n   Console.WriteLine(directUrl);\n   ```\n   \u003e [!IMPORTANT]  \n   \u003e Yandex will return a link to a 30-seconds track if you do not log in (do not use a config with a valid token).\n\nYou can take a look at unit test project for additional examples.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskproch%2Fyandexmusicresolver","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fskproch%2Fyandexmusicresolver","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskproch%2Fyandexmusicresolver/lists"}