src/vs/server/node/remoteTerminalChannel.ts/RemoteTerminalChannel/call
class RemoteTerminalChannel:	async call(ctx: RemoteAgentConnectionContext, command: string, args?: any): Promise<any> {
		switch (command) {
			case '$restartPtyHost': return this._ptyService.restartPtyHost?.apply(this._ptyService, args);

			case '$createProcess': {
				const uriTransformer = createURITransformer(ctx.remoteAuthority);
				return this._createProcess(uriTransformer, <ICreateTerminalProcessArguments>args);
			}
			case '$attachToProcess': return this._ptyService.attachToProcess.apply(this._ptyService, args);
			case '$detachFromProcess': return this._ptyService.detachFromProcess.apply(this._ptyService, args);

			case '$listProcesses': return this._ptyService.listProcesses.apply(this._ptyService, args);
			case '$orphanQuestionReply': return this._ptyService.orphanQuestionReply.apply(this._ptyService, args);
			case '$acceptPtyHostResolvedVariables': return this._ptyService.acceptPtyHostResolvedVariables?.apply(this._ptyService, args);

			case '$start': return this._ptyService.start.apply(this._ptyService, args);
			case '$input': return this._ptyService.input.apply(this._ptyService, args);
			case '$acknowledgeDataEvent': return this._ptyService.acknowledgeDataEvent.apply(this._ptyService, args);
			case '$shutdown': return this._ptyService.shutdown.apply(this._ptyService, args);
			case '$resize': return this._ptyService.resize.apply(this._ptyService, args);
			case '$getInitialCwd': return this._ptyService.getInitialCwd.apply(this._ptyService, args);
			case '$getCwd': return this._ptyService.getCwd.apply(this._ptyService, args);

			case '$processBinary': return this._ptyService.processBinary.apply(this._ptyService, args);

			case '$sendCommandResult': return this._sendCommandResult(args[0], args[1], args[2]);
			case '$installAutoReply': return this._ptyService.installAutoReply.apply(this._ptyService, args);
			case '$uninstallAllAutoReplies': return this._ptyService.uninstallAllAutoReplies.apply(this._ptyService, args);
			case '$getDefaultSystemShell': return this._getDefaultSystemShell.apply(this, args);
			case '$getProfiles': return this._getProfiles.apply(this, args);
			case '$getEnvironment': return this._getEnvironment();
			case '$getWslPath': return this._getWslPath(args[0]);
			case '$getTerminalLayoutInfo': return this._ptyService.getTerminalLayoutInfo(<IGetTerminalLayoutInfoArgs>args);
			case '$setTerminalLayoutInfo': return this._ptyService.setTerminalLayoutInfo(<ISetTerminalLayoutInfoArgs>args);
			case '$serializeTerminalState': return this._ptyService.serializeTerminalState.apply(this._ptyService, args);
			case '$reviveTerminalProcesses': return this._ptyService.reviveTerminalProcesses.apply(this._ptyService, args);
			case '$getRevivedPtyNewId': return this._ptyService.getRevivedPtyNewId.apply(this._ptyService, args);
			case '$setUnicodeVersion': return this._ptyService.setUnicodeVersion.apply(this._ptyService, args);
			case '$reduceConnectionGraceTime': return this._reduceConnectionGraceTime();
			case '$updateIcon': return this._ptyService.updateIcon.apply(this._ptyService, args);
			case '$updateTitle': return this._ptyService.updateTitle.apply(this._ptyService, args);
			case '$updateProperty': return this._ptyService.updateProperty.apply(this._ptyService, args);
			case '$refreshProperty': return this._ptyService.refreshProperty.apply(this._ptyService, args);
			case '$requestDetachInstance': return this._ptyService.requestDetachInstance(args[0], args[1]);
			case '$acceptDetachedInstance': return this._ptyService.acceptDetachInstanceReply(args[0], args[1]);
			case '$freePortKillProcess': return this._ptyService.freePortKillProcess?.apply(this._ptyService, args);
		}

		throw new Error(`IPC Command ${command} not found`);
	}