Guide: Generate a Meeting Summary

Endpoints: Analyze Bot Media, Retrieve Job, Get Intelligence Results

Webhooks: Bot Status Change Events - analysis_done, analysis_failed


Start an analysis job

To analyze a bots media, first get the ID for the bot associated with the meeting you'd like to summarize.

Once you have this ID, you can simply call Analyze Bot Media while specifying which provider we'd like to use for analysis.

For this example, let's use AssemblyAI's transcription to generate an informative paragraph about the meeting whose bot ID is b80bcb9b-ae75-4794-9b28-bcb2e5471cb4.

Request

curl --request POST \
     --url https://api.recall.ai/api/v2beta/bot/b80bcb9b-ae75-4794-9b28-bcb2e5471cb4/analyze \
     --header 'Authorization: Token {RECALL_API_KEY}' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
{
  "assemblyai_async_transcription": {
    "summarization": true,
    "summary_type": "paragraph",
    "summary_model": "informative"
  }
}
'

Response

{
  "job_id": "04f737c6-9d1f-45f7-88d0-61d4c2bc5ba0"
}

This kicks off the asynchronous analysis job and returns the ID of the job, which you can store in your database.

Monitor the status of the job

Using the job ID from above, let's check on the status of the job by calling Retrieve Job.

Request

curl --request GET \
     --url https://api.recall.ai/api/v1/analysis/job/04f737c6-9d1f-45f7-88d0-61d4c2bc5ba0/ \
     --header 'Authorization: Token {RECALL_API_KEY}' \
     --header 'accept: application/json'

Response

{
  "id" :"04f737c6-9d1f-45f7-88d0-61d4c2bc5ba0",
  "name": "assemblyai-transcription-6dbea7af-0285-4dc7-a5ca-16c37e3e02b4",
  "status": "in_progress",
  "errors": [],
  "created_at": "2024-01-14T18:37:11.732928Z",
  "bot_id": "b80bcb9b-ae75-4794-9b28-bcb2e5471cb4"
}

One way to know if a job is complete is by polling this endpoint and receiving a status of done.

Depending on your use case, it's typically better to achieve this is by listening to bot status changes for analysis_done events.

Handle Analysis Webhooks

If you want to trigger an event or be notified when jobs completes or fails to complete, you can utilize Bot Status Change webhooks, which will send a bot.status_change event at the webhook URL you have configured in the Recall dashboard.

There are two bot status change events related to analysis jobs:

analysis_done - Any asynchronous intelligence (like transcription or audio intelligence) has been completed.

analysis_failed - Any asynchronous intelligence (like transcription or audio intelligence) has failed.

When the asynchronous job is complete, you might want to store the status of the job as done, trigger a notification, or some other application logic.

If a job fails, you'll receive an analysis_failed event. In this case, you may want to render an error in your application's UI, or have an internal notification to help debug why the job failed.

Get the results of the job

To get the actual results of the job, you can call the Get Intelligence Results endpoint for the bot you ran intelligence on.

Request

curl --request GET \
     --url https://api.recall.ai/api/v1/bot/b80bcb9b-ae75-4794-9b28-bcb2e5471cb4/intelligence/ \
     --header 'Authorization: Token {RECALL_API_KEY}' \
     --header 'accept: application/json'

Response

{
  "assembly_ai.summary": "This is an example summary of a meeting.",
  "assembly_ai.language_code": "en",
  ...
}

And that's it! In just a few API calls, we summarized a meeting using AI. ✨