---
title: "Generate a new distributed key"
method: POST
path: "/v1/node/dks"
tags: ["node"]
---

# Generate a new distributed key

`POST /v1/node/dks`

## Request body

- DKSharesPostRequest
  - `peerIdentities` string[], required — Names or hex encoded public keys of trusted peers to run DKG on.
  - `threshold` integer, required — Should be =< len(PeerPublicIdentities)
  - `timeoutMS` integer, required — Timeout in milliseconds.

## Response `200`

DK shares info

- DKSharesInfo
  - `address` string, string, required — New generated shared address.
  - `peerIdentities` string[], required — Identities of the nodes sharing the key. (Hex)
  - `peerIndex` integer, required
  - `publicKey` string, string, required — Used public key. (Hex)
  - `publicKeyShares` string[], required — Public key shares for all the peers. (Hex)
  - `threshold` integer, required

## Other responses

- `401` — Unauthorized (Wrong permissions, missing token)

---

[API](https://skmtc.net/iotaledger/apis/wasp-api.md) · [All operations](https://skmtc.net/iotaledger/apis/wasp-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/iotaledger/wasp-api/revisions/994a6c93b890/schema)
