In today's fast-paced digital landscape, developers are constantly tasked with building more intelligent and capable applications. While traditional automation is great for repetitive, rule-based tasks, what about the complex, multi-step objectives that usually require human intervention? This is where the next evolution in automation comes in: the autonomous digital worker.
Empower your applications with agentic intelligence. Meet Ivy, your pre-built autonomous digital worker on the .do platform. Ivy is designed to understand and execute complex business goals, turning cumbersome operations into simple, scalable, on-demand services.
This tutorial will show you just how easy it is to integrate Ivy into your existing stack and start delegating complex tasks in just a few lines of code using the .do SDK.
Before we dive into the code, let's clarify what makes an autonomous worker like Ivy so powerful.
Unlike a simple script or a rigid automation bot, an autonomous worker operates on an "agentic" model. This means it can:
Think of it as the difference between giving a team member a rigid, 100-step checklist versus just telling them, "Please research our top three competitors and summarize their marketing strategies." An autonomous worker handles the latter, giving you a powerful new capability to embed directly into your software.
Let's get hands-on. We'll walk through adding Ivy to a standard Node.js/TypeScript project.
First, add the official SDK to your project's dependencies. Open your terminal and run:
npm install @do-inc/sdk
This package is the gateway to the entire .do platform, including the Ivy agent.
Now, in your application code, you can import the Do client and initialize a connection to Ivy. It's as simple as referencing the agent by its name.
import { Do } from '@do-inc/sdk';
// Configure the client with your API key
// (It's best practice to use environment variables for this)
// Do.config({ apiKey: 'YOUR_API_KEY' });
// Initialize a handle for the Ivy agent
const ivy = Do.agent('ivy');
console.log('Successfully connected to Ivy!');
With just two lines of code, your application now has a direct line to a powerful AI agent.
This is where the magic happens. To give Ivy a task, you use the asynchronous run method. You provide an objective-driven prompt and tell Ivy how you want the output delivered.
Let's use the full example from the ivy.do website:
import { Do } from '@do-inc/sdk';
// Initialize the client for the Ivy agent
const ivy = Do.agent('ivy');
// Assign a complex research task to Ivy
const taskResult = await ivy.run({
task: "Analyze Q1 2024 customer feedback and generate a sentiment analysis report.",
output: {
format: "pdf",
path: "./reports/sentiment-analysis-q1.pdf"
}
});
console.log(`Task complete. Report saved to ${taskResult.output.path}.`);
Let's break down the ivy.run() call:
When the await resolves, taskResult will contain information about the completed job, including the path to your newly generated report. That's it! You've successfully delegated a complex business process to an autonomous worker through a simple API call.
The example above is just the beginning. You can integrate Ivy into your workflows to:
By treating complex operations as programmable, on-demand services, you can build smarter, more powerful applications with unprecedented speed.
Q: What is Ivy?
A: Ivy is a pre-built autonomous digital worker on the .do platform. It's designed to understand and execute complex business tasks assigned via API, transforming your operational workflows into programmable, on-demand services.
Q: What kinds of tasks can Ivy perform?
A: Ivy can handle a wide array of business processes, including data analysis, market research, report generation, content summarization, and process automation. Any objective-driven task can be delegated to Ivy.
Q: How does Ivy differ from a standard automation tool?
A: Unlike simple scripts or bots that follow rigid rules, Ivy is an agentic worker. It can reason, plan multi-step actions, and utilize various tools to achieve a given objective, adapting its approach to complete complex tasks autonomously.
Q: How do I integrate Ivy into my business?
A: You can integrate Ivy seamlessly into your existing applications and workflows using the .do platform's simple APIs and SDKs. Treat Ivy as a service that you can call to execute tasks, just like any other modern software API.
Ready to give your application a digital teammate? Visit ivy.do to learn more and get started on the .do platform today.