HexaPDF is a pure Ruby library with an accompanying application for working with PDF files. In short, it allows
- creating new PDF files,
- manipulating existing PDF files,
- merging multiple PDF files into one,
- extracting meta information, text, images and files from PDF files,
- securing PDF files by encrypting them and
- optimizing PDF files for smaller file size or other criteria.