agentleFS
geoai-latamgeoai-latam/SKILL_JS5_ARCGIS/skills/arcgis-portal-content/AGENTS.md

SKILL_JS5_ARCGIS / arcgis-portal-content

AGENTS.md1 starsChanged 6 months agoMITView on GitHub

Quick-reference for portal content (SDK 5.1). Read before searching/loading items. 1. Know the id? → web map: item-id on <arcgis-map> / WebMap; layer item: Layer.fromPortalItem; metadata: new PortalItem({ id }) + load(). 2. Search? → portal.queryItems(new PortalQueryParams({ query, num: 100, sortField, sortOrder })). 3. Groups? → portal.queryGroups / group.queryItems.

The file

Files
AGENTS.md

Agent Guide: arcgis-portal-content

Quick-reference for portal content (SDK 5.1). Read before searching/loading items.

Quick Decision Tree

  1. Know the id? → web map: item-id on <arcgis-map> / WebMap; layer item: Layer.fromPortalItem; metadata: new PortalItem({ id }) + load().
  2. Search? → portal.queryItems(new PortalQueryParams({ query, num: 100, sortField, sortOrder })).
  3. Groups? → portal.queryGroups / group.queryItems.

Setup Checklist

  • Page until nextQueryParams.start === -1 (the object is always there).
  • num ≤ 100; start + num ≤ 10000.
  • sortOrder: "desc" for "latest".
  • await item.load() before reading metadata.
  • Set portal.url for Enterprise; sign in for private content.

Anti-patterns (one-liner reminders)

  • ❌ while (page.nextQueryParams): restarts at page one forever.
  • ❌ sortField: "modified" alone: oldest first.
  • ❌ Layer.fromPortalItem on a web map: Unknown item type 'Web Map'.
  • ❌ Reading item.title before load() (null).

Files in This Skill

  • SKILL.md / SKILL.es.md — full guides
  • references/api-detail.md — Portal / PortalItem / query
  • references/examples.md — search / load / groups
  • references/pitfalls.md — extended troubleshooting
  • scripts/snippet-portal-query.ts

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.