
Security News
vlt Launches "reproduce": A New Tool Challenging the Limits of Package Provenance
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
@microsoft/api2teams
Advanced tools
This is a CLI tool to convert OpenAPI spec file to Teams App command bot project with adaptive cards based on TeamsFx.
To run this CLI and run generated Teams APP in your local dev machine or deploy to Azure, you will need:
Install the CLI
npm install @microsoft/api2teams@latest -g
Download sample-open-api-spec.yml to current working directory
Run the command below to convert sample-open-api-spec.yml
file to Teams App, it will generate teams project to generated-teams-app
folder
api2teams sample-open-api-spec.yml
You can specify which folder to generate teams project as below
api2teams sample-open-api-spec.yml -o my-custom-teams-app-folder
If you want to overwrite the output folder, you can use -f
parameters
api2teams sample-open-api-spec.yml -o my-custom-teams-app-folder -f
If you have other personal swagger yaml files, you can also use this CLI tool to covert them.
The CLI name is api2teams
. Usage is as below:
Usage: api2teams [options] <yaml>
Convert open api spec file to Teams APP project, only for GET operation
Arguments:
yaml yaml file path to convert
Options:
-o, --output [string] output folder for teams app (default: "./generated-teams-app")
-f, --force force overwrite the output folder
-v, --version output the current version
-h, --help display help for command
User can input below command to generate Teams App to default or specific folder:
api2teams sample-open-api-spec.yml # generate teams app to default folder ./generated-teams-app
api2teams sample-open-api-spec.yml -o ./my-app # generate teams app to ./my-app folder
api2teams sample-open-api-spec.yml -o ./my-app -f # generate teams app to ./my-app folder, and force overwrite output folder
api2teams -h # show help message
api2teams -v # show version information
Open generated folder in VSCode, and make sure you have installed Teams Toolkit >= 5.0.0.
Click F5 in VSCode to run the Teams App to view the result (Below is the example of teams app converted by sample-open-api-spec.yml file)
Send message GET /pets/1
to Bot, bot will send a response adaptive card:
Send message GET /pets
to Bot, it will first send request a request adaptive card:
Input value in the request adaptive card, and then click GET button, it will send back response adaptive card:
Send message GET /pets?limit=1
, it will send back response adaptive card directly:
FAQs
openapi spec to teams app
The npm package @microsoft/api2teams receives a total of 6 weekly downloads. As such, @microsoft/api2teams popularity was classified as not popular.
We found that @microsoft/api2teams demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
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.
Security News
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.