Presence Structure

Understand the required folder layout for a Nowly presence.

Folder Layout

A presence lives under src, grouped by the first letter of its name:

TXT
src/Y/YouTube/
|-- metadata.json
|-- presence.ts
`-- assets/
    |-- logo.png
    |-- icon.png
    `-- thumbnail.jpg

metadata.json

metadata.json describes the platform, supported URLs, author, category, localized descriptions, and marketplace assets.

presence.ts

presence.ts contains runtime logic. It detects page state and calls the Presence API.

utils/

For complex presences, split your logic into dedicated files under a utils/ folder. The YouTube presence, for example, organizes DOM helpers, channel parsing, and Shorts resolution into separate modules:

TXT
src/Y/YouTube/
|-- metadata.json
|-- presence.ts
|-- assets/
|   |-- logo.png
|   |-- icon.png
|   `-- thumbnail.jpg
`-- utils/
    |-- categories.ts
    |-- dom.ts
    |-- channel.ts
    |-- text.ts
    |-- bridge.ts
    |-- shorts-dom.ts
    |-- shorts-resolve.ts
    `-- youtube-data.ts

The bundler resolves local imports from presence.ts, so you can import utility files normally:

import { findVideo } from "./utils/dom"
import { getChannelInfo } from "./utils/channel"

assets

Assets are used by the marketplace, installed presence package, Discord activity payloads, and Open Graph images.

Required files:

FieldTypeDescriptionDefault
logo.png*PNGWide brand mark for marketplace headers, presence pages, and generated OG images.-
icon.png*PNGSquare icon for compact UI surfaces and Discord activity image keys.-
thumbnail.jpg*JPGPreview image used when the presence needs a larger visual.-