Verentis

MIME & content types

Registering MIME & content types

How an app claims the files it should open, including wildcards, priorities, and custom content recognised by JSON Schema.

An app is reached when a user opens a file whose type the app claims. Getting your mime-types right is what makes your app discoverable.

Claiming common types

Most apps claim standard MIME types. Use exact patterns where you can, wildcards where you must:

spec:
  mime-types:
    - pattern: image/png
      mode: view
      priority: 200
    - pattern: "image/*"
      mode: view
      priority: 100

The workspace picks the highest-priority matching app, so an exact image/png claim outranks a broad image/* one. See File types & the MIME registry for how type is determined in the first place.

Modes

Declare how you handle each type:

view

The app displays the file read-only. Request node.file.read.

edit

The app modifies the file. Request write permissions such as node.node.create and node.node.update in addition to read.

Custom & vendor content types

To handle a content type that isn't a standard MIME type — your own document format, for example — declare a custom MIME pattern and pair it with a JSON Schema so the registry recognises content by shape:

spec:
  mime-types:
    - pattern: application/vnd.acme.diagram+json
      mode: edit
      priority: 200
      json-schema:
        id: acme-diagram
        source: /schemas/diagram.schema.json
        title: Acme Diagram
        version: "1.0"

This is the extensible path for app/engine/vendor types: the registry learns your type from the manifest — no platform change required.

Multiple surfaces

If different parts of your app open different types, use entry-points, each with its own mime-types (see the app manifest reference).

Tips

  • Start specific, then add wildcards as fallbacks at lower priority.
  • Don't over-claim: claiming text/* at high priority will shadow more specialised editors.
  • Keep mode honest — request write scopes only when you declare edit.

Next

The SDK & bridge

Now that your app opens the right files, read and write their content.