Get icon SVG
get_icon_svgGet an icon as SVG by its ID - PREFERRED FORMAT for Icons8 icons. SVG format provides scalable, crisp icons suitable for web applications. Personal API key is required for SVG access.
RECOMMENDED: Use this tool instead of PNG when possible for better quality and scalability.
An animated icon's SVG is a still frame - Icons8 publishes no animated vector. The result then carries a "note" saying so and an "animation" block with the motion, so no further call is needed.
Args: icon_id: The id from a search_icons result (field icons[].id) ctx: MCP context for API access
Returns: Dictionary containing the SVG content. For an animated icon it also carries a "note" saying the SVG is a still frame and an "animation" block of permanent gif and apng links. On failure, an "error" describing what the Icons8 API said - a rejected key is reported, not returned as an empty icon. Counts toward the paid-download limit: a refusal carries "retry_after_seconds" and a free PNG "url"
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| icon_id | Yes | Icon id from the results of search_icons (field icons[].id) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| svg | No | SVG markup of the icon. Absent when error is set. | |
| url | No | Free 24px PNG link. Set only when the download limit refused the call. | |
| note | No | Set only for an animated icon: the SVG is a still frame. | |
| error | No | Set only on failure. | |
| animation | No | Permanent gif and apng links. Set for an animated icon, and when the download limit refused the call. | |
| retry_after_seconds | No | Seconds until the download limit resets. Set only when the limit refused the call. |