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

# Export tool parameters and outputs

> Include tool parameters and return values in Compliance API conversation exports.

Conversation exports include the arguments sent to a tool and the value it returned when you set both `include_message_content=true` and `include_action_results=true`.

## Endpoints

Send both parameters on any of these requests:

```
GET /api/compliance/{workspace_id}/conversations
GET /api/compliance/{workspace_id}/conversations/{conversation_id}
GET /api/compliance/{workspace_id}/agents/{agent_id}/conversations
```

List responses include `next_cursor`. Pass that value as `cursor` to read the next page. `limit` defaults to 50. The maximum is 50.

`GET /api/compliance/{workspace_id}/messages` returns usage and cost rows. Tool parameters and outputs are on the conversation endpoints above.

## Base URL

```
https://app.langdock.com/api/compliance/{workspace_id}/conversations/{conversation_id}?include_message_content=true&include_action_results=true
```

> [!WARNING]
>
> **Dedicated deployments**
>
> Replace `app.langdock.com` with your deployment URL. Keep the path `/api/compliance/...`.

## Before You Start

* Create an API key with the **Compliance API** scope in [Settings > API](https://app.langdock.com/settings/workspace/products/api).
* Send the key as `Authorization: Bearer YOUR_API_KEY`.

> [!NOTE]
>
> On Cloud, these requests return 404 until the Compliance API is turned on for your workspace. The **Compliance API** scope stays hidden until then. Dedicated deployments serve the API unless that deployment turns it off.

## Parameters

Pass `true` or `false` as strings. Any other value returns 400.

| Parameter | Required | Description |
| - | - | - |
| `include_message_content` | No | `true` adds a `messages` array to each conversation. The default is `false`, which omits `messages`. |
| `include_action_results` | No | `true` adds action fields on tool messages. This applies only together with `include_message_content=true`. The default is `false`. |

With only `include_message_content=true`, tool messages still appear. `content` is the action name, and `action_name`, `action_input`, `action_output`, and `is_error` are omitted.

With only `include_action_results=true`, the response omits `messages`.

## Tool fields

With both parameters set to `true`, a tool message includes:

| Field | Description |
| - | - |
| `message_id` | ID of the chat message |
| `role` | `tool` |
| `content` | Action name |
| `action_name` | Action name |
| `action_input` | Arguments passed to the action |
| `action_output` | Value the action returned. When the action failed, this is the error payload. |
| `is_error` | `true` when the action failed, otherwise `false` |
| `created_at` | When the message was created |

User and assistant messages include `message_id`, `role`, `content`, and `created_at`.

## Example

```bash theme={null}
curl "https://app.langdock.com/api/compliance/550e8400-e29b-41d4-a716-446655440000/conversations/550e8400-e29b-41d4-a716-446655440001?include_message_content=true&include_action_results=true" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

```json theme={null}
{
  "data": [
    {
      "conversation_id": "550e8400-e29b-41d4-a716-446655440001",
      "created_at": "2026-01-01T09:00:00.000Z",
      "updated_at": "2026-01-01T10:00:02.000Z",
      "workspace_name": "Acme",
      "created_by_id": "550e8400-e29b-41d4-a716-446655440002",
      "using_agent": true,
      "agent_id": "550e8400-e29b-41d4-a716-446655440003",
      "agent_name": "Sales assistant",
      "current_model": null,
      "num_messages": 2,
      "messages": [
        {
          "message_id": "550e8400-e29b-41d4-a716-446655440004",
          "role": "user",
          "content": "Look up open deals",
          "created_at": "2026-01-01T10:00:00.000Z"
        },
        {
          "message_id": "550e8400-e29b-41d4-a716-446655440005",
          "role": "tool",
          "content": "List_deals",
          "action_name": "List_deals",
          "action_input": { "status": "open" },
          "action_output": { "deals": [{ "id": "d-1", "name": "Acme" }] },
          "is_error": false,
          "created_at": "2026-01-01T10:00:02.000Z"
        }
      ]
    }
  ],
  "next_cursor": null
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.