Skip to content

Instantly share code, notes, and snippets.

@supersational
Last active February 2, 2025 02:07
Show Gist options
  • Save supersational/a492cf3b6181e04e136725e1b18bf969 to your computer and use it in GitHub Desktop.
Save supersational/a492cf3b6181e04e136725e1b18bf969 to your computer and use it in GitHub Desktop.
Claude Autoclick "Allow Tool"
while true; do
osascript -e '
tell application "System Events"
if exists process "Claude" then
tell process "Claude"
if exists button "Allow for This Chat" of group 2 of group 1 of group 2 of group 1 of UI element "Claude" of group 1 of group 1 of group 1 of group 1 of window "Claude" then
click button "Allow for This Chat" of group 2 of group 1 of group 2 of group 1 of UI element "Claude" of group 1 of group 1 of group 1 of group 1 of window "Claude"
log "clicked allow button"
end if
end tell
end if
end tell
'
sleep 1
done
@PWereh
Copy link

PWereh commented Nov 29, 2024

Any guide on how to implement this in current Claude Desktop for x64

@brewmecoffee
Copy link

not working :/

@supersational
Copy link
Author

Fixed

@Lopofsky
Copy link

execution error: System Events got an error: osascript is not allowed assistive access.

@supersational
Copy link
Author

you need to allow it in system settings: Privacy & Security -> Accessibility -> Toggle on for Terminal (or whatever you're running it from - not needed to toggle on for Claude)

@thomassauve26
Copy link

Hello can someone explain how to use it on mac silicon? it doesnt work even with claude's help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment