Like or unlike a gist
set_gist_likeSets whether a gist is liked, toggling only when the current state differs. Prevents duplicate actions, so calling twice with the same value leaves the gist unchanged.
Instructions
Like or unlike a gist. Idempotent: the current state is read first and the gist is only toggled when it differs, so calling this twice with the same value does not undo it. Requires the user:write scope on the access token.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"gistId": "<gistId>",
"liked": "<liked>"
},
"name": "set_gist_like"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| liked | Yes | true to like the gist, false to remove the like | |
| gistId | Yes | ID of the gist — the "id" field returned by list_gists/search_gists, not its title |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| note | No | ||
| liked | Yes | ||
| gistId | Yes | ||
| changed | Yes | False when it was already in that state. |