ModuleDraft 0.1, for comment

On this page
  1. What is sent
  2. How it is sent
  3. What the home does
  4. Messages without a share
  5. Open questions
  6. Prior art

Share module (draft 0.1)

Status: draft for comment. Namespace: org.openmusiccollection.share. Needs: Core 1.0.

People send each other music all the time: a link in a message, a label's newsletter, a friend's "you'll love this". Share makes that something a collection can receive: what someone sends is matched against what the person already has, and comes in with who sent it.

It works like email, and can use email. Anyone can send. The receiver decides what gets in.

What is sent

A share is a piece of a collection file: a header, then the items being shared (recordings or releases), the sources their copies are on, and optionally one list (a playlist, a mix). It has the same file extension, .omc.ndjson, and media type, application/x-ndjson; profile="https://openmusiccollection.org/core/1.0". The header may carry a message:

{"type":"omc","version":"1.0","generated_at":"2026-10-20T09:00:00Z","generator":{"name":"Lumen Records"},"ext":{"org.openmusiccollection.share":{"from":{"name":"Lumen Records","url":"https://lumen.example"},"message":"Our new EP is out today."}}}
{"type":"source","id":"s1","platform":"bandcamp","name":"Bandcamp"}
{"type":"item","id":"r1","kind":"release","title":"Night Drive EP","artists":["Mira Holt"],"ids":{"upc":"0123456789012"},"copies":[{"source":"s1","ref":"3170425711","url":"https://mira.bandcamp.example/album/night-drive-ep","ownership":"none"}]}

Ids are the sender's and only tie the piece together. Nothing about the sender's own collection (their lists, ratings, notes, other apps' data) belongs in a share unless they chose to send it. A sender's word about one track ("start with this one") goes in the shared list's entry note.

How it is sent

  • By email: as an attachment to an ordinary message, with the media type above and a file name ending in .omc.ndjson. The message's text is for people; mail programs that know nothing of OMC show it as a file.
  • To a share address over HTTP: POST the share to a share URL the person gave out (POST {share url}, conventionally ending in /share). No token: the URL itself is the address.

A person's home MAY give them share addresses: an email address, a share URL, or both. They are opt-in, the person can have several (one per label they follow, one for friends), and can change or delete one to stop what arrives there.

What the home does

  1. Checks the sender. A share by email is from a known sender when its From address is one the person allowed and the message passes DKIM. A share to a share URL is known when the person marked that URL as trusted (one they gave a single label, say).
  2. Combines the share's items with the collection by the core's rules, as Access's POST /import does. Items the person already has are not added twice.
  3. Adds what known senders send to the collection, in the list the person chose for that address if they chose one, with via set to the sender ({ "name": "Lumen Records", "url": "https://lumen.example" }). A shared list becomes a new list, with the same via.
  4. Holds what unknown senders send (Held): the person lets it in or turns it away. Nothing from an unknown sender enters the collection on its own.

A home MUST treat everything in a share as untrusted input (see Security and privacy), MUST NOT fetch its URLs on receipt, and SHOULD limit how much one sender can send.

Messages without a share

Ordinary messages also carry music: a link to a Bandcamp album, a receipt, a newsletter. Reading them is guesswork, so it is not part of this module: a home or an app may do it, adding what it finds as suggestions with provenance origin inferred. An app that reads the person's mailbox can bring music in itself, adding through Access with library:add (see the Feeds example).

Open questions

  1. Should a share be signable (like DKIM, but for share URLs), so senders can be known without a URL per sender?
  2. Should a home answer a share (accepted, held, already had) to the sender, or stay silent so senders can't probe a collection?
  3. A registered media type of its own (application/vnd.omc+json-seq?) instead of NDJSON with a profile?

Prior art

Email attachments and vCard (.vcf), which made contacts sendable the same way; iCalendar invitations; ActivityPub's delivery to a person's address.