#dev 2018-10-18

2018-10-18 UTC
snarfed, [tantek], dougbeal|mb1, [dmitshur], [dave], renem, [eddie], ben_thatmustbeme, [Rose], gRegorLove, jjuran, tonz and cweiske joined the channel
#
Zegnat
dansup, re: webfinger, what made you decide to use that rather than straight up URLs?
#
Zegnat
still hasn't setup webfinger ...
#
dansup
Zegnat: compatibility with mastodon
#
Zegnat
Right. I guess if all fediverse ideas follow that I'll have little choice but to also get webfinger. He.
#
jacky
yeah that's something I've been debating for Koype
#
jacky
WebFinger's _kinda_ anti IndieWeb (re: sharing domains)
#
dansup
Zegnat: yeah, webfinger isn't so bad. Nodeinfo uses something similar. https://pixelfed.social/.well-known/nodeinfo https://pixelfed.social/api/nodeinfo/2.0.json
#
jacky
you can emulate it by doing something like ${u-nickname}@${u-url:hostname} (from your top-level h-card)
#
dansup
jacky: what is Koype?
#
jacky
what is Koype
#
Loqi
Koype is an upcoming software project that aims to provide a one-stop shop for those looking for a single-tenant Web service to uphold IndieWeb principles https://indieweb.org/Koype
#
jacky
it's my attempt to pull _everything_ in house
#
jacky
to my personal website
#
jacky
photos, checkins, notes/toots/tweets, blog posts
#
Zegnat
jacky the look of the webfinger would be easy. It would just be my email address. I would just prefer I could give tools my URL instead where they can find my Actor object immediately ( through conneg)
#
jacky
Zegnat: right but people would be using that to do lookups on other services (unless your email address's domain name matches your site)
#
dansup
jacky: wow, nice!
#
jacky
like also in my case, I'm going to be @yo@jacky.wtf ideally (and that's my email) but if someone was coming in and using GMail, that might not suffice
#
jacky
dansup: thanks! hoping to have a slight demo soon once I can move my personal site over to it
#
Zegnat
martijn@vanderven.se -> vanderven.se/martijn would be the lookup for me
#
jacky
ahhh yeah gotcha
#
Zegnat
Both strings are even of equal length, assuming I don't need a scheme
#
jacky
hmm I _think_ there's a slight one
#
jacky
but it eludes me
[kevinmarks] joined the channel
#
[kevinmarks]
WebFinger--
#
jacky
going to move this to #-chat
[pfefferle] and swentel joined the channel
#
jacky
I'm curious about making a PoC editor that could do this on the fly
#
jacky
re: webfinger and alternative forms of mentioning people
#
jacky
s/making/seeing/g
#
Zegnat
I should find a moment today and document the Reddit thing. As that is basically by URL. They just made the domain part optional as it is all within silo anyway.
#
Zegnat
Which is a lot like the @-mentions used on the fediverse I think? No need for hostname if on the same instance?
#
jacky
Zegnat: it's cosmetic IIRC
#
jacky
actually even if you're not on the same instance, it'll truncate down to username visually
#
Zegnat
Yes, but I'm thinking about the ease for an author. Not display as much.
#
jacky
ah right right
#
jacky
lemme see
#
jacky
yeah it does
#
jacky
going to upload a snapshot
#
jacky
might be helpful when people consider building nickname caches
[Rose] joined the channel
#
Zegnat
That's interesting. Are the people all people you have mentioned before? How does it know to autocomplete from other instances?
#
jacky
I think I have in the past
#
jacky
I might need to check docs/code for that
#
jacky
kinda wish Masto had this documented ;)
#
jacky
tbh I think it uses a cache of mentions from the past
#
jacky
that's cheaper than querying a whole list of names each time
#
jacky
from each server you follow
#
Zegnat
That's what I'm thinking too. So mentioning someone you haven't mentioned before probably depends wholely on the webfinger syntax
tglobe joined the channel
#
Zegnat
The IndieWeb wiki contains a lot of documentation of stuff implementers didn't bother to document. Haha.
#
jacky
I don't think that they were looking at the IndieWeb wiki when they were building Masto
#
jacky
or at least not heavily
[kevinmarks] joined the channel
mblaney joined the channel
#
[kevinmarks]
Separating the use case of autocompleting @ mentions into links from WebFinger is important.
#
swentel
I've wondering, if a webmention comes in that is generated by bridgy (or fed.bridgy), and it's an in-reply-to, it's probably safe to publish them immediately as comments right (I currently moderate those).
#
sknebel
swentel: if you're fine with Twitter spam on your site...
#
swentel
to be fair, replies have always been ok for now, but yeah
#
sknebel
yeah, guess depends on the case. in bigger threads there's been spam sometimes, but the majority was fine
#
swentel
hmm yeah, maybe I should relate this with the nicknames cache I'm working on
#
swentel
if the user is in there
#
swentel
it's ok by default
#
[kevinmarks]
If your post takes off on twitter, you are likely to get bridged nastiness.
#
[kevinmarks]
Webmention is a hugely convoluted way to get from something that misleadingly looks like an email address to a profile url
#
[kevinmarks]
Autocomplete messed up there
#
jacky
did you mean WebFinger?
#
Zegnat
I hope you meant to say WebFinger, [kevinmarks] ;)
#
jacky
lol right
#
Zegnat
darn, sniped by jacky
#
jacky
Zegnat++
#
Loqi
Zegnat has 62 karma in this channel over the last year (171 in all channels)
#
[kevinmarks]
The autolinker implementations at the moment do assume that @ means twitter (following common plaintext practice) though I have seen @ used for Instagram too in public (which may be deliberate muddying by Facebook)
#
jacky
it's used in a lot of places (even outside of those bigger silos - GitHub, GitLab, Dev.To, etc)
#
jacky
but yeah
#
jacky
the one in Jekyll-mentions does default to twitter
#
[kevinmarks]
Sure, and it was on irc before that. Most of the silos do have an autocomplete ui
#
jacky
the only thing that makes this "complicated" _is_ the existence of silos
#
jacky
like with a nickname cache or a localized h-card (or maybe even a h-card service? like a public listing), one could see the places to find someone (granted you could link to their site but what if they use a silo as their only site?)
[schmarty], jgmac1106, bradenslen, [eddie], [tantek], [jgmac1106], [calumryan] and [AkyRhO] joined the channel
#
Loqi
[lfender6445] theme_bandit: Convert any site theme template (Wordpress, Joomla, etc) into a rack application
#
[AkyRhO]
awesome, thanks!
#
[AkyRhO]
i'll try this out today
#
[jgmac1106]
seems everyone exports to xml, but may want to look for a json tool
#
[jgmac1106]
I am tempted to just archive my wordpress site and use a redirect plugin. I am leaning towards Known now but wanted to play with FrancisCMS
[Rose], swentel, jimpick and [kevinmarks] joined the channel
#
[kevinmarks]
There is also the silo @ mapping problem - I have had @'s be the wrong account on Instagram because I was using the twitter @
#
[kevinmarks]
But that can also be resolved by an h-card/rel-me cache
#
GWG
I really want to build one someday
#
GWG
Too many projects
[Rose] and [dave] joined the channel
#
[jgmac1106]
[kevinmarks] why I am hoping a combination of way to follow a blog that parses the hcard and stores correct silo nick would be awesome
#
[jgmac1106]
I publish a follow post to your blog. You have the preferred networks as u-url. That get stored, when I then choose to syndicate to Mastodon, Twitter etc [kevinmarks] get converted to correct url for network mention
#
[jgmac1106]
Actually probably be easier I subscribe in my reader and it publishes a follow post through micropub and handles parsing and storing of h-card
#
[jgmac1106]
... And I of course can do none of this stuff
swentel, [pfefferle], jgmac1106, [grantcodes], snarfed and [kevinmarks] joined the channel
#
[kevinmarks]
WebFinger
#
jgmac1106
@eddie doesn’t a podcast rss feed contain fline length info? Is there any trigerr in iOS to know if a file playes for x=minutes?
#
[jgmac1106]
[Rose] just listened to your show with [eddie], thought maybe I should try a GRAV solution since my recent migration efforts to Known keep failing .then you started talking YAML and headers, and I freaked..
[eddie] joined the channel
#
[eddie]
jgmac1106 iOS is very restrictive on access permissions. Unless you are the app that is playing the audio, there is no way to know how long or if a file is played in the iOS
#
jeremycherfas
Grav is not an easy fit with IndieWeb
#
jeremycherfas
But I need to listen to [Rose]
#
Zegnat
[jgmac1106], that nick cache you describe sounds like what aaronpk is already using. Where he knows different silo URLs for different people
#
jgmac1106
yeah been talking about it [eddie] and reading up on what [aaronpk] is doing…though I drawn to the idea of syndicating to an h-card phonebook for anyone to use
#
[eddie]
!tell aaronpk I can’t seem to figure out how to get webmention.io’s web hook payload and api endpoint to match? the payload has a post attribute that contains everything and the api endpoint returns data and activity in two seperate attributes
#
Loqi
Ok, I'll tell them that when I see them next
[manton] joined the channel
#
[manton]
I've been working on ActivityPub in Micro.blog and think I may be losing my mind a little. 🙂 A bunch of things are working (following, receiving replies) but I can't seem to get a basic post sent to Mastodon. I get a 202 back but nothing happens. Anyone ([aaronpk], [snarfed]) have a minute to check my requests and see if anything stands out? I've tried several different variations of the JSON. https://gist.github.com/manton/8d50084d798924dd9
#
swentel
202 is standard
#
swentel
if you get that, you at least know the signature was fine
#
swentel
but than mastodon handles the rest async
#
swentel
(annoying I know)
#
[manton]
Okay, that's good to know! I wasn't sure when it checked the signature.
#
swentel
mm that gist is 404 here
[tantek] joined the channel
#
[manton]
Hmm. I'll make it public. Try again?
#
swentel
still 404
[dmitshur] joined the channel
#
[manton]
Maybe the URL got truncated in the Slack → IRC translation.
#
aaronpk
202 means mastodon accepted the signature and is processing the rest of it asynchronously
#
Loqi
aaronpk: [eddie] left you a message 12 minutes ago: I can’t seem to figure out how to get webmention.io’s web hook payload and api endpoint to match? the payload has a post attribute that contains everything and the api endpoint returns data and activity in two seperate attributes
#
aaronpk
[eddie] add .jf2 to the end of the webmention.io API URL
#
aaronpk
[manton]: there might be a problem that your actor URL is manton.org but the object URL is www.manton.org
#
[manton]
[aaronpk] Seems like it must be a problem routing the post to the recipient/followers, or some problem with the content. I've tried all sorts of combinations of to/cc in different places.
#
aaronpk
it's pretty picky about the domains matching. also I think the id domain and actor domain might have to match?
#
[eddie]
ohhh, I looked at the code and thought it was format=jf2
#
swentel
mastodon compares the host of id and actor
#
swentel
if they don't match
#
swentel
it ignores the post
#
snarfed
(which is custom and not in the AP spec, grumble grumble)
#
aaronpk
the AP spec leaves a lot of things open to implementers
#
aaronpk
like oauth, it's more a framework than a spec
#
snarfed
sure, as do all of them. we're just bitter because this extra check of mastodon's made bridges like bridgy fed more difficult. ah well.
#
snarfed
they acknowledged that tradeoff when they did it, at least
#
[eddie]
but it didn’t look any different lol
[schmarty] joined the channel
#
[schmarty]
sknebel: a link to an article about GitHub Actions
#
swentel
[manton], more background with links to code in mastodon - https://github.com/snarfed/bridgy-fed/issues/16#issuecomment-424799599 :)
#
Loqi
[swentel] So I finally found out why replies don't show up. The problem is that mastodon compares the id on the object with the actor url. See https://github.com/tootsuite/mastodon/blob/master/app/lib/activitypub/activity/create.rb#L8 See https://github.co...
#
snarfed
soooo finicky and delicate
#
snarfed
(mf2 can be too, but at least the rest of the indieweb stack is usually simpler and more robust)
#
[manton]
I never would have guessed it would care about that. I was off in the weeds looking at other things.
#
aaronpk
I think it's a security thing, but i'd have to run through the threat model to figure out if it's strictly necessary
#
aaronpk
I had similar challenges trying to make my bridge work, and ended up needing to tell users to make a redirect for post IDs from their domain to the bridge
#
Loqi
[aaronpk] Nautilus: Turn your website into an ActivityPub profile
#
[manton]
So to be clear, this is the "id" on the "object", right, but the "id" and "url" elsewhere doesn't need to match?
#
[eddie]
perfect! Thanks aaronpk
#
swentel
[manton], the hosts need to match
#
swentel
id = "https://example.com/unique-id" url="https://example.com/another-url" should work (actually didn't try that variation heh)
#
[manton]
"id" of what, though, the post or the ActivityPub request?
#
swentel
id of the post
#
jeremycherfas
!tell eddie weirdness at myurlis Micropub’s
#
Loqi
Ok, I'll tell them that when I see them next
#
[manton]
Thanks.
#
jacky
I might have to reverse engineer / port that jf2 lib from Python to Elixir
#
jacky
side-note: how do y'all handle input from micropub clients?
#
jacky
I notice that Quill sends slighty different payloads depending on the post type (which makes sense)
#
jacky
but for articles, the expected properties are nested in a bit
#
jacky
I might have missed something in the micropub spec
#
swentel
articles are json IIRC
#
[manton]
That fixed it! Wow. Thank you so much @swentel, [aaronpk], [snarfed]. (Of course, this is a problem now because I frequently use micro.blog URLs for unique IDs, but permalinks with the custom domain name. But that's solvable.)
#
[eddie]
correct, swentel
#
Loqi
[eddie]: jeremycherfas left you a message 13 minutes ago: weirdness at myurlis Micropub’s
#
jacky
hmm so if I'm detecting incoming JSON, I should expect it to be kinda like j(m)f2 it looks like https://www.w3.org/TR/micropub/#json-syntax
#
[eddie]
jacky, there are two variants of Micropub. The urlencoded post and the json post
#
[eddie]
so jf2 is a slight variant where certain properties are strings
#
jacky
looks like I'd have to listen for both
#
[eddie]
mf2 all properties are arrays
#
jacky
I have it leaning towards the urlencoded type
#
[eddie]
urlencoded is the baseline definitely
#
[eddie]
json is an optional upgrade for servers that require it's functionality
#
jacky
I might need to add this to a 'capability' thing in my micropub config
#
[eddie]
certain things like checkins using OwnYourSwarm or embedded html content (hence Quill's articles being JSON)
#
[eddie]
often times what people will do is check for urlencoded post and if that's what it is, convert it to mf2
#
[eddie]
that way the only "extra" code you have is the urlencoded form to mf2 converter which shouldn't be much code
#
aaronpk
yep that's how my micropub server library handles it
#
[eddie]
That's where I stole the idea from 😄 haha
#
Loqi
[aaronpk] p3k-micropub: Utilities to help handle Micropub requests when building servers and clients
#
swentel
yeah I use that library too for the drupal module
#
jacky
💯 y'all rock
#
[eddie]
That's also how the library I use does it
#
[eddie]
then from there you can either hand the converted mf2 object or any mf2 json that comes in to the same function
#
[eddie]
From your build a micropub endpoint at IWC Baltimore
#
NinjaTrappeur
Hey, I'm the person who wrote the lobsters webmention/mf2 module. I think I screw up: look at the repost section of this article -> https://aaronparecki.com/2018/04/20/46/indieweb-reader-my-new-home-on-the-internet . There's a default picture linking to my lobsters profile. I don't think this is the intented behavior, I rather whish it pointed to the repost url (
#
NinjaTrappeur
https://lobste.rs/s/zouoim/indieweb_reader_my_new_home_on_internet ). What did I do wrong? Should I remove the h-card embedding the user name?
#
Loqi
[Aaron Parecki] An IndieWeb reader: My new home on the internet
#
aaronpk
ooh nice
#
aaronpk
repost-of looks right, but I see a "url" that is an h-card, which I think it looks like that should be the "author" property instead
#
aaronpk
looking at your HTML now
#
aaronpk
<a href="/u/NinjaTrappeur" class="h-card u-url ">NinjaTrappeur</a> should be <a href="/u/NinjaTrappeur" class="u-author h-card">NinjaTrappeur</a>
#
aaronpk
(the order of h-card u-author doesn't matter but I prefer u-author first since it's easier to read as 'there is a author property and the value is this h-card')
#
NinjaTrappeur
Subsidiary question: what would make the more sense, considering the user posting the link as the repost author or using "lobsters" (with its associated picture) as the repost author?
#
aaronpk
that's an interesting question
#
aaronpk
on indienews I use the user's info
[chegalabonga] joined the channel
#
[chegalabonga]
pleeeeeeeeeeeeeeeeeeease
#
[chegalabonga]
Does anyone know of a good JSON LD library in php (specifically with Laravel). Just mocking up an ActivityPub example.
#
aaronpk
[chegalabonga]: my advice is just ignore JSON LD and treat it as JSON
#
[chegalabonga]
just return normal JSON with the `@context` etc?
#
[chegalabonga]
ahh k
#
[chegalabonga]
that makes it easier
#
[chegalabonga]
for me
#
jgmac1106
just laughing in my head wondering if people in these channels think “good JSON-LD” can even be a thing
#
[chegalabonga]
thanks
#
[chegalabonga]
haha [jgmac1106]
#
NinjaTrappeur
aaronpk, thanks! I'll correct the u-author thing shortly!
#
[chegalabonga]
Am i right in thinking that `webfinger` is just an agreement about where a lookup is kept? As opposed to being a specific piece of code / library?
#
KartikPrabhu
what is webfinger?
#
Loqi
WebFinger is a discovery protocol for the web that uses email address-like identifiers to get info about users https://indieweb.org/WebFinger
#
[chegalabonga]
:thumbsup:
snarfed, [Rose] and cweiske joined the channel
#
[chegalabonga]
oh
#
[chegalabonga]
my
#
[chegalabonga]
god
#
[chegalabonga]
I have just got a working discoverable site using AP
jgmac1106 joined the channel
#
aaronpk
haha congrats
#
Loqi
Davidoff
#
[chegalabonga]
haha
#
snarfed
[chegalabonga]++ welcome to the club!
#
Loqi
[chegalabonga] has 1 karma over the last year
#
[chegalabonga]
Loqi
#
[chegalabonga]
😊
#
[chegalabonga]
I think I was maybe overthinking it all
#
[chegalabonga]
literally followed the Mastodon docs
#
[chegalabonga]
one question if I may, about the public key
#
[chegalabonga]
how is that used? Is it stored by Mastodon (if followed on mastodon) and then used to check future messages?
#
[chegalabonga]
I'm not too knowledgeable able cryptography
#
aaronpk
yep, whenever you send a message to mastodon, you'll need to sign the message with your private key. mastodon will look up the actor, find the public key, and verify that the signature checks out.
#
aaronpk
mastodon also does cache the key for a while, which is a real pain when you're first starting to test this stuff.
#
[chegalabonga]
ah k. So as long as I keep the same key for testing
#
[chegalabonga]
am I okay to drop a code snippet here? For advice?
#
[chegalabonga]
its actually from mastodon site. In Ruby I think, but need it in PHP 😬
#
aaronpk
use a gist or pastebin or something, don't paste into slack
#
[chegalabonga]
okis
#
aaronpk
should really make the slack bridge do that automatically
#
[chegalabonga]
Don't suppose anyone knows an example of this but in PHP? please.
#
[chegalabonga]
Like a link to docs somewhere
#
aaronpk
docs heh
#
aaronpk
the spec is barely done
#
aaronpk
also the httpsignature spec doesn't even tell you enough to do this 😂
#
[chegalabonga]
You in laravel too
#
[chegalabonga]
that class
#
[chegalabonga]
I think I love you
#
swentel
[chegalabonga], I have php code that works
#
swentel
what do you need ?
#
swentel
nevermind :)
#
swentel
that should work too heh
#
[chegalabonga]
I ve got a HTTPSignature class from [aaronpk] thanks.
#
[chegalabonga]
I'm building my own example ActivityPub example for learning swentel
#
[chegalabonga]
Thanks again [aaronpk] I cant even think how much time that has saved me
#
aaronpk
haha np.
#
aaronpk
I can! I know how much time that took!
#
swentel
[chegalabonga], I have bunch of code examples for reply, follow, accept and delete if you need to know how the payload needs to look like
#
swentel
so feel free to ping
#
swentel
the best tip for now though: make sure the host of 'id' and 'url' match your 'actor' host, especially for posts/replies :)
#
swentel
otherwhise you will go crazy hehe
#
[chegalabonga]
yer hehe. and thanks
[jgmac1106] joined the channel
#
[jgmac1106]
migration--
#
Loqi
migration has -1 karma over the last year
#
[jgmac1106]
in terms of data not people
snarfed1, jackjamieson, tglobe and [cleverdevil] joined the channel
#
[cleverdevil]
So, I made a little action for Drafts 5 in iOS that speaks Micropub.
#
[cleverdevil]
Pulls the title for the post from the first Markdown h1.
#
[cleverdevil]
Prompts you for an IndieAuth token and Micropub endpoint and saves them for future runs.
#
[cleverdevil]
Also supports categories, in-reply-to, and toggling of "visibility" = "private"
#
[cleverdevil]
I also discovered a bug in Known while I am at it... hah.
[eddie] joined the channel
#
[eddie]
That's awesome, [cleverdevil]!
#
[cleverdevil]
I'll fix that first, and when its done, I'll publish the action to the directory.
#
[cleverdevil]
There is a beta version of Drafts for macOS, too.
#
[cleverdevil]
Though, it doesn't (yet) support actions.
#
[cleverdevil]
Once it does, this will likely become my preferred way to compose long-form content.
#
[eddie]
Ohhh That's interesting. I'm guessing the drafts sync between the two apps?
#
[eddie]
That is good. I started writing a post on Quill the other day and had to switch to my iPad. So I had to copy and paste the text from rich text in Quill to Ulysses in Markdown so I could continue on my iPad. But then I couldn't post from Ulysses, so then I had to copy and paste into Indigenous to post.
#
[cleverdevil]
Yes, they sync via iCloud
#
[eddie]
It would be great to just type in Drafts from any device and then submit
#
[eddie]
[cleverdevil]++
#
Loqi
[cleverdevil] has 38 karma in this channel over the last year (72 in all channels)
#
[eddie]
drafts++
#
Loqi
drafts has 1 karma over the last year
#
[cleverdevil]
I like to take notes in Drafts on my iPhone in meetings, church, classes, etc.
#
[cleverdevil]
This means I can now publish those notes to my website as private posts, categorized for things like Work, Meeting, Church, etc.
#
[eddie]
:exploding_head: That's pretty awesome
#
[cleverdevil]
Its great!
[kevinmarks] and KartikPrabhu joined the channel
#
[eddie]
Nice! Added. Thanks!
#
[cleverdevil]
LMK if it works for ya 😉
[tantek] and j12t joined the channel
#
skippy
[cleverdevil]: does that support images, too?
#
[cleverdevil]
I don't know if Drafts really has any support for images. Its really focused on plain text.
#
[cleverdevil]
That's true, I suppose.
[Rose] joined the channel
#
[Rose]
Preview mode does - if the images are stored somewhere it can read (such as a URL)
#
[cleverdevil]
I could theoretically add support for images, but it'd involve people first storing images somewhere accessible by URL and then copy/pasting, which doesn't seem like a great experience.
#
[Rose]
I actually use Dropbox as an image gateway. I ought to write it up. Essentially you use Shortcuts to save to the Dropbox folder and it copies the image reference to your clipboard which you paste into Drafts. And the Drafts action temporarily replaces those URLs with Dropbox links for preview.
#
[cleverdevil]
I do something similar with Dropshare, which uploads to my web server.
#
[eddie]
Shortcut that uploads an image to a media endpoint and then copies the url returned to the clipboard?
#
[Rose]
I upload the images as part of my posting script rather than in advance.
#
[cleverdevil]
Still it'd be weird to have images uploaded once to Dropbox or Dropshare, and then again via the media endpoint.
#
[cleverdevil]
[eddie] that's a great idea, actually.
#
[Rose]
That might be a solution in the future Eddie. But I mess with my images as I go, overwriting in Dropbox is mentally easier somehow.
#
[cleverdevil]
That's a good use case.
#
[cleverdevil]
Would be an nice addition to Micropub media endpoints: updating an image.
#
[Rose]
(Plus my blog posts don’t use a media endpoint (yet), and the images are stored in the folder with the post which the media endpoint can’t figure out)
#
[Rose]
That would be nice.
#
[Rose]
I’d also like to set something up so I can store images in folders via the endpoint. Just for easy grouping.
#
[Rose]
(Folders specified by me when uploading the image)
#
[eddie]
I think I just had a great idea for a Media Endpoint shortcut!
#
[eddie]
opens app
jackjamieson joined the channel
jackjamieson joined the channel
#
skippy
wonder how much work it would be to make a micropub workflow.
#
[eddie]
Hmmm do people return the url of the item in the body of the response in the Media Endpoint? I know you have to return it in the Location header, but it turns out Apple Shortcuts can't grab content from the Location header
#
[eddie]
ohhh I see
#
[eddie]
You can send it a file as a share sheet, but if you activate it without the share sheet it'll have you pick a file from either the Photos app or the Files app, upload it and copy the url to the clipboard.
snarfed and [kevinmarks] joined the channel
#
snarfed
i'm trying, and it keeps returning 401. i can create tweets and do other things with the same token ok
[jgmac1106] and [cleverdevil] joined the channel
#
[cleverdevil]
Nice [eddie]!
#
[cleverdevil]
Busy with some work stuff atm, but I'll check it out in a bit 🙂
#
[eddie]
A couple gotchas I'm fixing anyway :) I'll create a new link once I finish those up and then I'll post to the Shortcuts page
#
[eddie]
What is Shortcuts?
#
Loqi
Shortcuts is an iOS app formerly known as Workflow used to automate various actions https://indieweb.org/Shortcuts
snarfed joined the channel
#
snarfed
figured it out. their docs are wrong. tweet id needs to be in params, not url. i'll file a bug with them
j12t and [Vanessa] joined the channel
#
@benborges_
↩️ Solution : #fediverse with alternative like #mastodon and decentralized identity for websites with indieauth & indieweb = putting "social media" back into the openweb. only way to break monopolies and recreate/maintain the social graph.
(twitter.com/_/status/1053023781751611394)
[Rose] joined the channel
#
[Rose]
Here’s a multi file/photo version of Eddie’s Shortcut by the way: https://www.icloud.com/shortcuts/90e0332c5c1c4726b318f1c57005917b
#
[eddie]
:exploding_head: haha! I thought "you can't do multiple" but I didn't think about looping the get contents of URL!
#
[eddie]
brilliant
wagle joined the channel
#
[Rose]
Well, there’s probably a better way. But this works and is easy to see what’s happening with.
wagle joined the channel
#
[eddie]
Now I need to modify my Drafts 5 action to loop through the lines and insert a separate Markdown image link for each line 🤔
#
[Rose]
You could actually make these into markdown image links before combining them and copying them to your clipboard.
#
[eddie]
oh! Even better
#
[eddie]
Sometimes I might just want the url
#
[eddie]
I guess just a choice at the beginning
#
[eddie]
do you want the Url, Markdown images or html images?
#
[Rose]
But with the script action you just `clipboard.split(“\n”);`, then off you go.
#
[Rose]
Clipboard is wrong, the rest is real JS.
#
[Rose]
Anyway, sleep is required. I have a workshop, a 4 hour train ride and pre IWC Nürnberg dinner tomorrow!
#
[eddie]
Have fun!
[kevinmarks] joined the channel
#
[cleverdevil]
This is awesome stuff!
#
[cleverdevil]
Good job [eddie]!
#
[cleverdevil]
And [Rose]!
#
[eddie]
Okay so I took my shortcut and [Rose]'s update of my shortcut and I updated it again. I think this is the mostly finished version: https://www.icloud.com/shortcuts/d79de6ea6b67430189eb502251168890 It allows you to upload multiple images and allows you to choose whether you want to output as URLs, Markdown or HTML
#
[cleverdevil]
This Shortcut plus my Drafts action, and you've got a pretty nice workflow for creating content!
#
[eddie]
Yep! Hopefully this means we'll be seeing many more blog posts popping up!
[dougbeal] and j12t joined the channel
#
GWG
Shouldn't representative h-card work regardless of trailing slash?
#
Zegnat
That may depend on which trailing slash
#
Zegnat
Although in general I guess the representative h-card thing probably doesn't specify to normalise URLs prior to comparing
#
GWG
It should, shouldn't it?
#
Zegnat
Looks like this as marked as an issue on the mf wiki. Initial and only answer was to use the URL spec for comparisons.
#
GWG
Which says what?
#
Zegnat
So if you mean the slash that comes right after the tld, yes, that one should probably match
#
GWG
I meant a trailing slash
#
Zegnat
Empty path is invalid, IIRC, and defaults to /. So a URL without a path and one with a / match. If there are other symbols in the path then the answer is no.
#
Zegnat
example.com/a and example.com/a/ are two different paths as far as URLs are concerned.
[dougbeal] joined the channel
#
Zegnat
But example.com/ and example.com (no path) are allowed to match.
#
Zegnat
Going half from memory here, as I do not have my laptop handy
#
Zegnat
Falling asleep. Happy to discuss specific case tomorrow if you ran into issues!
#
gRegorLove
For context, this was the issue (from -wordpress): https://github.com/indieweb/indiewebify-me/issues/75
#
Loqi
[gRegorLove] #75 representative h-card: add url uid source algorithm
#
gRegorLove
Though I noticed that method will only work for https://dougbeal.com. http version won't match the h-card.
#
gRegorLove
Redirecting http to https could avoid that.
j12t joined the channel
#
GWG
Should protocol matter?
j12t_ and [jgmac1106] joined the channel