Skip to main content
POST
/
api
/
admin
/
histories
Retrieve conversation histories for admin users
curl --request POST \
  --url https://pria.praxislxp.com/api/admin/histories \
  --header 'Content-Type: application/json' \
  --header 'x-access-token: <api-key>' \
  --data '
{
  "institution": "<string>",
  "usersearch": "<string>",
  "account": "<string>",
  "course_name": "<string>",
  "includeForgotten": false,
  "includeInactive": false,
  "includeDeleted": false,
  "daterange": [
    "2026-01-01",
    "2026-01-31"
  ],
  "page": 1,
  "pageSize": 1000,
  "limit": 123,
  "limitsearch": 123,
  "summary": true,
  "summaryInstruction": "<string>"
}
'
import requests

url = "https://pria.praxislxp.com/api/admin/histories"

payload = {
"institution": "<string>",
"usersearch": "<string>",
"account": "<string>",
"course_name": "<string>",
"includeForgotten": False,
"includeInactive": False,
"includeDeleted": False,
"daterange": ["2026-01-01", "2026-01-31"],
"page": 1,
"pageSize": 1000,
"limit": 123,
"limitsearch": 123,
"summary": True,
"summaryInstruction": "<string>"
}
headers = {
"x-access-token": "<api-key>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'POST',
headers: {'x-access-token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
institution: '<string>',
usersearch: '<string>',
account: '<string>',
course_name: '<string>',
includeForgotten: false,
includeInactive: false,
includeDeleted: false,
daterange: ['2026-01-01', '2026-01-31'],
page: 1,
pageSize: 1000,
limit: 123,
limitsearch: 123,
summary: true,
summaryInstruction: '<string>'
})
};

fetch('https://pria.praxislxp.com/api/admin/histories', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://pria.praxislxp.com/api/admin/histories",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'institution' => '<string>',
'usersearch' => '<string>',
'account' => '<string>',
'course_name' => '<string>',
'includeForgotten' => false,
'includeInactive' => false,
'includeDeleted' => false,
'daterange' => [
'2026-01-01',
'2026-01-31'
],
'page' => 1,
'pageSize' => 1000,
'limit' => 123,
'limitsearch' => 123,
'summary' => true,
'summaryInstruction' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-access-token: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://pria.praxislxp.com/api/admin/histories"

payload := strings.NewReader("{\n \"institution\": \"<string>\",\n \"usersearch\": \"<string>\",\n \"account\": \"<string>\",\n \"course_name\": \"<string>\",\n \"includeForgotten\": false,\n \"includeInactive\": false,\n \"includeDeleted\": false,\n \"daterange\": [\n \"2026-01-01\",\n \"2026-01-31\"\n ],\n \"page\": 1,\n \"pageSize\": 1000,\n \"limit\": 123,\n \"limitsearch\": 123,\n \"summary\": true,\n \"summaryInstruction\": \"<string>\"\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("x-access-token", "<api-key>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://pria.praxislxp.com/api/admin/histories")
.header("x-access-token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"institution\": \"<string>\",\n \"usersearch\": \"<string>\",\n \"account\": \"<string>\",\n \"course_name\": \"<string>\",\n \"includeForgotten\": false,\n \"includeInactive\": false,\n \"includeDeleted\": false,\n \"daterange\": [\n \"2026-01-01\",\n \"2026-01-31\"\n ],\n \"page\": 1,\n \"pageSize\": 1000,\n \"limit\": 123,\n \"limitsearch\": 123,\n \"summary\": true,\n \"summaryInstruction\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://pria.praxislxp.com/api/admin/histories")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["x-access-token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"institution\": \"<string>\",\n \"usersearch\": \"<string>\",\n \"account\": \"<string>\",\n \"course_name\": \"<string>\",\n \"includeForgotten\": false,\n \"includeInactive\": false,\n \"includeDeleted\": false,\n \"daterange\": [\n \"2026-01-01\",\n \"2026-01-31\"\n ],\n \"page\": 1,\n \"pageSize\": 1000,\n \"limit\": 123,\n \"limitsearch\": 123,\n \"summary\": true,\n \"summaryInstruction\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "success": true,
  "data": [
    {
      "_id": "<string>",
      "credits": 123,
      "usage": 123,
      "cached": 123,
      "completion": 123,
      "latencyMs": 123,
      "ragDurationMs": 123,
      "hasRagSearch": true,
      "ragSearchCount": 123,
      "input": "<string>",
      "inputs": [
        "<string>"
      ],
      "output": "<string>",
      "outputs": [
        "<string>"
      ],
      "success": true,
      "user": {
        "_id": "<string>",
        "email": "jsmith@example.com",
        "fname": "<string>",
        "lname": "<string>",
        "accountType": "<string>",
        "status": "<string>",
        "lxp_user_id": "<string>",
        "picture": "<string>",
        "lxp_user_type": 123,
        "lxp_partner_id": 123,
        "lxp_partner_name": "<string>",
        "lxp_role_id": 123,
        "lxp_role_name": "<string>",
        "credits": 123,
        "creditsUsed": 123,
        "plan": "<string>",
        "institution": {
          "_id": "<string>",
          "name": "<string>",
          "picture": "<string>",
          "credits": 123,
          "creditsUsed": 123,
          "creditsAwarded": 123,
          "publicId": "<string>",
          "publicAuthorizedUrls": [
            "<string>"
          ],
          "ainame": "<string>",
          "contactEmail": "<string>",
          "poolCredits": true,
          "created": "2023-11-07T05:31:56Z",
          "lastActivityAt": "2023-11-07T05:31:56Z",
          "conversationModel": "<string>",
          "account": {
            "_id": "<string>",
            "name": "<string>",
            "managerEmail": "jsmith@example.com",
            "credits": 123,
            "domainUrls": [
              "<string>"
            ],
            "qualification": "<string>",
            "created": "2023-11-07T05:31:56Z",
            "creditCaps": {
              "enabled": false,
              "perUserAccountTotal": 123,
              "perUserInstitutionDefault": 123,
              "perUser24hDefault": 123
            }
          },
          "agent": {
            "enabled": true,
            "preset": "<string>",
            "manifestYaml": "<string>",
            "manifestDigest": "<string>",
            "preferences": {
              "cpu": 2.125,
              "memoryMb": 4352,
              "storageGb": 52,
              "gui": true,
              "vncResolution": "1280x800"
            },
            "requestedBy": "<string>",
            "requestedAt": "2023-11-07T05:31:56Z",
            "provisionedAt": "2023-11-07T05:31:56Z",
            "lastError": "<string>"
          },
          "maxCompletionTokens": 123,
          "creditsTotal": 123,
          "creditsUsagePct": 123,
          "id": "<string>",
          "displayAgentDetails": true,
          "displayThinkingDetails": true,
          "displayRagSearchDetails": true,
          "displayThinkingExecution": true,
          "displayToolExecution": true
        },
        "remember_history_count": 123,
        "created": "2023-11-07T05:31:56Z"
      },
      "institution": {
        "_id": "<string>",
        "name": "<string>",
        "picture": "<string>",
        "credits": 123,
        "creditsUsed": 123,
        "creditsAwarded": 123,
        "publicId": "<string>",
        "publicAuthorizedUrls": [
          "<string>"
        ],
        "ainame": "<string>",
        "contactEmail": "<string>",
        "poolCredits": true,
        "created": "2023-11-07T05:31:56Z",
        "lastActivityAt": "2023-11-07T05:31:56Z",
        "conversationModel": "<string>",
        "account": {
          "_id": "<string>",
          "name": "<string>",
          "managerEmail": "jsmith@example.com",
          "credits": 123,
          "domainUrls": [
            "<string>"
          ],
          "qualification": "<string>",
          "created": "2023-11-07T05:31:56Z",
          "creditCaps": {
            "enabled": false,
            "perUserAccountTotal": 123,
            "perUserInstitutionDefault": 123,
            "perUser24hDefault": 123
          }
        },
        "agent": {
          "enabled": true,
          "preset": "<string>",
          "manifestYaml": "<string>",
          "manifestDigest": "<string>",
          "preferences": {
            "cpu": 2.125,
            "memoryMb": 4352,
            "storageGb": 52,
            "gui": true,
            "vncResolution": "1280x800"
          },
          "requestedBy": "<string>",
          "requestedAt": "2023-11-07T05:31:56Z",
          "provisionedAt": "2023-11-07T05:31:56Z",
          "lastError": "<string>"
        },
        "maxCompletionTokens": 123,
        "creditsTotal": 123,
        "creditsUsagePct": 123,
        "id": "<string>",
        "displayAgentDetails": true,
        "displayThinkingDetails": true,
        "displayRagSearchDetails": true,
        "displayThinkingExecution": true,
        "displayToolExecution": true
      },
      "status": "<string>",
      "query_duration_ms": 123,
      "course_id": 123,
      "course_name": "<string>",
      "assistant": {
        "_id": "<string>",
        "name": "<string>"
      },
      "conversation_model": "<string>",
      "tools": [
        {
          "id": "<string>",
          "name": "<string>",
          "responseLength": 123,
          "responseDurationMs": 123,
          "success": true,
          "_id": "<string>",
          "description": "<string>",
          "instructions": "<string>",
          "argument_1": "<string>",
          "argument_2": "<string>",
          "argument_3": "<string>",
          "argument_4": "<string>",
          "argument_5": "<string>",
          "argument_6": "<string>",
          "isArray": false,
          "rtEnabled": false,
          "rtOnly": false,
          "categories": [],
          "status": "active",
          "created": "2023-11-07T05:31:56Z",
          "unavailable": true,
          "unavailableReason": "<string>"
        }
      ],
      "created": "2023-11-07T05:31:56Z",
      "forgotten": true
    }
  ],
  "total": 123,
  "hasMore": true,
  "page": 123,
  "pageSize": 123,
  "message": "<string>"
}

Authorizations

x-access-token
string
header
required

JWT token passed in x-access-token header

Body

application/json
institution
string

Institution ID to filter histories (space-separated for multiple)

usersearch
string

Search term to filter by user email, first name, or last name. Also matches a raw 24-hex user _id (for actioned accounts whose PII has been scrubbed).

account
string

Account ID to filter by account's institutions (space-separated for multiple)

accountType
enum<string>

Filter by user account type

Available options:
user,
admin,
super
course_name
string

Filter by course name (case-insensitive partial match)

includeForgotten
boolean
default:false

When true, include conversations the user soft-deleted (forgotten); each such row carries forgotten=true so the UI can label them. Hidden by default.

includeInactive
boolean
default:false

Include users of any account status (not just non-deleted) in the usersearch resolution, so inactive/actioned accounts surface. Default false.

includeDeleted
boolean
default:false

Include soft-deleted (status:'deleted') history rows, not just active. Default false.

daterange
(string<date> | null)[]

Date range filter as [startDate, endDate]. Defaults to last 30 days if not provided. Use null for open-ended ranges.

Required array length: 2 elements
Example:
["2026-01-01", "2026-01-31"]
page
integer
default:1

Page number for pagination (1-based)

Required range: x >= 1
pageSize
integer
default:1000

Number of records per page (max 5000). Default 1000 for backward compatibility.

Required range: 1 <= x <= 5000
limit
integer
deprecated

Deprecated: use 'pageSize' instead.

limitsearch
integer
deprecated

Deprecated: use 'pageSize' instead.

summary
boolean

When true, returns an AI-generated summary instead of raw data

summaryInstruction
string

Custom instruction for the AI summary generation

Response

Successfully retrieved conversation histories

success
boolean
data
object[]
total
integer

Total number of matching records across all pages

hasMore
boolean

Whether more pages exist beyond the current page

page
integer

Current page number (1-based)

pageSize
integer

Records per page (resolved/clamped value)

message
string