pexels-media

pexels-media is a skill for Claude Code, Codex from nicepkg/ai-workflow. It costs 45 tokens per session (2,731 once invoked), scanned A, original, MIT.

A media-sourcing tool that searches the Pexels library for royalty-free photos and videos, with options for curated content, collections, and image sizes.

In plain words
What is it for?
Use it to source photos or videos for designs, placeholders, and published content, with a Pexels API key.
Why use it?
It helps find visual assets for designs and content without having to search and download them manually from the Pexels website.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/nicepkg/ai-workflow/pexels-media
Any agent
npx skills add nicepkg/ai-workflow --skill pexels-media
Clone the repo
git clone --depth 1 https://github.com/nicepkg/ai-workflow

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pexels-media

README.md
[![agentmods](https://agentmods.dev/badge/skills/nicepkg/ai-workflow/pexels-media.svg)](https://agentmods.dev/skills/nicepkg/ai-workflow/pexels-media)
Your own site
<a href="https://agentmods.dev/skills/nicepkg/ai-workflow/pexels-media"><img src="https://agentmods.dev/badge/skills/nicepkg/ai-workflow/pexels-media.svg" alt="Measured on agentmods" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,731 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00045 $0.02731
Opus 5 $0.00023 $0.01366
Sonnet 5 $0.00009 $0.00546
Haiku 4.5 $0.00005 $0.00273

Measured yesterday against content hash 75c82060a5c9, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

pexels-media scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -H "Authorization: $PEXELS_API_KEY" "https://api.pexels.com/v1/search?query=nature"
workflows/talk-to-slidev-workflow/.claude/skills/pexels-media/SKILL.md · 333 lines

How it starts

The opening of the file, as written. The whole thing — 333 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Pexels Media Sourcing

Source high-quality, royalty-free images and videos from Pexels for design work, placeholders, or content creation.

Prerequisites

This skill requires the PEXELS_API_KEY environment variable to be set.

# Check if API key is available
echo $PEXELS_API_KEY

If not set, obtain a free API key from Pexels API.

API Base URLs

  • Photos: https://api.pexels.com/v1/
  • Videos: https://api.pexels.com/videos/

Authentication

All requests require the Authorization header:

curl -H "Authorization: $PEXELS_API_KEY" "https://api.pexels.com/v1/search?query=nature"

Photo Endpoints

Search Photos

curl -H "Authorization: $PEXELS_API_KEY" \
  "https://api.pexels.com/v1/search?query=QUERY&orientation=ORIENTATION&size=SIZE&color=COLOR&locale=LOCALE&page=PAGE&per_page=PER_PAGE"

Parameters:

Parameter Required Values
query Yes Search term
orientation No landscape, portrait, square
size No large (24MP), medium (12MP), small (4MP)
color No red, orange, yellow, green, turquoise, blue, violet, pink, brown, black, gray, white, or hex code (e.g., #ffffff)
locale No en-US, pt-BR, es-ES, de-DE, fr-FR, ja-JP, zh-CN, ko-KR, etc.
page No Page number (default: 1)
per_page No Results per page (default: 15, max: 80)

Curated Photos

Trending photos curated by the Pexels team (updated hourly):

curl -H "Authorization: $PEXELS_API_KEY" \
  "https://api.pexels.com/v1/curated?page=1&per_page=15"

Get Photo by ID

curl -H "Authorization: $PEXELS_API_KEY" \
  "https://api.pexels.com/v1/photos/PHOTO_ID"

Video Endpoints

Search Videos

curl -H "Authorization: $PEXELS_API_KEY" \
  "https://api.pexels.com/videos/search?query=QUERY&orientation=ORIENTATION&size=SIZE&min_width=MIN_WIDTH&min_height=MIN_HEIGHT&min_duration=MIN_DURATION&max_duration=MAX_DURATION&page=PAGE&per_page=PER_PAGE"

Read the full file on GitHub · 333 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 333 lines · 45 tokens per session scan A 75c82060a5c9

Subscribe to this mod's changes

pexels-media is a skill published in the GitHub repository nicepkg/ai-workflow (282 stars, last pushed 7mo ago), licensed MIT. It adds 45 tokens to every session and 2,731 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.