Call Objects

With the Vocode API in-progress and completed calls are accessible as Call objects.

To list your call history:

calls = vocode_client.calls.list_calls()

The resulting list of Call objects is structured like this:

    id: 'call_id',
    userId: 'user_id',
    toNumber: '123456789',
    fromNumber: '123456789',
    agent: {
      id: 'agent_id',
      userId: 'user_id',
      prompt: 'The assistant is having a pleasant conversation about life.',
      actions: [],
      voice: [Object],
      initialMessage: undefined,
      webhook: undefined
    goal: undefined,
    transcript: undefined,
    recordingUrl: undefined,
    status: 'ended',
    errorMessage: undefined,
    recordingAvailable: false

Get a specific call

If you have a call ID, you can get the call object for that call.


Download a call recording

If you enabled call recording, you can download the call recording file.