Skip to main content
Connect your AI

Claude Inference hooks

Claude Enterprise can ask StackJack about each request before Claude acts on it. StackJack checks the prompt, the attached files and the tool results against your data-loss rules and your approved…

Written By Christopher Scaminaci

Last updated 4 days ago

Claude Enterprise can ask StackJack about each request before Claude acts on it. StackJack checks the prompt, the attached files and the tool results against your data-loss rules and your approved tool list, and answers allow or stop. This page covers how to set that up, what a person sees when a request is stopped, and what StackJack cannot do on this path.

At a glance

  • What it does: lets StackJack allow or stop each Claude Enterprise request before Claude acts.
  • Plan: Business and above.
  • Who: a Claude Owner makes the change in Claude. A StackJack Administrator sets it up. An Auditor reads the status.
  • Where you set it up: AI Governance → Staff computers → Claude hooks.
  • Where you see the data: Activity → Activity explorer and Activity → Findings.

The setup lives on the Claude hooks page (AI Governance → Staff computers → Claude hooks). You need the Admin role in AI Governance to change anything there. An auditor can read the status and nothing else.

What hooks do

StackJack checks each prompt, each attached file and each tool result before Claude answers, and can allow the request or stop it. With Validate tool calls on in Claude, StackJack also checks which tool servers Claude is about to call, and reads the arguments of each call.

Hooks cover every Claude product your organization uses with Claude Enterprise: claude.ai, Cowork, Claude Code, Claude for Microsoft 365, Claude Tag and Claude in Chrome, on the web, desktop, mobile and the command line.

Hooks do not cover Claude Platform organizations that only use the API, Amazon Bedrock, Google Cloud, Claude Security scans, Code Review or smart reports. Voice mode is covered only in part. Requests from API keys and from Claude Tag conversations in Slack are skipped when Claude inspects only selected roles.

Who can set it up

Only a Claude Owner or Primary owner can open the Inference hooks settings in Claude, and only Claude Enterprise organizations have them. StackJack cannot push these settings into Claude for you. The Claude hooks tab walks you through the Claude screen step by step, with the labels Claude uses.

Plans

Hooks need the Business plan or higher. Below that, StackJack allows every request from Claude without inspection, whatever you set up in Claude, and the page tells you so. Claude never stops working because of a StackJack plan or switch.

Set it up

  1. In Claude, open the Inference hooks settings in your organization's admin settings. Only a Claude Owner or Primary owner can open them, and only Claude Enterprise organizations have them.
  2. Paste the address from the Claude hooks tab into the endpoint URL field. Wait two minutes after you turned this on before you save in Claude.
  3. Set the mode to Shadow mode while you test: nothing is blocked. Later choose Allow the request (if StackJack is slow or unreachable, Claude lets the request through) or Block the request (Claude stops requests StackJack cannot answer).
  4. Leave Prompt verdict timeout (ms) at 5000.
  5. Turn on Validate tool calls if you want StackJack to check which tool servers Claude calls.
  6. Save. Claude shows the signing secret one time. Copy it.
  7. Paste it into the box on the Claude hooks tab and select Save secret. Wait two minutes.
  8. Back in Claude, run the connection test. Then check the Claude hooks tab: it shows Verified with the time of the newest verified request. If it does not, check the address and the secret.
  9. When it shows Verified, switch the mode from Shadow mode to your choice and set Requests inspected (%) to 100, then turn on Enforce verdicts.

Start in Shadow mode, then move to Allow the request. Choose Block the request only after the tab shows Verified and a week of clean shadow data.

Do not restrict the address by IP address. The signature is the control: StackJack checks that every request is signed with your secret, and refuses any that is not.

What a person sees when a request is stopped

The person sees a short message that names the data-loss rule that stopped the request, never the text that matched it. Claude adds your own "Custom blocked prompt message" below it. For a tool server that is not on your approved list, the message names the server.

Warn and justify

A rule can ask for a reason instead of stopping the request outright. The message then holds a link. The person opens the link, gives a reason of 10 to 500 characters, and retries in about a minute. The exception lasts 15 minutes for that rule and that person.

What StackJack cannot do

  • StackJack can only allow or stop a request. It cannot rewrite or redact it. A rule that asks to mask the matched text therefore acts as a block or as an allow, as you set in the AI gateway lane settings (the default is a block).
  • StackJack reads prompts, attached files and tool results and, with Validate tool calls on, tool calls. A tool result is seen one turn late, so it can stop the next request, not the tool that already ran.
  • Claude's answers are not sent to hooks. Use the Claude Compliance source to cover chats.

Rotating the secret

Rotating the secret in Claude takes effect at once for Claude, but StackJack needs the new secret within about two minutes. Paste the new secret right after you rotate it. Requests signed in between are refused, and Claude applies your mode (Allow the request or Block the request). StackJack keeps accepting the old secret for 10 minutes after you save a new one.

If something is wrong

What you seeWhat to do
The tab does not show Verified after the connection testWait two minutes, then check the secret and check that the address is the one for your region. A mistyped address still passes Claude's connection test and never shows Verified on the tab.
Claude shows a 401 (refused) from the endpointThe secret in StackJack does not match the secret in Claude. Paste the current secret again.
Requests slow downClaude waits for StackJack on every request. If StackJack is unreachable, Claude applies your mode, so AI work continues when the mode is Allow the request.
The tab says the plan is requiredHooks need the Business plan or higher. Until then StackJack allows every request without inspection.

Privacy

What StackJack stores depends on the capture level of the Claude hooks source, which you set on the All sources page: facts only, scan and discard, masked text, or full text. At any level that stores text, StackJack stores the newest turn of the conversation only, never the whole history Claude sends. People you excluded from content capture are never stored. Only the roles you gave in AI Governance can read stored text, and every read is recorded.

Turning it off

  1. Switch off Inspect requests in the Status panel of the Claude hooks page. StackJack then allows every request from Claude without inspection.
  2. To remove the address, first switch the hook in Claude to Shadow mode (or turn it off). Then use Remove this address at the foot of the page and type the confirmation phrase. Both signing secrets are deleted.

More from Claude

Claude's own documentation describes the settings and the request format: Inference hooks configuration and Inference hooks endpoint.