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

@grammyjs/types

Package Overview
Dependencies
Maintainers
3
Versions
85
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@grammyjs/types - npm Package Compare versions

Comparing version 2.0.4 to 2.1.0

61

inline.d.ts

@@ -1,3 +0,4 @@

import { User } from "./manage";
import { Chat, User } from "./manage";
import { Location, MessageEntity, ParseMode } from "./message";
import { LabeledPrice } from "./payment";

@@ -10,4 +11,2 @@ /** This object represents an incoming inline query. When the user sends an empty query, your bot could return some default or trending results. */

from: User;
/** Sender location, only for bots that request user location */
location?: Location;
/** Text of the query (up to 256 characters) */

@@ -17,2 +16,6 @@ query: string;

offset: string;
/** Type of the chat, from which the inline query was sent. Can be either “sender” for a private chat with the inline query sender, “private”, “group”, “supergroup”, or “channel”. The chat type should be always known for requests sent from official clients and most third-party clients, unless the request was sent from a secret chat */
chat_type?: "sender" | Chat["type"];
/** Sender location, only for bots that request user location */
location?: Location;
}

@@ -668,3 +671,3 @@

/** This object represents the content of a message to be sent as a result of an inline query. Telegram clients currently support the following 4 types:
/** This object represents the content of a message to be sent as a result of an inline query. Telegram clients currently support the following 5 types:

@@ -674,3 +677,4 @@ - InputTextMessageContent

- InputVenueMessageContent
- InputContactMessageContent */
- InputContactMessageContent
- InputInvoiceMessageContent */
export type InputMessageContent =

@@ -680,3 +684,4 @@ | InputTextMessageContent

| InputVenueMessageContent
| InputContactMessageContent;
| InputContactMessageContent
| InputInvoiceMessageContent;

@@ -743,2 +748,46 @@ /** Represents the content of a text message to be sent as the result of an inline query. */

/** Represents the content of an invoice message to be sent as the result of an inline query. */
export interface InputInvoiceMessageContent {
/** Product name, 1-32 characters */
title: string;
/** Product description, 1-255 characters */
description: string;
/** Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes. */
payload: string;
/** Payment provider token, obtained via Botfather */
provider_token: string;
/** Three-letter ISO 4217 currency code, see more on currencies */
currency: string;
/** Price breakdown, a list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.) */
prices: LabeledPrice[];
/** The maximum accepted amount for tips in the smallest units of the currency (integer, not float/double). For example, for a maximum tip of US$ 1.45 pass max_tip_amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies). Defaults to 0 */
max_tip_amount?: number;
/** An array of suggested amounts of tip in the smallest units of the currency (integer, not float/double). At most 4 suggested tip amounts can be specified. The suggested tip amounts must be positive, passed in a strictly increased order and must not exceed max_tip_amount. */
suggested_tip_amounts?: number[];
/** An object for data about the invoice, which will be shared with the payment provider. A detailed description of the required fields should be provided by the payment provider. */
provider_data?: string;
/** URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service. People like it better when they see what they are paying for. */
photo_url?: string;
/** Photo size */
photo_size?: number;
/** Photo width */
photo_width?: number;
/** Photo height */
photo_height?: number;
/** Pass True, if you require the user's full name to complete the order */
need_name?: boolean;
/** Pass True, if you require the user's phone number to complete the order */
need_phone_number?: boolean;
/** Pass True, if you require the user's email address to complete the order */
need_email?: boolean;
/** Pass True, if you require the user's shipping address to complete the order */
need_shipping_address?: boolean;
/** Pass True, if user's phone number should be sent to provider */
send_phone_number_to_provider?: boolean;
/** Pass True, if user's email address should be sent to provider */
send_email_to_provider?: boolean;
/** Pass True, if the final price depends on the shipping method */
is_flexible?: boolean;
}
/** Represents a result of an inline query that was chosen by the user and sent to their chat partner.

@@ -745,0 +794,0 @@

@@ -112,2 +112,5 @@ import { InlineKeyboardMarkup } from "./inline";

};
export type VoiceChatScheduledMessage = ServiceMessage & {
voice_chat_scheduled: Value;
};
export type VoiceChatStartedMessage = ServiceMessage & {

@@ -193,2 +196,4 @@ voice_chat_started: Value;

proximity_alert_triggered?: ProximityAlertTriggered;
/** Service message: voice chat scheduled */
voice_chat_scheduled?: VoiceChatScheduled;
/** Service message: voice chat started */

@@ -591,2 +596,8 @@ voice_chat_started?: VoiceChatStarted;

/** This object represents a service message about a voice chat scheduled in the chat. */
export interface VoiceChatScheduled {
/** Point in time (Unix timestamp) when the voice chat is supposed to be started by a chat administrator */
start_date: number;
}
/** This object represents a service message about a voice chat started in the chat. Currently holds no information. */

@@ -593,0 +604,0 @@ export interface VoiceChatStarted {}

2

package.json
{
"name": "@grammyjs/types",
"version": "2.0.4",
"version": "2.1.0",
"description": "Telegram Bot API type declarations for grammY",

@@ -5,0 +5,0 @@ "main": "index.js",

Sorry, the diff of this file is too big to display

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