Add LogPlayerReports and LogImpressions to Playable Locations service
PiperOrigin-RevId: 299724050
This commit is contained in:
parent
b6927fca80
commit
af7dff701f
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright 2019 Google LLC.
|
||||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
|
|
@ -11,7 +11,6 @@
|
|||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
|
|
@ -19,7 +18,9 @@ package google.maps.playablelocations.v3;
|
|||
|
||||
import "google/api/annotations.proto";
|
||||
import "google/api/field_behavior.proto";
|
||||
import "google/maps/playablelocations/v3/resources.proto";
|
||||
import "google/maps/playablelocations/v3/sample/resources.proto";
|
||||
import "google/maps/unity/clientinfo.proto";
|
||||
import "google/protobuf/duration.proto";
|
||||
import "google/api/client.proto";
|
||||
|
||||
|
|
@ -45,6 +46,29 @@ service PlayableLocations {
|
|||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
// Logs bad playable location reports submitted by players.
|
||||
//
|
||||
// Reports are not partially saved; either all reports are saved and this
|
||||
// request succeeds, or no reports are saved, and this request fails.
|
||||
rpc LogPlayerReports(LogPlayerReportsRequest) returns (LogPlayerReportsResponse) {
|
||||
option (google.api.http) = {
|
||||
post: "/v3:logPlayerReports"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
// Logs new events when playable locations are displayed, and when they are
|
||||
// interacted with.
|
||||
//
|
||||
// Impressions are not partially saved; either all impressions are saved and
|
||||
// this request succeeds, or no impressions are saved, and this request fails.
|
||||
rpc LogImpressions(LogImpressionsRequest) returns (LogImpressionsResponse) {
|
||||
option (google.api.http) = {
|
||||
post: "/v3:logImpressions"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
|
|
@ -98,3 +122,57 @@ message SamplePlayableLocationsResponse {
|
|||
// business might have closed permanently).
|
||||
google.protobuf.Duration ttl = 9;
|
||||
}
|
||||
|
||||
// A request for logging your player's bad location reports.
|
||||
message LogPlayerReportsRequest {
|
||||
// Required. Player reports. The maximum number of player reports that you can log at
|
||||
// once is 50.
|
||||
repeated PlayerReport player_reports = 1 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. A string that uniquely identifies the log player reports request. This
|
||||
// allows you to detect duplicate requests. We recommend that you use UUIDs
|
||||
// for this value. The value must not exceed 50 characters.
|
||||
//
|
||||
// You should reuse the `request_id` only when retrying a request in the case
|
||||
// of a failure. In that case, the request must be identical to the one that
|
||||
// failed.
|
||||
string request_id = 2 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. Information about the client device (for example, device model and
|
||||
// operating system).
|
||||
google.maps.unity.ClientInfo client_info = 3 [(google.api.field_behavior) = REQUIRED];
|
||||
}
|
||||
|
||||
// A response for the [LogPlayerReports][google.maps.playablelocations.v3.PlayableLocations.LogPlayerReports]
|
||||
// method.
|
||||
//
|
||||
// This method returns no data upon success.
|
||||
message LogPlayerReportsResponse {
|
||||
|
||||
}
|
||||
|
||||
// A request for logging impressions.
|
||||
message LogImpressionsRequest {
|
||||
// Required. Impression event details. The maximum number of impression reports that you
|
||||
// can log at once is 50.
|
||||
repeated Impression impressions = 1 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. A string that uniquely identifies the log impressions request. This allows
|
||||
// you to detect duplicate requests. We recommend that you use UUIDs for this
|
||||
// value. The value must not exceed 50 characters.
|
||||
//
|
||||
// You should reuse the `request_id` only when retrying a request in case of
|
||||
// failure. In this case, the request must be identical to the one that
|
||||
// failed.
|
||||
string request_id = 2 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. Information about the client device. For example, device model and
|
||||
// operating system.
|
||||
google.maps.unity.ClientInfo client_info = 3 [(google.api.field_behavior) = REQUIRED];
|
||||
}
|
||||
|
||||
// A response for the [LogImpressions][google.maps.playablelocations.v3.PlayableLocations.LogImpressions] method.
|
||||
// This method returns no data upon success.
|
||||
message LogImpressionsResponse {
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,5 +8,5 @@ apis:
|
|||
|
||||
backend:
|
||||
rules:
|
||||
- selector: google.maps.playablelocations.v3.PlayableLocations.SamplePlayableLocations
|
||||
- selector: 'google.maps.playablelocations.v3.PlayableLocations.*'
|
||||
deadline: 60.0
|
||||
|
|
|
|||
|
|
@ -0,0 +1,106 @@
|
|||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package google.maps.playablelocations.v3;
|
||||
|
||||
import "google/api/field_behavior.proto";
|
||||
import "google/protobuf/field_mask.proto";
|
||||
import "google/type/latlng.proto";
|
||||
|
||||
option csharp_namespace = "Google.Maps.PlayableLocations.V3";
|
||||
option go_package = "google.golang.org/genproto/googleapis/maps/playablelocations/v3;playablelocations";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "ResourcesProto";
|
||||
option java_package = "com.google.maps.playablelocations.v3";
|
||||
option objc_class_prefix = "GMPL";
|
||||
|
||||
// A report submitted by a player about a playable location that is considered
|
||||
// inappropriate for use in the game.
|
||||
message PlayerReport {
|
||||
// The reason why the playable location is considered bad.
|
||||
enum BadLocationReason {
|
||||
// Unspecified reason. Do not use.
|
||||
BAD_LOCATION_REASON_UNSPECIFIED = 0;
|
||||
|
||||
// The reason isn't one of the reasons in this enumeration.
|
||||
OTHER = 1;
|
||||
|
||||
// The playable location isn't accessible to pedestrians. For example, if
|
||||
// it's in the middle of a highway.
|
||||
NOT_PEDESTRIAN_ACCESSIBLE = 2;
|
||||
|
||||
// The playable location isn't open to the public. For example, a private
|
||||
// office building.
|
||||
NOT_OPEN_TO_PUBLIC = 4;
|
||||
|
||||
// The playable location is permanently closed. For example, when a business
|
||||
// has been shut down.
|
||||
PERMANENTLY_CLOSED = 5;
|
||||
|
||||
// The playable location is temporarily inaccessible. For example, when a
|
||||
// business has closed for renovations.
|
||||
TEMPORARILY_INACCESSIBLE = 6;
|
||||
}
|
||||
|
||||
// Required. The name of the playable location.
|
||||
string location_name = 1 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. One or more reasons why this playable location is considered bad.
|
||||
repeated BadLocationReason reasons = 2 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. A free-form description detailing why the playable location is
|
||||
// considered bad.
|
||||
string reason_details = 3 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Language code (in BCP-47 format) indicating the language of the freeform
|
||||
// description provided in `reason_details`. Examples are "en", "en-US" or
|
||||
// "ja-Latn". For more information, see
|
||||
// http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
|
||||
string language_code = 4;
|
||||
}
|
||||
|
||||
// Encapsulates impression event details.
|
||||
message Impression {
|
||||
// The type of impression event.
|
||||
enum ImpressionType {
|
||||
// Unspecified type. Do not use.
|
||||
IMPRESSION_TYPE_UNSPECIFIED = 0;
|
||||
|
||||
// The playable location was presented to a player.
|
||||
PRESENTED = 1;
|
||||
|
||||
// A player interacted with the playable location.
|
||||
INTERACTED = 2;
|
||||
}
|
||||
|
||||
// Required. The name of the playable location.
|
||||
string location_name = 1 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Required. The type of impression event.
|
||||
ImpressionType impression_type = 2 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// An arbitrary, developer-defined type identifier for each type of game
|
||||
// object used in your game.
|
||||
//
|
||||
// Since players interact with differ types of game objects in different ways,
|
||||
// this field allows you to segregate impression data by type for analysis.
|
||||
//
|
||||
// You should assign a unique `game_object_type` ID to represent a distinct
|
||||
// type of game object in your game.
|
||||
//
|
||||
// For example, 1=monster location, 2=powerup location.
|
||||
int32 game_object_type = 4;
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright 2019 Google LLC.
|
||||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
|
|
@ -11,7 +11,6 @@
|
|||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,87 @@
|
|||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package google.maps.unity;
|
||||
|
||||
option csharp_namespace = "Google.Maps.Unity";
|
||||
option go_package = "google.golang.org/genproto/googleapis/maps/unity;unity";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "ClientInfoProto";
|
||||
option java_package = "com.google.maps.unity";
|
||||
option objc_class_prefix = "GMU";
|
||||
|
||||
// Client information.
|
||||
message ClientInfo {
|
||||
// Platform enum.
|
||||
enum Platform {
|
||||
// Unspecified or unknown OS.
|
||||
PLATFORM_UNSPECIFIED = 0;
|
||||
|
||||
// Development environment.
|
||||
EDITOR = 1;
|
||||
|
||||
// macOS.
|
||||
MAC_OS = 2;
|
||||
|
||||
// Windows.
|
||||
WINDOWS = 3;
|
||||
|
||||
// Linux
|
||||
LINUX = 4;
|
||||
|
||||
// Android
|
||||
ANDROID = 5;
|
||||
|
||||
// iOS
|
||||
IOS = 6;
|
||||
|
||||
// WebGL.
|
||||
WEB_GL = 7;
|
||||
}
|
||||
|
||||
// Application ID, such as the package name on Android and the bundle
|
||||
// identifier on iOS platforms.
|
||||
string application_id = 1;
|
||||
|
||||
// Application version number, such as "1.2.3". The exact format is
|
||||
// application-dependent.
|
||||
string application_version = 2;
|
||||
|
||||
// Platform where the application is running.
|
||||
Platform platform = 3;
|
||||
|
||||
// Operating system name and version as reported by the OS. For example,
|
||||
// "Mac OS X 10.10.4". The exact format is platform-dependent.
|
||||
string operating_system = 4;
|
||||
|
||||
// API client name and version. For example, the SDK calling the API. The
|
||||
// exact format is up to the client.
|
||||
string api_client = 5;
|
||||
|
||||
// Device model as reported by the device. The exact format is
|
||||
// platform-dependent.
|
||||
string device_model = 6;
|
||||
|
||||
// Language code (in BCP-47 format) indicating the UI language of the client.
|
||||
// Examples are "en", "en-US" or "ja-Latn". For more information, see
|
||||
// http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
|
||||
string language_code = 7;
|
||||
|
||||
// Build number/version of the operating system. e.g., the contents of
|
||||
// android.os.Build.ID in Android, or the contents of sysctl "kern.osversion"
|
||||
// in iOS.
|
||||
string operating_system_build = 8;
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright 2019 Google LLC.
|
||||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
|
|
@ -11,7 +11,6 @@
|
|||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue