You can use the 'Enable/disable collisions' action in the Physics behavior for collision filtering.
Integrating a physics engine with Construct is an advanced topic with lots of complexity. If you are asking for a simple code example, you probably won't get one - it's going to be complicated. As others have advised, by far the easiest thing to do is just use the Physics behavior, which already uses the Box2D physics engine. It also uses a WebAssembly build of the original C++ code for maximum performance.