@botbuildercommunity/storage-mssql
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

Bot Builder Microsoft SQL Server Storage

This is a simple storage adapter for Microsoft SQL Server.

Installation

npm install @botbuildercommunity/storage-mssql --save

Usage

import { MSSQLStorage } from '@botbuildercommunity/storage-mssql';

const storage = new MSSQLStorage({ 
    user: <DATABASE_USERNAME>,
    password: <DATABASE_PASSWORD>,
    server: <DATABASE_SERVER>,
    database: <DATABASE_NAME>,
    table: <DATABASE_TABLE>
});

const conversationState = new ConversationState(storage);
const userState = new UserState(storage);

This module uses the node-mssql package for SQL connectivity. The MSSQLOptions that is passed to the MSSQLStorage object extends the config object of that package. All options from that config option can be passed in.

This module assumes two string-based columns in your database table: id and data.

/@botbuildercommunity/storage-mssql/

    Package Sidebar

    Install

    npm i @botbuildercommunity/storage-mssql

    Weekly Downloads

    7

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    111 kB

    Total Files

    33

    Last publish

    Collaborators

    • jamesemann
    • cloudguy_pro
    • imick