¿Why the Trace tool error occurs with Status 401, and with Postman and CURL no ?

Greetings. I have configured a Proxy server and when testing it with the "Trace" tool, it does nothing - it does not show anything in "Transaction Map" - I do not see that it executes any step; and generates a Status 401. I have an APIKey configured which I am entering as a Header in "Filters" (left column), and right there in "Filters" I am also entering a Token that requires the application to which the proxy addresses. However, when I test the operation of the proxy using the cURL command in Linux, it works for me Ok - there I also enter the APIKey and the Token as headers. Likewise, Postman also works well for me. ¿Could someone please tell me what this is due to?, ¿What can I have wrongly configured in the proxy ? ¿How can I solve it?.

Solved Solved
1 2 262
1 ACCEPTED SOLUTION

Hmmm, I'm sorry you're having troubles.

I don't quite understand what you're trying to do.

But let me say this:

The UI for the Trace tool is designed primarily to show you what Apigee edge is doing with requests it handles. There is a small piece of the UI that allows you to send a request, but this form is really quite limited in its capability.

  • it can send only GET requests
  • You cannot set HEADERS
  • You cannot send a payload (obviously, since it sends only GETs)

I think maybe you have misunderstood how the Trace page works. And that is not a great surprise. In my opinion, The UI for the Trace screen is confusing. It tries to do too many things. It lets you view transactions, and also it lets you send a very simple request. Why not eliminate that second function, which is very limited anyway?

Regarding the "Filters" fields - the purpose of the "Filters" field is to restrict the transactions that are collected and then shown in the Trace UI. Setting a header in the Filters area tells the Trace subsystem in Apigee Edge to only collect information for requests with the value you specify for the Header. If a request arrives and is handled by Apigee Edge but it lacks the filter value you specify, that request will not be traced.

The Filters fields do not send the specified values when you click the SEND button.

If you specify a Header like "Authorization: Bearer XXXX", then ... the Trace system will collect and allow you to see only those requests that have that header value. Eg, if you use curl or some other client to send in a request, the Trace tool will show it only if the header you send in, matches what you specified in the Filters.

My suggestion:

  • don't use the Trace UI to send requests
  • use curl or some other client. I like Postman. But there are lots of HTTP / REST clients out there. Any of them will be more suitable than the send button in the Trace UI.

Good luck!

View solution in original post

2 REPLIES 2

Hmmm, I'm sorry you're having troubles.

I don't quite understand what you're trying to do.

But let me say this:

The UI for the Trace tool is designed primarily to show you what Apigee edge is doing with requests it handles. There is a small piece of the UI that allows you to send a request, but this form is really quite limited in its capability.

  • it can send only GET requests
  • You cannot set HEADERS
  • You cannot send a payload (obviously, since it sends only GETs)

I think maybe you have misunderstood how the Trace page works. And that is not a great surprise. In my opinion, The UI for the Trace screen is confusing. It tries to do too many things. It lets you view transactions, and also it lets you send a very simple request. Why not eliminate that second function, which is very limited anyway?

Regarding the "Filters" fields - the purpose of the "Filters" field is to restrict the transactions that are collected and then shown in the Trace UI. Setting a header in the Filters area tells the Trace subsystem in Apigee Edge to only collect information for requests with the value you specify for the Header. If a request arrives and is handled by Apigee Edge but it lacks the filter value you specify, that request will not be traced.

The Filters fields do not send the specified values when you click the SEND button.

If you specify a Header like "Authorization: Bearer XXXX", then ... the Trace system will collect and allow you to see only those requests that have that header value. Eg, if you use curl or some other client to send in a request, the Trace tool will show it only if the header you send in, matches what you specified in the Filters.

My suggestion:

  • don't use the Trace UI to send requests
  • use curl or some other client. I like Postman. But there are lots of HTTP / REST clients out there. Any of them will be more suitable than the send button in the Trace UI.

Good luck!

Thanks for the clarification. I'll keep it in mind.