1717 * @phpstan-import-type OutputTextType from OutputMessageContentOutputText
1818 * @phpstan-import-type ContentRefusalType from OutputMessageContentRefusal
1919 *
20- * @phpstan-type ContentPartType array{type: string, content_index: int, item_id: string, output_index: int, part: OutputTextType|ContentRefusalType}
20+ * @phpstan-type ContentPartType array{type: string, content_index: int, item_id: string, output_index: int, sequence_number: int, part: OutputTextType|ContentRefusalType}
2121 *
2222 * @implements ResponseContract<ContentPartType>
2323 */
@@ -36,6 +36,7 @@ private function __construct(
3636 public readonly int $ contentIndex ,
3737 public readonly string $ itemId ,
3838 public readonly int $ outputIndex ,
39+ public readonly int $ sequenceNumber ,
3940 public readonly OutputMessageContentOutputText |OutputMessageContentRefusal $ part ,
4041 private readonly MetaInformation $ meta ,
4142 ) {}
@@ -55,6 +56,7 @@ public static function from(array $attributes, MetaInformation $meta): self
5556 contentIndex: $ attributes ['content_index ' ],
5657 itemId: $ attributes ['item_id ' ],
5758 outputIndex: $ attributes ['output_index ' ],
59+ sequenceNumber: $ attributes ['sequence_number ' ],
5860 part: $ part ,
5961 meta: $ meta ,
6062 );
@@ -70,6 +72,7 @@ public function toArray(): array
7072 'content_index ' => $ this ->contentIndex ,
7173 'item_id ' => $ this ->itemId ,
7274 'output_index ' => $ this ->outputIndex ,
75+ 'sequence_number ' => $ this ->sequenceNumber ,
7376 'part ' => $ this ->part ->toArray (),
7477 ];
7578 }
0 commit comments