Skip to content

Add server-side search and filtering to ListAgents API #68

@Kavirubc

Description

@Kavirubc

Summary

The current ListAgents API fetches all agents and performs pagination in memory. This approach doesn't scale well as the number of agents grows. Additionally, the frontend currently performs search filtering client-side.

Proposed Changes

agent-manager-service

  • Add query parameters to ListAgents endpoint:
    • search - text search across agent name, displayName, and description
    • provisioningType - filter by provisioning type (internal, external, api)
    • sortBy - sort field (name, createdAt, updatedAt)
    • sortOrder - sort direction (asc, desc)
  • Implement database-level filtering and pagination using GORM
  • Return total count for proper pagination

console

  • Connect existing search UI to backend search parameter
  • Add debouncing to search input to reduce API calls
  • Remove client-side filtering logic

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions