Super newbie at Postman, APIs and not all that with programming. I have the data that I need from API Postman Get requests. I see it in the console body and I have environmental variables created that were used in the get requests. I have a relatively beefy mathematical formula that needs to be run using some of the data that was returned. I then need to send the calculated total back. I need to do this monthly. Underneath is a snip of the console body and the calculations need to happen using some custom categoryIds i.e. "6872":"Hole". Custom categoryId "6975": is the total that needs to be sent back with the new calculations monthly. What would be the best and easiest way to do this. Thank you soooo much for your help and time! This is one of the formulas for Hole (I have not made a variable for the formula yet) The formula is in SQL so far
Formula: Hole=((SQRT(@PSI*(2.30864.4))(SQUARE(CAST@Width AS DECIMAL(10,2)/12)).785)0.77.48*60)*LeakTime)*60)*HoleCount)
https://i.stack.imgur.com/RzwoE.png
Thank you, Jennifer
You can use postman monitory. It allows to execute collection as per schedule
https://learning.postman.com/docs/monitoring-your-api/intro-monitors/
Just create collection and then run this collection weekly in the monitor
add a condition for next request as the difference between last and current date is more than one month then only send the next request.
Eg add below in your script it to do something only one first day of the month:
let moment = require('moment')
if(moment().date()===1){
//do something
console.log("hi")
}