For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dashboard
User GuideDeveloper GuidesAPI Reference
User GuideDeveloper GuidesAPI Reference
    • Overview
  • Runtype API
      • GETList generation sessions
      • POSTCreate a generation session
      • GETGet session details
      • DELDelete a generation session
      • PATCHUpdate a generation session
      • POSTAppend an event to a session
Dashboard
LogoLogo
Runtype APIProduct Generation

Append an event to a session

POST
/v1/products/generation/sessions/:id/events
POST
/v1/products/generation/sessions/:id/events
$curl -X POST https://api.runtype.com/v1/products/generation/sessions/id/events \
> -H "Authorization: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '{
> "type": "progress",
> "message": "Generating flow capabilities...",
> "payload": {
> "step": 2,
> "totalSteps": 5
> },
> "stage": "generation"
>}'
1{
2 "createdAt": "string",
3 "id": "string",
4 "message": "string",
5 "organizationId": "string",
6 "payload": {},
7 "sessionId": "string",
8 "stage": "string",
9 "type": "string",
10 "userId": "string"
11}
Adds a new event to a generation session for tracking progress and state changes.
Was this page helpful?
Previous

Configure webhook from documentation

Next
Built with

Authentication

AuthorizationBearer
API key or Clerk session token

Path parameters

idstringRequired
Session ID

Request

This endpoint expects an object.
typestringRequired>=1 character
messagestringOptional
payloadmap from strings to anyOptional
stagestringOptional

Response

Event created
createdAtstring
idstring
messagestring or null
organizationIdstring or null
payloadmap from strings to any
sessionIdstring
stagestring or null
typestring
userIdstring

Errors

401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
500
Internal Server Error