···339339 "pullerDID", pullerDID,
340340 "cacheKey", cacheKey)
341341342342- token, err := token.GetOrFetchServiceTokenWithAppPassword(ctx, pullerDID, holdDID, pullerPDSEndpoint)
342342+ token, err := auth.GetOrFetchServiceTokenWithAppPassword(ctx, pullerDID, holdDID, pullerPDSEndpoint)
343343 if err != nil {
344344 slog.Error("Failed to get service token with app-password",
345345 "component", "registry/middleware",
···357357 "pullerDID", pullerDID,
358358 "cacheKey", cacheKey)
359359360360- token, err := token.GetOrFetchServiceToken(ctx, nr.refresher, pullerDID, holdDID, pullerPDSEndpoint)
360360+ token, err := auth.GetOrFetchServiceToken(ctx, nr.refresher, pullerDID, holdDID, pullerPDSEndpoint)
361361 if err != nil {
362362 slog.Error("Failed to get service token with OAuth",
363363 "component", "registry/middleware",
+2-2
pkg/appview/storage/crew.go
···99 "time"
10101111 "atcr.io/pkg/atproto"
1212+ "atcr.io/pkg/auth"
1213 "atcr.io/pkg/auth/oauth"
1313- "atcr.io/pkg/auth/token"
1414)
15151616// EnsureCrewMembership attempts to register the user as a crew member on their default hold.
···3939 }
40404141 // Wrap the refresher to match OAuthSessionRefresher interface
4242- serviceToken, err := token.GetOrFetchServiceToken(ctx, refresher, client.DID(), holdDID, client.PDSEndpoint())
4242+ serviceToken, err := auth.GetOrFetchServiceToken(ctx, refresher, client.DID(), holdDID, client.PDSEndpoint())
4343 if err != nil {
4444 slog.Warn("failed to get service token", "holdDID", holdDID, "error", err)
4545 return
···22// Service tokens are JWTs issued by a user's PDS to authorize AppView to
33// act on their behalf when communicating with hold services. Tokens are
44// cached with automatic expiry parsing and 10-second safety margins.
55-package token
55+package auth
6677import (
88 "encoding/base64"