@@ -277,13 +277,19 @@ export const revokeAppleAccessToken = onCall({
277277
278278 try {
279279 const { token } = request . data ;
280- const { teamId, clientId, keyId, privateKey } = getAppleConfiguration ( ) ;
281280
282281 if ( ! token ) {
283282 throw new HttpsError ( "invalid-argument" , "Token is required" ) ;
284283 }
285284
286- // JWT 생성
285+ console . log ( "Starting Apple token revocation" , {
286+ uid : request . auth . uid
287+ } ) ;
288+
289+ console . log ( "Starting Apple configuration load for token revocation" ) ;
290+ const { teamId, clientId, keyId, privateKey } = getAppleConfiguration ( ) ;
291+
292+ console . log ( "Starting Apple client secret creation for token revocation" ) ;
287293 const clientSecret = jwt . sign ( { } , privateKey , {
288294 algorithm : "ES256" ,
289295 expiresIn : "5m" ,
@@ -293,14 +299,15 @@ export const revokeAppleAccessToken = onCall({
293299 keyid : keyId ,
294300 } ) ;
295301
296- // Apple 서버에 토큰 취소 요청
297- await axios . post ( "https://appleid.apple.com/auth/revoke" ,
298- new URLSearchParams ( {
299- client_id : clientId ,
300- client_secret : clientSecret ,
301- token : token ,
302- token_type_hint : "access_token" // access_token 또는 refresh_token 지정 가능
303- } ) . toString ( ) , {
302+ console . log ( "Starting Apple revoke API request" ) ;
303+ await axios . post (
304+ "https://appleid.apple.com/auth/revoke" ,
305+ new URLSearchParams ( {
306+ client_id : clientId ,
307+ client_secret : clientSecret ,
308+ token : token ,
309+ token_type_hint : "access_token" // access_token 또는 refresh_token 지정 가능
310+ } ) . toString ( ) , {
304311 headers : { "Content-Type" : "application/x-www-form-urlencoded" } ,
305312 } ) ;
306313
0 commit comments