---
title: "Add a new debug session - this is used by the squash client."
method: PUT
path: "/debugconfig/{debugConfigId}/session"
tags: ["debugsessions"]
---

# Add a new debug session - this is used by the squash client.

`PUT /debugconfig/{debugConfigId}/session`

When a debugger is attached, it should create a new debug session object under the debug config  that caused the debug session. Only one debug session is allowed per debug config. Once a  session is added, The service will stop being watched, and new debug configs for the same service can be created again.

## Path parameters

- `debugConfigId` string, required

## Request body

- DebugSession
  - `url` string
  - `debugConfigId` string, required

## Response `201`

Debug session created

- DebugSession
  - `url` string
  - `debugConfigId` string, required

## Other responses

- `400` — Invalid ID supplied
- `404` — debug config not found
- `412` — Debug state currently exists
- `422` — Invalid input

## Changes

- **2017-08-22** `7d244be4e5ca` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/solo-io/apis/squash-server/changes/debugconfig/:debugConfigId/session/put.md)

---

[API](https://skmtc.dev/solo-io/apis/squash-server.md) · [All operations](https://skmtc.dev/solo-io/apis/squash-server/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/solo-io/squash-server/revisions/7d244be4e5ca/schema)
