Micropub-extensions

From IndieWeb
Jump to: navigation, search

This page is for documenting extensions to Micropub. Discussion for these should take place on GitHub.

Server Commands

The Micropub spec reserves the mp- prefix in the form-encoded syntax as a mechanism for clients to give commands to servers. This section is for brainstorming additional uses of the mp- functionality.

Slug

Issues and discussion:
https://github.com/indieweb/micropub-extensions/projects/1

Many posting UIs provide an option for the user to choose a slug for the post that will be created.

wordpress-customize-slug.png

This proposal is for a new mp- command for the client to suggest a slug to the Micropub endpoint.

  • mp-slug=

The server may or may not decide to respect the requested slug, based on whether it would cause conflicts with other URLs on the site. For example, some URL structures are {year}/{slug}, so the server may decide to modify the slug to avoid conflicting with an existing one.

Implementations

Destination

Issues and discussion:
https://github.com/indieweb/micropub-extensions/projects/4

Specify a destination to create a new post on a web site other than the default. The value of mp-destination should be a uid from the array of destinations returned from q=config. See an example query response here.

Implementations

  • Clients
    • Monocle - Monocle will check if your Micropub server returns a list of destinations and will then provide an account chooser UI in the footer when viewing a timeline. Selecting an account will cause any of the response buttons to be sent with the corresponding mp-destination value.
  • Servers

New Properties

Post Status

Issues and discussion:
https://github.com/indieweb/micropub-extensions/projects/2
  • post-status=published (or no post-status set) - The post is published, or when the published date is in the future, the post is scheduled.
  • post-status=draft - The post is a draft, and should not be shown in lists. (Of course it's up to the implementation whether it wants to use a capability URL for draft posts or actually restrict it to logged-in users.)

Implementations

Visibility

Issues and discussion:
https://github.com/indieweb/micropub-extensions/projects/3
  • visibility=public (or no visibility set)
  • visibility=private

In addition to public/private visibility, Wordpress also supports password-protected posts. However, passwords are inherently insecure and also not very user friendly, and there are likely better solutions to the problem. Essentially the goal of password-protected posts on Wordpress is to provide "guest access" to posts, where the viewer does not need an account at the site. Flickr accomplishes this with something they call "guest passes".

As well as public or private there could also be use in a value to hide posts from a main feed. Grant Richmond uses visibility=unlisted for this with his photo posts that appear in a gallery collection - The photos have their own post with a unique viewable url, but appear in a gallery post in the main feed, not as multiple individual photos. "unlisted" is already in use by mastodon.

Implementations

Location Visibility

Proposal by David Shanske

  • location-visibility=public (or no visibility set)
  • location-visibility=private
  • location-visibility=protected

This is based on David Shanske's implementation in Simple Location, an Indieweb friendly location plugin, of the WordPress Geodata unofficial guidelines. It states a single property which can be set to public or private, with the absence of the property being considered to be public. Proposing the third property, which will allow for a less specific text only display, but no actual coordinates.

Implementations

Query

Micropub supports making a GET request to a Micropub endpoint with a q= parameter, in order to query aspects of the endpoint or for retrieving the original source content of posts. This section is for brainstorming additional uses of the query functionality. See also Micropub-brainstorming#Query_for_other_information

  • mp-config
  • venue - not yet implemented suggestion of a venue query for a client to retrieve venues as part of check-in functionality.
  • category - suggestion to get existing tags/categories in the client
  • extended markup formats – right now it is relatively dependent on the server implementation how text content is treated (1:1, basic processing like linking URLs, Markdown, ...). A query could expose information about this (and maybe even be part of a way to choose for the user)
  • media endpoint history – query recent uploads to the media endpoint, e.g. the last X photos uploaded from a phone

Questions

  • According to the current spec (2017-01), a GET ?q=config should also include the syndicate-to property. If the collection of supported properties grows, is this still a thing to hold on to? Venues and tags can make the response potentially large. Sebastiaan Andeweg
    • Agreed, I think the empty GET ?q=config should be very limited, and clients should reqest things with potentially large responses separately. Aaron Parecki 11:40, 11 April 2018 (PDT)

See Also