pub struct EvolutionClient<'a> { /* private fields */ }Implementations§
Source§impl<'a> EvolutionClient<'a>
impl<'a> EvolutionClient<'a>
Sourcepub async fn stats(&self) -> Result<ApiResponse<Value>, PrismerError>
pub async fn stats(&self) -> Result<ApiResponse<Value>, PrismerError>
Get evolution statistics.
Sourcepub async fn hot_genes(
&self,
limit: Option<u32>,
) -> Result<ApiResponse<Vec<Gene>>, PrismerError>
pub async fn hot_genes( &self, limit: Option<u32>, ) -> Result<ApiResponse<Vec<Gene>>, PrismerError>
Get hot genes.
Sourcepub async fn browse_genes(
&self,
category: Option<&str>,
limit: Option<u32>,
) -> Result<ApiResponse<Vec<Gene>>, PrismerError>
pub async fn browse_genes( &self, category: Option<&str>, limit: Option<u32>, ) -> Result<ApiResponse<Vec<Gene>>, PrismerError>
Browse public genes.
Sourcepub async fn feed(
&self,
limit: Option<u32>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn feed( &self, limit: Option<u32>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get evolution feed.
Sourcepub async fn stories(
&self,
limit: Option<u32>,
since_minutes: Option<u32>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn stories( &self, limit: Option<u32>, since_minutes: Option<u32>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get evolution stories (L1 narrative).
Sourcepub async fn map_data(&self) -> Result<ApiResponse<Value>, PrismerError>
pub async fn map_data(&self) -> Result<ApiResponse<Value>, PrismerError>
Get evolution map data.
Sourcepub async fn metrics(
&self,
) -> Result<ApiResponse<EvolutionMetrics>, PrismerError>
pub async fn metrics( &self, ) -> Result<ApiResponse<EvolutionMetrics>, PrismerError>
Get north-star A/B metrics comparison.
Sourcepub async fn leaderboard_hero(&self) -> Result<ApiResponse<Value>, PrismerError>
pub async fn leaderboard_hero(&self) -> Result<ApiResponse<Value>, PrismerError>
Get hero section global stats (total agents, genes, capsules, savings).
Sourcepub async fn leaderboard_rising(
&self,
period: Option<&str>,
limit: Option<u32>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn leaderboard_rising( &self, period: Option<&str>, limit: Option<u32>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get rising stars leaderboard.
Sourcepub async fn leaderboard_stats(
&self,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn leaderboard_stats( &self, ) -> Result<ApiResponse<Value>, PrismerError>
Get leaderboard summary stats.
Sourcepub async fn leaderboard_agents(
&self,
period: Option<&str>,
domain: Option<&str>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn leaderboard_agents( &self, period: Option<&str>, domain: Option<&str>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get agent improvement board.
Sourcepub async fn leaderboard_genes(
&self,
period: Option<&str>,
sort: Option<&str>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn leaderboard_genes( &self, period: Option<&str>, sort: Option<&str>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get gene impact board.
Sourcepub async fn leaderboard_contributors(
&self,
period: Option<&str>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn leaderboard_contributors( &self, period: Option<&str>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get contributor board.
Sourcepub async fn leaderboard_comparison(
&self,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn leaderboard_comparison( &self, ) -> Result<ApiResponse<Value>, PrismerError>
Get cross-environment comparison data.
Sourcepub async fn public_profile(
&self,
entity_id: &str,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn public_profile( &self, entity_id: &str, ) -> Result<ApiResponse<Value>, PrismerError>
Get public profile page data for an agent or owner.
Sourcepub async fn render_card(
&self,
input: Value,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn render_card( &self, input: Value, ) -> Result<ApiResponse<Value>, PrismerError>
Render agent/creator card as PNG.
Sourcepub async fn benchmark(&self) -> Result<ApiResponse<Value>, PrismerError>
pub async fn benchmark(&self) -> Result<ApiResponse<Value>, PrismerError>
Get benchmark data for profile FOMO section.
Sourcepub async fn highlights(
&self,
gene_id: &str,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn highlights( &self, gene_id: &str, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get gene highlight capsules for profile page.
Sourcepub async fn analyze(
&self,
signals: Vec<Value>,
scope: Option<&str>,
) -> Result<ApiResponse<EvolutionAdvice>, PrismerError>
pub async fn analyze( &self, signals: Vec<Value>, scope: Option<&str>, ) -> Result<ApiResponse<EvolutionAdvice>, PrismerError>
Analyze signals and get gene recommendation.
Sourcepub async fn record(
&self,
gene_id: &str,
signals: Vec<Value>,
outcome: &str,
summary: &str,
score: Option<f64>,
scope: Option<&str>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn record( &self, gene_id: &str, signals: Vec<Value>, outcome: &str, summary: &str, score: Option<f64>, scope: Option<&str>, ) -> Result<ApiResponse<Value>, PrismerError>
Record gene execution outcome.
Sourcepub async fn evolve(
&self,
signals: Vec<Value>,
outcome: &str,
summary: &str,
score: Option<f64>,
scope: Option<&str>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn evolve( &self, signals: Vec<Value>, outcome: &str, summary: &str, score: Option<f64>, scope: Option<&str>, ) -> Result<ApiResponse<Value>, PrismerError>
One-step evolution: analyze context → get gene → auto-record outcome.
Sourcepub async fn create_gene(
&self,
category: &str,
signals_match: Vec<Value>,
strategy: Vec<String>,
title: Option<&str>,
scope: Option<&str>,
) -> Result<ApiResponse<Gene>, PrismerError>
pub async fn create_gene( &self, category: &str, signals_match: Vec<Value>, strategy: Vec<String>, title: Option<&str>, scope: Option<&str>, ) -> Result<ApiResponse<Gene>, PrismerError>
Create a new gene.
Sourcepub async fn list_genes(
&self,
scope: Option<&str>,
) -> Result<ApiResponse<Vec<Gene>>, PrismerError>
pub async fn list_genes( &self, scope: Option<&str>, ) -> Result<ApiResponse<Vec<Gene>>, PrismerError>
List own genes.
Sourcepub async fn delete_gene(
&self,
gene_id: &str,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn delete_gene( &self, gene_id: &str, ) -> Result<ApiResponse<Value>, PrismerError>
Delete a gene.
Sourcepub async fn publish_gene(
&self,
gene_id: &str,
) -> Result<ApiResponse<Gene>, PrismerError>
pub async fn publish_gene( &self, gene_id: &str, ) -> Result<ApiResponse<Gene>, PrismerError>
Publish gene as canary.
Sourcepub async fn edges(
&self,
signal_key: Option<&str>,
gene_id: Option<&str>,
scope: Option<&str>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn edges( &self, signal_key: Option<&str>, gene_id: Option<&str>, scope: Option<&str>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get edges.
Sourcepub async fn personality(
&self,
agent_id: &str,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn personality( &self, agent_id: &str, ) -> Result<ApiResponse<Value>, PrismerError>
Get personality.
Sourcepub async fn list_scopes(
&self,
) -> Result<ApiResponse<Vec<String>>, PrismerError>
pub async fn list_scopes( &self, ) -> Result<ApiResponse<Vec<String>>, PrismerError>
List available evolution scopes.
Sourcepub async fn collect_metrics(
&self,
window_hours: u32,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn collect_metrics( &self, window_hours: u32, ) -> Result<ApiResponse<Value>, PrismerError>
Trigger metrics collection.
Sourcepub async fn search_skills(
&self,
query: Option<&str>,
category: Option<&str>,
limit: Option<u32>,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn search_skills( &self, query: Option<&str>, category: Option<&str>, limit: Option<u32>, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Search skills catalog.
Sourcepub async fn install_skill(
&self,
slug_or_id: &str,
scope: Option<&str>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn install_skill( &self, slug_or_id: &str, scope: Option<&str>, ) -> Result<ApiResponse<Value>, PrismerError>
Install a skill — creates cloud record + Gene, returns content for local install.
Pass scope to associate the install with a specific evolution scope.
Sourcepub async fn get_workspace(
&self,
scope: Option<&str>,
slots: Option<&[&str]>,
include_content: bool,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn get_workspace( &self, scope: Option<&str>, slots: Option<&[&str]>, include_content: bool, ) -> Result<ApiResponse<Value>, PrismerError>
Get workspace view — active genes/skills/memory visible to this agent.
scope filters by evolution scope, slots restricts returned slot types,
include_content embeds full SKILL.md content in the response.
Sourcepub async fn uninstall_skill(
&self,
slug_or_id: &str,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn uninstall_skill( &self, slug_or_id: &str, ) -> Result<ApiResponse<Value>, PrismerError>
Uninstall a skill.
Sourcepub async fn installed_skills(
&self,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn installed_skills( &self, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
List installed skills for this agent.
Sourcepub async fn get_skill_content(
&self,
slug_or_id: &str,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn get_skill_content( &self, slug_or_id: &str, ) -> Result<ApiResponse<Value>, PrismerError>
Get full skill content (SKILL.md + package info).
Sourcepub async fn install_skill_local(
&self,
slug_or_id: &str,
platforms: Option<&[&str]>,
project: bool,
project_root: Option<&str>,
) -> Result<(ApiResponse<Value>, Vec<String>), PrismerError>
pub async fn install_skill_local( &self, slug_or_id: &str, platforms: Option<&[&str]>, project: bool, project_root: Option<&str>, ) -> Result<(ApiResponse<Value>, Vec<String>), PrismerError>
Install a skill and write SKILL.md to local filesystem. Combines cloud install + local file sync for Claude Code / OpenClaw / OpenCode.
Sourcepub async fn uninstall_skill_local(
&self,
slug_or_id: &str,
) -> Result<(ApiResponse<Value>, Vec<String>), PrismerError>
pub async fn uninstall_skill_local( &self, slug_or_id: &str, ) -> Result<(ApiResponse<Value>, Vec<String>), PrismerError>
Uninstall a skill and remove local SKILL.md files.
Sourcepub async fn sync_skills_local(
&self,
platforms: Option<&[&str]>,
) -> Result<(usize, usize, Vec<String>), PrismerError>
pub async fn sync_skills_local( &self, platforms: Option<&[&str]>, ) -> Result<(usize, usize, Vec<String>), PrismerError>
Sync all installed skills to local filesystem.
Sourcepub async fn submit_report(
&self,
raw_context: &str,
outcome: &str,
task_context: Option<&str>,
task_error: Option<&str>,
task_id: Option<&str>,
metadata: Option<Value>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn submit_report( &self, raw_context: &str, outcome: &str, task_context: Option<&str>, task_error: Option<&str>, task_id: Option<&str>, metadata: Option<Value>, ) -> Result<ApiResponse<Value>, PrismerError>
Submit a raw-context evolution report (auto-creates signals + gene match).
Sourcepub async fn get_report_status(
&self,
trace_id: &str,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn get_report_status( &self, trace_id: &str, ) -> Result<ApiResponse<Value>, PrismerError>
Get status of a submitted report by traceId.
Sourcepub async fn get_achievements(
&self,
) -> Result<ApiResponse<Vec<Value>>, PrismerError>
pub async fn get_achievements( &self, ) -> Result<ApiResponse<Vec<Value>>, PrismerError>
Get evolution achievements for the current agent.
Sourcepub async fn get_sync_snapshot(
&self,
since: Option<u64>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn get_sync_snapshot( &self, since: Option<u64>, ) -> Result<ApiResponse<Value>, PrismerError>
Get a sync snapshot (global gene/edge state since a sequence number).
Sourcepub async fn sync(
&self,
push_outcomes: Option<Vec<Value>>,
pull_since: Option<u64>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn sync( &self, push_outcomes: Option<Vec<Value>>, pull_since: Option<u64>, ) -> Result<ApiResponse<Value>, PrismerError>
Bidirectional sync: push local outcomes and pull remote updates.
Sourcepub async fn export_gene_as_skill(
&self,
gene_id: &str,
slug: Option<&str>,
display_name: Option<&str>,
changelog: Option<&str>,
) -> Result<ApiResponse<Value>, PrismerError>
pub async fn export_gene_as_skill( &self, gene_id: &str, slug: Option<&str>, display_name: Option<&str>, changelog: Option<&str>, ) -> Result<ApiResponse<Value>, PrismerError>
Export a Gene as a Skill (export_gene_as_skill).