integrate-arcjet-guard-cloudflare-think

integrate-arcjet-guard-cloudflare-think is a skill for Claude Code, Codex from arcjet/arcjet-js. It costs 106 tokens per session (3,078 once invoked), scanned A, original, Apache-2.0.

An integration guide for adding Arcjet security checks to tools used by a Cloudflare Think agent. Arcjet decides whether a tool call is allowed, denied, or replaced with a response.

In plain words
What is it for?
It helps attach a before-tool-call check, apply rate limits or other Arcjet decisions, and carry a caller-provided session ID through the integration.
Why use it?
It defines where checks run and how denied or unavailable checks behave, reducing the risk of tools running without the intended protection.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It helps attach a before-tool-call check, apply rate limits or other Arcjet decisions, and carry a caller-provided session ID through the integration.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think
Install

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.

Any agent
npx skills add arcjet/arcjet-js --skill integrate-arcjet-guard-cloudflare-think
Clone the repo
git clone --depth 1 https://github.com/arcjet/arcjet-js

Made for: Claude Code, Codex.

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 integrate-arcjet-guard-cloudflare-think

README.md
[![agentmods](https://agentmods.dev/badge/skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think/github.svg)](https://agentmods.dev/skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think)
Your own site
<a href="https://agentmods.dev/skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think"><img src="https://agentmods.dev/badge/skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think/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 integrate-arcjet-guard-cloudflare-think

Your own site · 80×15
<a href="https://agentmods.dev/skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think"><img src="https://agentmods.dev/badge/skills/arcjet/arcjet-js/integrate-arcjet-guard-cloudflare-think.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 106 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,078 The whole file, excluding the scripts and references it only reads on demand.
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.00106 $0.03078
Opus 5.5 $0.00042 $0.01231
Sonnet 5.5 $0.00021 $0.00616
Haiku 4.5 $0.00011 $0.00308

Measured yesterday against content hash 95d72e3d81aa, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

integrate-arcjet-guard-cloudflare-think 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 yesterday.

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.

arcjet-guard/skills/integrate-arcjet-guard-cloudflare-think/SKILL.md · 267 lines

How it starts

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

Integrate Arcjet Guard into Cloudflare Think

@arcjet/guard's Cloudflare Think v0 namespace wraps the agent's existing Arcjet client. It never talks to the Arcjet API itself. Two surfaces, one decision rule:

  • Tool calls → guardHooks(). A { beforeToolCall } object assigned on a Think subclass. Default DENY is { action: "substitute", output: ArcjetDenialResult } so the tool never runs and the model sees the payload. Optional onDeny: "block" returns { action: "block", reason } and skips the tool — the model does not get ArcjetDenialResult. Do not throw from the hook. Fail-closed unavailable stays substitute even when onDeny is "block".
  • Correlation → cloudflareThinkContext() reads a caller-owned id from helper options (guardHooks({ sessionId })) or a wrap (cloudflareThinkContext({ context: appContext })). It never mints a new id. It never reads toolCallId (Think always generates it). It never reads requestId / traceId / Durable Object name / id.

There is no guardTool. There is no guardInbound, no guardApproval, and no afterToolCall capture hook.

This namespace is Cloudflare Think Think + class beforeToolCall. Not the Vercel AI SDK. Do not also wrap with @arcjet/guard/vercel-ai/v7 or @arcjet/guard/claude-managed-agents/v0. Client tools with no local execute are out of scope.

Docs live at docs.arcjet.com/guards/cloudflare-think/. Do not overwrite any other /guards/... slug.

The floor is @cloudflare/[email protected] because that is the first release whose beforeToolCall returns a functional ToolCallDecision (allow / block / substitute) and wraps every server-side tool's execute so the hook runs first.

Screen inbound before the Think turn — there is no inbound hook.

There is no first-class inbound deny channel, so there is no guardInbound. Put prompt-injection (and other inbound rules) in the application before the turn. Call guard() directly. guard() fails open — callers must check hasFailedOpen().

Read the full file on GitHub · 267 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. yesterday Changed · -4 lines 95d72e3d81aa
  2. 9d ago Changed · +1 lines 9137adaffad0
  3. 10d ago Changed · +5 lines 14d85846b4d0
  4. 14d ago Changed · +3 lines c51b7892b59f
  5. 24d ago First seen · 262 lines · 106 tokens per session scan A 2f661716f6fc

Subscribe to this mod's changes

integrate-arcjet-guard-cloudflare-think is a skill published in the GitHub repository arcjet/arcjet-js (692 stars, last pushed today), licensed Apache-2.0. It adds 106 tokens to every session and 3,078 once invoked, about $0.0004 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-09-22.

Related

Other skills, from other repositories

create-auth-skill

Scaffold and implement authentication in TypeScript/JavaScript apps using Better Auth. Detect frameworks, configure database adapters, set up route handlers, add OAuth providers, and create auth UI pages. Use when users want to add login, sign-up, or authentication to a new or existing project with Better Auth.

Agent-Threat-Rule/agent-threat-rules · 66 tokens

fhir-developer-skill

FHIR API development guide for building healthcare endpoints. Use when: (1) Creating FHIR REST endpoints (Patient, Observation, Encounter, Condition, MedicationRequest), (2) Validating FHIR resources and returning proper HTTP status codes and error responses, (3) Implementing SMART on FHIR authorization and OAuth…

Agent-Threat-Rule/agent-threat-rules · 132 tokens

create-auth-skill

Scaffold and implement authentication in TypeScript/JavaScript apps using Better Auth. Detect frameworks, configure database adapters, set up route handlers, add OAuth providers, and create auth UI pages. Use when users want to add login, sign-up, or authentication to a new or existing project with Better Auth.

Agent-Threat-Rule/agent-threat-rules · 66 tokens

hunt-api-misconfig

Hunt API security misconfiguration — mass assignment, prototype pollution, HTTP verb tampering. Mass assignment: send {isadmin:true, role:admin, verified:true} on profile/account/reset endpoints — server blindly applies. JWT signature/crypto forging (alg:none, key confusion, kid/jku) is owned by hunt-jwt-crypto; this…

elementalsouls/Claude-BugHunter · 207 tokens

clinical-trial-protocol-skill

Generate clinical trial protocols for medical devices or drugs. This skill should be used when users say "Create a clinical trial protocol", "Generate protocol for [device/drug]", "Help me design a clinical study", "Research similar trials for [intervention]", or when developing FDA submission documentation for…

Agent-Threat-Rule/agent-threat-rules · 70 tokens

claude-d3js-skill

This skill provides guidance for creating sophisticated, interactive data visualisations using d3.js.

Agent-Threat-Rule/agent-threat-rules · 25 tokens