Having trouble figuring out OAuth authentication for downloading

37 views
Skip to first unread message

Hari Durai Baskar

unread,
Oct 14, 2024, 2:30:17 AM10/14/24
to Freesound API

Hello,

I received my API key and I wish to download sounds via curl like in the API docs.

Let's pretend my API key is abCDEFghijkLMNOP123456789 and the sound I want has an id of 12345.

The docs are kind of confusing me because of the brackets, but according to the docs I need to do this:

curl -H "Authorization: Bearer {{abCDEFghijkLMNOP123456789}}" 'https://freesound.org/apiv2/sounds/12345/download/'

Now when I run the above I get this from curl in response:

{"detail":"Authentication credentials were not provided."}

What am I doing wrong?

Frederic Font Corbera

unread,
Oct 14, 2024, 2:35:44 AM10/14/24
to freeso...@googlegroups.com
Hi,

Thanks for the message. You should not include the brackets, did you try without them?

Cheers,

frederic


--
Frederic Font - ffont.github.io
Music Technology Group, UPF - mtg.upf.edu
Freesound - freesound.org



--

---
You received this message because you are subscribed to the Google Groups "Freesound API" group.
To unsubscribe from this group and stop receiving emails from it, send an email to freesound-ap...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/freesound-api/1c564d42-ea45-4afb-a641-72a28f575930n%40googlegroups.com.

Hari Durai Baskar

unread,
Oct 14, 2024, 2:54:05 AM10/14/24
to Freesound API
Hi Fredric,
I tried this: curl -H "Authorization: freesound abcdefg123456" 'https://freesound.org/apiv2/sounds/632625/download/'

freesound is the name of my api credential i created.
Reply all
Reply to author
Forward
0 new messages