question

webforte avatar image
webforte asked David Marginian commented

401 unauthorized in API response

e-commerce api
10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

David Marginian avatar image
David Marginian answered

Tokens need to have the correct permissions for the call you are making (in this case, Customer Read) - https://community.clover.com/articles/23744/resolving-401-unauthorized-responses-when-making-a.html.

10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

webforte avatar image
webforte answered David Marginian commented

In the documentation https://docs.clover.com/docs/using-oauth-20, i am using step 2 token to get access_token via API (https://sandbox.dev.clover.com/oauth/token?client_id={appId}&client_secret={APP_SECRET}&code={AUTHORIZATION_CODE}), but getting 401 when using this fetched access_token as authorization header in API https://scl-sandbox.dev.clover.com/v1/customers

1 comment
10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

I answered your question below:

Tokens need to have the correct permissions for the call you are making (in this case, Customer Read) - https://community.clover.com/articles/23744/resolving-401-unauthorized-responses-when-making-a.html.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community