tangled
alpha
login
or
join now
kris.darkworld.download
/
nix
1
fork
atom
My NixOS configurations + dotfiles
1
fork
atom
overview
issues
pulls
pipelines
cider
kris.darkworld.download
4 months ago
f65844f4
c4c6968a
+15
1 changed file
expand all
collapse all
unified
split
scripts
lib
CiderV2Playing.ts
+15
scripts/lib/CiderV2Playing.ts
···
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
···
1
+
export type CiderPlaying = {
2
+
status: "ok",
3
+
info: {
4
+
albumName: string,
5
+
artistName: string,
6
+
name: string
7
+
}
8
+
}
9
+
10
+
const d = await fetch("http://localhost:10767/api/v1/playback/now-playing?token=z");
11
+
// console.log(d.status, d.statusText, await d.text())
12
+
const {info}: CiderPlaying = await d.json();
13
+
14
+
console.log(`${info.artistName} - ${info.name} [${info.albumName}]`);
15
+
console.log(info);