MikroTik API icon

MikroTik API

Community Node for MikroTik RouterOS API

Actions67

System Script → Remove

AI-generated

Summary

Remove a system script by ID or name on a MikroTik device.

Inputs

  • targetId (required) — ID (*1, *2) or Name (ether1, user1)
  • options — Optional configuration for connection retry, delay, key cleaning, and tagging.

Output shape

{ resource, operation, count, data }

Data array is post-processed: if cleanKeys is true, '-' and '/' in keys are replaced with '_'.

Examples

Example 1: Remove a script named 'backup-db'.

targetId: 'backup-db'

Example 2: Remove script ID 5 with 3 retries, 2-second delay, key cleaning, and tag 42.

targetId: '5', options: { connectionAttempts: 3, connectionDelay: 2, cleanKeys: true, tag: 42 }

Links

Discussion