# Gaps in claude-code SessionStart support

**URL:** <https://forum.cursor.com/t/gaps-in-claude-code-sessionstart-support/153739>\
**Category:** Bug Reports\
**Tags:** hooks\
**Created:** [March 5, 2026, 5:44pm UTC](https://forum.cursor.com/t/gaps-in-claude-code-sessionstart-support/153739 "2026-03-05T17:44:27Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![James\_Koch](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/james_koch/32/100532_2.png) [@James\_Koch](https://forum.cursor.com/u/James_Koch)\
**Post date:** [March 5, 2026, 5:44pm UTC](https://forum.cursor.com/t/gaps-in-claude-code-sessionstart-support/153739/1 "2026-03-05T17:44:27Z")

</div>

### Where does the bug appear (feature/product)?

Cursor IDE

### Describe the Bug

I found two notable differences here:

1. claude-code supports non-JSON stdout for its SessionStart hooks. Output is added directly to context. Cursor rejects non-JSON stdout with `JSON Parse Error: SyntaxError: ...`
2. claude-code supports SessionStart adding to context using JSON stdout with field `additionalContext`. Cursor ignores a field of that name, but honors one named `additional_context`

### Steps to Reproduce

.

### Expected Behavior

Overall I was able to work-around this by (1) converting output to JSON and (2) double-outputting the context in both `additionalContext` and `additional_context`.

### Operating System

Windows 10/11

### Version Information

Version: 2.6.11 (user setup)  
VSCode Version: 1.105.1  
Commit: 8c95649f251a168cc4bb34c89531fae7db4bd990  
Date: 2026-03-03T18:57:48.001Z  
Build Type: Stable  
Release Track: Default  
Electron: 39.6.0  
Chromium: 142.0.7444.265  
Node.js: 22.22.0  
V8: 14.2.231.22-electron.0

### Does this stop you from using Cursor

No - Cursor works, but with this issue

---

<div class="post-metadata">

**Author:** ![mohitjain](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/mohitjain/32/100229_2.png) [@mohitjain](https://forum.cursor.com/u/mohitjain)\
**Post date:** [March 13, 2026, 9:24am UTC](https://forum.cursor.com/t/gaps-in-claude-code-sessionstart-support/153739/4 "2026-03-13T09:24:47Z")

</div>

Hey James,

Thanks for the detailed write-up. Both observations are accurate.

Non-JSON stdout: Cursor requires hook output to be valid JSON. Plain text stdout from a `sessionStart` hook will be rejected with a parse error. Your workaround of wrapping the output in JSON is the right approach.

`additionalContext` vs `additional_context`: Cursor uses the `additional_context` (snake\_case) field name for `SessionStart` hook responses. The camelCase `additionalContext` that `claude-code` uses isn’t currently recognized. Your double-output workaround is a nice way to support both tools.

Both of these are compatibility gaps between Cursor’s hook implementation and `claude-code`’s. I’ve flagged them for the team.

Appreciate the report — it really helps us prioritize closing these gaps.

Best,  
Mohit

---

<div class="post-metadata">

**Author:** ![system](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/system/32/99069_2.png) [@system](https://forum.cursor.com/u/system)\
**Post date:** [April 4, 2026, 9:25am UTC](https://forum.cursor.com/t/gaps-in-claude-code-sessionstart-support/153739/6 "2026-04-04T09:25:51Z")

</div>

Closed on April 4, 2026, 9:25am UTC

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/colin/32/90452_2.png) [@Colin](https://forum.cursor.com/u/Colin)\
**Post date:** [June 4, 2026, 10:53am UTC](https://forum.cursor.com/t/gaps-in-claude-code-sessionstart-support/153739/8 "2026-06-04T10:53:13Z")

</div>

Hey @James_Koch!

This bit:

> [@James\_Koch](#):
>
> claude-code supports SessionStart adding to context using JSON stdout with field `additionalContext`. Cursor ignores a field of that name, but honors one named `additional_context`

Should be improved in Cursor _v3.7_, which is around the corner.
