Hi codebard! Thank you so much for your reply.
I don’t know what this forum would do without you!
Yes, to both your questions.
It’s difficult to figure out what exactly is going on as I didn’t create our API script myself (it was outsourced), but I’ve been testing with Insomnia and I think the problem is that using APIv1 you can get all the user data immediately with a single query, while with APIv2 additional queries have to be performed for each user to get the necessary data. Here’s a part of the APIv2 script (with the call):
public function fetch_page_of_members_from_campaign($campaign_id, $page_size, $cursor = null) {
$url = "campaigns/{$campaign_id}/members?page".urlencode('[count]')."={$page_size}";
if ($cursor != null) {
$escaped_cursor = urlencode($cursor);
$url = $url . "&page".urlencode('[cursor]')."={$escaped_cursor}";
}
return $this->get_data($url."&include=currently_entitled_tiers,address&fields".urlencode('[member]')."=full_name,is_follower,last_charge_date,last_charge_status,lifetime_support_cents,currently_entitled_amount_cents,patron_status&fields".urlencode('[tier]')."=amount_cents,created_at,description,discord_role_ids,edited_at,patron_count,published,published_at,requires_shipping,title,url");
}
public function fetch_member_details($member_id) {
return $this->get_data("members/{$member_id}?include=address,campaign,user,currently_entitled_tiers&fields".urlencode('[member]')."=full_name,is_follower,email,last_charge_date,last_charge_status,lifetime_support_cents,patron_status,currently_entitled_amount_cents,pledge_relationship_start,will_pay_amount_cents&fields".urlencode('[tier]')."=title&fields".urlencode('[user]')."=full_name,hide_pledges");
}
It still shouldn’t take hours though to go through 1000+ users.