aka [email protected], [email protected], and any username from lemmon.website

  • 1 Post
  • 17 Comments
Joined 1 year ago
cake
Cake day: July 17th, 2023

help-circle
  • freamon@endlesstalk.orgtoLemmy@lemmy.mlHow to download account data?
    link
    fedilink
    English
    arrow-up
    6
    arrow-down
    1
    ·
    4 months ago

    No settings page (as far as I’m aware), but you can use the API to get everything (posts, comments, etc):

    step 1: get login token -

    curl --request POST \
         --url https://lemmy.ml/api/v3/user/login \
         --header 'accept: application/json' \
         --header 'content-type: application/json' \
         --data '
    {
      "username_or_email": "2br02b",
      "password": "YOUR-PASSWORD"
    }
    '
    

    step 2: use login token (big long string starting with ‘ey’) to get data -

    curl --request GET \
         --url 'https://lemmy.ml/api/v3/user?username=2br02b&page=1' \
         --header 'accept: application/json' \
         --header 'authorization: Bearer YOUR-JWT'
    

    Increment page number until you have everything. source: https://lemmy.readme.io/reference/get_user







  • Regarding the ‘Unresolved questions’ part, the ActivityPub activity for Reports is:

    {
      "actor": "http://ds9.lemmy.ml/u/lemmy_alpha",
      "to": ["http://enterprise.lemmy.ml/c/main"],
      "audience": "http://enterprise.lemmy.ml/u/main",
      "object": "http://enterprise.lemmy.ml/post/7",
      "summary": "report this post",
      "type": "Flag",
      "id": "http://ds9.lemmy.ml/activities/flag/98b0933f-5e45-4a95-a15f-e0dc86361ba4"
    }
    

    From this page. I imagine it’s up to lemmy where this actually gets sent (in the sense that if a community has 1 moderator, it goes to 1 inbox, but if it has 2 moderators, it goes to 2 inboxes).







  • The short answer is that you have to ask blahaj.zone to resolve it. lemmy.ml has it as post id 11470168, but it’ll be different for other instances - whatever the next number was in their database when the post was announced.

    You get different answers depending on whether you’re logged in or not though.
    From endlesstalk.org, I can search for that post in the web-ui: Communities -> paste the post url into Search -> Change the Type from ‘communities’ to ‘posts’
    Alternatively, using the API, I can resolve it with
    curl --header 'accept: application/json' --header 'authorization: Bearer MY_LOGIN_TOKEN' https://endlesstalk.org/api/v3/resolve_object?q=https://lemmy.ml/post/11470168

    I’m not logged into blahaj.zone though, so it won’t resolve it. The web-ui only gives me this post as one that mentions the thing I’m searching for, and the API returns ‘not found’



  • I would argue that I’m not asking it to be a queryable thing or a datastore. I wouldn’t expect a community’s ‘Accept’ of a ‘Follow’ to contain loads of data about past activity because that’s not a logical or practical thing to encapsulate. For an Undo though, there’s already a small, fixed-length encapsulated object inside, consistent with how ActivityPub is used for other circumstances. Since it’s there anyway, I don’t see the value in it containing incorrect, made-up data, when it may as well have the correct data.