Search Query Syntax
Nest uses a structured query parser that supports field-specific searches, comparison operators, and quoted strings.Basic Field Syntax
Search specific fields using thefield:value format:
Field Types
The query parser supports four field types:String Fields
Text-based searches with partial matchingExample:
name:nest language:pythonNumber Fields
Numeric searches with comparison operatorsExample:
stars:100 forks>50Boolean Fields
True/false valuesExample:
archived:false is_template:trueDate Fields
Date-based searches with comparisonsExample:
created_at>2024-01-01Comparison Operators
Use comparison operators with number and date fields:| Operator | Description | Example |
|---|---|---|
= | Equal to (default) | stars=100 |
> | Greater than | stars>100 |
< | Less than | stars<100 |
>= | Greater than or equal | stars>=100 |
<= | Less than or equal | stars<=100 |
Number Field Examples
Date Field Examples
Date formats supported:
YYYY-MM-DD or YYYYMMDDString Matching
String fields support two matching strategies:Case-Insensitive Partial Match (Default)
Exact Match
Use quotes for exact matching:Quoted Strings
Use double quotes for multi-word values:Escaping Quotes
Escape quotes within quoted strings:Boolean Values
Boolean fields accept multiple value formats: True values:true, 1, yes, on
False values: false, 0, no, off
Combining Conditions
All conditions are combined with implicit AND logic:Free-Text Search
Tokens without a field prefix are treated as free-text searches:Real-World Examples
Find Popular Python Projects
Find Recently Updated Projects
Find Beginner-Friendly Projects
Find Projects by Technology
Searchable Fields by Entity
Repositories
Repository name (partial match)
Primary programming language
Number of GitHub stars
Number of repository forks
Number of unique contributors
Whether the repository is archived
Repository creation date
Last update date
Projects
Project name (partial match)
Project level (e.g., “flagship”, “lab”)
Project creation date
Last update date
Chapters
Chapter name (partial match)
Chapter country
Geographic region
Error Handling
The query parser gracefully handles errors:Unknown Fields
Invalid Values
Malformed Dates
Implementation Details
Nest’s structured search is powered by a custom query parser:Parser Configuration
Query Result Format
API Integration
Use structured search with the REST API:Search Repositories
Search Projects
URL Encoding
Remember to URL-encode special characters:- cURL
- Python
- JavaScript
Best Practices
Start Simple
Start Simple
Begin with basic searches and add conditions incrementally:
name:nestname:nest stars>100name:nest stars>100 language:python
Use Appropriate Operators
Use Appropriate Operators
Choose operators that match your intent:
- Use
>for “at least” searches:stars>100 - Use
>=for “minimum” thresholds:contributors>=10 - Use
<for “maximum” limits:forks<50
Quote Multi-Word Values
Quote Multi-Word Values
Always quote strings with spaces:
Validate Date Formats
Validate Date Formats
Use ISO format dates for clarity: