Skip to content

Built for people who want to own their automations. Join the waitlist for an invite.

Package listing

@kody/telegram

src/index.ts

31 lines · 778 B · TypeScript
import { DEFAULT_SECRET_NAME, TELEGRAM_API_HOST } from './request.ts'
import { secretSetupUrl } from './validation.ts'

/** Package overview and safety metadata for Telegram Bot API helpers. */
export default async function telegramOverview() {
	return {
		auth: 'bot-token',
		secretName: DEFAULT_SECRET_NAME,
		secretUrl: secretSetupUrl(DEFAULT_SECRET_NAME),
		host: TELEGRAM_API_HOST,
		oauth: false,
		identity: 'bot',
		apiBaseUrl: 'https://api.telegram.org/bot<token>',
		exports: [
			'smoke-test',
			'guide',
			'get-me',
			'get-updates',
			'get-chat',
			'get-webhook-info',
			'send-message',
			'request',
		],
		safety: {
			sendingRequiresConfirmation: true,
			dryRunAvailable: true,
			botTokensSupported: true,
			oauthLoginWidgetUnsupported: true,
		},
	}
}