Files
discord-rich-presence-plugin/manifest.json
Atridad Lahiji 24fb4cf752
Some checks failed
Build / Build (push) Failing after 6m3s
added custom activity name template
2026-03-09 18:01:58 -06:00

176 lines
5.1 KiB
JSON

{
"$schema": "https://raw.githubusercontent.com/navidrome/navidrome/refs/heads/master/plugins/manifest-schema.json",
"name": "Discord Rich Presence",
"author": "Navidrome Team",
"version": "1.0.0-prerelease",
"description": "Discord Rich Presence integration for Navidrome",
"website": "https://github.com/navidrome/discord-rich-presence-plugin",
"permissions": {
"users": {
"reason": "To process scrobbles on behalf of users"
},
"http": {
"reason": "To communicate with Discord API, image uploads, and ListenBrainz for track resolution",
"requiredHosts": [
"discord.com",
"uguu.se",
"labs.api.listenbrainz.org"
]
},
"websocket": {
"reason": "To maintain real-time connection with Discord gateway",
"requiredHosts": [
"gateway.discord.gg"
]
},
"cache": {
"reason": "To store connection state and sequence numbers"
},
"scheduler": {
"reason": "To schedule heartbeat messages and activity clearing"
},
"artwork": {
"reason": "To get track artwork URLs for rich presence display"
},
"subsonicapi": {
"reason": "To fetch track artwork data for image hosting upload"
}
},
"config": {
"schema": {
"type": "object",
"properties": {
"clientid": {
"type": "string",
"title": "Discord Application Client ID",
"description": "The Client ID from your Discord Developer Application. Create one at https://discord.com/developers/applications",
"minLength": 17,
"maxLength": 20,
"pattern": "^[0-9]+$"
},
"activityname": {
"type": "string",
"title": "Activity Name Display",
"description": "Choose what to display as the activity name in Discord Rich Presence",
"enum": [
"Default",
"Track",
"Album",
"Artist",
"Custom"
],
"default": "Default"
},
"activitynametemplate": {
"type": "string",
"title": "Custom Activity Name Template",
"description": "Template for the activity name. Available placeholders: {track}, {artist}, {album}",
"default": "{artist} - {track}"
},
"uguuenabled": {
"type": "boolean",
"title": "Upload artwork to uguu.se (enable if Navidrome is not publicly accessible)",
"default": false
},
"spotifylinks": {
"type": "boolean",
"title": "Enable Spotify link-through",
"description": "When enabled, clicking the track title or album art in Discord opens the corresponding Spotify page",
"default": false
},
"users": {
"type": "array",
"title": "User Tokens",
"description": "Discord tokens for each Navidrome user. WARNING: Store tokens securely!",
"minItems": 1,
"items": {
"type": "object",
"properties": {
"username": {
"type": "string",
"title": "Navidrome Username",
"description": "The Navidrome username to associate with this Discord token",
"minLength": 1
},
"token": {
"type": "string",
"title": "Discord Token",
"description": "The user's Discord token (keep this secret!)",
"minLength": 1
}
},
"required": [
"username",
"token"
]
}
}
},
"required": [
"clientid",
"users"
]
},
"uiSchema": {
"type": "VerticalLayout",
"elements": [
{
"type": "Control",
"scope": "#/properties/clientid"
},
{
"type": "Control",
"scope": "#/properties/activityname",
"options": {
"format": "radio"
}
},
{
"type": "Control",
"scope": "#/properties/activitynametemplate",
"rule": {
"effect": "SHOW",
"condition": {
"scope": "#/properties/activityname",
"schema": {
"const": "Custom"
}
}
}
},
{
"type": "Control",
"scope": "#/properties/uguuenabled"
},
{
"type": "Control",
"scope": "#/properties/spotifylinks"
},
{
"type": "Control",
"scope": "#/properties/users",
"options": {
"elementLabelProp": "username",
"detail": {
"type": "HorizontalLayout",
"elements": [
{
"type": "Control",
"scope": "#/properties/username"
},
{
"type": "Control",
"scope": "#/properties/token",
"options": {
"format": "password"
}
}
]
}
}
}
]
}
}
}