import { Controller, Get, Param } from '@nestjs/common';
import { SandboxService } from './sandbox.service';

@Controller('sandbox')
export class SandboxShareController {
  constructor(private sandboxService: SandboxService) {}

  @Get('shared/:token')
  async viewShared(@Param('token') token: string) {
    return this.sandboxService.getSessionByShareToken(token);
  }
}
