Hello,
In my app I need to differentiate users based on if they are:
- Subscribed to my patreon
- The tier they have subscribed
I’ve implemented the “log in with Patreon” button with the scope: “identity”
Then I use their access token to request (as I’ve seen on this forum multiple times and in the PHP doc):
My question est extremely simple:
Is my patreon (campaign) always the first index (index: 0) of the ‘included’ property?
If yes, then I can use to check their authorizations:
$data['included'][0]['attributes']['currently_entitled_amount_cents'];
$data['included'][0]['attributes']['patron_status'];
Or should I map over the included results and check their related campaign’s id to find my campaign?
$data['included'][0]['relationships']['campaign']['id'];
Thanks for your help!