scripting / opml.org

A repository to back up the opml.org website.
MIT License
15 stars 1 forks source link

HTTP content-type for OPML files? #20

Open scripting opened 5 months ago

scripting commented 5 months ago

I have a server that's returning OPML files.

It's not the first time I've done this, but now there seem to be enough other people interested in this that it's worth raising this question.

What content type should I use? Generally I've been using text/xml.

But I see other people using text/opml.

I asked ChatGPT what it thinks and it says that text/x-opml is the standard.

Meta.ai says application/opml+xml.

I'm interested primarily in what other people are currently doing.

cshotton commented 5 months ago

You should use the standard syntax for mime type suffixes and/or subtypes. There is a well-defined standard for this.

It could be any of: text/xml.opml text/xml+opml Or even: text/xml;opml

I think the second one (+opml) is the proper use of a suffix to refine the primary type.

https://en.m.wikipedia.org/wiki/Media_type