access: Instructions file for Codex

AGENTS.md

access AGENTS.md is an instructions file for Codex, OpenCode from Scottpedia0/access. It costs 1,144 tokens per session, scanned A, original, MIT.

A set of project instructions for coding agents working on Access, a self-hosted credential store and API proxy. It explains the codebase structure, security approach, and recurring coding patterns.

In plain words
What is it for?
Use it when developing or reviewing Access code, especially API routes, upstream service clients, authentication, security, audit logging, database models, or its MCP server.
Why use it?
It gives agents the project context they need before changing code, reducing guesses about where logic belongs and how authentication, encryption, and auditing work.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions CLAUDE.md.

This is Scottpedia0/access's own configuration. It tells Codex and OpenCode how to work on access itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything access configures →

Reuse

Borrowing it

Nothing to install: this file belongs to Scottpedia0/access. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/Scottpedia0/access/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/Scottpedia0/access

Made for: Codex, OpenCode.

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 access AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/scottpedia0/access/agents-md/github.svg)](https://agentmods.dev/instructions/scottpedia0/access/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/scottpedia0/access/agents-md"><img src="https://agentmods.dev/badge/instructions/scottpedia0/access/agents-md/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.

agentmods 80×15 button for access AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/scottpedia0/access/agents-md"><img src="https://agentmods.dev/badge/instructions/scottpedia0/access/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,144 This file is loaded in full into every session.
When invoked 1,144 The same file — it is already loaded in full.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.01144 $0.01144
Opus 5.5 $0.00458 $0.00458
Sonnet 5.5 $0.00229 $0.00229
Haiku 4.5 $0.00114 $0.00114

Measured 1mo ago against content hash fd394c8ef163, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

access AGENTS.md 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 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.

Makes network callslowCapability

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

curl -H "Authorization: Bearer $GLOBAL_AGENT_TOKEN" \
AGENTS.md · 115 lines

How it starts

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

Access — Agent Instructions

For agents developing on this codebase

What this is

Access is a self-hosted credential store + API proxy + MCP server for agents and scripts. Next.js App Router + Prisma + PostgreSQL.

Architecture

  • src/app/api/v1/<service>/route.ts — proxy route handlers (Zod validation, auth, proxy upstream)
  • src/lib/<service>/client.ts — upstream API client functions
  • src/lib/access.ts — request authentication (global token, consumer token, session)
  • src/lib/security/encryption.ts — AES-256-GCM encrypt/decrypt with key rotation support
  • src/lib/security/tokens.ts — HMAC-SHA256 consumer token generation and verification
  • src/lib/env.ts — environment variable helpers and encryption key loading
  • src/lib/audit.ts — audit event logging
  • src/middleware.ts — rate limiting and body size enforcement
  • prisma/schema.prisma — data model (Service, Secret, Consumer, AccessGrant, AuditEvent, etc.)
  • mcp-server.mjs — standalone MCP server exposing Google Workspace tools
  • scripts/rotate-keys.ts — encryption key rotation script

Key patterns

  • Every route uses isValidGlobalAgentToken() or authenticateRequestActor() for auth
  • Every route has Zod schemas for input validation
  • Every route catches errors with process.env.NODE_ENV === "development" gating on details
  • export const runtime = "nodejs" on all POST route handlers
  • Google services use authenticateGoogleRequest() which handles multi-account resolution

Adding a new service adapter

  1. Create src/lib/<service>/client.ts with API functions
  2. Create src/app/api/v1/<service>/route.ts following the hubspot pattern
  3. Add env vars to .env.example
  4. Update the Supported Services section in README.md

Data model

  • Service — a registered service (name, slug, description, visibility mode)
  • Secret — encrypted credential belonging to a service (envVarName, encryptedValue)
  • Consumer — an agent identity (name, slug, hashed token)
  • AccessGrant — links a consumer to a service or specific secret
  • AuditEvent — log of every access, reveal, copy, login, and API call
  • GoogleToken — OAuth tokens for Google multi-account broker

Read the full file on GitHub · 115 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. 1mo ago First seen · 115 lines · 1,144 tokens per session scan A fd394c8ef163

Subscribe to this mod's changes

access AGENTS.md is an instructions file published in the GitHub repository Scottpedia0/access (0 stars, last pushed 6mo ago), licensed MIT. It adds 1,144 tokens to every session, about $0.0046 per session on Opus 5.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-08-31.

Related

Other instructions, from other repositories