Spacc BBS Spacc BBS
    • Categorie
    • Recenti
    • Tag
    • Popolare
    • Mondo
    • Utenti
    • Gruppi
    • Registrati
    • Accedi
    La nuova BBS è in fase Alpha. I post precedenti al 22 luglio 2024 potrebbero non essere trasferibili, ma rimarranno disponibili per la lettura su /old/.

    Recommend object URL should 301 to AP resource

    Pianificato Fissato Bloccato Spostato Uncategorized
    activitypubghostdiscourse
    15 Post 6 Autori 0 Visualizzazioni
    Caricamento altri post
    • Da Vecchi a Nuovi
    • Da Nuovi a Vecchi
    • Più Voti
    Rispondi
    • Topic risposta
    Effettua l'accesso per rispondere
    Questa discussione è stata eliminata. Solo gli utenti con diritti di gestione possono vederla.
    • julian@community.nodebb.orgJ Questo utente è esterno a questo forum
      julian@community.nodebb.org
      ultima modifica di

      Wanted to start a convo with @johnonolan@mastodon.xyz from Ghost and @angus@socialhub.activitypub.rocks from Discourse about AP resource discovery.

      A common use case from fediverse users is to be linked out to a site, and attempt to "bring it in" to their local instance/app of choice. This is done by taking the browser URL and pasting it into their site/app's search bar, or equivalent.

      For example:

      • Ghost: https://activitypub.ghost.org/warp-factor-5-mr-sulu/
      • Discourse: any forum topic

      For context, last night I discovered that Ghost's latest blog post didn't make it into NodeBB, due to a bug on my end. I attempted to resolve it via URL but there was no AP resource at that URL. I ended up having to query the instance actor (which I happened to already know), and looking at the outbox.

      To my knowledge there is no way to find a Discourse post or topic's AP resource ID without having a local Discourse account.

      Would it be possible for you to send back an HTTP 301 Moved Permanently (or similar) if the Accepts header contains one of the AP-related types?

      N.B. This probably has some overlap with @evan@cosocial.ca's HTTP Discovery Task Force, a 308 is recommended there.

      1 Risposta Ultima Risposta Rispondi Cita 0
      • trwnh@mastodon.socialT Questo utente è esterno a questo forum
        trwnh@mastodon.social
        ultima modifica di

        @julian @johnonolan @angus @evan 301/308 are meant to permanently update old identifiers regardless of request headers. consider 303 See Other for content negotiation purposes, or consider rel=alternate type=… Link headers otherwise.

        evan@cosocial.caE 1 Risposta Ultima Risposta Rispondi Cita 0
        • evan@cosocial.caE Questo utente è esterno a questo forum
          evan@cosocial.ca
          ultima modifica di

          @julian @johnonolan @angus there's a whole task force for this. You've commented on it. Why does this need to be discussed?

          julian@community.nodebb.orgJ 1 Risposta Ultima Risposta Rispondi Cita 0
          • evan@cosocial.caE Questo utente è esterno a questo forum
            evan@cosocial.ca @trwnh@mastodon.social
            ultima modifica di

            @trwnh @julian @johnonolan @angus there's a doc for this.

            1 Risposta Ultima Risposta Rispondi Cita 0
            • julian@community.nodebb.orgJ Questo utente è esterno a questo forum
              julian@community.nodebb.org @evan@cosocial.ca
              ultima modifica di

              @evan@cosocial.ca this was to ask the mentioned parties for Ghost and Discourse to implement.

              I mentioned you to keep you in the loop because task forces achieve nothing without implementors doing the work.

              1 Risposta Ultima Risposta Rispondi Cita 0
              • rimu@piefed.socialR Questo utente è esterno a questo forum
                rimu@piefed.social
                ultima modifica di

                Object IDs should really be retrievable by http GET. See section 3.2 of https://www.w3.org/TR/activitypub

                julian@community.nodebb.orgJ 1 Risposta Ultima Risposta Rispondi Cita 0
                • julian@community.nodebb.orgJ Questo utente è esterno a questo forum
                  julian@community.nodebb.org @rimu@piefed.social
                  ultima modifica di

                  @rimu@piefed.social yes, that's right. I'm specifically referring to object urls though, which tend to be more user facing.

                  1 Risposta Ultima Risposta Rispondi Cita 0
                  • silverpill@mitra.socialS Questo utente è esterno a questo forum
                    silverpill@mitra.social
                    ultima modifica di

                    @julian @johnonolan @angus @evan

                    Why 301 and not 302?
                    I am using 302. Probably chose it because everyone else was using it.

                    julian@community.nodebb.orgJ 1 Risposta Ultima Risposta Rispondi Cita 0
                    • julian@community.nodebb.orgJ Questo utente è esterno a questo forum
                      julian@community.nodebb.org @silverpill@mitra.social
                      ultima modifica di

                      @silverpill@mitra.social 302/307 is also fine by me. Probably safer from being accidentally cached and may be more appropriate in this situation.

                      1 Risposta Ultima Risposta Rispondi Cita 0
                      • rimu@piefed.socialR Questo utente è esterno a questo forum
                        rimu@piefed.social
                        ultima modifica di

                        You could save yourself some hassle and make urls and IDs the same value. But you do you :)

                        1 Risposta Ultima Risposta Rispondi Cita 0
                        • johnonolan@mastodon.xyzJ Questo utente è esterno a questo forum
                          johnonolan@mastodon.xyz
                          ultima modifica di

                          @julian @angus @evan interesting problem! Redirect feels like a slightly weird pattern to me, intuitively, but open to implementing any preferred approach

                          julian@community.nodebb.orgJ 1 Risposta Ultima Risposta Rispondi Cita 0
                          • julian@community.nodebb.orgJ Questo utente è esterno a questo forum
                            julian@community.nodebb.org @johnonolan@mastodon.xyz
                            ultima modifica di

                            @johnonolan@mastodon.xyz A solution is only needed if the resource id is different from the URL (which in Ghost's case, is true).

                            You don't have to use a redirect. If your software is capable of doing it, you can serve the ActivityPub object directly from that route's controller; that's what NodeBB does.

                            1 Risposta Ultima Risposta Rispondi Cita 0
                            • johnonolan@mastodon.xyzJ Questo utente è esterno a questo forum
                              johnonolan@mastodon.xyz
                              ultima modifica di

                              @julian If you want to make an issue here about what you'd like to see I'll make sure the team sees it :)

                              Link Preview Image
                              GitHub - TryGhost/ActivityPub: A full-featured ActivityPub server for networked publishing with Ghost

                              A full-featured ActivityPub server for networked publishing with Ghost - TryGhost/ActivityPub

                              favicon

                              GitHub (github.com)

                              johnonolan@mastodon.xyzJ 1 Risposta Ultima Risposta Rispondi Cita 0
                              • johnonolan@mastodon.xyzJ Questo utente è esterno a questo forum
                                johnonolan@mastodon.xyz @johnonolan@mastodon.xyz
                                ultima modifica di

                                @julian (Thank you for the ping btw, I appreciate the note - this wasn't on my radar)

                                julian@community.nodebb.orgJ 1 Risposta Ultima Risposta Rispondi Cita 0
                                • julian@community.nodebb.orgJ Questo utente è esterno a questo forum
                                  julian@community.nodebb.org @johnonolan@mastodon.xyz
                                  ultima modifica di

                                  @johnonolan@mastodon.xyz no worries, and thanks! Will do.

                                  1 Risposta Ultima Risposta Rispondi Cita 0
                                  • Primo post
                                    Ultimo post