Introduction
Searching is done by entering a query string into the search box. The query string can contain contain operators, fields, keywords, numeric intervals, date ranges, or free text search.
Text search
A free text search query without any operator, such as volvo for sale will match any documents that contains any of the words in any of the fields independently of their order. It is translated into a query of volvo OR for OR sale. If surrounding the query with double quotes, e.g. "volvo for sale" it will search for all of the words in that order.
It is also possible to specify words that must (+) and must not (-) be present. For example, apple +iPhone -7s finds any items where iPhone must be present, 7s must not be present and where apple is optional.
Search on specific fields
Besides, you can also specify what fields the query should match against. For example:
- To search for items that contain the word lamp in the title:
document.content.title:lamp - To search for items that contain any of the words iPhone 6s in the body:
document.content.body:(iPhone 6s). - To search for the exact phrase MacBook Pro in the body:
document.content.body:"MacBook Pro". - To search with a wildcard, add * to replace zero or more characters:
document.content.category.name:Cars*. - To search for a regular expression in the user name:
document.user.name:/joh?n(ath[oa]n)/.
All the available fields are documented in the Available fields sections of this page.
Range search
For date, numeric and string fields, it is also possible to specify a range. Inclusive ranges are specified with square brackets [min TO max] and exclusive ranges with curly brackets {min TO max}. One sided ranges can be specified with >, >=, <, and <=. For example:
- To search for all items that were created in Implio from 2017-04-01 to 2017-04-07:
metadata.created:[2017-04-01 TO 2017-04-07] - To search for all items that have a price amount between 3 to 10:
document.content.price.amount:[3 TO 10] - To search for all items that have a price less than or equal to 50:
document.content.price.amount:<=50
OR/AND Logical Operators
Finally, it is also possible to group multiple words, operators and clauses to form sub queries. For example,
- To search for all items where the title contains the word volvo, the price is less than 1000 and the result from Implio was APPROVE:
document.content.title:volvo AND document.content.price.amount:<1000 AND metadata.result:APPROVE - To search for all refused items that were reviewed by the agent John Doe:
metadata.result:REFUSE AND metadata.manualResults.agentId:john.doe@besedo.com - To search for all items that contain the words dangerous and phone in the body, the words volvo or sell in the title, where the category begins with Kl which were updated in Implio for the month of April:
document.content.body:(dangerous AND phone) OR document.content.title:(volvo sell) AND document.content.category.name:Kl* AND metadata.updated:[2017-04-01 TO 2017-04-30]
Available search fields
Item related fields
These fields follow a similar structure as our API (https://besedo.com/api-documentation/#structure) except that the root level is represented by "document". Also note, that the fields below will return the data exactly as it was provided by the customer via the API. To query for edited body or title for instance, use the metadata fields in the next section
Field |
Type |
Description |
---|---|---|
document.id |
String |
Id of the document in the customer's system |
document.content.title |
String |
Text title |
document.content.body |
String |
Text body |
document.content.languageExpected |
String |
ISO 639-1 code of the language in which the ad is expected to be written |
document.content.price.amount |
Double |
Price value |
document.content.price.currency |
String |
ISO 4217 Currency Code |
document.content.type.id |
String |
Id of the type in the customer's system |
document.content.type.name |
String |
Display name of the type e.g “For sale” |
document.content.category.id |
String |
Id of the category in the customers' system |
document.content.category.name |
String |
Display name of the category e.g “Cars” |
document.content.status |
String |
Status of the item in the customer's system |
document.content.createdAt |
Date |
Date when the item was created in the customer's system |
document.content.updatedAt |
Date |
Date when the item was latest updated by user or admin on the customer's system |
document.content.publishedAt |
Date |
Date when the item was published in the customer's sytem |
document.user.id |
String |
Id of user in the customer's system |
document.user.name |
String |
Display name of user in the customer's system |
document.user.phoneNumbers |
String |
Phone number of user in the customer's system |
document.user.emailAddresses |
String |
Email address of user in the customer's system |
document.location.city |
String |
City |
document.location.postalCode |
String |
Postal (zip) code |
document.location.region |
String |
Region |
document.location.countryCode |
String |
Two-letter country code |
document.location.ipAddress |
String |
IP address from where the item was posted |
Metadata fields
Unlike the fields above that are provided by the customer, those documented below are generated automatically or manually in Implio.
Field |
Type |
Description |
---|---|---|
metadata.taskId |
String |
Unique processing id for a specific item version |
metadata.batchId |
String |
Unique id for items that were posted together in the same batch |
metadata.created |
Date |
Date when the item entered Implio |
metadata.updated |
Date |
Date when the item was last updated in Implio |
metadata.result |
String |
Result for the item. The values can either be MANUAL, DEFER, APPROVE, REFUSE, NO DECISION |
metadata.feedback.id |
String |
Feedback decisions id |
metadata.feedback.name |
String |
Feedback decisions name |
metadata.decisions.id |
String |
Refusal decisions id |
metadata.decisions.name |
String |
Refusal decisions name |
metadata.manualResults.timestamp |
Date |
Date when an item was processed by agent |
metadata.manualResults.result |
String |
Decision from agent who reviewed the item. The values can either be DEFER, APPROVE, REFUSE, NO DECISION |
metadata.manualResults.decisions.id |
String |
Refusal decisions id |
metadata.manualResults.decisions.name |
String |
Refusal decisions name |
metadata.manualResults.agentId |
String |
Id of agent that took the decision |
metadata.manualResults.title |
String |
Edits made by the moderator to the title |
metadata.manualResults.body |
String |
Edits made by the moderator to the body |
metadata.manualResults.category.name |
String |
Edits made to the category by the moderator |
metadata.automaticResults.result |
String |
Result from all votes of rules. The values can either be MANUAL, APPROVE, REFUSE, NO DECISION |
metadata.automaticResults.timestamp |
Date |
Date when rules were processed |
metadata.automaticResults.filters.name |
String |
Name of rule that hit the item |
metadata.automaticResults.filters.result |
String |
Vote of rule that hit the item. The values can either be MANUAL, APPROVE, REFUSE, NO DECISION |