Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
16 changes: 8 additions & 8 deletions .github/workflows/CI-API.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ on:
- "[0-9]+.[0-9]+.[0-9]+"
paths:
- .github/workflows/CI-API.yaml
- "api/**"
- "cache/**"
- "entities/**"
- "unified/**"
- Cargo.lock
- Dockerfile.common
- api/Dockerfile
- "core/api/**"
- "core/cache/**"
- "core/osentities/**"
- "core/unified/**"
- core/Cargo.lock
- core/Dockerfile.common
- core/api/Dockerfile

env:
docker_image_tag: ${{ github.ref == 'refs/heads/main' && github.sha || github.ref_name }}
Expand All @@ -32,7 +32,7 @@ jobs:
image: "us-docker.pkg.dev/integrationos/docker-oss/api:${{ env.docker_image_tag }}"
service_account: github-actions@integrationos.iam.gserviceaccount.com
workload_identity_provider: projects/356173785332/locations/global/workloadIdentityPools/github-actions/providers/github-actions
file: api/Dockerfile
file: core/api/Dockerfile
context: .
build-args: |
"EXECUTABLE=api"
12 changes: 6 additions & 6 deletions .github/workflows/CI-ARCHIVER.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ on:
- "[0-9]+.[0-9]+.[0-9]+"
paths:
- .github/workflows/CI-ARCHIVER.yaml
- "domain/**"
- "archiver/**"
- Cargo.lock
- Dockerfile.common
- archiver/Dockerfile
- "core/osentities/domain/**"
- "core/archiver/**"
- core/Cargo.lock
- core/Dockerfile.common
- core/archiver/Dockerfile

env:
docker_image_tag: ${{ github.ref == 'refs/heads/main' && github.sha || github.ref_name }}
Expand All @@ -31,7 +31,7 @@ jobs:
image: "us-docker.pkg.dev/integrationos/docker-oss/archiver:${{ env.docker_image_tag }}"
service_account: github-actions@integrationos.iam.gserviceaccount.com
workload_identity_provider: projects/356173785332/locations/global/workloadIdentityPools/github-actions/providers/github-actions
file: archiver/Dockerfile
file: core/archiver/Dockerfile
context: .
build-args: |
"EXECUTABLE=archiver"
12 changes: 6 additions & 6 deletions .github/workflows/CI-DATABASE.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ on:
- "[0-9]+.[0-9]+.[0-9]+"
paths:
- .github/workflows/CI-DATABASE.yaml
- "domain/**"
- "database/**"
- Cargo.lock
- Dockerfile.common
- database/Dockerfile
- "core/osentities/domain/**"
- "core/database/**"
- core/Cargo.lock
- core/Dockerfile.common
- core/database/Dockerfile

env:
docker_image_tag: ${{ github.ref == 'refs/heads/main' && github.sha || github.ref_name }}
Expand All @@ -30,7 +30,7 @@ jobs:
image: "us-docker.pkg.dev/integrationos/docker-oss/database:${{ env.docker_image_tag }}"
service_account: github-actions@integrationos.iam.gserviceaccount.com
workload_identity_provider: projects/356173785332/locations/global/workloadIdentityPools/github-actions/providers/github-actions
file: database/Dockerfile
file: core/database/Dockerfile
context: .
build-args: |
"EXECUTABLE=database"
6 changes: 3 additions & 3 deletions .github/workflows/CI-OAUTH.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- "[0-9]+.[0-9]+.[0-9]+"
paths:
- .github/workflows/CI-OAUTH.yaml
- "oauth/**"
- "core/oauth/**"

env:
docker_image_tag: ${{ github.ref == 'refs/heads/main' && github.sha || github.ref_name }}
Expand All @@ -23,8 +23,8 @@ jobs:
- uses: actions/checkout@v3
- uses: integration-os/google-artifact-registry-action@v2
with:
context: oauth
file: oauth/Dockerfile
context: core/oauth
file: core/oauth/Dockerfile
image: "us-docker.pkg.dev/integrationos/docker-oss/platform-oauth:${{ env.docker_image_tag }}"
service_account: github-actions@integrationos.iam.gserviceaccount.com
workload_identity_provider: projects/356173785332/locations/global/workloadIdentityPools/github-actions/providers/github-actions
8 changes: 4 additions & 4 deletions .github/workflows/CI-SEED.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ on:
- "[0-9]+.[0-9]+.[0-9]+"
paths:
- .github/workflows/CI-SEED.yaml
- "resources/Dockerfile"
- "resources/seed/**"
- "core/resources/Dockerfile"
- "core/resources/seed/**"

env:
docker_image_tag: ${{ github.ref == 'refs/heads/main' && github.sha || github.ref_name }}
Expand All @@ -27,5 +27,5 @@ jobs:
image: "us-docker.pkg.dev/integrationos/docker-oss/seed-data:${{ env.docker_image_tag }}"
service_account: github-actions@integrationos.iam.gserviceaccount.com
workload_identity_provider: projects/356173785332/locations/global/workloadIdentityPools/github-actions/providers/github-actions
context: resources
file: resources/Dockerfile
context: core/resources
file: core/resources/Dockerfile
14 changes: 7 additions & 7 deletions .github/workflows/CI-WATCHDOG.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ on:
- "[0-9]+.[0-9]+.[0-9]+"
paths:
- .github/workflows/CI-WATCHDOG.yaml
- "cache/**"
- "domain/**"
- "watchdog/**"
- Cargo.lock
- Dockerfile.common
- watchdog/Dockerfile
- "core/cache/**"
- "core/osentities/domain/**"
- "core/watchdog/**"
- core/Cargo.lock
- core/Dockerfile.common
- core/watchdog/Dockerfile

env:
docker_image_tag: ${{ github.ref == 'refs/heads/main' && github.sha || github.ref_name }}
Expand All @@ -31,7 +31,7 @@ jobs:
image: "us-docker.pkg.dev/integrationos/docker-oss/watchdog:${{ env.docker_image_tag }}"
service_account: github-actions@integrationos.iam.gserviceaccount.com
workload_identity_provider: projects/356173785332/locations/global/workloadIdentityPools/github-actions/providers/github-actions
file: watchdog/Dockerfile
file: core/watchdog/Dockerfile
context: .
build-args: |
"EXECUTABLE=watchdog"
163 changes: 72 additions & 91 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<p align="center">
<a href="https://picaos.com">
<img alt="Pica Logo" src="./resources/images/banner.svg" style="border-radius: 10px;">
<img alt="Pica Logo" src="https://assets.picaos.com/github/header.svg" style="border-radius: 10px;">
</a>
</p>

<p align="center"><b>Pica, The AI Integrations Solution</b></p>
<p align="center"><b>Pica</b> - <i>Ensuring outcomes for the AI-first world</i></p>

<p align="center">
<b>
<a href="https://www.picaos.com/">Website</a>
<a href="https://www.picaos.com">Website</a>
·
<a href="https://docs.picaos.com">Documentation</a>
·
Expand All @@ -24,133 +24,114 @@

---

Pica gives every builder instant, reliable access to the tools they need—no keys, no configs, no headaches.
Connect LLMs to 25,000+ actions with Pica-verified knowledge and developer-friendly SDKs. No keys, no configs, no headaches.

## Why Pica?
Pica makes it simple to build and manage AI agents with 3 key products:
1. **OneTool**: Connect agents to over [150+ integrations](https://picaos.com/integrations) with a single SDK. Zero-shot execution that gets smarter with every use.
2. **AuthKit**: Streamline authentication for multi-tenant applications with secure, end-to-end OAuth flows and automated token management. Handles the complexity of authentication so you don't have to.
3. **BuildKit**: Create AI tools for integrations or empower vibe coding with integrations that work zero-shot.

Pica simplifies AI agent development with our four core products:
Built in Rust for blazing speed and ultra-low latency execution. Full logging and action traceability gives developers complete visibility into their agents' decisions and activities. Our tools simplify building and running AI agents so developers can focus on results.

✅ OneTool – Connect agents to [100+ APIs and tools](https://app.picaos.com/tools) with a single SDK. <br/>
✅ AuthKit – Secure authentication for seamless tool integration. <br/>
✅ BuildKit - Empower vibe coding with integrations that work zero-shot.
# Getting started 👋

Pica also provides full logging and action traceability, giving developers complete visibility into their agents’ decisions and activities. Our tools simplify building and running AI agents so developers can focus on results.
Follow this tutorial to build a tool to fetch your Gmail emails in under 5 minutes.

## Getting started
> 📖 **Full Demo**: For a comprehensive walkthrough with all IDE and framework options, visit [buildkit.picaos.com](https://buildkit.picaos.com)

### Install
> 🎥 **Demo Video**: Watch the [4-minute tutorial](https://youtu.be/EnbRfu-BsJE)

```bash
npm install @picahq/ai
```

### Setup
## What we'll do:

1. Create a new [Pica account](https://app.picaos.com)
2. Create a Connection via the [Dashboard](https://app.picaos.com/connections)
3. Create an [API key](https://app.picaos.com/settings/api-keys)
4. Set the API key as an environment variable: `PICA_SECRET_KEY=<your-api-key>`
1. Install the Pica MCP Server
2. Connect your Gmail account
3. Set up a starter project with Vercel AI SDK
4. Add some rules for the LLMs to understand BuildKit
5. Prompt the LLM to build your tool

### Example Usage
## Step 1: Install the Pica MCP Server

Below is an example demonstrating how to integrate the [Pica OneTool](https://www.npmjs.com/package/@picahq/ai) with the [Vercel AI SDK](https://www.npmjs.com/package/ai) for a GitHub use case:
In the Cursor menu, select "MCP Settings" and update the MCP JSON file to include the following:

```typescript
import { openai } from "@ai-sdk/openai";
import { generateText } from "ai";
import { Pica } from "@picahq/ai";
import * as dotenv from "dotenv";
dotenv.config();

const pica = new Pica(process.env.PICA_SECRET_KEY!, {
connectors: ["*"]
});

async function runAgentTask(message: string): Promise<string> {
const system = await pica.generateSystemPrompt();
```json
{
"mcpServers": {
"pica": {
"command": "npx",
"args": ["@picahq/mcp"],
"env": {
"PICA_SECRET": "your-pica-secret-key"
}
}
}
}
```

const { text } = await generateText({
model: openai("gpt-4.1"),
system,
prompt: message,
tools: { ...pica.oneTool },
maxSteps: 10,
});
**Note:** Replace `your-pica-secret-key` with your actual Pica secret key from the dashboard: [Get API Key](https://app.picaos.com/settings/api-keys)

return text;
}
## Step 2: Connect your Gmail account

runAgentTask("Star the repo picahq/pica with github")
.then((text) => {
console.log(text);
})
.catch(console.error);
```
Now we need to connect your Gmail account so we can test our tool after we build it.

[![Try with Replit Badge](https://replit.com/badge?caption=Try%20with%20Replit)](https://replit.com/@picahq/Pica-or-GitHub-Star-Demo)
[**Add Gmail Connection →**](https://app.picaos.com/connections)

## Step 3: Set up a starter project

For more use cases, visit our [Use Cases Library](https://www.picaos.com/community/use-cases) or our [Awesome Pica Repository](https://github.com/picahq/awesome-pica).
#### 1. Clone and install dependencies

### Next.js Integration
```bash
git clone https://github.com/picahq/buildkit-vercel-ai-starter.git && cd buildkit-vercel-ai-starter
```

⭐️ You can see a full Next.js demo [here](https://github.com/picahq/onetool-demo)
```bash
npm install
```

#### 2. Set up environment variables

> For more examples and detailed documentation, check out our [SDK documentation](https://docs.picaos.com/sdk/vercel-ai).
Create a `.env.local` file in the root directory:

---
```env
OPENAI_API_KEY=your_openai_api_key_here
```

## Running Pica locally
#### 3. Run the development server

> [!IMPORTANT]
> The Pica dashboard is going open source! Stay tuned for the big release 🚀
```bash
npm run dev
```

### Prerequisites
#### 4. Open your browser

* [Docker](https://docs.docker.com/engine/)
* [Docker Compose](https://docs.docker.com/compose/)
Navigate to `http://localhost:3000` to see the chat interface.

### Step 1: Install the Pica CLI
## Step 4: Add some rules for the LLMs to understand BuildKit

```sh
npm install -g @picahq/cli
```
### BuildKit Rules for Cursor

### Step 2: Initialize the Pica CLI
Create a `.cursor/rules/buildkit.mdc` file in the root of your project and copy the rules from our local file:

To generate the configuration file, run:
📋 **Copy the rules**: [buildkit/rules/cursor/buildkit.mdc](buildkit/rules/cursor/buildkit.mdc)

```shell
pica init
```
### ✅ Verify Setup

### Step 3: Start the Pica Server
You can verify setup by asking "What connections do I have in Pica?" - it should show your Gmail connection.

```sh
pica start
```
## Step 5: Prompt the LLM to build your tool

> All the inputs are required. Seeding is optional, but recommended when running the command for the first time.
Now you can ask Cursor to build a Gmail tool for you! Copy this prompt:

##### Example
> Create me a tool called fetchGmailEmails in my Vercel AI SDK agent for fetching my Gmail unread emails and returning the content using BuildKit

```Shell
# To start the docker containers
pica start
Enter the IOS Crypto Secret (32 characters long): xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Do you want to seed? (Y/N) y
```
🎉 **You now have a working AI tool to fetch your Gmail unread emails in under 5 minutes!**

**The Pica API will be available at `http://localhost:3005` 🚀**
---

To stop the docker containers, simply run:
## 🚀 What's Next?

```Shell
pica stop
```
Ready to build more AI tools? Pica connects to 150+ platforms with zero-shot execution.

**🔗 [Explore All Integrations](https://buildkit.picaos.com/integrations)** - Discover integrations for HubSpot, Salesforce, Slack, GitHub, and more

## License
**⚡ [Launch Pica Dashboard](https://app.picaos.com)** - Manage connections, support multi-tenant authentication, monitor usage, and scale your AI agents

Pica is released under the [**GPL-3.0 license**](LICENSE).
9 changes: 9 additions & 0 deletions buildkit/rules/claude/CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Pica BuildKit – LLM Rules

**Role**
You are an expert integration developer working with **Pica MCP**. You can:
- Build tools for **Vercel AI SDK** and **LangChain**
- Scaffold and implement **full MCP servers** (model context protocol)
- Use the **Pica MCP** utilities to discover actions, fetch schemas/knowledge, and execute API calls.

Before you write ANY code you read ALL of buildkit-rules.md to understand how to use BuildKit in your code.
Loading
Loading