Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
2900c3e
✨ feat: add OAuth2 login/logout with PKCE via golang.org/x/oauth2
kwent Mar 28, 2026
f6a947c
🐛 fix: resolve CI lint and Go version compatibility issues
kwent Mar 28, 2026
724eb4d
🐛 fix: resolve remaining lint issues
kwent Mar 28, 2026
e892f7e
🐛 fix: remove unused nolint directive
kwent Mar 28, 2026
f3b1f49
♻️ refactor: consolidate DeriveAuthBaseURL into oauth package
kwent Mar 28, 2026
c786503
💄 style: remove extra blank lines flagged by goimports
kwent Mar 28, 2026
a0bca79
♻️ refactor: simplify OAuth integration
kwent Mar 28, 2026
6fff5ad
♻️ refactor: merge OAuth tokens into config.yaml
kwent Mar 28, 2026
e29c8b7
🐛 fix: lint — use strings.Contains in test, remove double blank lines
kwent Mar 28, 2026
5046a2f
🐛 fix: Windows CI — set USERPROFILE alongside HOME in tests
kwent Mar 28, 2026
9bf21ce
✨ feat: auto-append /api for localhost endpoints
kwent Mar 28, 2026
41380aa
✨ feat: suggest 'rootly login' when token refresh fails
kwent Mar 28, 2026
2b7a44f
🐛 fix: close response body in refresh failure test (bodyclose lint)
kwent Mar 28, 2026
566a62c
🐛 fix: address Greptile P1/P2 review findings
kwent Mar 28, 2026
62a84ee
✨ feat: replace hardcoded client_id with dynamic OAuth registration
kwent Mar 28, 2026
9041563
🔧 fix: derive auth base URL as rootly.com instead of app.rootly.com
kwent Mar 29, 2026
13bd28b
Merge remote-tracking branch 'origin/master' into features/oauth2-login
kwent Apr 21, 2026
e1ee952
🔧 fix: use API host for OAuth registration, auth host for authorize
kwent May 7, 2026
a1d5f82
🔧 fix: use scopes from registration response, remove DeriveAPIBaseURL
kwent May 8, 2026
4378359
🐛 fix: resolve lint errors — named returns and struct alignment
kwent May 8, 2026
3d76df1
Merge branch 'master' into features/oauth2-login
kwent May 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,25 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added
- `rootly login` — browser-based OAuth2 authentication with PKCE (no API key needed)
- `rootly logout` — clear stored OAuth tokens
- OAuth2 auto-refresh transport using `golang.org/x/oauth2`
- Auto-append `/api` for localhost endpoints (no need to pass `--api-host=localhost:22166/api`)
- `http://` scheme auto-detection for localhost/127.0.0.1 endpoints

### Changed
- OAuth tokens stored in `~/.rootly-cli/config.yaml` under `oauth` key (single config file)
- API client uses OAuth Bearer tokens when available, falls back to API key
- Auth-exempt commands use `Annotations["skipAuth"]` instead of hardcoded name list
- Switch `oncall who` and `oncall shifts` to unified `/v1/oncalls` endpoint with richer data (escalation policy, level, user email)
- Add new filter flags: `--schedule-id`, `--service-id`, `--escalation-policy-id`, `--user-id`, `--time-zone`, `--earliest`
- Table output now includes Escalation Policy, Level, and Email columns
- Rename `oncall list` to `oncall schedules`

### Fixed
- Fix `oncall schedules` 404 error (use correct `/v1/schedules` endpoint)
- Windows test compatibility (`USERPROFILE` alongside `HOME`)

### Removed
- Removed legacy `/v1/shifts` endpoint usage and associated `Shift`/`ShiftsResult` types
Expand Down Expand Up @@ -54,7 +65,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Homebrew tap distribution
- GitHub Actions CI (lint, test, build) and release workflows

[Unreleased]: https://github.com/rootlyhq/rootly-cli/compare/v0.1.4...HEAD
[Unreleased]: https://github.com/rootlyhq/rootly-cli/compare/v0.1.5...HEAD
[0.1.5]: https://github.com/rootlyhq/rootly-cli/compare/v0.1.4...v0.1.5
[0.1.4]: https://github.com/rootlyhq/rootly-cli/compare/v0.1.3...v0.1.4
[0.1.3]: https://github.com/rootlyhq/rootly-cli/compare/v0.1.2...v0.1.3
[0.1.2]: https://github.com/rootlyhq/rootly-cli/releases/tag/v0.1.2
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ require (
github.com/rootlyhq/rootly-go v0.9.0
github.com/spf13/cobra v1.10.2
github.com/spf13/viper v1.21.0
golang.org/x/oauth2 v0.28.0
gopkg.in/yaml.v3 v3.0.1
)

Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ github.com/woodsbury/decimal128 v1.4.0 h1:xJATj7lLu4f2oObouMt2tgGiElE5gO6mSWUjQs
github.com/woodsbury/decimal128 v1.4.0/go.mod h1:BP46FUrVjVhdTbKT+XuQh2xfQaGki9LMIRJSFuh6THU=
go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc=
go.yaml.in/yaml/v3 v3.0.4/go.mod h1:DhzuOOF2ATzADvBadXxruRBLzYTpT36CKvDb3+aBEFg=
golang.org/x/oauth2 v0.28.0 h1:CrgCKl8PPAVtLnU3c+EDw6x11699EWlsDeWNWKdIOkc=
golang.org/x/oauth2 v0.28.0/go.mod h1:onh5ek6nERTohokkhCD/y2cV4Do3fxFHFuAejCkRWT8=
golang.org/x/sys v0.41.0 h1:Ivj+2Cp/ylzLiEU89QhWblYnOE9zerudt9Ftecq2C6k=
golang.org/x/sys v0.41.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
golang.org/x/text v0.34.0 h1:oL/Qq0Kdaqxa1KbNeMKwQq0reLCCaFtqu2eNuSeNHbk=
Expand Down
Loading
Loading