Distance calculator

FREEMIUM
Par Oleksii Neishchenko | Mise à jour a month ago | Location
Popularité

9.2 / 10

Latence

179ms

Niveau de service

100%

Health Check

N/A

Retour à toutes les discussions

422 error

Rapid account: Ianmckintosh 1969
ianmckintosh1969
6 months ago

I just signed up for the API service but getting a 422 error when attempting to call. Any suggestions are appreciated.

Rapid account: Ianmckintosh 1969
ianmckintosh1969 Commented 6 months ago

just sent.

Rapid account: Api Ocean
ApiOcean Commented 6 months ago

I have not used this software, but I can try to help.
Could you send me screenshots of the request settings to o.neishch@gmail.com?

Rapid account: Ianmckintosh 1969
ianmckintosh1969 Commented 6 months ago

Unfortunately, it is not a common language. I am making the calls from within a vendor provided application which supports REST API calls. The application is from Jack Henry.

Rapid account: Api Ocean
ApiOcean Commented 6 months ago

What programming language and technology do you use?

Rapid account: Ianmckintosh 1969
ianmckintosh1969 Commented 6 months ago

Not sure how I can pass the following as a query string.

{
“start_point”:"(1234,-1234)"
“end_point_1”:"(2345,-2345)"
“unit”:“miles”
}

I changed it to be in the body of a REST call but that resulted in no parameters being sent.

Rapid account: Api Ocean
ApiOcean Commented 6 months ago

Now the parameters look like this:
{
"{start_point:(1234,1234)end_point_1:(2345,2345)end_point_2:(3456,-3456)unit:milesdecimal_places:2}":true
}

That is, there should be 5 separate parameters: start_point, end_point_1, end_point_2, unit, decimal_places
Instead, there is a single parameter that contains a mix of all 5 parameters in its name and has a value of “true”

Rapid account: Api Ocean
ApiOcean Commented 6 months ago

In the last 3 requests I found, no parameters were sent

Rapid account: Ianmckintosh 1969
ianmckintosh1969 Commented 6 months ago

Appreciate the quick response. I made an adjustment but 422 still occurs. Can you take a look to see if the information is still being passed incorrectly?

Rapid account: Api Ocean
ApiOcean Commented 6 months ago

It looks like the problem is in the parameters you are sending.
It should be like this:
{
“start_point”:"(1234,-1234)"
“end_point_1”:"(2345,-2345)"
“unit”:“miles”
}

And from you it comes like this:
{
“start_point=(1234%2C1234)&end_point_1=(2345%2C2345)&end_point_2=(3456%2C3456)&unit=miles&decimal_places=2)”:true
}

Participez à la discussion - ajoutez un commentaire ci-dessous:

Connectez-vous / Inscrivez-vous pour publier de nouveaux commentaires