Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

VoiceGate SDK

Official Python and Node.js SDKs for VoiceGate — voice infrastructure for AI agents, by CallsFlow Ltd.

VoiceGate gives an autonomous AI agent a real phone line. Your agent picks the number, voice and language; VoiceGate places the call, transcribes the other side and speaks your agent's replies in real time. Your agent's own model decides what to say — VoiceGate is the ears, mouth and phone line. Billing is per minute in USDC on the Base network.

On top of calls, VoiceGate ships KYA (Know Your Agent): verifiable agent identity and portable reputation on the open ERC-8004 standard, using W3C Verifiable Credentials and did:key (Ed25519). An agent registers once, receives a credential, and logs in with it on later visits through a challenge–response handshake.

Status

Surface State
KYA — identity, credential, login, cabinet Live
Voice call API (/v1/agent-call) Private beta — request access, or point the SDK at your own gateway

The SDKs are dependency-light and the KYA flow is verified end-to-end against the live issuer.

Install

Python:

pip install voicegate        # or: pip install ./python

Node.js (18+):

npm install voicegate        # or: npm install ./node

Quick start — place a call

Python:

from voicegate import VoiceGate

vg = VoiceGate(api_key="sk_...")          # base_url defaults to the VoiceGate host
vg.call(
    to="+15551234567",
    agent_webhook="https://your-agent-brain.com/webhook",
    voice="female",
    language="en",
    initial_message="Hi, I'm calling to confirm your appointment.",
)

Node.js:

const { VoiceGate } = require('voicegate');

const vg = new VoiceGate({ apiKey: 'sk_...' });
await vg.call({
  to: '+15551234567',
  agentWebhook: 'https://your-agent-brain.com/webhook',
  voice: 'female',
  language: 'en',
  initialMessage: "Hi, I'm calling to confirm your appointment.",
});

The gateway calls the number, and on every turn POSTs the transcribed speech to your agent_webhook; whatever your agent returns is spoken back over the line.

Quick start — KYA identity (live)

Give the agent a persistent cryptographic identity, then log in with a Verifiable Credential:

from voicegate import VoiceGate, AgentKey

vg = VoiceGate(kya_url="https://aivoicegate.com")
key = AgentKey.generate()                 # persist key.seed_b64() to reuse the same DID
print(key.did)                            # did:key:z6Mk...

reg = vg.kya_register(key, operator_email="ops@your-company.com", domain="your-agent.com")
credential = vg.kya_get_credential(key, reg["agent_id"])   # issued once KYC passes

vg.kya_login(key, credential)             # challenge → sign nonce → session
print(vg.me())                            # cabinet: balance, reputation, calls

Node.js:

const { VoiceGate, AgentKey } = require('voicegate');

const vg = new VoiceGate({ kyaUrl: 'https://aivoicegate.com' });
const key = AgentKey.generate();          // persist key.seedB64() to reuse the same DID

const reg = await vg.kyaRegister(key, 'ops@your-company.com', 'your-agent.com');
const credential = await vg.kyaGetCredential(key, reg.agent_id);

await vg.kyaLogin(key, credential);
console.log(await vg.me());

Keys never leave your process: the SDK signs the registration proof and the login nonce locally with Ed25519, and only the DID, credential and signatures go over the wire.

What's in the box

  • AgentKey — Ed25519 keypair with did:key derivation and base64url signing. Generate once, persist the seed, reload later.
  • VoiceGate.call(...) — place a call through the gateway.
  • VoiceGate.kya_register / kya_get_credential / kya_login / me / issuer — the full KYA flow.

See python/examples and node/examples for runnable scripts.

License

MIT — see LICENSE. VoiceGate and KYA are products of CallsFlow Ltd. Not affiliated with Selma, Vapi, Retell AI or Bland AI; names are used for identification only.

About

Official Python & Node.js SDKs for VoiceGate — voice infrastructure for AI agents, with KYA agent identity (ERC-8004 / W3C Verifiable Credentials). By CallsFlow Ltd.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages