← Developer DocsOptional Calls

Get Results with Empty Items

Fetch all agenda items of a protocol, including those without generated text.

Use the getResultsWithEmpty query to retrieve all agenda items for a protocol — including items that have no AI-generated text yet.

This is identical to getResults except that it drops the textsegment_count__gt=0 filter. Empty items will have textList: {} and resolutionList: [] naturally, since they have no associated content rows.

Use this query when you need to render a complete agenda outline regardless of whether all items have been processed.


GraphQL Query

query GetResultsWithEmpty($protocolSlug: String!) {
  getResultsWithEmpty(protocolSlug: $protocolSlug) {
    creationDone
    protocol {
      slug
      name
      date
      language
      empty
      creatingStep
      status
      renamedSpeakers
      streamingUrl
      videoStreamingUrl
      streamingUrlsExpiresAt
    }
    agendaItemList {
      id
      classType
      title
      depth
      maxDepth
      metaData
      textList
      resolutionList {
        resolution
        decision
      }
      texts {
        depth
        name
        text
        hasBulletpoints
      }
      resolutions {
        id
        resolution
        decision
        positiveVote
        negativeVote
        neutralVote
        numberAttendees
      }
      createdAt
      updatedAt
    }
    taskItemList {
      id
      text
      date
      assignedTo
      done
      createdAt
      updatedAt
    }
  }
}

Streaming URLs

The protocol object includes signed CloudFront URLs for streaming or downloading the uploaded media files:

  • streamingUrl — Signed URL for the audio file.
  • videoStreamingUrl — Signed URL for the video file. This is only usable when a video was uploaded for the protocol.
  • streamingUrlsExpiresAt — Expiry timestamp for both signed URLs. URLs are currently valid for two hours after generation.

The URL fields can be returned even when no file exists for the protocol, for example when the audio was deleted or no video was recorded. In that case, requesting the URL results in a 404 response.


Example JavaScript Implementation

import axios from "axios";

const GET_RESULTS_WITH_EMPTY = `
  query GetResultsWithEmpty($protocolSlug: String!) {
    getResultsWithEmpty(protocolSlug: $protocolSlug) {
      creationDone
      protocol {
        slug
        name
        date
        creatingStep
        status
      }
      agendaItemList {
        id
        title
        depth
        textList
        resolutionList {
          resolution
          decision
        }
      }
      taskItemList {
        id
        text
        assignedTo
        done
      }
    }
  }
`;

export async function getResultsWithEmpty(protocolSlug) {
  const res = await axios.post(
    "https://api-v2.speechmind.com/external/v2/graphql",
    {
      query: GET_RESULTS_WITH_EMPTY,
      variables: { protocolSlug },
    },
    {
      headers: {
        "Content-Type": "application/json",
        "x-api-key": process.env.SPEECHMIND_API_KEY,
      },
    }
  );

  const result = res.data.data.getResultsWithEmpty;
  const { creationDone, protocol, agendaItemList, taskItemList } = result;

  return { creationDone, protocol, agendaItemList, taskItemList };
}

Two ways to read content — both fully supported

Same as getResults, each agenda item exposes two parallel field sets. Both are fully supported — request whichever fits your integration, or both at once.

Text content

  • textList — JSON object keyed by depth level. {"0": [...]} for summary, {"0": [...], "1": [...], "2": [...]} for politics. Empty items return {}.
  • texts — Typed list. Each entry has depth (Int), name (String, e.g. "Verlauf"), text ([String]), and hasBulletpoints (Boolean).

Resolutions

  • resolutionList — Each entry has resolution (String) and decision (String).
  • resolutions — Each entry adds id, positiveVote, negativeVote, neutralVote, and numberAttendees on top of the legacy fields.

Notes

  • Items with no AI content will have textList: {} and texts: [] — your rendering logic should handle both empty states.
  • Results are ordered by pos (position), the same ordering used by getResults.
  • If creationDone is false, some items may still be empty because processing is ongoing — poll until creationDone is true before treating empty items as permanently empty.