question

Kman-9406 avatar image
0 Votes"
Kman-9406 asked PRADEEPCHEEKATLA-MSFT edited

Making an API's call

Hi All,

I wanted to make API calls maybe twice a day or even if I wanted to make it every few minutes and put the API data (JSON) into ADLS and then into Azure SQL.

What is the best Azure Services I can use for both scenarios which is scalable? How would the Azure SQL deal with heavily nested JSON data?


Thank You.

azure-sql-databaseazure-api-management
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

JayaC-MSFT avatar image
0 Votes"
JayaC-MSFT answered JayaC-MSFT commented

Hello @Kman-9406, you may consider Timer trigger in this case. You can use Httpclient to make an API call to the endpoints mentioned in the document. You may need to pass an authorization token for validation , for that please refer to this

You may also check logic app recurrence trigger : https://docs.microsoft.com/en-us/azure/logic-apps/tutorial-build-schedule-recurring-logic-app-workflow
or, scheduler : https://docs.microsoft.com/en-us/azure/logic-apps/concepts-schedule-automated-recurring-tasks-workflows
https://docs.microsoft.com/en-us/azure/connectors/connectors-native-recurrence

and, for the ADLS and Sql server :
https://docs.microsoft.com/en-us/connectors/azuredatalake/
https://docs.microsoft.com/en-us/azure/connectors/connectors-create-api-sqlazure


· 2
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.

@JayaC-MSFT I am not sure if I understand the solution you have just provided, you have just provided links as references. How would this fit together. How would Azure SQL deal with heavily nested JSON data from the API call? How would complex Authentication be dealt with such as Tokens etc.

0 Votes 0 ·

Hello @Kman-9406, I have shared the links to specify the resources you can use to start with. The implementation will definitely depend on the individual requirements.
For the JSON you would have to transform accordingly, need to design the schema to match the JSON and then loop over all nested structures to create rows etc. Or you can directly work with the JSON and leverage SQL features while querying:
https://docs.microsoft.com/en-us/azure/azure-sql/database/json-features
For the authentication part, what exactly are you looking for?
If you think you need more specific assistance , please send an email with subject line “Attn:Jaya” to AzCommunity[at]Microsoft[dot]com referencing this thread so that we can discuss offline.

0 Votes 0 ·