Repository navigation
feat(platform): add list_entity_summaries for one page of entities - #1885
wilcobrouwer wants to merge 2 commits into
Conversation
|
There was a problem hiding this comment.
🟢 Approval recommended
The change is backward compatible by default, correctly gated to v1-only behavior, and includes targeted sync/async tests for the new functionality.
Pull request overview
This PR adds an opt-in way to list Data Service entities without returning each entity’s full fields schema, reducing response size (and traced span size) for tenants with many entities while keeping default behavior unchanged.
Changes:
- Added
include_fields: bool = TruetoEntitiesService.list_entities()/list_entities_async()and routedinclude_fields=Falseto the v1/Entity/simpleendpoint. - Extended the internal
EntitySchemaServicelist methods/spec builder to supportinclude_fields, rejectinginclude_fields=Falsewhenuse_v3=True. - Added sync/async tests for the “simple” route behavior and a test asserting v3 rejection; bumped
uipath-platformto0.2.27.
File summaries
| File | Description |
|---|---|
| packages/uipath/uv.lock | Updates locked uipath-platform version to 0.2.27. |
| packages/uipath-platform/uv.lock | Updates local package lock version to 0.2.27. |
| packages/uipath-platform/tests/services/test_entities_service.py | Adds coverage for listing entities without field schemas (sync/async) and v3 rejection behavior. |
| packages/uipath-platform/src/uipath/platform/entities/_entity_schema_service.py | Implements include_fields routing to /Entity/simple and enforces v1-only support. |
| packages/uipath-platform/src/uipath/platform/entities/_entities_service.py | Exposes include_fields on public list methods and documents the behavior. |
| packages/uipath-platform/pyproject.toml | Bumps package version to 0.2.27. |
Review details
- Files reviewed: 4/6 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
8dc0ec0 to
abf78b1
Compare
3b4a4ac to
fa4997d
Compare
8071a40 to
b623559
Compare
🚨 Heads up:
|
icpsoni
left a comment
There was a problem hiding this comment.
I would suggest to have a new method return Paginated data instead of modifying the current one based on some parameter.
Also please start accepting page number etc into new method with default value.
b623559 to
d60ede2
Compare
🚨 Heads up:
|
d60ede2 to
d4f040e
Compare
list_entity_summaries(skip, top) returns one PagedResult page from GET datafabric_/api/v3/entities/paginated, which lists the same entities as GET /v3/entities without loading their field schemas. Bumps uipath-platform to 0.3.3. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
d4f040e to
502cadd
Compare
|



Why
list_entities_v3()returns every entity with its fullfieldsschema. On a tenant with many entities that is a large response, and@tracedstores it in the span as well. Callers that only need names and ids (for example to resolve an entity id by name) pay for every field definition.The backend's
GET datafabric_/api/v3/entities/paginatedroute (built for the Data Fabric entity grid) lists the same entities without the field schemas,recordCountor the storage sizes. Measured on 2026-11-04 with read-only GETs against one of our production tenants (11 entities, 201 fields in total), median of 5 runs:fieldsGET datafabric_/api/v3/entitiesGET datafabric_/api/v3/entities/paginatedBoth routes return the same 11 entity ids. The full listing grows with the number of entities and their fields; the summaries grow only with the number of entities.
What changed
list_entity_summaries(skip=0, top=50)and its async variant. Each call returns onePagedResult[Entity]page fromGET /v3/entities/paginated, without field schemas (fields,record_countand the storage sizes areNone).has_morecomes from the route'stotalCount, andtopis capped at 200, the backend's maximum.list_entities_v3()is unchanged.uipath-platformto 0.3.3.Testing
topabove 200.list_entity_summariesreturned the same 11 ids aslist_entities_v3(), all withfields=None;top=5paged through them in 3 calls withhas_moreending the loop;skippast the end returned an empty page withhas_more=False; the async variant returned the default page withhas_more=False;top=201is rejected before any request. Through the SDK, the full listing took 666 ms and the summaries 203 ms.🤖 Generated with Claude Code