From 24aaa3e376a170bf60c9ccba2d255da3428d926d Mon Sep 17 00:00:00 2001 From: rahulpa Date: Thu, 16 Aug 2018 09:11:26 -0700 Subject: [PATCH] Add proto for Ads Service. --- pb/demo.proto | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/pb/demo.proto b/pb/demo.proto index 0862730..d586b18 100644 --- a/pb/demo.proto +++ b/pb/demo.proto @@ -217,3 +217,27 @@ message PlaceOrderRequest { message PlaceOrderResponse { OrderResult order = 1; } + +// ------------Ads service------------------ + +service AdsService { + rpc GetAds(AdsRequest) returns (AdsResponse) {} +} + +message AdsRequest { + // List of important key words from the current page describing the context. + repeated string context_keys = 1; +} + +message AdsResponse { + repeated Ads ads = 1; +} + +message Ads { + // url to redirect to when an ad is clicked. + string redirect_url = 1; + + // Optional text to display. + // Should not be more than 100 characters. + string text = 2; +}