1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18namespace Google\Service\WebRisk\Resource;
19
20use Google\Service\WebRisk\GoogleCloudWebriskV1Submission;
21
22/**
23 * The "submissions" collection of methods.
24 * Typical usage is:
25 *  <code>
26 *   $webriskService = new Google\Service\WebRisk(...);
27 *   $submissions = $webriskService->submissions;
28 *  </code>
29 */
30class ProjectsSubmissions extends \Google\Service\Resource
31{
32  /**
33   * Creates a Submission of a URI suspected of containing phishing content to be
34   * reviewed. If the result verifies the existence of malicious phishing content,
35   * the site will be added to the [Google's Social Engineering
36   * lists](https://support.google.com/webmasters/answer/6350487/) in order to
37   * protect users that could get exposed to this threat in the future. Only
38   * allowlisted projects can use this method during Early Access. Please reach
39   * out to Sales or your customer engineer to obtain access. (submissions.create)
40   *
41   * @param string $parent Required. The name of the project that is making the
42   * submission. This string is in the format "projects/{project_number}".
43   * @param GoogleCloudWebriskV1Submission $postBody
44   * @param array $optParams Optional parameters.
45   * @return GoogleCloudWebriskV1Submission
46   */
47  public function create($parent, GoogleCloudWebriskV1Submission $postBody, $optParams = [])
48  {
49    $params = ['parent' => $parent, 'postBody' => $postBody];
50    $params = array_merge($params, $optParams);
51    return $this->call('create', [$params], GoogleCloudWebriskV1Submission::class);
52  }
53}
54
55// Adding a class alias for backwards compatibility with the previous class name.
56class_alias(ProjectsSubmissions::class, 'Google_Service_WebRisk_Resource_ProjectsSubmissions');
57