Custom Azure API Pattern

Rob50
Tera Contributor

I am looking at calling the Resource Graph API to retrieve a list of all Firewalls in Azure. I have created 2 Patterns to try and achieve this:

  1. ServerLess Pattern which runs on a ServerLess schedule, that calls the Azure Resource Graph API. The pattern has been configured as a infrastructure pattern in line with how other Serverless patterns have been configured
  2. Cloud Resource Pattern which runs when a Cloud Discovery is executed. The pattern type is "Resource" and I have the pattern executing, however the input parameters are not being received when the pattern is executed.

What I am trying to establish is:

  1. What is the best method for retrieving the data - ServerLess / Cloud Resource?
  2. What is the API to retrieve the data from Azure? I am assuming the following Azure docs is the correct API
  3. What is the body to be executed? 

 

{ "subscriptions": [ "<subscription_id>" ], "query": "Resources | where type =~ 'Microsoft.Network/azureFirewalls'"}​

 

Any pointers or help is much appreciated.

 

Thanks,

Rob

0 REPLIES 0