···27272828Aside from the on-paper violation of using a user token programmatically (on your behalf), there is no misuse of the API to achieve rich presence.
29293030-Additionally, MS uses the state of non-MS sessions to determine if it should update presence at all. Essentially, it will not act on your behalf unless you are:
3030+Additionally, MS uses the state of non-MS sessions to conservatively update presence. [By default it will not conflict](#configure-when-presence-is-used) with any other official presence activities and is only used when you are actually active on a device.
3131+3232+</DetailsAdmo>
3333+3434+<DetailsAdmo type="note" summary="REQUIRED Interaction after Starting Multi-Scrobbler">
3535+3636+Every time multi-scrobbler is started a discord session update needs to be triggered so that [MS can capture the signals it uses to determine if presence can be updated.](#configure-when-presence-is-used) This only needs to be *once*, after starting multi-scrobbler. But it does need to be *every time* multi-scrobbler is (re)started. Without these signals MS will not update presence.
3737+3838+This session update can happen automatically after *some* time so you may not need to do anything. If you want to force the update then do one of the following:
31393232-* using an official client
3333-* physically online
3434-* not invisible
4040+* Open discord on a device it was not recently active on
4141+* Exit discord on an active device
4242+* Change your status (online, idle, etc...)
4343+* Set a custom status
4444+* Cause a presence update with a different app (listening to..., playing..., etc.)
35453646</DetailsAdmo>
37473838-## User Token
4848+## Required Setup
4949+5050+### User Token
39514052You must provide a User Token for this scrobbler to work.
4153···49615062:::
51635252-## Artwork
6464+## Optional Setup
6565+6666+### Configure When Presence Is Used
6767+6868+MS uses several signals from your "real" Discord sessions to determine if it should update presence. The default configuration is **extremely** conservative to ensure that MS does not conflict with other apps using presence. Additionally, it only updates if a "real" user device is active on discord.
6969+7070+:::tip[TLDR]
7171+7272+Without any additional configuration, MS will only update presence if:
7373+7474+* you have discord open on a real device
7575+* your status is either: online, idle, or dnd (not invisible)
7676+* no other apps are broadcasting presence (no other listening, playing, competing, etc... activities on your profile)
7777+7878+:::
7979+8080+#### Online Status
8181+8282+Configure if MS is allowed to update presence based on your online status. If this setting is not defined MS will only update if your status is **online**, **idle**, or **dnd**.
8383+8484+Allowed Values: `online` `idle` `dnd` `invisible`
8585+8686+<details>
8787+8888+<summary>Example</summary>
8989+9090+Only allow presence updating when all of your "real" sessions are either online or idle.
9191+9292+9393+In File/AIO:
9494+9595+```json
9696+[
9797+ {
9898+ "name": "MS",
9999+ "enable": true,
100100+ "data": {
101101+ "token": "Ma7XBvzRERK3gQdkX4dkb3OQ.6aaGmJ.rvFiiVrzG4VXHHL3LyhZYhpWdG3Ph_if9aKz5E",
102102+ "applicationId": "8190211179716453570",
103103+ "statusOverrideAllow": ["online", "idle"]
104104+ }
105105+ }
106106+ ]
107107+```
108108+109109+In ENV:
110110+111111+```
112112+DISCORD_STATUS_OVERRIDE_ALLOW=online,idle
113113+```
114114+115115+</details>
116116+117117+#### Activity Type
118118+119119+Configure the activity types of **other** activities that MS is allowed to broadcast at the same time as. If this setting is not defined MS will only update if no other activities or only `custom`.
120120+121121+Note: Discord shows both `custom` and other non `custom` activities at the same time. All other activities are mutually exclusive.
122122+123123+Allowed Values:
124124+125125+* `playing` `streaming` `listening` `custom` `competing`
126126+* `true` => allow presence during *any*
127127+* `false` => allow presence during *none*
128128+129129+<details>
130130+131131+<summary>Example</summary>
132132+133133+You want to allow MS to update presence when you are normally playing any game but not when any other activity (streaming, listening, competing) is happening.
134134+135135+In File/AIO:
136136+137137+```json
138138+[
139139+ {
140140+ "name": "MS",
141141+ "enable": true,
142142+ "data": {
143143+ "token": "Ma7XBvzRERK3gQdkX4dkb3OQ.6aaGmJ.rvFiiVrzG4VXHHL3LyhZYhpWdG3Ph_if9aKz5E",
144144+ "applicationId": "8190211179716453570",
145145+ "activitiesOverrideAllow": ["playing", "custom"]
146146+ }
147147+ }
148148+ ]
149149+```
150150+151151+In ENV:
152152+153153+```
154154+DISCORD_ACTIVITIES_OVERRIDE_ALLOW=playing,custom
155155+```
156156+157157+___
158158+159159+You **do not** want to allow MS to update presence if **any** other activity is occurring, including `custom`.
160160+161161+```json
162162+[
163163+ {
164164+ "name": "MS",
165165+ "enable": true,
166166+ "data": {
167167+ "token": "Ma7XBvzRERK3gQdkX4dkb3OQ.6aaGmJ.rvFiiVrzG4VXHHL3LyhZYhpWdG3Ph_if9aKz5E",
168168+ "applicationId": "8190211179716453570",
169169+ "activitiesOverrideAllow": false
170170+ }
171171+ }
172172+ ]
173173+```
174174+175175+In ENV:
176176+177177+```
178178+DISCORD_ACTIVITIES_OVERRIDE_ALLOW=false
179179+```
180180+181181+</details>
182182+183183+#### Activity Name
184184+185185+Configure the names of **other** activities that MS is **not** allowed to broadcast at the same time as.
186186+187187+It is not required to use [Activity Type](#activity-type) with this setting, but it is useful.
188188+189189+<details>
190190+191191+<summary>Example</summary>
192192+193193+You want to allow MS to update presence when you are normally playing any game but not when any other activity (streaming, listening, competing) is happening. You also do not want to allow MS to update presence if the game is fortnite.
194194+195195+In File/AIO:
196196+197197+```json
198198+[
199199+ {
200200+ "name": "MS",
201201+ "enable": true,
202202+ "data": {
203203+ "token": "Ma7XBvzRERK3gQdkX4dkb3OQ.6aaGmJ.rvFiiVrzG4VXHHL3LyhZYhpWdG3Ph_if9aKz5E",
204204+ "applicationId": "8190211179716453570",
205205+ "activitiesOverrideAllow": ["playing", "custom"],
206206+ "applicationsOverrideDisallow": ["fortnite"]
207207+ }
208208+ }
209209+ ]
210210+```
211211+212212+In ENV:
213213+214214+```
215215+DISCORD_ACTIVITIES_OVERRIDE_ALLOW=playing,custom
216216+DISCORD_APPNAME_OVERRIDE_DISALLOW=fortnite
217217+```
218218+</details>
219219+220220+### Artwork
5322154222For some Sources, MS parses album art and displays it in the dashboard. If a Discord **Application Id** is provided then this image can be displayed on Discord alongside your listening status.
552235656-If no Application Id is provided Discord will always show a default image next to your status.
224224+**If no Application Id is provided Discord will use its own default image next to your status.**
5722558226<details>
59227···8024881249MS is conservative in this context by **disallowing** use of album art URLs **by default.** Additionally, it **always** disallows use of these URLs if they do not start with `https`.
822508383-* To allow **any** `https` album art URLs set ENV `DISCORD_ARTWORK=true`
251251+* To allow **any** `https` album art URLs set ENV `DISCORD_ARTWORK=true` (or in file as `"artwork": true`)
84252* To allow only `https` album art URLs from certain domains use a list of keywords like `DISCORD_ARTWORK=spotify,jellyfin` (or in file as `"artwork": ["spotify","jellyfin"]`)
8525386254If a listening activity does not have album art, or the URL is disallowed, MS will use the [multi-scrobbler logo](https://github.com/FoxxMD/multi-scrobbler/blob/master/assets/icon.png) as a fallback image.
···92260## Configuration
9326194262<Config config="DiscordClientConfig" fileContent={JsonConfig} client name="discord">
9595- | Environmental Variable | Required? | Default | Description |
9696- | :---------------------------- | --------- | ------- | :--------------------------------------------------------------------------------------------------------------- |
9797- | `DISCORD_TOKEN` | Yes | | User Token acquired from an active Discord sessions |
9898- | `DISCORD_APPLICATION_ID` | Yes | | Application ID for user with album art |
9999- | `DISCORD_ARTWORK` | No | | A boolean indicating if external artwork URLs should be used. Or a comma-separated list of allowed domains |
100100- | `DISCORD_ARTWORK_DEFAULT_URL` | No | | A URL of an image to use as a fallback if the album art URL cannot be used. Or `false` to use discord's default. |
263263+ | Environmental Variable | Required? | Default | Description |
264264+ | :---------------------------------- | --------- | ----------------- | :--------------------------------------------------------------------------------------------------------------- |
265265+ | `DISCORD_TOKEN` | Yes | | User Token acquired from an active Discord sessions |
266266+ | `DISCORD_APPLICATION_ID` | No | | Application ID used to display album art |
267267+ | `DISCORD_ARTWORK` | No | | A boolean indicating if external artwork URLs should be used. Or a comma-separated list of allowed domains |
268268+ | `DISCORD_ARTWORK_DEFAULT_URL` | No | | A URL of an image to use as a fallback if the album art URL cannot be used. Or `false` to use discord's default. |
269269+ | `DISCORD_STATUS_OVERRIDE_ALLOW` | No | `online,idle,dnd` | A comma-separated list of statuses are allowed to have presence. |
270270+ | `DISCORD_ACTIVITIES_OVERRIDE_ALLOW` | No | `custom` | A comma-seperated list of *other* activity types MS can broadcast presence at the same time as. |
271271+ | `DISCORD_APPNAME_OVERRIDE_DISALLOW` | No | | A commera-seperated list of activity names MS is *not* allowed to broadcast presence at the same time as. |
101272</Config>