Skip to main content

Availability

To develop and test plugins locally, use file:// paths and the reload API. You can then iterate instantly without reinstalling the plugin.

Quick Start: 5-Minute Setup

1. Create Your Plugin

Create main.go:
Expandable

2. Build and Get Absolute Path

3. Register Plugin Once

Expandable
Save the plugin ID from the response!

4. Development Loop

Now you can iterate without reinstalling:
That’s it! Your changes are live instantly.

The Development Loop Explained

When Do You Need to Reinstall?

You only need to update the plugin registration (not just reload) when:

Development Environment Setup

Run AI Studio locally for fastest iteration:

Option 2: Docker Compose

Mount your plugin directory:
Then use container paths:
ALLOW_INTERNAL_NETWORK_ACCESS=true allows every internal host on the platform. Use it only on a local development instance. From Tyk AI Studio 2.3.0:
  • Plugins do not inherit the environment of AI Studio. If your plugin reads an environment variable, add its name to PLUGIN_ENV_PASSTHROUGH. Refer to Plugin Environment.
  • AI Studio requires signatures on OCI plugins by default (Enterprise Edition). To test an unsigned OCI build, set AI_STUDIO_OCI_REQUIRE_SIGNATURE=false on your development instance. Refer to Signature Settings.

Option 3: Remote AI Studio

For remote instances, use grpc:// deployment during development:

Helper Scripts

dev.sh - One-Command Development

Create this script in your plugin directory:
Expandable
Usage:

watch.sh - Auto-Rebuild on Save

Expandable

Project Structure Recommendations

Makefile Example

Expandable
Usage:

Debugging Tips

Plugin logs go to AI Studio’s log output:
Expandable
Before registering, test your plugin runs:

Common Issues and Resolution

Symptoms: Reload returns success but changes aren’t reflectedSolutions:
Symptoms: Reload fails with permission errorSolutions:
Symptoms: Old behavior persists after reloadSolutions:
Symptoms: New UI components or permissions not appearingSolutions: