> ## Documentation Index
> Fetch the complete documentation index at: https://docs.superdoc.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# bookmarks.remove

> Remove a bookmark from the document.

## Summary

Remove a bookmark from the document.

* Operation ID: `bookmarks.remove`
* API member path: `editor.doc.bookmarks.remove(...)`
* Mutates document: `yes`
* Idempotency: `non-idempotent`
* Supports tracked mode: `no`
* Supports dry run: `yes`
* Deterministic target resolution: `yes`

## Expected result

Returns a BookmarkMutationResult indicating success or a failure.

## Input fields

| Field | Type | Required | Description |
| - | - | - | - |
| `target` | object(kind="entity") | yes | |
| `target.entityType` | `"bookmark"` | yes | Constant: `"bookmark"` |
| `target.kind` | `"entity"` | yes | Constant: `"entity"` |
| `target.name` | string | yes | |
| `target.story` | StoryLocator | no | StoryLocator |

### Example request

```json theme={null}
{
  "target": {
    "entityType": "bookmark",
    "kind": "entity",
    "name": "example",
    "story": {
      "kind": "story",
      "storyType": "body"
    }
  }
}
```

## Output fields

### Variant 1 (success=true)

| Field | Type | Required | Description |
| - | - | - | - |
| `bookmark` | object(kind="entity") | yes | |
| `bookmark.entityType` | `"bookmark"` | yes | Constant: `"bookmark"` |
| `bookmark.kind` | `"entity"` | yes | Constant: `"entity"` |
| `bookmark.name` | string | yes | |
| `bookmark.story` | StoryLocator | no | StoryLocator |
| `success` | `true` | yes | Constant: `true` |

### Variant 2 (success=false)

| Field | Type | Required | Description |
| - | - | - | - |
| `failure` | object | yes | |
| `failure.code` | string | yes | |
| `failure.details` | any | no | |
| `failure.message` | string | yes | |
| `success` | `false` | yes | Constant: `false` |

### Example response

```json theme={null}
{
  "bookmark": {
    "entityType": "bookmark",
    "kind": "entity",
    "name": "example",
    "story": {
      "kind": "story",
      "storyType": "body"
    }
  },
  "success": true
}
```

## Pre-apply throws

* `TARGET_NOT_FOUND`
* `INVALID_TARGET`
* `CAPABILITY_UNAVAILABLE`

## Non-applied failure codes

* None

## Raw schemas

> [accordion] Raw input schema
>
> ```json theme={null}
> {
>   "additionalProperties": false,
>   "properties": {
>     "target": {
>       "additionalProperties": false,
>       "properties": {
>         "entityType": {
>           "const": "bookmark"
>         },
>         "kind": {
>           "const": "entity"
>         },
>         "name": {
>           "type": "string"
>         },
>         "story": {
>           "$ref": "#/$defs/StoryLocator"
>         }
>       },
>       "required": [
>         "kind",
>         "entityType",
>         "name"
>       ],
>       "type": "object"
>     }
>   },
>   "required": [
>     "target"
>   ],
>   "type": "object"
> }
> ```

> [accordion] Raw output schema
>
> ```json theme={null}
> {
>   "oneOf": [
>     {
>       "additionalProperties": false,
>       "properties": {
>         "bookmark": {
>           "additionalProperties": false,
>           "properties": {
>             "entityType": {
>               "const": "bookmark"
>             },
>             "kind": {
>               "const": "entity"
>             },
>             "name": {
>               "type": "string"
>             },
>             "story": {
>               "$ref": "#/$defs/StoryLocator"
>             }
>           },
>           "required": [
>             "kind",
>             "entityType",
>             "name"
>           ],
>           "type": "object"
>         },
>         "success": {
>           "const": true
>         }
>       },
>       "required": [
>         "success",
>         "bookmark"
>       ],
>       "type": "object"
>     },
>     {
>       "additionalProperties": false,
>       "properties": {
>         "failure": {
>           "additionalProperties": false,
>           "properties": {
>             "code": {
>               "type": "string"
>             },
>             "details": {},
>             "message": {
>               "type": "string"
>             }
>           },
>           "required": [
>             "code",
>             "message"
>           ],
>           "type": "object"
>         },
>         "success": {
>           "const": false
>         }
>       },
>       "required": [
>         "success",
>         "failure"
>       ],
>       "type": "object"
>     }
>   ]
> }
> ```

> [accordion] Raw success schema
>
> ```json theme={null}
> {
>   "additionalProperties": false,
>   "properties": {
>     "bookmark": {
>       "additionalProperties": false,
>       "properties": {
>         "entityType": {
>           "const": "bookmark"
>         },
>         "kind": {
>           "const": "entity"
>         },
>         "name": {
>           "type": "string"
>         },
>         "story": {
>           "$ref": "#/$defs/StoryLocator"
>         }
>       },
>       "required": [
>         "kind",
>         "entityType",
>         "name"
>       ],
>       "type": "object"
>     },
>     "success": {
>       "const": true
>     }
>   },
>   "required": [
>     "success",
>     "bookmark"
>   ],
>   "type": "object"
> }
> ```

> [accordion] Raw failure schema
>
> ```json theme={null}
> {
>   "additionalProperties": false,
>   "properties": {
>     "failure": {
>       "additionalProperties": false,
>       "properties": {
>         "code": {
>           "type": "string"
>         },
>         "details": {},
>         "message": {
>           "type": "string"
>         }
>       },
>       "required": [
>         "code",
>         "message"
>       ],
>       "type": "object"
>     },
>     "success": {
>       "const": false
>     }
>   },
>   "required": [
>     "success",
>     "failure"
>   ],
>   "type": "object"
> }
> ```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.