Hi @wout swennen Thanks for reaching out. From the description i understand that you wanted to know how to get the operation id to set the policy to specific operations. Operation ids are automatically generated, you can use the below Rest api call after importing the API's and see what operations are available and get the name property to identify the intended operation for which you want to set the policy.
https://learn.microsoft.com/en-us/rest/api/apimanagement/current-ga/api-operation/list-by-api?tabs=HTTP
I am not sure if terraform has ability to call REST API and parse the response you can also use powershell commands to fetch the operation ids.
do let me know incase of further queries, I would be happy to assist you.