sentry-miniapp: Instructions file for Codex

AGENTS.md

sentry-miniapp AGENTS.md is an instructions file for Codex, OpenCode from lizhiyao/sentry-miniapp. It costs 1,972 tokens per session, scanned A, original, MIT.

A project checklist and rulebook for contributors and coding agents working on a Sentry error-monitoring SDK for mini programs. Mini programs are small apps that run inside platforms such as WeChat or Alipay.

In plain words
What is it for?
Use it before changing the SDK, especially when adding platform-specific features, changing cross-platform code, preparing a release, or reviewing the required tests and documentation.
Why use it?
It reduces the risk of breaking support across different mini-program platforms or losing fallback behaviour. It also sets expectations for tests, documentation, branches, and commit messages.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: reads .claude/ paths; mentions CLAUDE.md; mentions Claude Code.

This is lizhiyao/sentry-miniapp's own configuration. It tells Codex and OpenCode how to work on sentry-miniapp 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 sentry-miniapp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to lizhiyao/sentry-miniapp. 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/lizhiyao/sentry-miniapp/master/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/lizhiyao/sentry-miniapp

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 sentry-miniapp AGENTS.md

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/lizhiyao/sentry-miniapp/agents-md"><img src="https://agentmods.dev/badge/instructions/lizhiyao/sentry-miniapp/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,972 This file is loaded in full into every session.
When invoked 1,972 The same file — it is already loaded in full.
Security scan A 0 findings. 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.01972 $0.01972
Opus 5.5 $0.00789 $0.00789
Sonnet 5.5 $0.00394 $0.00394
Haiku 4.5 $0.00197 $0.00197

Measured 2d ago against content hash 657a9b7be09f, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

sentry-miniapp AGENTS.md 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 2d 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.

AGENTS.md · 88 lines

How it starts

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

AGENTS.md - Agent 入场清单

sentry-miniapp 是基于 @sentry/core 的跨端小程序 Sentry SDK,覆盖微信、支付宝、字节跳动、钉钉、QQ、百度、快手,并兼容 Taro / uni-app 等跨端框架。所有功能改动都要优先保护跨端兼容性、降级路径和现有 SDK 使用方式。

本文件是 agents.md 开放标准约定的多 agent 入场清单,跨 Claude Code / Codex / Cursor / Aider / Gemini CLI 等工具通用。Claude Code 用户:本仓库的 CLAUDE.md 通过 @AGENTS.md import 同一份内容,无需重复维护。

开工先做

  • 涉及 commit、PR、分支或发版时,先看 CONTRIBUTING.md。
  • 涉及 SDK 功能或 Core 依赖改造时,先看 ARCHITECTURE.md 的职责边界和验证不变量。
  • 功能改造前确认对所有已支持平台的影响;如果使用某个平台特有 API,必须提供条件判断或回退机制。
  • 交付前默认跑 yarn run lint 和 yarn run test(Vitest 单测);涉及构建产物或跨端行为时,再跑 yarn run build。
  • 新增测试前先检查能否强化现有用例;参数组合优先参数化,跨层重复须保护不同接缝,不以用例数量作为验收指标。具体准则见 CONTRIBUTING.md 的 Testing。
  • 代码改造完成后,必须检查并更新相关文档,如 README.md、docs/README.en.md、website/ 或示例工程文档。
  • 文档改动对照当前源码、默认值和实际命令;官网改动运行 yarn run docs:build 并核对链接/锚点。用户指南讲当前行为,旧配置放迁移页,版本审查证据保留在维护记录;文档索引见 docs/README.md。

硬规则

  • 遵守 GitHub Flow:master 是唯一长期分支;feature / fix / docs / chore 从最新 master 切短分支,通过 PR 回 master。
  • 不要直接在 master 上提交;不要引入 develop 或其它长期集成分支。
  • commit 格式必须使用 Conventional Commits,并用中文 subject,例如 feat: 新增网络请求体抓取功能。推荐 scope 使用稳定模块名,如 sdk / cross-platform / integrations / transports / docs / agents-md / release。
  • 遵循现有 ESLint 规范,优先使用 TypeScript。

Sentry Core 升级收尾

  • 处理 @sentry/core 升级 PR 时,同时查找本仓库跟踪该目标版本的 open Issue,包括更新检查 Action 自动创建的 Issue。
  • 关联 Issue 的收尾属于升级任务的一部分,无需再次询问。确认 PR 已合并至默认分支、该分支已使用目标版本且必需 CI 通过后,将对应 Issue 关闭为 completed。
  • 合并前优先在 PR 描述中加入 Closes #<issue>;PR 已合并时直接关闭对应 Issue。仅关闭而未合并的 PR、失败或未完成的升级,不视为 Issue 已解决;不关闭无关或目标版本尚未安装的 Issue。
  • 最终同时报告 PR 与关联 Issue 的状态,两者均核对完成后才能宣布升级任务完成。

用户视角的文档

  • README、官网和对外介绍中的核心能力与适用场景,必须先说明用户遇到的问题、适合的项目或场景,以及接入后能获得的结果。
  • 使用用户能理解的语言。API 名称、协议字段和实现机制放在对应接入、配置或架构文档中;介绍中只保留影响用户选择或操作的技术细节。
  • 能力与收益必须对照当前实现,保留必要的启用条件、平台差异和使用限制,避免把可选采集写成默认能力,或承诺完整捕获、必定送达、自动合规等无法保证的结果。

跨端兼容性

  • 改平台能力时,同时考虑微信、支付宝、字节跳动、钉钉、QQ、百度、快手。
  • 新增平台特有 API 前,先查现有 src/crossPlatform.ts、src/types.ts 和相关 integration / transport 的抽象方式。
  • 没有同等能力的平台要有明确回退:跳过、降级、特性检测或保守默认值,避免运行期直接报错。
  • 小游戏(微信 / 抖音 / 快手小游戏)没有 App()/Page()/路由;用 crossPlatform.isMinigame() 区分并检测实际平台 API,依赖 App/Page 的能力须守卫 no-op。2.0 的小游戏生命周期默认按宿主检测启用,首帧只测 SDK 安装至首次 rAF;FPS 默认关闭,使用 enableMinigameFrameRate: true 显式启用。公共集成使用 factories,不恢复旧 class 或伪造完整冷启动测量。
  • 测试应覆盖平台差异入口;窄改动至少补对应单测,影响 SDK 初始化、transport、集成插件或事件构建时扩大验证范围。

Read the full file on GitHub · 88 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. 2d ago Changed · +7 lines · +186 tokens per session 657a9b7be09f
  2. 13d ago Changed · +3 tokens per session b329e9dfbca9
  3. 26d ago Changed · +8 lines · +247 tokens per session 244a7f79312c
  4. 27d ago Changed · +1 lines · +108 tokens per session 464dffe0cf9b
  5. 28d ago Changed · +2 lines · +52 tokens per session 19901fb3998d
  6. 1mo ago Changed · +30 tokens per session 6340e1a4a79c
  7. 1mo ago Changed · +2 tokens per session a16fcad74141
  8. 2mo ago First seen · 70 lines · 1,344 tokens per session scan A bdf858ebd895

Subscribe to this mod's changes

sentry-miniapp AGENTS.md is an instructions file published in the GitHub repository lizhiyao/sentry-miniapp (712 stars, last pushed yesterday), licensed MIT. It adds 1,972 tokens to every session, about $0.0079 per session on Opus 5.5. 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.

Related

sentry-miniapp AGENTS.md compared with instructions from other repositories

sentry-miniapp AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
sentry-miniapp AGENTS.mdlizhiyao/sentry-miniappInstructions file712yesterdayMITA1,972Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode