D
D
davchikf02020-10-05 16:35:55
API
davchikf0, 2020-10-05 16:35:55

When GET to API request 404 error, although the page in the browser returns xml, why?

When sending a get request according to the API documentation to the server, it returns a 404 error, although when you go to this link in the browser, the xml opens according to the documentation. Other requests go through, I can get data about the device, the user, but the device profiles do not work. prompt with what it can be connected?

Answer the question

In order to leave comments, you need to log in

5 answer(s)
A
azarij, 2020-10-05
@azarij

give an example of the get request you are sending.
give an example of the full answer you get in return.
provide a link to the documentation for the API.
then it will be possible to talk in detail, but for now, with the available information about the problem, it will be fortune-telling on coffee grounds.

D
Developer, 2020-10-05
@samodum

Sending request incorrectly

A
Alexander, 2020-10-05
@AlexVue

The problem may be that you are sending a request with http and you need with https or vice versa.

E
Egor, 2020-10-06
@exorka

Even in my practice, in particular, there was such a reaction to the absence of a User-Agent

D
Dmitry, 2020-10-27
@dlnsk

Are you sending an Accept header?
If you're sending something like application/xml, then try sending text/html (which is often what the browser sends).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question