## GET /v1/functions/{function_id}/runs/{id}/logs

Read what the handler wrote to standard output and standard error. Empty until the run ends.

Required permissions: read:functions.
API key: Supported.
CLI user token: Supported.
Session token: Not supported by session tokens, even with permissions.ellipsis enabled.
Higher permission levels include lower levels: read < write < delete.

### Response

```text
{
  "logs": str,
  "truncated": bool
}
```

### Python

```python
import os

from ellipsis import Ellipsis

client = Ellipsis(api_key=os.environ["ELLIPSIS_API_TOKEN"])

result = client.functions.runs.logs("open-pr-count", "...")
print(result)
```

### TypeScript

```typescript
import { Ellipsis } from '@ellipsis-dev/sdk';

const client = new Ellipsis({
  apiKey: process.env.ELLIPSIS_API_TOKEN!,
});

const result = await client.functions.runs.logs("open-pr-count", '...');
console.log(result);
```

### cURL

```bash
curl "https://api.ellipsis.dev/v1/functions/{function_id}/runs/{id}/logs" \
  -H "Authorization: Bearer $ELLIPSIS_API_TOKEN"
```

### Response schema

```json
{
  "properties": {
    "logs": {
      "type": "string"
    },
    "truncated": {
      "type": "boolean"
    }
  },
  "required": [
    "logs",
    "truncated"
  ],
  "type": "object"
}
```
