Enabling Native REST API
This document covers API version 7 supported by the HNAS native REST API. Native API mode has been introduced in software release 13.9.6800, and will be used for future API improvements and features, replacing the previous legacy API versions.
To check which mode is enabled, use the rest-server-mode command:
G800-443037-1:$ rest-server-mode The RestAPI server mode is: legacy
To switch to native mode, stop the REST API server, enable native mode, and then restart the REST API server, using the following commands:
G800-443037-1:$ rest-server-stop The RestAPI server has been successfully stopped. G800-443037-1:$ rest-server-mode --native The RestAPI server mode change will not take affect until the RestAPI server is restarted. G800-443037-1:$ rest-server-start The RestAPI server has been successfully started. G800-443037-1:$ rest-server-mode The RestAPI server mode is: native G800-443037-1:$