Closed alexander-haller closed 2 months ago
In GitLab by @mhxion on Jun 15, 2024, 12:39
marked the checklist item Move get
, post
, patch
, delete
to its own section named "Raw API commands". as completed
In GitLab by @mhxion on Jul 1, 2024, 14:09
marked the checklist item Move get
, post
, patch
, delete
to its own section named "Raw API commands". as incomplete
In GitLab by @mhxion on Jul 1, 2024, 14:33
marked the checklist item Move get
, post
, patch
, delete
to its own section named "Raw API commands". as completed
In GitLab by @mhxion on May 17, 2024, 16:06
get
,post
,patch
,delete
mostly do not handle API response errors as intended. These 4 commands are meant to behave this way, to behave as closely as possible with the original behavior of eLabFTW (or how curl would behave).Plugins, however are meant to handle edge cases and all sorts of errors. The same action with experiments plugin will give:
This difference is one of the main differences between the 4 raw commands and plugins. Plugins are meant to handle all special/edge cases. Eventually, we would have a plugin for all endpoints. So
get
,post
,patch
anddelete
are mainly useful for testing/inspecting things.To properly clarify this distinction, we propose the following changes:
get
,post
,patch
,delete
to its own section named "Raw API commands".- [ ] This pitfall of using the raw commands should be explicitly mentioned in online documentation and in--help
. "For proper error handling, one should use plugins that are meant to handle one's intended cases."The main issue that influenced this
feature-request
was brought up by @alexander-haller as usual. Proposed solutions are collaborative.