Is there such a thing? Like a like button, maybe showing the number of patrons? I had a brief look around but could not find something like that.
I donât believe anything like this exists currently. You could easily create a script that generates one for yourself server-side though. I think youâre out of luck for a purely client-side implementation, for now.
Great question. Okay so thereâs a few answers:
- Every creator has a widget they can embed found here https://www.patreon.com/dashboard/widgets
-
We do have a way to make it easy for a third party developer to generate those on behalf of creators given their public âvanityâ url. Itâs admittedly poorly documented, and Iâm happy to share that here if itâs helpful
-
Nothing so far on # patrons, goals, etc. We love the idea of it - and decided that weâd be better off focusing our team on the REST API and Webhooks for the time being.
@wackazong curious and interested to hear more about your context and use case
Oh? Whatâs this? Share! Share!
Here goes, first time this is being revealed publicly drumrollâŚ
And if this is interesting enough we can include in the docs.
How to create widgets on behalf of creators
-
Your appâs UI asks its users for their patreon URL
-
Your app code calls GET https://api.patreon.com/platform/users?filter[patreon_url]=${their patreon url} Note that only the GET value changes for each user, the GET key is static
-
Patreon returns JSON containing the user id:
data: {
type: 'user',
id: {their user id},
...
},
...
}
-
Your app should probably save the returned Patreon user id in your users database since it will not change
-
When rendering the widget for a given individual creator, put this HTML snippet in their page:
<a href="https://www.patreon.com/bePatron?u={their user id}" data-patreon-widget-type="become-patron-button">Become a Patron!</a><script async src="https://cdn6.patreon.com/becomePatronButton.bundle.js"></script>
cc @david who built this a few months ago
Also cc @codebard I know this may be interesting to some of the work youâve mentioned in the past
Ooo, awesome! I definitely have a use for this.
And please tell me that the filter[]
query will show up in more places. Itâs so beautifulâŚ
Thanks, I took a note of this.
I made current version of my Patron Pro plugin get creator id automatically to use in widgets and urls. I may look into adding it to my widgets plugin in future if anyone uses it without Pro version.
Thanks for all the great answers! I was looking for the widget, that is what I need. @tal, I built a small gate application for every free link that I give out. It fetches some metadata from the link it points to (like a soundcloud track) and presents the user with a page where they can (not must) support me in some way, FB like, soundcloud follow, etc. There I would also like to place the widget.
Thanks again!
this is probably an old post , but as i am going through this , for some reason i am getting empty results object
{
âdataâ: []
}
this is how i make the request
axios.get(âhttps://api.patreon.com/platform/users?filter[patreon_url]=${https://www.patreon.com/theralphreport}â).then((res)=>{
console.log(res.data);
})
am i missing something here ?
if i need to inject my token or client_key please give me an example of how do i do that.
${their patreon url}
This is the token that should be replaced completely, i.e, it becomes:
https://www.patreon.com/theralphreport
Therefore, the complete code isâŚ
axios.get('https://api.patreon.com/platform/users?filter[patreon_url]=https://www.patreon.com/theralphreport').then((res)=>{
console.log(res.data);
})
Hello, I am a young but very ambitious karting pilot. Just Because it is a very expensive sport, i am looking for people who can contribute me to my dreams of becoming a champion. My all posts are currently in Lithuanian, but if you are in the process of joining, the recordings will become English.
What is the difference between a button that is generated from https://www.patreon.com/dashboard/widgets with a custom button that links to the checkout page?
They are technically the same widget, however the widget from the Button and Widgets Plugin can put your visitors directly into pledge flow (to become a member) at Patreon if you have Patron Plugin Pro (a premium addon). That helps increase conversion.
I know this was a few years ago; but currently it sadly does not work for me, the image doesnât show up even if I paste the custom.
âhttps://c6.patreon.com/becomePatronButton.bundle.jsâ
Iâm thinking that maybe this is the problem?
That custom JS widget is likely unmaintained. You may need to make your own custom one. You dont need to use JS for that, a button with a simple link that puts your users into the pledge flow should be enough.