adrianhajdin / project_music_player

Master modern web development by building an improved version of Spotify. With a modern homepage, fully-fledged music player, search, lyrics, song exploration features, search, popular music around you, worldwide top charts, and much more, this is the best music application you can currently find on YouTube.
https://jsmastery.pro
1.02k stars 287 forks source link

Lyrics not found #42

Open zhane123 opened 8 months ago

zhane123 commented 8 months ago

The original lyrics api has depreciated and new one is https://shazam-core.p.rapidapi.com/v2/tracks/details'

However it still does not work?

My shazamCore Code looks like this:

`import { createApi, fetchBaseQuery } from "@reduxjs/toolkit/query/react";

export const shazamCoreApi = createApi({ reducerPath: "shazamCoreApi", baseQuery: fetchBaseQuery({ baseUrl: "https://shazam-core.p.rapidapi.com/", prepareHeaders: (headers) => { headers.set( "X-RapidAPI-Key", "e919fc6e47msh434a4c7817b528dp1d9dc2jsn46121b2f2e3d" ); return headers; }, }), endpoints: (builder) => ({ getTopCharts: builder.query({ query: () => "v1/charts/world" }), getSongsByGenre: builder.query({ query: (genre) => v1/charts/genre-world?genre_code=${genre}, }), getSongsByCountry: builder.query({ query: (countryCode) => v1/charts/country?country_code=${countryCode}, }), getSongsBySearch: builder.query({ query: (searchTerm) => v1/search/multi?search_type=SONGS_ARTISTS&query=${searchTerm}, }), getArtistDetails: builder.query({ query: (artistId) => v2/artists/details?artist_id=${artistId}, }), getSongDetails: builder.query({ query: ({ songid }) => v2/tracks/details?track_id=${songid}, }), getSongRelated: builder.query({ query: ({ songid }) => v1/tracks/related?track_id=${songid}, }), }), });

export const { useGetTopChartsQuery, useGetSongsByGenreQuery, useGetSongsByCountryQuery, useGetSongsBySearchQuery, useGetArtistDetailsQuery, useGetSongDetailsQuery, useGetSongRelatedQuery, } = shazamCoreApi; `

What am I doing wrong?

rishu15 commented 8 months ago

I have the same issue, apparently shazam core api does not provide lyrics anymore. Navigate to https://rapidapi.com/tipsters/api/shazam-core and test the "Track Details" endpoint by track id the result does not contain lyrics

shubhamrathod0015 commented 4 months ago

@zhane123 and @rishu15 did you solve your problem or not