How would I query for an item based on its Custom Field value?

JosefBudJosefBud Member Posts: 2
edited January 2020 in Development

I'm working on a Node.js app to sync inventory levels between our Lightspeed inventory and our Amazon seller account. Using the Lightspeed docs, I figured I could use Item.json?load_relations=['CustomFieldValues']&CustomFieldValues.value={ASIN} but it started by throwing a SQL error about the column not existing and now it throws the following error:

      '<div>\r\n' +
      "\tAn error has occurred and we've been notified.\r\n" +
      '\tPlease try again and if this problem persists please contact support.\r\n' +

Meanwhile, CustomFieldValues.customFieldID={id} works fine.

Am I doing something wrong?


  • gregaricangregarican Member Posts: 907 

    Not sure if this is possible. For some of my integrations I pipe out Lightspeed Retail data and push it into a local SQL Server repository. Most of the time I have to pull any/all records and parse them if I am looking for anything to do with custom field values. Maybe we are just missing something and this functionality is available. *fingers crossed*

  • JosefBudJosefBud Member Posts: 2

    Yeah it sounds like storing the data locally like that would be the best way. Fortunately, I talked it over with the business owner and we decided that we don't need the Custom SKU field for anything else, and that field can be directly queried so we'll just use that for Amazon ASINs instead of the Custom Field values. Not the way I had hoped to go but it'll work.

Sign In or Register to comment.