Fetch RSS every 'n' hours

Hi all, I'm trying to create a pipe that fetch a RSS input every 'n' hours and gives an output FEED of the last 10 elements, where N is a defined time unit (3 hours, 1 hour or whatever). I've searched a way to do it with the date module but I haven't figured out how it could be done.

Anyone have a hint?

3 Replies
  • anyone????

  • you want the pipe to fetch every X hours? pipes doesn't do that, you'll have to create either a cronjob on your server to hit a pipes url or some other automated way.

    pipes only runs when you access the pipe url. it's on demand vs. constantly running.

    thanks -paul

  • Use an IFTTT recipe. Arrange for the pipe to filter out everything unless the current time is when you want it to run. If you want it to emit items every three hours, you can use the simple math module on the hour element using the hour %3 (for every three hours, %5 for every five hours). %3 gives the remainder after dividing by 3. So if the hour is exactly divisible by three, you'll get remainder 0. You can then use this fact to drive the filter.

    Actually that's only half the battle. With IFTTT running every 15 mins or so, the pipe will end up emitting uo to 4 times in that hour. So you need to take one step further and use another filter condition that checks if the current minute is less than 16. Only if both conditions are met (hour %3 = 0 and also current minute is less than 16) should you let the pipe emit something.


Recent Posts

in Pipes