Skip to content

feat(openclaw-security-advisor) adds unique signup path#11

Merged
St0rmz1 merged 2 commits intomainfrom
feat/openclaw-advisor-url
Apr 20, 2026
Merged

feat(openclaw-security-advisor) adds unique signup path#11
St0rmz1 merged 2 commits intomainfrom
feat/openclaw-advisor-url

Conversation

@St0rmz1
Copy link
Copy Markdown
Collaborator

@St0rmz1 St0rmz1 commented Apr 20, 2026

Change the sign up URL to correctly attribute new signups

  • src/auth/device-auth.ts — startDeviceAuth now constructs its own verification URL (${apiBase}/openclaw-advisor?code=...) instead of returning the server's generic /device-auth?code=.... Comment explains the cloud side uses the path prefix to attribute Security Advisor signups and apply a per-product bonus; older plugin builds still work but land on the generic URL without the bonus.
  • README.md — Updated the documented signup URL to /openclaw-advisor.
  • test/device-auth.test.ts (new) — Four bun:test cases:
    a. Ignores server's legacy URL and constructs the /openclaw-advisor one from the code
    b. Honors the caller-provided apiBase (dev loop via host.docker.internal)
    c. URL-encodes the code (defense-in-depth against malformed server responses)
    d. Throws a descriptive HTTP 500 error on server rejection

@St0rmz1 St0rmz1 changed the title feat(openclaw-security-advisor) adds unique signup path for tracking… feat(openclaw-security-advisor) adds unique signup path Apr 20, 2026
Comment thread src/auth/device-auth.ts Outdated
@kilo-code-bot
Copy link
Copy Markdown

kilo-code-bot Bot commented Apr 20, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (2 files)
  • src/auth/device-auth.ts
  • test/device-auth.test.ts

Reviewed by gpt-5.4-20260305 · 171,788 tokens

@St0rmz1 St0rmz1 requested a review from joshavant April 20, 2026 18:48
@St0rmz1 St0rmz1 merged commit 8416e4f into main Apr 20, 2026
7 checks passed
@St0rmz1 St0rmz1 deleted the feat/openclaw-advisor-url branch April 20, 2026 20:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants