{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/opper/main/json-schema/opper-orstream-event-response-in-progress-schema.json",
  "title": "response.in_progress",
  "x-generated": "2026-10-15",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/opper-openapi.json#/components/schemas/ORStreamEventResponseInProgress",
  "properties": {
    "response": {
      "properties": {
        "completed_at": {
          "type": "integer"
        },
        "created_at": {
          "type": "integer"
        },
        "error": {
          "properties": {
            "code": {
              "type": "string"
            },
            "details": {
              "type": "object"
            },
            "message": {
              "type": "string"
            },
            "param": {
              "type": "string"
            },
            "type": {
              "type": "string"
            }
          },
          "required": [
            "message",
            "type"
          ],
          "type": "object"
        },
        "frequency_penalty": {
          "type": "number"
        },
        "id": {
          "type": "string"
        },
        "incomplete_details": {
          "description": "Any value"
        },
        "instructions": {
          "type": "string"
        },
        "max_output_tokens": {
          "type": "integer"
        },
        "metadata": {
          "type": "object"
        },
        "model": {
          "type": "string"
        },
        "object": {
          "type": "string"
        },
        "output": {
          "items": {
            "properties": {
              "action": {
                "type": "string"
              },
              "arguments": {
                "type": "string"
              },
              "cache_creation_tokens": {
                "type": "integer"
              },
              "cache_read_tokens": {
                "type": "integer"
              },
              "call_id": {
                "type": "string"
              },
              "content": {
                "items": {
                  "properties": {
                    "annotations": {
                      "items": {
                        "description": "Any value"
                      },
                      "type": "array"
                    },
                    "refusal": {
                      "type": "string"
                    },
                    "text": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "type",
                    "text"
                  ],
                  "type": "object"
                },
                "type": "array"
              },
              "cost_usd": {
                "type": "number"
              },
              "encrypted_content": {
                "type": "string"
              },
              "execution_ms": {
                "type": "integer"
              },
              "findings": {
                "items": {
                  "description": "Any value"
                },
                "type": "array"
              },
              "flagged": {
                "type": "boolean"
              },
              "guard_type": {
                "type": "string"
              },
              "id": {
                "type": "string"
              },
              "model_warnings": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "models_used": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "name": {
                "type": "string"
              },
              "role": {
                "type": "string"
              },
              "status": {
                "type": "string"
              },
              "summary": {
                "items": {
                  "properties": {
                    "text": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "type",
                    "text"
                  ],
                  "type": "object"
                },
                "type": "array"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "type"
            ],
            "type": "object"
          },
          "type": "array"
        },
        "parallel_tool_calls": {
          "type": "boolean"
        },
        "presence_penalty": {
          "type": "number"
        },
        "previous_response_id": {
          "type": "string"
        },
        "reasoning": {
          "properties": {
            "effort": {
              "type": "string"
            },
            "summary": {
              "type": "string"
            }
          },
          "type": "object"
        },
        "service_tier": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "temperature": {
          "type": "number"
        },
        "text": {
          "properties": {
            "format": {
              "properties": {
                "name": {
                  "type": "string"
                },
                "schema": {
                  "type": "object"
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "type"
              ],
              "type": "object"
            }
          },
          "type": "object"
        },
        "tool_choice": {
          "description": "Any value"
        },
        "tools": {
          "items": {
            "properties": {
              "description": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "parameters": {
                "type": "object"
              },
              "strict": {
                "type": "boolean"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "type"
            ],
            "type": "object"
          },
          "type": "array"
        },
        "top_p": {
          "type": "number"
        },
        "truncation": {
          "type": "string"
        },
        "usage": {
          "properties": {
            "cost": {
              "description": "Opper extension: execution cost in USD. Present on streaming response.completed events; non-stream surfaces the same value via the X-Opper-Cost header.",
              "type": "number"
            },
            "input_tokens": {
              "type": "integer"
            },
            "input_tokens_details": {
              "properties": {
                "cached_tokens": {
                  "type": "integer"
                }
              },
              "required": [
                "cached_tokens"
              ],
              "type": "object"
            },
            "output_tokens": {
              "type": "integer"
            },
            "output_tokens_details": {
              "properties": {
                "reasoning_tokens": {
                  "type": "integer"
                }
              },
              "required": [
                "reasoning_tokens"
              ],
              "type": "object"
            },
            "total_tokens": {
              "type": "integer"
            }
          },
          "required": [
            "input_tokens",
            "output_tokens",
            "total_tokens"
          ],
          "type": "object"
        }
      },
      "required": [
        "id",
        "object",
        "created_at",
        "completed_at",
        "status",
        "model",
        "output",
        "error",
        "incomplete_details",
        "tool_choice"
      ],
      "type": "object"
    },
    "sequence_number": {
      "type": "integer"
    },
    "type": {
      "enum": [
        "response.in_progress"
      ],
      "type": "string"
    }
  },
  "required": [
    "type",
    "sequence_number",
    "response"
  ],
  "type": "object"
}