Postman: Sending Request with headers

你。 提交于 2021-02-10 17:56:36

问题


I am trying to consume an API and the instructions are below:

To send authenticated requests, provide the client_id and client_secret values as a base64 encoded HTTP Authorization header.

curl --user {YOUR_CLIENT_ID}:{YOUR_CLIENT_SECRET} https://www.somewebsite.com/api-2.0/something

I am sending the request like this:

Postman builder screenshot[1

What am I doing wrong?


回答1:


Use the Basic Auth in the Authorization tab. If you add those details as the Username / Password it will create the Base64 encoded header for you and add this to the request.

The header will look like this:



来源:https://stackoverflow.com/questions/48769575/postman-sending-request-with-headers

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!