Export and Other

Export PDF with notes

http://yoursite.com/annotate/php/apiExportPdf.php?    
     api-user=joe@example.com
     &api-requesttime=1234566
     &api-annotateuser=jill@example.com
     &api-auth=ABC123...

     &ws=123456                       // Workspace ID
     &d=2009-01-02                    // Date of pdf document
     &c=xyz123                        // Code of pdf document
     &subset=1                        // '0': all pages; '1': just those with notes
     &exportFormat=margin             // (optional): 
                                          // 'margin' : default (notes in rhs margin)
                                          // 'hand'   : for full size pages w handwriting only

The return value will either be "ERR {some error message}" or "OK {pdf_url} {modified_time}", where the pdf_url is the url of the exported PDF file (which includes a long random code), and the modified_time is the timestamp of the exported file.

OK http://yoursite.com/annotate/js/docs/xxxxxxx12345/welcome-notes.pdf 1234567

Export as Track-Changes

For documents uploaded as Word .docx or Word2003 .xml, you can export a new .docx (or .xml) file with the comments (and deletes and insertions) included as tracked changes, using an HTTP GET call to apiExportWord.php:

 http://yoursite.com/annotate/php/apiExportWord.php?    
     api-user=joe@example.com
     &api-requesttime=1234566
     &api-annotateuser=jill@example.com
     &api-auth=ABC123...

     &d=2009-01-02                    // Date of uploaded .docx or word2003 .xml document
     &c=xyz123                        // Code of document
                    

The return value will either be "ERR {some error message}" or "OK {word_url} {modified_time}", where the word_url is the url of the exported Word file (which includes a long random code), and the modified_time is the timestamp.

OK http://yoursite.com/annotate/js/docs/xxxxxxx12345/somedoc-export.docx 1234567

Provide the source Word document if you uploaded a PDF

In order to export a new Word document with the comments, annotate needs to have access to the original. This will be automatic if you uploaded the .docx file to annotate (e.g. using the uploadDocument call), but if you managed the conversion to PDF using your own code, and only uploaded the pdf version, you will need to also supply the Word version if you want to be able to export track changes. This can be done using the apiProvideSourceDocument api call, providing the docurl and docname arguments. Currently this only supports .docx and word2003 .xml file formats; the binary .doc file format cannot be used.

http://yoursite.com/annotate/php/apiProvideSourceDocument.php?    
     api-user=joe@example.com
     &api-requesttime=1234566
     &api-annotateuser=jill@example.com
     &api-auth=ABC123...

     &d=2009-01-02                    // Date of uploaded PDF document
     &c=xyz123                        // Code of document

     &docurl=http://yoursite.com/somefile.docx   // http URL to fetch .docx file 
     &docname=somefile.docx                      // Filename of .docx file (or .xml word2003)

#    &docxmltype=word2003                        // optional: if uploading word2003 .xml

                    

The return value is "OK" or "ERR + message". After calling this, you will be able to call apiExportWord above.

Get server version number

A HTTP GET call to apiGetVersion.php will return "OK " + the server version number.

HTTP GET call (no authentication needed):
   http://yoursite.com/annotate/php/apiGetVersion.php

# Sample return value:
OK 4.0.20