Hello fellow devs. I’ve built a “credits” end card for my YouTube channel using V1 of the API… but I was reading about some of the info that’s available (specifically campaign_lifetime_support_cents
and pledge_cadence
) that I had ideas on some awesome stuff I could do…
So I set about upgrading to V2, but soon realized I was missing a step somewhere and couldn’t find any info to help resolve my issues.
I’m writing this in PHP and I have run composer require patreon\patreon
. I successfully get a list of Patrons after running fetch_page_of_members_from_campaign
and I loop through these results running fetch_member_details
on each user… however the details I get back seem incomplete:
{
"data": {
"attributes": [],
"id": "<uuid>",
"relationships": {
"address": {
"data": null
},
"campaign": {
"data": {
"id": "<id>",
"type": "campaign"
},
"links": {
"related": "https:\/\/www.patreon.com\/api\/oauth2\/v2\/campaigns\/<id>"
}
},
"currently_entitled_tiers": {
"data": []
},
"user": {
"data": {
"id": "<id>",
"type": "user"
},
"links": {
"related": "https:\/\/www.patreon.com\/api\/oauth2\/v2\/user\/<id>"
}
}
},
"type": "member"
},
"included": [
{
"attributes": [],
"id": "<id>",
"type": "campaign"
},
{
"attributes": [],
"id": "<id>",
"type": "user"
}
],
"links": {
"self": "https:\/\/www.patreon.com\/api\/oauth2\/v2\/members\/<uuid>"
}
},
I can’t seem to find any relevant member data and (even more worrisome), running this function takes literal minutes for my campaign’s some 460 patrons.
I want to get the member’s info including their name, lifetime pledges, start date, current pledge status, number of post likes, my notes about the patron… but I’ve got no idea what am I supposed to do to get that info! Any help would be greatly appreciated!