---
title: "CreateTerminalSession"
method: POST
path: "/v1/terminal-sessions/"
tags: ["terminal-session"]
---

# CreateTerminalSession

`POST /v1/terminal-sessions/`

## Request

- Base URL: `https://localhost:1618/api`
- URL: `https://localhost:1618/api/v1/terminal-sessions/`
- Auth: API key in header `Authorization`

Create a terminal session. The working directory must exist. The account cap is thirty sessions.

## Request body

- DtoCreateTerminalSession
  - `accountId` integer
  - `command` string
  - `name` string
  - `workingDir` string

## Response `201`

Created

- EntityTerminalSession
  - `accountUsername` string
  - `attachedClients` integer
  - `command` string
  - `createdAt` integer
  - `id` string
  - `name` string
  - `workingDir` string

## Changes

- **2026-10-12** `1902a56749d0`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/goinfinite/apis/osapi/changes/v1/terminal-sessions/post.md)

---

[API](https://skmtc.dev/goinfinite/apis/osapi.md) - [All operations](https://skmtc.dev/goinfinite/apis/osapi/llms.txt) - [OpenAPI document](https://skmtc.dev/goinfinite/apis/osapi/revisions/3147503ce764?raw)
