Get Portfolio Indicators
const url = 'https://indepai.app/api/v1/indicators?portfolioId=550e8400-e29b-41d4-a716-446655440000';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://indepai.app/api/v1/indicators?portfolioId=550e8400-e29b-41d4-a716-446655440000' \ --header 'Authorization: Bearer <token>'Returns the five portfolio indicators. Optionally scopes the calculation to one portfolio and one to three focused cities.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Scope to one portfolio (omit = all holdings)
Example
550e8400-e29b-41d4-a716-446655440000One to three comma-separated city slugs to model in the supplied order
Responses
Section titled “Responses”Portfolio indicators calculated successfully
object
Unique identifier (UUID v4)
All five indicators in fixed order; each may carry status:‘pending’
object
Indicator key
Sub-metric / indicator status
Per-indicator computed bundle
object
Example
{ "portfolioId": "550e8400-e29b-41d4-a716-446655440000", "indicators": [ { "key": "fire-coverage", "status": "ok" } ]}Invalid portfolio or city scope
object
Always false for error responses
Error type
Machine-readable error code
Detailed validation errors
object
Path to the invalid field
Error message
Example
{ "success": false, "error": "Validation error", "code": "VALIDATION_ERROR", "details": [ { "path": "currentAge", "message": "Must be between 18 and 100" } ]}Authentication required
object
Always false for error responses
Error type
Machine-readable error code
Detailed validation errors
object
Path to the invalid field
Error message
Example
{ "success": false, "error": "Validation error", "code": "VALIDATION_ERROR", "details": [ { "path": "currentAge", "message": "Must be between 18 and 100" } ]}