Skip to content

Commit 3d75d36

Browse files
committed
Add Airweave app with 7 actions for semantic search and collection management.
- Search Collection: semantic + keyword search across data sources - List/Create/Get/Delete Collections - List Available Sources - Trigger Source Connection Sync Includes full @airweave/sdk integration, dynamic dropdowns, and comprehensive documentation.
1 parent 84fcc91 commit 3d75d36

File tree

10 files changed

+543
-0
lines changed

10 files changed

+543
-0
lines changed

components/airweave/README.md

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
# Airweave Integration for Pipedream
2+
3+
Airweave is an open-source platform that makes **any app searchable for your agent** by syncing data from various sources with minimal configuration for agentic search.
4+
5+
## What is Airweave?
6+
7+
Airweave serves as a bridge between your data sources and agents, transforming raw data into queryable knowledge. It can extract and process data from:
8+
9+
- API endpoints (REST)
10+
- Productivity and collaboration tools
11+
- Relational databases
12+
- Document stores
13+
- File systems and storage services
14+
15+
## Available Actions
16+
17+
### Collections
18+
- **Search Collection** - Search across all data sources within a collection (semantic + keyword search)
19+
- **List Collections** - Get all collections in your organization
20+
- **Create Collection** - Create a new collection to group data sources
21+
- **Get Collection** - Retrieve details of a specific collection
22+
- **Delete Collection** - Permanently remove a collection and all associated data
23+
24+
### Sources
25+
- **List Sources** - Get all available data source connectors
26+
- **Trigger Sync** - Manually trigger a data sync for a source connection
27+
28+
## Setup
29+
30+
1. Sign up for an Airweave account at [airweave.ai](https://airweave.ai)
31+
2. Get your API key from the Airweave dashboard (Settings → API Keys)
32+
3. Connect your Airweave account in Pipedream by entering your API key
33+
34+
## Example Workflows
35+
36+
### Slack Q&A Bot
37+
Slash command → Search Airweave collection → Reply with relevant information
38+
39+
### Support Automation
40+
Form submission → Search documentation → Create support ticket with context
41+
42+
### Daily Digest
43+
Cron schedule → Search recent updates → Send email summary
44+
45+
### GitHub Integration
46+
New issue → Search codebase → Auto-comment with relevant code references
47+
48+
## Authentication
49+
50+
This integration uses API key authentication. You can find your API key in your Airweave dashboard under Settings → API Keys.
51+
52+
Optionally, you can specify a custom base URL if you're using a self-hosted Airweave instance.
53+
54+
## Links
55+
56+
- [Airweave Documentation](https://docs.airweave.ai)
57+
- [Airweave GitHub](https://github.com/airweave-ai/airweave)
58+
- [API Reference](https://docs.airweave.ai/api-reference)
59+
- [Airweave TypeScript SDK](https://github.com/airweave-ai/typescript-sdk)
60+
61+
## Support
62+
63+
For issues or questions:
64+
- Airweave Community: [GitHub Discussions](https://github.com/airweave-ai/airweave/discussions)
65+
- Pipedream Support: [pipedream.com/support](https://pipedream.com/support)
66+
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-create-collection",
5+
name: "Create Collection",
6+
description: "Create a new Airweave collection. Collections are logical groups of data sources that provide unified search capabilities. The newly created collection is initially empty until you add source connections to it. [See the documentation](https://docs.airweave.ai/api-reference/collections/create)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
name: {
12+
type: "string",
13+
label: "Name",
14+
description: "Display name for the collection (e.g., 'Customer Support Data')",
15+
},
16+
readableId: {
17+
type: "string",
18+
label: "Readable ID",
19+
description: "URL-friendly identifier for the collection (lowercase, hyphens allowed, e.g., 'customer-support-data'). This cannot be changed after creation.",
20+
},
21+
description: {
22+
type: "string",
23+
label: "Description",
24+
description: "Optional description of what this collection contains and its purpose",
25+
optional: true,
26+
},
27+
},
28+
async run({ $ }) {
29+
const response = await this.airweave.createCollection({
30+
name: this.name,
31+
readable_id: this.readableId,
32+
description: this.description,
33+
});
34+
35+
$.export("$summary", `Successfully created collection: ${response.name} (${response.readable_id})`);
36+
37+
return response;
38+
},
39+
};
40+
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-delete-collection",
5+
name: "Delete Collection",
6+
description: "Delete a collection and all associated data. This permanently removes the collection including all synced data and source connections. This action cannot be undone. [See the documentation](https://docs.airweave.ai/api-reference/collections/delete)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
collectionId: {
12+
propDefinition: [
13+
airweave,
14+
"collectionId",
15+
],
16+
},
17+
confirmation: {
18+
type: "string",
19+
label: "Confirmation",
20+
description: "Type 'DELETE' to confirm deletion. This action cannot be undone.",
21+
},
22+
},
23+
async run({ $ }) {
24+
if (this.confirmation !== "DELETE") {
25+
throw new Error("Please type 'DELETE' to confirm deletion. This action cannot be undone.");
26+
}
27+
28+
const response = await this.airweave.deleteCollection(this.collectionId);
29+
30+
$.export("$summary", `Successfully deleted collection: ${response.name} (${response.readable_id})`);
31+
32+
return response;
33+
},
34+
};
35+
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-get-collection",
5+
name: "Get Collection",
6+
description: "Retrieve details of a specific collection by its readable ID. [See the documentation](https://docs.airweave.ai/api-reference/collections/get)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
collectionId: {
12+
propDefinition: [
13+
airweave,
14+
"collectionId",
15+
],
16+
},
17+
},
18+
async run({ $ }) {
19+
const response = await this.airweave.getCollection(this.collectionId);
20+
21+
$.export("$summary", `Successfully retrieved collection: ${response.name} (${response.readable_id})`);
22+
23+
return response;
24+
},
25+
};
26+
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-list-collections",
5+
name: "List Collections",
6+
description: "List all collections in your organization. Collections are logical groups of data sources that provide unified search capabilities. [See the documentation](https://docs.airweave.ai/api-reference/collections/list)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
skip: {
12+
type: "integer",
13+
label: "Skip",
14+
description: "Number of collections to skip for pagination",
15+
optional: true,
16+
default: 0,
17+
min: 0,
18+
},
19+
limit: {
20+
type: "integer",
21+
label: "Limit",
22+
description: "Maximum number of collections to return",
23+
optional: true,
24+
default: 50,
25+
min: 1,
26+
max: 100,
27+
},
28+
},
29+
async run({ $ }) {
30+
const response = await this.airweave.listCollections({
31+
skip: this.skip,
32+
limit: this.limit,
33+
});
34+
35+
const count = response.length;
36+
$.export("$summary", `Successfully retrieved ${count} collection(s)`);
37+
38+
return response;
39+
},
40+
};
41+
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-list-sources",
5+
name: "List Available Sources",
6+
description: "List all available data source connectors. These are the types of integrations Airweave can connect to (e.g., GitHub, Slack, Google Drive, PostgreSQL, etc.). [See the documentation](https://docs.airweave.ai/api-reference/sources/list)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
},
12+
async run({ $ }) {
13+
const response = await this.airweave.listSources();
14+
15+
const count = response.length;
16+
$.export("$summary", `Successfully retrieved ${count} available source connector(s)`);
17+
18+
return response;
19+
},
20+
};
21+
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-search-collection",
5+
name: "Search Collection",
6+
description: "Search across all data sources within a collection using semantic and keyword search. [See the documentation](https://docs.airweave.ai/api-reference/collections/search)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
collectionId: {
12+
propDefinition: [
13+
airweave,
14+
"collectionId",
15+
],
16+
},
17+
searchQuery: {
18+
propDefinition: [
19+
airweave,
20+
"searchQuery",
21+
],
22+
},
23+
searchLimit: {
24+
propDefinition: [
25+
airweave,
26+
"searchLimit",
27+
],
28+
},
29+
responseType: {
30+
propDefinition: [
31+
airweave,
32+
"responseType",
33+
],
34+
},
35+
offset: {
36+
type: "integer",
37+
label: "Offset",
38+
description: "Number of results to skip for pagination",
39+
optional: true,
40+
default: 0,
41+
min: 0,
42+
},
43+
recencyBias: {
44+
type: "string",
45+
label: "Recency Bias",
46+
description: "How much to weigh recency vs similarity (0-1). 0 = no recency effect; 1 = rank by recency only",
47+
optional: true,
48+
},
49+
},
50+
async run({ $ }) {
51+
const params = {
52+
query: this.searchQuery,
53+
limit: this.searchLimit,
54+
offset: this.offset,
55+
};
56+
57+
if (this.responseType) {
58+
params.response_type = this.responseType;
59+
}
60+
61+
if (this.recencyBias !== undefined) {
62+
params.recency_bias = parseFloat(this.recencyBias);
63+
}
64+
65+
const response = await this.airweave.searchCollection(
66+
this.collectionId,
67+
params,
68+
);
69+
70+
const resultCount = response.results?.length || 0;
71+
$.export("$summary", `Successfully searched collection "${this.collectionId}" and found ${resultCount} result(s)`);
72+
73+
return response;
74+
},
75+
};
76+
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
import airweave from "../../airweave.app.mjs";
2+
3+
export default {
4+
key: "airweave-trigger-sync",
5+
name: "Trigger Source Connection Sync",
6+
description: "Manually trigger a data sync for a source connection. The sync job runs asynchronously in the background and returns immediately with job details. [See the documentation](https://docs.airweave.ai/api-reference/source-connections/run)",
7+
version: "0.0.1",
8+
type: "action",
9+
props: {
10+
airweave,
11+
collectionId: {
12+
propDefinition: [
13+
airweave,
14+
"collectionId",
15+
],
16+
description: "The collection that contains the source connection",
17+
},
18+
sourceConnectionId: {
19+
propDefinition: [
20+
airweave,
21+
"sourceConnectionId",
22+
(c) => ({
23+
collectionId: c.collectionId,
24+
}),
25+
],
26+
},
27+
},
28+
async run({ $ }) {
29+
const response = await this.airweave.runSourceConnection(
30+
this.sourceConnectionId,
31+
);
32+
33+
$.export("$summary", `Successfully triggered sync job: ${response.id} (Status: ${response.status})`);
34+
35+
return response;
36+
},
37+
};
38+

0 commit comments

Comments
 (0)