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

magicbell

Package Overview
Dependencies
Maintainers
2
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

magicbell - npm Package Compare versions

Comparing version 3.0.0 to 3.0.1

20

CHANGELOG.md
# magicbell
## 3.0.1
### Patch Changes
- [`1ed7ce5`](https://github.com/magicbell-io/magicbell-js/commit/1ed7ce52f27569e06878d6fcac42531055b57fc1) Thanks [@renovate[bot]](https://github.com/renovate%5Bbot%5D)! - Updated dependencies:
- updated `@size-limit/preset-small-lib` to `^8.2.6`.
- [`5a3443f`](https://github.com/magicbell-io/magicbell-js/commit/5a3443f814323352b35eab36d87dbf9e3aa1cba0) Thanks [@renovate[bot]](https://github.com/renovate%5Bbot%5D)! - Updated dependencies:
- updated `openapi-types` to `^12.1.3`.
- [`33d2cab`](https://github.com/magicbell-io/magicbell-js/commit/33d2cabca427e4ea9bc00b2e6304b57d6b7191f6) Thanks [@renovate[bot]](https://github.com/renovate%5Bbot%5D)! - Updated dependencies:
- updated `tsx` to `^3.14.0`.
- [#222](https://github.com/magicbell-io/magicbell-js/pull/222) [`444e653`](https://github.com/magicbell-io/magicbell-js/commit/444e653a435255d5ffcd10257f595cf496e3d1c8) Thanks [@renovate](https://github.com/apps/renovate)! - Updated dependencies:
- updated `recast` to `^0.23.4`.
## 3.0.0

@@ -4,0 +24,0 @@

2

client/error.d.ts
export declare function createError(rawError: ErrorConfig): AuthenticationError | InvalidRequestError | APIError | RateLimitError | IdempotencyError | NotFoundError | UserInputError | UnknownError;
declare type ErrorConfig = {
type ErrorConfig = {
name: string;

@@ -4,0 +4,0 @@ type?: string;

import { ClientOptions, RequestMethod } from './types';
declare type KeyOfType<T, V> = keyof {
type KeyOfType<T, V> = keyof {
[P in keyof T as T[P] extends V ? P : never]: any;
};
export declare type IterablePromise<TData, TKey extends KeyOfType<TData, Array<unknown>> = KeyOfType<TData, Array<unknown>>, TNode = TData[TKey] extends Array<unknown> ? TData[TKey][number] : never> = Promise<TData> & {
export type IterablePromise<TData, TKey extends KeyOfType<TData, Array<unknown>> = KeyOfType<TData, Array<unknown>>, TNode = TData[TKey] extends Array<unknown> ? TData[TKey][number] : never> = Promise<TData> & {
[Symbol.asyncIterator](): Iterator<TNode>;

@@ -7,0 +7,0 @@ forEach(cb: (node: TNode, index: number) => void | boolean | Promise<void | boolean>): Promise<void>;

import { Client } from './client';
import { IterablePromise } from './method';
import { FeatureFlag } from './types';
declare type ResourceRequestOptions = {
type ResourceRequestOptions = {
method: 'GET' | 'PUT' | 'POST' | 'DELETE' | 'PATCH';

@@ -6,0 +6,0 @@ path?: string;

import type { Hooks } from 'ky';
export declare type WithRequired<T, K extends keyof T> = Omit<T, K> & Required<Pick<T, K>>;
export declare type ClientOptions = {
export type WithRequired<T, K extends keyof T> = Omit<T, K> & Required<Pick<T, K>>;
export type ClientOptions = {
host?: string;

@@ -24,4 +24,4 @@ apiKey: string;

};
export declare type FeatureFlag = keyof ClientOptions['features'];
export declare type RequestOptions = {
export type FeatureFlag = keyof ClientOptions['features'];
export type RequestOptions = {
userEmail?: string;

@@ -35,4 +35,4 @@ userExternalId?: string;

};
export declare type RequestMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
export declare type RequestArgs = {
export type RequestMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
export type RequestArgs = {
method: RequestMethod;

@@ -39,0 +39,0 @@ path: string;

@@ -1,2 +0,2 @@

declare type UserData = {
type UserData = {
userExternalId?: string;

@@ -3,0 +3,0 @@ userEmail: string;

{
"name": "magicbell",
"version": "3.0.0",
"version": "3.0.1",
"description": "MagicBell API wrapper",

@@ -5,0 +5,0 @@ "author": "MagicBell <bot@magicbell.io> (https://magicbell.com)",

@@ -7,3 +7,3 @@ import { Client } from './client/client';

import { Users } from './project-resources/users';
export declare type ProjectClientOptions = WithRequired<Omit<ClientOptions, 'userEmail' | 'userExternalId'>, 'apiKey' | 'apiSecret'>;
export type ProjectClientOptions = WithRequired<Omit<ClientOptions, 'userEmail' | 'userExternalId'>, 'apiKey' | 'apiSecret'>;
export declare class ProjectClient extends Client {

@@ -10,0 +10,0 @@ broadcasts: Broadcasts;

@@ -7,7 +7,7 @@ import { type FromSchema } from 'json-schema-to-ts';

import { BroadcastsNotifications } from './broadcasts/notifications';
declare type CreateBroadcastsResponse = FromSchema<typeof schemas.CreateBroadcastsResponseSchema>;
declare type CreateBroadcastsPayload = FromSchema<typeof schemas.CreateBroadcastsPayloadSchema>;
declare type ListBroadcastsResponse = FromSchema<typeof schemas.ListBroadcastsResponseSchema>;
declare type ListBroadcastsPayload = FromSchema<typeof schemas.ListBroadcastsPayloadSchema>;
declare type GetBroadcastsResponse = FromSchema<typeof schemas.GetBroadcastsResponseSchema>;
type CreateBroadcastsResponse = FromSchema<typeof schemas.CreateBroadcastsResponseSchema>;
type CreateBroadcastsPayload = FromSchema<typeof schemas.CreateBroadcastsPayloadSchema>;
type ListBroadcastsResponse = FromSchema<typeof schemas.ListBroadcastsResponseSchema>;
type ListBroadcastsPayload = FromSchema<typeof schemas.ListBroadcastsPayloadSchema>;
type GetBroadcastsResponse = FromSchema<typeof schemas.GetBroadcastsResponseSchema>;
export declare class Broadcasts extends Resource {

@@ -14,0 +14,0 @@ path: string;

@@ -6,4 +6,4 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../../schemas/broadcasts/notifications';
declare type ListBroadcastsNotificationsResponse = FromSchema<typeof schemas.ListBroadcastsNotificationsResponseSchema>;
declare type ListBroadcastsNotificationsPayload = FromSchema<typeof schemas.ListBroadcastsNotificationsPayloadSchema>;
type ListBroadcastsNotificationsResponse = FromSchema<typeof schemas.ListBroadcastsNotificationsResponseSchema>;
type ListBroadcastsNotificationsPayload = FromSchema<typeof schemas.ListBroadcastsNotificationsPayloadSchema>;
export declare class BroadcastsNotifications extends Resource {

@@ -10,0 +10,0 @@ path: string;

@@ -5,5 +5,5 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../schemas/imports';
declare type CreateImportsResponse = FromSchema<typeof schemas.CreateImportsResponseSchema>;
declare type CreateImportsPayload = FromSchema<typeof schemas.CreateImportsPayloadSchema>;
declare type GetImportsResponse = FromSchema<typeof schemas.GetImportsResponseSchema>;
type CreateImportsResponse = FromSchema<typeof schemas.CreateImportsResponseSchema>;
type CreateImportsPayload = FromSchema<typeof schemas.CreateImportsPayloadSchema>;
type GetImportsResponse = FromSchema<typeof schemas.GetImportsResponseSchema>;
export declare class Imports extends Resource {

@@ -10,0 +10,0 @@ path: string;

@@ -7,3 +7,3 @@ import { type FromSchema } from 'json-schema-to-ts';

import { MetricsTopics } from './metrics/topics';
declare type GetMetricsResponse = FromSchema<typeof schemas.GetMetricsResponseSchema>;
type GetMetricsResponse = FromSchema<typeof schemas.GetMetricsResponseSchema>;
export declare class Metrics extends Resource {

@@ -10,0 +10,0 @@ path: string;

@@ -5,3 +5,3 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../../schemas/metrics/categories';
declare type GetMetricsCategoriesResponse = FromSchema<typeof schemas.GetMetricsCategoriesResponseSchema>;
type GetMetricsCategoriesResponse = FromSchema<typeof schemas.GetMetricsCategoriesResponseSchema>;
export declare class MetricsCategories extends Resource {

@@ -8,0 +8,0 @@ path: string;

@@ -5,3 +5,3 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../../schemas/metrics/topics';
declare type GetMetricsTopicsResponse = FromSchema<typeof schemas.GetMetricsTopicsResponseSchema>;
type GetMetricsTopicsResponse = FromSchema<typeof schemas.GetMetricsTopicsResponseSchema>;
export declare class MetricsTopics extends Resource {

@@ -8,0 +8,0 @@ path: string;

@@ -8,13 +8,13 @@ import { type FromSchema } from 'json-schema-to-ts';

import { UsersPushSubscriptions } from './users/push-subscriptions';
declare type CreateUsersResponse = FromSchema<typeof schemas.CreateUsersResponseSchema>;
declare type CreateUsersPayload = FromSchema<typeof schemas.CreateUsersPayloadSchema>;
declare type ListUsersResponse = FromSchema<typeof schemas.ListUsersResponseSchema>;
declare type ListUsersPayload = FromSchema<typeof schemas.ListUsersPayloadSchema>;
declare type GetUsersResponse = FromSchema<typeof schemas.GetUsersResponseSchema>;
declare type UpdateUsersResponse = FromSchema<typeof schemas.UpdateUsersResponseSchema>;
declare type UpdateUsersPayload = FromSchema<typeof schemas.UpdateUsersPayloadSchema>;
declare type UpdateByEmailUsersResponse = FromSchema<typeof schemas.UpdateByEmailUsersResponseSchema>;
declare type UpdateByEmailUsersPayload = FromSchema<typeof schemas.UpdateByEmailUsersPayloadSchema>;
declare type UpdateByExternalIdUsersResponse = FromSchema<typeof schemas.UpdateByExternalIdUsersResponseSchema>;
declare type UpdateByExternalIdUsersPayload = FromSchema<typeof schemas.UpdateByExternalIdUsersPayloadSchema>;
type CreateUsersResponse = FromSchema<typeof schemas.CreateUsersResponseSchema>;
type CreateUsersPayload = FromSchema<typeof schemas.CreateUsersPayloadSchema>;
type ListUsersResponse = FromSchema<typeof schemas.ListUsersResponseSchema>;
type ListUsersPayload = FromSchema<typeof schemas.ListUsersPayloadSchema>;
type GetUsersResponse = FromSchema<typeof schemas.GetUsersResponseSchema>;
type UpdateUsersResponse = FromSchema<typeof schemas.UpdateUsersResponseSchema>;
type UpdateUsersPayload = FromSchema<typeof schemas.UpdateUsersPayloadSchema>;
type UpdateByEmailUsersResponse = FromSchema<typeof schemas.UpdateByEmailUsersResponseSchema>;
type UpdateByEmailUsersPayload = FromSchema<typeof schemas.UpdateByEmailUsersPayloadSchema>;
type UpdateByExternalIdUsersResponse = FromSchema<typeof schemas.UpdateByExternalIdUsersResponseSchema>;
type UpdateByExternalIdUsersPayload = FromSchema<typeof schemas.UpdateByExternalIdUsersPayloadSchema>;
export declare class Users extends Resource {

@@ -21,0 +21,0 @@ path: string;

@@ -6,4 +6,4 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../../schemas/users/notifications';
declare type ListUsersNotificationsResponse = FromSchema<typeof schemas.ListUsersNotificationsResponseSchema>;
declare type ListUsersNotificationsPayload = FromSchema<typeof schemas.ListUsersNotificationsPayloadSchema>;
type ListUsersNotificationsResponse = FromSchema<typeof schemas.ListUsersNotificationsResponseSchema>;
type ListUsersNotificationsPayload = FromSchema<typeof schemas.ListUsersNotificationsPayloadSchema>;
export declare class UsersNotifications extends Resource {

@@ -10,0 +10,0 @@ path: string;

@@ -6,4 +6,4 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../../schemas/users/push-subscriptions';
declare type ListUsersPushSubscriptionsResponse = FromSchema<typeof schemas.ListUsersPushSubscriptionsResponseSchema>;
declare type ListUsersPushSubscriptionsPayload = FromSchema<typeof schemas.ListUsersPushSubscriptionsPayloadSchema>;
type ListUsersPushSubscriptionsResponse = FromSchema<typeof schemas.ListUsersPushSubscriptionsResponseSchema>;
type ListUsersPushSubscriptionsPayload = FromSchema<typeof schemas.ListUsersPushSubscriptionsPayloadSchema>;
export declare class UsersPushSubscriptions extends Resource {

@@ -10,0 +10,0 @@ path: string;

import { Client } from '../client/client';
import { RequestOptions } from '../client/types';
declare type Event = {
type Event = {
id: string;

@@ -42,3 +42,3 @@ timestamp: number;

});
declare type IterableEventSource<TNode> = {
type IterableEventSource<TNode> = {
[Symbol.asyncIterator](): Iterator<TNode>;

@@ -48,3 +48,3 @@ forEach(cb: (node: TNode, index: number) => void | boolean | Promise<void | boolean>): Promise<void>;

};
export declare type Listener = (options?: RequestOptions) => IterableEventSource<Event>;
export type Listener = (options?: RequestOptions) => IterableEventSource<Event>;
export declare function createListener(client: InstanceType<typeof Client>, args?: {

@@ -51,0 +51,0 @@ sseHost?: string;

@@ -7,3 +7,3 @@ import { Client } from './client/client';

import { Subscriptions } from './user-resources/subscriptions';
export declare type UserClientOptions = WithRequired<Omit<ClientOptions, 'apiSecret'>, 'apiKey' | 'userEmail'> | WithRequired<Omit<ClientOptions, 'apiSecret'>, 'apiKey' | 'userExternalId'>;
export type UserClientOptions = WithRequired<Omit<ClientOptions, 'apiSecret'>, 'apiKey' | 'userEmail'> | WithRequired<Omit<ClientOptions, 'apiSecret'>, 'apiKey' | 'userExternalId'>;
export declare class UserClient extends Client {

@@ -10,0 +10,0 @@ listen: import("./resources/listen").Listener;

@@ -5,5 +5,5 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../schemas/notification-preferences';
declare type GetNotificationPreferencesResponse = FromSchema<typeof schemas.GetNotificationPreferencesResponseSchema>;
declare type UpdateNotificationPreferencesResponse = FromSchema<typeof schemas.UpdateNotificationPreferencesResponseSchema>;
declare type UpdateNotificationPreferencesPayload = FromSchema<typeof schemas.UpdateNotificationPreferencesPayloadSchema>;
type GetNotificationPreferencesResponse = FromSchema<typeof schemas.GetNotificationPreferencesResponseSchema>;
type UpdateNotificationPreferencesResponse = FromSchema<typeof schemas.UpdateNotificationPreferencesResponseSchema>;
type UpdateNotificationPreferencesPayload = FromSchema<typeof schemas.UpdateNotificationPreferencesPayloadSchema>;
export declare class NotificationPreferences extends Resource {

@@ -10,0 +10,0 @@ path: string;

@@ -6,7 +6,7 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../schemas/notifications';
declare type MarkAllReadNotificationsPayload = FromSchema<typeof schemas.MarkAllReadNotificationsPayloadSchema>;
declare type MarkAllSeenNotificationsPayload = FromSchema<typeof schemas.MarkAllSeenNotificationsPayloadSchema>;
declare type ListNotificationsResponse = FromSchema<typeof schemas.ListNotificationsResponseSchema>;
declare type ListNotificationsPayload = FromSchema<typeof schemas.ListNotificationsPayloadSchema>;
declare type GetNotificationsResponse = FromSchema<typeof schemas.GetNotificationsResponseSchema>;
type MarkAllReadNotificationsPayload = FromSchema<typeof schemas.MarkAllReadNotificationsPayloadSchema>;
type MarkAllSeenNotificationsPayload = FromSchema<typeof schemas.MarkAllSeenNotificationsPayloadSchema>;
type ListNotificationsResponse = FromSchema<typeof schemas.ListNotificationsResponseSchema>;
type ListNotificationsPayload = FromSchema<typeof schemas.ListNotificationsPayloadSchema>;
type GetNotificationsResponse = FromSchema<typeof schemas.GetNotificationsResponseSchema>;
export declare class Notifications extends Resource {

@@ -13,0 +13,0 @@ path: string;

@@ -6,5 +6,5 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../schemas/push-subscriptions';
declare type CreatePushSubscriptionsResponse = FromSchema<typeof schemas.CreatePushSubscriptionsResponseSchema>;
declare type CreatePushSubscriptionsPayload = FromSchema<typeof schemas.CreatePushSubscriptionsPayloadSchema>;
declare type ListPushSubscriptionsResponse = FromSchema<typeof schemas.ListPushSubscriptionsResponseSchema>;
type CreatePushSubscriptionsResponse = FromSchema<typeof schemas.CreatePushSubscriptionsResponseSchema>;
type CreatePushSubscriptionsPayload = FromSchema<typeof schemas.CreatePushSubscriptionsPayloadSchema>;
type ListPushSubscriptionsResponse = FromSchema<typeof schemas.ListPushSubscriptionsResponseSchema>;
export declare class PushSubscriptions extends Resource {

@@ -11,0 +11,0 @@ path: string;

@@ -6,9 +6,9 @@ import { type FromSchema } from 'json-schema-to-ts';

import * as schemas from '../schemas/subscriptions';
declare type CreateSubscriptionsResponse = FromSchema<typeof schemas.CreateSubscriptionsResponseSchema>;
declare type CreateSubscriptionsPayload = FromSchema<typeof schemas.CreateSubscriptionsPayloadSchema>;
declare type UnsubscribeSubscriptionsResponse = FromSchema<typeof schemas.UnsubscribeSubscriptionsResponseSchema>;
declare type UnsubscribeSubscriptionsPayload = FromSchema<typeof schemas.UnsubscribeSubscriptionsPayloadSchema>;
declare type ListSubscriptionsResponse = FromSchema<typeof schemas.ListSubscriptionsResponseSchema>;
declare type GetSubscriptionsResponse = FromSchema<typeof schemas.GetSubscriptionsResponseSchema>;
declare type DeleteSubscriptionsPayload = FromSchema<typeof schemas.DeleteSubscriptionsPayloadSchema>;
type CreateSubscriptionsResponse = FromSchema<typeof schemas.CreateSubscriptionsResponseSchema>;
type CreateSubscriptionsPayload = FromSchema<typeof schemas.CreateSubscriptionsPayloadSchema>;
type UnsubscribeSubscriptionsResponse = FromSchema<typeof schemas.UnsubscribeSubscriptionsResponseSchema>;
type UnsubscribeSubscriptionsPayload = FromSchema<typeof schemas.UnsubscribeSubscriptionsPayloadSchema>;
type ListSubscriptionsResponse = FromSchema<typeof schemas.ListSubscriptionsResponseSchema>;
type GetSubscriptionsResponse = FromSchema<typeof schemas.GetSubscriptionsResponseSchema>;
type DeleteSubscriptionsPayload = FromSchema<typeof schemas.DeleteSubscriptionsPayloadSchema>;
export declare class Subscriptions extends Resource {

@@ -15,0 +15,0 @@ path: string;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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