In today's application landscape, data is the lifeblood, but it's often fragmented across dozens of sources: relational databases, NoSQL stores, third-party services, and internal APIs. For developers, this creates a constant challenge: how do you efficiently and securely query this data without writing tangled, brittle code?
Enter a new paradigm: Intelligent Search, Delivered as Code.
Searches.do is an agentic workflow platform designed to solve this very problem. It allows you to build, deploy, and manage intelligent search and data retrieval agents, transforming complex logic into simple, powerful, and reusable APIs.
This guide will walk you through the core concepts of Searches.do and show you how to build your first intelligent data query.
Before we dive in, let's clarify what we mean by an "agent." Think of a search agent as a specialized, autonomous unit of code dedicated to a single data retrieval task. It's more than just a function or a SQL query; it's a complete package that encapsulates:
By using this agentic workflow, you decouple your main application from the complexities of your data sources. Your app no longer needs to know how to talk to the customer database; it just needs to ask the find-customer agent for the data it needs.
Let’s walk through a classic developer task: retrieving a customer's profile from a database using their email address.
On the Searches.do platform, you'd start by creating a new agent. We'll name it find-customer-by-email. This name isn't just a label; it's the unique identifier we'll use to call our agent later.
Inside the agent's configuration, you define the search logic. This is "Business-as-Code" in action. You might:
SELECT id, first_name, last_name, email, created_at
FROM customers
WHERE email = ?;
With the logic defined, you deploy the agent. Instantly, Searches.do provisions a secure, scalable endpoint for your agent. You've just turned a raw database query into a fully-managed search API without writing a single line of backend server code, managing infrastructure, or worrying about security vulnerabilities like SQL injection (since the query structure is pre-defined).
Now for the fun part. With your agent live, you can call it from any application using the Searches.do client library. The complexity of the database connection and query is completely abstracted away.
Here’s how you’d use our find-customer-by-email agent in a TypeScript application:
import { createClient } from 'searches.do';
// Initialize the client with your API key
const searches = createClient(process.env.DO_API_KEY);
// Effortlessly run a pre-defined search agent
async function findCustomer(email: string) {
try {
const customer = await searches.run('find-customer-by-email', {
email: email
});
console.log('Found customer:', customer);
return customer;
} catch (error) {
console.error('Failed to retrieve customer:', error);
}
}
findCustomer('jane.doe@example.com');
Let's break that down:
The result is clean, readable, and incredibly powerful. Your application code is now focused on what it needs (the customer data), not how to get it.
Adopting an agentic workflow for data retrieval offers profound benefits beyond just cleaner code.
You've just seen how to transform a standard data query into a secure, scalable, and simple intelligent search API. By treating your data retrieval logic as code and packaging it into agents, you can build faster, more secure, and more maintainable applications.
Ready to stop wrestling with data sources and start building smarter?
Sign up on Searches.do and deploy your first agent in minutes.