I may be missing something obvious, but can you search for main url of a post? Trying avoid posting duplicate content. The search doesn’t seem to check the url field for local or all search options.
I may be missing something obvious, but can you search for main url of a post? Trying avoid posting duplicate content. The search doesn’t seem to check the url field for local or all search options.
I’m not sure of any programs that will do this for you but Lemmy has a pretty nice API that you can use and there are libraries you can use for languages like JavaScript: https://github.com/LemmyNet/lemmy-js-client
Edit: This can also be done without the library, got me interested and I’ve been playing with it.
This is essentially what the library does when you don’t need authentication:
https://beehaw.org/api/v3/search?listing_type=Local&q=https%3A%2F%2Fwww.huckmag.com%2Farticle%2Fsex-workers-and-the-kink-community-are-fighting-back-against-instagram-deplatforming&sort=TopNineMonths&type_=Url
This is the function they’re using to URL encode the FormData and it just gets pasted onto “https://www.beehaw.org/api/v3/[endpoint]?”:
Ah, thanks. I should have given the API a look. I’ll see if I can write something that will do what I need.
If reading through all the JS and/or Rust is frustrating, theres programs to read it into easier to parse formats.