You are here

interface ClientServiceInterface in Sparkpost email 8.2

Same name and namespace in other branches
  1. 8 src/ClientServiceInterface.php \Drupal\sparkpost\ClientServiceInterface

Interface for the client service.

@package Drupal\sparkpost

Hierarchy

Expanded class hierarchy of ClientServiceInterface

All classes that implement ClientServiceInterface

1 file declares its use of ClientServiceInterface
QueuedMessageWrapper.php in modules/sparkpost_requeue/src/QueuedMessageWrapper.php

File

src/ClientServiceInterface.php, line 10

Namespace

Drupal\sparkpost
View source
interface ClientServiceInterface {

  /**
   * Gets the client.
   *
   * @return \SparkPost\SparkPost
   *   The client.
   */
  public function getClient();

  /**
   * Sends the message.
   *
   * @param array $message
   *   The sparkpost message.
   *
   * @return array
   *   The body of the response.
   */
  public function sendMessage(array $message);

  /**
   * Sends the request.
   *
   * @param string $endpoint
   *   The endpoint to use.
   * @param array $data
   *   The data to send.
   * @param string $method
   *   The HTTP method to use.
   *
   * @return array
   *   The body of the response.
   */
  public function sendRequest($endpoint, array $data, $method = 'GET');

}

Members

Namesort descending Modifiers Type Description Overrides
ClientServiceInterface::getClient public function Gets the client. 1
ClientServiceInterface::sendMessage public function Sends the message. 1
ClientServiceInterface::sendRequest public function Sends the request. 1