New API Key Not Working

If I use my API key and the example code on this page, I get “invalid API Key” error. Works if I use the example key.

Anyone else?

FYI, rotated my API key about 10 minutes ago.

If I try to use my Picard AcoustID API key on the example I get the same failure, but if I submit IDs from Picard I have no issues with the key. I wrote a pearl script to query the API to get the ID from the fingerprint but still only use the example key which changes regularly, so not sure if there is an issue. In the past I have had a few hiccups submitting fingerprints from Picard and rotated my key just in case, but that did not solve the issue at the time.

Edit: After looking more there are appears to be two API keys, a USER key and a CLIENT key, it appears the Picard key is a USER key, but not sure. So if the key you rotated is the Picard key it probably will not work with the example.

2 Likes

I’m not sure if something changed. But there are two keys: One is the client parameter. This is meant to be setup for the application and is needed for all API requests. If you are logged in on AcoustID you can manage those keys on https://acoustid.org/my-applications. For users of Picard this is not needed, Picard already has this included.

The other is the user key, which is only needed for submission and is meant to be per user. On AcoustID you can change this at https://acoustid.org/api-key. This is also the key users have to configure in Picard in order to submit fingerprints.

4 Likes

ah thanks to you and @dashv i’ll give it another go shortly :slight_smile:

never knew there were two keys

2 Likes