Person Spectrum
GET /portfolio/person/{id}/spectrum
Returns the aggregated OpenAlex research spectrum for one person.
Parameters
| Parameter | Type | Description |
|---|---|---|
id (path) |
string | Person MongoDB ObjectID. |
apikey |
string | Portfolio API key, if configured; alternatively use X-API-Key. |
limit |
integer | Maximum list rows. A positive value enables shared pagination. |
offset |
integer | List rows to skip with limit. Defaults to 0; negative values become 0. |
Authentication, pagination, and error envelopes are described in Portfolio API Basics. Parameters such as json, filter, columns[], full, and aggregate are not supported unless listed here.
Example Request
1 | |
Example Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | |
The example uses illustrative values. Optional stored or rendered fields may be omitted. Response count is the number of returned list rows before shared pagination.
Returned Fields
| Field | Description |
|---|---|
_id |
OpenAlex topic ID, e.g. T12345. |
count |
Number of assigned topic occurrences in matching publications. |
sumScore |
Sum of stored topic scores. |
topic |
First stored OpenAlex topic object for this group, including available ID/name/score/hierarchy metadata. |
total |
Number of matching publications with non-empty assigned OpenAlex topics. |
avg_score |
sumScore / count. |
share |
count / total. |
weight |
(count / total) * (sumScore / total). |
Response Behavior
Resolves a visible person ObjectID to a username and matches publication rendered.users. Inactive persons remain accepted. This standalone handler passes helper entity persons, so the four-publication minimum used by the embedded person profile (helper entity person) does not apply.
Requires publication type=publication and non-empty openalex.topics. The spectrum helper does not add hide, affiliation, or workflow restrictions. Topics below 5% share are discarded; remaining topics are sorted by weight descending and capped at 25 before shared pagination. Response count is the retained number of topics, not source publications.
When portfolio-spectrum is disabled, or no matching assignments exist, returns a successful empty array. The local data contained no spectrum rows; the non-empty example follows the helper implementation.
Errors
With the feature enabled, a missing/hidden person returns 404 DataNotFound with msg: "Person not found".