-- Leo's gemini proxy

-- Connecting to bbs.geminispace.org:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini; charset=utf-8

Can the metadata in a Gemini response be completely arbitrary? Like can I include custom parameters other than the lang attribute? I'm aware I can return whatever text I want, but is arbitrary metadata allowed by the spec?


Posted in: s/Gemini

๐ŸŒ™ projectmoon

Mar 29 ยท 7 weeks ago ยท ๐Ÿ‘ norayr


3 Comments โ†“


๐Ÿš€ stack ยท Mar 29 at 19:20:

I recommend reading a recent post

โ€” auragem.letz.dev/devlog/20240323.gmi

and all the other texts therer.


๐Ÿ•น๏ธ skyjake [mod...] ยท Mar 29 at 20:13:

Generally speaking, one is not allowed to define their own media type parameters, however this is beyond the scope of the Gemini spec. You should be adhering to the media type spec here (RFC 6838).


Clients are obligated to ignore any unknown parameters, so in practice any custom stuff that a server puts in there will just be skipped by compliant clients. So you could put something in there that is meant for humans or specialized clients to read, if you are OK with serving unofficial/unregistered media types to people.


๐ŸŒ™ projectmoon [OP] ยท Mar 30 at 08:05:

In this case, it's for a prototype webmentions-esque thing built on top of Gemini. I'm currently using a link on the gemtext page itself as a "verification," but I was curious if I could serve this as a response header/metadata value. Agate seems to serve whatever you put in its .meta file, so I can use this data w/ my specialized client. But maybe it's best to just keep to the link on the page, or serve a .txt file at a pre-defined path with my custom metadata.


I don't really want to break the mime type spec itself (though I'm not specifically opposed to it).

-- Response ended

-- Page fetched on Sun May 19 18:28:28 2024