maple-nextjs-style
Skill by MapleTechLabs
Guides developers on adding Maple OpenTelemetry tracing, metrics and logs to Next.js and Vercel apps. It covers the instrumentation.ts bootstrap, Anthropic instrumentation and browser setup with @maple-dev/browser.
Install maple-nextjs-style
Built from the published package, never by AI.
git clone --depth 1 https://github.com/MapleTechLabs/maple /tmp/maple && mkdir -p ~/.claude/skills && cp -r /tmp/maple/skills/maple-nextjs-style ~/.claude/skills/maple-nextjs-styleRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/MapleTechLabs/maple /tmp/maple && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/maple/skills/maple-nextjs-style ~/.gemini/antigravity-cli/skills/maple-nextjs-styleAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
This skill is a style guide for adding Maple observability to Next.js and Vercel apps. It sets up OpenTelemetry through instrumentation.ts and @vercel/otel, with the Maple endpoint and public ingest key passed inline to registerOTel. It also covers Anthropic instrumentation with OpenInference, native @opentelemetry/api spans, metrics and logs in route handlers, and browser tracing with @maple-dev/browser.
The guidance tells the assistant to keep the default bootstrap instead of a custom NodeSDK setup, and to avoid wrapping LLM provider calls that instrumentation already covers. It explains which @vercel/otel logs option to use for each major version and how to give server and browser services separate names. It is aimed at developers building Next.js apps who want to send traces, metrics and logs to Maple.
Written from the project's SKILL.md and checked against it.
What it can do
- instrumentation.ts bootstrapRegisters @vercel/otel from instrumentation.ts with an explicit Maple endpoint and ingest key.
- Anthropic instrumentationAdds OpenInference Anthropic instrumentation in the same bootstrap while keeping call sites native.
- Route handler spansWraps key business operations in tracer.startActiveSpan with error recording and span ending.
- Custom metricsShows how to create counters with the OpenTelemetry metrics API in route handlers.
- Structured OTLP logsEmits log records with @opentelemetry/api-logs instead of console calls.
- Browser tracingInitializes @maple-dev/browser from a client component rendered in the root layout.
- Browser and server trace joiningNotes that same-origin fetch calls carry traceparent so browser and server spans join one trace.
What you need
- A Next.js app using instrumentation.ts
- Vercel OpenTelemetry (@vercel/otel)
- A Maple public ingest key (maple_pk_…), or the MAPLE_TEST placeholder
- npm scripts for typecheck and build
Try asking
- Set up Maple tracing in my Next.js app using instrumentation.ts
- Add Anthropic tracing with OpenInference to my Next.js route handlers
- Wrap my reply generation route in an OpenTelemetry span with error handling
Good to know
- Do not rely on OTEL_EXPORTER_OTLP_* environment variables; the config is inline.
- Use only the public ingest key (maple_pk_…), never maple_sk_.
- The logs option differs by @vercel/otel version: logRecordProcessor for 1.x, logRecordProcessors for 2.x.
- Maple does not price tokens, according to the source.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: skills/maple-nextjs-style/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to maple-nextjs-style
All alternatives →Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.
Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.
Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.
Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.
Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.
Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.
Compare with openclaw-github-repo-commander, gradio or hig-components-menus
maple-nextjs-style: common questions
Does this require a custom NodeSDK setup?
No. The source says not to replace the @vercel/otel bootstrap with a custom NodeSDK setup unless the repo is not a standard Next or Vercel app or already has a custom provider.
Which Maple key should the browser client use?
Only the public key (maple_pk_…). The source says the browser client must never use maple_sk_.
Should I add extra spans around LLM provider calls?
Not when OpenInference or provider instrumentation supports the SDK. The source says to leave the call in place and add business context to the active span or structured log.
How do I install maple-nextjs-style?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is maple-nextjs-style free?
The code is published under the NOASSERTION licence. The service it connects to may have its own pricing.
Is maple-nextjs-style safe to use?
It scores 71 of 100. Grades: maintenance A, licence F, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to maple-nextjs-style?
Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.
