from chronicle import Chronicle
import os
world_id = os.environ["WORLD_ID"]
with Chronicle() as client:
result = client.worlds.activity.list(world_id, limit=100)
print(result.items)
print(result.has_next_page())import { Chronicle } from "@chroniclelabs/sdk";
const client = new Chronicle();
const worldId = process.env.WORLD_ID;
if (!worldId) throw new Error("Set WORLD_ID");
const result = await client.worlds.activity.list(worldId, { limit: 100 });
console.log(result.items);
console.log(result.hasNextPage());import { Chronicle } from "@chroniclelabs/sdk";
const client = new Chronicle();
const worldId = process.env.WORLD_ID;
if (!worldId) throw new Error("Set WORLD_ID");
const result = await client.worlds.activity.list(worldId, { limit: 100 });
console.log(result.items);
console.log(result.hasNextPage());package main
import (
"context"
"fmt"
"log"
"os"
"time"
chronicle "github.com/chronicle-labs/chronicle-go"
)
func main() {
if err := example(); err != nil { log.Fatal(err) }
}
func example() error {
ctx, cancel := context.WithTimeout(context.Background(), 120*time.Second)
defer cancel()
client := chronicle.NewClient()
worldID := os.Getenv("WORLD_ID")
if worldID == "" { return fmt.Errorf("set WORLD_ID") }
result, err := client.Worlds.Activity.List(ctx, worldID, chronicle.PageParams{Limit: 100})
if err != nil {
return err
}
fmt.Println(result.Items)
fmt.Println(result.HasNextPage())
return nil
}use chronicle_sdk::Chronicle;
use chronicle_sdk::types::PageParams;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = Chronicle::from_env()?;
let world_id = std::env::var("WORLD_ID")?;
let result = client.worlds().activity().list(&world_id, PageParams { limit: Some(100), ..Default::default() }).await?;
println!("{:?}", result.items);
println!("{}", result.has_next_page());
Ok(())
}{
"activities": [
{
"activity": {
"durationMs": 123,
"endedAt": "2023-11-07T05:31:56Z",
"method": "<string>",
"mutationCount": 1,
"path": "<string>",
"requestId": "<string>",
"startedAt": "2023-11-07T05:31:56Z",
"status": 1,
"traceId": "<string>",
"truncated": true,
"requestBytes": 1,
"responseBytes": 1,
"sessionId": "<string>"
},
"mutations": [
{
"changedFields": [
"<string>"
],
"collection": "<string>",
"durationMs": 123,
"endedAt": "2023-11-07T05:31:56Z",
"entityId": "<string>",
"operation": "insert",
"parentSpanId": "<string>",
"spanId": "<string>",
"startedAt": "2023-11-07T05:31:56Z",
"truncated": true,
"after": "<unknown>",
"before": "<unknown>",
"source": "collection"
}
],
"mutationsTruncated": true,
"service": "<string>",
"twinInstanceId": "<string>"
}
],
"hasMore": true,
"nextCursor": "<string>"
}{
"error": "World not found"
}{
"error": "World not found"
}{
"error": "World not found"
}{
"error": "World not found"
}List world activity
Requests made to any twin in this world, newest first, each with the service, twin ID, and a summary of the records it changed. Use the twin activity detail endpoint for full payloads.
Use the SDK setup with CHRONICLE_API_KEY and CHRONICLE_API_URL. The Go and Rust samples are complete entry points; Rust also needs Tokio (see Rust setup). Set WORLD_ID to the world.id returned by a launch or world-list result. Read full request and mutation data in Twin activity.
The schema below is the HTTP representation. SDKs normalize field names and list wrappers; see SDK and HTTP fields.
from chronicle import Chronicle
import os
world_id = os.environ["WORLD_ID"]
with Chronicle() as client:
result = client.worlds.activity.list(world_id, limit=100)
print(result.items)
print(result.has_next_page())import { Chronicle } from "@chroniclelabs/sdk";
const client = new Chronicle();
const worldId = process.env.WORLD_ID;
if (!worldId) throw new Error("Set WORLD_ID");
const result = await client.worlds.activity.list(worldId, { limit: 100 });
console.log(result.items);
console.log(result.hasNextPage());import { Chronicle } from "@chroniclelabs/sdk";
const client = new Chronicle();
const worldId = process.env.WORLD_ID;
if (!worldId) throw new Error("Set WORLD_ID");
const result = await client.worlds.activity.list(worldId, { limit: 100 });
console.log(result.items);
console.log(result.hasNextPage());package main
import (
"context"
"fmt"
"log"
"os"
"time"
chronicle "github.com/chronicle-labs/chronicle-go"
)
func main() {
if err := example(); err != nil { log.Fatal(err) }
}
func example() error {
ctx, cancel := context.WithTimeout(context.Background(), 120*time.Second)
defer cancel()
client := chronicle.NewClient()
worldID := os.Getenv("WORLD_ID")
if worldID == "" { return fmt.Errorf("set WORLD_ID") }
result, err := client.Worlds.Activity.List(ctx, worldID, chronicle.PageParams{Limit: 100})
if err != nil {
return err
}
fmt.Println(result.Items)
fmt.Println(result.HasNextPage())
return nil
}use chronicle_sdk::Chronicle;
use chronicle_sdk::types::PageParams;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = Chronicle::from_env()?;
let world_id = std::env::var("WORLD_ID")?;
let result = client.worlds().activity().list(&world_id, PageParams { limit: Some(100), ..Default::default() }).await?;
println!("{:?}", result.items);
println!("{}", result.has_next_page());
Ok(())
}{
"activities": [
{
"activity": {
"durationMs": 123,
"endedAt": "2023-11-07T05:31:56Z",
"method": "<string>",
"mutationCount": 1,
"path": "<string>",
"requestId": "<string>",
"startedAt": "2023-11-07T05:31:56Z",
"status": 1,
"traceId": "<string>",
"truncated": true,
"requestBytes": 1,
"responseBytes": 1,
"sessionId": "<string>"
},
"mutations": [
{
"changedFields": [
"<string>"
],
"collection": "<string>",
"durationMs": 123,
"endedAt": "2023-11-07T05:31:56Z",
"entityId": "<string>",
"operation": "insert",
"parentSpanId": "<string>",
"spanId": "<string>",
"startedAt": "2023-11-07T05:31:56Z",
"truncated": true,
"after": "<unknown>",
"before": "<unknown>",
"source": "collection"
}
],
"mutationsTruncated": true,
"service": "<string>",
"twinInstanceId": "<string>"
}
],
"hasMore": true,
"nextCursor": "<string>"
}{
"error": "World not found"
}{
"error": "World not found"
}{
"error": "World not found"
}{
"error": "World not found"
}Authorizations
Your Chronicle API key (chr_...). Create one in Settings > API keys.
Path Parameters
The world version ID, from world.id.
Query Parameters
Page size, 1 to 100. Default 50.
x >= 0The nextCursor from the previous page. Omit for the newest page.