# Update Speaker Events — Symbl.ai

> Update the Speaker Events of the Conversation. See the doc here.

- Key: `symbl_ai-put-speaker-events`
- Type: Action (Write)
- Version: 0.0.5
- App: Symbl.ai (`symbl_ai`) — https://pipedream.com/apps/symbl-ai.md
- This page (HTML): https://pipedream.com/apps/symbl-ai/actions/put-speaker-events
- Hints: destructive · open-world
- Source: https://github.com/PipedreamHQ/pipedream/blob/master/components/symbl_ai/actions/put-speaker-events/put-speaker-events.mjs

## Description

Update the Speaker Events of the Conversation. See the doc [here](https://docs.symbl.ai/docs/conversation-api/speaker-events/).

## Props

| Prop | Type | Required | Description |
|---|---|---|---|
| `conversationId` | `string` | Yes | The Id of the Conversation Options are loaded from the connected account. |
| `speakerEvents` | `string[]` | Yes | Provide a JSON array of speaker events with their type, user and offset information. Each Speaker Event object is represented by the following structure: [{"type": "started_speaking","user": {"id": "4194eb50-357d-4712-a02d-94215ead1064","name": "user","email": "user@example.com"},"offset": {"seconds": 0,"nanos": 5000000000}},{"type": "stopped_speaking","user": {"id": "4194eb50-357d-4712-a02d-94215ead1064","name": "User","email": "user@example.com"},"offset": {"seconds": 15,"nanos": 5000000000}}]. See doc here |

## 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": "symbl_ai",
      },
    },
  },
)

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: "symbl_ai-put-speaker-events",
  arguments: {
    conversationId: "Conversation Id",
    speakerEvents: ["Speaker Events"],
  },
})
```

**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: "symbl_ai-put-speaker-events",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    symbl_ai: { authProvisionId: "apn_xxxxxxx" },
    conversationId: "Conversation Id",
    speakerEvents: ["Speaker Events"],
  },
})

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": "symbl_ai-put-speaker-events",
    "configured_props": {
      "symbl_ai": { "authProvisionId": "apn_xxxxxxx" },
      "conversationId": "Conversation Id",
      "speakerEvents": ["Speaker Events"]
    }
  }'
```

---

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