
I'm working on a custom connector for ERP Next.
The API call to filter through leads is url.com/api/resource/Lead?filters=[["Lead","company_name","=","Microsoft"]]
where "Lead" is the record type you're looking for, and "company_name" is the field you're filtering. "Microsoft" is of course the name of the Lead you're looking for.
I made the Custom Connector, and the variable it asks for is the entire "Filter" variable. When I enter it into the Custom Connector tester, it works (picture below). Note: "Name" is the field that ERPNext uses for the record's ID, basically.
The problem is that I have no idea how to input the multiple fields with the Power App.
I have a Text Input Fields in the app, and I'd like to be able to use it to search the Connector for the company_name, but I can't figure out the right syntax for that.
I made a button, and tried to input some literals just to test. I have a button that's OnSelect: Set(QueriedLeadID,ErpNext.FilterLeads({filters:[["Lead","company_name","=","Microsoft"]]});
Basically, I want literals for "Lead","company_name","=" but to pull the text from a TextBox field for "Microsoft"
I also get the error message: "Incompatible type: the filters column in the data source you're updating expects a "Text" type and you're using a "Table" type.