API Reference
Create/Update Multiple Rows
1min
code examples curl location 'https //api hunni io/v1/hunnirowsavebulk' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data '"\[\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 0\n },\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 1\n }\n]"'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var raw = json stringify("\[\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 0\n },\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 1\n }\n]"); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("https //api hunni io/v1/hunnirowsavebulk", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));require "uri" require "json" require "net/http" url = uri("https //api hunni io/v1/hunnirowsavebulk") https = net http new(url host, url port) https use ssl = true request = net http post new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request body = json dump("\[\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 0\n },\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 1\n }\n]") response = https request(request) puts response read body import requests import json url = "https //api hunni io/v1/hunnirowsavebulk" payload = json dumps("\[\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 0\n },\n {\n \\"id\\" \\"\<integer>\\",\n \\"hunniassetid\\" \\"\<integer>\\",\n \\"hunnirowcolumnvalues\\" \[\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n },\n {\n \\"hunnirowid\\" \\"\<integer>\\",\n \\"hunnicolumnid\\" \\"\<integer>\\",\n \\"value\\" \\"\<string>\\"\n }\n ],\n \\"assettype\\" 1\n }\n]") headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses { "message" "\<string>", "issuccess" "\<boolean>", "objectid" "\<integer>" }