Tutorial

How to Build an n8n Search Workflow with Scavio

Learn how to set up an n8n workflow that searches Google, Reddit, and YouTube via Scavio's API, with scheduling and output delivery.

n8n is a workflow automation platform that makes it easy to connect APIs, schedule tasks, and process data without writing full applications. This tutorial builds an n8n workflow that runs a daily search across Google, Reddit, and YouTube using Scavio's API, processes the results, and delivers them to Slack or email. The self-hosted version of n8n is free with unlimited executions.

Prerequisites

  • n8n installed (self-hosted or cloud)
  • A Scavio API key from scavio.dev
  • Basic familiarity with n8n's visual workflow editor

Walkthrough

Step 1: Create a new workflow with a schedule trigger

Start a new workflow and add a Schedule Trigger node set to run daily at your preferred time.

JavaScript
// Schedule Trigger node settings:
// Trigger interval: Every day
// Hour: 8
// Minute: 0
// Timezone: your local timezone

Step 2: Add an HTTP Request node for Scavio search

Add an HTTP Request node that calls Scavio's search endpoint.

JavaScript
// HTTP Request node settings:
// Method: POST
// URL: https://api.scavio.dev/api/v1/search
// Authentication: Header Auth
//   Header Name: x-api-key
//   Header Value: your_scavio_api_key
// Body Content Type: JSON
// Body: {
//   "platform": "google",
//   "query": "your search query here"
// }

Step 3: Parse and format results

Add a Code node to extract and format the search results.

JavaScript
// Code node (JavaScript):
const results = $input.all()[0].json.organic || [];
return results.slice(0, 5).map(r => ({
  json: {
    title: r.title,
    url: r.link,
    snippet: r.snippet,
    position: r.position
  }
}));

Step 4: Deliver results to Slack or email

Add a Slack or Email node to send the formatted results.

JavaScript
// Slack node settings:
// Channel: #search-results
// Text: {{$json.title}} - {{$json.url}}
//
// Or Email node:
// To: your@email.com
// Subject: Daily Search Report
// Body: formatted HTML table of results

Python Example

Python
# Equivalent Python script for n8n HTTP Request:
import requests, os
H = {'x-api-key': os.environ['SCAVIO_API_KEY']}

def n8n_search(query, platform='google'):
    resp = requests.post('https://api.scavio.dev/api/v1/search',
        headers=H, json={'platform': platform, 'query': query}, timeout=10)
    return [{'title': r['title'], 'url': r['link'], 'snippet': r['snippet']}
            for r in resp.json().get('organic', [])[:5]]

JavaScript Example

JavaScript
// n8n Code node example:
const results = $input.all()[0].json.organic || [];
return results.slice(0, 5).map(r => ({
  json: { title: r.title, url: r.link, snippet: r.snippet }
}));

Expected Output

JSON
A daily n8n workflow that searches via Scavio and delivers formatted results to Slack or email.

Related Tutorials

Frequently Asked Questions

Most developers complete this tutorial in 15 to 30 minutes. You will need a Scavio API key (free tier works) and a working Python or JavaScript environment.

n8n installed (self-hosted or cloud). A Scavio API key from scavio.dev. Basic familiarity with n8n's visual workflow editor. A Scavio API key gives you 500 free credits per month.

Yes. The free tier includes 500 credits per month, which is more than enough to complete this tutorial and prototype a working solution.

Scavio has a native LangChain package (langchain-scavio), an MCP server, and a plain REST API that works with any HTTP client. This tutorial uses the raw REST API, but you can adapt to your framework of choice.

Start Building

Learn how to set up an n8n workflow that searches Google, Reddit, and YouTube via Scavio's API, with scheduling and output delivery.