cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AbleAndyUK
Frequent Visitor

How to request more than one piece of data using an API key

I have access to the DVLA (UK Vehicle licensing) database through an API key.  The key allows a maximum call of 10 registrations per second.

 

I have set up a flow that will collect the data for 1 vehicle to get things started (I am new to this and only just learning the great things Power Automate can offer me).  I have a list in an excel table of over 350 registrations.

 

I believe I can put in a loop to get the next registration, with a break to pause to keep within the 10 per second rule but what do I put in the HTTP box to pull the next registration from the excel table as opposed to being hard fixed as shown below:

 

DVLA.png

 

Many thanks.

 

Andy

1 ACCEPTED SOLUTION

Accepted Solutions
Expiscornovus
Super User
Super User

Hi @AbleAndyUK,

 

Yes I think this would be possible by adding a integer variable action to count the number of http requests and then when you hit the number 10 add a delay of a second to it. Btw, you should be able to add the registration number to the body of the HTTP post by using a dynamic value. 

 

Beware, in this example I am using a List rows present in a table action to collect the data from Excel. I don't know how you formatted your Excel sheet?

 

Below is an example how you could set this up.

1. Add an initialize variable action called Count of type Integer and set the default value to 0

initializevariablecount.png

2. Add the registrationnumber dynamic value to the body of your HTTP action

httppostdvla.png

3. Add an increment variable action and set the value to 1

incrementvariablecount.png

4. Add a condition to check if the count variable equals 10

countequals10.png

5. In the Yes section add a delay action of 1 second

6. Add a set variable action to reset the count variable back to 0 again

resetto0variable.png

 

Hope this helps a bit?



Happy to help out! 🙂

Interested in more #PowerAutomate #SharePointOnline or #PowerVirtualAgents content?
Visit my blog, Subscribe to my YouTube channel or Follow me on Twitter


View solution in original post

2 REPLIES 2
Expiscornovus
Super User
Super User

Hi @AbleAndyUK,

 

Yes I think this would be possible by adding a integer variable action to count the number of http requests and then when you hit the number 10 add a delay of a second to it. Btw, you should be able to add the registration number to the body of the HTTP post by using a dynamic value. 

 

Beware, in this example I am using a List rows present in a table action to collect the data from Excel. I don't know how you formatted your Excel sheet?

 

Below is an example how you could set this up.

1. Add an initialize variable action called Count of type Integer and set the default value to 0

initializevariablecount.png

2. Add the registrationnumber dynamic value to the body of your HTTP action

httppostdvla.png

3. Add an increment variable action and set the value to 1

incrementvariablecount.png

4. Add a condition to check if the count variable equals 10

countequals10.png

5. In the Yes section add a delay action of 1 second

6. Add a set variable action to reset the count variable back to 0 again

resetto0variable.png

 

Hope this helps a bit?



Happy to help out! 🙂

Interested in more #PowerAutomate #SharePointOnline or #PowerVirtualAgents content?
Visit my blog, Subscribe to my YouTube channel or Follow me on Twitter


Thank you @Expiscornovus that was very useful and sped up the call.  

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Community Calls Conversations

Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Users online (2,142)