@Aditya Jadia
Yes,it's possible with either of Execute Script (or) Execute Stream Command (or) Execute Groovy Script processors, all these processors can accept incoming connections so that your flow is dependent on the success of another processor.
.
If the Answer helped to resolve your issue, Click on Accept button below to accept the answer, That would be great help to Community users to find solution quickly for these kind of issues.