summaryrefslogtreecommitdiff
path: root/lib/rms.php
diff options
context:
space:
mode:
authorjade (winter)2025-12-05 00:34:03 +0000
committerjade (winter)2025-12-05 00:34:03 +0000
commit92d27365cadbd98e6d709673cd0729de8793c494 (patch)
treee7ac18fab25957d39745a865ef269f6b6733f15a /lib/rms.php
initial commit
Diffstat (limited to 'lib/rms.php')
-rw-r--r--lib/rms.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/rms.php b/lib/rms.php
new file mode 100644
index 0000000..1e76d53
--- /dev/null
+++ b/lib/rms.php
@@ -0,0 +1,10 @@
+<?php
+
+const RMS_API_BASE = 'https://rms.api.bbc.co.uk/v2';
+const RMS_SOUNDS_HOME = '/experience/inline/listen/sign-in';
+const RMS_SOUNDS_CONTAINER = '/experience/inline/container';
+const RMS_SOUNDS_PLAYABLE = '/experience/inline/play';
+
+function rms_fetch(string $path): stdClass {
+ return json_decode(file_get_contents(RMS_API_BASE . $path));
+}