apify-hello-world
Run your first Apify Actor and retrieve results via apify-client. Use when starting a new Apify integration, testing connectivity, or learning the Actor call/dataset retrieval pattern. Trigger: "apify hello world", "apify example", "run an apify actor", "apify quick start", "first apify scrape".
Best use case
apify-hello-world is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Run your first Apify Actor and retrieve results via apify-client. Use when starting a new Apify integration, testing connectivity, or learning the Actor call/dataset retrieval pattern. Trigger: "apify hello world", "apify example", "run an apify actor", "apify quick start", "first apify scrape".
Teams using apify-hello-world should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/apify-hello-world/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How apify-hello-world Compares
| Feature / Agent | apify-hello-world | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Run your first Apify Actor and retrieve results via apify-client. Use when starting a new Apify integration, testing connectivity, or learning the Actor call/dataset retrieval pattern. Trigger: "apify hello world", "apify example", "run an apify actor", "apify quick start", "first apify scrape".
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
Best AI Skills for Claude
Explore the best AI skills for Claude and Claude Code across coding, research, workflow automation, documentation, and agent operations.
ChatGPT vs Claude for Agent Skills
Compare ChatGPT and Claude for AI agent skills across coding, writing, research, and reusable workflow execution.
SKILL.md Source
# Apify Hello World
## Overview
Run a public Actor from the Apify Store, wait for it to finish, and retrieve the scraped data. This demonstrates the fundamental call-wait-collect pattern used in every Apify integration.
## Prerequisites
- `npm install apify-client` completed
- `APIFY_TOKEN` environment variable set
- See `apify-install-auth` if not ready
## Core Pattern: Call Actor, Get Data
```typescript
import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
// 1. Run an Actor and wait for it to finish
const run = await client.actor('apify/website-content-crawler').call({
startUrls: [{ url: 'https://docs.apify.com/academy' }],
maxCrawlPages: 5,
});
// 2. Retrieve results from the default dataset
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(`Crawled ${items.length} pages:`);
items.forEach(item => {
console.log(` - ${item.url}: ${item.text?.substring(0, 80)}...`);
});
```
## Instructions
### Step 1: Create the Script
Create `hello-apify.ts` (or `.js`) with the code above.
### Step 2: Run It
```bash
# With tsx (recommended)
npx tsx hello-apify.ts
# Or with Node.js (plain JS)
node hello-apify.js
```
### Step 3: Understand the Output
The Actor runs on Apify's cloud infrastructure. When it finishes:
- `run.id` — unique run identifier
- `run.status` — `SUCCEEDED`, `FAILED`, `TIMED-OUT`, or `ABORTED`
- `run.defaultDatasetId` — ID of the dataset containing results
- `run.defaultKeyValueStoreId` — ID of the KV store with metadata
## Popular Starter Actors
| Actor ID | Purpose | Typical Input |
|----------|---------|---------------|
| `apify/website-content-crawler` | Crawl and extract text | `{ startUrls, maxCrawlPages }` |
| `apify/web-scraper` | General-purpose scraper | `{ startUrls, pageFunction }` |
| `apify/cheerio-scraper` | Fast HTML scraper | `{ startUrls, pageFunction }` |
| `apify/google-search-scraper` | Google SERP results | `{ queries, maxPagesPerQuery }` |
## Synchronous vs Asynchronous Runs
```typescript
// SYNCHRONOUS — .call() waits for the Actor to finish (simple, blocking)
const run = await client.actor('apify/web-scraper').call(input);
// ASYNCHRONOUS — .start() returns immediately, poll later
const run = await client.actor('apify/web-scraper').start(input);
// ... do other work ...
const finishedRun = await client.run(run.id).waitForFinish();
```
## Working with Results
```typescript
// Get all items (paginated internally)
const { items } = await client.dataset(run.defaultDatasetId).listItems();
// Get items with pagination control
const page1 = await client.dataset(run.defaultDatasetId).listItems({
limit: 100,
offset: 0,
});
// Download entire dataset as CSV/JSON/etc.
const buffer = await client.dataset(run.defaultDatasetId).downloadItems('csv');
// Get a named output from the key-value store
const screenshot = await client
.keyValueStore(run.defaultKeyValueStoreId)
.getRecord('screenshot');
```
## Run Configuration Options
```typescript
const run = await client.actor('apify/web-scraper').call(
input, // Actor-specific input object
{
memory: 1024, // Memory in MB (128–32768, powers of 2)
timeout: 300, // Timeout in seconds (default: Actor's setting)
build: 'latest', // Which build to use
waitSecs: 120, // Max wait for .call() (0 = don't wait)
}
);
```
## Error Handling
| Error | Cause | Solution |
|-------|-------|----------|
| `Actor not found` | Wrong Actor ID | Check ID at apify.com/store |
| `run.status === 'FAILED'` | Actor crashed | Check `run.statusMessage` for details |
| `run.status === 'TIMED-OUT'` | Exceeded timeout | Increase `timeout` or reduce workload |
| `Dataset is empty` | Actor produced no output | Verify input parameters; check Actor logs |
| `402 Payment Required` | Insufficient compute units | Top up at console.apify.com/billing |
## Complete Example: Scrape and Save
```typescript
import { ApifyClient } from 'apify-client';
import { writeFileSync } from 'fs';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
async function scrapeAndSave() {
console.log('Starting Actor run...');
const run = await client.actor('apify/website-content-crawler').call({
startUrls: [{ url: 'https://example.com' }],
maxCrawlPages: 10,
});
if (run.status !== 'SUCCEEDED') {
throw new Error(`Actor run failed: ${run.status} — ${run.statusMessage}`);
}
const { items } = await client.dataset(run.defaultDatasetId).listItems();
writeFileSync('results.json', JSON.stringify(items, null, 2));
console.log(`Saved ${items.length} items to results.json`);
}
scrapeAndSave().catch(console.error);
```
## Resources
- [Apify Store — Browse Actors](https://apify.com/store)
- [Run Actor via API](https://docs.apify.com/academy/api/run-actor-and-retrieve-data-via-api)
- [JS Client Examples](https://docs.apify.com/api/client/js/docs/guides/examples)
## Next Steps
Proceed to `apify-local-dev-loop` for local Actor development.Related Skills
workhuman-hello-world
Workhuman hello world for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman hello world".
wispr-hello-world
Wispr Flow hello world for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr hello world".
windsurf-hello-world
Create your first Windsurf Cascade interaction and Supercomplete experience. Use when starting with Windsurf, testing your setup, or learning basic Cascade and Supercomplete workflows. Trigger with phrases like "windsurf hello world", "windsurf example", "windsurf quick start", "first windsurf project", "try windsurf".
webflow-hello-world
Create a minimal working Webflow Data API v2 example. Use when starting a new Webflow integration, testing your setup, or learning basic Webflow API patterns — list sites, read CMS collections, create items. Trigger with phrases like "webflow hello world", "webflow example", "webflow quick start", "simple webflow code", "first webflow API call".
vercel-hello-world
Create a minimal working Vercel deployment with a serverless API route. Use when starting a new Vercel project, testing your setup, or learning basic Vercel deployment and API route patterns. Trigger with phrases like "vercel hello world", "vercel example", "vercel quick start", "simple vercel project", "first vercel deploy".
veeva-hello-world
Veeva Vault hello world with REST API and VQL. Use when integrating with Veeva Vault for life sciences document management. Trigger: "veeva hello world".
vastai-hello-world
Rent your first GPU instance on Vast.ai and run a workload. Use when starting a new Vast.ai integration, testing your setup, or learning basic Vast.ai GPU rental patterns. Trigger with phrases like "vastai hello world", "vastai example", "vastai quick start", "rent first gpu", "vastai first instance".
twinmind-hello-world
Create your first TwinMind meeting transcription and AI summary. Use when starting with TwinMind, testing your setup, or learning basic transcription and summary patterns. Trigger with phrases like "twinmind hello world", "first twinmind meeting", "twinmind quick start", "test twinmind transcription".
together-hello-world
Run inference with Together AI -- chat completions, streaming, and model selection. Use when testing open-source models, comparing model performance, or learning the Together AI API. Trigger: "together hello world, together AI example, run llama".
techsmith-hello-world
Capture a screenshot with Snagit COM API and produce a Camtasia video. Use when automating screen captures, batch-processing recordings, or building documentation pipelines with TechSmith tools. Trigger: "techsmith hello world, snagit capture, camtasia render".
supabase-hello-world
Run your first Supabase query — insert a row and read it back. Use when starting a new Supabase project, verifying your connection works, or learning the basic insert-then-select pattern with @supabase/supabase-js. Trigger with phrases like "supabase hello world", "first supabase query", "supabase quick start", "test supabase connection", "supabase insert and select".
stackblitz-hello-world
Boot a WebContainer, mount files, install npm packages, and run a dev server in the browser. Use when learning WebContainers, building browser-based IDEs, or running Node.js without a backend server. Trigger: "stackblitz hello world", "webcontainer example", "run node in browser".