import BrainbaseLabs from 'brainbase-labs';
const client = new BrainbaseLabs({
apiKey: process.env['BRAINBASE_LABS_API_KEY'], // This is the default and can be omitted
});
const voiceV1Deployment = await client.workers.deployments.voicev1.create('workerId', {
allowedTransferNumbers: ['string'],
config: {},
endSentence: 'endSentence',
flowId: 'flowId',
functions: 'functions',
language: 'language',
model: 'model',
name: 'name',
objective: 'objective',
phoneNumber: 'phoneNumber',
resourceKeys: ['string'],
startSentence: 'startSentence',
voiceId: 'voiceId',
wsBaseUrl: 'wsBaseUrl',
});
console.log(voiceV1Deployment.id);