Uopload files to DOCs using API

Uopload files to DOCs using API

How do I upload files using the API.
Programming example in any language
Can someone help with this?