This document describes how the Dynamic Entity Diagnostics page processes data.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β DYNAMIC ENTITY DIAGNOSTICS FLOW β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
STEP 1: Fetch Entity Definitions
βββββββββββββββββββββββββββββββββ
API ENDPOINT:
GET /obp/v5.1.0/management/system-dynamic-entities
Response:
{
"dynamic_entities": [
{
"dynamicEntityId": "abc-123",
"userId": "user-1",
"OGCR2Parcel": {
"description": "...",
"type": "object",
"properties": {...}
}
},
{ ... more entities ... }
]
}
Extract:
β Entity Name: "OGCR2Parcel"
β Entity ID: "abc-123"
β Schema: {...properties...}
STEP 2: For EACH Entity, Fetch Data Records
ββββββββββββββββββββββββββββββββββββββββββββ
API ENDPOINT:
GET /obp/dynamic-entity/{entityName}
Example:
GET /obp/dynamic-entity/OGCR2Parcel
Response (Raw):
{
"ogcr2_parcel_list": [
{ "ogcr2_parcel_id": "1", ... },
{ "ogcr2_parcel_id": "2", ... }
]
}
Process:
1. Store rawResponse = { "ogcr2_parcel_list": [...] }
2. Get responseKeys = ["ogcr2_parcel_list"]
3. Find keys ending with "_list" β ["ogcr2_parcel_list"]
4. Check if it's an array β YES
5. Count records β 2
STEP 3: Create Diagnostic Object
βββββββββββββββββββββββββββββββββ
(No API call - just processing)
{
"dynamicEntityId": "abc-123",
"entityName": "OGCR2Parcel",
"recordCount": 2, β Successfully counted!
"error": undefined, β No error
"schema": {...},
"responseKeys": ["ogcr2_parcel_list"],
"triedKeys": ["ogcr2_parcel_list"],
"rawResponse": {...} β Full API response saved
}
STEP 4: Display in UI
βββββββββββββββββββββ
(No API call - just rendering)
βββββββββββββββββββββββββββββββββββββββββββ
β OGCR2Parcel [Has Data] β
β ID: abc-123 β
β β
β Record Count: 2 β
β Schema Properties: 4 β
β β
β [View CRUD] [View Definition] β
β β
β βΆ Show Raw API Response β
β (Click to expand full JSON) β
βββββββββββββββββββββββββββββββββββββββββββ
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
SUMMARY OF API ENDPOINTS USED:
βββββββββββββββββββββββββββββββ
1. GET /obp/v5.1.0/management/system-dynamic-entities
β Fetches list of all entity definitions (called ONCE)
2. GET /obp/dynamic-entity/{entityName}
β Fetches data records for specific entity (called ONCE per entity)
β Examples:
- GET /obp/dynamic-entity/OGCR2Parcel
- GET /obp/dynamic-entity/OGCR2Project
- GET /obp/dynamic-entity/Person
If you have 10 entities, the diagnostics page makes:
- 1 API call to get all entity definitions
- 10 API calls to get data for each entity
- Total: 11 API calls