just wanted to ask this bc lemmy supposedly has public upvotes/downvotes and I don’t know if kbin has it too

  • ZickZack@kbin.social
    link
    fedilink
    arrow-up
    31
    ·
    1 year ago

    Everything using the activityPub standard has open likes (see https://www.w3.org/TR/2018/REC-activitypub-20180123/ for the standard), and logically it makes sense to do this to allow for verification of “likes”:
    If you did not do that, a malicious instance could much more easily just shove a bunch of likes onto another instance’s post, while, if you have “like authors” it’s much easier to do like moderation.
    Effectively ActivityPub treats all interactions like comments, where you have a “from” and “to” field just like email does (just imagine you could send messages without having an originator: email would have unusable levels of spam and harassment).
    Specfically, here is an example of a simple activity:

    POST /outbox/ HTTP/1.1
    Host: dustycloud.org
    Authorization: Bearer XXXXXXXXXXX
    Content-Type: application/ld+json; profile="https://www.w3.org/ns/activitystreams"
    
    {
      "@context": ["https://www.w3.org/ns/activitystreams",
                   {"@language": "en"}],
      "type": "Like",
      "actor": "https://dustycloud.org/chris/",
      "name": "Chris liked 'Minimal ActivityPub update client'",
      "object": "https://rhiaro.co.uk/2016/05/minimal-activitypub",
      "to": ["https://rhiaro.co.uk/#amy",
             "https://dustycloud.org/followers",
             "https://rhiaro.co.uk/followers/"],
      "cc": "https://e14n.com/evan"
    }
    
    

    As you can see this has a very “email like” structure with a sender, receiver, and content. The difference is mostly that you can also publish a “type” that allows for more complex interactions (e.g. if type is comment, then lemmy knows to put it into the comments, if type is like it knows to put it to the likes, etc…).
    The actual protocol is a little more complex, but if you replace “ActivityPub” with “typed email” you are correct 99% of the time.

    The different services, like lemmy, kbin, mastodon, or peertube are now just specific instantiations of this standard. E.g. a “like” might have slightly different effects on different services (hence also the confusion with “boosting” vs “liking” on kbin)