Constituent list return empty "value": []
Hello and thank you for the help in advance.
Description:
I am working on a data integration project using the Sky Api and I have successfully used the Constituent list endpoint to retrieve data following the Documentation.
this is the initial api call:
and the next 3 calls to the next_link look like this:
https://api.sky.blackbaud.com/constituent/v1/constituents?sort_token=ew0KICAiRGF0ZSI6ICIyMDIxLTA0LTI3VDE3OjA4OjEwLjk4NC0wNDowMCIsDQogICJJZCI6ICIzMTQ2NTIiLA0KICAiQ29sdW1uIjogNDMsDQogICJEaXJlY3Rpb24iOiAwDQp9&limit=5000&offset=0
Problem:
I am trying to get all the data, After my PHP script has retrieved around 70,000 records looping through the pages using the (nextlink, limit, offset, and last_modified) and waiting for 1 second in the script after each call the api calls start to return an empty “value”[ ], see examples of this below
this is the api call:
https://api.sky.blackbaud.com/constituent/v1/constituents?sort_token=ew0KICAiRGF0ZSI6ICIyMDI0LTA0LTEwVDE2OjUxOjI5LjUzMS0wNDowMCIsDQogICJJZCI6ICI1MjEzNDIiLA0KICAiQ29sdW1uIjogNDMsDQogICJEaXJlY3Rpb24iOiAwDQp9&limit=5000&offset=70000
this is the api result:
{"count":11676,"next_link":"https://api.sky.blackbaud.com/constituent/v1/constituents?sort_token=ew0KICAiRGF0ZSI6ICIyMDI0LTA0LTEwVDE2OjUxOjI5LjUzMS0wNDowMCIsDQogICJJZCI6ICI1MjEzNDIiLA0KICAiQ29sdW1uIjogNDMsDQogICJEaXJlY3Rpb24iOiAwDQp9&limit=5000","value":[]}
I know that the number of records is over 500000 given in the “count” field
Maybe I missed something in the documentation, some help will be appreciated
thank you,
Yoaime Hernandez, BI Data Warehouse Architect
305-348-8074, yrhernan@fiu.edu
University Advancement
Florida International University
Comments
-
@Yoaime Hernandez
if you are using last_modified and next_link, you do not need to use offset.start off with:
?limit=5000&include_inactive=True&include_deceased=True&last_modified=1970-01-01
then from there simply use next_link.
You will check from the returned results, the COUNT property, and stop the looping when COUNT = 0
1 -
@Alex Won
Thank you very much for your response
0
Categories
- All Categories
- 6 Blackbaud Community Help
- 206 bbcon®
- 1.4K Blackbaud Altru®
- 394 Blackbaud Award Management™ and Blackbaud Stewardship Management™
- 1.1K Blackbaud CRM™ and Blackbaud Internet Solutions™
- 15 donorCentrics®
- 357 Blackbaud eTapestry®
- 2.5K Blackbaud Financial Edge NXT®
- 646 Blackbaud Grantmaking™
- 561 Blackbaud Education Management Solutions for Higher Education
- 3.2K Blackbaud Education Management Solutions for K-12 Schools
- 934 Blackbaud Luminate Online® and Blackbaud TeamRaiser®
- 84 JustGiving® from Blackbaud®
- 6.4K Blackbaud Raiser's Edge NXT®
- 3.6K SKY Developer
- 242 ResearchPoint™
- 118 Blackbaud Tuition Management™
- 165 Organizational Best Practices
- 238 The Tap (Just for Fun)
- 33 Blackbaud Community Challenges
- 28 PowerUp Challenges
- 3 (Open) Raiser's Edge NXT PowerUp Challenge: Product Update Briefing
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Standard Reports+
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Email Marketing
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Gift Management
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Event Management
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Home Page
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Standard Reports
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Query
- 778 Community News
- 2.9K Jobs Board
- 53 Blackbaud SKY® Reporting Announcements
- 47 Blackbaud CRM Higher Ed Product Advisory Group (HE PAG)
- 19 Blackbaud CRM Product Advisory Group (BBCRM PAG)
