Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial push of codegen for Mikrotik RouterOS - routeros-fetch #770

Open
wants to merge 35 commits into
base: develop
Choose a base branch
from

Conversation

mobileskyfi
Copy link

@mobileskyfi mobileskyfi commented Sep 23, 2024

New codegen for Mikrotik's RouterOS /tool/fetch command, in Postman terms named routeros-fetch. The command is used on any Mikrotik router to run web services. But RouterOS syntax is not the easiest since it requires specific escaping. So this "snippet" will deal with mapping a Postman Request, with the right string encoding. Error and tips are presented as RouterOS comments in the snippet. Two new options are added commentary to control if errors/tips are shown & style to control to specific form of the command as it can be used interactively or as a variable in a larger script.

Code was created using "npm boilerplate", with code/structure borrowed from http codegen since RouterOS requires similar "raw-like" bodies. Added "test-unit" that verify the RouterOS codegen offline, similar to the http file codegen unit tests.

The Newman tests do run successfully, except they require MikroTik RouterOS device running with SSH enabled to test (see codegen/routeros-fetch. I ran these manually.

See Issue #769 - Codegen push for Mikrotik RouterOS's /tool/fetch CLI command (routeros-fetch)

@mobileskyfi
Copy link
Author

Any update here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant