<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -",
    "macOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "FoundationModels",
  "identifier" : "/documentation/FoundationModels/Transcript/Response/init(id:metadata:segments:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "Foundation Models",
      "FoundationModels"
    ],
    "preciseIdentifier" : "s:16FoundationModels10TranscriptV8ResponseV2id8metadata8segmentsAESS_SDySSAA29ConvertibleToGeneratedContent_pGSayAC7SegmentOGtcfc"
  },
  "title" : "init(id:metadata:segments:)"
}
-->

# init(id:metadata:segments:)

Creates a response that contains the metadata and segments you provide.

```
init(id: String = UUID().uuidString, metadata: [String : any ConvertibleToGeneratedContent] = [:], segments: [Transcript.Segment])
```

## Parameters

`id`

A unique identifier for the response.

`metadata`

Additional information to associate with the response, keyed by name.

`segments`

The segments of the response, in order.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)