---
title: "Create an SSH key for a Devbox"
method: POST
path: "/v1/devboxes/{id}/create_ssh_key"
tags: ["Devbox", "Devbox-NetworkTools"]
---

# Create an SSH key for a Devbox

`POST /v1/devboxes/{id}/create_ssh_key`

Create an SSH key for a Devbox to enable remote access.

## Path parameters

- `id` string, required

## Response `200`

OK

- DevboxCreateSshKeyView
  - `id` string, required — The ID of the Devbox.
  - `url` string, required — The host url of the Devbox that can be used for SSH.
  - `ssh_private_key` string, required — The ssh private key, in PEM format.
  - `ssh_user` string, required — The Linux user to use for SSH connections to this Devbox.

## Other responses

- `404` — Devbox not found.

## Changes

- **2025-12-13** `370a5d676ff0` — 1 info
  - added the required property `ssh_user` to the response with the `200` status

[Change history](https://skmtc.dev/runloopai/apis/runloop-api/changes/v1/devboxes/:id/create_ssh_key/post.md)

---

[API](https://skmtc.dev/runloopai/apis/runloop-api.md) · [All operations](https://skmtc.dev/runloopai/apis/runloop-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/runloopai/runloop-api/revisions/e9dc776053e4/schema)
