← RSS

Random item from multiple RSS feeds from RSS API

Pipedream makes it easy to connect APIs for RSS and 1000+ other apps remarkably fast.

Trigger workflow on
Random item from multiple RSS feeds from the RSS API
Next, do this
Connect to 1000+ APIs using code and no-code building blocks
No credit card required
Into to Pipedream
Watch us build a workflow
Watch us build a workflow
7 min
Watch now ➜
Trusted by 250,000+ developers from startups to Fortune 500 companies:
Trusted by 250,000+ developers from startups to Fortune 500 companies

Developers Pipedream

Getting Started

Trigger a workflow on Random item from multiple RSS feeds with RSS API. When you configure and deploy the workflow, it will run on Pipedream's servers 24x7 for free.

  1. Configure the Random item from multiple RSS feeds trigger
    1. Connect your RSS account
    2. Configure timer
    3. Configure Feed URLs
  2. Add steps to connect to 1000+ APIs using code and no-code building blocks
  3. Deploy the workflow
  4. Send a test event to validate your setup
  5. Turn on the trigger

Integrations

Send Message with Discord Webhook API on Random item from multiple RSS feeds from RSS API
RSS + Discord Webhook
 
Try it
Add Multiple Rows with Google Sheets API on Random item from multiple RSS feeds from RSS API
RSS + Google Sheets
 
Try it
Get Film with SWAPI - Star Wars API on Random item from multiple RSS feeds from RSS API
RSS + SWAPI - Star Wars
 
Try it
Create Multiple Records with Airtable API on Random item from multiple RSS feeds from RSS API
RSS + Airtable
 
Try it
Send any HTTP Request with HTTP / Webhook API on Random item from multiple RSS feeds from RSS API
RSS + HTTP / Webhook
 
Try it

Details

This is a pre-built, open source component from Pipedream's GitHub repo. The component is developed by Pipedream and the community, and verified and maintained by Pipedream.

To contribute an update to an existing component or create a new component, create a PR on GitHub. If you're new to Pipedream component development, you can start with quickstarts for trigger span and action development, and then review the component API reference.

Random item from multiple RSS feeds on RSS
Description:Emit a random item from multiple RSS feeds
Version:0.0.3
Key:rss-random-item-in-multiple-feeds

Code

import rss from "../../app/rss.app.mjs";
import { defineSource } from "@pipedream/types";
import rssCommon from "../common/common.mjs";
export default defineSource({
    ...rssCommon,
    key: "rss-random-item-in-multiple-feeds",
    name: "Random item from multiple RSS feeds",
    type: "source",
    description: "Emit a random item from multiple RSS feeds",
    version: "0.0.3",
    props: {
        ...rssCommon.props,
        urls: {
            propDefinition: [
                rss,
                "urls",
            ],
        },
    },
    dedupe: "unique",
    hooks: {
        async activate() {
            // Try to parse the feed one time to confirm we can fetch and parse.
            // The code will throw any errors to the user.
            for (const url of this.urls) {
                await this.rss.fetchAndParseFeed(url);
            }
        },
    },
    async run() {
        const items = [];
        for (const url of this.urls) {
            const feedItems = await this.rss.fetchAndParseFeed(url);
            items.push(...feedItems);
        }
        const item = items[Math.floor(Math.random() * items.length)];
        const meta = this.generateMeta(item);
        this.$emit(item, meta);
    },
});

Configuration

This component may be configured based on the props defined in the component code. Pipedream automatically prompts for input values in the UI and CLI.
LabelPropTypeDescription
RSSrssappThis component uses the RSS app.
timer$.interface.timer

How often you want to poll the feed for new items

Feed URLsurlsstring[]

Enter either one or multiple URLs from any public RSS feed

Authentication

The RSS API does not require authentication.

About RSS

Real Simple Syndication

More Ways to Use RSS

Triggers

New Item in Feed from the RSS API

Emit new items from an RSS feed

 
Try it
New Item From Multiple RSS Feeds from the RSS API

Emit new items from multiple RSS feeds

 
Try it

Actions

Merge RSS Feeds with the RSS API

Retrieve multiple RSS feeds and return a merged array of items sorted by date See docs

 
Try it