-
Notifications
You must be signed in to change notification settings - Fork 25
Open
Description
openalexR will split large filters in multiple requests of 50 values:
Lines 114 to 125 in e116c3e
| # overcome OA limitation of combining 50 values (OR) for a filter at a time | |
| # https://docs.openalex.org/how-to-use-the-api/get-lists-of-entities/filter-entity-lists#addition-or | |
| # here, we assume there is only ONE "large" filter | |
| large_filter <- which(lengths(filter) > 50) | |
| if (length(large_filter) == 0) { | |
| list_id <- list(`1` = NULL) | |
| } else { | |
| list_id <- split( | |
| filter[[large_filter]], | |
| ceiling(seq_along(filter[[large_filter]]) / 50) | |
| ) | |
| } |
However, it seems that the limit of 50 was raised to 100 last year (or at least the docs were updated at that time):
ourresearch/openalex-docs@db68a28
Could openalexR be updated to reflect this so the number of API calls can be cut in half?
Metadata
Metadata
Assignees
Labels
No labels