code: public function send($message, string $endpointArn)
      {
          if ($this->debug) {
              $this->logger && $this->logger->notice(
                  "Message would have been sent to $endpointArn",
                  [
                      'Message' => $message,
                  ]
              );
  
              return;
          }
  
          if (!($message instanceof Message)) {
              $message = new Message($message);
          }
  
          $this->sns->publish(
              [
                  'TargetArn' => $endpointArn,
                  'Message' => $this->encodeMessage($message),
                  'MessageStructure' => 'json',
              ]
          );
      }
docs: Send a message to an endpoint.
  
  @param Message|string $message
  @param string         $endpointArn
  
  @throws MessageTooLongException