timothy young
Posts: 0
Joined: Mon Mar 10, 2014 2:42 am

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

Why is the debug client showing the me the error

{"code":"PTCT010","description":"Mandatory parameter 'appery-rest' is missing"}

when my App uses the Appery proxy i.e. https://api.appery.io/rest/1/proxy/tu... ...

My request in Test mode has both the appery-rest and appery-proxy-url set to proper values as well as the data source required header and other parameters for the tunneled request, and the Test returns the expected results ...
However, when I have saved the working app details as mentioned above and attempt to execute the same flow from App on the Browser sim or on a Device via the appery.io/app/view/{clientid}/mobilescreen.html , then the error above PTCT010?

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

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

Hello,

Please can you show us your settings tab, request/response and test tab with results.

timothy young
Posts: 0
Joined: Mon Mar 10, 2014 2:42 am

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

Image

req / response text pasted below

appery-rest 2208271
appery-proxy-url https://api.att.com/2/devices/location
Authorization Bearer E909UXvQEfkK6dBjvKHuECITvHmjfd0w
accept application/json

{

"accuracy": "3339",

"latitude": "47.98491",

"longitude": "-122.01194",

"timestamp": "2014-03-10T20:52:00.000-05:00"

}

General Settings tab info :

See the pic ... Using the appery proxy I am doing GET on https://api.appery.io/rest/1/proxy/tu...
Appery.io Proxy: is unchecked.

Then I get the PCT error mentioned above ...

If I substitute the working URI to the ATT REST API for Terminal Location, the response in the test frame is perfect.

I just can't get appery.io app or web client to send the request properly... it would seem...

Using the appery proxy then I get a request and response but observe the PCT error in the response.

Here is the HEADERS tab of my network debug trace for my client at http://debug.appery.io/client/#efca6e...
This is what I see when not using the appery.io proxy config mentioned above,,, in other words this is the repsonse when going direct to the ATT API.

Request URL:https://api.att.com/2/devices/locatio...
Query String Parameters
requestedAccuracy:222
Request Payload
requestedAccuracy=222

Image

timothy young
Posts: 0
Joined: Mon Mar 10, 2014 2:42 am

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

Little mistake there in that middle sentence ...

"This is what I see when not using the appery.io proxy config mentioned above,,, in other words this is the repsonse when going direct to the ATT API. "

should instead say,
"This is what I see when not using the appery.io proxy config mentioned above,,, in other words this is the Request when going direct to the ATT API."

There is no response or it is blank by the time the Weinre Network capture sees it...

<

Here is the HEADERS tab of my network debug trace for my client at http://debug.appery.io/client/#efca6e...
This is what I see when not using the appery.io proxy config mentioned above,,, in other words this is the repsonse when going direct to the ATT API.

Request URL:https://api.att.com/2/devices/locatio...
Query String Parameters
requestedAccuracy:222
Request Payload
requestedAccuracy=222

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

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

Hello! Could you give us your public app link and steps to reproduce?

timothy young
Posts: 0
Joined: Mon Mar 10, 2014 2:42 am

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

Thank you!
Plz see below.

public app link
http://appery.io/app/mobile-frame?src...

weinre debug link
http://debug.appery.io/client/#efca6e...

My original questions is about the PCT error when using an Appery io proxy. The response on that scenario is the PCT error. I would to understand why that happens ....

Please note: The public link application, is now configured to NOT use appery.io proxy, and in the wienre network trace you cannot see any response to appery request toward the location API at ATT.

MORE IMPORTANTLY THOUGH IS my inability to get any response back from my app triggered (public link) app.

Perhaps the "Authorization: Bearer 23764526375sadf" header details are not being sent in the request outbound from appery toward AT&T location API.

Is it possible to catch a trace of (ALL of) the headers sent out from the appery.io on behalf of my public link application? My guess is that the trace will not match the trace for the online test mode (which you will observe, is working e2e)
I'm not sure the network capture of debug is complete.

thx!!!
Tim Image

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

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

Hello! Did you change anything on Source tab? Please delete eddited (blue colored) files and undo all source changes.

timothy young
Posts: 0
Joined: Mon Mar 10, 2014 2:42 am

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

Yes. I removed the papery proxy headers and decided to continue testing this using no proxy.

Now, while I do not get the Pct error, I do get a blank response in my app. Test mode stills works great.

Can u check logs or capture trace of the action when the app link invokes the request?

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

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

Hello!

If you call some external service and it doesn't return response you have to use Appery.io proxy, here is more information http://docs.appery.io/documentation/c...

You can disable proxy when test on device.

timothy young
Posts: 0
Joined: Mon Mar 10, 2014 2:42 am

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

Ok. Thank you
Can tell me why the pct errors then, given the above, when I use the proxy configs ? See my original question at top

Return to “Issues”