What Is the Default Network Boundary for VoiceStudio?

VoiceStudio’s default network boundary is the FastAPI HTTP server listening on port 3900 (0.0.0.0), which serves as the primary interface between the frontend UI and backend processing engine.

VoiceStudio, an open-source audio processing application maintained by debpalash/VoiceStudio, implements a strict architectural separation between its user interface and core engine through this defined default network boundary. This design ensures modular communication while maintaining full backward compatibility for client integrations. Understanding this boundary is essential for developers deploying the application or building integrations against its HTTP API.

Understanding the Primary Network Boundary

The core of VoiceStudio’s architecture relies on a FastAPI backend that exposes its functionality through a public HTTP interface. This interface represents the primary network boundary for all client-side operations.

FastAPI Server on Port 3900

According to the design documentation in docs/superpowers/specs/2026-05-30-network-sharing-design.md, the primary backend port is hardcoded as the literal integer 3900. The file backend/main.py initializes the FastAPI application and binds it to 0.0.0.0:3900, making the API accessible across all network interfaces.

All standard client requests—whether fetching system information or triggering audio processing—traverse this boundary via HTTP requests to port 3900. Key endpoints include:

  • GET /system/info – Returns version and network share status
  • POST /system/network/enable – Activates the secondary collaborative sharing feature

Secondary Network Share Boundary

VoiceStudio implements an optional network-share feature that creates an additional listener for collaborative workflows. This secondary boundary only activates when explicitly enabled with a PIN configuration.

Dynamic Port Allocation Starting at 3901

As implemented in backend/services/network_share.py, the network share feature attempts to bind to the next available port starting from 3901. If port 3901 is occupied, the service iterates upward until it finds a free port. Until a PIN is set and sharing is enabled, the middleware simply passes traffic through the primary boundary on port 3900, preserving full backward compatibility.

The design document specifies that this secondary listener remains dormant by default, ensuring the default network boundary for VoiceStudio remains solely the FastAPI interface on port 3900.

Interacting with the Network Boundary

Developers can interact with VoiceStudio’s default network boundary using standard HTTP clients. The following Python example demonstrates fetching system information and enabling the secondary network share:

import httpx

# Default network boundary – FastAPI server on port 3900

BASE_URL = "http://127.0.0.1:3900"

# Example: fetch system information

resp = httpx.get(f"{BASE_URL}/system/info")
print(resp.json())

# → { "version": "...", "network_share": { "enabled": false, ... } }

# Example: enable network sharing (creates a secondary listener on 3901)

resp = httpx.post(
    f"{BASE_URL}/system/network/enable",
    json={"base_port": 3900}          # optional, defaults to 3900

)
share_state = resp.json()
print(f"Share enabled on port {share_state['share_port']} with PIN {share_state['pin']}")

In this implementation, the base_port parameter in the enable request defaults to 3900, maintaining consistency with the hardcoded primary port defined in the specification.

Summary

  • Port 3900 serves as the default network boundary for VoiceStudio, hosting the primary FastAPI HTTP interface defined in backend/main.py.
  • The secondary network-share feature creates an additional listener starting at port 3901, implemented in backend/services/network_share.py, but only activates when explicitly enabled.
  • Design specifications in docs/superpowers/specs/2026-05-30-network-sharing-design.md document the hardcoded primary port and dynamic secondary allocation logic.
  • All client requests traverse the port 3900 boundary by default, with the secondary port providing optional collaborative functionality.

Frequently Asked Questions

What port does VoiceStudio use by default?

VoiceStudio uses port 3900 as its default network boundary. The FastAPI backend binds to 0.0.0.0:3900 on startup, serving as the exclusive entry point for API requests until network sharing is manually enabled.

How do I enable network sharing in VoiceStudio?

Send a POST request to the /system/network/enable endpoint on the default port 3900. The request optionally accepts a base_port parameter (defaulting to 3900) and returns a JSON response containing the allocated share port and authentication PIN. The implementation in backend/services/network_share.py handles the dynamic port assignment starting from 3901.

Can I change the default port from 3900?

According to the source code analysis of docs/superpowers/specs/2026-05-30-network-sharing-design.md, the primary backend port is hardcoded as the literal value 3900 without configuration options in the current implementation. While the network share feature dynamically selects ports above 3900, the primary boundary remains fixed at 3900 to ensure consistent client behavior.

Is the network share port always 3901?

No, 3901 is the starting port, not a fixed assignment. The backend/services/network_share.py implementation scans for the next available free port beginning at 3901. If 3901 is occupied, it automatically binds to 3902 or the subsequent available port, returning the actual allocated port in the API response.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →