Upload attachment with CURL

Did you check out

?