Integration fields pull data from custom API using Bearer token

Hi Prismic team, I have successfully set up pull from custom API but I am struggling to protect it with a token.
I've filled the Access token field in my custom API but it gives an error examining webserver logs it gives a 401 error. Digging a little bit further it looks that Access token is not really used as expected - as a token. The request from prismic is created with the header "Authorization: Basic provided_token_base64_encoded"
If your intention was to use Basic authentication please reflect this in the documentation, but I have to say this is really a poor decision. A Bearer token would be much more useful solution and will even require less work on your end. Oauth2 would be even better.
Can you please comment on this, is this an error, and when do you plan to fix it?
Thanks in advance.

Hey there.

Integration fields' API uses Bearer authentication tokens for each request. Where are you getting this warning from?

HI @Pau, thanks for responding
I have a Custom Integration field that fetches data from an external endpoint. The integration works correctly, I have verified it. I am trying to secure the endpoint using a token:


I believe you are talking about pushing data from external source to Prismic API.
I can see the 401 errors in the logs of the nginx server on my API Endpoint created when Prismic tries to pull data.

Hello @test.johnwalker, I've consulted this with the team. I can confirm that, for pulling data from the Integration field, the token is indeed a basic auth instead of a bearer token. We've updated the documentation to correctly reflect this information.