Page 2 of 2

Why PTCTO - "Mandatory parameter 'appery-rest' is missing" when the parameter is there and the Test mode works perfectly

Posted: Thu Mar 13, 2014 4:36 pm
by Nikita

Hello,

Have you edited anything in tab Source? Please roll back changes and activate a proxy. After this it must work.


Why PTCTO - "Mandatory parameter 'appery-rest' is missing" when the parameter is there and the Test mode works perfectly

Posted: Fri Mar 14, 2014 4:14 am
by timothy young

Thanks for your help ... here's the result when I use what I think is the correct appery proxy setup for this type of external resource.

Image

And here's the network trace ...
Image


Why PTCTO - "Mandatory parameter 'appery-rest' is missing" when the parameter is there and the Test mode works perfectly

Posted: Fri Mar 14, 2014 4:33 am
by timothy young

Hi Nikita,
I think I know what may be the problem. What I can see in weinre debug is consistent with the error condition where appery send the GET on behalf of my app. When such a get does not include the Authorization header, for example, it will throw an HTTP 400 Bad Request ... which is what weinre shows.

So, a guess is that appery is not sending that header for my app for some reason.

Could you please confirm the headers are being sent and that my setup is correctly to do so?

Thx!!
Tim

here's the same request as what we do in appery, but sent from a generic Apigee console... Note that I've replace "Authorization" with "foo" in the GET request header. The HTTP 400 BR and complaint about accesstoken tells that story.

Image


Why PTCTO - "Mandatory parameter 'appery-rest' is missing" when the parameter is there and the Test mode works perfectly

Posted: Fri Mar 14, 2014 5:55 am
by Alena Prykhodko

Hello Tim,

There is some things you should know to figure out why it happens:

1 When you use "Test" tab in the service - your request automatically is sent through http://appery.io/app/rest/html5/testC....

that's why your parameters appery-rest and appery-proxy-url not processed as you expected.

2 To send request "manualy" through the proxy you should:

2.1 specify "appery-key" parameter as header.

2.2 specity "appery-proxy-url" parameter as header.

2.3 specify "appery-rest" parameter as header.

2.4 send request to https://api.appery.io/rest/1/proxy/tu...

So if you don't like "use Appery.io proxy" option in settings you should have same parameters as on this screenshot

Image