How to trigger an Azure Function with a TimerTrigger during development

So you have just created an Azure Function App with a TimerTrigger and you want to debug it, but you do not want have to change the schedule every time.

You have two options:

  1. You can trigger the function using a HTTP POST
    Make sure you supply an empty body
    URL to use: http://localhost:7071/admin/functions/<your function name>
  2. Add "RunOnStartup= true" to your function method signature
    See: How to Easily Debug a Timer Trigger Azure Function Locally | Magnetism Solutions | NZ (Auckland, Wellington, Christchurch and Dunedin) for an example.

Comments

Popular Posts