H
H
HelgaSel2021-02-15 14:20:07
API
HelgaSel, 2021-02-15 14:20:07

How to make authorization in Postman?

Good afternoon. Please advise how to correctly create requests using any convenient client REST API: auth and token?
I am currently using Postman. In communication with the API, I am a complete zero. Therefore, help is needed. In general, where to start:
1. Created a collection.
2. I use the Post method (is that right?)
3. I enter all the data and get a 405 error in response (picture 1) 602a52384ebf4953469391.jpeg
4. I tried with the Get method, I understand that this is a little different, the answer came out like this: 602a5294e606a269807390.jpeg
But I didn’t receive the password.
5. I also tried using Oauth2, I got a new window on the sandbox site: https://sb.mdlp.crpt.ru/?response_type=code&state=...
So the question is, what am I doing wrong?
There is only such data:
POST api/v1/auth HTTP/1.1
Host: api.sb.mdlp.crpt.ru
Accept: application/json
Content-Type: application/json
{
"client_id": "b7fd3898-c77d-4f57-ba5d-b6a730dd1281",
"client_secret": "ed26b871-00f1-43be -b228-b37a9915ac9d",
"user_id": "bfba7d15072f30f2266f9c7be649276ce5c1c944",
"auth_type": "1c353bfe-bca4-478d-8e28-6690e69ba3b7"
}

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
David on the headstock, 2021-02-15
@davGro

Is the address correct? I follow the link api.sb.mdlp.crpt.ru and the answer is empty.
I suggest:
Specify the data in https://sb.mdlp.crpt.ru/#/auth/signin by clicking on login and password , but do not send. We open the developer mode, the network tab, then click on the input with the specified data and watch what our browser sends during authorization. We select any request, scroll down and see the data: login and password.
And we are already looking, having chosen the right request: what url our data is sent to, what parameters are passed in the get or post request. Good luck, hope it helps

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question