---
title: init()
framework: cryptokit
role: symbol
role_heading: Initializer
path: cryptokit/mlkem768/privatekey/init()
---

# init()

Initializes a random private key.

## Declaration

```swift
init() throws
```

## See Also

### Creating a private key

- [generate()](cryptokit/mlkem768/privatekey/generate().md)
- [init(integrityCheckedRepresentation:)](cryptokit/mlkem768/privatekey/init(integritycheckedrepresentation:).md)
- [init(seedRepresentation:publicKey:)](cryptokit/mlkem768/privatekey/init(seedrepresentation:publickey:).md)
