• Sage the Lawyer@lemmy.world
    link
    fedilink
    arrow-up
    7
    ·
    1 year ago

    I still don’t know what an API is. But people who know more about it than me have told me in no uncertain terms that spez is scum for it, and I was able to confirm that because he put his whole ass on display in that AMA, and so here I am.

    • bozo@kbin.social
      link
      fedilink
      arrow-up
      6
      ·
      1 year ago

      A loose analogy would be to compare it to a restaurant kitchen. The kitchen serves up food for customers dining in (official Reddit app) but also has a takeout window (the API) which anyone can use to get their food without having to go into the restaurant (3rd party apps).

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

      An Application Programming Interface (API) is basically a way to let apps communicate with the server (Reddit, in this case) directly, in ways that are faster and more efficient (but less user friendly) than the site page.

      For apps, having an API for Reddit meant that they could just ask Reddit directly for a list of posts, and submit any interactions without having to pretend to be a user and “read” the site, which might break as soon as Reddit changed something, like redesigning the website.

      For Reddit, that meant that it didn’t need to send the apps a whole page, and waste valuable bandwidth/processing power. It could just send the relevant bits the apps needed, and save resources/cost.

      Running an API isn’t free, since it is basically another part of the site to maintain and deal with. Reddit officially claims that the costs associated with the API (from sending the data to apps) are too great, which why they are clamping down on it, and increasing costs so significantly (although it is worth noting that the numbers are orders of magnitude higher than the API costs for similar services, like Imgur, and higher than what Reddit’s own costs would be, so take with a mountain of salt).

    • bobaduk@lemmy.world
      link
      fedilink
      arrow-up
      1
      ·
      1 year ago

      It’s just a website, but for computers. Instead of returning HTML, that your browser can render, it returns structured data that’s easier to read with a computer program, like a 3rd party app or a bot.

      You could just fetch the website and pull information from that, but HTML is awkward to read, and has a lot of data for display purposes that you don’t need for other use cases .