# Bots Playground

![](https://outline-production-attachments.s3-accelerate.amazonaws.com/uploads/fe746996-bd68-4ba8-a15e-e239ddd741be/b7f2926b-018a-4e08-a047-5a93ceb3e323/image.png?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA4EOUDTOVUICLPZ4P%2F20260919%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260919T064500Z&X-Amz-Expires=86400&X-Amz-Signature=4cb04670e91e403bbb095433fe94d92ee036e135f2af22483eebce343697ae59&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject " =1536x1024")

SmartBots Bots Playground is a JavaScript sandbox to run your own programs to control your SmartBot.

The Bots Playground is available here: [play.mysmartbots.com](https://https://)

## Controlling bots with JavaScript

 ![](https://outline-production-attachments.s3-accelerate.amazonaws.com/uploads/fe746996-bd68-4ba8-a15e-e239ddd741be/ba7e2730-41db-4c5f-8aaa-522a7ddb8e08/image.png?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA4EOUDTOVUICLPZ4P%2F20260919%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260919T064500Z&X-Amz-Expires=86400&X-Amz-Signature=d4278f65e06f9b38355440301d90d512f89b14420bf74ca400f8284d86b0abcf&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject " =2876x1334")

Playground runs programs written JavaScript. The pure javascript: with callbacks, functions, arrays and objects. The underlying javascript engine is NodeJS.

There are some limitations applied yet:

* We do not support ECMAScript 6
* import/export is disabled
* you can't include one script into another (yet)

## Interacting with your bot

Your program runs in a sandbox and sends commands to the bot. Events come from the bots to your program.

This two-way communication is tied directly into javascript program routines:

* Bot commands are functions you call
* Events are callback functions you specify

Refer to the Examples page for more info.

## Read more

* Playground FAQ
* Bug Hunter program
* Create and sell Playground scripts

---

**Documents**

- [Updates & Changes](https://sb-docs-dev.getoutline.com/s/dev/doc/updates-changes-MCGbGnimHj)
- [Development Tools](https://sb-docs-dev.getoutline.com/s/dev/doc/development-tools-7MATbXuMGW)
- [Built-in Functions](https://sb-docs-dev.getoutline.com/s/dev/doc/built-in-functions-BvplCuHZTW)
- [Commands](https://sb-docs-dev.getoutline.com/s/dev/doc/commands-aynA0j9JDH)
- [Events](https://sb-docs-dev.getoutline.com/s/dev/doc/events-hYQZz4dpZI)
- [Selling scripts in Store](https://sb-docs-dev.getoutline.com/s/dev/doc/selling-scripts-in-store-6T3D6O6eKj)
- [AI](https://sb-docs-dev.getoutline.com/s/dev/doc/ai-W6uURwDSGu)
- [Logging](https://sb-docs-dev.getoutline.com/s/dev/doc/logging-Gtqf5x2Zvw)
- [Callbacks & return values](https://sb-docs-dev.getoutline.com/s/dev/doc/callbacks-return-values-pN45bZ8qcC)
- [Async and await](https://sb-docs-dev.getoutline.com/s/dev/doc/async-and-await-EVpINNjt9k)
- [FAQ](https://sb-docs-dev.getoutline.com/s/dev/doc/faq-DURKDBFull)
- [Examples](https://sb-docs-dev.getoutline.com/s/dev/doc/examples-AxBrOQ8cZ1)
- [Bug Hunter program](https://sb-docs-dev.getoutline.com/s/dev/doc/bug-hunter-program-dawt0YNjZJ)