1.0.1 • Published 2 years ago

@ravenappdev/raven_api v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Raven

raven - Client SDK for Raven Api This is the SDK Documentation of Raven. You can find out more about Raven at https://ravenapp.dev/.

Installation (via npm)

npm install @ravenappdev/raven --save

Requirements

You will need to get a Raven API key to get started. You can sign up and create one for free at ravenapp.dev.

Getting Started

Please follow the installation instruction and execute the following JS code:

import { RavenClient } from "raven";

const config = {
  // Configure API key authorization
  apiKey: "YOUR API KEY",
};
const raven = RavenClient(config);

var appId = "appId_example"; // {String} app id of raven app

var event = {
  //event payload for bulk event to be trggered
};

var opts = {
  //other options
  idempotencyKey: uuidv4(),
};

raven.sendBulk({ appId, event, opts }).then(
  function (response) {
    console.log("API called successfully. Returned response: " + response);
  },
  function (error) {
    console.error(error);
  }
);

Documentation for API Endpoints

All URIs are relative to https://api.ravenapp.dev

ClassMethodHTTP requestDescription
RavenClientsendBulkPOST /v1/apps/{app_id}/events/bulk_sendsends the event in bulk to all the clients specified
RavenClientsendPOST /v1/apps/{app_id}/events/sendsends the event to the client specified

Documentation for Models