when people sign into the app, it shows the domain with a client-metadata.json path; this removes that path!
+1
-1
README.md
+1
-1
README.md
···
53
For production deployment:
54
55
1. Update the OAuth redirect URLs in both code and the Bluesky developer settings
56
+
2. Make sure the client metadata file is accessible at `https://flushing.im/oauth-client-metadata.json`
57
3. Deploy the application to Vercel
58
59
## Custom Lexicon Schema
+1
-1
public/client-metadata.json
public/oauth-client-metadata.json
+1
-1
public/client-metadata.json
public/oauth-client-metadata.json
+1
-1
src/app/api/auth/token/route.ts
+1
-1
src/app/api/auth/token/route.ts
···
5
6
const DEFAULT_AUTH_SERVER = 'https://public.api.bsky.app';
7
const REDIRECT_URI = 'https://flushes.app/auth/callback';
8
-
const CLIENT_ID = 'https://flushes.app/client-metadata.json';
9
10
// Function to get a nonce from the specified PDS
11
async function getNonce(pdsEndpoint: string): Promise<string | null> {
···
5
6
const DEFAULT_AUTH_SERVER = 'https://public.api.bsky.app';
7
const REDIRECT_URI = 'https://flushes.app/auth/callback';
8
+
const CLIENT_ID = 'https://flushes.app/oauth-client-metadata.json';
9
10
// Function to get a nonce from the specified PDS
11
async function getNonce(pdsEndpoint: string): Promise<string | null> {
+3
-3
src/lib/bluesky-api.ts
+3
-3
src/lib/bluesky-api.ts
···
111
body: new URLSearchParams({
112
'grant_type': 'refresh_token',
113
'refresh_token': refreshToken,
114
-
'client_id': 'https://flushes.app/client-metadata.json'
115
})
116
});
117
···
215
body: new URLSearchParams({
216
'grant_type': 'refresh_token',
217
'refresh_token': refreshToken,
218
-
'client_id': 'https://flushes.app/client-metadata.json'
219
})
220
});
221
···
276
body: new URLSearchParams({
277
'grant_type': 'refresh_token',
278
'refresh_token': refreshToken,
279
-
'client_id': 'https://flushes.app/client-metadata.json'
280
})
281
});
282
···
111
body: new URLSearchParams({
112
'grant_type': 'refresh_token',
113
'refresh_token': refreshToken,
114
+
'client_id': 'https://flushes.app/oauth-client-metadata.json'
115
})
116
});
117
···
215
body: new URLSearchParams({
216
'grant_type': 'refresh_token',
217
'refresh_token': refreshToken,
218
+
'client_id': 'https://flushes.app/oauth-client-metadata.json'
219
})
220
});
221
···
276
body: new URLSearchParams({
277
'grant_type': 'refresh_token',
278
'refresh_token': refreshToken,
279
+
'client_id': 'https://flushes.app/oauth-client-metadata.json'
280
})
281
});
282
+1
-1
src/lib/bluesky-auth.ts
+1
-1
src/lib/bluesky-auth.ts
···
1
// Default Bluesky OAuth client configuration
2
const DEFAULT_AUTH_SERVER = 'https://public.api.bsky.app';
3
const REDIRECT_URI = 'https://flushes.app/auth/callback';
4
-
const CLIENT_ID = 'https://flushes.app/client-metadata.json';
5
// Need to include transition:generic to be able to create records
6
const SCOPES = 'atproto transition:generic';
7
···
1
// Default Bluesky OAuth client configuration
2
const DEFAULT_AUTH_SERVER = 'https://public.api.bsky.app';
3
const REDIRECT_URI = 'https://flushes.app/auth/callback';
4
+
const CLIENT_ID = 'https://flushes.app/oauth-client-metadata.json';
5
// Need to include transition:generic to be able to create records
6
const SCOPES = 'atproto transition:generic';
7
+1
-1
src/lib/oauth-client.ts
+1
-1
src/lib/oauth-client.ts