# SOSL Lib > Apex library that provides functional constructs for building SOSL (Salesforce Object Search Language) queries in Salesforce. Open source (MIT), maintained by Beyond The Cloud as part of Apex Fluently. SOSL Lib wraps SOSL search queries in a fluent Apex builder: `SOSL.find('term').returning(SOSL.Returning(Account.SObject).with(Account.Id, Account.Name)).toSearchList()`. It covers FIND, RETURNING, WHERE, USING SCOPE, ORDER BY, LIMIT, OFFSET, field-level security, sharing mode and mocking of search results in unit tests. ## Docs - [Getting Started](https://sosl.beyondthecloud.dev/index.md): deploy to Salesforce, feature list, license notes - [Installation](https://sosl.beyondthecloud.dev/installation.md): how to add SOSL Lib to a Salesforce project - [Overview](https://sosl.beyondthecloud.dev/docs/overview.md): single class, functional style, dynamic SOSL, FLS, sharing, mocking, dynamic conditions - [Basic Features](https://sosl.beyondthecloud.dev/docs/basic-features.md): dynamic SOSL, controlling FLS, sharing mode, mocking, dynamic conditions with code samples - [Design](https://sosl.beyondthecloud.dev/design.md): single-class design (SOSL.cls) and functional programming approach ## API - [SOSL](https://sosl.beyondthecloud.dev/api/sosl.md): main entry point, FIND clause, scope, limit, offset, sharing, mocking, result methods - [Returning](https://sosl.beyondthecloud.dev/api/sosl-returning.md): RETURNING clause per SObject, fields, filters, ordering, subqueries - [Filter](https://sosl.beyondthecloud.dev/api/sosl-filter.md): single WHERE condition on a field - [FilterGroup](https://sosl.beyondthecloud.dev/api/sosl-filters-group.md): grouping and combining filters with AND/OR ## Examples - [FIND](https://sosl.beyondthecloud.dev/examples/find.md) - [SUBQUERY](https://sosl.beyondthecloud.dev/examples/subquery.md) - [USING SCOPE](https://sosl.beyondthecloud.dev/examples/scope.md) - [WHERE](https://sosl.beyondthecloud.dev/examples/where.md) - [GROUP BY](https://sosl.beyondthecloud.dev/examples/group-by.md) - [ORDER BY](https://sosl.beyondthecloud.dev/examples/order-by.md) - [LIMIT](https://sosl.beyondthecloud.dev/examples/limit.md) - [OFFSET](https://sosl.beyondthecloud.dev/examples/offset.md) - [FIELD-LEVEL SECURITY](https://sosl.beyondthecloud.dev/examples/fls.md) - [SHARING MODE](https://sosl.beyondthecloud.dev/examples/sharing-settings.md) - [MOCKING](https://sosl.beyondthecloud.dev/examples/mocking.md) - [DEBUGGING](https://sosl.beyondthecloud.dev/examples/debug.md) - [RESULT](https://sosl.beyondthecloud.dev/examples/result.md) ## Advanced Usage - [Field-Level Security](https://sosl.beyondthecloud.dev/advanced-usage/fls.md): how FLS is enforced and how to bypass it - [Sharing Rules](https://sosl.beyondthecloud.dev/advanced-usage/sharing.md): with sharing, without sharing, inherited sharing - [Mocking](https://sosl.beyondthecloud.dev/advanced-usage/mocking.md): returning fake search results in Apex tests ## Links - [Source code on GitHub](https://github.com/beyond-the-cloud-dev/sosl-lib) - [Apex Fluently](https://apexfluently.beyondthecloud.dev): the family of Apex libraries this project belongs to - [Beyond The Cloud](https://beyondthecloud.dev): Salesforce consultancy that maintains the library