Create item with api

Create item with api

Help with the following would be greatly appreciated .....

// get & copy existing item details...

var itemID = "###############";
  var itemArray = [];
  var url = 'https://books.zoho.com/api/v3/items/' + encodeURIComponent(itemID) + '?authtoken=' + token;
  var response = UrlFetchApp.fetch(url);
  var obj = JSON.parse(response.getContentText());
  for (var i = 0; i <= obj.item.custom_fields.length-1 ; i++)
  {
    if (obj.item.custom_fields[i].label == "Bay") itemArray.push(["Bay",obj.item.custom_fields[i].value]);
    if (obj.item.custom_fields[i].label == "Recno") itemArray.push(["Recno",obj.item.custom_fields[i].value]);
  }
  itemArray.push(["name",obj.item.name]);
  itemArray.push(["unit",obj.item.unit]);
  itemArray.push(["vendor_name",obj.item.vendor_name]);
  itemArray.push(["tax_name",obj.item.tax_name]);

var customField = [];
customField.push("label","Bay");
customField.push("value","On Order");
array.push("custom_fields",customField);
Blah, blah, blah ....

Is the above OK to use ?
The code below is a miserable failure so I need an example of how to post a new item properly (difficult to find anywhere)  ......

var url = 'https://books.zoho.com/api/v3/items/' + 'createItem' + array
+ '?authtoken=' + token; 
  var Response = UrlFetchApp.fetch(url);
  
  Logger.log(Response) Request failed for     Request failed for https://books.zoho.com/api/v3/items/createItem?