---
title: "This machine (the calling credential) says whether it records sessions and which stores it reads"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.gitpando.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Pando API › sessions

`PUT /v1/user/session-machine`

## Authentication

Requires one of the following:

- `credential`, http, header `Authorization`
- `session`, apiKey, in cookie

## Request body

_Required._

- `reportSessionMachine.recording` (boolean, required)
- `reportSessionMachine.stores` (array<object>, required)
  - `reportSessionMachine.stores.program` (string, required)
    - one of `"claude-code"`, `"codex"`, `"pi"`, `"opencode"`
  - `reportSessionMachine.stores.path` (string, required)
  - `reportSessionMachine.stores.found` (string, required) — default, environment, commit hook or paths add

## Example request

```json
{
  "recording": true,
  "stores": [
    {
      "program": "claude-code",
      "path": "string",
      "found": "string"
    }
  ]
}
```

## Code samples

### cURL

```curl
curl --request PUT \
  --url https://app.gitpando.com/v1/user/session-machine \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "recording": true,
  "stores": [
    {
      "program": "claude-code",
      "path": "string",
      "found": "string"
    }
  ]
}
'
```

### TypeScript

```typescript
const url = 'https://app.gitpando.com/v1/user/session-machine';
const options = {
  method: 'PUT',
  headers: {'Content-Type': 'application/json', Authorization: 'Bearer <token>'},
  body: JSON.stringify({
    recording: true,
    stores: [{program: 'claude-code', path: 'string', found: 'string'}]
  })
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://app.gitpando.com/v1/user/session-machine"

payload = {
    "recording": True,
    "stores": [
        {
            "program": "claude-code",
            "path": "string",
            "found": "string"
        }
    ]
}
headers = {
    "Content-Type": "application/json",
    "Authorization": "Bearer <token>"
}

response = requests.put(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 204

Saved.

### 400

An error

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "paths": [
      "string"
    ],
    "checks": {
      "sha": "string",
      "state": "success",
      "required": [
        "string"
      ],
      "checks_unknown": "string",
      "missing": [
        "string"
      ],
      "statuses": [
        {
          "sha": "string",
          "context": "string",
          "state": "pending",
          "target_url": "string",
          "description": "string",
          "creator": "string",
          "app": "string",
          "created_at": "2019-08-24T14:15:22Z"
        }
      ]
    }
  }
}
```

- `reportSessionMachine.response.400.error` (object, required)
  - `reportSessionMachine.response.400.error.code` (string, required)
  - `reportSessionMachine.response.400.error.message` (string, required)
  - `reportSessionMachine.response.400.error.paths` (array<string>, optional)
  - `reportSessionMachine.response.400.error.checks` (object, optional) — GitHub's combined status, plus the required contexts and which are missing.
    - `reportSessionMachine.response.400.error.checks.sha` (string | null, required)
    - `reportSessionMachine.response.400.error.checks.state` (string, required) — `success` when the merge gate passes; `missing` when a required context has not reported; `unknown` while the required checks are (an unforced merge is refused).
      - one of `"success"`, `"pending"`, `"failure"`, `"error"`, `"missing"`, `"unknown"`
    - `reportSessionMachine.response.400.error.checks.required` (array | null, required) — Null while unknown.
    - `reportSessionMachine.response.400.error.checks.checks_unknown` (string | null, required) — Why the required checks are unknown, in plain words: "Pando couldn't read this monorepo's required checks; try again", or "pando.toml line 3: expected comma or end of structure; fix it on main, or merge with force". Null otherwise.
    - `reportSessionMachine.response.400.error.checks.statuses` (array<object>, required) — The latest status per context.
      - `reportSessionMachine.response.400.error.checks.statuses.sha` (string, required)
      - `reportSessionMachine.response.400.error.checks.statuses.context` (string, required)
      - `reportSessionMachine.response.400.error.checks.statuses.state` (string, required)
        - one of `"pending"`, `"success"`, `"failure"`, `"error"`
      - `reportSessionMachine.response.400.error.checks.statuses.created_at` (string, required)
        - format `date-time`
      - `reportSessionMachine.response.400.error.checks.statuses.target_url` (string | null, optional)
      - `reportSessionMachine.response.400.error.checks.statuses.description` (string | null, optional)
      - `reportSessionMachine.response.400.error.checks.statuses.creator` (string, optional) — The member who posted it (a login); `app:<slug>` for a status posted with a status token or by a CI integration; `hook:<hook id>` for a status token from a web hook with no app.
      - `reportSessionMachine.response.400.error.checks.statuses.app` (string | null, optional) — The CI service that reported it (`buildkite`, `github-actions`, ...), stamped by Pando from a status token or a CI integration, never from the body or `target_url`. Null when a member posted it with their own credential. The web shows the service's mark for a slug it knows.
    - `reportSessionMachine.response.400.error.checks.missing` (array<string>, optional)


Source: https://docs.gitpando.com/api/sessions/reportSessionMachine/index.md
