# Update Assistant Settings — Vapi

> Updates the configuration settings for a specific assistant. See the documentation

- Key: `vapi-update-assistant-settings`
- Type: Action (Write)
- Version: 0.0.5
- App: Vapi (`vapi`) — https://pipedream.com/apps/vapi.md
- This page (HTML): https://pipedream.com/apps/vapi/actions/update-assistant-settings
- Hints: destructive · open-world
- Source: https://github.com/PipedreamHQ/pipedream/blob/master/components/vapi/actions/update-assistant-settings/update-assistant-settings.mjs

## Description

Updates the configuration settings for a specific assistant. [See the documentation](https://docs.vapi.ai/api-reference/assistants/update)

## Props

| Prop | Type | Required | Description |
|---|---|---|---|
| `assistantId` | `string` | Yes | ID of the assistant to start a conversation with or update Options are loaded from the connected account. |
| `transcriber` | `object` | No | A formatted JSON object for the assistant's transcriber. Example: { "provider": "talkscriber", "language": "en", "model": "whisper" }. See the documentation for further details |
| `model` | `object` | No | A formatted JSON object for the assistant's LLM. Example: {"provider": "xai", "model": "grok-beta", "emotionRecognitionEnabled": true, "knowledgeBase": {"server": {"url": "url", "timeoutSeconds": 20}}, "knowledgeBaseId": "model", "maxTokens": 1.1, "messages": [{"role": "assistant"}], "numFastTurns": 1.1, "temperature": 1.1, "toolIds": ["model"], "tools": [{"type": "transferCall", "async": false}]}. See the documentation for further details |
| `voice` | `object` | No | A formatted JSON object for the assistant's voice. Example: {"provider":"tavus","voiceId":"r52da2535a","callbackUrl":"voice","chunkPlan":{"enabled":true,"minCharacters":30,"punctuationBoundaries":["。",",",".","!","?",";","،",",","।","॥","\|","\|\|",",",":"],"formatPlan":{"enabled":true,"numberToDigitsCutoff":2025}},"conversationName":"voice","conversationalContext":"voice","customGreeting":"voice","fallbackPlan":{"voices":[{"provider":"tavus","voiceId":"r52da2535a"}]},"personaId":"voice","properties":{"maxCallDuration":1.1,"participantLeftTimeout":1.1,"participantAbsentTimeout":1.1,"enableRecording":true,"enableTranscription":true,"applyGreenscreen":true,"language":"language","recordingS3BucketName":"recordingS3BucketName","recordingS3BucketRegion":"recordingS3BucketRegion","awsAssumeRoleArn":"awsAssumeRoleArn"}}. See the documentation for further details |
| `firstMessage` | `string` | No | The first message the assistant will say or a URL to an audio file. If unspecified, assistant will wait for user to speak and use the model to respond once they speak. |
| `firstMessageMode` | `string` | No | Mode for the first message |
| `hipaaEnabled` | `boolean` | No | When this is enabled, no logs, recordings, or transcriptions will be stored. At the end of the call, you will still receive an end-of-call-report message to store on your server. |
| `clientMessages` | `string[]` | No | These are the messages that will be sent to your Client SDKs |
| `serverMessages` | `string[]` | No | These are the messages that will be sent to your Server URL |
| `silenceTimeoutSeconds` | `integer` | No | How many seconds of silence to wait before ending the call. |
| `maxDurationSeconds` | `integer` | No | This is the maximum number of seconds that the call will last. When the call reaches this duration, it will be ended. |
| `backgroundSound` | `string` | No | This is the background sound in the call. Default for phone calls is 'office' and default for web calls is 'off'. |
| `backgroundDenoisingEnabled` | `boolean` | No | This enables filtering of noise and background speech while the user is talking. Default false while in beta. |
| `modelOutputInMessagesEnabled` | `boolean` | No | This determines whether the model's output is used in conversation history rather than the transcription of assistant's speech. Default false while in beta. |
| `transportConfigurations` | `string[]` | No | These are the configurations to be passed to the transport providers of assistant's calls, like Twilio. You can store multiple configurations for different transport providers. For a call, only the configuration matching the call transport provider is used. Example: [{"provider":"twilio","timeout":60,"record":false,"recordingChannels":"mono"}]. See the documentation for further details |
| `credentials` | `string[]` | No | These are dynamic credentials that will be used for the assistant calls. By default, all the credentials are available for use in the call but you can supplement an additional credentials using this. Dynamic credentials override existing credentials. Example: [{"provider":"xai","apiKey":"credentials","name":"credentials"}]. See the documentation for further details |
| `name` | `string` | No | Name of the assistant. This is required when you want to transfer between assistants in a call. |
| `voicemailDetection` | `object` | No | These are the settings to configure or disable voicemail detection. Alternatively, voicemail detection can be configured using the model.tools=[VoicemailTool]. This uses Twilio's built-in detection while the VoicemailTool relies on the model to detect if a voicemail was reached. You can use neither of them, one of them, or both of them. By default, Twilio built-in detection is enabled while VoicemailTool is not. Example: {"provider":"twilio","voicemailDetectionTypes":["machine_end_beep","machine_end_silence"],"enabled":true,"machineDetectionTimeout":1.1,"machineDetectionSpeechThreshold":1.1,"machineDetectionSpeechEndThreshold":1.1,"machineDetectionSilenceTimeout":1.1}. See the documentation for further details |
| `voicemailMessage` | `string` | No | This is the message that the assistant will say if the call is forwarded to voicemail. If unspecified, it will hang up |
| `endCallMessage` | `string` | No | This is the message that the assistant will say if it ends the call. If unspecified, it will hang up without saying anything |
| `endCallPhrases` | `string[]` | No | A list containing phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. |
| `metadata` | `object` | No | This is for metadata you want to store on the assistant. |
| `analysisPlan` | `object` | No | This is the plan for analysis of assistant's calls. Stored in call.analysis. Example: {"summaryPlan":{"messages":[{"key":"value"}],"enabled":true,"timeoutSeconds":1.1},"structuredDataPlan":{"messages":[{"key":"value"}],"enabled":true,"schema":{"type":"string"},"timeoutSeconds":1.1},"successEvaluationPlan":{"rubric":"NumericScale","messages":[{"key":"value"}],"enabled":true,"timeoutSeconds":1.1}}. See the documentation for further details |
| `artifactPlan` | `object` | No | This is the plan for artifacts generated during assistant's calls. Stored in call.artifact. Note: recordingEnabled is currently at the root level. It will be moved to artifactPlan in the future, but will remain backwards compatible. Example: {"recordingEnabled":true,"videoRecordingEnabled":false,"transcriptPlan":{"enabled":true,"assistantName":"assistantName","userName":"userName"},"recordingPath":"recordingPath"}. See the documentation for further details |
| `messagePlan` | `object` | No | This is the plan for static predefined messages that can be spoken by the assistant during the call, like idleMessages. Note: firstMessage, voicemailMessage, and endCallMessage are currently at the root level. They will be moved to messagePlan in the future, but will remain backwards compatible. Example: {"idleMessages":["idleMessages"],"idleMessageMaxSpokenCount":1.1,"idleTimeoutSeconds":1.1}. See the documentation for further details |
| `startSpeakingPlan` | `object` | No | This is the plan for when the assistant should start talking. Example: {"waitSeconds":0.4,"smartEndpointingEnabled":false,"customEndpointingRules":[{"type":"both","assistantRegex":"customEndpointingRules","customerRegex":"customEndpointingRules","timeoutSeconds":1.1}],"transcriptionEndpointingPlan":{"onPunctuationSeconds":0.1,"onNoPunctuationSeconds":1.5,"onNumberSeconds":0.5}}. See the documentation for further details |
| `stopSpeakingPlan` | `object` | No | This is the plan for when assistant should stop talking on customer interruption. Example: {"numWords":0,"voiceSeconds":0.2,"backoffSeconds":1}. See the documentation for further details |
| `monitorPlan` | `object` | No | This is the plan for real-time monitoring of the assistant's calls. Note: serverMessages, clientMessages, serverUrl and serverUrlSecret are currently at the root level but will be moved to monitorPlan in the future. Will remain backwards compatible. Example: {"listenEnabled":false,"controlEnabled":false}. See the documentation for further details |
| `credentialIds` | `string[]` | No | These are the credentials that will be used for the assistant calls. By default, all the credentials are available for use in the call but you can provide a subset using this. |
| `server` | `object` | No | This is where Vapi will send webhooks. You can find all webhooks available along with their shape in ServerMessage schema. Example: {"url":"url","timeoutSeconds":20,"secret":"secret","headers":{"key":"value"}}. See the documentation for further details |

## Run it

**MCP**

```ts
import { Client } from "@modelcontextprotocol/sdk/client/index.js"
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js"
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const accessToken = await pd.rawAccessToken

const transport = new StreamableHTTPClientTransport(
  new URL("https://remote.mcp.pipedream.net/v3"),
  {
    requestInit: {
      headers: {
        Authorization: `Bearer ${accessToken}`,
        "x-pd-project-id": process.env.PIPEDREAM_PROJECT_ID!,
        "x-pd-environment": "production",
        "x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
        "x-pd-app-slug": "vapi",
      },
    },
  },
)

const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)

const { tools } = await mcp.listTools()

// listTools() hands your model this tool's input schema, so it can
// fill the arguments itself:
const result = await mcp.callTool({
  name: "vapi-update-assistant-settings",
  arguments: {
    assistantId: "Assistant ID",
    transcriber: "Transcriber",
  },
})
```

**TypeScript**

```ts
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "vapi-update-assistant-settings",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    vapi: { authProvisionId: "apn_xxxxxxx" },
    assistantId: "Assistant ID",
    transcriber: "Transcriber",
  },
})

console.log(result)
```

**cURL**

```bash
curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
  -H "Content-Type: application/json" \
  -H "X-PD-Environment: production" \
  -H "Authorization: Bearer {access_token}" \
  -d '{
    "external_user_id": "{external_user_id}",
    "id": "vapi-update-assistant-settings",
    "configured_props": {
      "vapi": { "authProvisionId": "apn_xxxxxxx" },
      "assistantId": "Assistant ID",
      "transcriber": "Transcriber"
    }
  }'
```

---

- App: https://pipedream.com/apps/vapi.md · All apps: https://pipedream.com/apps
