Nothing is sent without a yes

Bot Cookbook

Search the index

Search templates, guides, and prompts.

Prompt

Write and test a small script: Grok Bot prompt

Bot writes a script, runs it on sample data you provide, and shows the result.

Updated 15 Oct 2026.

We've tried this one (last run 14 Oct 2026).

Are you the creator? Ask us to remove this.

Prompt

Write a [language] script that [task]. I will put sample input in the workspace. Run it and show me the output and any errors before I use it.

Fill in

  • [language]
  • [task]

Connectors

none

Uses this feature

Cloud computer · Computer and apps

Which task is “Write and test a small script” written for?

Use “Write and test a small script” when you want the bot to do this job: “Write a [language] script that [task]. I will put sample input in the workspace.”

What do I replace in “Write and test a small script” before I send it?

In “Write and test a small script”, where it says “Write a [language] script that [task]”, put the language you mean and where it says “a [language] script that [task]. I will”, put the task you mean. Send it without [language] and [task] still sitting in the text.

What does a finished “Write and test a small script” look like?

A finished run of “Write and test a small script” looks like this: “Bot writes a script, runs it on sample data you provide, and shows the result.”

What should I double-check before I trust “Write and test a small script”?

The miss with “Write and test a small script” is sending [language] and [task] through as if they were real values. Fill them so the reply can still match “Bot writes a script, runs it on sample data you provide, and shows the result.”