How to create a Color Threshold filter with custom channel settings?

I just need a script that creates a Color Adjustment filter with this setting:

Top Node: (Input:0, Output: 255)
Bottom Node: (Input:0, Output: 0)

Are you still stuck on this problem? This should be helpful.