-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request] PronounDB integration/public facing api for querying pronouns based on social media handles/ids #47
Comments
I'm happy to do whatever to make this easier for @cyyynthia if she wants to integrate somehow. But it does seem like pronouny and pronoundb have quite different approaches to neopronouns and custom sets which might make this impossible. My end goal with pronouny was an API and that never really panned out so would love to support https://pronoundb.org/ however I can if you need anything. |
Also pronouny already has an API to pull pronouns out of a given username (eg: https://pronouny.xyz/api/users/profile/username/noa). You could use this to import pronouny data if you liked. If you wanted to use this with whitelisting I would suggest using the listed field on the pronouns but you could do other ways as well. |
Ah, I didn't know you have an API. I'd def put some docs somewhere on the site since I didn't see any there. Like if you had some button called "API" with some simple docs, that'd suffice. (or even if it just redirected you to a github wiki with all the details) But as for neopronouns, based on what I've seen on one of the pronoundb issues, (cyyynthia/pronoundb.org#3), they're open to allowing uses to use neopronouns, but just don't have a good enough UI for them, nor do they have a good method of adding all the neopronouns someone might want. Also, one thing I'd like to point out is that it seems the API returns following, but not followers. This isn't a feature that's needed by any means, but is this intentional? (Also, I'm assuming anyone in the "friends" category is someone who's both following + followers) It also seems you've listed ids for individual pronouns and users. Is there a way to query that from the API, or no? |
@solonovamax The API docs aren't public because the API is for internal use. I made it when I was just starting to learn web development and it's not the most sensible thing. I wanted to make a public facing one seperately, but have not had time for this. As for the specific API questions
|
And as for API routes you can look at https://github.com/pronouns/main/blob/master/modules/users/server/routes/users.server.routes.js for user related ones and https://github.com/pronouns/main/blob/master/modules/pronouns/server/routes/pronouns.server.routes.js for pronoun related ones. Some are restricted to logged in users only but that should be fairly obvious I hope. |
I've decided to not support them due to the additional maintenance troubles this would bring and the moderation issues in case of custom sets. The format PronounDB uses to store pronoun sets is also rather incompatible with such (although it could always be worked around and/or changed). It's also worth noting that despite not having a large userbase, the pronoundb.org domain has been handling 2M+ requests for the past month and has been distributing in total 1.9GB of data. Not working with identifier-based pronouns and shove them entirely in the payload would (in a pessimistic scenario) multiply by 2 the outbound traffic, which is something I'd be more than happy to avoid. It also completely kills any hopes of decent internationalization which is something I may want to look into in the future.
This sounds more like merging projects than integrating, but w/e. The problem for me here is that PronounDB is no longer the data broker for pronouns which makes me dependent on a third-party service for the provision of data, the format of the data I receive, and any form of legal text the third-party is using (Privacy Policy or Terms of Use for example).
As falkirks mentioned, the differences between the approaches we've taken on pronouns handling makes integrating a hassle, and you'd at best only get a partial integration. But, if you really wish to try, either Pronouny or PronounDB in a safe & robust manner, one of the services would have to implement an OAuth layer, so the other can go through an authorization flow before the data is passed. You can't just expect users to throw in a text field their ID and expect things to work. Also note that, because of French laws which pronoundb.org abides by, I will not be sharing all of someone's linked accounts & their pronouns to a third party without their explicit approval (so through an OAuth screen). This is to ensure no sensitive information is leaked out to the public, and because it'd be disrespectful for user's privacy.
Sure, but people also make different and incompatible choices, and some prefer to be lone wolves 🐺 |
This is such a huge issue and something that I didn't think about when building Pronouny. I'm glad that's something PronounDB might support nicely in future.
Yeah I'm also unsure what the purpose of this would be. I don't think any of the pronouny code or sytems should really be relied on in a continuing way. Things are quite fragile and brittle. But you are welcome to any of my code if it helps (but I really doubt it will) and I am happy to relicense my contributions if there are legal issues with your license.
I am at ~25M and 279.5 GB this month so I think your way of handling data is far more sustainable lol
I also want to add that I value the choices you made and the reasoning you put into them. I made this app for a specific and different context. And if you do ever want support with PronounDB I am really excited about software like this and happy to take issues or provide some server space (although it sounds like your requirements around that are fairly specific). |
You also have more data to carry than me from what I've seen, and if I really wanted to optimize the payload sizes I could use shorter keys; it's not something I'm too worried about, but keeping it down is still preferable.
I'm fine with the hardware I currently have and I can afford an upgrade if necessary, I could even afford spinning up a k8s cluster and let the cloud:tm: magic scale up infinitely for me. Scaling up a project like PronounDB is super easy since it's literally spawning a new instance and balancing the load between the two (or getting a new server and let Cloudflare do the job), compared to some of my other projects with involve real time communication and where I need to be able to pass messages around the entire cluster in a few ms, not the same level! Thanks for the proposal though, appreciate it 😄 As for maintenance help, for now there are not many modules and the server-side abstraction lets me add new platforms in a matter of minutes on that end. The only tricky part is smoothly integrating into the apps, which is easy but time consuming. For now since I haven't reached version 1 things are rather volatile (the structure might change, the extension popout will definitely get a complete rework, ...) but in the future contributing will be much easier if you really want to help out! |
ye, this issue was never made as a "this is something that needs to be done now" I made it more as a "hey, those two things to some cool stuff that's kinda similar. Is there maybe a way to integrate them?? Because that'd be pretty cool."
Fair. Time is pretty hard to come by nowadays.
Yeah, when I said "set up some basic thing for pronoundb that allows you to connect a pronouny" I meant more "I'll set up a simple text field and some really simple (and probably very bad) code that sends out HTTP requests as a POC to see how something like this might work in a real implementation" I wasn't thinking that I could make something that would actually be used, just something I could host locally and mess around with.
That's fair. As someone who cares a lot about privacy, I completely understand wanting to keep your users' privacy. But one option for a kind of pronouny integration would be to have the API just return their pronouny username, which an application could then use to query the pronouns there. Of course, you'd have a nice big sign saying "this will share your pronouny username publicly, are you okay with that" to any user attempting to enable it. (This isn't really a long term solution. This is just me throwing out ideas and seeing what others have to say about them. I understand that designing web apis isn't a quick and easy thing, and it's something you need to put thought into.)
Of course. I completely understand that. I just wasn't sure whether both projects were aware of each other, and thought something cool might come of it. As I said at the start, this isn't anything that I see happening in the near future. This is just me saying "this would be pretty cool if it could theoretically happen" and just shitting out ideas and whatnot. |
There's another project, pronoundb, which allows you to query an API to return someone's pronouns using a social media handle/id that they have authorized.
So if I were to sign up to pronoundb with my discord which had the theoretical id of
123456
, then I'd be able to send a request tohttps://pronoundb.org/api/v1/lookup?platform=discord&id=123456
and it would return a json object specifying my pronouns.Right now, we currently have 2 different services that basically accomplish the same task. (Of allowing people to share their pronouns)
So, I'm opening this issue because I think it'd be worthwhile to merge the functionality of the two services.
You could make the service entirely opt-in for the user, so nobody would be at risk of accidentally exposing themselves.
And if you don't feel like making all the required features for supporting a bunch of different site integrations, then you could just make a public-facing API that allows people to query the pronouns of an arbitrary pronouny user, which could then be integrated into pronoundb, thereby separating the two services but allowing them to interact with each other.
TL;DR cool people know how to write cool code, and I think they should integrate their code so it can work together and make cooler code.
Also, I'm @'ing @cyyynthia because she's the owner of the pronoundb repo and I'm too lazy to make two issues for this lol
The text was updated successfully, but these errors were encountered: