# /systems/export - Export systems to CSV or PDF **GET /systems/export** Export systems with applied filters to CSV or PDF format. **Features:** - Supports all filter parameters from GET /systems - Maximum 10,000 systems per export (DoS protection) - CSV format: Simple spreadsheet with all fields - PDF format: Formatted report with metadata and filters applied - File naming: `systems_export_YYYY-MM-DD_HHmmss.[csv|pdf]` **Permissions**: Requires `read:systems` permission and respects RBAC hierarchy **Export Fields:** - Name, Type, Version, Status - FQDN, IPv4 Address, IPv6 Address - System Key, Notes - Created At - Organization Name, Organization Type - Created By Name, Created By Email, Created By Organization ## Servers - Backend API server (port 8080): https://api.your-domain.com/api (Backend API server (port 8080)) - Collect API server (port 8081): https://collect.your-domain.com/api (Collect API server (port 8081)) ## Authentication methods - Bearer auth ## Parameters ### Query parameters - **format** (string) Export format (csv or pdf) - **search** (string) Search term - **sort_by** (string) Field to sort systems by - **sort_direction** (string) Sort direction - **name** (string) Filter systems by name (case-insensitive, partial match) - **system_key** (string) Filter systems by system key (exact match). Useful for exporting a single system. - **type** (array[string]) Filter systems by type/product (exact match). Supports multiple values for checkbox filtering. - **created_by** (array[string]) Filter systems by creator user ID or creator organization ID (exact match). Each provided ID is checked against both the user_id and organization_id fields of the system creator. Supports multiple values for checkbox filtering. Examples: - `?created_by=53h5zxpwu4vc` - matches systems created by user with ID 53h5zxpwu4vc - `?created_by=lbswt1rxdhbz` - matches systems created by users in organization lbswt1rxdhbz - `?created_by=53h5zxpwu4vc&created_by=lbswt1rxdhbz` - matches systems created by the user OR by users in the organization - **version** (array[string]) Filter systems by version using prefixed format `product:version` (e.g., `nsec:8.0`, `ns8:1.2.3`). The prefix prevents ambiguity when the same version number exists for multiple products. Supports multiple values for checkbox filtering. **Example**: `?version=nsec:8.0&version=ns8:1.2.3` matches systems with (nsec version 8.0) OR (ns8 version 1.2.3) **Backward compatibility**: Non-prefixed versions (e.g., `8.0`) are still supported but may match multiple products. - **organization_id** (array[string]) Filter systems by organization ID (exact match). Supports multiple values for checkbox filtering. - **status** (array[string]) Filter systems by status (exact match). Supports multiple values for checkbox filtering. Special value "deleted" shows soft-deleted systems (where deleted_at IS NOT NULL). When "deleted" is combined with other statuses, both deleted and non-deleted systems matching the other statuses are returned. ## Responses ### 200 Export file generated successfully #### Headers - **Content-Disposition** (string) Attachment filename - **Content-Length** (integer) File size in bytes #### Body: text/csv (string(binary)) string(binary) ### 400 Bad request (invalid format or too many systems) #### Body: application/json (object) - **code** (integer) - **message** (string) - **data** (object) ### 401 Unauthorized - invalid or missing token #### Body: application/json (object) - **code** (integer) - **message** (string) - **data** (object | null) ### 403 Forbidden - insufficient permissions #### Body: application/json (object) - **code** (integer) - **message** (string) - **data** (object | null) [Powered by Bump.sh](https://bump.sh)