Agent skill

Portaljs Add Resource

by datopian in datopian/portaljs

Add another file (resource) to an EXISTING dataset in a PortalJS portal — a data dictionary, methodology, or an additional data file.

MITAuto-check passed

Install Portaljs Add Resource

skills CLI
$ npx skills add datopian/portaljs --skill portaljs-add-resource -a claude-code

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

GitHub CLI
$ gh skill install datopian/portaljs portaljs-add-resource --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/datopian/portaljs.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/portaljs-add-resource .claude/skills/portaljs-add-resource && 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
portaljs-add-resource
GitHub stars
2.4k
Used in
1 other repo
Token cost
~1.6k tokens
SKILL.md length
639 words
Files
2 (incl. references)
Skills in repo
14
Repo updated
First seen
Licence
MIT

At a glance

Add another file (resource) to an EXISTING dataset in a PortalJS portal — a data dictionary, methodology, or an additional data file.

  • Works in 6 steps: Gather input (interview if thin):… → Validate the portal and locate the… → Detect the format from… → …
  • A dataset needs a second file
  • SKILL.md covers Overview, Prerequisites, Instructions and Output, plus 3 more sections
  • Calls npx and curl

What it does

Portaljs Add Resource is an agent skill from datopian/portaljs. Add another file (resource) to an EXISTING dataset in a PortalJS portal — a data dictionary, methodology, or an additional data file. Turns a single-file dataset into a multi-resource one; the showcase renders a section per resource. Use when a dataset needs a second file, such as a data dictionary, methodology doc, or an additional period's data.

Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/reference.md`). Compatibility notes: Claude Code with PortalJS portals (Next.js 14, React 18, Node 18+). Runs from any project via the plugin, a personal ~/.claude/commands install, or a portaljs…

The repository describes itself as: 🌀 AI-native framework for building data portals. Scaffold a full portal from a brief and load datasets in minutes with agentic skills — any backend (CKAN, GitHub, Frictionless). The licence is MIT.

When your agent uses it

  • A dataset needs a second file
  • Such as a data dictionary
  • Methodology doc
  • An additional periods data

Example prompts

  • “/portaljs-add-resource”

Requirements

  • Node.js
  • Compatibility (from SKILL.md): Claude Code with PortalJS portals (Next.js 14, React 18, Node 18+). Runs from any project via the plugin, a personal ~/.claude/commands install, or a portaljs clone.
  • Pre-approved tools (allowed-tools): Read, Write, Edit, Bash(npm:*), Bash(curl:*), Bash(mkdir:*), Bash(cp:*), WebFetch

Workflow steps

6 steps, taken from the first numbered list in SKILL.md.

  1. Gather input (interview if thin): DATASET (slug or namespace/slug), SOURCE
  2. Validate the portal and locate the dataset entry by slug (and namespace, if
  3. Detect the format from extension/Content-Type, fetch (check HTTP status) or
  4. Update datasets.json: if the dataset has no resources yet, migrate its
  5. Verify the build with npx next build, capturing output to a log file; fix
  6. Report the outcome (see Output below).

What it can do on your machine

Read from SKILL.md and the folder at commit d5c096a. 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(npm:*)
    • Bash(curl:*)
    • Bash(mkdir:*)
    • Bash(cp:*)
    • WebFetch

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npx
    • curl

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

  • Network

    Links to these hosts (documentation or services it may open):

    • datapackage.org

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

  • Credentials

    Names no API keys, tokens, secrets or passwords.

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

  • Compatibility

    Claude Code with PortalJS portals (Next.js 14, React 18, Node 18+). Runs from any project via the plugin, a personal ~/.claude/commands install, or a portaljs clone.

    From compatibility in the SKILL.md frontmatter.

Context cost

Portaljs Add Resource loads about 1.6k tokens when it runs, and up to ~2.3k if it reads all its reference files. Until then it costs about 93 tokens; SKILL.md has 639 words of instructions outside code blocks.

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

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 datopian/portaljs at commit d5c096a, republished under its MIT licence (© datopian). 639 words, ~1,566 tokens.

Download SKILL.mdSave it as .claude/skills/portaljs-add-resource/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
portaljs-add-resource
description
Add another file (resource) to an EXISTING dataset in a PortalJS portal — a data dictionary, methodology, or an additional data file. Turns a single-file dataset into a multi-resource one; the showcase renders a section per resource. Use when a dataset needs a second file, such as a data dictionary, methodology doc, or an additional period's data.
allowed-tools
Read, Write, Edit, Bash(npm:*), Bash(curl:*), Bash(mkdir:*), Bash(cp:*), WebFetch
compatibility
Claude Code with PortalJS portals (Next.js 14, React 18, Node 18+). Runs from any project via the plugin, a personal ~/.claude/commands install, or a portaljs clone.
version
1.0.0
author
Datopian <hello@datopian.com>
license
MIT
tags
portaljs, data-portal, resource, data-dictionary, metadata, catalog

PortalJS — Add Resource

Overview

Add a resource — an additional file — to a dataset that already exists in a portaljs-catalog portal. Where /portaljs-add-dataset creates a new dataset (one file), this skill adds a file to an existing one: a data dictionary, a methodology document, or another data file (e.g. a second year's figures).

Mirrors the Frictionless Data Package model: a dataset holds a resources[] array, and the showcase at /@<namespace>/<slug> renders one section per resource (preview, schema, download). A single-file dataset migrates to resources[] automatically the first time a second file is added — no data is lost.

Prerequisites

  • An existing PortalJS portal (portaljs-catalog template) with datasets.json, package.json, and pages/[owner]/[slug].tsx present.
  • The target dataset already registered in datasets.json.
  • The new resource's source: a local file path or a public URL, in CSV, TSV, JSON (array), or GeoJSON format.
  • Node 18+ installed to run npx next build for verification.

Instructions

The canonical, full step-by-step workflow lives in .claude/commands/portaljs-add-resource.md in this repository — that file is the single source of truth. Read and follow it. Summary:

  1. Gather input (interview if thin): DATASET (slug or namespace/slug), SOURCE (path or URL), PORTAL_DIR (default .), RESOURCE_NAME, RESOURCE_TITLE, DESCRIPTION. If DATASET or SOURCE is missing, list datasets from datasets.json and ask.
  2. Validate the portal and locate the dataset entry by slug (and namespace, if given). If the dataset does not exist, offer /portaljs-add-dataset instead.
  3. Detect the format from extension/Content-Type, fetch (check HTTP status) or confirm the local path exists, then copy into PORTAL_DIR/public/data/ under a non-colliding filename.
  4. Update datasets.json: if the dataset has no resources yet, migrate its top-level file/format/schema into the first resource (lossless), then append the new resource; if resources already exists, just append, keeping name unique within the array.
  5. Verify the build with npx next build, capturing output to a log file; fix malformed JSON before reporting success.
  6. Report the outcome (see Output below).

Output

✓ Resource added to DATASET: RESOURCE_TITLE (RESOURCE_NAME.EXT)
  - Data file: public/data/RESOURCE_NAME.EXT
  - Manifest:  datasets.json (dataset now has <n> resources)
  - Showcase:  /@<namespace>/<slug> renders a section per resource

If this was the first migration to multi-resource, note that the dataset's single file was moved into resources[] with no data lost.

Show full SKILL.md (303 more words)Show less

Error Handling

SymptomCauseFix
"Dataset not found"DATASET slug/namespace doesn't match any entry in datasets.jsonList datasets from datasets.json and ask the user to pick, or run /portaljs-add-dataset to create it
npx next build fails with a JSON parse errorManually edited datasets.json has a trailing comma or unescaped characterRe-open the file, fix the JSON, and rebuild before reporting success
Resource file fails to fetch (non-2xx)SOURCE URL is wrong, private, or the host is downConfirm the URL in a browser or with curl -I SOURCE; ask for a corrected URL or a local path
New resource's filename collides with an existing one in /public/dataAuto-derived RESOURCE_NAME matches an existing file stemPick a distinct RESOURCE_NAME, or let the skill append a numeric suffix
Showcase doesn't render the new section after buildname in the new resource object duplicates an existing resource's nameRename the resource's name to something unique within that dataset's resources[]

Examples

Example 1 — Add a data dictionary to a single-file dataset
/portaljs-add-resource orders ./data/orders-data-dictionary.csv --title "Data dictionary"

orders was a single CSV. It is migrated to a two-resource dataset (the original data plus the dictionary), and its showcase now renders a section for each.

Example 2 — Add a resource by URL to a dataset that already has resources
/portaljs-add-resource climate-observations https://example.org/data/methodology.json --name methodology --title "Methodology notes"

The skill fetches the URL, checks the HTTP status, copies it to public/data/methodology.json, and appends it to the existing resources[] array.

Example 3 — Run with no arguments (interview mode)
/portaljs-add-resource

With no arguments, the skill lists datasets from datasets.json, asks which one to extend and for the new file's path or URL, then proceeds through steps 2-6 above.

Resources

© datopian, 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/portaljs-add-resource of datopian/portaljs.

  • SKILL.md
  • references/reference.md

Open the folder on GitHubat commit d5c096a

Used in 1 other repository

We found 1 copy of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in datopian/portaljs, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Portaljs Add Resource 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.

Portaljs Add Resource compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Portaljs Add Resource this skilldatopian/portaljs2.4k1 repos~1.6kAutomated safety check: PassMIT
DatasetsArize-ai/phoenix12k—~1.6kAutomated safety check: PassCustom licence
Repository Resource PortalR6410418/Jackrong-llm-finetuning-guide1.7k—~387Automated safety check: PassApache-2.0
Agent Resource Allocatorruvnet/ruflo74k2 repos~4.9kAutomated safety check: PassMIT
Resourceswindmill-labs/windmill18k—~1.7kAutomated safety check: PassCustom licence
PortalBuilderIO/agent-native7.1k—~1.1kAutomated safety check: NotesNone

Similar skills

  • Datasets

    Arize-ai/phoenix

    Understand what a Phoenix dataset is and reason well about its examples, outputs, splits, and how it feeds evaluators and experiments.

    12k GitHub stars~1.6k tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Repository Resource Portal

    R6410418/Jackrong-llm-finetuning-guide

    Maintain this repository as a growing educational LLM knowledge base.

    1.7k GitHub stars~387 tokensUpdated 3 mo ago
    Frontend & DesignAuto-check passed
  • Agent skill for resource-allocator - invoke with $agent-resource-allocator

    74k GitHub starsUsed in 2 repos~4.9k tokens
    Auto-check passed
  • Resources

    windmill-labs/windmill

    MUST use when managing resources.

    18k GitHub stars~1.7k tokensUpdated today
    Backend & APIsAuto-check passed
  • Portal

    BuilderIO/agent-native

    Continue a coding session on a paired always-on computer. An agent skill from BuilderIO/agent-native.

    7.1k GitHub stars~1.1k tokensUpdated today
    Productivity & AutomationAuto-check: notes
  • Resource Hints

    thedaviddias/Front-End-Checklist

    A skill your agent uses when auditing slow page loads, heavy assets, or rendering delays related to Use resource hints for faster loading.

    74k GitHub stars~430 tokensUpdated 3 days ago
    Frontend & DesignAuto-check passed

More from datopian/portaljs

All 14 skills in this repo
  • Arcgis To Portaljs

    datopian/portaljs

    Migrate a whole ArcGIS Hub site into a PortalJS Arc portal end-to-end.

    2.4k GitHub starsUsed in 1 repo~2k tokens
    Auto-check passed
  • Portaljs Add Chart

    datopian/portaljs

    Add a chart (line, bar, area, pie, or scatter) to a dataset's showcase in a PortalJS portal.

    2.4k GitHub starsUsed in 1 repo~1.1k tokens
    Auto-check passed
  • Portaljs Add Dataset

    datopian/portaljs

    Add a dataset (CSV, TSV, JSON, or GeoJSON) to an existing PortalJS portal.

    2.4k GitHub starsUsed in 1 repo~1.6k tokens
    Auto-check passed
  • Portaljs Add Dcat

    datopian/portaljs

    Make a PortalJS portal harvestable by national/EU/US open-data portals — emit standards-compliant DCAT catalog feeds (DCAT 2/3, DCAT-AP, DCAT-US, national profiles) in JSON-LD, Turtle, and RDF/XML…

    2.4k GitHub starsUsed in 1 repo~1.8k tokens
    Auto-check passed
  • Portaljs Add Geo

    datopian/portaljs

    Auto-ingest a geospatial file (GeoJSON, Shapefile, GeoPackage, KML/KMZ, FlatGeobuf, CSV-with-geometry) into a PortalJS portal on the user's own machine, with no server.

    2.4k GitHub starsUsed in 1 repo~1.7k tokens
    Auto-check passed
  • Portaljs Add Map

    datopian/portaljs

    Render a GeoJSON dataset on an interactive Leaflet map in the Views section of a dataset's showcase.

    2.4k GitHub starsUsed in 1 repo~1.3k tokens
    Auto-check passed

Questions about Portaljs Add Resource

What does Portaljs Add Resource do?

Add another file (resource) to an EXISTING dataset in a PortalJS portal — a data dictionary, methodology, or an additional data file. Portaljs Add Resource is an agent skill from datopian/portaljs. Add another file (resource) to an EXISTING dataset in a PortalJS portal — a data dictionary, methodology, or an additional data file.

When should I use Portaljs Add Resource?

Portaljs Add Resource fits situations like: A dataset needs a second file; such as a data dictionary; methodology doc; an additional periods data.

How do I install Portaljs Add Resource in Claude Code?

Run `npx skills add datopian/portaljs --skill portaljs-add-resource -a claude-code`. Or copy the skill folder (skills/portaljs-add-resource in datopian/portaljs) into .claude/skills/portaljs-add-resource in your project. Claude Code loads it when a task matches its description.

How do I install Portaljs Add Resource in Codex?

Run `npx skills add datopian/portaljs --skill portaljs-add-resource -a codex`. Or copy the skill folder (skills/portaljs-add-resource in datopian/portaljs) into .agents/skills/portaljs-add-resource in your project. Codex loads it when a task matches its description.

Can I use Portaljs Add Resource 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 datopian/portaljs --skill portaljs-add-resource -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/portaljs-add-resource, .gemini/skills/portaljs-add-resource, .github/skills/portaljs-add-resource and .opencode/skills/portaljs-add-resource in your project.

What does Portaljs Add Resource need to run?

Going by SKILL.md and its folder, Portaljs Add Resource needs the command-line tools its instructions call (npx and curl). Our summary lists: Node.js. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash(npm:*), Bash(curl:*), Bash(mkdir:*), Bash(cp:*), WebFetch. Compatibility (from SKILL.md): Claude Code with PortalJS portals (Next.js 14, React 18, Node 18+). Runs from any project via the plugin, a personal ~/.claude/commands install, or a portaljs clone..

Does Portaljs Add Resource access the network?

SKILL.md names 1 domain. As links in the text: datapackage.org. This is read from the text; nothing was executed.

Is Portaljs Add Resource 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 Portaljs Add Resource use?

Portaljs Add Resource 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 Portaljs Add Resource use?

About 1.6k tokens (SKILL.md is roughly 6.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 740 tokens, read only when the agent opens those files.

What are the alternatives to Portaljs Add Resource?

Skills that share tags, products or a category with Portaljs Add Resource: Datasets (Arize-ai/phoenix, 12k stars), Repository Resource Portal (R6410418/Jackrong-llm-finetuning-guide, 1.7k stars), Agent Resource Allocator (ruvnet/ruflo, 74k stars) and Resources (windmill-labs/windmill, 18k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Portaljs Add Resource?

datopian (a GitHub organization) maintains it in datopian/portaljs, which has 2,358 GitHub stars. The repository holds 14 skills in this directory. The repository was last updated on October 8, 2026.

Source: datopian/portaljs on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.