list_filaments
List filament spools with optional filters and sorting. Accounts often have hundreds of spools, so ALWAYS pair sort_by with a limit. Use sort_by=last_used + limit=10 for "most used / most popular spool" questions. Use sort_by=created + limit=N for recently added. Use sort_by=left for emptiest/fullest. Filters (material_type/brand/color) are case-insensitive substring matches. If the user names a specific spool by id or 4-character short id (e.g. "T2SO"), call get_filament instead — do NOT list and grep. Amount-remaining fields: report weight from leftGrams/totalGrams (grams) and percentLeft (%), NOT the raw total/left which are internal filament LENGTH in mm. density (g/cm³) is the value used for the gram conversion; densityIsEstimated=true means the spool has no material profile so a default density was assumed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| brand | No | Brand name substring | |
| color | No | Color substring — matches hex, name, or color group | |
| empty | No | true = only empty spools; false = only non-empty spools | |
| limit | No | Cap on number of spools returned after sorting/filtering. Use this with sort_by to grab e.g. the 3 newest. | |
| compact | No | Keep at default true. Returns minimal data tuned for AI context. Only set to false if you specifically need fields the compact view drops, and then pair with limit to keep the response small. | |
| sort_by | No | Field to sort by. Defaults to created (newest first). | |
| assigned | No | true = only spools assigned to a printer; false = only unassigned spools | |
| sort_dir | No | Sort direction. Defaults to desc. | |
| printer_id | No | Only spools assigned to this printer id | |
| material_type | No | Material type substring (e.g. "PLA", "PETG") |