update_config_from_file
Replace a BunkerWeb config snippet with base64-encoded file content, optionally renaming or retyping it; saves to the database for later scheduler application, not immediate live confirmation.
Instructions
Replace a snippet from a base64 file ({filename, content_base64}); without new_name the stem renames it. UI/API-managed or template-derived only; templates cannot be renamed. Use update_config for text. Saved to the database; the scheduler applies it later; this tool cannot confirm it is live.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | Yes | File whose content replaces the snippet's | |
| name | Yes | Snippet name: letters, digits, _ or -, no extension | |
| type | Yes | Custom config type, e.g. http, server-http, default-server-http, stream, server-stream, modsec, modsec-crs, crs-plugins-before, crs-plugins-after | |
| service | No | Service ID that owns the snippet; omit or 'global' for global | |
| new_name | No | New name; if omitted the file stem renames the snippet, so pass the current name to keep it | |
| new_type | No | Change the type; omit to keep | |
| new_service | No | Move to this service; omit to keep | |
| new_is_draft | No | Set the draft flag; omit to keep |