How consume input after reading action value?

My case: I want to rotate camera / pan after player holds one of mouse buttons.

  1. I got 2 functions that rotate / pan camera. I bound them to Mouse clicks (middle and right)

  2. I did variable pointer to read Axis Values.

  3. But I don’t know how to consume action value or do it otherway.

MouseXYBindingValue = &( EnhancedInputComponent->BindActionValue(MouseXYAction) );
// Pawn Header
	UPROPERTY(VisibleAnywhere, BlueprintReadOnly)
	TObjectPtr<class UEnhancedInputComponent> EnhancedInputComponent;

	UPROPERTY(EditAnywhere, BlueprintReadOnly)
	TObjectPtr<class UInputMappingContext> BuilderInputMappingContext;

	UPROPERTY(EditAnywhere, BlueprintReadOnly)
	TObjectPtr<class UInputAction> MouseXYAction;

	TObjectPtr<struct FEnhancedInputActionValueBinding> MouseXYBindingValue;
/// .cpp 
/// Functions that rotate / pan camera
void ABuilderPawn::HandleRotationUnBound(const FInputActionValue& value)
{

	FVector2D rotat = MouseXYBindingValue->GetValue().Get<FVector2D>();
	UE_LOGFMT(YasiuPlayerLog, VeryVerbose, "Camera rotation: {0}", rotat.ToString());

	FRotator curRot = SpringArm->GetRelativeRotation();
	RotateVectorKeepRoll(curRot, rotat.Y * camYawSensitivity, rotat.X * camPitchSensitivity);
	SpringArm->SetRelativeRotation(curRot);
	//UE_LOGFMT(YasiuPlayerLog, Verbose, "Updating camera rotation to: {0}", curRot.ToString());
}


void ABuilderPawn::HandlePanUnBound(const FInputActionValue& value)
{
	FVector moveXY = MouseXYBindingValue->GetValue().Get<FVector>();
	//MouseXYAction->bConsumeInput = true;
	//MouseXYBindingValue->GetAction(); /// Consume
	//MouseXYAction//->cons
	//EnhancedInputComponent->Consum
	//EnhancedInputComponent->ConsumeAction(Click);
	MoveActor(moveXY);
}


You don’t, not directly. Instead you have manage your mapping context priorities when you add them to an enhanced input subsystem.

So, instead of PanUnbound consuming the input you would have things setup so that it has the mapping context with that input action has the highest priority for the key in question.

A couple other notes:
TObjectPtr is only meant to be used with UObjects, not pointers to structures. Pointers to structures are generally a no-no in Unreal, at least when stored as members like this.
You’re not meant to save & use the binding value that way. You should use the FInputActionValue function parameter instead.