Try this API feature does not show optionally request body or path

We have an API and a certain Get method which comprises of optionally

  1. request body

  2. optionally paths where

E.g. /api/v1/Person GET is ok, /api/v1/Person?$search=card=123123 GET is also valid, there are other variations for the search.

In the Try this API feature, we do not see the request body text box. Is this something that can be achieved?

Or a way of entering the path after (its the same endpoint) /api/v1/Person, e.g. ?$search=card=123123 . Is this something that can be achieved?

Thanks in advance.

Elvina

Thank you for your question @Elvina_ART, we saw your post and wanted to let you know we’re keeping it on our radar. We will also invite others in the community to pitch in and share their thoughts.

Also, join us on next thursday, december at 4 pm CET | 10 am NY | 9 am MX | 12 pm BR to hear an Apigee expert answer live forum questions :right_arrow: We look forward to seeing you there! Register here: Apigee & Application Integration Tech Talks

Hello @Elvina_ART,

Our integrated portal logic will more or less create a wrapper (similar to Swagger UI) given your OpenAPI specification inputted.

Does your OpenAPI specification published to the developer portal contain logic to support the noted query parameters? Does the specification render properly using third party services (ie: Swagger UI, etc)?

Best
Matt

Hey,

Hope you’re keeping well.

In the Apigee integrated developer portal, the “Try this API” widget is generated from your OpenAPI spec. For a GET method, the UI will not show a request body text box because request bodies are not supported in GET according to the spec. To allow optional query parameters like ?$search=card=123123, you need to define them as query parameters in your OpenAPI definition for that endpoint. Once they’re declared, the Try-it panel will render input fields for them, and you can append any valid query string when testing directly in the widget.

Thanks and regards,
Taz

1 Like

Thank you. That worked and we had some Odata options as well.

Hey @iTazB!

A huge thank you for your recent contributions in the forum. We greatly appreciate the insightful and helpful responses you have been sharing across our Apigee threads. Keep up the fantastic work! We love seeing this peer-to-peer support :slightly_smiling_face:

If you’d like to join us this Thursday, feel free to tune in to the last Community Tech Talk of the year for an Apigee MCP Deep Dive on Dec 11 at 5 PM CEST / 11 AM NY Time :right_arrow: Apigee & Application Integration Tech Talks