All Projects → GitbookIO → node-opds

GitbookIO / node-opds

Licence: Apache-2.0 license
Node.js library to parse/generate OPDS feed

Programming Languages

javascript
184084 projects - #8 most used programming language

node-opds

This is a library to parse or generate OPDS feed. It makes it easy to generate a feed from a list of book., it also handles correctly BISAC subjects.

How to install it?

$ npm install opds

How to use it?

⚠️ This example is incomplete to pass OPDS Validation (http://opds-validator.appspot.com).

var opds = require("opds");

var xml = opds.create({
    title: "My Catalog",
    author: {
        name: "Samy Pesse",
        uri: "https://www.gitbook.com"
    },
    books: [
        {
            title: "A book",
            summary: "This is a test book",
            updated: new Date(),
            author: {
                name: "Aaron O'Mullan",
                uri: "https://www.gitbook.com/@aaron"
            },
            links: [
                {
                    rel: "image",
                    href: "/book/test.jpg",
                    type: "image/jpeg"
                },
                {
                    rel: "acquisition/buy",
                    href: "/book/test.epub",
                    type: "application/epub+zip"
                }
            ],
            categories: [
                "FIC020000"
            ]
        }
    ]
});

You can also parse an OPDS feed:

var feed = opds.parse('...');
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].