feat(routing): add dynamic agent profile routing (#2698)
This commit is contained in:
@@ -513,12 +513,19 @@ export class ApiClient {
|
||||
"GET",
|
||||
"/api/v1/agents",
|
||||
);
|
||||
return {
|
||||
...response,
|
||||
agents: response.agents.map((agent) => ({
|
||||
// The Dynamic family is intentionally ranked first by the product API so
|
||||
// settings can present its dedicated card first. Most E2E profile
|
||||
// factories predate virtual families and use the first agent as a
|
||||
// launchable owner, so keep concrete families first in this test client.
|
||||
const agents = response.agents
|
||||
.map((agent) => ({
|
||||
...agent,
|
||||
profiles: (agent.profiles ?? []).map(normalizeAgentProfile),
|
||||
})),
|
||||
}))
|
||||
.sort((a, b) => Number(a.id === "dynamic") - Number(b.id === "dynamic"));
|
||||
return {
|
||||
...response,
|
||||
agents,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user