mirror of
				https://github.com/juspay/hyperswitch.git
				synced 2025-11-04 05:59:48 +08:00 
			
		
		
		
	feat(auth): Add support for partial-auth, by facilitating injection of authentication parameters in headers (#4802)
Co-authored-by: Jagan <jaganelavarasan@gmail.com>
This commit is contained in:
		@ -56,7 +56,7 @@ pub async fn create_payment_method_api(
 | 
			
		||||
            ))
 | 
			
		||||
            .await
 | 
			
		||||
        },
 | 
			
		||||
        &auth::ApiKeyAuth,
 | 
			
		||||
        &auth::HeaderAuth(auth::ApiKeyAuth),
 | 
			
		||||
        api_locking::LockAction::NotApplicable,
 | 
			
		||||
    ))
 | 
			
		||||
    .await
 | 
			
		||||
@ -426,7 +426,7 @@ pub async fn payment_method_retrieve_api(
 | 
			
		||||
        |state, auth, pm, _| {
 | 
			
		||||
            cards::retrieve_payment_method(state, pm, auth.key_store, auth.merchant_account)
 | 
			
		||||
        },
 | 
			
		||||
        &auth::ApiKeyAuth,
 | 
			
		||||
        &auth::HeaderAuth(auth::ApiKeyAuth),
 | 
			
		||||
        api_locking::LockAction::NotApplicable,
 | 
			
		||||
    ))
 | 
			
		||||
    .await
 | 
			
		||||
@ -515,7 +515,7 @@ pub async fn list_countries_currencies_for_connector_payment_method(
 | 
			
		||||
        },
 | 
			
		||||
        #[cfg(not(feature = "release"))]
 | 
			
		||||
        auth::auth_type(
 | 
			
		||||
            &auth::ApiKeyAuth,
 | 
			
		||||
            &auth::HeaderAuth(auth::ApiKeyAuth),
 | 
			
		||||
            &auth::JWTAuth(Permission::MerchantConnectorAccountWrite),
 | 
			
		||||
            req.headers(),
 | 
			
		||||
        ),
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user