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

# init()

Creates a NIST P-256 elliptic curve private key for use with Diffie-Hellman key exchange.

## Declaration

```swift
init()
```
