I am working on Youtube API.
The base URL is <https://www.googleapis.com/youtube/v3/search/>
Request :GET
https://www.googleapis.com/youtube/v3/search?part=snippet&q={search_keyword}&key={API_KEY}
ApiService Interface code-
public interface ApiService {
@GET("")
Call<YoutubeResponse> searchVideos(@Query("part") String part,
@Query("q") String q,@Query("key") String apiKey);
}
The error: java.lang.IllegalArgumentException: Missing either @GET URL or @Url parameter. in the line of code
Call<YoutubeResponse> call=service.searchVideos("snippet",s, URLConstants.Youtube_API_KEY);
I'm a beginner. Please help!