Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

sqreen-sdk

Package Overview
Dependencies
Maintainers
3
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sqreen-sdk

SDK for Sqreen signals API

  • 0.8.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.4K
decreased by-30.42%
Maintainers
3
Weekly downloads
 
Created
Source

Standalone SDK for Sqreen API

Usage

Installation

The module is available as sqreen-sdk:

$ npm i -S sqreen-sdk

Auth

Before sending any signal to Sqreen ingestion API, the init method must be called first to setup the authentication token and initialize the batch.

const SqreenSDK = require('sqreen-sdk');
// SqreenSDK.init(token, max batch size, max batch age in seconds)
SqreenSDK.init('<my application token>', 100, 60);

The batch is part of the reporting system of the SDK. It means that the signals placed into it, will be reported together when one of the following condition is reached:

  • the batch size reached it's max value
  • the batch is not empty and has not been reported in the interval set as its max age.

Creating Points

Creating Metrics

Creating Traces

HTTP Traces
Usage with Express

FAQs

Package last updated on 05 Jan 2021

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc