Agent skill

Apollo Performance Tuning

by jeremylongshore in jeremylongshore/tons-of-skills-marketplace

Optimize Apollo.io API performance. An agent skill from jeremylongshore/tons-of-skills-marketplace.

MITAuto-check passedBackend & APIs

Install Apollo Performance Tuning

skills CLI
$ npx skills add jeremylongshore/tons-of-skills-marketplace --skill apollo-performance-tuning -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install jeremylongshore/tons-of-skills-marketplace apollo-performance-tuning --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/.curated/apollo-performance-tuning .claude/skills/apollo-performance-tuning && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
apollo-performance-tuning
GitHub stars
2.8k
Token cost
~2.1k tokens
SKILL.md length
313 words
Files
2 (incl. references)
Skills in repo
3,342
Repo updated
First seen
Licence
MIT

At a glance

Optimize Apollo.io API performance. An agent skill from jeremylongshore/tons-of-skills-marketplace.

  • Works in 6 steps: Connection Pooling → Response Caching with Per-Endpoint TTLs → Use Bulk Endpoints Over Single Calls → …
  • Improving API response times
  • SKILL.md covers Overview, Prerequisites, Instructions and Output, plus 4 more sections
  • Reaches api.apollo.io; needs APOLLO_API_KEY

What it does

Apollo Performance Tuning is an agent skill from jeremylongshore/tons-of-skills-marketplace. Optimize Apollo.io API performance. Use when improving API response times, reducing latency, or optimizing bulk operations. Trigger with phrases like "apollo performance", "optimize apollo", "apollo slow", "apollo latency", "speed up apollo".

Its SKILL.md is about 2.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/implementation-guide.md`). Compatibility notes: Designed for Claude Code

It sits in Backend & APIs, covering GraphQL. The repository describes itself as: Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com. The licence is MIT.

When your agent uses it

  • Improving API response times
  • Reducing latency
  • Optimizing bulk operations
  • With phrases like apollo performance

Example prompts

  • “apollo performance”
  • “optimize apollo”
  • “apollo slow”
  • “/apollo-performance-tuning”

Requirements

  • Node.js
  • A credential in APOLLO_API_KEY
  • Compatibility (from SKILL.md): Designed for Claude Code
  • Pre-approved tools (allowed-tools): Read, Write, Edit, Bash(gh:*), Bash(curl:*)

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. Connection Pooling
  2. Response Caching with Per-Endpoint TTLs
  3. Use Bulk Endpoints Over Single Calls
  4. Parallel Search with Concurrency Control
  5. Slim Response Payloads
  6. Benchmark Your Endpoints

What it can do on your machine

Read from SKILL.md and the folder at commit cfae287. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Edit
    • Bash(gh:*)
    • Bash(curl:*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are typescript).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • api.apollo.io

    Also links to:

    • github.com
    • docs.apollo.io
    • nodejs.org

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • APOLLO_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

  • Compatibility

    Designed for Claude Code

    From compatibility in the SKILL.md frontmatter.

Context cost

Apollo Performance Tuning loads about 2.1k tokens when it runs, and up to ~4.4k if it reads all its reference files. Until then it costs about 67 tokens; SKILL.md has 313 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~67
When it runs · the whole SKILL.md, loaded when a task matches
~2.1k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~4.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from jeremylongshore/tons-of-skills-marketplace at commit cfae287, republished under its MIT licence (© jeremylongshore). 313 words, ~2,064 tokens.

Download SKILL.mdSave it as .claude/skills/apollo-performance-tuning/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
apollo-performance-tuning
description
Optimize Apollo.io API performance. Use when improving API response times, reducing latency, or optimizing bulk operations. Trigger with phrases like "apollo performance", "optimize apollo", "apollo slow", "apollo latency", "speed up apollo".
allowed-tools
Read, Write, Edit, Bash(gh:*), Bash(curl:*)
compatibility
Designed for Claude Code
version
1.13.0
license
MIT
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
saas, apollo, api, performance

Apollo Performance Tuning

Overview

Optimize Apollo.io API performance through response caching, connection pooling, bulk operations, parallel fetching, and result slimming. Key insight: search is free but slow (~500ms), enrichment costs credits — cache aggressively and batch enrichment calls.

Prerequisites

  • Valid Apollo API key
  • Node.js 18+

Instructions

Step 1: Connection Pooling

Reuse TCP connections to avoid TLS handshake overhead on every request.

typescript
// src/apollo/optimized-client.ts
import axios from 'axios';
import https from 'https';

const httpsAgent = new https.Agent({
  keepAlive: true,
  maxSockets: 10,
  maxFreeSockets: 5,
  timeout: 30_000,
});

export const optimizedClient = axios.create({
  baseURL: 'https://api.apollo.io/api/v1',
  headers: { 'Content-Type': 'application/json', 'x-api-key': process.env.APOLLO_API_KEY! },
  httpsAgent,
  timeout: 15_000,
});
Step 2: Response Caching with Per-Endpoint TTLs
typescript
// src/apollo/cache.ts
import { LRUCache } from 'lru-cache';

// Different TTLs based on data volatility
const CACHE_TTLS: Record<string, number> = {
  '/organizations/enrich': 24 * 60 * 60 * 1000,    // 24h — company data rarely changes
  '/people/match': 4 * 60 * 60 * 1000,              // 4h — contact data changes occasionally
  '/mixed_people/api_search': 15 * 60 * 1000,       // 15min — search results are dynamic
  '/mixed_companies/search': 30 * 60 * 1000,         // 30min — company search
  '/contact_stages': 60 * 60 * 1000,                 // 1h — stages rarely change
};

const cache = new LRUCache<string, { data: any; at: number }>({
  max: 5000,
  maxSize: 50 * 1024 * 1024,
  sizeCalculation: (v) => JSON.stringify(v).length,
});

function cacheKey(endpoint: string, params: any): string {
  return `${endpoint}:${JSON.stringify(params)}`;
}

export async function cachedRequest<T>(
  endpoint: string,
  requestFn: () => Promise<T>,
  params: any,
): Promise<T> {
  const key = cacheKey(endpoint, params);
  const ttl = CACHE_TTLS[endpoint] ?? 15 * 60 * 1000;
  const cached = cache.get(key);

  if (cached && Date.now() - cached.at < ttl) return cached.data;

  const data = await requestFn();
  cache.set(key, { data, at: Date.now() });
  return data;
}

export function getCacheStats() {
  return { entries: cache.size, sizeBytes: cache.calculatedSize };
}
Step 3: Use Bulk Endpoints Over Single Calls

Apollo's bulk enrichment endpoint handles 10 records per call vs 1. Massive performance gain.

typescript
// src/apollo/bulk-ops.ts
import { optimizedClient } from './optimized-client';
import PQueue from 'p-queue';

const queue = new PQueue({ concurrency: 3, intervalCap: 2, interval: 1000 });

// Enrich 100 people: 100 individual calls = 100 requests @ 500ms = 50s
// Batch of 10: 10 bulk calls @ 600ms = 6s (8x faster, same credits)
export async function batchEnrich(
  details: Array<{ email?: string; linkedin_url?: string; first_name?: string; last_name?: string; organization_domain?: string }>,
): Promise<any[]> {
  const results: any[] = [];

  for (let i = 0; i < details.length; i += 10) {
    const batch = details.slice(i, i + 10);
    const result = await queue.add(async () => {
      const { data } = await optimizedClient.post('/people/bulk_match', {
        details: batch,
        reveal_personal_emails: false,
        reveal_phone_number: false,
      });
      return data.matches ?? [];
    });
    results.push(...(result ?? []));
  }

  return results;
}
Step 4: Parallel Search with Concurrency Control
typescript
export async function parallelSearch(
  domains: string[],
  concurrency: number = 5,
): Promise<Map<string, any[]>> {
  const searchQueue = new PQueue({ concurrency });
  const results = new Map<string, any[]>();

  await searchQueue.addAll(
    domains.map((domain) => async () => {
      const data = await cachedRequest(
        '/mixed_people/api_search',
        () => optimizedClient.post('/mixed_people/api_search', {
          q_organization_domains_list: [domain],
          person_seniorities: ['vp', 'director', 'c_suite'],
          per_page: 25,
        }).then((r) => r.data),
        { domain },
      );
      results.set(domain, data.people ?? []);
    }),
  );

  return results;
}
Step 5: Slim Response Payloads

Apollo returns large person objects (~2KB each). Extract only needed fields to reduce memory.

typescript
interface SlimPerson {
  id: string;
  name: string;
  title: string;
  email?: string;
  company: string;
  seniority: string;
}

function slimPerson(raw: any): SlimPerson {
  return {
    id: raw.id,
    name: raw.name,
    title: raw.title,
    email: raw.email,
    company: raw.organization?.name ?? '',
    seniority: raw.seniority ?? '',
  };
}

// Use immediately after API call to free memory
const { data } = await optimizedClient.post('/mixed_people/api_search', { ... });
const slim = data.people.map(slimPerson);  // ~200 bytes each instead of ~2KB
Step 6: Benchmark Your Endpoints
typescript
async function benchmark(includePaidEndpoints = false) {
  const endpoints = [
    { name: 'People Search', fn: () => optimizedClient.post('/mixed_people/api_search',
        { q_organization_domains_list: ['apollo.io'], per_page: 1 }) },
    { name: 'Auth Health', fn: () => optimizedClient.get('/auth/health') },
  ];

  // Paid enrichment benchmarks require an approved, budgeted test run.
  if (includePaidEndpoints) {
    endpoints.push({ name: 'Org Enrich', fn: () => optimizedClient.get('/organizations/enrich',
      { params: { domain: 'apollo.io' } }) });
  }

  for (const ep of endpoints) {
    const times: number[] = [];
    for (let i = 0; i < 5; i++) {
      const start = Date.now();
      try { await ep.fn(); } catch {}
      times.push(Date.now() - start);
    }
    const avg = Math.round(times.reduce((a, b) => a + b) / times.length);
    const p95 = times.sort((a, b) => a - b)[Math.floor(times.length * 0.95)];
    console.log(`${ep.name}: avg=${avg}ms, p95=${p95}ms`);
  }
}

Output

  • Connection pooling with keepAlive and configurable maxSockets
  • LRU cache with per-endpoint TTLs (24h org, 4h contact, 15m search)
  • Bulk enrichment via /people/bulk_match (10x fewer requests)
  • Parallel search with p-queue concurrency control
  • Response slimming reducing memory from ~2KB to ~200B per person
  • Benchmarking script measuring avg and p95 latency

Examples

For a search-latency regression, capture a baseline with the free search and health endpoints against a mock or approved sandbox fixture, then introduce connection reuse and a bounded cache behind a feature flag. Compare p95, error rate, cache-hit behavior, and result equivalence before promoting the change. A paid-enrichment benchmark requires an explicit approval flag, a fixed credit budget, and a public organization fixture; otherwise it remains out of the run. Roll back the flag if latency improves at the cost of stale, incorrect, or over-broadly cached results.

Error Handling

IssueResolution
High latencyEnable connection pooling, check for stale cache
Cache missesIncrease TTL for stable data (org enrichment)
Rate limits with parallelismReduce p-queue concurrency
Memory growthLower LRU max entries, slim response payloads

Resources

Next Steps

Proceed to apollo-cost-tuning for cost optimization.

© jeremylongshore, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (references) in skills/.curated/apollo-performance-tuning of jeremylongshore/tons-of-skills-marketplace.

  • SKILL.md
  • references/implementation-guide.md

Open the folder on GitHubat commit cfae287

Compare with similar skills

Apollo Performance Tuning next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Apollo Performance Tuning compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Apollo Performance Tuning this skilljeremylongshore/tons-of-skills-marketplace2.8k—~2.1kAutomated safety check: PassMIT
Nodejs Backend Patternsever-works/ever-works16218 repos~4kAutomated safety check: PassAGPL-3.0
API DesignerJeffallan/claude-skills12k1 repos~2kAutomated safety check: PassMIT
GraphQL Operations with CodegenChrisWiles/claude-code-showcase6.1k3 repos~1.5kAutomated safety check: PassNone
Supabasecurvenote/curvenote1705 repos~2.2kAutomated safety check: PassCustom licence
API Design Principlesjh941213/my-cc-harness12518 repos~3.4kAutomated safety check: PassNone

Similar skills

  • Nodejs Backend Patterns

    ever-works/ever-works

    Build production-ready Node.js backend services with Express/Fastify, implementing middleware patterns, error handling, authentication, database integration, and API design best practices.

    162 GitHub starsUsed in 18 repos~4k tokens
    Backend & APIsAuto-check passed
  • API Designer

    Jeffallan/claude-skills

    Designs REST and GraphQL APIs from resource modeling to an OpenAPI 3.1 contract, with versioning, pagination and RFC 7807 error handling.

    12k GitHub starsUsed in 1 repo~2k tokens
    Backend & APIsAuto-check passed
  • GraphQL Operations with Codegen

    ChrisWiles/claude-code-showcase

    Sets the rules for writing GraphQL queries and mutations in .gql files, running codegen, and using generated Apollo hooks with proper error and loading handling.

    6.1k GitHub starsUsed in 3 repos~1.5k tokens
    Backend & APIsAuto-check passed
  • Supabase

    curvenote/curvenote

    A skill your agent uses when doing ANY task involving Supabase.

    170 GitHub starsUsed in 5 repos~2.2k tokens
    Backend & APIsAuto-check passed
  • API Design Principles

    jh941213/my-cc-harness

    REST 및 GraphQL API 설계 원칙 가이드. An agent skill from jh941213/my-cc-harness.

    125 GitHub starsUsed in 18 repos~3.4k tokens
    Backend & APIsAuto-check passed
  • API And Interface Design

    dzhalaevd/Donatello

    Guides stable API and interface design. An agent skill from dzhalaevd/Donatello.

    135 GitHub starsUsed in 8 repos~2.6k tokens
    Backend & APIsAuto-check passed

More from jeremylongshore/tons-of-skills-marketplace

All 3,342 skills in this repo
  • Performing Security Code Review

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to conduct a security-focused code review using the security-agent plugin.

    2.8k GitHub starsUsed in 2 repos~1.3k tokens
    Auto-check: notes
  • Adapting Transfer Learning Models

    jeremylongshore/tons-of-skills-marketplace

    Build this skill automates the adaptation of pre-trained machine learning models using transfer learning techniques.

    2.8k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Agent Context Loader

    jeremylongshore/tons-of-skills-marketplace

    Execute proactive auto-loading: automatically detects and loads agents.md files.

    2.8k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Aggregating Performance Metrics

    jeremylongshore/tons-of-skills-marketplace

    Aggregate and centralize performance metrics from applications, systems, databases, caches, and services.

    2.8k GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Analyzing Capacity Planning

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to analyze capacity requirements and plan for future growth.

    2.8k GitHub stars~947 tokensUpdated today
    Auto-check passed
  • Analyzing Database Indexes

    jeremylongshore/tons-of-skills-marketplace

    Process use when you need to work with database indexing. An agent skill from jeremylongshore/tons-of-skills-marketplace.

    2.8k GitHub stars~2k tokensUpdated today
    Auto-check passed

Categories

Questions about Apollo Performance Tuning

What does Apollo Performance Tuning do?

Optimize Apollo.io API performance. An agent skill from jeremylongshore/tons-of-skills-marketplace. Apollo Performance Tuning is an agent skill from jeremylongshore/tons-of-skills-marketplace.io API performance.

When should I use Apollo Performance Tuning?

Apollo Performance Tuning fits situations like: improving API response times; reducing latency; optimizing bulk operations; with phrases like apollo performance.

How do I install Apollo Performance Tuning in Claude Code?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill apollo-performance-tuning -a claude-code`. Or copy the skill folder (skills/.curated/apollo-performance-tuning in jeremylongshore/tons-of-skills-marketplace) into .claude/skills/apollo-performance-tuning in your project. Claude Code loads it when a task matches its description.

How do I install Apollo Performance Tuning in Codex?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill apollo-performance-tuning -a codex`. Or copy the skill folder (skills/.curated/apollo-performance-tuning in jeremylongshore/tons-of-skills-marketplace) into .agents/skills/apollo-performance-tuning in your project. Codex loads it when a task matches its description.

Can I use Apollo Performance Tuning in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill apollo-performance-tuning -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/apollo-performance-tuning, .gemini/skills/apollo-performance-tuning, .github/skills/apollo-performance-tuning and .opencode/skills/apollo-performance-tuning in your project.

What does Apollo Performance Tuning need to run?

Going by SKILL.md and its folder, Apollo Performance Tuning needs credentials named APOLLO_API_KEY. Our summary lists: Node.js; A credential in APOLLO_API_KEY. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash(gh:*), Bash(curl:*). Compatibility (from SKILL.md): Designed for Claude Code.

Does Apollo Performance Tuning access the network?

SKILL.md names 4 domains. In commands or code: api.apollo.io; the agent is likely to contact it when it follows the instructions. As links in the text: github.com, docs.apollo.io and nodejs.org. This is read from the text; nothing was executed.

Is Apollo Performance Tuning safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Apollo Performance Tuning use?

Apollo Performance Tuning is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Apollo Performance Tuning use?

About 2.1k tokens (SKILL.md is roughly 8.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 2.3k tokens, read only when the agent opens those files.

What are the alternatives to Apollo Performance Tuning?

Skills that share tags, products or a category with Apollo Performance Tuning: Nodejs Backend Patterns (ever-works/ever-works, 162 stars), API Designer (Jeffallan/claude-skills, 12k stars), GraphQL Operations with Codegen (ChrisWiles/claude-code-showcase, 6.1k stars) and Supabase (curvenote/curvenote, 170 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Apollo Performance Tuning?

jeremylongshore (a GitHub user) maintains it in jeremylongshore/tons-of-skills-marketplace, which has 2,827 GitHub stars. The repository holds 3,342 skills in this directory. The repository was last updated on October 10, 2026.

Source: jeremylongshore/tons-of-skills-marketplace on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.