jarodm
Mega Guru

There is an Attachment API: Attachment API



If you want to just do it in a script, there is a pretty good description of where things are stored here:Attachments in ServiceNow



JarodM