---
title: "POST /v1/{+parent}:importSshPublicKey"
method: POST
path: "/v1/{+parent}:importSshPublicKey"
tags: ["users"]
---

# POST /v1/{+parent}:importSshPublicKey

`POST /v1/{+parent}:importSshPublicKey`

Adds an SSH public key and returns the profile information. Default POSIX account information is set when no username and UID exist as part of the login profile.

## Path parameters

- `parent` string, required

## Query parameters

- `projectId` string
- `regions` string[]

## Request body

- SshPublicKey — The SSH public key information associated with a Google account.
  - `fingerprint` string — Output only. The SHA-256 fingerprint of the SSH public key.
  - `key` string — Required. Public key text in SSH format, defined by [RFC4253](https://www.ietf.org/rfc/rfc4253.txt) section 6.6.
  - `name` string — Output only. The canonical resource name.
  - `expirationTimeUsec` string, int64 — An expiration time in microseconds since epoch.

## Response `200`

Successful response

---

[API](https://skmtc.dev/google/apis/oslogin.md) · [All operations](https://skmtc.dev/google/apis/oslogin/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/google/oslogin/revisions/d37e38e2f1c7/schema)
