resources.proto 46 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300
  1. // Copyright 2022 Google LLC
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. syntax = "proto3";
  15. package google.analytics.admin.v1alpha;
  16. import "google/api/field_behavior.proto";
  17. import "google/api/resource.proto";
  18. import "google/protobuf/timestamp.proto";
  19. import "google/protobuf/wrappers.proto";
  20. option go_package = "google.golang.org/genproto/googleapis/analytics/admin/v1alpha;admin";
  21. option java_multiple_files = true;
  22. option java_outer_classname = "ResourcesProto";
  23. option java_package = "com.google.analytics.admin.v1alpha";
  24. // The category selected for this property, used for industry benchmarking.
  25. enum IndustryCategory {
  26. // Industry category unspecified
  27. INDUSTRY_CATEGORY_UNSPECIFIED = 0;
  28. // Automotive
  29. AUTOMOTIVE = 1;
  30. // Business and industrial markets
  31. BUSINESS_AND_INDUSTRIAL_MARKETS = 2;
  32. // Finance
  33. FINANCE = 3;
  34. // Healthcare
  35. HEALTHCARE = 4;
  36. // Technology
  37. TECHNOLOGY = 5;
  38. // Travel
  39. TRAVEL = 6;
  40. // Other
  41. OTHER = 7;
  42. // Arts and entertainment
  43. ARTS_AND_ENTERTAINMENT = 8;
  44. // Beauty and fitness
  45. BEAUTY_AND_FITNESS = 9;
  46. // Books and literature
  47. BOOKS_AND_LITERATURE = 10;
  48. // Food and drink
  49. FOOD_AND_DRINK = 11;
  50. // Games
  51. GAMES = 12;
  52. // Hobbies and leisure
  53. HOBBIES_AND_LEISURE = 13;
  54. // Home and garden
  55. HOME_AND_GARDEN = 14;
  56. // Internet and telecom
  57. INTERNET_AND_TELECOM = 15;
  58. // Law and government
  59. LAW_AND_GOVERNMENT = 16;
  60. // News
  61. NEWS = 17;
  62. // Online communities
  63. ONLINE_COMMUNITIES = 18;
  64. // People and society
  65. PEOPLE_AND_SOCIETY = 19;
  66. // Pets and animals
  67. PETS_AND_ANIMALS = 20;
  68. // Real estate
  69. REAL_ESTATE = 21;
  70. // Reference
  71. REFERENCE = 22;
  72. // Science
  73. SCIENCE = 23;
  74. // Sports
  75. SPORTS = 24;
  76. // Jobs and education
  77. JOBS_AND_EDUCATION = 25;
  78. // Shopping
  79. SHOPPING = 26;
  80. }
  81. // Various levels of service for Google Analytics.
  82. enum ServiceLevel {
  83. // Service level not specified or invalid.
  84. SERVICE_LEVEL_UNSPECIFIED = 0;
  85. // The standard version of Google Analytics.
  86. GOOGLE_ANALYTICS_STANDARD = 1;
  87. // The paid, premium version of Google Analytics.
  88. GOOGLE_ANALYTICS_360 = 2;
  89. }
  90. // Different kinds of actors that can make changes to Google Analytics
  91. // resources.
  92. enum ActorType {
  93. // Unknown or unspecified actor type.
  94. ACTOR_TYPE_UNSPECIFIED = 0;
  95. // Changes made by the user specified in actor_email.
  96. USER = 1;
  97. // Changes made by the Google Analytics system.
  98. SYSTEM = 2;
  99. // Changes made by Google Analytics support team staff.
  100. SUPPORT = 3;
  101. }
  102. // Types of actions that may change a resource.
  103. enum ActionType {
  104. // Action type unknown or not specified.
  105. ACTION_TYPE_UNSPECIFIED = 0;
  106. // Resource was created in this change.
  107. CREATED = 1;
  108. // Resource was updated in this change.
  109. UPDATED = 2;
  110. // Resource was deleted in this change.
  111. DELETED = 3;
  112. }
  113. // Types of resources whose changes may be returned from change history.
  114. enum ChangeHistoryResourceType {
  115. // Resource type unknown or not specified.
  116. CHANGE_HISTORY_RESOURCE_TYPE_UNSPECIFIED = 0;
  117. // Account resource
  118. ACCOUNT = 1;
  119. // Property resource
  120. PROPERTY = 2;
  121. // FirebaseLink resource
  122. FIREBASE_LINK = 6;
  123. // GoogleAdsLink resource
  124. GOOGLE_ADS_LINK = 7;
  125. // GoogleSignalsSettings resource
  126. GOOGLE_SIGNALS_SETTINGS = 8;
  127. // ConversionEvent resource
  128. CONVERSION_EVENT = 9;
  129. // MeasurementProtocolSecret resource
  130. MEASUREMENT_PROTOCOL_SECRET = 10;
  131. // CustomDimension resource
  132. CUSTOM_DIMENSION = 11;
  133. // CustomMetric resource
  134. CUSTOM_METRIC = 12;
  135. // DataRetentionSettings resource
  136. DATA_RETENTION_SETTINGS = 13;
  137. // DisplayVideo360AdvertiserLink resource
  138. DISPLAY_VIDEO_360_ADVERTISER_LINK = 14;
  139. // DisplayVideo360AdvertiserLinkProposal resource
  140. DISPLAY_VIDEO_360_ADVERTISER_LINK_PROPOSAL = 15;
  141. // SearchAds360Link resource
  142. SEARCH_ADS_360_LINK = 16;
  143. // DataStream resource
  144. DATA_STREAM = 18;
  145. // AttributionSettings resource
  146. ATTRIBUTION_SETTINGS = 20;
  147. }
  148. // Status of the Google Signals settings (i.e., whether this feature has been
  149. // enabled for the property).
  150. enum GoogleSignalsState {
  151. // Google Signals status defaults to GOOGLE_SIGNALS_STATE_UNSPECIFIED to
  152. // represent that the user has not made an explicit choice.
  153. GOOGLE_SIGNALS_STATE_UNSPECIFIED = 0;
  154. // Google Signals is enabled.
  155. GOOGLE_SIGNALS_ENABLED = 1;
  156. // Google Signals is disabled.
  157. GOOGLE_SIGNALS_DISABLED = 2;
  158. }
  159. // Consent field of the Google Signals settings (i.e., whether the user has
  160. // consented to the Google Signals terms of service.)
  161. enum GoogleSignalsConsent {
  162. // Google Signals consent value defaults to
  163. // GOOGLE_SIGNALS_CONSENT_UNSPECIFIED. This will be treated as
  164. // GOOGLE_SIGNALS_CONSENT_NOT_CONSENTED.
  165. GOOGLE_SIGNALS_CONSENT_UNSPECIFIED = 0;
  166. // Terms of service have been accepted
  167. GOOGLE_SIGNALS_CONSENT_CONSENTED = 2;
  168. // Terms of service have not been accepted
  169. GOOGLE_SIGNALS_CONSENT_NOT_CONSENTED = 1;
  170. }
  171. // An indication of which product the user initiated a link proposal from.
  172. enum LinkProposalInitiatingProduct {
  173. // Unspecified product.
  174. LINK_PROPOSAL_INITIATING_PRODUCT_UNSPECIFIED = 0;
  175. // This proposal was created by a user from Google Analytics.
  176. GOOGLE_ANALYTICS = 1;
  177. // This proposal was created by a user from a linked product (not Google
  178. // Analytics).
  179. LINKED_PRODUCT = 2;
  180. }
  181. // The state of a link proposal resource.
  182. enum LinkProposalState {
  183. // Unspecified state
  184. LINK_PROPOSAL_STATE_UNSPECIFIED = 0;
  185. // This proposal is awaiting review from a Google Analytics user. This
  186. // proposal will automatically expire after some time.
  187. AWAITING_REVIEW_FROM_GOOGLE_ANALYTICS = 1;
  188. // This proposal is awaiting review from a user of a linked product. This
  189. // proposal will automatically expire after some time.
  190. AWAITING_REVIEW_FROM_LINKED_PRODUCT = 2;
  191. // This proposal has been withdrawn by an admin on the initiating product.
  192. // This proposal will be automatically deleted after some time.
  193. WITHDRAWN = 3;
  194. // This proposal has been declined by an admin on the receiving product. This
  195. // proposal will be automatically deleted after some time.
  196. DECLINED = 4;
  197. // This proposal expired due to lack of response from an admin on the
  198. // receiving product. This proposal will be automatically deleted after some
  199. // time.
  200. EXPIRED = 5;
  201. // This proposal has become obsolete because a link was directly created to
  202. // the same external product resource that this proposal specifies. This
  203. // proposal will be automatically deleted after some time.
  204. OBSOLETE = 6;
  205. }
  206. // Types of Property resources.
  207. enum PropertyType {
  208. // Unknown or unspecified property type
  209. PROPERTY_TYPE_UNSPECIFIED = 0;
  210. // Ordinary GA4 property
  211. PROPERTY_TYPE_ORDINARY = 1;
  212. // GA4 subproperty
  213. PROPERTY_TYPE_SUBPROPERTY = 2;
  214. // GA4 rollup property
  215. PROPERTY_TYPE_ROLLUP = 3;
  216. }
  217. // A resource message representing a Google Analytics account.
  218. message Account {
  219. option (google.api.resource) = {
  220. type: "analyticsadmin.googleapis.com/Account"
  221. pattern: "accounts/{account}"
  222. };
  223. // Output only. Resource name of this account.
  224. // Format: accounts/{account}
  225. // Example: "accounts/100"
  226. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  227. // Output only. Time when this account was originally created.
  228. google.protobuf.Timestamp create_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
  229. // Output only. Time when account payload fields were last updated.
  230. google.protobuf.Timestamp update_time = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  231. // Required. Human-readable display name for this account.
  232. string display_name = 4 [(google.api.field_behavior) = REQUIRED];
  233. // Country of business. Must be a Unicode CLDR region code.
  234. string region_code = 5;
  235. // Output only. Indicates whether this Account is soft-deleted or not. Deleted
  236. // accounts are excluded from List results unless specifically requested.
  237. bool deleted = 6 [(google.api.field_behavior) = OUTPUT_ONLY];
  238. }
  239. // A resource message representing a Google Analytics GA4 property.
  240. message Property {
  241. option (google.api.resource) = {
  242. type: "analyticsadmin.googleapis.com/Property"
  243. pattern: "properties/{property}"
  244. };
  245. // Output only. Resource name of this property.
  246. // Format: properties/{property_id}
  247. // Example: "properties/1000"
  248. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  249. // Immutable. The property type for this Property resource. When creating a property, if
  250. // the type is "PROPERTY_TYPE_UNSPECIFIED", then "ORDINARY_PROPERTY" will be
  251. // implied. "SUBPROPERTY" and "ROLLUP_PROPERTY" types cannot yet be created
  252. // via Google Analytics Admin API.
  253. PropertyType property_type = 14 [(google.api.field_behavior) = IMMUTABLE];
  254. // Output only. Time when the entity was originally created.
  255. google.protobuf.Timestamp create_time = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  256. // Output only. Time when entity payload fields were last updated.
  257. google.protobuf.Timestamp update_time = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
  258. // Immutable. Resource name of this property's logical parent.
  259. //
  260. // Note: The Property-Moving UI can be used to change the parent.
  261. // Format: accounts/{account}, properties/{property}
  262. // Example: "accounts/100", "properties/101"
  263. string parent = 2 [(google.api.field_behavior) = IMMUTABLE];
  264. // Required. Human-readable display name for this property.
  265. //
  266. // The max allowed display name length is 100 UTF-16 code units.
  267. string display_name = 5 [(google.api.field_behavior) = REQUIRED];
  268. // Industry associated with this property
  269. // Example: AUTOMOTIVE, FOOD_AND_DRINK
  270. IndustryCategory industry_category = 6;
  271. // Required. Reporting Time Zone, used as the day boundary for reports, regardless of
  272. // where the data originates. If the time zone honors DST, Analytics will
  273. // automatically adjust for the changes.
  274. //
  275. // NOTE: Changing the time zone only affects data going forward, and is not
  276. // applied retroactively.
  277. //
  278. // Format: https://www.iana.org/time-zones
  279. // Example: "America/Los_Angeles"
  280. string time_zone = 7 [(google.api.field_behavior) = REQUIRED];
  281. // The currency type used in reports involving monetary values.
  282. //
  283. //
  284. // Format: https://en.wikipedia.org/wiki/ISO_4217
  285. // Examples: "USD", "EUR", "JPY"
  286. string currency_code = 8;
  287. // Output only. The Google Analytics service level that applies to this property.
  288. ServiceLevel service_level = 10 [(google.api.field_behavior) = OUTPUT_ONLY];
  289. // Output only. If set, the time at which this property was trashed. If not set, then this
  290. // property is not currently in the trash can.
  291. google.protobuf.Timestamp delete_time = 11 [(google.api.field_behavior) = OUTPUT_ONLY];
  292. // Output only. If set, the time at which this trashed property will be permanently
  293. // deleted. If not set, then this property is not currently in the trash can
  294. // and is not slated to be deleted.
  295. google.protobuf.Timestamp expire_time = 12 [(google.api.field_behavior) = OUTPUT_ONLY];
  296. // Immutable. The resource name of the parent account
  297. // Format: accounts/{account_id}
  298. // Example: "accounts/123"
  299. string account = 13 [
  300. (google.api.field_behavior) = IMMUTABLE,
  301. (google.api.resource_reference) = {
  302. type: "analyticsadmin.googleapis.com/Account"
  303. }
  304. ];
  305. }
  306. // A resource message representing a data stream.
  307. message DataStream {
  308. option (google.api.resource) = {
  309. type: "analyticsadmin.googleapis.com/DataStream"
  310. pattern: "properties/{property}/dataStreams/{data_stream}"
  311. };
  312. // Data specific to web streams.
  313. message WebStreamData {
  314. // Output only. Analytics "Measurement ID", without the "G-" prefix.
  315. // Example: "G-1A2BCD345E" would just be "1A2BCD345E"
  316. string measurement_id = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  317. // Output only. ID of the corresponding web app in Firebase, if any.
  318. // This ID can change if the web app is deleted and recreated.
  319. string firebase_app_id = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
  320. // Immutable. Domain name of the web app being measured, or empty.
  321. // Example: "http://www.google.com", "https://www.google.com"
  322. string default_uri = 3 [(google.api.field_behavior) = IMMUTABLE];
  323. }
  324. // Data specific to Android app streams.
  325. message AndroidAppStreamData {
  326. // Output only. ID of the corresponding Android app in Firebase, if any.
  327. // This ID can change if the Android app is deleted and recreated.
  328. string firebase_app_id = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  329. // Immutable. The package name for the app being measured.
  330. // Example: "com.example.myandroidapp"
  331. string package_name = 2 [(google.api.field_behavior) = IMMUTABLE];
  332. }
  333. // Data specific to iOS app streams.
  334. message IosAppStreamData {
  335. // Output only. ID of the corresponding iOS app in Firebase, if any.
  336. // This ID can change if the iOS app is deleted and recreated.
  337. string firebase_app_id = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  338. // Required. Immutable. The Apple App Store Bundle ID for the app
  339. // Example: "com.example.myiosapp"
  340. string bundle_id = 2 [
  341. (google.api.field_behavior) = IMMUTABLE,
  342. (google.api.field_behavior) = REQUIRED
  343. ];
  344. }
  345. // The type of the data stream.
  346. enum DataStreamType {
  347. // Type unknown or not specified.
  348. DATA_STREAM_TYPE_UNSPECIFIED = 0;
  349. // Web data stream.
  350. WEB_DATA_STREAM = 1;
  351. // Android app data stream.
  352. ANDROID_APP_DATA_STREAM = 2;
  353. // iOS app data stream.
  354. IOS_APP_DATA_STREAM = 3;
  355. }
  356. // Data for specific data stream types. The message that will be
  357. // set corresponds to the type of this stream.
  358. oneof stream_data {
  359. // Data specific to web streams. Must be populated if type is
  360. // WEB_DATA_STREAM.
  361. WebStreamData web_stream_data = 6;
  362. // Data specific to Android app streams. Must be populated if type is
  363. // ANDROID_APP_DATA_STREAM.
  364. AndroidAppStreamData android_app_stream_data = 7;
  365. // Data specific to iOS app streams. Must be populated if type is
  366. // IOS_APP_DATA_STREAM.
  367. IosAppStreamData ios_app_stream_data = 8;
  368. }
  369. // Output only. Resource name of this Data Stream.
  370. // Format: properties/{property_id}/dataStreams/{stream_id}
  371. // Example: "properties/1000/dataStreams/2000"
  372. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  373. // Required. Immutable. The type of this DataStream resource.
  374. DataStreamType type = 2 [
  375. (google.api.field_behavior) = IMMUTABLE,
  376. (google.api.field_behavior) = REQUIRED
  377. ];
  378. // Human-readable display name for the Data Stream.
  379. //
  380. // Required for web data streams.
  381. //
  382. // The max allowed display name length is 255 UTF-16 code units.
  383. string display_name = 3;
  384. // Output only. Time when this stream was originally created.
  385. google.protobuf.Timestamp create_time = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
  386. // Output only. Time when stream payload fields were last updated.
  387. google.protobuf.Timestamp update_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
  388. }
  389. // A resource message representing a user's permissions on an Account or
  390. // Property resource.
  391. message UserLink {
  392. option (google.api.resource) = {
  393. type: "analyticsadmin.googleapis.com/UserLink"
  394. pattern: "accounts/{account}/userLinks/{user_link}"
  395. pattern: "properties/{property}/userLinks/{user_link}"
  396. };
  397. // Output only. Example format: properties/1234/userLinks/5678
  398. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  399. // Immutable. Email address of the user to link
  400. string email_address = 2 [(google.api.field_behavior) = IMMUTABLE];
  401. // Roles directly assigned to this user for this account or property.
  402. //
  403. // Valid values:
  404. // predefinedRoles/viewer
  405. // predefinedRoles/analyst
  406. // predefinedRoles/editor
  407. // predefinedRoles/admin
  408. // predefinedRoles/no-cost-data
  409. // predefinedRoles/no-revenue-data
  410. //
  411. // Excludes roles that are inherited from a higher-level entity, group,
  412. // or organization admin role.
  413. //
  414. // A UserLink that is updated to have an empty list of direct_roles will be
  415. // deleted.
  416. repeated string direct_roles = 3;
  417. }
  418. // Read-only resource used to summarize a principal's effective roles.
  419. message AuditUserLink {
  420. // Example format: properties/1234/userLinks/5678
  421. string name = 1;
  422. // Email address of the linked user
  423. string email_address = 2;
  424. // Roles directly assigned to this user for this entity.
  425. //
  426. // Format: predefinedRoles/viewer
  427. //
  428. // Excludes roles that are inherited from an account (if this is for a
  429. // property), group, or organization admin role.
  430. repeated string direct_roles = 3;
  431. // Union of all permissions a user has at this account or property (includes
  432. // direct permissions, group-inherited permissions, etc.).
  433. //
  434. // Format: predefinedRoles/viewer
  435. repeated string effective_roles = 4;
  436. }
  437. // A link between a GA4 property and a Firebase project.
  438. message FirebaseLink {
  439. option (google.api.resource) = {
  440. type: "analyticsadmin.googleapis.com/FirebaseLink"
  441. pattern: "properties/{property}/firebaseLinks/{firebase_link}"
  442. };
  443. // Output only. Example format: properties/1234/firebaseLinks/5678
  444. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  445. // Immutable. Firebase project resource name. When creating a FirebaseLink, you may
  446. // provide this resource name using either a project number or project ID.
  447. // Once this resource has been created, returned FirebaseLinks will always
  448. // have a project_name that contains a project number.
  449. //
  450. // Format: 'projects/{project number}'
  451. // Example: 'projects/1234'
  452. string project = 2 [(google.api.field_behavior) = IMMUTABLE];
  453. // Output only. Time when this FirebaseLink was originally created.
  454. google.protobuf.Timestamp create_time = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  455. }
  456. // Read-only resource with the tag for sending data from a website to a
  457. // DataStream. Only present for web DataStream resources.
  458. message GlobalSiteTag {
  459. option (google.api.resource) = {
  460. type: "analyticsadmin.googleapis.com/GlobalSiteTag"
  461. pattern: "properties/{property}/dataStreams/{data_stream}/globalSiteTag"
  462. };
  463. // Output only. Resource name for this GlobalSiteTag resource.
  464. // Format: properties/{property_id}/dataStreams/{stream_id}/globalSiteTag
  465. // Example: "properties/123/dataStreams/456/globalSiteTag"
  466. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  467. // Immutable. JavaScript code snippet to be pasted as the first item into the head tag of
  468. // every webpage to measure.
  469. string snippet = 2 [(google.api.field_behavior) = IMMUTABLE];
  470. }
  471. // A link between a GA4 property and a Google Ads account.
  472. message GoogleAdsLink {
  473. option (google.api.resource) = {
  474. type: "analyticsadmin.googleapis.com/GoogleAdsLink"
  475. pattern: "properties/{property}/googleAdsLinks/{google_ads_link}"
  476. };
  477. // Output only. Format: properties/{propertyId}/googleAdsLinks/{googleAdsLinkId}
  478. //
  479. // Note: googleAdsLinkId is not the Google Ads customer ID.
  480. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  481. // Immutable. Google Ads customer ID.
  482. string customer_id = 3 [(google.api.field_behavior) = IMMUTABLE];
  483. // Output only. If true, this link is for a Google Ads manager account.
  484. bool can_manage_clients = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
  485. // Enable personalized advertising features with this integration.
  486. // Automatically publish my Google Analytics audience lists and Google
  487. // Analytics remarketing events/parameters to the linked Google Ads account.
  488. // If this field is not set on create/update, it will be defaulted to true.
  489. google.protobuf.BoolValue ads_personalization_enabled = 5;
  490. // Output only. Time when this link was originally created.
  491. google.protobuf.Timestamp create_time = 7 [(google.api.field_behavior) = OUTPUT_ONLY];
  492. // Output only. Time when this link was last updated.
  493. google.protobuf.Timestamp update_time = 8 [(google.api.field_behavior) = OUTPUT_ONLY];
  494. // Output only. Email address of the user that created the link.
  495. // An empty string will be returned if the email address can't be retrieved.
  496. string creator_email_address = 9 [(google.api.field_behavior) = OUTPUT_ONLY];
  497. }
  498. // A resource message representing data sharing settings of a Google Analytics
  499. // account.
  500. message DataSharingSettings {
  501. option (google.api.resource) = {
  502. type: "analyticsadmin.googleapis.com/DataSharingSettings"
  503. pattern: "accounts/{account}/dataSharingSettings"
  504. };
  505. // Output only. Resource name.
  506. // Format: accounts/{account}/dataSharingSettings
  507. // Example: "accounts/1000/dataSharingSettings"
  508. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  509. // Allows Google support to access the data in order to help troubleshoot
  510. // issues.
  511. bool sharing_with_google_support_enabled = 2;
  512. // Allows Google sales teams that are assigned to the customer to access the
  513. // data in order to suggest configuration changes to improve results.
  514. // Sales team restrictions still apply when enabled.
  515. bool sharing_with_google_assigned_sales_enabled = 3;
  516. // Allows any of Google sales to access the data in order to suggest
  517. // configuration changes to improve results.
  518. bool sharing_with_google_any_sales_enabled = 4;
  519. // Allows Google to use the data to improve other Google products or services.
  520. bool sharing_with_google_products_enabled = 5;
  521. // Allows Google to share the data anonymously in aggregate form with others.
  522. bool sharing_with_others_enabled = 6;
  523. }
  524. // A virtual resource representing an overview of an account and
  525. // all its child GA4 properties.
  526. message AccountSummary {
  527. option (google.api.resource) = {
  528. type: "analyticsadmin.googleapis.com/AccountSummary"
  529. pattern: "accountSummaries/{account_summary}"
  530. };
  531. // Resource name for this account summary.
  532. // Format: accountSummaries/{account_id}
  533. // Example: "accountSummaries/1000"
  534. string name = 1;
  535. // Resource name of account referred to by this account summary
  536. // Format: accounts/{account_id}
  537. // Example: "accounts/1000"
  538. string account = 2 [(google.api.resource_reference) = {
  539. type: "analyticsadmin.googleapis.com/Account"
  540. }];
  541. // Display name for the account referred to in this account summary.
  542. string display_name = 3;
  543. // List of summaries for child accounts of this account.
  544. repeated PropertySummary property_summaries = 4;
  545. }
  546. // A virtual resource representing metadata for a GA4 property.
  547. message PropertySummary {
  548. // Resource name of property referred to by this property summary
  549. // Format: properties/{property_id}
  550. // Example: "properties/1000"
  551. string property = 1 [(google.api.resource_reference) = {
  552. type: "analyticsadmin.googleapis.com/Property"
  553. }];
  554. // Display name for the property referred to in this property summary.
  555. string display_name = 2;
  556. // The property's property type.
  557. PropertyType property_type = 3;
  558. // Resource name of this property's logical parent.
  559. //
  560. // Note: The Property-Moving UI can be used to change the parent.
  561. // Format: accounts/{account}, properties/{property}
  562. // Example: "accounts/100", "properties/200"
  563. string parent = 4;
  564. }
  565. // A secret value used for sending hits to Measurement Protocol.
  566. message MeasurementProtocolSecret {
  567. option (google.api.resource) = {
  568. type: "analyticsadmin.googleapis.com/MeasurementProtocolSecret"
  569. pattern: "properties/{property}/dataStreams/{data_stream}/measurementProtocolSecrets/{measurement_protocol_secret}"
  570. };
  571. // Output only. Resource name of this secret. This secret may be a child of any type of
  572. // stream.
  573. // Format:
  574. // properties/{property}/dataStreams/{dataStream}/measurementProtocolSecrets/{measurementProtocolSecret}
  575. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  576. // Required. Human-readable display name for this secret.
  577. string display_name = 2 [(google.api.field_behavior) = REQUIRED];
  578. // Output only. The measurement protocol secret value. Pass this value to the api_secret
  579. // field of the Measurement Protocol API when sending hits to this
  580. // secret's parent property.
  581. string secret_value = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  582. }
  583. // A set of changes within a Google Analytics account or its child properties
  584. // that resulted from the same cause. Common causes would be updates made in the
  585. // Google Analytics UI, changes from customer support, or automatic Google
  586. // Analytics system changes.
  587. message ChangeHistoryEvent {
  588. // ID of this change history event. This ID is unique across Google Analytics.
  589. string id = 1;
  590. // Time when change was made.
  591. google.protobuf.Timestamp change_time = 2;
  592. // The type of actor that made this change.
  593. ActorType actor_type = 3;
  594. // Email address of the Google account that made the change. This will be a
  595. // valid email address if the actor field is set to USER, and empty otherwise.
  596. // Google accounts that have been deleted will cause an error.
  597. string user_actor_email = 4;
  598. // If true, then the list of changes returned was filtered, and does not
  599. // represent all changes that occurred in this event.
  600. bool changes_filtered = 5;
  601. // A list of changes made in this change history event that fit the filters
  602. // specified in SearchChangeHistoryEventsRequest.
  603. repeated ChangeHistoryChange changes = 6;
  604. }
  605. // A description of a change to a single Google Analytics resource.
  606. message ChangeHistoryChange {
  607. // A snapshot of a resource as before or after the result of a change in
  608. // change history.
  609. message ChangeHistoryResource {
  610. oneof resource {
  611. // A snapshot of an Account resource in change history.
  612. Account account = 1;
  613. // A snapshot of a Property resource in change history.
  614. Property property = 2;
  615. // A snapshot of a FirebaseLink resource in change history.
  616. FirebaseLink firebase_link = 6;
  617. // A snapshot of a GoogleAdsLink resource in change history.
  618. GoogleAdsLink google_ads_link = 7;
  619. // A snapshot of a GoogleSignalsSettings resource in change history.
  620. GoogleSignalsSettings google_signals_settings = 8;
  621. // A snapshot of a DisplayVideo360AdvertiserLink resource in change
  622. // history.
  623. DisplayVideo360AdvertiserLink display_video_360_advertiser_link = 9;
  624. // A snapshot of a DisplayVideo360AdvertiserLinkProposal resource in
  625. // change history.
  626. DisplayVideo360AdvertiserLinkProposal display_video_360_advertiser_link_proposal = 10;
  627. // A snapshot of a ConversionEvent resource in change history.
  628. ConversionEvent conversion_event = 11;
  629. // A snapshot of a MeasurementProtocolSecret resource in change history.
  630. MeasurementProtocolSecret measurement_protocol_secret = 12;
  631. // A snapshot of a CustomDimension resource in change history.
  632. CustomDimension custom_dimension = 13;
  633. // A snapshot of a CustomMetric resource in change history.
  634. CustomMetric custom_metric = 14;
  635. // A snapshot of a data retention settings resource in change history.
  636. DataRetentionSettings data_retention_settings = 15;
  637. // A snapshot of a DataStream resource in change history.
  638. DataStream data_stream = 18;
  639. // A snapshot of AttributionSettings resource in change history.
  640. AttributionSettings attribution_settings = 20;
  641. }
  642. }
  643. // Resource name of the resource whose changes are described by this entry.
  644. string resource = 1;
  645. // The type of action that changed this resource.
  646. ActionType action = 2;
  647. // Resource contents from before the change was made. If this resource was
  648. // created in this change, this field will be missing.
  649. ChangeHistoryResource resource_before_change = 3;
  650. // Resource contents from after the change was made. If this resource was
  651. // deleted in this change, this field will be missing.
  652. ChangeHistoryResource resource_after_change = 4;
  653. }
  654. // A link between a GA4 property and a Display & Video 360 advertiser.
  655. message DisplayVideo360AdvertiserLink {
  656. option (google.api.resource) = {
  657. type: "analyticsadmin.googleapis.com/DisplayVideo360AdvertiserLink"
  658. pattern: "properties/{property}/displayVideo360AdvertiserLinks/{display_video_360_advertiser_link}"
  659. };
  660. // Output only. The resource name for this DisplayVideo360AdvertiserLink resource.
  661. // Format: properties/{propertyId}/displayVideo360AdvertiserLinks/{linkId}
  662. //
  663. // Note: linkId is not the Display & Video 360 Advertiser ID
  664. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  665. // Immutable. The Display & Video 360 Advertiser's advertiser ID.
  666. string advertiser_id = 2 [(google.api.field_behavior) = IMMUTABLE];
  667. // Output only. The display name of the Display & Video 360 Advertiser.
  668. string advertiser_display_name = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  669. // Enables personalized advertising features with this integration.
  670. // If this field is not set on create/update, it will be defaulted to true.
  671. google.protobuf.BoolValue ads_personalization_enabled = 4;
  672. // Immutable. Enables the import of campaign data from Display & Video 360 into the GA4
  673. // property. After link creation, this can only be updated from the Display &
  674. // Video 360 product.
  675. // If this field is not set on create, it will be defaulted to true.
  676. google.protobuf.BoolValue campaign_data_sharing_enabled = 5 [(google.api.field_behavior) = IMMUTABLE];
  677. // Immutable. Enables the import of cost data from Display & Video 360 into the GA4
  678. // property. This can only be enabled if campaign_data_sharing_enabled is
  679. // enabled. After link creation, this can only be updated from the Display &
  680. // Video 360 product.
  681. // If this field is not set on create, it will be defaulted to true.
  682. google.protobuf.BoolValue cost_data_sharing_enabled = 6 [(google.api.field_behavior) = IMMUTABLE];
  683. }
  684. // A proposal for a link between a GA4 property and a Display & Video 360
  685. // advertiser.
  686. //
  687. // A proposal is converted to a DisplayVideo360AdvertiserLink once approved.
  688. // Google Analytics admins approve inbound proposals while Display & Video 360
  689. // admins approve outbound proposals.
  690. message DisplayVideo360AdvertiserLinkProposal {
  691. option (google.api.resource) = {
  692. type: "analyticsadmin.googleapis.com/DisplayVideo360AdvertiserLinkProposal"
  693. pattern: "properties/{property}/displayVideo360AdvertiserLinkProposals/{display_video_360_advertiser_link_proposal}"
  694. };
  695. // Output only. The resource name for this DisplayVideo360AdvertiserLinkProposal resource.
  696. // Format:
  697. // properties/{propertyId}/displayVideo360AdvertiserLinkProposals/{proposalId}
  698. //
  699. // Note: proposalId is not the Display & Video 360 Advertiser ID
  700. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  701. // Immutable. The Display & Video 360 Advertiser's advertiser ID.
  702. string advertiser_id = 2 [(google.api.field_behavior) = IMMUTABLE];
  703. // Output only. The status information for this link proposal.
  704. LinkProposalStatusDetails link_proposal_status_details = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  705. // Output only. The display name of the Display & Video Advertiser.
  706. // Only populated for proposals that originated from Display & Video 360.
  707. string advertiser_display_name = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
  708. // Input only. On a proposal being sent to Display & Video 360, this field must be set to
  709. // the email address of an admin on the target advertiser. This is used to
  710. // verify that the Google Analytics admin is aware of at least one admin on
  711. // the Display & Video 360 Advertiser. This does not restrict approval of the
  712. // proposal to a single user. Any admin on the Display & Video 360 Advertiser
  713. // may approve the proposal.
  714. string validation_email = 5 [(google.api.field_behavior) = INPUT_ONLY];
  715. // Immutable. Enables personalized advertising features with this integration.
  716. // If this field is not set on create, it will be defaulted to true.
  717. google.protobuf.BoolValue ads_personalization_enabled = 6 [(google.api.field_behavior) = IMMUTABLE];
  718. // Immutable. Enables the import of campaign data from Display & Video 360.
  719. // If this field is not set on create, it will be defaulted to true.
  720. google.protobuf.BoolValue campaign_data_sharing_enabled = 7 [(google.api.field_behavior) = IMMUTABLE];
  721. // Immutable. Enables the import of cost data from Display & Video 360.
  722. // This can only be enabled if campaign_data_sharing_enabled is enabled.
  723. // If this field is not set on create, it will be defaulted to true.
  724. google.protobuf.BoolValue cost_data_sharing_enabled = 8 [(google.api.field_behavior) = IMMUTABLE];
  725. }
  726. // Status information for a link proposal.
  727. message LinkProposalStatusDetails {
  728. // Output only. The source of this proposal.
  729. LinkProposalInitiatingProduct link_proposal_initiating_product = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  730. // Output only. The email address of the user that proposed this linkage.
  731. string requestor_email = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
  732. // Output only. The state of this proposal.
  733. LinkProposalState link_proposal_state = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  734. }
  735. // A conversion event in a Google Analytics property.
  736. message ConversionEvent {
  737. option (google.api.resource) = {
  738. type: "analyticsadmin.googleapis.com/ConversionEvent"
  739. pattern: "properties/{property}/conversionEvents/{conversion_event}"
  740. };
  741. // Output only. Resource name of this conversion event.
  742. // Format: properties/{property}/conversionEvents/{conversion_event}
  743. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  744. // Immutable. The event name for this conversion event.
  745. // Examples: 'click', 'purchase'
  746. string event_name = 2 [(google.api.field_behavior) = IMMUTABLE];
  747. // Output only. Time when this conversion event was created in the property.
  748. google.protobuf.Timestamp create_time = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
  749. // Output only. If set, this event can currently be deleted via DeleteConversionEvent.
  750. bool deletable = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
  751. // Output only. If set to true, this conversion event refers to a custom event. If set to
  752. // false, this conversion event refers to a default event in GA. Default
  753. // events typically have special meaning in GA. Default events are usually
  754. // created for you by the GA system, but in some cases can be created by
  755. // property admins. Custom events count towards the maximum number of
  756. // custom conversion events that may be created per property.
  757. bool custom = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
  758. }
  759. // Settings values for Google Signals. This is a singleton resource.
  760. message GoogleSignalsSettings {
  761. option (google.api.resource) = {
  762. type: "analyticsadmin.googleapis.com/GoogleSignalsSettings"
  763. pattern: "properties/{property}/googleSignalsSettings"
  764. };
  765. // Output only. Resource name of this setting.
  766. // Format: properties/{property_id}/googleSignalsSettings
  767. // Example: "properties/1000/googleSignalsSettings"
  768. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  769. // Status of this setting.
  770. GoogleSignalsState state = 3;
  771. // Output only. Terms of Service acceptance.
  772. GoogleSignalsConsent consent = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
  773. }
  774. // A definition for a CustomDimension.
  775. message CustomDimension {
  776. option (google.api.resource) = {
  777. type: "analyticsadmin.googleapis.com/CustomDimension"
  778. pattern: "properties/{property}/customDimensions/{custom_dimension}"
  779. };
  780. // Valid values for the scope of this dimension.
  781. enum DimensionScope {
  782. // Scope unknown or not specified.
  783. DIMENSION_SCOPE_UNSPECIFIED = 0;
  784. // Dimension scoped to an event.
  785. EVENT = 1;
  786. // Dimension scoped to a user.
  787. USER = 2;
  788. }
  789. // Output only. Resource name for this CustomDimension resource.
  790. // Format: properties/{property}/customDimensions/{customDimension}
  791. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  792. // Required. Immutable. Tagging parameter name for this custom dimension.
  793. //
  794. // If this is a user-scoped dimension, then this is the user property name.
  795. // If this is an event-scoped dimension, then this is the event parameter
  796. // name.
  797. //
  798. // May only contain alphanumeric and underscore characters, starting with a
  799. // letter. Max length of 24 characters for user-scoped dimensions, 40
  800. // characters for event-scoped dimensions.
  801. string parameter_name = 2 [
  802. (google.api.field_behavior) = REQUIRED,
  803. (google.api.field_behavior) = IMMUTABLE
  804. ];
  805. // Required. Display name for this custom dimension as shown in the Analytics UI.
  806. // Max length of 82 characters, alphanumeric plus space and underscore
  807. // starting with a letter. Legacy system-generated display names may contain
  808. // square brackets, but updates to this field will never permit square
  809. // brackets.
  810. string display_name = 3 [(google.api.field_behavior) = REQUIRED];
  811. // Optional. Description for this custom dimension. Max length of 150 characters.
  812. string description = 4 [(google.api.field_behavior) = OPTIONAL];
  813. // Required. Immutable. The scope of this dimension.
  814. DimensionScope scope = 5 [
  815. (google.api.field_behavior) = REQUIRED,
  816. (google.api.field_behavior) = IMMUTABLE
  817. ];
  818. // Optional. If set to true, sets this dimension as NPA and excludes it from ads
  819. // personalization.
  820. //
  821. // This is currently only supported by user-scoped custom dimensions.
  822. bool disallow_ads_personalization = 6 [(google.api.field_behavior) = OPTIONAL];
  823. }
  824. // A definition for a custom metric.
  825. message CustomMetric {
  826. option (google.api.resource) = {
  827. type: "analyticsadmin.googleapis.com/CustomMetric"
  828. pattern: "properties/{property}/customMetrics/{custom_metric}"
  829. };
  830. // Possible types of representing the custom metric's value.
  831. //
  832. // Currency representation may change in the future, requiring a breaking API
  833. // change.
  834. enum MeasurementUnit {
  835. // MeasurementUnit unspecified or missing.
  836. MEASUREMENT_UNIT_UNSPECIFIED = 0;
  837. // This metric uses default units.
  838. STANDARD = 1;
  839. // This metric measures a currency.
  840. CURRENCY = 2;
  841. // This metric measures feet.
  842. FEET = 3;
  843. // This metric measures meters.
  844. METERS = 4;
  845. // This metric measures kilometers.
  846. KILOMETERS = 5;
  847. // This metric measures miles.
  848. MILES = 6;
  849. // This metric measures milliseconds.
  850. MILLISECONDS = 7;
  851. // This metric measures seconds.
  852. SECONDS = 8;
  853. // This metric measures minutes.
  854. MINUTES = 9;
  855. // This metric measures hours.
  856. HOURS = 10;
  857. }
  858. // The scope of this metric.
  859. enum MetricScope {
  860. // Scope unknown or not specified.
  861. METRIC_SCOPE_UNSPECIFIED = 0;
  862. // Metric scoped to an event.
  863. EVENT = 1;
  864. }
  865. // Labels that mark the data in this custom metric as data that should be
  866. // restricted to specific users.
  867. enum RestrictedMetricType {
  868. // Type unknown or unspecified.
  869. RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0;
  870. // Metric reports cost data.
  871. COST_DATA = 1;
  872. // Metric reports revenue data.
  873. REVENUE_DATA = 2;
  874. }
  875. // Output only. Resource name for this CustomMetric resource.
  876. // Format: properties/{property}/customMetrics/{customMetric}
  877. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  878. // Required. Immutable. Tagging name for this custom metric.
  879. //
  880. // If this is an event-scoped metric, then this is the event parameter
  881. // name.
  882. //
  883. // May only contain alphanumeric and underscore charactes, starting with a
  884. // letter. Max length of 40 characters for event-scoped metrics.
  885. string parameter_name = 2 [
  886. (google.api.field_behavior) = REQUIRED,
  887. (google.api.field_behavior) = IMMUTABLE
  888. ];
  889. // Required. Display name for this custom metric as shown in the Analytics UI.
  890. // Max length of 82 characters, alphanumeric plus space and underscore
  891. // starting with a letter. Legacy system-generated display names may contain
  892. // square brackets, but updates to this field will never permit square
  893. // brackets.
  894. string display_name = 3 [(google.api.field_behavior) = REQUIRED];
  895. // Optional. Description for this custom dimension.
  896. // Max length of 150 characters.
  897. string description = 4 [(google.api.field_behavior) = OPTIONAL];
  898. // Required. The type for the custom metric's value.
  899. MeasurementUnit measurement_unit = 5 [(google.api.field_behavior) = REQUIRED];
  900. // Required. Immutable. The scope of this custom metric.
  901. MetricScope scope = 6 [
  902. (google.api.field_behavior) = REQUIRED,
  903. (google.api.field_behavior) = IMMUTABLE
  904. ];
  905. // Optional. Types of restricted data that this metric may contain. Required for metrics
  906. // with CURRENCY measurement unit. Must be empty for metrics with a
  907. // non-CURRENCY measurement unit.
  908. repeated RestrictedMetricType restricted_metric_type = 8 [(google.api.field_behavior) = OPTIONAL];
  909. }
  910. // Settings values for data retention. This is a singleton resource.
  911. message DataRetentionSettings {
  912. option (google.api.resource) = {
  913. type: "analyticsadmin.googleapis.com/DataRetentionSettings"
  914. pattern: "properties/{property}/dataRetentionSettings"
  915. };
  916. // Valid values for the data retention duration.
  917. enum RetentionDuration {
  918. // Data retention time duration is not specified.
  919. RETENTION_DURATION_UNSPECIFIED = 0;
  920. // The data retention time duration is 2 months.
  921. TWO_MONTHS = 1;
  922. // The data retention time duration is 14 months.
  923. FOURTEEN_MONTHS = 3;
  924. // The data retention time duration is 26 months.
  925. // Available to 360 properties only.
  926. TWENTY_SIX_MONTHS = 4;
  927. // The data retention time duration is 38 months.
  928. // Available to 360 properties only.
  929. THIRTY_EIGHT_MONTHS = 5;
  930. // The data retention time duration is 50 months.
  931. // Available to 360 properties only.
  932. FIFTY_MONTHS = 6;
  933. }
  934. // Output only. Resource name for this DataRetentionSetting resource.
  935. // Format: properties/{property}/dataRetentionSettings
  936. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  937. // The length of time that event-level data is retained.
  938. RetentionDuration event_data_retention = 2;
  939. // If true, reset the retention period for the user identifier with every
  940. // event from that user.
  941. bool reset_user_data_on_new_activity = 3;
  942. }
  943. // The attribution settings used for a given property. This is a singleton
  944. // resource.
  945. message AttributionSettings {
  946. option (google.api.resource) = {
  947. type: "analyticsadmin.googleapis.com/AttributionSettings"
  948. pattern: "properties/{property}/attributionSettings"
  949. };
  950. // How far back in time events should be considered for inclusion in a
  951. // converting path which leads to the first install of an app or the first
  952. // visit to a site.
  953. enum AcquisitionConversionEventLookbackWindow {
  954. // Lookback window size unspecified.
  955. ACQUISITION_CONVERSION_EVENT_LOOKBACK_WINDOW_UNSPECIFIED = 0;
  956. // 7-day lookback window.
  957. ACQUISITION_CONVERSION_EVENT_LOOKBACK_WINDOW_7_DAYS = 1;
  958. // 30-day lookback window.
  959. ACQUISITION_CONVERSION_EVENT_LOOKBACK_WINDOW_30_DAYS = 2;
  960. }
  961. // How far back in time events should be considered for inclusion in a
  962. // converting path for all conversions other than first app install/first site
  963. // visit.
  964. enum OtherConversionEventLookbackWindow {
  965. // Lookback window size unspecified.
  966. OTHER_CONVERSION_EVENT_LOOKBACK_WINDOW_UNSPECIFIED = 0;
  967. // 30-day lookback window.
  968. OTHER_CONVERSION_EVENT_LOOKBACK_WINDOW_30_DAYS = 1;
  969. // 60-day lookback window.
  970. OTHER_CONVERSION_EVENT_LOOKBACK_WINDOW_60_DAYS = 2;
  971. // 90-day lookback window.
  972. OTHER_CONVERSION_EVENT_LOOKBACK_WINDOW_90_DAYS = 3;
  973. }
  974. // The reporting attribution model used to calculate conversion credit in this
  975. // property's reports.
  976. enum ReportingAttributionModel {
  977. // Reporting attribution model unspecified.
  978. REPORTING_ATTRIBUTION_MODEL_UNSPECIFIED = 0;
  979. // Data-driven attribution distributes credit for the conversion based on
  980. // data for each conversion event. Each Data-driven model is specific to
  981. // each advertiser and each conversion event.
  982. CROSS_CHANNEL_DATA_DRIVEN = 1;
  983. // Ignores direct traffic and attributes 100% of the conversion value to the
  984. // last channel that the customer clicked through (or engaged view through
  985. // for YouTube) before converting.
  986. CROSS_CHANNEL_LAST_CLICK = 2;
  987. // Gives all credit for the conversion to the first channel that a customer
  988. // clicked (or engaged view through for YouTube) before converting.
  989. CROSS_CHANNEL_FIRST_CLICK = 3;
  990. // Distributes the credit for the conversion equally across all the channels
  991. // a customer clicked (or engaged view through for YouTube) before
  992. // converting.
  993. CROSS_CHANNEL_LINEAR = 4;
  994. // Attributes 40% credit to the first and last interaction, and the
  995. // remaining 20% credit is distributed evenly to the middle interactions.
  996. CROSS_CHANNEL_POSITION_BASED = 5;
  997. // Gives more credit to the touchpoints that happened closer in time to
  998. // the conversion.
  999. CROSS_CHANNEL_TIME_DECAY = 6;
  1000. // Attributes 100% of the conversion value to the last Google Ads channel
  1001. // that the customer clicked through before converting.
  1002. ADS_PREFERRED_LAST_CLICK = 7;
  1003. }
  1004. // Output only. Resource name of this attribution settings resource.
  1005. // Format: properties/{property_id}/attributionSettings
  1006. // Example: "properties/1000/attributionSettings"
  1007. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  1008. // Required. The lookback window configuration for acquisition conversion events.
  1009. // The default window size is 30 days.
  1010. AcquisitionConversionEventLookbackWindow acquisition_conversion_event_lookback_window = 2 [(google.api.field_behavior) = REQUIRED];
  1011. // Required. The lookback window for all other, non-acquisition conversion events.
  1012. // The default window size is 90 days.
  1013. OtherConversionEventLookbackWindow other_conversion_event_lookback_window = 3 [(google.api.field_behavior) = REQUIRED];
  1014. // Required. The reporting attribution model used to calculate conversion credit in this
  1015. // property's reports.
  1016. //
  1017. // Changing the attribution model will apply to both historical and future
  1018. // data. These changes will be reflected in reports with conversion and
  1019. // revenue data. User and session data will be unaffected.
  1020. ReportingAttributionModel reporting_attribution_model = 4 [(google.api.field_behavior) = REQUIRED];
  1021. }