You are here

public static function EntityResource::getInternalPingUrl in CMS Content Sync 2.0.x

Same name and namespace in other branches
  1. 8 src/Plugin/rest/resource/EntityResource.php \Drupal\cms_content_sync\Plugin\rest\resource\EntityResource::getInternalPingUrl()
  2. 2.1.x src/Plugin/rest/resource/EntityResource.php \Drupal\cms_content_sync\Plugin\rest\resource\EntityResource::getInternalPingUrl()

Parameters

string $method:

Return value

string a URL the Sync Core can use to ping this site and check if all methods work (so inbound traffic is allowed from the Sync Core)

File

src/Plugin/rest/resource/EntityResource.php, line 166

Class

EntityResource
Provides entity interfaces for Content Sync, allowing Sync Core to request and manipulate entities.

Namespace

Drupal\cms_content_sync\Plugin\rest\resource

Code

public static function getInternalPingUrl($method) {
  return DrupalApplication::get()
    ->getRestUrl(self::PING_PARAMETER, self::PING_PARAMETER, self::PING_PARAMETER, self::PING_PARAMETER, 'POST' === $method ? null : self::PING_PARAMETER);
}