cnx2js

1.0.6 • Public • Published

cnx2js

Converts (some) IBM Connections Cloud ATOM XML to JSON.

Installation

npm install cnx2js --save

Usage

var cnx2js = require('cnx2js');
cnx2js.format(xml, 'topics', (err, json) => {
    console.log(json);
});
{
  "topics": [
    {
      "id": "eba13222-c22a-4529-bb43-badc700c11c3",
      "source": "forum",
      "title": "How will Internet of Things affect collaboration?",
      "parent": "658dcc36-6d2d-4508-9dc8-87332fbbab19",
      "api": "https://apps.na.collabserv.com/communities/service/atom/community/instance?communityUuid=658dcc36-6d2d-4508-9dc8-87332fbbab19",
      "url": "https://apps.na.collabserv.com/forums/html/topic?id=eba13222-c22a-4529-bb43-badc700c11c3",
      "content": "\n    <p dir=\"ltr\">\n      Will devices be able to monitor and react to social collaboration like status updates and posts?\n    </p>\n  "
    },
    ...
    ]
  }

Coverage

  • Blog Entries
  • Forum Topics
  • Comments
  • Profile Tags
  • Wiki Pages

Package Sidebar

Install

npm i cnx2js

Weekly Downloads

1

Version

1.0.6

License

Apache-2.0

Last publish

Collaborators

  • van-ibm