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

# init(id:contentType:content:metadata:)

Creates a data entry with the content type, content, and metadata
you provide.

```
init(id: String = UUID().uuidString, contentType: UTType, content: Data, metadata: GeneratedContent = GeneratedContent(properties: [:]))
```

## Parameters

`id`

A unique identifier for the entry.

`contentType`

A `UTType` identifying how to interpret `content`.

`content`

A raw binary representation of the entry.

`metadata`

Metadata pertinent to this entry.

---

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)