mirror of
				https://github.com/pelican-dev/panel.git
				synced 2025-11-01 00:46:52 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			28 lines
		
	
	
		
			570 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			28 lines
		
	
	
		
			570 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
| <?php
 | |
| 
 | |
| namespace App\Http\Requests\Api\Client\Servers;
 | |
| 
 | |
| use App\Models\Permission;
 | |
| use App\Http\Requests\Api\Client\ClientApiRequest;
 | |
| 
 | |
| class SendCommandRequest extends ClientApiRequest
 | |
| {
 | |
|     /**
 | |
|      * Determine if the API user has permission to perform this action.
 | |
|      */
 | |
|     public function permission(): string
 | |
|     {
 | |
|         return Permission::ACTION_CONTROL_CONSOLE;
 | |
|     }
 | |
| 
 | |
|     /**
 | |
|      * Rules to validate this request against.
 | |
|      */
 | |
|     public function rules(): array
 | |
|     {
 | |
|         return [
 | |
|             'command' => 'required|string|min:1',
 | |
|         ];
 | |
|     }
 | |
| }
 | 
