@akilles/soundcloud-watcher 2.2.5 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -9,6 +9,7 @@ Monitor your SoundCloud account and track artist releases. Get notified when som
9
9
  - **New releases** - Get notifications when tracked artists release new music
10
10
  - **Smart API usage** - Only fetches what changed, automatically skips dormant artists
11
11
  - **Rate limit handling** - Exponential backoff for API reliability
12
+ - **OAuth 2.1** - Uses SoundCloud's latest authentication endpoint
12
13
 
13
14
  ## Prerequisites
14
15
 
@@ -85,7 +86,7 @@ The plugin responds to commands but doesn't auto-poll. Set up a cron job for aut
85
86
  openclaw cron add --name "soundcloud-check" \
86
87
  --every 6h \
87
88
  --isolated \
88
- --message "Run /soundcloud-cron and forward any updates to me on Telegram."
89
+ --message "Run /soundcloud-cron and forward any updates to me."
89
90
  ```
90
91
 
91
92
  Uses `/soundcloud-cron` which:
@@ -2,7 +2,7 @@
2
2
  "id": "soundcloud-watcher",
3
3
  "name": "SoundCloud Watcher",
4
4
  "description": "Monitor your SoundCloud account and track artist releases",
5
- "version": "2.2.4",
5
+ "version": "2.3.0",
6
6
  "configSchema": {
7
7
  "type": "object",
8
8
  "additionalProperties": false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@akilles/soundcloud-watcher",
3
- "version": "2.2.5",
3
+ "version": "2.3.0",
4
4
  "description": "OpenClaw plugin to monitor SoundCloud account and track artist releases",
5
5
  "main": "index.ts",
6
6
  "openclaw": {
@@ -336,14 +336,19 @@ class SoundCloudAPI {
336
336
 
337
337
  try {
338
338
  this.log("Refreshing token...");
339
+ const basicAuth = Buffer.from(
340
+ `${this.config.clientId}:${this.config.clientSecret}`
341
+ ).toString("base64");
339
342
  const body = new URLSearchParams({
340
343
  grant_type: "client_credentials",
341
- client_id: this.config.clientId,
342
- client_secret: this.config.clientSecret,
343
344
  });
344
- const resp = await fetch(`${API_BASE}/oauth2/token`, {
345
+ const resp = await fetch("https://secure.soundcloud.com/oauth/token", {
345
346
  method: "POST",
346
- headers: { "Content-Type": "application/x-www-form-urlencoded" },
347
+ headers: {
348
+ "Content-Type": "application/x-www-form-urlencoded",
349
+ "Authorization": `Basic ${basicAuth}`,
350
+ "Accept": "application/json; charset=utf-8",
351
+ },
347
352
  body: body.toString(),
348
353
  signal: AbortSignal.timeout(API_TIMEOUT_MS),
349
354
  });