website/errors/interface.extendsInternalInterface.md
<?php declare(strict_types = 1);
namespace Vendor {
/** @internal */
interface InternalServiceInterface {}
}
namespace App {
interface MyServiceInterface extends \Vendor\InternalServiceInterface {}
}
The interface extends another interface that is marked as @internal. Internal interfaces are not part of the package's public API and may change or be removed without notice in future versions. Extending an internal interface couples your code to implementation details that may break when the dependency is updated.
Extend a non-internal interface instead, or define the required methods directly:
-interface MyServiceInterface extends \Vendor\InternalServiceInterface {}
+interface MyServiceInterface
+{
+ public function execute(): void;
+}
If the package provides a public interface for the same purpose, extend that instead:
-interface MyServiceInterface extends \Vendor\InternalServiceInterface {}
+interface MyServiceInterface extends \Vendor\PublicServiceInterface {}
If no public alternative exists, consider reaching out to the package maintainers to request a public API for your use case.