Skip to content
StudyFetch API

Performance Insights

Create conversation

Creates a new Performance Insights conversation. A session ID is auto-generated if not provided.

OpenAPI specification
POST/api/v1/performance-insights/sessions/create

Authentication

x-api-key

Request

curl --globoff --request POST \
  --url 'https://api.example.com/api/v1/performance-insights/sessions/create' \
  --header 'x-api-key: <API_KEY>' \
  --header 'Content-Type: application/json' \
  --data-raw '{}'

Replace credential and <field> placeholders with your own values. URL placeholders appear as %3Cfield%3E. Review the example values before sending your request.

Replace https://api.example.com with the API server URL.

Use the sample JSON body as your starting point, and enter values that match the endpoint's schema.

Request body schema or example

{
  "type": "object",
  "properties": {
    "sessionId": {
      "type": "string",
      "description": "Custom session ID. Auto-generated if omitted."
    },
    "title": {
      "type": "string",
      "description": "Conversation title",
      "default": "New Chat"
    },
    "suggestionContext": {
      "type": "string",
      "description": "Report-page suggestion context to stamp onto this conversation only (e.g. low_answer_confidence_correct_individual). Omit on New Chat so later conversations do not inherit the landing page chips.",
      "example": "low_answer_confidence_correct_individual"
    }
  }
}

Responses

201Conversation created
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Conversation / session ID"
    },
    "userId": {
      "type": "string",
      "description": "Owner user ID"
    },
    "organizationId": {
      "type": "string",
      "description": "Organization ID"
    },
    "groupId": {
      "type": "string",
      "description": "Group ID composite key (sorted, comma-separated) when sessions are scoped to a group"
    },
    "title": {
      "type": "string",
      "description": "Conversation title"
    },
    "messages": {
      "description": "AI SDK UIMessage array with hydrated image URLs",
      "type": "array",
      "items": {
        "type": "object"
      }
    },
    "createdAt": {
      "format": "date-time",
      "type": "string",
      "description": "Creation timestamp"
    },
    "updatedAt": {
      "format": "date-time",
      "type": "string",
      "description": "Last update timestamp"
    },
    "suggestionContext": {
      "type": "string",
      "description": "Report-page suggestion context stamped on this conversation, if any"
    }
  },
  "required": [
    "id",
    "userId",
    "organizationId",
    "title",
    "messages",
    "createdAt",
    "updatedAt"
  ]
}