fdsh-client

0.6.1 • Public • Published

fdsh-client NPM version

A Node.js client for the Federal Data Services Hub (FDSH)

Install

Install with npm:

npm install fdsh-client

Synopsis

Setup a bunch of config data:

const fdsh = require('fdsh-client');
const fs = require('fs');
 
// connectivity config
const host = 'dev.hub.cms.gov'
const port = 5443
const path = null
const userId = 'MY_USER_ID'
const password = 'MY_PASSWORD'
const cert = fs.readFileSync('/path/to/cert.pem')
const key = fs.readFileSync('/path/to/key.pem')
const connectivityArgs = { host, port, path, userId, password, cert, key }
 
// method-specific config
const firstName = 'MARK'
const middleName = ''
const lastName = 'WHITE'
const ssn = '277025100'
const dob = '1991-07-08'
const methodArgs = { firstName, middleName, lastName, ssn, dob }
 
// some simple callbacks
let onThen = result => console.log(result)
let onCatch = err => console.error(err)

Then you can start feeding it to methods that correspond to FDSH services.

For example, the Hub Connectivity Service:

fdsh.HubConnectivityService.hubConnectivityCheck(connectivityArgs)
  .then(onThen)
  .catch(onCatch)

…outputs:

{ ResponseMetadata: { ResponseCode: 'HS000000', ResponseDescriptionText: 'Success' } }

The Verify SSA Composite Service:

fdsh.VerifySSACompositeService.verifySsa(connectivityArgs, methodArgs)
  .then(onThen)
  .catch(onCatch)

…outputs:

 
{ SSACompositeIndividualResponse:
  { ResponseMetadata: { ResponseCode: 'HS000000', ResponseDescriptionText: 'Success' },
    PersonSSNIdentification: '277025100',
    SSAResponse:
    { SSNVerificationIndicator: 'true',
      DeathConfirmationCode: 'Unconfirmed',
      PersonUSCitizenIndicator: 'true',
      PersonIncarcerationInformationIndicator: 'false',
      SSATitleIIMonthlyIncomeInformationIndicator: 'true',
      SSATitleIIAnnualIncomeInformationIndicator: 'false',
      SSATitleIIMonthlyIncome: [Object] } } }

FAQ

What is the Federal Data Services Hub (FDSH)?

It's a system developed for the sharing of information between various entities.

Who oversees the FDSH?

The Centers for Medicare & Medicaid Services (CMS)

Who built the FDSH?

QSS, Inc. (QSSI)

How can I obtain a user ID, password, etc.?

You must speak with CMS.

TODO

  • tests
  • include more services
  • better error handling (more informative error messages, perhaps a unified error messaging scheme, etc.)

Public domain

This project is in the worldwide public domain. As stated in CONTRIBUTING:

This project is in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication.

All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.

Readme

Keywords

Package Sidebar

Install

npm i fdsh-client

Weekly Downloads

2

Version

0.6.1

License

CC0-1.0

Last publish

Collaborators

  • rossdakin