Files
coolify/app/Mcp/Tools/GetDatabaseImport.php
T
6b07f03107 feat(terminal): interactive console mode for containers (docker attach) (#11538)
Co-authored-by: peaklabs-dev <122374094+peaklabs-dev@users.noreply.github.com>
Co-authored-by: Andras Bacsai <5845193+andrasbacsai@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: rosslh <ross@rosshill.ca>
2026-10-14 14:32:02 +02:00

33 lines
1.2 KiB
PHP

<?php
namespace App\Mcp\Tools;
use Laravel\Mcp\Server\Tools\Annotations\IsReadOnly;
#[IsReadOnly]
class GetDatabaseImport extends RestActionTool
{
protected string $name = 'get_database_import';
protected string $description = 'Get the status of a backup import into a standalone database or a service database of the authenticated team. Requires read ability; the import output is only shown with read:sensitive. Same validation and permissions as the REST API.';
protected function actions(): array
{
return [
'get' => ['method' => 'GET', 'paths' => [
'database' => 'databases/{uuid}/imports/{activity_id}',
'service_database' => 'services/{uuid}/databases/{database_uuid}/imports/{activity_id}',
], 'ability' => 'read', 'description' => 'import status'],
];
}
protected function pathParams(): array
{
return [
'uuid' => 'Database UUID (resource=database) or service UUID (resource=service_database).',
'database_uuid' => 'Service database UUID (resource=service_database).',
'activity_id' => 'Import ID returned by the import action.',
];
}
}