diff --git a/bynder.info.yml b/bynder.info.yml
index 563c130..260355f 100644
--- a/bynder.info.yml
+++ b/bynder.info.yml
@@ -2,10 +2,11 @@ name: Bynder
 description: 'Bynder digital asset management system integration.'
 type: module
 package: Media
-core: 8.x
+core_version_requirement: ^8 || ^9
 configure: bynder.configuration_form
 
 dependencies:
   - drupal:media (>= 8.4.0)
   - ctools:ctools
   - entity_browser:entity_browser (>= 8.x-2.x)
+  - jquery_ui_tooltip:jquery_ui_tooltip
diff --git a/bynder.install b/bynder.install
index dabfd34..8499a6c 100644
--- a/bynder.install
+++ b/bynder.install
@@ -9,6 +9,7 @@ use Drupal\bynder\Plugin\Field\FieldType\BynderMetadataItem;
 use Drupal\Core\Utility\UpdateException;
 use Drupal\field\Entity\FieldStorageConfig;
 use Drupal\system\Entity\Action;
+use Drupal\Core\File\FileSystemInterface;
 
 /**
  * Implements hook_requirements().
@@ -45,8 +46,8 @@ function bynder_requirements($phase) {
 function bynder_install() {
   $source = drupal_get_path('module', 'bynder') . '/images/icons';
   $destination = \Drupal::config('media.settings')->get('icon_base_uri');
-  file_prepare_directory($destination, FILE_CREATE_DIRECTORY | FILE_MODIFY_PERMISSIONS);
-  $files = file_scan_directory($source, '/.*\.(svg|png|jpg|jpeg|gif)$/');
+  \Drupal::service('file_system')->prepareDirectory($destination, FileSystemInterface::CREATE_DIRECTORY | FileSystemInterface::MODIFY_PERMISSIONS);
+  $files = \Drupal::service('file_system')->scanDirectory($source, '/.*\.(svg|png|jpg|jpeg|gif)$/');
   foreach ($files as $file) {
     // When reinstalling this module we don't want to copy the icons when they
     // already exist. The icons could be replaced (by a contrib module or
@@ -55,7 +56,7 @@ function bynder_install() {
     // referenced somewhere else. Since showing an error that it was not
     // possible to copy the files is also confusing, we silently do nothing.
     if (!file_exists($destination . DIRECTORY_SEPARATOR . $file->filename)) {
-      file_unmanaged_copy($file->uri, $destination, FILE_EXISTS_ERROR);
+      \Drupal::service('file_system')->copy($file->uri, $destination, FileSystemInterface::EXISTS_ERROR);
     }
   }
 }
@@ -71,8 +72,9 @@ function bynder_update_8001() {
  * Remove unecessary database table.
  */
 function bynder_update_8002() {
-  if (db_table_exists('bynder_metaproperty_information')) {
-    db_drop_table('bynder_metaproperty_information');
+  $database = \Drupal::database();
+  if ($database->tableExists('bynder_metaproperty_information')) {
+    $database->dropTable('bynder_metaproperty_information');
   }
 }
 
diff --git a/bynder.libraries.yml b/bynder.libraries.yml
index dda4ff4..fb5d925 100644
--- a/bynder.libraries.yml
+++ b/bynder.libraries.yml
@@ -52,4 +52,4 @@ formatter:
   dependencies:
     - core/jquery
     - core/drupal
-    - core/jquery.ui.tooltip
+    - jquery_ui_tooltip/tooltip
diff --git a/modules/bynder_select2/bynder_select2.info.yml b/modules/bynder_select2/bynder_select2.info.yml
index 89c2a86..8fb3e3d 100755
--- a/modules/bynder_select2/bynder_select2.info.yml
+++ b/modules/bynder_select2/bynder_select2.info.yml
@@ -2,7 +2,7 @@ name: Bynder Select2 Integration
 type: module
 description: Adds integration with the <a herf="http://ivaynberg.github.io/select2" target="_blank">Select2</a> Javascript plugin.
 package: User interface
-core: 8.x
+core_version_requirement: ^8 || ^9
 
 dependencies:
   - bynder:bynder
diff --git a/modules/bynder_usage/bynder_usage.info.yml b/modules/bynder_usage/bynder_usage.info.yml
index f7dd1fb..97e328a 100644
--- a/modules/bynder_usage/bynder_usage.info.yml
+++ b/modules/bynder_usage/bynder_usage.info.yml
@@ -2,7 +2,7 @@ name: Bynder Usage
 description: 'Reports usage tracking of media items back to the Bynder API'
 type: module
 package: Media
-core: 8.x
+core_version_requirement: ^8 || ^9
 
 dependencies:
   - bynder:bynder
diff --git a/modules/demo/bynder_demo.info.yml b/modules/demo/bynder_demo.info.yml
index d987016..e24fb61 100644
--- a/modules/demo/bynder_demo.info.yml
+++ b/modules/demo/bynder_demo.info.yml
@@ -2,7 +2,7 @@ name: Bynder Demo
 description: 'Demonstration of the Bynder integration.'
 type: module
 package: Media
-core: 8.x
+core_version_requirement: ^8 || ^9
 
 dependencies:
   - bynder:bynder
diff --git a/modules/lightning/bynder_lightning.info.yml b/modules/lightning/bynder_lightning.info.yml
index fbfd47d..6ec7c72 100644
--- a/modules/lightning/bynder_lightning.info.yml
+++ b/modules/lightning/bynder_lightning.info.yml
@@ -2,7 +2,7 @@ name: Bynder Lightning
 description: 'Bynder integration for the Lightning distribution.'
 type: module
 package: Lightning
-core: 8.x
+core_version_requirement: ^8 || ^9
 
 dependencies:
   - bynder:bynder
diff --git a/src/Exception/BynderException.php b/src/Exception/BynderException.php
index ec57392..68ef529 100644
--- a/src/Exception/BynderException.php
+++ b/src/Exception/BynderException.php
@@ -3,6 +3,7 @@
 namespace Drupal\bynder\Exception;
 
 use Drupal\Core\StringTranslation\StringTranslationTrait;
+use Drupal\Core\Messenger\MessengerInterface;
 
 /**
  * Base exception class for Bynder.
@@ -19,13 +20,6 @@ abstract class BynderException extends \Exception {
    */
   protected $adminPermission = 'administer bynder configuration';
 
-  /**
-   * Message level to be used when displaying the message to the user.
-   *
-   * @var string
-   */
-  protected $messageLevel = 'error';
-
   /**
    * User-facing for admin users.
    *
@@ -47,6 +41,13 @@ abstract class BynderException extends \Exception {
    */
   protected $logMessageArgs;
 
+  /**
+   * Include the messenger service.
+   *
+   * @var \Drupal\Core\Messenger\MessengerInterface
+   */
+  protected $messenger;
+
   /**
    * Constructs BundleNotExistException.
    */
@@ -54,11 +55,13 @@ abstract class BynderException extends \Exception {
     $message,
     $admin_message = NULL,
     $log_message = NULL,
-    $log_message_args = []
+    $log_message_args = [],
+    MessengerInterface $messenger
   ) {
     $this->adminMessage = $admin_message ?: $message;
     $this->logMessage = $log_message ?: $this->adminMessage;
     $this->logMessageArgs = $log_message_args;
+    $this->messenger = $messenger;
     parent::__construct($message);
   }
 
@@ -67,10 +70,10 @@ abstract class BynderException extends \Exception {
    */
   public function displayMessage() {
     if (\Drupal::currentUser()->hasPermission($this->adminPermission)) {
-      drupal_set_message($this->adminMessage, $this->messageLevel);
+      $this->messenger->addError($this->adminMessage);
     }
     else {
-      drupal_set_message($this->getMessage(), $this->messageLevel);
+      $this->messenger->addError($this->getMessage());
     }
   }
 
diff --git a/src/Plugin/EntityBrowser/Widget/BynderUpload.php b/src/Plugin/EntityBrowser/Widget/BynderUpload.php
index cefa9e1..e7a1454 100644
--- a/src/Plugin/EntityBrowser/Widget/BynderUpload.php
+++ b/src/Plugin/EntityBrowser/Widget/BynderUpload.php
@@ -20,6 +20,8 @@ use Drupal\Core\Language\LanguageManagerInterface;
 use Drupal\Core\Link;
 use Drupal\Core\Logger\LoggerChannelFactoryInterface;
 use Drupal\Core\Url;
+use Drupal\Core\File\FileSystemInterface;
+use Drupal\Core\Messenger\MessengerInterface;
 use Drupal\entity_browser\WidgetValidationManager;
 use Drupal\media\Entity\Media;
 use Drupal\media\MediaInterface;
@@ -54,6 +56,20 @@ class BynderUpload extends BynderWidgetBase {
    */
   protected $session;
 
+  /**
+   * The file system service.
+   *
+   * @var \Drupal\Core\File\FileSystemInterface
+   */
+  protected $fileSystem;
+
+  /**
+   * Include the messenger service.
+   *
+   * @var \Drupal\Core\Messenger\MessengerInterface
+   */
+  protected $messenger;
+
   /**
    * Upload constructor.
    *
@@ -81,10 +97,16 @@ class BynderUpload extends BynderWidgetBase {
    *   The language manager.
    * @param \Symfony\Component\HttpFoundation\RequestStack $request_stack
    *   The request stack.
+   * @param \Drupal\Core\File\FileSystemInterface $file_system
+   *   The file system service.
+   * @param \Drupal\Core\File\FileSystemInterface $messanger
+   *   The messanger service.
    */
-  public function __construct(array $configuration, $plugin_id, $plugin_definition, EventDispatcherInterface $event_dispatcher, EntityTypeManagerInterface $entity_type_manager, WidgetValidationManager $validation_manager, BynderApiInterface $bynder_api, ConfigFactoryInterface $config_factory, LoggerChannelFactoryInterface $logger_factory, SessionInterface $session, LanguageManagerInterface $language_manager, RequestStack $request_stack) {
+  public function __construct(array $configuration, $plugin_id, $plugin_definition, EventDispatcherInterface $event_dispatcher, EntityTypeManagerInterface $entity_type_manager, WidgetValidationManager $validation_manager, BynderApiInterface $bynder_api, ConfigFactoryInterface $config_factory, LoggerChannelFactoryInterface $logger_factory, SessionInterface $session, LanguageManagerInterface $language_manager, RequestStack $request_stack, FileSystemInterface $file_system, MessengerInterface $messenger) {
     parent::__construct($configuration, $plugin_id, $plugin_definition, $event_dispatcher, $entity_type_manager, $validation_manager, $bynder_api, $logger_factory, $language_manager, $request_stack, $config_factory);
     $this->session = $session;
+    $this->fileSystem = $file_system;
+    $this->messenger = $messenger;
   }
 
   /**
@@ -103,7 +125,9 @@ class BynderUpload extends BynderWidgetBase {
       $container->get('logger.factory'),
       $container->get('session'),
       $container->get('language_manager'),
-      $container->get('request_stack')
+      $container->get('request_stack'),
+      $container->get('file_system'),
+      $container->get('messenger')
     );
   }
 
@@ -338,7 +362,7 @@ class BynderUpload extends BynderWidgetBase {
       $result = \Drupal::service('bynder_api')->uploadFileAsync($data);
       $context['results']['accessRequestId'] = $result['accessRequestId'];
       $context['results'][$file['path']] = $result['mediaid'];
-      file_unmanaged_delete($file['path']);
+      $this->fileSystem->delete($file['path']);
       $context['message'] = t('Uploaded @file to Bynder.', ['@file' => $file['filename']]);
     }
     catch (\Exception $e) {
@@ -378,7 +402,7 @@ class BynderUpload extends BynderWidgetBase {
         $context['message'] = t('Mapped @file locally.', ['@file' => $file['filename']]);
       }
       else {
-        drupal_set_message(t("Your file was uploaded to Bynder but needs to be approved before you can use it. Please go to your Bynder waiting room and review the uploaded assets."), 'warning');
+        $this->messenger->addWarning(t("Your file was uploaded to Bynder but needs to be approved before you can use it. Please go to your Bynder waiting room and review the uploaded assets."));
       }
       $context['finished'] = 1;
     }
@@ -396,7 +420,7 @@ class BynderUpload extends BynderWidgetBase {
       if ($context['sandbox']['fails'] >= static::FAIL_LIMIT) {
         watchdog_exception('bynder', $e);
         (new UploadFailedException(t("There was an unexpected error after uploading the file to Bynder.")))->displayMessage();
-        drupal_set_message(t("There was an unexpected error after uploading the file to Bynder. Please contact your site administrator for more info."), 'warning');
+        $this->messenger->addWarning(t("There was an unexpected error after uploading the file to Bynder. Please contact your site administrator for more info."));
       }
     }
   }
diff --git a/src/Plugin/media/Source/Bynder.php b/src/Plugin/media/Source/Bynder.php
index 4e1d084..90c16f9 100644
--- a/src/Plugin/media/Source/Bynder.php
+++ b/src/Plugin/media/Source/Bynder.php
@@ -16,6 +16,7 @@ use Drupal\Core\Form\FormStateInterface;
 use Drupal\Core\Logger\LoggerChannelFactoryInterface;
 use Drupal\Core\Routing\UrlGeneratorInterface;
 use Drupal\Core\Session\AccountProxyInterface;
+use Drupal\Core\Messenger\MessengerInterface;
 use Drupal\media\MediaInterface;
 use Drupal\media\MediaSourceBase;
 use Drupal\media\MediaTypeInterface;
@@ -100,6 +101,13 @@ class Bynder extends MediaSourceBase {
    */
   protected static $timoutDetected = FALSE;
 
+  /**
+   * The messenger service.
+   *
+   * @var \Drupal\Core\Messenger\MessengerInterface
+   */
+  protected $messenger;
+
   /**
    * Constructs a new class instance.
    *
@@ -129,8 +137,10 @@ class Bynder extends MediaSourceBase {
    *   The cache service.
    * @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
    *   The module handler.
+   * @param \Drupal\Core\Messenger\MessengerInterface $messenger
+   *   The messenger service.
    */
-  public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entity_type_manager, EntityFieldManagerInterface $entity_field_manager, FieldTypePluginManagerInterface $field_type_manager, ConfigFactoryInterface $config_factory, BynderApiInterface $bynder_api_service, AccountProxyInterface $account_proxy, UrlGeneratorInterface $url_generator, LoggerChannelFactoryInterface $logger, CacheBackendInterface $cache, TimeInterface $time, ModuleHandlerInterface $module_handler) {
+  public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entity_type_manager, EntityFieldManagerInterface $entity_field_manager, FieldTypePluginManagerInterface $field_type_manager, ConfigFactoryInterface $config_factory, BynderApiInterface $bynder_api_service, AccountProxyInterface $account_proxy, UrlGeneratorInterface $url_generator, LoggerChannelFactoryInterface $logger, CacheBackendInterface $cache, TimeInterface $time, ModuleHandlerInterface $module_handler, MessengerInterface $messenger) {
     parent::__construct($configuration, $plugin_id, $plugin_definition, $entity_type_manager, $entity_field_manager, $field_type_manager, $config_factory);
 
     $this->bynderApi = $bynder_api_service;
@@ -140,6 +150,7 @@ class Bynder extends MediaSourceBase {
     $this->cache = $cache;
     $this->time = $time;
     $this->moduleHandler = $module_handler;
+    $this->messenger = $messenger;
   }
 
   /**
@@ -160,7 +171,8 @@ class Bynder extends MediaSourceBase {
       $container->get('logger.factory'),
       $container->get('cache.data'),
       $container->get('datetime.time'),
-      $container->get('module_handler')
+      $container->get('module_handler'),
+      $container->get('messenger')
     );
   }
 
@@ -383,12 +395,12 @@ class Bynder extends MediaSourceBase {
     }
     catch (\Exception $exception) {
       if ($this->accountProxy->hasPermission('administer bynder configuration')) {
-        drupal_set_message($this->t('Connecting with Bynder failed. Check if the configuration is set properly <a href=":url">here</a>.', [
+        $this->messenger->addError($this->t('Connecting with Bynder failed. Check if the configuration is set properly <a href=":url">here</a>.', [
           ':url' => $this->urlGenerator->generateFromRoute('bynder.configuration_form'),
-        ]), 'error');
+        ]));
       }
       else {
-        drupal_set_message($this->t('Something went wrong with the Bynder connection. Please contact the site administrator.'), 'error');
+        $this->messenger->addError($this->t('Something went wrong with the Bynder connection. Please contact the site administrator.'));
       }
     }
 
diff --git a/tests/modules/bynder_test_module/bynder_test_module.info.yml b/tests/modules/bynder_test_module/bynder_test_module.info.yml
index af2c745..f524b95 100644
--- a/tests/modules/bynder_test_module/bynder_test_module.info.yml
+++ b/tests/modules/bynder_test_module/bynder_test_module.info.yml
@@ -2,7 +2,7 @@ name: Bynder Test Module
 description: 'Bynder test module.'
 type: module
 package: Media
-core: 8.x
+core_version_requirement: ^8 || ^9
 
 dependencies:
   - bynder:bynder
diff --git a/tests/modules/entity_browser_bynder_test/entity_browser_bynder_test.info.yml b/tests/modules/entity_browser_bynder_test/entity_browser_bynder_test.info.yml
index 95b561f..a60ac42 100644
--- a/tests/modules/entity_browser_bynder_test/entity_browser_bynder_test.info.yml
+++ b/tests/modules/entity_browser_bynder_test/entity_browser_bynder_test.info.yml
@@ -1,7 +1,7 @@
 name: 'Entity browser bynder test'
 type: module
 description: 'Support module for the Bynder module tests.'
-core: 8.x
+core_version_requirement: ^8 || ^9
 package: Testing
 version: VERSION
 dependencies:
diff --git a/tests/src/Unit/BynderApiUnitTest.php b/tests/src/Unit/BynderApiUnitTest.php
index 2cbe3db..0a9277d 100644
--- a/tests/src/Unit/BynderApiUnitTest.php
+++ b/tests/src/Unit/BynderApiUnitTest.php
@@ -33,7 +33,7 @@ class BynderApiUnitTest extends UnitTestCase {
     $cache = $this->prophesize(CacheBackendInterface::class);
     $time = $this->prophesize(TimeInterface::class);
 
-    $api = $this->getMock(BynderApi::class, ['__call'], [$config->reveal(), $logger->reveal(), $session->reveal(), $state->reveal(), $cache->reveal(), $time->reveal()]);
+    $api = $this->createMock(BynderApi::class, ['__call'], [$config->reveal(), $logger->reveal(), $session->reveal(), $state->reveal(), $cache->reveal(), $time->reveal()]);
     $this->assertEquals($expected, $api->hasAccessToken());
   }
 
