---
title: "Extend a reservation."
method: POST
path: "/api/ports/reservations/{id}/renew"
tags: ["ports"]
---

# Extend a reservation.

`POST /api/ports/reservations/{id}/renew`

## Request

- The document declares no server URL.
- Auth: none declared

Moves the reservation's expiry to now plus `ttl_secs`. A reservation that has already lapsed is gone: request it again with the same `owner_id` through `POST /api/ports/reservations` instead.

## Path parameters

- `id` string, uuid, required

## Request body

- RenewReservationRequest: Extend a reservation's lifetime.
  - `ttl_secs` integer, nullable: New lifetime in seconds, counted from now. Defaults to the server's configured TTL.

## Response `200`

The renewed reservation

- PortReservation: Ports held by one owner. `ports` is an explicit list, ascending. Allocation prefers a contiguous run and growth prefers extending the existing one, but neither is guaranteed — a port the operator left out of the pool, one another owner holds, or one found blocked can put a hole anywhere. Callers must not assume contiguity.
  - `created_at` string, required: When the reservation was first granted (RFC 3339, UTC).
  - `expires_at` string, required: When it lapses unless renewed (RFC 3339, UTC).
  - `id` string, uuid, required: Reservation identifier, used to renew, release and assign.
  - `in_use` PortInUse[]: Which of `ports` the owner has told the pool are used by a flow.
    - `flow_id` string, uuid, required: The flow the owner says uses it.
    - `port` integer, required: The port.
  - `owner_id` string, required: The owner's stable name. One reservation per owner; asking again returns it.
  - `ports` integer[], required: The ports held, ascending.

## Other responses

- `400`: Invalid ttl_secs
- `404`: No live reservation with that id
- `500`: Reservation could not be persisted
- `503`: No port pool is configured on this server

## Changes

- **2026-09-28** `fd671a19e55a`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/eyevinn/apis/strom-api/changes/api/ports/reservations/:id/renew/post.md)

---

[API](https://skmtc.dev/eyevinn/apis/strom-api.md) - [All operations](https://skmtc.dev/eyevinn/apis/strom-api/llms.txt) - [OpenAPI document](https://skmtc.dev/eyevinn/apis/strom-api/revisions/8cd4dbc44175?raw)
