Commit bf934d5
authored
bugfix(mcp) correctly slice claude url hash (tldraw#8186)
Bring the url of the domain anthropic will be hosting its widget on in
line with the
[docs](https://claude.com/docs/connectors/building/mcp-apps/cross-compatibility#domain-handling)
### Change type
- [ ] `bugfix`
- [ ] `improvement`
- [ ] `feature`
- [ ] `api`
- [x] `other`
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> **Low Risk**
> Small, isolated change to Claude widget domain computation; main risk
is miscomputing the domain and breaking widget loading in Claude.
>
> **Overview**
> Fixes Claude widget domain generation to match Anthropic’s docs by
truncating the SHA-256 hex digest to the first 32 characters before
appending `.claudemcpcontent.com`.
>
> Also updates the inline documentation/example command in
`getWidgetDomain` and slightly refactors the hash string construction
for readability.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
9638410. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->1 parent fe0a82f commit bf934d5
1 file changed
Lines changed: 8 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
| 68 | + | |
69 | 69 | | |
70 | | - | |
| 70 | + | |
71 | 71 | | |
72 | 72 | | |
73 | | - | |
74 | | - | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
75 | 76 | | |
76 | 77 | | |
77 | 78 | | |
| |||
83 | 84 | | |
84 | 85 | | |
85 | 86 | | |
86 | | - | |
87 | | - | |
88 | | - | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
89 | 90 | | |
90 | 91 | | |
91 | 92 | | |
| |||
0 commit comments