---
title: "POST /v1/projects/{project}/instances/{instance}/rotateServerCertificate"
method: POST
path: "/v1/projects/{project}/instances/{instance}/rotateServerCertificate"
tags: ["instances"]
---

# POST /v1/projects/{project}/instances/{instance}/rotateServerCertificate

`POST /v1/projects/{project}/instances/{instance}/rotateServerCertificate`

Rotates the server certificate version to one previously added with the addServerCertificate method. For instances not using Certificate Authority Service (CAS) server CA, use RotateServerCa instead.

## Path parameters

- `project` string, required
- `instance` string, required

## Request body

- InstancesRotateServerCertificateRequest — Rotate server certificate request.
  - `rotateServerCertificateContext` RotateServerCertificateContext — Instance rotate server certificate context.
    - `kind` string — Optional. This is always `sql#rotateServerCertificateContext`.
    - `nextVersion` string — The fingerprint of the next version to be rotated to. If left unspecified, will be rotated to the most recently added server certificate version.

## Response `200`

Successful response

---

[API](https://skmtc.net/google/apis/sqladmin.md) · [All operations](https://skmtc.net/google/apis/sqladmin/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/google/sqladmin/versions/e9eef8a2afcd/schema)
