@vybit/n8n-nodes-vybit 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,215 @@
1
+ # @vybit/n8n-nodes-vybit
2
+
3
+ Official n8n community nodes for [Vybit](https://vybit.net) - the personalized audio notification platform.
4
+
5
+ [![npm version](https://badge.fury.io/js/%40vybit%2Fn8n-nodes-vybit.svg)](https://www.npmjs.com/package/@vybit/n8n-nodes-vybit)
6
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
7
+
8
+ ## Features
9
+
10
+ - 🔐 **Dual Authentication**: OAuth2 for multi-user services or API Key for personal automation
11
+ - 🔔 **Push Notifications**: Send personalized audio notifications from your workflows
12
+ - 📋 **Manage Vybits**: Create, update, and delete vybits programmatically
13
+ - 📊 **View Logs**: Access notification history and analytics
14
+ - 🎵 **Sound Management**: Search and manage custom audio files
15
+ - 👥 **Subscription Management**: Subscribe to and share vybits
16
+ - 🔐 **Peeps Management**: Invite users to follow your vybits and and control access
17
+ - ✅ **Zero Dependencies**: Built with zero runtime dependencies
18
+
19
+ ---
20
+
21
+ ## Installation
22
+
23
+ ### Self-Hosted n8n
24
+
25
+ ```bash
26
+ npm install @vybit/n8n-nodes-vybit
27
+ ```
28
+
29
+ Then restart your n8n instance.
30
+
31
+ <!-- n8n Cloud support coming soon -->
32
+
33
+ ### For Multi-User Deployments
34
+
35
+ See [DEPLOYMENT.md](./DEPLOYMENT.md) for configuring credential sharing in multi-user n8n instances to centrally manage OAuth2 Client Secrets.
36
+
37
+ ---
38
+
39
+ ## Which Authentication Method Should I Use?
40
+
41
+ ### Use **Developer API** (API Key) if:
42
+ - ✅ You're automating your own Vybit account
43
+ - ✅ Building personal workflows (e.g., "alert me when server is down")
44
+ - ✅ Integrating Vybit into your backend service
45
+ - ✅ You need full API access (create vybits, manage sounds, view logs)
46
+
47
+ **Example**: DevOps engineer using n8n to trigger their personal Vybit when monitoring detects issues
48
+
49
+ ### Use **OAuth2** if:
50
+ - ✅ You're building a service where users connect their accounts
51
+ - ✅ Each user needs to authorize their own Vybit account
52
+ - ✅ Multi-tenant scenarios (agency managing client notifications)
53
+ - ✅ Similar to how Zapier/IFTTT integrates with Vybit
54
+
55
+ **Example**: Agency building n8n workflows that send notifications to client Vybit accounts
56
+
57
+ ---
58
+
59
+ ## Quick Start
60
+
61
+ ### Developer API Setup (Personal Automation)
62
+
63
+ 1. Go to [developer.vybit.net](https://developer.vybit.net)
64
+ 2. Generate an API key
65
+ 3. In n8n:
66
+ - Add Vybit node
67
+ - Authentication: "Developer API (For Personal Automation)"
68
+ - Create new credential and paste your API key
69
+ 4. You now have full access to YOUR Vybit account
70
+
71
+ ### OAuth2 Setup (Multi-User Service)
72
+
73
+ 1. Go to [developer.vybit.net](https://developer.vybit.net)
74
+ 2. Configure OAuth2 settings (client ID, redirect URI)
75
+ 3. In n8n:
76
+ - Add Vybit node
77
+ - Authentication: "OAuth2 (For Multi-User Services)"
78
+ - Create OAuth2 credential with your client ID/secret
79
+ 4. Users authorize their Vybit accounts to connect
80
+
81
+ ---
82
+
83
+ ## Available Operations
84
+
85
+ ### Profile Resource (API Key Only)
86
+
87
+ | Operation | Description |
88
+ |-----------|-------------|
89
+ | **Get Profile** | View account information |
90
+ | **Get Usage Metrics** | View current usage and tier limits |
91
+ | **Check API Status** | Check API service health |
92
+
93
+ ### Vybits Resource
94
+
95
+ | Operation | OAuth2 | API Key | Description |
96
+ |-----------|--------|---------|-------------|
97
+ | **List** | ✅ | ✅ | Get all vybits |
98
+ | **Get** | ❌ | ✅ | Get vybit details |
99
+ | **Create** | ❌ | ✅ | Create a new vybit |
100
+ | **Update** | ❌ | ✅ | Update vybit settings |
101
+ | **Delete** | ❌ | ✅ | Delete a vybit |
102
+ | **Trigger** | ✅ | ✅ | Send a notification |
103
+
104
+ ### Logs Resource (API Key Only)
105
+
106
+ | Operation | Description |
107
+ |-----------|-------------|
108
+ | **List All** | View all notification logs |
109
+ | **Get** | Get specific log entry details |
110
+ | **List by Vybit** | View logs for a specific vybit |
111
+ | **List by Subscription** | View logs for a subscription |
112
+
113
+ ### Sounds Resource (API Key Only)
114
+
115
+ | Operation | Description |
116
+ |-----------|-------------|
117
+ | **Search** | Search available sounds |
118
+ | **Get** | Get sound details |
119
+
120
+ ### Peeps Resource (API Key Only)
121
+
122
+ | Operation | Description |
123
+ |-----------|-------------|
124
+ | **List All** | View all peep invitations |
125
+ | **List by Vybit** | View peeps for a specific vybit |
126
+ | **Invite** | Invite a user to a vybit |
127
+ | **Get** | Get peep details |
128
+ | **Delete** | Remove a peep invitation |
129
+
130
+ ### Subscriptions Resource (API Key Only)
131
+
132
+ | Operation | Description |
133
+ |-----------|-------------|
134
+ | **List Public Vybits** | Browse publicly available vybits |
135
+ | **Get Public Vybit** | Get details of a public vybit |
136
+ | **Subscribe** | Subscribe to a vybit |
137
+ | **List My Subscriptions** | Get your subscriptions |
138
+ | **Get Subscription** | Get subscription details |
139
+ | **Update Subscription** | Update subscription settings |
140
+ | **Unsubscribe** | Unsubscribe from a vybit |
141
+ | **Send to Owner** | Send notification to vybit owner |
142
+ | **Send to Group** | Send notification to all subscribers |
143
+
144
+ ---
145
+
146
+ ## Example Workflows
147
+
148
+ ### Trigger Alert on Server Error
149
+
150
+ ```
151
+ Webhook (error event)
152
+ → Vybit (Trigger)
153
+ ```
154
+
155
+ ### Daily Summary Notification
156
+
157
+ ```
158
+ Schedule (daily at 9am)
159
+ → HTTP Request (fetch metrics)
160
+ → Vybit (Trigger with summary)
161
+ ```
162
+
163
+ ### Create Vybit from Airtable
164
+
165
+ ```
166
+ Airtable Trigger (new record)
167
+ → Vybit (Create vybit)
168
+ → Vybit (Trigger, send notification)
169
+ ```
170
+
171
+ ---
172
+
173
+ ## Development
174
+
175
+ This package bundles `@vybit/api-sdk` and `@vybit/oauth2-sdk` to meet n8n's verified node requirements (zero runtime dependencies).
176
+
177
+ ### Building
178
+
179
+ ```bash
180
+ npm run build
181
+ ```
182
+
183
+ ### Testing Locally
184
+
185
+ ```bash
186
+ npm link
187
+ cd /path/to/n8n
188
+ npm link @vybit/n8n-nodes-vybit
189
+ n8n start
190
+ ```
191
+
192
+ ---
193
+
194
+ ## Resources
195
+
196
+ - 📖 [Developer API Documentation](https://developer.vybit.net/api-reference)
197
+ - 🔐 [OAuth2 Documentation](https://developer.vybit.net/oauth-reference)
198
+ - 💬 [Support](mailto:developer@vybit.net)
199
+ - 🐛 [Report Issues](https://gitlab.com/flatirontek/vybit-sdk/-/issues)
200
+
201
+ ---
202
+
203
+ ## Related Packages
204
+
205
+ Part of the Vybit SDK monorepo:
206
+
207
+ - [@vybit/api-sdk](https://www.npmjs.com/package/@vybit/api-sdk) - Developer API client
208
+ - [@vybit/oauth2-sdk](https://www.npmjs.com/package/@vybit/oauth2-sdk) - OAuth2 client
209
+ - [@vybit/mcp-server](https://www.npmjs.com/package/@vybit/mcp-server) - MCP server for AI assistants
210
+
211
+ ---
212
+
213
+ ## License
214
+
215
+ MIT © Flatirontek LLC
@@ -0,0 +1,47 @@
1
+ class VybitApi {
2
+ constructor() {
3
+ this.name = "vybitApi";
4
+ this.displayName = "API Key";
5
+ this.documentationUrl = "https://developer.vybit.net/api-reference";
6
+ // Key description for users
7
+ this.description = "Advanced: Use your Vybit Developer API key for full programmatic access. Get your API key from developer.vybit.net";
8
+ this.properties = [
9
+ {
10
+ displayName: "API Key",
11
+ name: "apiKey",
12
+ type: "string",
13
+ typeOptions: {
14
+ password: true
15
+ },
16
+ default: "",
17
+ required: true,
18
+ description: 'Your Vybit Developer API key from <a href="https://developer.vybit.net" target="_blank">developer.vybit.net</a>. For different environments (dev, staging, production), create separate Vybit accounts and use different API keys.'
19
+ },
20
+ {
21
+ displayName: "Base URL",
22
+ name: "baseUrl",
23
+ type: "string",
24
+ default: "https://api.vybit.net/v1",
25
+ required: true,
26
+ description: "The Vybit API base URL (default: https://api.vybit.net/v1). Use the production API with different API keys for different environments."
27
+ }
28
+ ];
29
+ this.authenticate = {
30
+ type: "generic",
31
+ properties: {
32
+ headers: {
33
+ "X-API-Key": "={{$credentials.apiKey}}"
34
+ }
35
+ }
36
+ };
37
+ this.test = {
38
+ request: {
39
+ baseURL: "={{$credentials.baseUrl}}",
40
+ url: "/status",
41
+ method: "GET"
42
+ }
43
+ };
44
+ }
45
+ }
46
+
47
+ export { VybitApi };
@@ -0,0 +1,84 @@
1
+ class VybitOAuth2Api {
2
+ constructor() {
3
+ this.name = "vybitOAuth2Api";
4
+ this.displayName = "OAuth2 Token";
5
+ this.documentationUrl = "https://developer.vybit.net/oauth-reference";
6
+ // Key description for users
7
+ this.description = "Connect your Vybit account to n8n. You will be asked to authorize access to your vybits.";
8
+ this.extends = ["oAuth2Api"];
9
+ this.properties = [
10
+ {
11
+ displayName: "Grant Type",
12
+ name: "grantType",
13
+ type: "hidden",
14
+ default: "authorizationCode"
15
+ },
16
+ {
17
+ displayName: "Authorization URL",
18
+ name: "authUrl",
19
+ type: "hidden",
20
+ default: "https://app.vybit.net"
21
+ },
22
+ {
23
+ displayName: "Access Token URL",
24
+ name: "accessTokenUrl",
25
+ type: "hidden",
26
+ default: "https://app.vybit.net/service/token"
27
+ },
28
+ {
29
+ displayName: "Scope",
30
+ name: "scope",
31
+ type: "hidden",
32
+ default: ""
33
+ },
34
+ {
35
+ displayName: "Auth URI Query Parameters",
36
+ name: "authQueryParameters",
37
+ type: "hidden",
38
+ default: ""
39
+ },
40
+ {
41
+ displayName: "Client ID",
42
+ name: "clientId",
43
+ type: "string",
44
+ default: "",
45
+ required: true,
46
+ description: 'OAuth2 Client ID from <a href="https://developer.vybit.net" target="_blank">developer.vybit.net</a>'
47
+ },
48
+ {
49
+ displayName: "Client Secret",
50
+ name: "clientSecret",
51
+ type: "string",
52
+ typeOptions: {
53
+ password: true
54
+ },
55
+ default: "",
56
+ required: true,
57
+ description: "OAuth2 Client Secret from your Vybit developer portal"
58
+ },
59
+ {
60
+ displayName: "Authentication",
61
+ name: "authentication",
62
+ type: "hidden",
63
+ default: "body"
64
+ }
65
+ ];
66
+ this.authenticate = {
67
+ type: "generic",
68
+ properties: {
69
+ headers: {
70
+ Authorization: "=Bearer {{$credentials.accessToken}}"
71
+ }
72
+ }
73
+ };
74
+ this.test = {
75
+ request: {
76
+ baseURL: "https://app.vybit.net",
77
+ url: "/service/test",
78
+ method: "GET"
79
+ }
80
+ };
81
+ }
82
+ }
83
+
84
+ export { VybitOAuth2Api };