Commit graph

8 commits

Author SHA1 Message Date
derdeagle
ad6faf275d
Fixes #236: Add missing parameters for the "ip firewall" subpaths and set the default value for the "disabled" parameter for most paths (#237)
* Fixes #236: Add missing parameters

The parameters "address-list", "address-list-timeout", and "realm" were
missing for some subpaths of "ip firewall" and are now added.
Additionally the default value of "False" for the "disabled" parameter
has been set so that an e.g. firewall rule, which was disabled
(disabled=True) is enabled (disabled=False) after removing the
"disabled" argument in the data.

Some more parameters can now be removed, e.g. "jump-target", "log", and "log-prefix",
which are not mandatory.

* Add missing changes for #236

Additionally fixed the PR id in the changelog fragment.

* Update changelogs/fragments/237-add-missing-ip-firewall-attributes.yml

Full stop added at the end of the changelog fragment

Co-authored-by: Felix Fontein <felix@fontein.de>

* Update changelogs/fragments/237-add-missing-ip-firewall-attributes.yml

Full stop added at the end of the changelog fragment

Co-authored-by: Felix Fontein <felix@fontein.de>

* Fix unit tests

---------

Co-authored-by: Johannes Münch <git@washiza.eu>
Co-authored-by: Felix Fontein <felix@fontein.de>
2023-12-03 13:02:08 +01:00
Felix Fontein
dcc1cf441d
Allow to differ on API paths based on RouterOS version (2/2) (#212)
* Allow to add versioned field for paths.

* The field added in 1aa41ad375 is RouterOS 7.7+.

* The fields added in 2e1159b4c4 are RouterOS 7.5+.
2023-09-01 23:17:47 +02:00
Felix Fontein
1dfa79c5ef
Remove unnecessary test imports. (#150) 2023-02-12 21:17:22 +01:00
Felix Fontein
d1ff3b2730
Add more tests for api_info and api_modify (#135)
* Add tests for builtin entries.

* Add tests for combined default and can_disable.
2022-11-18 12:55:34 +01:00
Tomas Herfert
5af14a8940
support for new API paths and few updates (#133)
* support for new API paths and few updates

Signed-off-by: Tomas Herfert <herfik>

* changelog fix

Signed-off-by: Tomas Herfert <herfik>

* tests update

Signed-off-by: Tomas Herfert <herfik>

Signed-off-by: Tomas Herfert <herfik>
Co-authored-by: Tomas Herfert <herfik>
2022-11-17 20:14:07 +01:00
Felix Fontein
9fc22be186
api_modify, api_info: support more fields in existing paths (#121)
* Support more paths.

* Forgot comma.

* Adjust tests.

* power-cycle-ping-address and power-cycle-ping-timeout can be unset

Co-authored-by: Tomas Herfert <68421396+therfert@users.noreply.github.com>

Co-authored-by: Tomas Herfert <68421396+therfert@users.noreply.github.com>
2022-11-10 21:10:24 +01:00
Felix Fontein
f797b4a231
Support absent values. Support absent value 'all' for 'server' in /ip dhcp-server lease. (#107) 2022-08-13 10:55:37 +02:00
Felix Fontein
2911710f1b
Add api_info and api_modify modules (#91)
* Add api_info and api_modify modules.

* Add documentation, and cross-references for the modules.

* Bump version added for new modules.

* Ignore dynamic entries. Allow _info module to return them.

* Document behavior for dynamic entries.

* Update license headers.

* Add disclaimer.

* Improve formulation.

* Auto-generate path list in DOCUMENTATION.

* Add test to make sure lists have been generated automatically.
2022-07-31 22:06:19 +02:00