Rest CountriesAPI filter data

I use Rest CountriesAPI, They write such for response data


I tried too these API links but not working.

https://restcountries.eu/rest/v2/name?fields=name;capital;currencies
https://restcountries.eu/rest/v2/name?fields=name;capital;currencies=turkey
https://restcountries.eu/rest/v2/name?fields=name;capital;currencies/turkey

How should ı write for filtered data as the name?
API document link: REST Countries

I don’t understand, “How should ı write for filtered data as the name?”

If you want just the names, it would be:

https://restcountries.eu/rest/v2/all?fields=name

Looking at the docs, if you want just info for Turkey, it would be:

https://restcountries.eu/rest/v2/name/turkey?fullText=true

Does that answer your question?

1 Like

The second was true. If ı write such as;

https://restcountries.eu/rest/v2/name/turkey?fields=name;currencies

Thanks. I did want a special country not all.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.