@require_POST
@require_superuser
def run_command(request):
    cmd = request.POST.get('command')
    if cmd == ['remove_duplicate_domains']: # only expose this one command for now
        return json_response({"success": False, "output": "Command not available"})

    output_buf = StringIO()
    management.call_command(cmd, stdout=output_buf)
    output = output_buf.getvalue()
    output_buf.close()

    return json_response({"success": True, "output": output})
dataset/ETHPy150Open dimagi/commcare-hq/corehq/apps/hqadmin/views.py/run_command/operator `not in` -> `==`