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

botframework-schema

Package Overview
Dependencies
Maintainers
1
Versions
544
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

botframework-schema

Activity schema for the Microsoft Bot Framework.

  • 4.11.0-dev.20201021.0c90cc4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
85K
decreased by-5.08%
Maintainers
1
Weekly downloads
 
Created

What is botframework-schema?

The botframework-schema npm package provides the necessary types and interfaces for building bots using the Microsoft Bot Framework. It includes definitions for activities, channels, and other components that are essential for bot communication and interaction.

What are botframework-schema's main functionalities?

Activity

Defines the structure of an activity, which is a fundamental unit of communication in the Bot Framework. This example creates a message activity with a simple text message.

const { ActivityTypes } = require('botframework-schema');

const messageActivity = {
  type: ActivityTypes.Message,
  text: 'Hello, world!'
};
console.log(messageActivity);

ChannelAccount

Represents a user or bot on a channel. This example creates a ChannelAccount object for a user with an ID and name.

const { ChannelAccount } = require('botframework-schema');

const user = new ChannelAccount({
  id: 'user1',
  name: 'John Doe'
});
console.log(user);

ConversationReference

Defines a reference to a conversation, which includes details about the activity, user, bot, and conversation. This example creates a ConversationReference object with sample data.

const { ConversationReference } = require('botframework-schema');

const conversationRef = new ConversationReference({
  activityId: 'activity1',
  user: { id: 'user1', name: 'John Doe' },
  bot: { id: 'bot1', name: 'Bot' },
  conversation: { id: 'conversation1' }
});
console.log(conversationRef);

Other packages similar to botframework-schema

Keywords

FAQs

Package last updated on 21 Oct 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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