there is no direct method for this but you may have a workaround
you can use custom rules to trigger a function and in your function, you can call your API
https://video2.skills-academy.com/en-us/azure/iot-central/core/howto-create-custom-rules
https://video2.skills-academy.com/en-us/azure/iot-central/core/howto-configure-rules-advanced