### Silent install NativeRest with /silent switch Source: https://nativesoft.com/docs/install Runs the NativeRest installer in silent mode without displaying its GUI. Use /verysilent to prevent the application from launching after installation, /update to update an existing installation, /uninstall to uninstall, and /dir="..." to override the default installation path %APPDATA%\Roaming\NativeSoft\NativeRest. Exit codes: 0 (no errors), 1 (common installation error), 2 (destination folder access denied). ```text nativerest.1.0.0.installer.exe /silent ``` -------------------------------- ### string.startsWith(_, _) Source: https://nativesoft.com/docs/functions Checks if a string starts with a specified prefix. ```APIDOC ## string.startsWith(_, _) ### Description Checks if a string starts with a specified prefix. ### Parameters - **_** (string) - Required - String to check. - **_** (string) - Required - Prefix. ### Example string.startsWith(_, _) ``` -------------------------------- ### GET /echo/get Source: https://nativesoft.com/docs/echo Test URL query parameters with a GET request. The API echoes back the query parameters and headers. ```APIDOC ## GET https://nativerest.net/echo/get ### Description Use this endpoint to test URL query parameters. The API will return a JSON object with your exact query parameters under the `args` property, and echo back your User-Agent and any custom headers. ### Method GET ### Endpoint https://nativerest.net/echo/get ### Parameters #### Query Parameters - **foo1** (string) - Optional - Example query parameter. - **foo2** (string) - Optional - Example query parameter. ### Response #### Success Response (200) - **args** (object) - Contains the query parameters sent. - **headers** (object) - Echoes back User-Agent and custom headers. #### Response Example { "args": { "foo1": "bar1", "foo2": "bar2" }, "headers": { "User-Agent": "...", "Custom-Header": "..." } } ``` -------------------------------- ### os.userRegistry(_, _) Source: https://nativesoft.com/docs/functions Returns the string value from the Windows registry (HKEY_CURRENT_USER). ```APIDOC ## os.userRegistry(_, _) ### Description Returns the string value from the Windows registry (HKEY_CURRENT_USER). ### Parameters - **_** (string) - Required - Registry key path. - **_** (string) - Required - Value name. ### Example os.userRegistry(_, _) ``` -------------------------------- ### os.machineRegistry(_, _) Source: https://nativesoft.com/docs/functions Returns the string value from the Windows registry (HKEY_CURRENT_MACHINE). ```APIDOC ## os.machineRegistry(_, _) ### Description Returns the string value from the Windows registry (HKEY_CURRENT_MACHINE). ### Parameters - **_** (string) - Required - Registry key path. - **_** (string) - Required - Value name. ### Example os.machineRegistry(_, _) ``` -------------------------------- ### os.getEnv(_) Source: https://nativesoft.com/docs/functions Returns the value of the operating system's environment variable specified by its name. ```APIDOC ## os.getEnv(_) ### Description Returns the value of the operating system's environment variable specified by its name. ### Parameters - **_** (string) - Required - Environment variable name. ### Example os.getEnv(_) ``` -------------------------------- ### file.readAll(_) Source: https://nativesoft.com/docs/functions Reads the entire content of a file. ```APIDOC ## file.readAll(_) ### Description Reads the entire content of a file. ### Parameters - **_** (string) - Required - File path. ### Example file.readAll(_) ``` -------------------------------- ### base64.encode(_) Source: https://nativesoft.com/docs/functions Encodes the input to Base64. ```APIDOC ## base64.encode(_) ### Description Encodes the input to Base64. ### Parameters - **_** (any) - Required - Input to encode. ### Example base64.encode(_) ``` -------------------------------- ### PUT /echo/post Source: https://nativesoft.com/docs/echo Simulate resource updates with a PUT request. The API echoes back the modified payload. ```APIDOC ## PUT https://nativerest.net/echo/post ### Description Ideal for simulating resource updates. Similar to POST, it echoes back the modified payload you sent. ### Method PUT ### Endpoint https://nativerest.net/echo/post ### Request Body - **data** (any) - Optional - The payload to be echoed back. ### Response #### Success Response (200) - **data** (any) - The echoed payload. #### Response Example { "data": "..." } ``` -------------------------------- ### POST /echo/post Source: https://nativesoft.com/docs/echo Test data payloads with a POST request. The API echoes back the parsed request body. ```APIDOC ## POST https://nativerest.net/echo/post ### Description Use this endpoint to test data payloads, including raw JSON, XML, or x-www-form-urlencoded forms. The API parses your request body and returns it under the `data` or `form` property. ### Method POST ### Endpoint https://nativerest.net/echo/post ### Request Body - **data** (any) - Optional - The raw payload to be echoed back. - **form** (object) - Optional - Form-encoded fields to be echoed back. ### Response #### Success Response (200) - **data** (any) - The parsed request body. - **form** (object) - The form fields received. #### Response Example { "data": "...", "form": { "field": "value" } } ``` -------------------------------- ### random.string(_, _) Source: https://nativesoft.com/docs/functions Generates a random string. Takes two parameters. ```APIDOC ## random.string(_, _) ### Description Generates a random string. ### Parameters - **_** (any) - Required - First parameter. - **_** (any) - Required - Second parameter. ### Example random.string(_, _) ``` -------------------------------- ### DELETE /echo/delete Source: https://nativesoft.com/docs/echo Test resource removal logic with a DELETE request. ```APIDOC ## DELETE https://nativerest.net/echo/delete ### Description Use this endpoint to test your resource removal logic. ### Method DELETE ### Endpoint https://nativerest.net/echo/delete ### Response #### Success Response (200) No response body details provided. ``` -------------------------------- ### string.length(_) Source: https://nativesoft.com/docs/functions Returns the length of a string. ```APIDOC ## string.length(_) ### Description Returns the length of a string. ### Parameters - **_** (string) - Required - String to measure. ### Example string.length(_) ``` -------------------------------- ### md5(_) Source: https://nativesoft.com/docs/functions Computes the MD5 hash of the input. Hash functions do not have a prefix. ```APIDOC ## md5(_) ### Description Computes the MD5 hash of the input. ### Parameters - **_** (any) - Required - Input to hash. ### Example md5(_) ``` -------------------------------- ### math.min(_, _) Source: https://nativesoft.com/docs/functions Returns the minimum of two numbers. ```APIDOC ## math.min(_, _) ### Description Returns the minimum of two numbers. ### Parameters - **_** (number) - Required - First number. - **_** (number) - Required - Second number. ### Example math.min(_, _) ``` -------------------------------- ### string.trim(_) Source: https://nativesoft.com/docs/functions Trims whitespace from the beginning and end of a string. ```APIDOC ## string.trim(_) ### Description Trims whitespace from the beginning and end of a string. ### Parameters - **_** (string) - Required - String to trim. ### Example string.trim(_) ``` -------------------------------- ### string.isEmpty(_) Source: https://nativesoft.com/docs/functions Checks if a string is empty. ```APIDOC ## string.isEmpty(_) ### Description Checks if a string is empty. ### Parameters - **_** (string) - Required - String to check. ### Example string.isEmpty(_) ``` -------------------------------- ### NativeRest Echo API test script (Tests tab) Source: https://nativesoft.com/docs/echo Paste this script into the Tests tab in NativeRest to verify the response status is 200 and the response time is under 1000 ms. When you click Send, NativeRest executes the script and displays green checkmarks in the Test Results panel. ```plaintext # Response status code is 200 response.status == 200 # Response time is less than 1000 ms response.time < 1000 ``` -------------------------------- ### math.div(_, _) Source: https://nativesoft.com/docs/functions Divides the first number by the second. ```APIDOC ## math.div(_, _) ### Description Divides the first number by the second. ### Parameters - **_** (number) - Required - Dividend. - **_** (number) - Required - Divisor. ### Example math.div(_, _) ``` -------------------------------- ### math.add(_, _) Source: https://nativesoft.com/docs/functions Adds two numbers. ```APIDOC ## math.add(_, _) ### Description Adds two numbers. ### Parameters - **_** (number) - Required - First addend. - **_** (number) - Required - Second addend. ### Example math.add(_, _) ``` -------------------------------- ### string.repeat(_, _) Source: https://nativesoft.com/docs/functions Repeats a string a specified number of times. ```APIDOC ## string.repeat(_, _) ### Description Repeats a string a specified number of times. ### Parameters - **_** (string) - Required - String to repeat. - **_** (integer) - Required - Number of repetitions. ### Example string.repeat(_, _) ``` -------------------------------- ### string.toUpperCase(_) Source: https://nativesoft.com/docs/functions Converts a string to uppercase. ```APIDOC ## string.toUpperCase(_) ### Description Converts a string to uppercase. ### Parameters - **_** (string) - Required - String to convert. ### Example string.toUpperCase(_) ``` -------------------------------- ### string.indexOf(_, _) Source: https://nativesoft.com/docs/functions Returns the index of the first occurrence of a substring. ```APIDOC ## string.indexOf(_, _) ### Description Returns the index of the first occurrence of a substring. ### Parameters - **_** (string) - Required - String to search. - **_** (string) - Required - Substring to find. ### Example string.indexOf(_, _) ``` -------------------------------- ### math.floor(_) Source: https://nativesoft.com/docs/functions Rounds a number down to the nearest integer. ```APIDOC ## math.floor(_) ### Description Rounds a number down to the nearest integer. ### Parameters - **_** (number) - Required - Number to round down. ### Example math.floor(_) ``` -------------------------------- ### if(condition, trueValue, falseValue) Source: https://nativesoft.com/docs/functions Returns the second or third argument depending on the result of the comparison. It is possible to use variables in arguments. ```APIDOC ## if(condition, trueValue, falseValue) ### Description Returns the second or third argument depending on the result of the comparison. It is possible to use variables in arguments. ### Parameters - **condition** (boolean) - Required - Comparison expression. - **trueValue** (any) - Required - Value returned if condition is true. - **falseValue** (any) - Required - Value returned if condition is false. ### Example if({{date.hours}} < 12, "Ante meridiem", "Post Meridiem") ### Comparison Operators !=, <=, >=, <, >, ==, %%, =%, %= ``` -------------------------------- ### file.readLine(_, _) Source: https://nativesoft.com/docs/functions Reads a specific line from a file. ```APIDOC ## file.readLine(_, _) ### Description Reads a specific line from a file. ### Parameters - **_** (string) - Required - File path. - **_** (integer) - Required - Line number. ### Example file.readLine(_, _) ``` -------------------------------- ### string.toLowerCase(_) Source: https://nativesoft.com/docs/functions Converts a string to lowercase. ```APIDOC ## string.toLowerCase(_) ### Description Converts a string to lowercase. ### Parameters - **_** (string) - Required - String to convert. ### Example string.toLowerCase(_) ``` -------------------------------- ### file.readProperty(_, _) Source: https://nativesoft.com/docs/functions Reads a property value from a properties file. ```APIDOC ## file.readProperty(_, _) ### Description Reads a property value from a properties file. ### Parameters - **_** (string) - Required - File path. - **_** (string) - Required - Property name. ### Example file.readProperty(_, _) ``` -------------------------------- ### date.format(_) Source: https://nativesoft.com/docs/functions Formats the current date and time according to the specified format string. See date and time format specifiers. ```APIDOC ## date.format(_) ### Description Formats the current date and time according to the specified format string. ### Parameters - **_** (string) - Required - Format string using date and time specifiers. ### Example {{date.format(yyyy-mm-dd hh:nn)}} ``` -------------------------------- ### file.readIni(_, _, _) Source: https://nativesoft.com/docs/functions Reads a value from an INI file. ```APIDOC ## file.readIni(_, _, _) ### Description Reads a value from an INI file. ### Parameters - **_** (string) - Required - File path. - **_** (string) - Required - Section. - **_** (string) - Required - Key. ### Example file.readIni(_, _, _) ``` -------------------------------- ### random.ulid(_) Source: https://nativesoft.com/docs/functions Generates a random ULID. Takes one parameter. ```APIDOC ## random.ulid(_) ### Description Generates a random ULID. ### Parameters - **_** (any) - Required - Placeholder for the single parameter. ### Example random.ulid(_) ``` -------------------------------- ### base64.decode(_) Source: https://nativesoft.com/docs/functions Decodes a Base64-encoded input. ```APIDOC ## base64.decode(_) ### Description Decodes a Base64-encoded input. ### Parameters - **_** (any) - Required - Base64 string to decode. ### Example base64.decode(_) ``` -------------------------------- ### string.charAt(_, _) Source: https://nativesoft.com/docs/functions Returns the character at the specified index. ```APIDOC ## string.charAt(_, _) ### Description Returns the character at the specified index. ### Parameters - **_** (string) - Required - String. - **_** (integer) - Required - Index. ### Example string.charAt(_, _) ``` -------------------------------- ### random.integer(_) Source: https://nativesoft.com/docs/functions Generates a random integer. The underscore indicates the number of parameters, which is one. ```APIDOC ## random.integer(_) ### Description Generates a random integer. ### Parameters - **_** (any) - Required - Placeholder for the single parameter. ### Example random.integer(_) ``` -------------------------------- ### hmac.sha384(_, _) Source: https://nativesoft.com/docs/functions Computes an HMAC-SHA384 hash. Takes two parameters. ```APIDOC ## hmac.sha384(_, _) ### Description Computes an HMAC-SHA384 hash. ### Parameters - **_** (any) - Required - First parameter. - **_** (any) - Required - Second parameter. ### Example hmac.sha384(_, _) ``` -------------------------------- ### sha384(_) Source: https://nativesoft.com/docs/functions Computes the SHA-384 hash of the input. ```APIDOC ## sha384(_) ### Description Computes the SHA-384 hash of the input. ### Parameters - **_** (any) - Required - Input to hash. ### Example sha384(_) ``` -------------------------------- ### sha1(_) Source: https://nativesoft.com/docs/functions Computes the SHA-1 hash of the input. ```APIDOC ## sha1(_) ### Description Computes the SHA-1 hash of the input. ### Parameters - **_** (any) - Required - Input to hash. ### Example sha1(_) ``` -------------------------------- ### math.max(_, _) Source: https://nativesoft.com/docs/functions Returns the maximum of two numbers. ```APIDOC ## math.max(_, _) ### Description Returns the maximum of two numbers. ### Parameters - **_** (number) - Required - First number. - **_** (number) - Required - Second number. ### Example math.max(_, _) ``` -------------------------------- ### file.readXml(_, _) Source: https://nativesoft.com/docs/functions Reads an XML value from a file. ```APIDOC ## file.readXml(_, _) ### Description Reads an XML value from a file. ### Parameters - **_** (string) - Required - File path. - **_** (string) - Required - XML path or key. ### Example file.readXml(_, _) ``` -------------------------------- ### math.mul(_, _) Source: https://nativesoft.com/docs/functions Multiplies two numbers. ```APIDOC ## math.mul(_, _) ### Description Multiplies two numbers. ### Parameters - **_** (number) - Required - First factor. - **_** (number) - Required - Second factor. ### Example math.mul(_, _) ``` -------------------------------- ### math.sqrt(_) Source: https://nativesoft.com/docs/functions Returns the square root of a number. ```APIDOC ## math.sqrt(_) ### Description Returns the square root of a number. ### Parameters - **_** (number) - Required - Number to take square root of. ### Example math.sqrt(_) ``` -------------------------------- ### hmac.sha512(_, _) Source: https://nativesoft.com/docs/functions Computes an HMAC-SHA512 hash. Takes two parameters. ```APIDOC ## hmac.sha512(_, _) ### Description Computes an HMAC-SHA512 hash. ### Parameters - **_** (any) - Required - First parameter. - **_** (any) - Required - Second parameter. ### Example hmac.sha512(_, _) ``` -------------------------------- ### math.ceil(_) Source: https://nativesoft.com/docs/functions Rounds a number up to the nearest integer. ```APIDOC ## math.ceil(_) ### Description Rounds a number up to the nearest integer. ### Parameters - **_** (number) - Required - Number to round up. ### Example math.ceil(_) ``` -------------------------------- ### random.range(_, _) Source: https://nativesoft.com/docs/functions Generates a random number within a specified range. Takes two parameters. ```APIDOC ## random.range(_, _) ### Description Generates a random number within a specified range. ### Parameters - **_** (any) - Required - First parameter. - **_** (any) - Required - Second parameter. ### Example random.range(_, _) ``` -------------------------------- ### sha256(_) Source: https://nativesoft.com/docs/functions Computes the SHA-256 hash of the input. ```APIDOC ## sha256(_) ### Description Computes the SHA-256 hash of the input. ### Parameters - **_** (any) - Required - Input to hash. ### Example sha256(_) ``` -------------------------------- ### hmac.sha256(_, _) Source: https://nativesoft.com/docs/functions Computes an HMAC-SHA256 hash. Takes two parameters. ```APIDOC ## hmac.sha256(_, _) ### Description Computes an HMAC-SHA256 hash. ### Parameters - **_** (any) - Required - First parameter. - **_** (any) - Required - Second parameter. ### Example hmac.sha256(_, _) ``` -------------------------------- ### sha512(_) Source: https://nativesoft.com/docs/functions Computes the SHA-512 hash of the input. ```APIDOC ## sha512(_) ### Description Computes the SHA-512 hash of the input. ### Parameters - **_** (any) - Required - Input to hash. ### Example sha512(_) ``` -------------------------------- ### random.uuid(_) Source: https://nativesoft.com/docs/functions Generates a random UUID. Takes one parameter. ```APIDOC ## random.uuid(_) ### Description Generates a random UUID. ### Parameters - **_** (any) - Required - Placeholder for the single parameter. ### Example random.uuid(_) ``` -------------------------------- ### sha224(_) Source: https://nativesoft.com/docs/functions Computes the SHA-224 hash of the input. ```APIDOC ## sha224(_) ### Description Computes the SHA-224 hash of the input. ### Parameters - **_** (any) - Required - Input to hash. ### Example sha224(_) ```