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.
npx skills add perforce/p4mcp-server --skill p4-workspace-setupgit clone --depth 1 https://github.com/perforce/p4mcp-serverWrote 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.
[](https://agentmods.dev/skills/perforce/p4mcp-server/p4-workspace-setup)<a href="https://agentmods.dev/skills/perforce/p4mcp-server/p4-workspace-setup"><img src="https://agentmods.dev/badge/skills/perforce/p4mcp-server/p4-workspace-setup/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/perforce/p4mcp-server/p4-workspace-setup"><img src="https://agentmods.dev/badge/skills/perforce/p4mcp-server/p4-workspace-setup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00575 |
| Opus 5.5 | $0.00000 | $0.00230 |
| Sonnet 5.5 | $0.00000 | $0.00115 |
| Haiku 4.5 | $0.00000 | $0.00057 |
Grade A, and why
p4-workspace-setup scanned grade A with 0 findings 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 1mo ago.
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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 59 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Workspace Setup & Management
Use the query_workspaces and modify_workspaces tools to manage P4 client workspaces.
Querying Workspaces
| Action | Purpose | Key Parameters |
|---|---|---|
list |
List workspaces with filters | user, max_results |
get |
Get full workspace spec | workspace_name |
type |
Check if workspace is stream or classic | workspace_name |
status |
Get workspace sync status | workspace_name |
Modifying Workspaces
| Action | Purpose | Key Parameters |
|---|---|---|
create |
Create a new workspace | name, specs |
update |
Update workspace spec fields | name, specs |
delete |
Delete a workspace (requires approval) | name |
switch |
Switch active workspace | name |
Common Workflows
Create a stream workspace
query_streams→listto find available streamsmodify_workspaces→createwithspecscontaining the stream depot pathmodify_files→syncto populate the workspace
Create a classic workspace
modify_workspaces→createwithspecscontaining view mappings (depot-to-local paths)modify_files→syncto populate the workspace
Check workspace state
query_workspaces→getto see the current specquery_workspaces→typeto check if it's stream-bound or classicquery_workspaces→statusto see sync state (have vs head revisions)
Switch between workspaces
query_workspaces→listto see available workspacesmodify_workspaces→switchto set the active workspace
Best Practices
- Use stream workspaces when working with P4 streams — they auto-configure the view mapping from the stream spec.
- Set the workspace
rootto a directory that exists and is writable. - Use
query_workspaces→statusto check for out-of-date files before starting work. - Delete workspaces only when you're sure no pending changelists reference them.
- Each workspace must have a unique name on the P4 server.
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.
- 1mo ago First seen · 59 lines · 0 tokens per session scan A 5dc26bc57bf7
p4-workspace-setup is a skill published in the GitHub repository perforce/p4mcp-server (123 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 575 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
polish-docs-meta
Finalize documentation and project metadata for a ship-ready release. Use after implementation is complete, tests pass, and devcheck is clean. Safe to run at any stage — each step checks current state and only acts on what still needs work.
github-via-nyxid
Operate a user's GitHub account through NyxID's credential-brokering proxy (service slug api-github) — read and write repositories, files, issues, pull requests, commits, branches, Actions, gists and anything else the GitHub REST API exposes, all on the user's behalf and without ever handling a raw token. NyxID…
git-workflow
Follow this team's Git conventions for branching, commit messages, and pull requests.
git-workflow
Git best practices for version control and collaboration.
issue-management
Create, update, list and search GitHub issues and PRs, list a repository's labels, run milestones, and check for duplicates.
p4-plan-search-queries
P4 Plan Find query syntax for advanced searching. Use when user needs to search, filter, or find items by status, assignee, priority, severity, dates, custom fields, or any combination.