question

Lily-9563 avatar image
0 Votes"
Lily-9563 asked MayankBargali-MSFT answered

How to map the parameter to the operation

Hi, I'm new to APIM. I have a API like below but have no idea how to map the parameter to the operation .
https://server.company.com/api/systemA/GetInvoiceData/AU
AU is a parameter here

It's not a Query parameter, so how can I configure it ?
119101-image.png


Need your help, much appreciated

azure-api-management
image.png (9.0 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

MayankBargali-MSFT avatar image
0 Votes"
MayankBargali-MSFT answered

@Lily-9563 You can refer to add the operation for details and I have defined name parameter in my URL as below

119772-image.png

In your policy you can use context.Request context.Request.MatchedParameters.GetValueOrDefault("name") and according to your requirement you can use rewrite URL or as per your requirement.


image.png (20.1 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.