New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@tryvital/vital-node

Package Overview
Dependencies
Maintainers
1
Versions
290
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tryvital/vital-node - npm Package Compare versions

Comparing version 0.2.9 to 0.3.0

11

client/Webhooks.ts

@@ -45,2 +45,13 @@ import { AxiosInstance } from 'axios';

public async test(
event_code: 'HISTORICAL_DATA_UPDATE' | 'CREATED',
webhook_type: 'activity' | 'body' | 'sleep' | 'workouts'
): Promise<ClientFacingWebhook> {
const resp = await this.client.post(this.baseURL.concat('/webhooks/test'), {
event_code,
webhook_type,
});
return resp.data;
}
public constructWebhookEvent(

@@ -47,0 +58,0 @@ payload: string,

1

dist/client/Webhooks.d.ts

@@ -11,3 +11,4 @@ import { AxiosInstance } from 'axios';

deregister(webhookId: string): Promise<ClientFacingWebhook>;
test(event_code: 'HISTORICAL_DATA_UPDATE' | 'CREATED', webhook_type: 'activity' | 'body' | 'sleep' | 'workouts'): Promise<ClientFacingWebhook>;
constructWebhookEvent(payload: string, header: string, secret: string, tolerance?: number): Record<string, unknown>;
}

@@ -90,2 +90,18 @@ "use strict";

};
WebhooksApi.prototype.test = function (event_code, webhook_type) {
return __awaiter(this, void 0, void 0, function () {
var resp;
return __generator(this, function (_a) {
switch (_a.label) {
case 0: return [4 /*yield*/, this.client.post(this.baseURL.concat('/webhooks/test'), {
event_code: event_code,
webhook_type: webhook_type,
})];
case 1:
resp = _a.sent();
return [2 /*return*/, resp.data];
}
});
});
};
WebhooksApi.prototype.constructWebhookEvent = function (payload, header, secret, tolerance) {

@@ -92,0 +108,0 @@ if (tolerance === void 0) { tolerance = undefined; }

2

package.json
{
"name": "@tryvital/vital-node",
"version": "0.2.9",
"version": "0.3.0",
"description": "Node client for Vital",

@@ -5,0 +5,0 @@ "author": "maitham",

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