Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
CMIS upload test script
import cmislib
client = cmislib.CmisClient('', 'Admin', 'alfresco')
repo = client.defaultRepository
root = repo.rootFolder
myFolder = root.createFolder('testFolder')
f1 = open('C:\\test_4.pdf', 'rb')
#f2 = open(''.pdf, 'rb')
#f3 = open(''.pdf, 'rb')
myFolder.createDocument('1.pdf', contentFile=f1)
#subFolder.cerateDocument('2.pdf', contentFile=f2)
#subFolder.cerateDocument('3.pdf', contentFile=f3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment