I think you’re missing the first UPrimitiveComponent parameter. See below for en example
UFUNCTION()
void OnOverlapBegin(UPrimitiveComponent* OverlappedComp, AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult& SweepResult);
If you add that first component to your method signature (and your cpp of course), then it should work correctly.