You are here

public function ContactMessageResource::availableMethods in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/contact/src/Plugin/rest/resource/ContactMessageResource.php \Drupal\contact\Plugin\rest\resource\ContactMessageResource::availableMethods()

Returns the available HTTP request methods on this plugin.

Return value

array The list of supported methods. Example: array('GET', 'POST', 'PATCH').

Overrides EntityResource::availableMethods

File

core/modules/contact/src/Plugin/rest/resource/ContactMessageResource.php, line 21

Class

ContactMessageResource
Customizes the entity REST Resource plugin for Contact's Message entities.

Namespace

Drupal\contact\Plugin\rest\resource

Code

public function availableMethods() {
  return [
    'POST',
  ];
}