# `dump_actions` Dump action info ## Usage > pdftl `` `dump_actions` `[...]` `[output` `]` ## Details The `dump_actions` operation extracts interactive actions and trigger events from a PDF file and outputs them in JSON format. This includes actions associated with: - Document events (e.g., scripts that run when opening, saving, or printing) - Document-level JavaScript libraries - Page events (e.g., actions triggered when opening or closing a page) - Annotations (e.g., links, hover events, focus events) - Bookmarks (e.g., actions triggered when clicking a bookmark node) - Interactive form fields (e.g., keystroke, formatting, validation, or calculation scripts) - Chained action sequences (subsequent actions triggered in a chain) ### Filtering Actions can be filtered using the same selector syntax as [`dump_annots`]() and [`modify_annots`](). The syntax is `selector` or `selector(Key=Value, ...)`, where: - `selector` is a page range (e.g., `1-5`, `odd`, see [[[`page_specs`](<../general/page_specs.md>)]]) and/or an action type (e.g., `/JavaScript`, `/GoTo`, `/URI`, `/Launch`). - `Key=Value` pairs filter actions by property values (e.g. matching a script body). Page-specific selectors (like `1/JavaScript`) only return actions associated with that page. Document-level and bookmark actions are excluded when page range filters are used. ## Examples > Show all action data for a file ``` pdftl in.pdf dump_actions ``` > Show only JavaScript actions ``` pdftl in.pdf dump_actions /JavaScript ``` > Show JavaScript actions located on Page 1 ``` pdftl in.pdf dump_actions "1/JavaScript" ``` > Show JavaScript actions matching an exact script ``` pdftl in.pdf dump_actions "/JavaScript(JS=(console.log('wc');))" ``` **Tags**: in_place, actions, info *Source: pdftl.operations.dump_actions* *Read online: [https://pdftl.readthedocs.io/en/latest/operations/dump_actions.html](https://pdftl.readthedocs.io/en/latest/operations/dump_actions.html)* *Type: Operation*