Connectors
अपने ऐप को Slack, Resend, और ElevenLabs जैसी third-party सेवाओं से जोड़ें। Credentials एन्क्रिप्टेड होते हैं और actions पहले से authenticated होते हैं।
Connectors की मदद से तुम code में raw API keys मैनेज किए बिना अपने ऐप में बाहरी सेवाओं को integrate कर सकते हो। एक बार connection सेट करो, उसे अपने project से bind करो, और Proyecta SDK के ज़रिए अपने ऐप से pre-built actions को call करो। Credentials rest पर encrypted रहते हैं और कभी भी तुम्हारे frontend code के सामने expose नहीं होते।
उपलब्ध connectors
Section titled “उपलब्ध connectors”| Connector | Category | Auth type | यह क्या करता है |
|---|---|---|---|
| Resend | Communications | API key | Transactional email भेजना, batch emails भेजना, verified domains की सूची देखना |
| Slack | Communications | OAuth | Messages post करना, channels और users की सूची देखना, messages पर react करना, threads पढ़ना |
| ElevenLabs | AI | API key | Text-to-speech, उपलब्ध voices की सूची देखना, sound effects generate करना |
नए connectors नियमित रूप से जोड़े जा रहे हैं।
Connectors कैसे काम करते हैं
Section titled “Connectors कैसे काम करते हैं”- तुम एक connection बनाते हो — credentials देते हो (एक API key या OAuth के ज़रिए sign in)
- तुम connection को एक project से bind करते हो — इससे project को उन credentials को इस्तेमाल करने की अनुमति मिलती है
- तुम्हारा ऐप actions call करता है — SDK Proyecta Cloud के ज़रिए request भेजता है, जो server-side पर credentials inject करता है
तुम्हारा ऐप code कभी भी raw API key या OAuth token को directly नहीं छूता। Connector system authentication, rate limiting, और audit logging खुद संभालता है।
Connector सेट करना
Section titled “Connector सेट करना”- Builder में अपना project खोलो
- Settings > Connectors पर जाओ
- Catalog में से कोई connector चुनो (जैसे, Resend)
- अपने credentials दर्ज करो:
- API key connectors (Resend, ElevenLabs): अपनी secret key paste करो
- OAuth connectors (Slack): Sign in करो और access authorize करो
- Connection को एक नाम दो (जैसे, “Production Resend”)
- Connection अपने आप test होती है और valid होने पर Active मार्क हो जाती है
अपने ऐप में connector का उपयोग करना
Section titled “अपने ऐप में connector का उपयोग करना”Connector actions को Proyecta SDK का उपयोग करके server-side code (Convex actions) से call किया जाता है:
'use node';import { action } from './_generated/server';import { v } from 'convex/values';import Proyecta from '@proyecta-ai/sdk';
const proyecta = new Proyecta({ apiKey: process.env.PROYECTA_API_KEY ?? null });
export const notifySlack = action({ args: { message: v.string(), }, handler: async (ctx, args) => { const result = await proyecta.connectors.execute({ connectorId: 'slack', actionId: 'postMessage', input: { channel: '#general', text: args.message, }, }); return result.output; },});execute method यह return करती है:
| Field | विवरण |
|---|---|
output | Action की return value (shape action पर निर्भर करती है) |
durationMs | Milliseconds में execution time |
invocationId | Audit log entry ID |
AI से इसे wire करवाओ
Section titled “AI से इसे wire करवाओ”तुम्हें connector code खुद लिखने की ज़रूरत नहीं है। AI builder जानता है कि तुम्हारे project से कौन-से connectors bound हैं और तुम्हारे लिए integration generate कर सकता है:
"Send a welcome email when users sign up"— Resend connector का उपयोग करता है"Post a Slack message when a new order comes in"— Slack connector का उपयोग करता है"Play audio narration on the article page"— ElevenLabs connector का उपयोग करता है
Connector actions reference
Section titled “Connector actions reference”Resend
Section titled “Resend”| Action | Side effects | विवरण |
|---|---|---|
sendEmail | write | एक single transactional email भेजना |
sendBatch | write | एक साथ कई emails भेजना |
listDomains | read | Verified sending domains की सूची देखना |
| Action | Side effects | विवरण |
|---|---|---|
postMessage | write | किसी channel में message post करना |
listChannels | read | Workspace में channels की सूची देखना |
listUsers | read | Workspace members की सूची देखना |
reactToMessage | write | Emoji reaction जोड़ना |
getThread | read | Thread में replies देखना |
ElevenLabs
Section titled “ElevenLabs”| Action | Side effects | विवरण |
|---|---|---|
textToSpeech | write | Text को speech audio में convert करना |
listVoices | read | उपलब्ध voices की सूची देखना |
generateSoundEffect | write | AI sound effect generate करना |
Connection statuses
Section titled “Connection statuses”| Status | अर्थ |
|---|---|
| Active | Credentials valid हैं और connection उपयोग के लिए तैयार है |
| Broken | Credentials expire हो गए या revoke कर दिए गए — restore करने के लिए उन्हें update करो |
Security
Section titled “Security”- Credentials को rest पर AES-256-GCM से encrypt किया जाता है
- Actions प्रति connector प्रति project प्रति minute 1,000 requests तक rate-limited हैं
- हर action call को एक audit trail के साथ log किया जाता है (connection, action, duration, status)
- Connections पूरे workspace के scope में होती हैं
क्या मैं एक ही connection को कई projects में उपयोग कर सकता हूँ?
हाँ। Connection एक बार बनाओ और उसे एक ही workspace के किसी भी number के projects से bind करो।
अगर मेरी API key expire हो जाए या revoke हो जाए तो क्या होगा?
Connection status Broken में बदल जाती है। इसे restore करने के लिए Settings > Connectors में credentials अपडेट करो।
क्या मैं frontend से connector actions call कर सकता हूँ?
नहीं। Credentials को secure रखने के लिए connector actions को server-side code (Convex actions) से ही call करना होगा। SDK Proyecta Cloud के ज़रिए route करता है, जो server-side पर authentication inject करता है।
क्या मैं अपने खुद के custom connectors जोड़ सकता हूँ?
अभी नहीं। Custom connector definitions roadmap पर हैं।
जल्द आ रहा है
Section titled “जल्द आ रहा है”- और connectors (Google, Twilio, SendGrid, और भी बहुत कुछ)
- Custom connector definitions — अपनी खुद की API लाओ
- Connected services से incoming events के लिए Webhook ingestion
- OAuth gateway — client-initiated flows के लिए भी tokens server-side रखना