Here is an authorization header that I use in Ruby:
headers = { ‘Authorization’ => “Bearer #{do_api_key}” }
So I think that you need to add Bearer
beforeyour api key.
Here are headers:
headers = { 'api-key' => discourse_api_key, 'api-username' => 'system' }
So I think you need headers like those. Discourse API Documentation is supposed to help with that.