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

@apidog/multibot-sdk-ts

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@apidog/multibot-sdk-ts - npm Package Compare versions

Comparing version 0.0.4-0 to 0.0.4

dist/abstract-bot.js

1

dist/abstract-bot.d.ts

@@ -24,2 +24,1 @@ export interface IBotPolling {

export {};
//# sourceMappingURL=abstract-bot.d.ts.map
export * from './telegram';
export * from './vk';
//# sourceMappingURL=index.d.ts.map
export declare const messageTypes: string[];
//# sourceMappingURL=const.d.ts.map

@@ -5,2 +5,3 @@ import AbstractBot, { IBotPolling, Listener } from '../abstract-bot';

import { User } from './types/user';
import { Config, Request } from './types/api';
declare const enum EventType {

@@ -29,9 +30,9 @@ Message = "message",

export declare type EventArgumentMessage = Listener<ArgumentMessage>;
export declare class TelegramBot extends AbstractBot<TelegramBot.Config, EventType, EventListener> implements IBotPolling {
static readonly defaultConfig: TelegramBot.Config;
constructor(config: TelegramBot.Config);
export declare class TelegramBot extends AbstractBot<Config, EventType, EventListener> implements IBotPolling {
static readonly defaultConfig: Config;
constructor(config: Config);
protected getApiEndpoint: (method: string) => string;
private readonly handleMethodsForFiles;
private handleParamsForFiles;
request: TelegramBot.Request;
request: Request;
/**

@@ -53,2 +54,1 @@ *

export * from './utils';
//# sourceMappingURL=index.d.ts.map
import { Location } from './media';
import { User } from './user';
import { InlineKeyboard } from './keyboard';
import { User } from './user';
declare namespace TelegramBot {
interface InlineQuery {
id: string;
from: User;
location?: Location;
query: string;
offset: string;
}
interface InlineQueryResultBase {
id: string;
reply_markup?: InlineKeyboard;
}
interface InlineQueryResultArticle extends InlineQueryResultBase {
type: 'article';
title: string;
input_message_content: InputMessageContent;
url?: string;
hide_url?: boolean;
description?: string;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
interface InlineQueryResultPhoto extends InlineQueryResultBase {
type: 'photo';
photo_url: string;
thumb_url: string;
photo_width?: number;
photo_height?: number;
title?: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultGif extends InlineQueryResultBase {
type: 'gif';
gif_url: string;
gif_width?: number;
gif_height?: number;
gif_duration?: number;
thumb_url?: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultMpeg4Gif extends InlineQueryResultBase {
type: 'mpeg4_gif';
mpeg4_url: string;
mpeg4_width?: number;
mpeg4_height?: number;
mpeg4_duration?: number;
thumb_url?: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultVideo extends InlineQueryResultBase {
type: 'video';
video_url: string;
mime_type: string;
thumb_url: string;
title: string;
caption?: string;
video_width?: number;
video_height?: number;
video_duration?: number;
description?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultAudio extends InlineQueryResultBase {
type: 'audio';
audio_url: string;
title: string;
caption?: string;
performer?: string;
audio_duration?: number;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultVoice extends InlineQueryResultBase {
type: 'voice';
voice_url: string;
title: string;
caption?: string;
voice_duration?: number;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultDocument extends InlineQueryResultBase {
type: 'document';
title: string;
caption?: string;
document_url: string;
mime_type: string;
description?: string;
input_message_content?: InputMessageContent;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
interface InlineQueryResultLocationBase extends InlineQueryResultBase {
latitude: number;
longitude: number;
title: string;
input_message_content?: InputMessageContent;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
interface InlineQueryResultLocation extends InlineQueryResultLocationBase {
type: 'location';
}
interface InlineQueryResultVenue extends InlineQueryResultLocationBase {
type: 'venue';
address: string;
foursquare_id?: string;
}
interface InlineQueryResultContact extends InlineQueryResultBase {
type: 'contact';
phone_number: string;
first_name: string;
last_name?: string;
input_message_content?: InputMessageContent;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
interface InlineQueryResultGame extends InlineQueryResultBase {
type: 'game';
game_short_name: string;
}
interface InlineQueryResultCachedPhoto extends InlineQueryResultBase {
type: 'photo';
photo_file_id: string;
title?: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedGif extends InlineQueryResultBase {
type: 'gif';
gif_file_id: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedMpeg4Gif extends InlineQueryResultBase {
type: 'mpeg4_gif';
mpeg4_file_id: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedSticker extends InlineQueryResultBase {
type: 'sticker';
sticker_file_id: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedDocument extends InlineQueryResultBase {
type: 'document';
title: string;
document_file_id: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedVideo extends InlineQueryResultBase {
type: 'video';
video_file_id: string;
title: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedVoice extends InlineQueryResultBase {
type: 'voice';
voice_file_id: string;
title: string;
caption?: string;
input_message_content?: InputMessageContent;
}
interface InlineQueryResultCachedAudio extends InlineQueryResultBase {
type: 'audio';
audio_file_id: string;
caption?: string;
input_message_content?: InputMessageContent;
}
type InputMessageContent = object;
type InlineQueryResult = InlineQueryResultCachedAudio | InlineQueryResultCachedDocument | InlineQueryResultCachedGif | InlineQueryResultCachedMpeg4Gif | InlineQueryResultCachedPhoto | InlineQueryResultCachedSticker | InlineQueryResultCachedVideo | InlineQueryResultCachedVoice | InlineQueryResultArticle | InlineQueryResultAudio | InlineQueryResultContact | InlineQueryResultGame | InlineQueryResultDocument | InlineQueryResultGif | InlineQueryResultLocation | InlineQueryResultMpeg4Gif | InlineQueryResultPhoto | InlineQueryResultVenue | InlineQueryResultVideo | InlineQueryResultVoice;
export interface InlineQuery {
id: string;
from: User;
location?: Location;
query: string;
offset: string;
}
export = TelegramBot;
//# sourceMappingURL=inline-query.d.ts.map
export interface InlineQueryResultBase {
id: string;
reply_markup?: InlineKeyboard;
}
export interface InlineQueryResultArticle extends InlineQueryResultBase {
type: 'article';
title: string;
input_message_content: InputMessageContent;
url?: string;
hide_url?: boolean;
description?: string;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
export interface InlineQueryResultPhoto extends InlineQueryResultBase {
type: 'photo';
photo_url: string;
thumb_url: string;
photo_width?: number;
photo_height?: number;
title?: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultGif extends InlineQueryResultBase {
type: 'gif';
gif_url: string;
gif_width?: number;
gif_height?: number;
gif_duration?: number;
thumb_url?: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultMpeg4Gif extends InlineQueryResultBase {
type: 'mpeg4_gif';
mpeg4_url: string;
mpeg4_width?: number;
mpeg4_height?: number;
mpeg4_duration?: number;
thumb_url?: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultVideo extends InlineQueryResultBase {
type: 'video';
video_url: string;
mime_type: string;
thumb_url: string;
title: string;
caption?: string;
video_width?: number;
video_height?: number;
video_duration?: number;
description?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultAudio extends InlineQueryResultBase {
type: 'audio';
audio_url: string;
title: string;
caption?: string;
performer?: string;
audio_duration?: number;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultVoice extends InlineQueryResultBase {
type: 'voice';
voice_url: string;
title: string;
caption?: string;
voice_duration?: number;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultDocument extends InlineQueryResultBase {
type: 'document';
title: string;
caption?: string;
document_url: string;
mime_type: string;
description?: string;
input_message_content?: InputMessageContent;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
export interface InlineQueryResultLocationBase extends InlineQueryResultBase {
latitude: number;
longitude: number;
title: string;
input_message_content?: InputMessageContent;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
export interface InlineQueryResultLocation extends InlineQueryResultLocationBase {
type: 'location';
}
export interface InlineQueryResultVenue extends InlineQueryResultLocationBase {
type: 'venue';
address: string;
foursquare_id?: string;
}
export interface InlineQueryResultContact extends InlineQueryResultBase {
type: 'contact';
phone_number: string;
first_name: string;
last_name?: string;
input_message_content?: InputMessageContent;
thumb_url?: string;
thumb_width?: number;
thumb_height?: number;
}
export interface InlineQueryResultGame extends InlineQueryResultBase {
type: 'game';
game_short_name: string;
}
export interface InlineQueryResultCachedPhoto extends InlineQueryResultBase {
type: 'photo';
photo_file_id: string;
title?: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedGif extends InlineQueryResultBase {
type: 'gif';
gif_file_id: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedMpeg4Gif extends InlineQueryResultBase {
type: 'mpeg4_gif';
mpeg4_file_id: string;
title?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedSticker extends InlineQueryResultBase {
type: 'sticker';
sticker_file_id: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedDocument extends InlineQueryResultBase {
type: 'document';
title: string;
document_file_id: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedVideo extends InlineQueryResultBase {
type: 'video';
video_file_id: string;
title: string;
description?: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedVoice extends InlineQueryResultBase {
type: 'voice';
voice_file_id: string;
title: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export interface InlineQueryResultCachedAudio extends InlineQueryResultBase {
type: 'audio';
audio_file_id: string;
caption?: string;
input_message_content?: InputMessageContent;
}
export declare type InputMessageContent = object;
export declare type InlineQueryResult = InlineQueryResultCachedAudio | InlineQueryResultCachedDocument | InlineQueryResultCachedGif | InlineQueryResultCachedMpeg4Gif | InlineQueryResultCachedPhoto | InlineQueryResultCachedSticker | InlineQueryResultCachedVideo | InlineQueryResultCachedVoice | InlineQueryResultArticle | InlineQueryResultAudio | InlineQueryResultContact | InlineQueryResultGame | InlineQueryResultDocument | InlineQueryResultGif | InlineQueryResultLocation | InlineQueryResultMpeg4Gif | InlineQueryResultPhoto | InlineQueryResultVenue | InlineQueryResultVideo | InlineQueryResultVoice;
export * from './text-entites';
export * from './reply';
export * from '../../utils/delay';
export * from './md-v2';
//# sourceMappingURL=index.d.ts.map

@@ -120,2 +120,1 @@ import { InlineKeyboard, CallbackGame } from '../types/keyboard';

export {};
//# sourceMappingURL=keyboard.d.ts.map
export {};
//# sourceMappingURL=keyboard.test.d.ts.map

@@ -13,2 +13,1 @@ declare type MdV2fx = (text: string) => string;

export {};
//# sourceMappingURL=md-v2.d.ts.map
export {};
//# sourceMappingURL=md-v2.test.d.ts.map

@@ -5,2 +5,1 @@ import { Message } from '../types/message';

export declare const reply: (bot: TelegramBot, message: Message, text: string, options?: SendMessageOptions) => Promise<Message>;
//# sourceMappingURL=reply.d.ts.map

@@ -5,2 +5,1 @@ import { Message, MessageEntity } from '../types/message';

})[];
//# sourceMappingURL=text-entites.d.ts.map
export {};
//# sourceMappingURL=text-entites.test.d.ts.map
export declare const delay: (ms: number) => Promise<unknown>;
//# sourceMappingURL=delay.d.ts.map
export {};
//# sourceMappingURL=delay.test.d.ts.map
import AbstractBot, { IBotPolling, Listener } from '../abstract-bot';
import { Message } from './types/api';
import { Message } from './types/message';
import { Config, Request } from './types/api';
declare const enum EventType {

@@ -13,8 +14,8 @@ Message = "message",

}
export declare class VkBot extends AbstractBot<VkBot.Config, EventType, EventListener> implements IBotPolling {
static readonly defaultConfig: VkBot.Config;
export declare class VkBot extends AbstractBot<Config, EventType, EventListener> implements IBotPolling {
static readonly defaultConfig: Config;
private server?;
constructor(config: VkBot.Config);
constructor(config: Config);
protected getApiEndpoint: (method: string) => string;
request: VkBot.Request;
request: Request;
/**

@@ -33,2 +34,1 @@ * Polling

export {};
//# sourceMappingURL=index.d.ts.map
{
"name": "@apidog/multibot-sdk-ts",
"version": "0.0.4-0",
"version": "0.0.4",
"description": "Telegram and VK bot SDK for TypeScript",

@@ -12,5 +12,5 @@ "main": "dist/index.js",

"scripts": {
"dev": "webpack && node dist/main",
"dev": "npm run build && node dist/main",
"prepare": "npm run build",
"build": "NODE_ENV=production webpack",
"build": "tsc",
"test": "jest",

@@ -30,24 +30,11 @@ "lint": "eslint --cache --ext .ts,.tsx src"

"devDependencies": {
"@babel/core": "^7.9.0",
"@babel/plugin-proposal-class-properties": "^7.8.3",
"@babel/plugin-proposal-optional-chaining": "^7.9.0",
"@babel/plugin-syntax-typescript": "^7.8.3",
"@babel/plugin-transform-runtime": "^7.9.0",
"@babel/preset-env": "^7.9.0",
"@types/jest": "^25.1.4",
"@types/node": "^13.9.2",
"@types/webpack": "^4.41.8",
"@typescript-eslint/eslint-plugin": "^2.25.0",
"@typescript-eslint/parser": "^2.25.0",
"babel-loader": "^8.1.0",
"eslint": "^6.8.0",
"form-data": "^3.0.0",
"jest": "^25.1.0",
"npm-run-all": "^4.1.5",
"terser-webpack-plugin": "^2.3.5",
"ts-jest": "^25.2.1",
"ts-loader": "^6.2.1",
"typescript": "^3.8.3",
"webpack": "^4.42.0",
"webpack-cli": "^3.3.11"
"typescript": "^3.8.3"
},

@@ -54,0 +41,0 @@ "bugs": {

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