Socket
Socket
Sign inDemoInstall

oscn-js

Package Overview
Dependencies
8
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    oscn-js

A json rest api wrapper for the oscn alpha api.


Version published
Weekly downloads
2
decreased by-60%
Maintainers
1
Install size
489 kB
Created
Weekly downloads
 

Readme

Source

OSCN-JS

A Node.js wrapper for the oscn api that's currently in alpha.

How To Use

npm i s oscn-js
or
yarn oscn-js

Then you can import it into your project like this:

import OSCN from 'oscn-js';
let os = new OSCN({api_key:"YOUR_API_KEY"});

os.getDockets(county,case_number).then() ..... 

Example Elastic Search Query

let obj = {

    "query":{
 
       "bool":{
 
          "must":[
             {
                 "match":{
                     "casetype": "CF"
                 }	
             },
 
             {
 
                "nested":{
 
                   "score_mode":"max",
 
                   "path":"parties",
 
                   "query":{
 
                      "bool":{
 
                         "must":[
 
                            {
 
                               "match":{
 
                                  "parties.name":"daniel"
 
                               }
 
                            }
 
                         ]
 
                      }
 
                   }
 
                }
 
             }
 
          ]
 
       }
 
    }
 
 }

os.elasticSearchCases(obj).then(res=>{
    console.log('response from api', res);
})

Keywords

FAQs

Last updated on 11 Feb 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc