MikroTik CRS305-1G-4S+ Rest API

MikroTik CRS305-1G-4S+ Rest API

Receiving general information from Rest API - Starting from RouterOS v7.1 beta 4 and newer

This example allows integration of a MikroTik CRS305-1G-4S+ switch into the ComfortClick automation platform. The integration enables seamless communication between the two systems, allowing for the retrieval of general information from the router through MikroTik's REST API. This integration enhances network management and automation capabilities, providing a user-friendly and efficient solution for monitoring the router's ports within the ComfortClick ecosystem. Added log filtering by selecting desired topics to log.

Device preparation

Connect to your Mikrotik device by using winbox app and login to your device. By selecting System and Users a User list will open where a new user should be made. When creating a new user a group needs to be created. It can be named as API and the following policies need to be set: read, write, test, api, rest-api.

Configuration

Download the example from our website and import it into your configuration. Step by step instructions on how to import are available in our instructional video.

Change the login credentials under Authentication and use your correct IP address in the Host URL. Import the example into the current configuration (make sure you have the correct MikroTik switch) The IP/Address node contains Control panel with Get IP function to get all the information from the device For more detailed guidance on API and connection settings, please consult their official API.

Top