I was trying to clean my engine bay this weekend and noticed that this wasn't connected (red connection),

I dont know if I had knocked it off or if it had been off for some time. Can anyone tell me what this is and what it does ?
Its tucked behind the down pipe just above the oil filter.

I dont know if I had knocked it off or if it had been off for some time. Can anyone tell me what this is and what it does ?
Its tucked behind the down pipe just above the oil filter.