@google-ads/admanager 0.4.1 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (291) hide show
  1. package/README.md +83 -0
  2. package/build/protos/google/ads/admanager/v1/ad_break_service.proto +1 -1
  3. package/build/protos/google/ads/admanager/v1/ad_review_center_ad_enums.proto +44 -0
  4. package/build/protos/google/ads/admanager/v1/ad_review_center_ad_messages.proto +62 -0
  5. package/build/protos/google/ads/admanager/v1/ad_review_center_ad_service.proto +238 -0
  6. package/build/protos/google/ads/admanager/v1/ad_unit_messages.proto +7 -7
  7. package/build/protos/google/ads/admanager/v1/ad_unit_service.proto +222 -6
  8. package/build/protos/google/ads/admanager/v1/application_messages.proto +47 -0
  9. package/build/protos/google/ads/admanager/v1/application_service.proto +129 -0
  10. package/build/protos/google/ads/admanager/v1/audience_segment_messages.proto +49 -0
  11. package/build/protos/google/ads/admanager/v1/audience_segment_service.proto +129 -0
  12. package/build/protos/google/ads/admanager/v1/bandwidth_group_service.proto +3 -3
  13. package/build/protos/google/ads/admanager/v1/browser_language_messages.proto +45 -0
  14. package/build/protos/google/ads/admanager/v1/browser_language_service.proto +129 -0
  15. package/build/protos/google/ads/admanager/v1/browser_messages.proto +51 -0
  16. package/build/protos/google/ads/admanager/v1/browser_service.proto +128 -0
  17. package/build/protos/google/ads/admanager/v1/cms_metadata_key_enums.proto +41 -0
  18. package/build/protos/google/ads/admanager/v1/cms_metadata_key_messages.proto +50 -0
  19. package/build/protos/google/ads/admanager/v1/cms_metadata_key_service.proto +129 -0
  20. package/build/protos/google/ads/admanager/v1/cms_metadata_value_enums.proto +44 -0
  21. package/build/protos/google/ads/admanager/v1/cms_metadata_value_messages.proto +61 -0
  22. package/build/protos/google/ads/admanager/v1/cms_metadata_value_service.proto +130 -0
  23. package/build/protos/google/ads/admanager/v1/company_messages.proto +14 -12
  24. package/build/protos/google/ads/admanager/v1/company_service.proto +3 -3
  25. package/build/protos/google/ads/admanager/v1/contact_enums.proto +57 -0
  26. package/build/protos/google/ads/admanager/v1/contact_messages.proto +45 -2
  27. package/build/protos/google/ads/admanager/v1/contact_service.proto +244 -0
  28. package/build/protos/google/ads/admanager/v1/content_bundle_messages.proto +53 -0
  29. package/build/protos/google/ads/admanager/v1/content_bundle_service.proto +129 -0
  30. package/build/protos/google/ads/admanager/v1/content_label_messages.proto +45 -0
  31. package/build/protos/google/ads/admanager/v1/content_label_service.proto +129 -0
  32. package/build/protos/google/ads/admanager/v1/content_messages.proto +45 -0
  33. package/build/protos/google/ads/admanager/v1/content_service.proto +128 -0
  34. package/build/protos/google/ads/admanager/v1/creative_template_enums.proto +63 -0
  35. package/build/protos/google/ads/admanager/v1/creative_template_messages.proto +253 -0
  36. package/build/protos/google/ads/admanager/v1/creative_template_service.proto +130 -0
  37. package/build/protos/google/ads/admanager/v1/creative_template_variable_url_type_enum.proto +47 -0
  38. package/build/protos/google/ads/admanager/v1/custom_field_messages.proto +5 -2
  39. package/build/protos/google/ads/admanager/v1/custom_field_service.proto +185 -3
  40. package/build/protos/google/ads/admanager/v1/custom_targeting_key_messages.proto +7 -6
  41. package/build/protos/google/ads/admanager/v1/custom_targeting_key_service.proto +191 -1
  42. package/build/protos/google/ads/admanager/v1/custom_targeting_value_messages.proto +9 -9
  43. package/build/protos/google/ads/admanager/v1/custom_targeting_value_service.proto +1 -1
  44. package/build/protos/google/ads/admanager/v1/device_capability_messages.proto +45 -0
  45. package/build/protos/google/ads/admanager/v1/device_capability_service.proto +130 -0
  46. package/build/protos/google/ads/admanager/v1/device_category_service.proto +2 -2
  47. package/build/protos/google/ads/admanager/v1/device_manufacturer_messages.proto +46 -0
  48. package/build/protos/google/ads/admanager/v1/device_manufacturer_service.proto +131 -0
  49. package/build/protos/google/ads/admanager/v1/entity_signals_mapping_service.proto +1 -1
  50. package/build/protos/google/ads/admanager/v1/exchange_syndication_product_enum.proto +47 -0
  51. package/build/protos/google/ads/admanager/v1/geo_target_service.proto +3 -3
  52. package/build/protos/google/ads/admanager/v1/goal.proto +57 -0
  53. package/build/protos/google/ads/admanager/v1/goal_enums.proto +129 -0
  54. package/build/protos/google/ads/admanager/v1/line_item_enums.proto +86 -0
  55. package/build/protos/google/ads/admanager/v1/line_item_messages.proto +93 -0
  56. package/build/protos/google/ads/admanager/v1/line_item_service.proto +128 -0
  57. package/build/protos/google/ads/admanager/v1/mobile_carrier_messages.proto +48 -0
  58. package/build/protos/google/ads/admanager/v1/mobile_carrier_service.proto +129 -0
  59. package/build/protos/google/ads/admanager/v1/mobile_device_messages.proto +54 -0
  60. package/build/protos/google/ads/admanager/v1/mobile_device_service.proto +129 -0
  61. package/build/protos/google/ads/admanager/v1/mobile_device_submodel_messages.proto +55 -0
  62. package/build/protos/google/ads/admanager/v1/mobile_device_submodel_service.proto +133 -0
  63. package/build/protos/google/ads/admanager/v1/network_messages.proto +8 -8
  64. package/build/protos/google/ads/admanager/v1/network_service.proto +32 -1
  65. package/build/protos/google/ads/admanager/v1/operating_system_service.proto +2 -2
  66. package/build/protos/google/ads/admanager/v1/operating_system_version_service.proto +2 -2
  67. package/build/protos/google/ads/admanager/v1/order_messages.proto +11 -10
  68. package/build/protos/google/ads/admanager/v1/order_service.proto +3 -3
  69. package/build/protos/google/ads/admanager/v1/placement_service.proto +220 -3
  70. package/build/protos/google/ads/admanager/v1/private_auction_deal_service.proto +2 -2
  71. package/build/protos/google/ads/admanager/v1/private_auction_service.proto +2 -2
  72. package/build/protos/google/ads/admanager/v1/programmatic_buyer_service.proto +1 -1
  73. package/build/protos/google/ads/admanager/v1/report_definition.proto +13347 -0
  74. package/build/protos/google/ads/admanager/v1/report_messages.proto +124 -3411
  75. package/build/protos/google/ads/admanager/v1/report_service.proto +10 -8
  76. package/build/protos/google/ads/admanager/v1/report_value.proto +73 -0
  77. package/build/protos/google/ads/admanager/v1/role_service.proto +3 -2
  78. package/build/protos/google/ads/admanager/v1/site_enums.proto +72 -0
  79. package/build/protos/google/ads/admanager/v1/site_messages.proto +77 -0
  80. package/build/protos/google/ads/admanager/v1/site_service.proto +295 -0
  81. package/build/protos/google/ads/admanager/v1/targeting.proto +311 -0
  82. package/build/protos/google/ads/admanager/v1/taxonomy_category_service.proto +1 -1
  83. package/build/protos/google/ads/admanager/v1/taxonomy_type_enum.proto +3 -0
  84. package/build/protos/google/ads/admanager/v1/team_enums.proto +62 -0
  85. package/build/protos/google/ads/admanager/v1/team_messages.proto +30 -0
  86. package/build/protos/google/ads/admanager/v1/team_service.proto +303 -0
  87. package/build/protos/google/ads/admanager/v1/web_property.proto +54 -0
  88. package/build/protos/protos.d.ts +34075 -11179
  89. package/build/protos/protos.js +102857 -43311
  90. package/build/protos/protos.json +11142 -3881
  91. package/build/src/index.d.ts +61 -1
  92. package/build/src/index.js +43 -3
  93. package/build/src/index.js.map +1 -1
  94. package/build/src/v1/ad_break_service_client.d.ts +465 -0
  95. package/build/src/v1/ad_break_service_client.js +659 -1
  96. package/build/src/v1/ad_break_service_client.js.map +1 -1
  97. package/build/src/v1/ad_break_service_proto_list.json +54 -1
  98. package/build/src/v1/ad_review_center_ad_service_client.d.ts +1634 -0
  99. package/build/src/v1/ad_review_center_ad_service_client.js +2327 -0
  100. package/build/src/v1/ad_review_center_ad_service_client.js.map +1 -0
  101. package/build/src/v1/ad_review_center_ad_service_client_config.json +38 -0
  102. package/build/src/v1/ad_review_center_ad_service_proto_list.json +127 -0
  103. package/build/src/v1/ad_unit_service_client.d.ts +667 -12
  104. package/build/src/v1/ad_unit_service_client.js +966 -56
  105. package/build/src/v1/ad_unit_service_client.js.map +1 -1
  106. package/build/src/v1/ad_unit_service_client_config.json +28 -0
  107. package/build/src/v1/ad_unit_service_proto_list.json +54 -1
  108. package/build/src/v1/application_service_client.d.ts +1369 -0
  109. package/build/src/v1/application_service_client.js +2027 -0
  110. package/build/src/v1/application_service_client.js.map +1 -0
  111. package/build/src/v1/application_service_client_config.json +34 -0
  112. package/build/src/v1/application_service_proto_list.json +127 -0
  113. package/build/src/v1/audience_segment_service_client.d.ts +1369 -0
  114. package/build/src/v1/audience_segment_service_client.js +2027 -0
  115. package/build/src/v1/audience_segment_service_client.js.map +1 -0
  116. package/build/src/v1/audience_segment_service_client_config.json +34 -0
  117. package/build/src/v1/audience_segment_service_proto_list.json +127 -0
  118. package/build/src/v1/bandwidth_group_service_client.d.ts +471 -6
  119. package/build/src/v1/bandwidth_group_service_client.js +663 -5
  120. package/build/src/v1/bandwidth_group_service_client.js.map +1 -1
  121. package/build/src/v1/bandwidth_group_service_proto_list.json +54 -1
  122. package/build/src/v1/browser_language_service_client.d.ts +1369 -0
  123. package/build/src/v1/browser_language_service_client.js +2027 -0
  124. package/build/src/v1/browser_language_service_client.js.map +1 -0
  125. package/build/src/v1/browser_language_service_client_config.json +34 -0
  126. package/build/src/v1/browser_language_service_proto_list.json +127 -0
  127. package/build/src/v1/browser_service_client.d.ts +1369 -0
  128. package/build/src/v1/browser_service_client.js +2027 -0
  129. package/build/src/v1/browser_service_client.js.map +1 -0
  130. package/build/src/v1/browser_service_client_config.json +34 -0
  131. package/build/src/v1/browser_service_proto_list.json +127 -0
  132. package/build/src/v1/cms_metadata_key_service_client.d.ts +1369 -0
  133. package/build/src/v1/cms_metadata_key_service_client.js +2027 -0
  134. package/build/src/v1/cms_metadata_key_service_client.js.map +1 -0
  135. package/build/src/v1/cms_metadata_key_service_client_config.json +34 -0
  136. package/build/src/v1/cms_metadata_key_service_proto_list.json +127 -0
  137. package/build/src/v1/cms_metadata_value_service_client.d.ts +1369 -0
  138. package/build/src/v1/cms_metadata_value_service_client.js +2027 -0
  139. package/build/src/v1/cms_metadata_value_service_client.js.map +1 -0
  140. package/build/src/v1/cms_metadata_value_service_client_config.json +34 -0
  141. package/build/src/v1/cms_metadata_value_service_proto_list.json +127 -0
  142. package/build/src/v1/company_service_client.d.ts +471 -6
  143. package/build/src/v1/company_service_client.js +663 -5
  144. package/build/src/v1/company_service_client.js.map +1 -1
  145. package/build/src/v1/company_service_proto_list.json +54 -1
  146. package/build/src/v1/contact_service_client.d.ts +1480 -0
  147. package/build/src/v1/contact_service_client.js +2171 -0
  148. package/build/src/v1/contact_service_client.js.map +1 -0
  149. package/build/src/v1/contact_service_client_config.json +50 -0
  150. package/build/src/v1/contact_service_proto_list.json +127 -0
  151. package/build/src/v1/content_bundle_service_client.d.ts +1369 -0
  152. package/build/src/v1/content_bundle_service_client.js +2027 -0
  153. package/build/src/v1/content_bundle_service_client.js.map +1 -0
  154. package/build/src/v1/content_bundle_service_client_config.json +34 -0
  155. package/build/src/v1/content_bundle_service_proto_list.json +127 -0
  156. package/build/src/v1/content_label_service_client.d.ts +1369 -0
  157. package/build/src/v1/content_label_service_client.js +2027 -0
  158. package/build/src/v1/content_label_service_client.js.map +1 -0
  159. package/build/src/v1/content_label_service_client_config.json +34 -0
  160. package/build/src/v1/content_label_service_proto_list.json +127 -0
  161. package/build/src/v1/content_service_client.d.ts +1369 -0
  162. package/build/src/v1/content_service_client.js +2027 -0
  163. package/build/src/v1/content_service_client.js.map +1 -0
  164. package/build/src/v1/content_service_client_config.json +34 -0
  165. package/build/src/v1/content_service_proto_list.json +127 -0
  166. package/build/src/v1/creative_template_service_client.d.ts +1369 -0
  167. package/build/src/v1/creative_template_service_client.js +2027 -0
  168. package/build/src/v1/creative_template_service_client.js.map +1 -0
  169. package/build/src/v1/creative_template_service_client_config.json +34 -0
  170. package/build/src/v1/creative_template_service_proto_list.json +127 -0
  171. package/build/src/v1/custom_field_service_client.d.ts +634 -6
  172. package/build/src/v1/custom_field_service_client.js +880 -6
  173. package/build/src/v1/custom_field_service_client.js.map +1 -1
  174. package/build/src/v1/custom_field_service_client_config.json +24 -0
  175. package/build/src/v1/custom_field_service_proto_list.json +54 -1
  176. package/build/src/v1/custom_targeting_key_service_client.d.ts +631 -0
  177. package/build/src/v1/custom_targeting_key_service_client.js +876 -2
  178. package/build/src/v1/custom_targeting_key_service_client.js.map +1 -1
  179. package/build/src/v1/custom_targeting_key_service_client_config.json +24 -0
  180. package/build/src/v1/custom_targeting_key_service_proto_list.json +54 -1
  181. package/build/src/v1/custom_targeting_value_service_client.d.ts +465 -0
  182. package/build/src/v1/custom_targeting_value_service_client.js +659 -1
  183. package/build/src/v1/custom_targeting_value_service_client.js.map +1 -1
  184. package/build/src/v1/custom_targeting_value_service_proto_list.json +54 -1
  185. package/build/src/v1/device_capability_service_client.d.ts +1369 -0
  186. package/build/src/v1/device_capability_service_client.js +2027 -0
  187. package/build/src/v1/device_capability_service_client.js.map +1 -0
  188. package/build/src/v1/device_capability_service_client_config.json +34 -0
  189. package/build/src/v1/device_capability_service_proto_list.json +127 -0
  190. package/build/src/v1/device_category_service_client.d.ts +468 -3
  191. package/build/src/v1/device_category_service_client.js +661 -3
  192. package/build/src/v1/device_category_service_client.js.map +1 -1
  193. package/build/src/v1/device_category_service_proto_list.json +54 -1
  194. package/build/src/v1/device_manufacturer_service_client.d.ts +1370 -0
  195. package/build/src/v1/device_manufacturer_service_client.js +2027 -0
  196. package/build/src/v1/device_manufacturer_service_client.js.map +1 -0
  197. package/build/src/v1/device_manufacturer_service_client_config.json +34 -0
  198. package/build/src/v1/device_manufacturer_service_proto_list.json +127 -0
  199. package/build/src/v1/entity_signals_mapping_service_client.d.ts +465 -0
  200. package/build/src/v1/entity_signals_mapping_service_client.js +659 -1
  201. package/build/src/v1/entity_signals_mapping_service_client.js.map +1 -1
  202. package/build/src/v1/entity_signals_mapping_service_proto_list.json +54 -1
  203. package/build/src/v1/gapic_metadata.json +1200 -6
  204. package/build/src/v1/geo_target_service_client.d.ts +471 -6
  205. package/build/src/v1/geo_target_service_client.js +663 -5
  206. package/build/src/v1/geo_target_service_client.js.map +1 -1
  207. package/build/src/v1/geo_target_service_proto_list.json +54 -1
  208. package/build/src/v1/index.d.ts +20 -0
  209. package/build/src/v1/index.js +42 -2
  210. package/build/src/v1/index.js.map +1 -1
  211. package/build/src/v1/line_item_service_client.d.ts +1369 -0
  212. package/build/src/v1/line_item_service_client.js +2027 -0
  213. package/build/src/v1/line_item_service_client.js.map +1 -0
  214. package/build/src/v1/line_item_service_client_config.json +34 -0
  215. package/build/src/v1/line_item_service_proto_list.json +127 -0
  216. package/build/src/v1/mobile_carrier_service_client.d.ts +1369 -0
  217. package/build/src/v1/mobile_carrier_service_client.js +2027 -0
  218. package/build/src/v1/mobile_carrier_service_client.js.map +1 -0
  219. package/build/src/v1/mobile_carrier_service_client_config.json +34 -0
  220. package/build/src/v1/mobile_carrier_service_proto_list.json +127 -0
  221. package/build/src/v1/mobile_device_service_client.d.ts +1369 -0
  222. package/build/src/v1/mobile_device_service_client.js +2027 -0
  223. package/build/src/v1/mobile_device_service_client.js.map +1 -0
  224. package/build/src/v1/mobile_device_service_client_config.json +34 -0
  225. package/build/src/v1/mobile_device_service_proto_list.json +127 -0
  226. package/build/src/v1/mobile_device_submodel_service_client.d.ts +1376 -0
  227. package/build/src/v1/mobile_device_submodel_service_client.js +2031 -0
  228. package/build/src/v1/mobile_device_submodel_service_client.js.map +1 -0
  229. package/build/src/v1/mobile_device_submodel_service_client_config.json +34 -0
  230. package/build/src/v1/mobile_device_submodel_service_proto_list.json +127 -0
  231. package/build/src/v1/network_service_client.d.ts +555 -12
  232. package/build/src/v1/network_service_client.js +757 -16
  233. package/build/src/v1/network_service_client.js.map +1 -1
  234. package/build/src/v1/network_service_proto_list.json +54 -1
  235. package/build/src/v1/operating_system_service_client.d.ts +468 -3
  236. package/build/src/v1/operating_system_service_client.js +661 -3
  237. package/build/src/v1/operating_system_service_client.js.map +1 -1
  238. package/build/src/v1/operating_system_service_proto_list.json +54 -1
  239. package/build/src/v1/operating_system_version_service_client.d.ts +468 -3
  240. package/build/src/v1/operating_system_version_service_client.js +661 -3
  241. package/build/src/v1/operating_system_version_service_client.js.map +1 -1
  242. package/build/src/v1/operating_system_version_service_proto_list.json +54 -1
  243. package/build/src/v1/order_service_client.d.ts +471 -6
  244. package/build/src/v1/order_service_client.js +663 -5
  245. package/build/src/v1/order_service_client.js.map +1 -1
  246. package/build/src/v1/order_service_proto_list.json +54 -1
  247. package/build/src/v1/placement_service_client.d.ts +662 -6
  248. package/build/src/v1/placement_service_client.js +962 -52
  249. package/build/src/v1/placement_service_client.js.map +1 -1
  250. package/build/src/v1/placement_service_client_config.json +28 -0
  251. package/build/src/v1/placement_service_proto_list.json +54 -1
  252. package/build/src/v1/private_auction_deal_service_client.d.ts +468 -3
  253. package/build/src/v1/private_auction_deal_service_client.js +661 -3
  254. package/build/src/v1/private_auction_deal_service_client.js.map +1 -1
  255. package/build/src/v1/private_auction_deal_service_proto_list.json +54 -1
  256. package/build/src/v1/private_auction_service_client.d.ts +468 -3
  257. package/build/src/v1/private_auction_service_client.js +661 -3
  258. package/build/src/v1/private_auction_service_client.js.map +1 -1
  259. package/build/src/v1/private_auction_service_proto_list.json +54 -1
  260. package/build/src/v1/programmatic_buyer_service_client.d.ts +465 -0
  261. package/build/src/v1/programmatic_buyer_service_client.js +659 -1
  262. package/build/src/v1/programmatic_buyer_service_client.js.map +1 -1
  263. package/build/src/v1/programmatic_buyer_service_proto_list.json +54 -1
  264. package/build/src/v1/report_service_client.d.ts +485 -17
  265. package/build/src/v1/report_service_client.js +669 -9
  266. package/build/src/v1/report_service_client.js.map +1 -1
  267. package/build/src/v1/report_service_proto_list.json +54 -1
  268. package/build/src/v1/role_service_client.d.ts +471 -3
  269. package/build/src/v1/role_service_client.js +663 -3
  270. package/build/src/v1/role_service_client.js.map +1 -1
  271. package/build/src/v1/role_service_proto_list.json +54 -1
  272. package/build/src/v1/site_service_client.d.ts +1530 -0
  273. package/build/src/v1/site_service_client.js +2243 -0
  274. package/build/src/v1/site_service_client.js.map +1 -0
  275. package/build/src/v1/site_service_client_config.json +58 -0
  276. package/build/src/v1/site_service_proto_list.json +127 -0
  277. package/build/src/v1/taxonomy_category_service_client.d.ts +465 -0
  278. package/build/src/v1/taxonomy_category_service_client.js +659 -1
  279. package/build/src/v1/taxonomy_category_service_client.js.map +1 -1
  280. package/build/src/v1/taxonomy_category_service_proto_list.json +54 -1
  281. package/build/src/v1/team_service_client.d.ts +1532 -0
  282. package/build/src/v1/team_service_client.js +2243 -0
  283. package/build/src/v1/team_service_client.js.map +1 -0
  284. package/build/src/v1/team_service_client_config.json +58 -0
  285. package/build/src/v1/team_service_proto_list.json +127 -0
  286. package/build/src/v1/user_service_client.d.ts +465 -0
  287. package/build/src/v1/user_service_client.js +659 -1
  288. package/build/src/v1/user_service_client.js.map +1 -1
  289. package/build/src/v1/user_service_proto_list.json +54 -1
  290. package/package.json +10 -2
  291. package/LICENSE +0 -202
@@ -0,0 +1,2243 @@
1
+ "use strict";
2
+ // Copyright 2026 Google LLC
3
+ //
4
+ // Licensed under the Apache License, Version 2.0 (the "License");
5
+ // you may not use this file except in compliance with the License.
6
+ // You may obtain a copy of the License at
7
+ //
8
+ // https://www.apache.org/licenses/LICENSE-2.0
9
+ //
10
+ // Unless required by applicable law or agreed to in writing, software
11
+ // distributed under the License is distributed on an "AS IS" BASIS,
12
+ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ // See the License for the specific language governing permissions and
14
+ // limitations under the License.
15
+ //
16
+ // ** This file is automatically generated by gapic-generator-typescript. **
17
+ // ** https://github.com/googleapis/gapic-generator-typescript **
18
+ // ** All changes to this file may be overwritten. **
19
+ Object.defineProperty(exports, "__esModule", { value: true });
20
+ exports.SiteServiceClient = void 0;
21
+ const jsonProtos = require("../../protos/protos.json");
22
+ const google_gax_1 = require("google-gax");
23
+ /**
24
+ * Client JSON configuration object, loaded from
25
+ * `src/v1/site_service_client_config.json`.
26
+ * This file defines retry strategy and timeouts for all API methods in this library.
27
+ */
28
+ const gapicConfig = require("./site_service_client_config.json");
29
+ const version = require('../../../package.json').version;
30
+ /**
31
+ * Provides methods for handling `Site` objects.
32
+ * @class
33
+ * @memberof v1
34
+ */
35
+ class SiteServiceClient {
36
+ _terminated = false;
37
+ _opts;
38
+ _providedCustomServicePath;
39
+ _gaxModule;
40
+ _gaxGrpc;
41
+ _protos;
42
+ _defaults;
43
+ _universeDomain;
44
+ _servicePath;
45
+ _log = google_gax_1.loggingUtils.log('admanager');
46
+ auth;
47
+ descriptors = {
48
+ page: {},
49
+ stream: {},
50
+ longrunning: {},
51
+ batching: {},
52
+ };
53
+ warn;
54
+ innerApiCalls;
55
+ pathTemplates;
56
+ siteServiceStub;
57
+ /**
58
+ * Construct an instance of SiteServiceClient.
59
+ *
60
+ * @param {object} [options] - The configuration object.
61
+ * The options accepted by the constructor are described in detail
62
+ * in [this document](https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#creating-the-client-instance).
63
+ * The common options are:
64
+ * @param {object} [options.credentials] - Credentials object.
65
+ * @param {string} [options.credentials.client_email]
66
+ * @param {string} [options.credentials.private_key]
67
+ * @param {string} [options.email] - Account email address. Required when
68
+ * using a .pem or .p12 keyFilename.
69
+ * @param {string} [options.keyFilename] - Full path to the a .json, .pem, or
70
+ * .p12 key downloaded from the Google Developers Console. If you provide
71
+ * a path to a JSON file, the projectId option below is not necessary.
72
+ * NOTE: .pem and .p12 require you to specify options.email as well.
73
+ * @param {number} [options.port] - The port on which to connect to
74
+ * the remote host.
75
+ * @param {string} [options.projectId] - The project ID from the Google
76
+ * Developer's Console, e.g. 'grape-spaceship-123'. We will also check
77
+ * the environment variable GCLOUD_PROJECT for your project ID. If your
78
+ * app is running in an environment which supports
79
+ * {@link https://cloud.google.com/docs/authentication/application-default-credentials Application Default Credentials},
80
+ * your project ID will be detected automatically.
81
+ * @param {string} [options.apiEndpoint] - The domain name of the
82
+ * API remote host.
83
+ * @param {gax.ClientConfig} [options.clientConfig] - Client configuration override.
84
+ * Follows the structure of {@link gapicConfig}.
85
+ * @param {boolean} [options.fallback] - Use HTTP/1.1 REST mode.
86
+ * For more information, please check the
87
+ * {@link https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#http11-rest-api-mode documentation}.
88
+ * @param {gax} [gaxInstance]: loaded instance of `google-gax`. Useful if you
89
+ * need to avoid loading the default gRPC version and want to use the fallback
90
+ * HTTP implementation. Load only fallback version and pass it to the constructor:
91
+ * ```
92
+ * const gax = require('google-gax/build/src/fallback'); // avoids loading google-gax with gRPC
93
+ * const client = new SiteServiceClient({fallback: true}, gax);
94
+ * ```
95
+ */
96
+ constructor(opts, gaxInstance) {
97
+ // Ensure that options include all the required fields.
98
+ const staticMembers = this.constructor;
99
+ if (opts?.universe_domain && opts?.universeDomain && opts?.universe_domain !== opts?.universeDomain) {
100
+ throw new Error('Please set either universe_domain or universeDomain, but not both.');
101
+ }
102
+ const universeDomainEnvVar = (typeof process === 'object' && typeof process.env === 'object') ? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] : undefined;
103
+ this._universeDomain = opts?.universeDomain ?? opts?.universe_domain ?? universeDomainEnvVar ?? 'googleapis.com';
104
+ this._servicePath = 'admanager.' + this._universeDomain;
105
+ const servicePath = opts?.servicePath || opts?.apiEndpoint || this._servicePath;
106
+ this._providedCustomServicePath = !!(opts?.servicePath || opts?.apiEndpoint);
107
+ const port = opts?.port || staticMembers.port;
108
+ const clientConfig = opts?.clientConfig ?? {};
109
+ // Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute).
110
+ if (!opts) {
111
+ opts = { fallback: true };
112
+ }
113
+ else {
114
+ opts.fallback = opts.fallback ?? true;
115
+ }
116
+ const fallback = opts?.fallback ?? (typeof window !== 'undefined' && typeof window?.fetch === 'function');
117
+ opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
118
+ // Request numeric enum values if REST transport is used.
119
+ opts.numericEnums = true;
120
+ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case.
121
+ if (servicePath !== this._servicePath && !('scopes' in opts)) {
122
+ opts['scopes'] = staticMembers.scopes;
123
+ }
124
+ // Load google-gax module synchronously if needed
125
+ if (!gaxInstance) {
126
+ gaxInstance = require('google-gax');
127
+ }
128
+ // Choose either gRPC or proto-over-HTTP implementation of google-gax.
129
+ this._gaxModule = opts.fallback ? gaxInstance.fallback : gaxInstance;
130
+ // Create a `gaxGrpc` object, with any grpc-specific options sent to the client.
131
+ this._gaxGrpc = new this._gaxModule.GrpcClient(opts);
132
+ // Save options to use in initialize() method.
133
+ this._opts = opts;
134
+ // Save the auth object to the client, for use by other methods.
135
+ this.auth = this._gaxGrpc.auth;
136
+ // Set useJWTAccessWithScope on the auth object.
137
+ this.auth.useJWTAccessWithScope = true;
138
+ // Set defaultServicePath on the auth object.
139
+ this.auth.defaultServicePath = this._servicePath;
140
+ // Set the default scopes in auth client if needed.
141
+ if (servicePath === this._servicePath) {
142
+ this.auth.defaultScopes = staticMembers.scopes;
143
+ }
144
+ // Determine the client header string.
145
+ const clientHeader = [
146
+ `gax/${this._gaxModule.version}`,
147
+ `gapic/${version}`,
148
+ ];
149
+ if (typeof process === 'object' && 'versions' in process) {
150
+ clientHeader.push(`gl-node/${process.versions.node}`);
151
+ }
152
+ else {
153
+ clientHeader.push(`gl-web/${this._gaxModule.version}`);
154
+ }
155
+ if (!opts.fallback) {
156
+ clientHeader.push(`grpc/${this._gaxGrpc.grpcVersion}`);
157
+ }
158
+ else {
159
+ clientHeader.push(`rest/${this._gaxGrpc.grpcVersion}`);
160
+ }
161
+ if (opts.libName && opts.libVersion) {
162
+ clientHeader.push(`${opts.libName}/${opts.libVersion}`);
163
+ }
164
+ // Load the applicable protos.
165
+ this._protos = this._gaxGrpc.loadProtoJSON(jsonProtos);
166
+ // This API contains "path templates"; forward-slash-separated
167
+ // identifiers to uniquely identify resources within the API.
168
+ // Create useful helper objects for these.
169
+ this.pathTemplates = {
170
+ adBreakPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/liveStreamEventsByAssetKey/{asset_key}/adBreaks/{ad_break}'),
171
+ adReviewCenterAdPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/webProperties/{web_property_code}/adReviewCenterAds/{ad_review_center_ad}'),
172
+ adUnitPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/adUnits/{ad_unit}'),
173
+ applicationPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/applications/{application}'),
174
+ audienceSegmentPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/audienceSegments/{audience_segment}'),
175
+ bandwidthGroupPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/bandwidthGroups/{bandwidth_group}'),
176
+ browserPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/browsers/{browser}'),
177
+ browserLanguagePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/browserLanguages/{browser_language}'),
178
+ cmsMetadataKeyPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/cmsMetadataKeys/{cms_metadata_key}'),
179
+ cmsMetadataValuePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/cmsMetadataValues/{cms_metadata_value}'),
180
+ companyPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/companies/{company}'),
181
+ contactPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/contacts/{contact}'),
182
+ contentPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/content/{content}'),
183
+ contentBundlePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/contentBundles/{content_bundle}'),
184
+ contentLabelPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/contentLabels/{content_label}'),
185
+ creativeTemplatePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/creativeTemplates/{creative_template}'),
186
+ customFieldPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/customFields/{custom_field}'),
187
+ customTargetingKeyPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/customTargetingKeys/{custom_targeting_key}'),
188
+ customTargetingValuePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/customTargetingValues/{custom_targeting_value}'),
189
+ deviceCapabilityPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/deviceCapabilities/{device_capability}'),
190
+ deviceCategoryPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/deviceCategories/{device_category}'),
191
+ deviceManufacturerPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/deviceManufacturers/{device_manufacturer}'),
192
+ entitySignalsMappingPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/entitySignalsMappings/{entity_signals_mapping}'),
193
+ geoTargetPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/geoTargets/{geo_target}'),
194
+ labelPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/labels/{label}'),
195
+ lineItemPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/lineItems/{line_item}'),
196
+ liveStreamEventPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/liveStreamEvents/{live_stream_event}'),
197
+ mobileCarrierPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/mobileCarriers/{mobile_carrier}'),
198
+ mobileDevicePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/mobileDevices/{mobile_device}'),
199
+ mobileDeviceSubmodelPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/mobileDeviceSubmodels/{mobile_device_submodel}'),
200
+ networkPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}'),
201
+ operatingSystemPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/operatingSystems/{operating_system}'),
202
+ operatingSystemVersionPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/operatingSystemVersions/{operating_system_version}'),
203
+ orderPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/orders/{order}'),
204
+ placementPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/placements/{placement}'),
205
+ privateAuctionPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/privateAuctions/{private_auction}'),
206
+ privateAuctionDealPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/privateAuctionDeals/{private_auction_deal}'),
207
+ programmaticBuyerPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/programmaticBuyers/{programmatic_buyer}'),
208
+ reportPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/reports/{report}'),
209
+ rolePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/roles/{role}'),
210
+ sitePathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/sites/{site}'),
211
+ taxonomyCategoryPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/taxonomyCategories/{taxonomy_category}'),
212
+ teamPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/teams/{team}'),
213
+ userPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/users/{user}'),
214
+ webPropertyPathTemplate: new this._gaxModule.PathTemplate('networks/{network_code}/webProperties/{web_property}'),
215
+ };
216
+ // Some of the methods on this service return "paged" results,
217
+ // (e.g. 50 results at a time, with tokens to get subsequent
218
+ // pages). Denote the keys used for pagination and results.
219
+ this.descriptors.page = {
220
+ listSites: new this._gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'sites')
221
+ };
222
+ // Put together the default options sent with requests.
223
+ this._defaults = this._gaxGrpc.constructSettings('google.ads.admanager.v1.SiteService', gapicConfig, opts.clientConfig || {}, { 'x-goog-api-client': clientHeader.join(' ') });
224
+ // Set up a dictionary of "inner API calls"; the core implementation
225
+ // of calling the API is handled in `google-gax`, with this code
226
+ // merely providing the destination and request information.
227
+ this.innerApiCalls = {};
228
+ // Add a warn function to the client constructor so it can be easily tested.
229
+ this.warn = this._gaxModule.warn;
230
+ }
231
+ /**
232
+ * Initialize the client.
233
+ * Performs asynchronous operations (such as authentication) and prepares the client.
234
+ * This function will be called automatically when any class method is called for the
235
+ * first time, but if you need to initialize it before calling an actual method,
236
+ * feel free to call initialize() directly.
237
+ *
238
+ * You can await on this method if you want to make sure the client is initialized.
239
+ *
240
+ * @returns {Promise} A promise that resolves to an authenticated service stub.
241
+ */
242
+ initialize() {
243
+ // If the client stub promise is already initialized, return immediately.
244
+ if (this.siteServiceStub) {
245
+ return this.siteServiceStub;
246
+ }
247
+ // Put together the "service stub" for
248
+ // google.ads.admanager.v1.SiteService.
249
+ this.siteServiceStub = this._gaxGrpc.createStub(this._opts.fallback ?
250
+ this._protos.lookupService('google.ads.admanager.v1.SiteService') :
251
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
252
+ this._protos.google.ads.admanager.v1.SiteService, this._opts, this._providedCustomServicePath);
253
+ // Iterate over each of the methods that the service provides
254
+ // and create an API call method for each.
255
+ const siteServiceStubMethods = ['getSite', 'listSites', 'createSite', 'batchCreateSites', 'updateSite', 'batchUpdateSites', 'batchDeactivateSites', 'batchSubmitSitesForApproval'];
256
+ for (const methodName of siteServiceStubMethods) {
257
+ const callPromise = this.siteServiceStub.then(stub => (...args) => {
258
+ if (this._terminated) {
259
+ return Promise.reject('The client has already been closed.');
260
+ }
261
+ const func = stub[methodName];
262
+ return func.apply(stub, args);
263
+ }, (err) => () => {
264
+ throw err;
265
+ });
266
+ const descriptor = this.descriptors.page[methodName] ||
267
+ undefined;
268
+ const apiCall = this._gaxModule.createApiCall(callPromise, this._defaults[methodName], descriptor, this._opts.fallback);
269
+ this.innerApiCalls[methodName] = apiCall;
270
+ }
271
+ return this.siteServiceStub;
272
+ }
273
+ /**
274
+ * The DNS address for this API service.
275
+ * @deprecated Use the apiEndpoint method of the client instance.
276
+ * @returns {string} The DNS address for this service.
277
+ */
278
+ static get servicePath() {
279
+ if (typeof process === 'object' && typeof process.emitWarning === 'function') {
280
+ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
281
+ }
282
+ return 'admanager.googleapis.com';
283
+ }
284
+ /**
285
+ * The DNS address for this API service - same as servicePath.
286
+ * @deprecated Use the apiEndpoint method of the client instance.
287
+ * @returns {string} The DNS address for this service.
288
+ */
289
+ static get apiEndpoint() {
290
+ if (typeof process === 'object' && typeof process.emitWarning === 'function') {
291
+ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
292
+ }
293
+ return 'admanager.googleapis.com';
294
+ }
295
+ /**
296
+ * The DNS address for this API service.
297
+ * @returns {string} The DNS address for this service.
298
+ */
299
+ get apiEndpoint() {
300
+ return this._servicePath;
301
+ }
302
+ get universeDomain() {
303
+ return this._universeDomain;
304
+ }
305
+ /**
306
+ * The port for this API service.
307
+ * @returns {number} The default port for this service.
308
+ */
309
+ static get port() {
310
+ return 443;
311
+ }
312
+ /**
313
+ * The scopes needed to make gRPC calls for every method defined
314
+ * in this service.
315
+ * @returns {string[]} List of default scopes.
316
+ */
317
+ static get scopes() {
318
+ return [
319
+ 'https://www.googleapis.com/auth/admanager'
320
+ ];
321
+ }
322
+ /**
323
+ * Return the project ID used by this class.
324
+ * @returns {Promise} A promise that resolves to string containing the project ID.
325
+ */
326
+ getProjectId(callback) {
327
+ if (callback) {
328
+ this.auth.getProjectId(callback);
329
+ return;
330
+ }
331
+ return this.auth.getProjectId();
332
+ }
333
+ getSite(request, optionsOrCallback, callback) {
334
+ request = request || {};
335
+ let options;
336
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
337
+ callback = optionsOrCallback;
338
+ options = {};
339
+ }
340
+ else {
341
+ options = optionsOrCallback;
342
+ }
343
+ options = options || {};
344
+ options.otherArgs = options.otherArgs || {};
345
+ options.otherArgs.headers = options.otherArgs.headers || {};
346
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
347
+ 'name': request.name ?? '',
348
+ });
349
+ this.initialize().catch(err => { throw err; });
350
+ this._log.info('getSite request %j', request);
351
+ const wrappedCallback = callback
352
+ ? (error, response, options, rawResponse) => {
353
+ this._log.info('getSite response %j', response);
354
+ callback(error, response, options, rawResponse); // We verified callback above.
355
+ }
356
+ : undefined;
357
+ return this.innerApiCalls.getSite(request, options, wrappedCallback)
358
+ ?.then(([response, options, rawResponse]) => {
359
+ this._log.info('getSite response %j', response);
360
+ return [response, options, rawResponse];
361
+ }).catch((error) => {
362
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
363
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
364
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
365
+ }
366
+ throw error;
367
+ });
368
+ }
369
+ createSite(request, optionsOrCallback, callback) {
370
+ request = request || {};
371
+ let options;
372
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
373
+ callback = optionsOrCallback;
374
+ options = {};
375
+ }
376
+ else {
377
+ options = optionsOrCallback;
378
+ }
379
+ options = options || {};
380
+ options.otherArgs = options.otherArgs || {};
381
+ options.otherArgs.headers = options.otherArgs.headers || {};
382
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
383
+ 'parent': request.parent ?? '',
384
+ });
385
+ this.initialize().catch(err => { throw err; });
386
+ this._log.info('createSite request %j', request);
387
+ const wrappedCallback = callback
388
+ ? (error, response, options, rawResponse) => {
389
+ this._log.info('createSite response %j', response);
390
+ callback(error, response, options, rawResponse); // We verified callback above.
391
+ }
392
+ : undefined;
393
+ return this.innerApiCalls.createSite(request, options, wrappedCallback)
394
+ ?.then(([response, options, rawResponse]) => {
395
+ this._log.info('createSite response %j', response);
396
+ return [response, options, rawResponse];
397
+ }).catch((error) => {
398
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
399
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
400
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
401
+ }
402
+ throw error;
403
+ });
404
+ }
405
+ batchCreateSites(request, optionsOrCallback, callback) {
406
+ request = request || {};
407
+ let options;
408
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
409
+ callback = optionsOrCallback;
410
+ options = {};
411
+ }
412
+ else {
413
+ options = optionsOrCallback;
414
+ }
415
+ options = options || {};
416
+ options.otherArgs = options.otherArgs || {};
417
+ options.otherArgs.headers = options.otherArgs.headers || {};
418
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
419
+ 'parent': request.parent ?? '',
420
+ });
421
+ this.initialize().catch(err => { throw err; });
422
+ this._log.info('batchCreateSites request %j', request);
423
+ const wrappedCallback = callback
424
+ ? (error, response, options, rawResponse) => {
425
+ this._log.info('batchCreateSites response %j', response);
426
+ callback(error, response, options, rawResponse); // We verified callback above.
427
+ }
428
+ : undefined;
429
+ return this.innerApiCalls.batchCreateSites(request, options, wrappedCallback)
430
+ ?.then(([response, options, rawResponse]) => {
431
+ this._log.info('batchCreateSites response %j', response);
432
+ return [response, options, rawResponse];
433
+ }).catch((error) => {
434
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
435
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
436
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
437
+ }
438
+ throw error;
439
+ });
440
+ }
441
+ updateSite(request, optionsOrCallback, callback) {
442
+ request = request || {};
443
+ let options;
444
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
445
+ callback = optionsOrCallback;
446
+ options = {};
447
+ }
448
+ else {
449
+ options = optionsOrCallback;
450
+ }
451
+ options = options || {};
452
+ options.otherArgs = options.otherArgs || {};
453
+ options.otherArgs.headers = options.otherArgs.headers || {};
454
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
455
+ 'site.name': request.site.name ?? '',
456
+ });
457
+ this.initialize().catch(err => { throw err; });
458
+ this._log.info('updateSite request %j', request);
459
+ const wrappedCallback = callback
460
+ ? (error, response, options, rawResponse) => {
461
+ this._log.info('updateSite response %j', response);
462
+ callback(error, response, options, rawResponse); // We verified callback above.
463
+ }
464
+ : undefined;
465
+ return this.innerApiCalls.updateSite(request, options, wrappedCallback)
466
+ ?.then(([response, options, rawResponse]) => {
467
+ this._log.info('updateSite response %j', response);
468
+ return [response, options, rawResponse];
469
+ }).catch((error) => {
470
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
471
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
472
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
473
+ }
474
+ throw error;
475
+ });
476
+ }
477
+ batchUpdateSites(request, optionsOrCallback, callback) {
478
+ request = request || {};
479
+ let options;
480
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
481
+ callback = optionsOrCallback;
482
+ options = {};
483
+ }
484
+ else {
485
+ options = optionsOrCallback;
486
+ }
487
+ options = options || {};
488
+ options.otherArgs = options.otherArgs || {};
489
+ options.otherArgs.headers = options.otherArgs.headers || {};
490
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
491
+ 'parent': request.parent ?? '',
492
+ });
493
+ this.initialize().catch(err => { throw err; });
494
+ this._log.info('batchUpdateSites request %j', request);
495
+ const wrappedCallback = callback
496
+ ? (error, response, options, rawResponse) => {
497
+ this._log.info('batchUpdateSites response %j', response);
498
+ callback(error, response, options, rawResponse); // We verified callback above.
499
+ }
500
+ : undefined;
501
+ return this.innerApiCalls.batchUpdateSites(request, options, wrappedCallback)
502
+ ?.then(([response, options, rawResponse]) => {
503
+ this._log.info('batchUpdateSites response %j', response);
504
+ return [response, options, rawResponse];
505
+ }).catch((error) => {
506
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
507
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
508
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
509
+ }
510
+ throw error;
511
+ });
512
+ }
513
+ batchDeactivateSites(request, optionsOrCallback, callback) {
514
+ request = request || {};
515
+ let options;
516
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
517
+ callback = optionsOrCallback;
518
+ options = {};
519
+ }
520
+ else {
521
+ options = optionsOrCallback;
522
+ }
523
+ options = options || {};
524
+ options.otherArgs = options.otherArgs || {};
525
+ options.otherArgs.headers = options.otherArgs.headers || {};
526
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
527
+ 'parent': request.parent ?? '',
528
+ });
529
+ this.initialize().catch(err => { throw err; });
530
+ this._log.info('batchDeactivateSites request %j', request);
531
+ const wrappedCallback = callback
532
+ ? (error, response, options, rawResponse) => {
533
+ this._log.info('batchDeactivateSites response %j', response);
534
+ callback(error, response, options, rawResponse); // We verified callback above.
535
+ }
536
+ : undefined;
537
+ return this.innerApiCalls.batchDeactivateSites(request, options, wrappedCallback)
538
+ ?.then(([response, options, rawResponse]) => {
539
+ this._log.info('batchDeactivateSites response %j', response);
540
+ return [response, options, rawResponse];
541
+ }).catch((error) => {
542
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
543
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
544
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
545
+ }
546
+ throw error;
547
+ });
548
+ }
549
+ batchSubmitSitesForApproval(request, optionsOrCallback, callback) {
550
+ request = request || {};
551
+ let options;
552
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
553
+ callback = optionsOrCallback;
554
+ options = {};
555
+ }
556
+ else {
557
+ options = optionsOrCallback;
558
+ }
559
+ options = options || {};
560
+ options.otherArgs = options.otherArgs || {};
561
+ options.otherArgs.headers = options.otherArgs.headers || {};
562
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
563
+ 'parent': request.parent ?? '',
564
+ });
565
+ this.initialize().catch(err => { throw err; });
566
+ this._log.info('batchSubmitSitesForApproval request %j', request);
567
+ const wrappedCallback = callback
568
+ ? (error, response, options, rawResponse) => {
569
+ this._log.info('batchSubmitSitesForApproval response %j', response);
570
+ callback(error, response, options, rawResponse); // We verified callback above.
571
+ }
572
+ : undefined;
573
+ return this.innerApiCalls.batchSubmitSitesForApproval(request, options, wrappedCallback)
574
+ ?.then(([response, options, rawResponse]) => {
575
+ this._log.info('batchSubmitSitesForApproval response %j', response);
576
+ return [response, options, rawResponse];
577
+ }).catch((error) => {
578
+ if (error && 'statusDetails' in error && error.statusDetails instanceof Array) {
579
+ const protos = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
580
+ error.statusDetails = (0, google_gax_1.decodeAnyProtosInArray)(error.statusDetails, protos);
581
+ }
582
+ throw error;
583
+ });
584
+ }
585
+ listSites(request, optionsOrCallback, callback) {
586
+ request = request || {};
587
+ let options;
588
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
589
+ callback = optionsOrCallback;
590
+ options = {};
591
+ }
592
+ else {
593
+ options = optionsOrCallback;
594
+ }
595
+ options = options || {};
596
+ options.otherArgs = options.otherArgs || {};
597
+ options.otherArgs.headers = options.otherArgs.headers || {};
598
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
599
+ 'parent': request.parent ?? '',
600
+ });
601
+ this.initialize().catch(err => { throw err; });
602
+ const wrappedCallback = callback
603
+ ? (error, values, nextPageRequest, rawResponse) => {
604
+ this._log.info('listSites values %j', values);
605
+ callback(error, values, nextPageRequest, rawResponse); // We verified callback above.
606
+ }
607
+ : undefined;
608
+ this._log.info('listSites request %j', request);
609
+ return this.innerApiCalls
610
+ .listSites(request, options, wrappedCallback)
611
+ ?.then(([response, input, output]) => {
612
+ this._log.info('listSites values %j', response);
613
+ return [response, input, output];
614
+ });
615
+ }
616
+ /**
617
+ * Equivalent to `listSites`, but returns a NodeJS Stream object.
618
+ * @param {Object} request
619
+ * The request object that will be sent.
620
+ * @param {string} request.parent
621
+ * Required. The parent, which owns this collection of Sites.
622
+ * Format: `networks/{network_code}`
623
+ * @param {number} [request.pageSize]
624
+ * Optional. The maximum number of `Sites` to return. The service may return
625
+ * fewer than this value. If unspecified, at most 50 `Sites` will be returned.
626
+ * The maximum value is 1000; values greater than 1000 will be coerced to
627
+ * 1000.
628
+ * @param {string} [request.pageToken]
629
+ * Optional. A page token, received from a previous `ListSites` call.
630
+ * Provide this to retrieve the subsequent page.
631
+ *
632
+ * When paginating, all other parameters provided to `ListSites` must match
633
+ * the call that provided the page token.
634
+ * @param {string} [request.filter]
635
+ * Optional. Expression to filter the response.
636
+ * See syntax details at
637
+ * https://developers.google.com/ad-manager/api/beta/filters
638
+ * @param {string} [request.orderBy]
639
+ * Optional. Expression to specify sorting order.
640
+ * See syntax details at
641
+ * https://developers.google.com/ad-manager/api/beta/filters#order
642
+ * @param {number} [request.skip]
643
+ * Optional. Number of individual resources to skip while paginating.
644
+ * @param {object} [options]
645
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
646
+ * @returns {Stream}
647
+ * An object stream which emits an object representing {@link protos.google.ads.admanager.v1.Site|Site} on 'data' event.
648
+ * The client library will perform auto-pagination by default: it will call the API as many
649
+ * times as needed. Note that it can affect your quota.
650
+ * We recommend using `listSitesAsync()`
651
+ * method described below for async iteration which you can stop as needed.
652
+ * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination | documentation }
653
+ * for more details and examples.
654
+ */
655
+ listSitesStream(request, options) {
656
+ request = request || {};
657
+ options = options || {};
658
+ options.otherArgs = options.otherArgs || {};
659
+ options.otherArgs.headers = options.otherArgs.headers || {};
660
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
661
+ 'parent': request.parent ?? '',
662
+ });
663
+ const defaultCallSettings = this._defaults['listSites'];
664
+ const callSettings = defaultCallSettings.merge(options);
665
+ this.initialize().catch(err => { throw err; });
666
+ this._log.info('listSites stream %j', request);
667
+ return this.descriptors.page.listSites.createStream(this.innerApiCalls.listSites, request, callSettings);
668
+ }
669
+ /**
670
+ * Equivalent to `listSites`, but returns an iterable object.
671
+ *
672
+ * `for`-`await`-`of` syntax is used with the iterable to get response elements on-demand.
673
+ * @param {Object} request
674
+ * The request object that will be sent.
675
+ * @param {string} request.parent
676
+ * Required. The parent, which owns this collection of Sites.
677
+ * Format: `networks/{network_code}`
678
+ * @param {number} [request.pageSize]
679
+ * Optional. The maximum number of `Sites` to return. The service may return
680
+ * fewer than this value. If unspecified, at most 50 `Sites` will be returned.
681
+ * The maximum value is 1000; values greater than 1000 will be coerced to
682
+ * 1000.
683
+ * @param {string} [request.pageToken]
684
+ * Optional. A page token, received from a previous `ListSites` call.
685
+ * Provide this to retrieve the subsequent page.
686
+ *
687
+ * When paginating, all other parameters provided to `ListSites` must match
688
+ * the call that provided the page token.
689
+ * @param {string} [request.filter]
690
+ * Optional. Expression to filter the response.
691
+ * See syntax details at
692
+ * https://developers.google.com/ad-manager/api/beta/filters
693
+ * @param {string} [request.orderBy]
694
+ * Optional. Expression to specify sorting order.
695
+ * See syntax details at
696
+ * https://developers.google.com/ad-manager/api/beta/filters#order
697
+ * @param {number} [request.skip]
698
+ * Optional. Number of individual resources to skip while paginating.
699
+ * @param {object} [options]
700
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
701
+ * @returns {Object}
702
+ * An iterable Object that allows {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols | async iteration }.
703
+ * When you iterate the returned iterable, each element will be an object representing
704
+ * {@link protos.google.ads.admanager.v1.Site|Site}. The API will be called under the hood as needed, once per the page,
705
+ * so you can stop the iteration when you don't need more results.
706
+ * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination | documentation }
707
+ * for more details and examples.
708
+ * @example <caption>include:samples/generated/v1/site_service.list_sites.js</caption>
709
+ * region_tag:admanager_v1_generated_SiteService_ListSites_async
710
+ */
711
+ listSitesAsync(request, options) {
712
+ request = request || {};
713
+ options = options || {};
714
+ options.otherArgs = options.otherArgs || {};
715
+ options.otherArgs.headers = options.otherArgs.headers || {};
716
+ options.otherArgs.headers['x-goog-request-params'] = this._gaxModule.routingHeader.fromParams({
717
+ 'parent': request.parent ?? '',
718
+ });
719
+ const defaultCallSettings = this._defaults['listSites'];
720
+ const callSettings = defaultCallSettings.merge(options);
721
+ this.initialize().catch(err => { throw err; });
722
+ this._log.info('listSites iterate %j', request);
723
+ return this.descriptors.page.listSites.asyncIterate(this.innerApiCalls['listSites'], request, callSettings);
724
+ }
725
+ // --------------------
726
+ // -- Path templates --
727
+ // --------------------
728
+ /**
729
+ * Return a fully-qualified adBreak resource name string.
730
+ *
731
+ * @param {string} network_code
732
+ * @param {string} asset_key
733
+ * @param {string} ad_break
734
+ * @returns {string} Resource name string.
735
+ */
736
+ adBreakPath(networkCode, assetKey, adBreak) {
737
+ return this.pathTemplates.adBreakPathTemplate.render({
738
+ network_code: networkCode,
739
+ asset_key: assetKey,
740
+ ad_break: adBreak,
741
+ });
742
+ }
743
+ /**
744
+ * Parse the network_code from AdBreak resource.
745
+ *
746
+ * @param {string} adBreakName
747
+ * A fully-qualified path representing AdBreak resource.
748
+ * @returns {string} A string representing the network_code.
749
+ */
750
+ matchNetworkCodeFromAdBreakName(adBreakName) {
751
+ return this.pathTemplates.adBreakPathTemplate.match(adBreakName).network_code;
752
+ }
753
+ /**
754
+ * Parse the asset_key from AdBreak resource.
755
+ *
756
+ * @param {string} adBreakName
757
+ * A fully-qualified path representing AdBreak resource.
758
+ * @returns {string} A string representing the asset_key.
759
+ */
760
+ matchAssetKeyFromAdBreakName(adBreakName) {
761
+ return this.pathTemplates.adBreakPathTemplate.match(adBreakName).asset_key;
762
+ }
763
+ /**
764
+ * Parse the ad_break from AdBreak resource.
765
+ *
766
+ * @param {string} adBreakName
767
+ * A fully-qualified path representing AdBreak resource.
768
+ * @returns {string} A string representing the ad_break.
769
+ */
770
+ matchAdBreakFromAdBreakName(adBreakName) {
771
+ return this.pathTemplates.adBreakPathTemplate.match(adBreakName).ad_break;
772
+ }
773
+ /**
774
+ * Return a fully-qualified adReviewCenterAd resource name string.
775
+ *
776
+ * @param {string} network_code
777
+ * @param {string} web_property_code
778
+ * @param {string} ad_review_center_ad
779
+ * @returns {string} Resource name string.
780
+ */
781
+ adReviewCenterAdPath(networkCode, webPropertyCode, adReviewCenterAd) {
782
+ return this.pathTemplates.adReviewCenterAdPathTemplate.render({
783
+ network_code: networkCode,
784
+ web_property_code: webPropertyCode,
785
+ ad_review_center_ad: adReviewCenterAd,
786
+ });
787
+ }
788
+ /**
789
+ * Parse the network_code from AdReviewCenterAd resource.
790
+ *
791
+ * @param {string} adReviewCenterAdName
792
+ * A fully-qualified path representing AdReviewCenterAd resource.
793
+ * @returns {string} A string representing the network_code.
794
+ */
795
+ matchNetworkCodeFromAdReviewCenterAdName(adReviewCenterAdName) {
796
+ return this.pathTemplates.adReviewCenterAdPathTemplate.match(adReviewCenterAdName).network_code;
797
+ }
798
+ /**
799
+ * Parse the web_property_code from AdReviewCenterAd resource.
800
+ *
801
+ * @param {string} adReviewCenterAdName
802
+ * A fully-qualified path representing AdReviewCenterAd resource.
803
+ * @returns {string} A string representing the web_property_code.
804
+ */
805
+ matchWebPropertyCodeFromAdReviewCenterAdName(adReviewCenterAdName) {
806
+ return this.pathTemplates.adReviewCenterAdPathTemplate.match(adReviewCenterAdName).web_property_code;
807
+ }
808
+ /**
809
+ * Parse the ad_review_center_ad from AdReviewCenterAd resource.
810
+ *
811
+ * @param {string} adReviewCenterAdName
812
+ * A fully-qualified path representing AdReviewCenterAd resource.
813
+ * @returns {string} A string representing the ad_review_center_ad.
814
+ */
815
+ matchAdReviewCenterAdFromAdReviewCenterAdName(adReviewCenterAdName) {
816
+ return this.pathTemplates.adReviewCenterAdPathTemplate.match(adReviewCenterAdName).ad_review_center_ad;
817
+ }
818
+ /**
819
+ * Return a fully-qualified adUnit resource name string.
820
+ *
821
+ * @param {string} network_code
822
+ * @param {string} ad_unit
823
+ * @returns {string} Resource name string.
824
+ */
825
+ adUnitPath(networkCode, adUnit) {
826
+ return this.pathTemplates.adUnitPathTemplate.render({
827
+ network_code: networkCode,
828
+ ad_unit: adUnit,
829
+ });
830
+ }
831
+ /**
832
+ * Parse the network_code from AdUnit resource.
833
+ *
834
+ * @param {string} adUnitName
835
+ * A fully-qualified path representing AdUnit resource.
836
+ * @returns {string} A string representing the network_code.
837
+ */
838
+ matchNetworkCodeFromAdUnitName(adUnitName) {
839
+ return this.pathTemplates.adUnitPathTemplate.match(adUnitName).network_code;
840
+ }
841
+ /**
842
+ * Parse the ad_unit from AdUnit resource.
843
+ *
844
+ * @param {string} adUnitName
845
+ * A fully-qualified path representing AdUnit resource.
846
+ * @returns {string} A string representing the ad_unit.
847
+ */
848
+ matchAdUnitFromAdUnitName(adUnitName) {
849
+ return this.pathTemplates.adUnitPathTemplate.match(adUnitName).ad_unit;
850
+ }
851
+ /**
852
+ * Return a fully-qualified application resource name string.
853
+ *
854
+ * @param {string} network_code
855
+ * @param {string} application
856
+ * @returns {string} Resource name string.
857
+ */
858
+ applicationPath(networkCode, application) {
859
+ return this.pathTemplates.applicationPathTemplate.render({
860
+ network_code: networkCode,
861
+ application: application,
862
+ });
863
+ }
864
+ /**
865
+ * Parse the network_code from Application resource.
866
+ *
867
+ * @param {string} applicationName
868
+ * A fully-qualified path representing Application resource.
869
+ * @returns {string} A string representing the network_code.
870
+ */
871
+ matchNetworkCodeFromApplicationName(applicationName) {
872
+ return this.pathTemplates.applicationPathTemplate.match(applicationName).network_code;
873
+ }
874
+ /**
875
+ * Parse the application from Application resource.
876
+ *
877
+ * @param {string} applicationName
878
+ * A fully-qualified path representing Application resource.
879
+ * @returns {string} A string representing the application.
880
+ */
881
+ matchApplicationFromApplicationName(applicationName) {
882
+ return this.pathTemplates.applicationPathTemplate.match(applicationName).application;
883
+ }
884
+ /**
885
+ * Return a fully-qualified audienceSegment resource name string.
886
+ *
887
+ * @param {string} network_code
888
+ * @param {string} audience_segment
889
+ * @returns {string} Resource name string.
890
+ */
891
+ audienceSegmentPath(networkCode, audienceSegment) {
892
+ return this.pathTemplates.audienceSegmentPathTemplate.render({
893
+ network_code: networkCode,
894
+ audience_segment: audienceSegment,
895
+ });
896
+ }
897
+ /**
898
+ * Parse the network_code from AudienceSegment resource.
899
+ *
900
+ * @param {string} audienceSegmentName
901
+ * A fully-qualified path representing AudienceSegment resource.
902
+ * @returns {string} A string representing the network_code.
903
+ */
904
+ matchNetworkCodeFromAudienceSegmentName(audienceSegmentName) {
905
+ return this.pathTemplates.audienceSegmentPathTemplate.match(audienceSegmentName).network_code;
906
+ }
907
+ /**
908
+ * Parse the audience_segment from AudienceSegment resource.
909
+ *
910
+ * @param {string} audienceSegmentName
911
+ * A fully-qualified path representing AudienceSegment resource.
912
+ * @returns {string} A string representing the audience_segment.
913
+ */
914
+ matchAudienceSegmentFromAudienceSegmentName(audienceSegmentName) {
915
+ return this.pathTemplates.audienceSegmentPathTemplate.match(audienceSegmentName).audience_segment;
916
+ }
917
+ /**
918
+ * Return a fully-qualified bandwidthGroup resource name string.
919
+ *
920
+ * @param {string} network_code
921
+ * @param {string} bandwidth_group
922
+ * @returns {string} Resource name string.
923
+ */
924
+ bandwidthGroupPath(networkCode, bandwidthGroup) {
925
+ return this.pathTemplates.bandwidthGroupPathTemplate.render({
926
+ network_code: networkCode,
927
+ bandwidth_group: bandwidthGroup,
928
+ });
929
+ }
930
+ /**
931
+ * Parse the network_code from BandwidthGroup resource.
932
+ *
933
+ * @param {string} bandwidthGroupName
934
+ * A fully-qualified path representing BandwidthGroup resource.
935
+ * @returns {string} A string representing the network_code.
936
+ */
937
+ matchNetworkCodeFromBandwidthGroupName(bandwidthGroupName) {
938
+ return this.pathTemplates.bandwidthGroupPathTemplate.match(bandwidthGroupName).network_code;
939
+ }
940
+ /**
941
+ * Parse the bandwidth_group from BandwidthGroup resource.
942
+ *
943
+ * @param {string} bandwidthGroupName
944
+ * A fully-qualified path representing BandwidthGroup resource.
945
+ * @returns {string} A string representing the bandwidth_group.
946
+ */
947
+ matchBandwidthGroupFromBandwidthGroupName(bandwidthGroupName) {
948
+ return this.pathTemplates.bandwidthGroupPathTemplate.match(bandwidthGroupName).bandwidth_group;
949
+ }
950
+ /**
951
+ * Return a fully-qualified browser resource name string.
952
+ *
953
+ * @param {string} network_code
954
+ * @param {string} browser
955
+ * @returns {string} Resource name string.
956
+ */
957
+ browserPath(networkCode, browser) {
958
+ return this.pathTemplates.browserPathTemplate.render({
959
+ network_code: networkCode,
960
+ browser: browser,
961
+ });
962
+ }
963
+ /**
964
+ * Parse the network_code from Browser resource.
965
+ *
966
+ * @param {string} browserName
967
+ * A fully-qualified path representing Browser resource.
968
+ * @returns {string} A string representing the network_code.
969
+ */
970
+ matchNetworkCodeFromBrowserName(browserName) {
971
+ return this.pathTemplates.browserPathTemplate.match(browserName).network_code;
972
+ }
973
+ /**
974
+ * Parse the browser from Browser resource.
975
+ *
976
+ * @param {string} browserName
977
+ * A fully-qualified path representing Browser resource.
978
+ * @returns {string} A string representing the browser.
979
+ */
980
+ matchBrowserFromBrowserName(browserName) {
981
+ return this.pathTemplates.browserPathTemplate.match(browserName).browser;
982
+ }
983
+ /**
984
+ * Return a fully-qualified browserLanguage resource name string.
985
+ *
986
+ * @param {string} network_code
987
+ * @param {string} browser_language
988
+ * @returns {string} Resource name string.
989
+ */
990
+ browserLanguagePath(networkCode, browserLanguage) {
991
+ return this.pathTemplates.browserLanguagePathTemplate.render({
992
+ network_code: networkCode,
993
+ browser_language: browserLanguage,
994
+ });
995
+ }
996
+ /**
997
+ * Parse the network_code from BrowserLanguage resource.
998
+ *
999
+ * @param {string} browserLanguageName
1000
+ * A fully-qualified path representing BrowserLanguage resource.
1001
+ * @returns {string} A string representing the network_code.
1002
+ */
1003
+ matchNetworkCodeFromBrowserLanguageName(browserLanguageName) {
1004
+ return this.pathTemplates.browserLanguagePathTemplate.match(browserLanguageName).network_code;
1005
+ }
1006
+ /**
1007
+ * Parse the browser_language from BrowserLanguage resource.
1008
+ *
1009
+ * @param {string} browserLanguageName
1010
+ * A fully-qualified path representing BrowserLanguage resource.
1011
+ * @returns {string} A string representing the browser_language.
1012
+ */
1013
+ matchBrowserLanguageFromBrowserLanguageName(browserLanguageName) {
1014
+ return this.pathTemplates.browserLanguagePathTemplate.match(browserLanguageName).browser_language;
1015
+ }
1016
+ /**
1017
+ * Return a fully-qualified cmsMetadataKey resource name string.
1018
+ *
1019
+ * @param {string} network_code
1020
+ * @param {string} cms_metadata_key
1021
+ * @returns {string} Resource name string.
1022
+ */
1023
+ cmsMetadataKeyPath(networkCode, cmsMetadataKey) {
1024
+ return this.pathTemplates.cmsMetadataKeyPathTemplate.render({
1025
+ network_code: networkCode,
1026
+ cms_metadata_key: cmsMetadataKey,
1027
+ });
1028
+ }
1029
+ /**
1030
+ * Parse the network_code from CmsMetadataKey resource.
1031
+ *
1032
+ * @param {string} cmsMetadataKeyName
1033
+ * A fully-qualified path representing CmsMetadataKey resource.
1034
+ * @returns {string} A string representing the network_code.
1035
+ */
1036
+ matchNetworkCodeFromCmsMetadataKeyName(cmsMetadataKeyName) {
1037
+ return this.pathTemplates.cmsMetadataKeyPathTemplate.match(cmsMetadataKeyName).network_code;
1038
+ }
1039
+ /**
1040
+ * Parse the cms_metadata_key from CmsMetadataKey resource.
1041
+ *
1042
+ * @param {string} cmsMetadataKeyName
1043
+ * A fully-qualified path representing CmsMetadataKey resource.
1044
+ * @returns {string} A string representing the cms_metadata_key.
1045
+ */
1046
+ matchCmsMetadataKeyFromCmsMetadataKeyName(cmsMetadataKeyName) {
1047
+ return this.pathTemplates.cmsMetadataKeyPathTemplate.match(cmsMetadataKeyName).cms_metadata_key;
1048
+ }
1049
+ /**
1050
+ * Return a fully-qualified cmsMetadataValue resource name string.
1051
+ *
1052
+ * @param {string} network_code
1053
+ * @param {string} cms_metadata_value
1054
+ * @returns {string} Resource name string.
1055
+ */
1056
+ cmsMetadataValuePath(networkCode, cmsMetadataValue) {
1057
+ return this.pathTemplates.cmsMetadataValuePathTemplate.render({
1058
+ network_code: networkCode,
1059
+ cms_metadata_value: cmsMetadataValue,
1060
+ });
1061
+ }
1062
+ /**
1063
+ * Parse the network_code from CmsMetadataValue resource.
1064
+ *
1065
+ * @param {string} cmsMetadataValueName
1066
+ * A fully-qualified path representing CmsMetadataValue resource.
1067
+ * @returns {string} A string representing the network_code.
1068
+ */
1069
+ matchNetworkCodeFromCmsMetadataValueName(cmsMetadataValueName) {
1070
+ return this.pathTemplates.cmsMetadataValuePathTemplate.match(cmsMetadataValueName).network_code;
1071
+ }
1072
+ /**
1073
+ * Parse the cms_metadata_value from CmsMetadataValue resource.
1074
+ *
1075
+ * @param {string} cmsMetadataValueName
1076
+ * A fully-qualified path representing CmsMetadataValue resource.
1077
+ * @returns {string} A string representing the cms_metadata_value.
1078
+ */
1079
+ matchCmsMetadataValueFromCmsMetadataValueName(cmsMetadataValueName) {
1080
+ return this.pathTemplates.cmsMetadataValuePathTemplate.match(cmsMetadataValueName).cms_metadata_value;
1081
+ }
1082
+ /**
1083
+ * Return a fully-qualified company resource name string.
1084
+ *
1085
+ * @param {string} network_code
1086
+ * @param {string} company
1087
+ * @returns {string} Resource name string.
1088
+ */
1089
+ companyPath(networkCode, company) {
1090
+ return this.pathTemplates.companyPathTemplate.render({
1091
+ network_code: networkCode,
1092
+ company: company,
1093
+ });
1094
+ }
1095
+ /**
1096
+ * Parse the network_code from Company resource.
1097
+ *
1098
+ * @param {string} companyName
1099
+ * A fully-qualified path representing Company resource.
1100
+ * @returns {string} A string representing the network_code.
1101
+ */
1102
+ matchNetworkCodeFromCompanyName(companyName) {
1103
+ return this.pathTemplates.companyPathTemplate.match(companyName).network_code;
1104
+ }
1105
+ /**
1106
+ * Parse the company from Company resource.
1107
+ *
1108
+ * @param {string} companyName
1109
+ * A fully-qualified path representing Company resource.
1110
+ * @returns {string} A string representing the company.
1111
+ */
1112
+ matchCompanyFromCompanyName(companyName) {
1113
+ return this.pathTemplates.companyPathTemplate.match(companyName).company;
1114
+ }
1115
+ /**
1116
+ * Return a fully-qualified contact resource name string.
1117
+ *
1118
+ * @param {string} network_code
1119
+ * @param {string} contact
1120
+ * @returns {string} Resource name string.
1121
+ */
1122
+ contactPath(networkCode, contact) {
1123
+ return this.pathTemplates.contactPathTemplate.render({
1124
+ network_code: networkCode,
1125
+ contact: contact,
1126
+ });
1127
+ }
1128
+ /**
1129
+ * Parse the network_code from Contact resource.
1130
+ *
1131
+ * @param {string} contactName
1132
+ * A fully-qualified path representing Contact resource.
1133
+ * @returns {string} A string representing the network_code.
1134
+ */
1135
+ matchNetworkCodeFromContactName(contactName) {
1136
+ return this.pathTemplates.contactPathTemplate.match(contactName).network_code;
1137
+ }
1138
+ /**
1139
+ * Parse the contact from Contact resource.
1140
+ *
1141
+ * @param {string} contactName
1142
+ * A fully-qualified path representing Contact resource.
1143
+ * @returns {string} A string representing the contact.
1144
+ */
1145
+ matchContactFromContactName(contactName) {
1146
+ return this.pathTemplates.contactPathTemplate.match(contactName).contact;
1147
+ }
1148
+ /**
1149
+ * Return a fully-qualified content resource name string.
1150
+ *
1151
+ * @param {string} network_code
1152
+ * @param {string} content
1153
+ * @returns {string} Resource name string.
1154
+ */
1155
+ contentPath(networkCode, content) {
1156
+ return this.pathTemplates.contentPathTemplate.render({
1157
+ network_code: networkCode,
1158
+ content: content,
1159
+ });
1160
+ }
1161
+ /**
1162
+ * Parse the network_code from Content resource.
1163
+ *
1164
+ * @param {string} contentName
1165
+ * A fully-qualified path representing Content resource.
1166
+ * @returns {string} A string representing the network_code.
1167
+ */
1168
+ matchNetworkCodeFromContentName(contentName) {
1169
+ return this.pathTemplates.contentPathTemplate.match(contentName).network_code;
1170
+ }
1171
+ /**
1172
+ * Parse the content from Content resource.
1173
+ *
1174
+ * @param {string} contentName
1175
+ * A fully-qualified path representing Content resource.
1176
+ * @returns {string} A string representing the content.
1177
+ */
1178
+ matchContentFromContentName(contentName) {
1179
+ return this.pathTemplates.contentPathTemplate.match(contentName).content;
1180
+ }
1181
+ /**
1182
+ * Return a fully-qualified contentBundle resource name string.
1183
+ *
1184
+ * @param {string} network_code
1185
+ * @param {string} content_bundle
1186
+ * @returns {string} Resource name string.
1187
+ */
1188
+ contentBundlePath(networkCode, contentBundle) {
1189
+ return this.pathTemplates.contentBundlePathTemplate.render({
1190
+ network_code: networkCode,
1191
+ content_bundle: contentBundle,
1192
+ });
1193
+ }
1194
+ /**
1195
+ * Parse the network_code from ContentBundle resource.
1196
+ *
1197
+ * @param {string} contentBundleName
1198
+ * A fully-qualified path representing ContentBundle resource.
1199
+ * @returns {string} A string representing the network_code.
1200
+ */
1201
+ matchNetworkCodeFromContentBundleName(contentBundleName) {
1202
+ return this.pathTemplates.contentBundlePathTemplate.match(contentBundleName).network_code;
1203
+ }
1204
+ /**
1205
+ * Parse the content_bundle from ContentBundle resource.
1206
+ *
1207
+ * @param {string} contentBundleName
1208
+ * A fully-qualified path representing ContentBundle resource.
1209
+ * @returns {string} A string representing the content_bundle.
1210
+ */
1211
+ matchContentBundleFromContentBundleName(contentBundleName) {
1212
+ return this.pathTemplates.contentBundlePathTemplate.match(contentBundleName).content_bundle;
1213
+ }
1214
+ /**
1215
+ * Return a fully-qualified contentLabel resource name string.
1216
+ *
1217
+ * @param {string} network_code
1218
+ * @param {string} content_label
1219
+ * @returns {string} Resource name string.
1220
+ */
1221
+ contentLabelPath(networkCode, contentLabel) {
1222
+ return this.pathTemplates.contentLabelPathTemplate.render({
1223
+ network_code: networkCode,
1224
+ content_label: contentLabel,
1225
+ });
1226
+ }
1227
+ /**
1228
+ * Parse the network_code from ContentLabel resource.
1229
+ *
1230
+ * @param {string} contentLabelName
1231
+ * A fully-qualified path representing ContentLabel resource.
1232
+ * @returns {string} A string representing the network_code.
1233
+ */
1234
+ matchNetworkCodeFromContentLabelName(contentLabelName) {
1235
+ return this.pathTemplates.contentLabelPathTemplate.match(contentLabelName).network_code;
1236
+ }
1237
+ /**
1238
+ * Parse the content_label from ContentLabel resource.
1239
+ *
1240
+ * @param {string} contentLabelName
1241
+ * A fully-qualified path representing ContentLabel resource.
1242
+ * @returns {string} A string representing the content_label.
1243
+ */
1244
+ matchContentLabelFromContentLabelName(contentLabelName) {
1245
+ return this.pathTemplates.contentLabelPathTemplate.match(contentLabelName).content_label;
1246
+ }
1247
+ /**
1248
+ * Return a fully-qualified creativeTemplate resource name string.
1249
+ *
1250
+ * @param {string} network_code
1251
+ * @param {string} creative_template
1252
+ * @returns {string} Resource name string.
1253
+ */
1254
+ creativeTemplatePath(networkCode, creativeTemplate) {
1255
+ return this.pathTemplates.creativeTemplatePathTemplate.render({
1256
+ network_code: networkCode,
1257
+ creative_template: creativeTemplate,
1258
+ });
1259
+ }
1260
+ /**
1261
+ * Parse the network_code from CreativeTemplate resource.
1262
+ *
1263
+ * @param {string} creativeTemplateName
1264
+ * A fully-qualified path representing CreativeTemplate resource.
1265
+ * @returns {string} A string representing the network_code.
1266
+ */
1267
+ matchNetworkCodeFromCreativeTemplateName(creativeTemplateName) {
1268
+ return this.pathTemplates.creativeTemplatePathTemplate.match(creativeTemplateName).network_code;
1269
+ }
1270
+ /**
1271
+ * Parse the creative_template from CreativeTemplate resource.
1272
+ *
1273
+ * @param {string} creativeTemplateName
1274
+ * A fully-qualified path representing CreativeTemplate resource.
1275
+ * @returns {string} A string representing the creative_template.
1276
+ */
1277
+ matchCreativeTemplateFromCreativeTemplateName(creativeTemplateName) {
1278
+ return this.pathTemplates.creativeTemplatePathTemplate.match(creativeTemplateName).creative_template;
1279
+ }
1280
+ /**
1281
+ * Return a fully-qualified customField resource name string.
1282
+ *
1283
+ * @param {string} network_code
1284
+ * @param {string} custom_field
1285
+ * @returns {string} Resource name string.
1286
+ */
1287
+ customFieldPath(networkCode, customField) {
1288
+ return this.pathTemplates.customFieldPathTemplate.render({
1289
+ network_code: networkCode,
1290
+ custom_field: customField,
1291
+ });
1292
+ }
1293
+ /**
1294
+ * Parse the network_code from CustomField resource.
1295
+ *
1296
+ * @param {string} customFieldName
1297
+ * A fully-qualified path representing CustomField resource.
1298
+ * @returns {string} A string representing the network_code.
1299
+ */
1300
+ matchNetworkCodeFromCustomFieldName(customFieldName) {
1301
+ return this.pathTemplates.customFieldPathTemplate.match(customFieldName).network_code;
1302
+ }
1303
+ /**
1304
+ * Parse the custom_field from CustomField resource.
1305
+ *
1306
+ * @param {string} customFieldName
1307
+ * A fully-qualified path representing CustomField resource.
1308
+ * @returns {string} A string representing the custom_field.
1309
+ */
1310
+ matchCustomFieldFromCustomFieldName(customFieldName) {
1311
+ return this.pathTemplates.customFieldPathTemplate.match(customFieldName).custom_field;
1312
+ }
1313
+ /**
1314
+ * Return a fully-qualified customTargetingKey resource name string.
1315
+ *
1316
+ * @param {string} network_code
1317
+ * @param {string} custom_targeting_key
1318
+ * @returns {string} Resource name string.
1319
+ */
1320
+ customTargetingKeyPath(networkCode, customTargetingKey) {
1321
+ return this.pathTemplates.customTargetingKeyPathTemplate.render({
1322
+ network_code: networkCode,
1323
+ custom_targeting_key: customTargetingKey,
1324
+ });
1325
+ }
1326
+ /**
1327
+ * Parse the network_code from CustomTargetingKey resource.
1328
+ *
1329
+ * @param {string} customTargetingKeyName
1330
+ * A fully-qualified path representing CustomTargetingKey resource.
1331
+ * @returns {string} A string representing the network_code.
1332
+ */
1333
+ matchNetworkCodeFromCustomTargetingKeyName(customTargetingKeyName) {
1334
+ return this.pathTemplates.customTargetingKeyPathTemplate.match(customTargetingKeyName).network_code;
1335
+ }
1336
+ /**
1337
+ * Parse the custom_targeting_key from CustomTargetingKey resource.
1338
+ *
1339
+ * @param {string} customTargetingKeyName
1340
+ * A fully-qualified path representing CustomTargetingKey resource.
1341
+ * @returns {string} A string representing the custom_targeting_key.
1342
+ */
1343
+ matchCustomTargetingKeyFromCustomTargetingKeyName(customTargetingKeyName) {
1344
+ return this.pathTemplates.customTargetingKeyPathTemplate.match(customTargetingKeyName).custom_targeting_key;
1345
+ }
1346
+ /**
1347
+ * Return a fully-qualified customTargetingValue resource name string.
1348
+ *
1349
+ * @param {string} network_code
1350
+ * @param {string} custom_targeting_value
1351
+ * @returns {string} Resource name string.
1352
+ */
1353
+ customTargetingValuePath(networkCode, customTargetingValue) {
1354
+ return this.pathTemplates.customTargetingValuePathTemplate.render({
1355
+ network_code: networkCode,
1356
+ custom_targeting_value: customTargetingValue,
1357
+ });
1358
+ }
1359
+ /**
1360
+ * Parse the network_code from CustomTargetingValue resource.
1361
+ *
1362
+ * @param {string} customTargetingValueName
1363
+ * A fully-qualified path representing CustomTargetingValue resource.
1364
+ * @returns {string} A string representing the network_code.
1365
+ */
1366
+ matchNetworkCodeFromCustomTargetingValueName(customTargetingValueName) {
1367
+ return this.pathTemplates.customTargetingValuePathTemplate.match(customTargetingValueName).network_code;
1368
+ }
1369
+ /**
1370
+ * Parse the custom_targeting_value from CustomTargetingValue resource.
1371
+ *
1372
+ * @param {string} customTargetingValueName
1373
+ * A fully-qualified path representing CustomTargetingValue resource.
1374
+ * @returns {string} A string representing the custom_targeting_value.
1375
+ */
1376
+ matchCustomTargetingValueFromCustomTargetingValueName(customTargetingValueName) {
1377
+ return this.pathTemplates.customTargetingValuePathTemplate.match(customTargetingValueName).custom_targeting_value;
1378
+ }
1379
+ /**
1380
+ * Return a fully-qualified deviceCapability resource name string.
1381
+ *
1382
+ * @param {string} network_code
1383
+ * @param {string} device_capability
1384
+ * @returns {string} Resource name string.
1385
+ */
1386
+ deviceCapabilityPath(networkCode, deviceCapability) {
1387
+ return this.pathTemplates.deviceCapabilityPathTemplate.render({
1388
+ network_code: networkCode,
1389
+ device_capability: deviceCapability,
1390
+ });
1391
+ }
1392
+ /**
1393
+ * Parse the network_code from DeviceCapability resource.
1394
+ *
1395
+ * @param {string} deviceCapabilityName
1396
+ * A fully-qualified path representing DeviceCapability resource.
1397
+ * @returns {string} A string representing the network_code.
1398
+ */
1399
+ matchNetworkCodeFromDeviceCapabilityName(deviceCapabilityName) {
1400
+ return this.pathTemplates.deviceCapabilityPathTemplate.match(deviceCapabilityName).network_code;
1401
+ }
1402
+ /**
1403
+ * Parse the device_capability from DeviceCapability resource.
1404
+ *
1405
+ * @param {string} deviceCapabilityName
1406
+ * A fully-qualified path representing DeviceCapability resource.
1407
+ * @returns {string} A string representing the device_capability.
1408
+ */
1409
+ matchDeviceCapabilityFromDeviceCapabilityName(deviceCapabilityName) {
1410
+ return this.pathTemplates.deviceCapabilityPathTemplate.match(deviceCapabilityName).device_capability;
1411
+ }
1412
+ /**
1413
+ * Return a fully-qualified deviceCategory resource name string.
1414
+ *
1415
+ * @param {string} network_code
1416
+ * @param {string} device_category
1417
+ * @returns {string} Resource name string.
1418
+ */
1419
+ deviceCategoryPath(networkCode, deviceCategory) {
1420
+ return this.pathTemplates.deviceCategoryPathTemplate.render({
1421
+ network_code: networkCode,
1422
+ device_category: deviceCategory,
1423
+ });
1424
+ }
1425
+ /**
1426
+ * Parse the network_code from DeviceCategory resource.
1427
+ *
1428
+ * @param {string} deviceCategoryName
1429
+ * A fully-qualified path representing DeviceCategory resource.
1430
+ * @returns {string} A string representing the network_code.
1431
+ */
1432
+ matchNetworkCodeFromDeviceCategoryName(deviceCategoryName) {
1433
+ return this.pathTemplates.deviceCategoryPathTemplate.match(deviceCategoryName).network_code;
1434
+ }
1435
+ /**
1436
+ * Parse the device_category from DeviceCategory resource.
1437
+ *
1438
+ * @param {string} deviceCategoryName
1439
+ * A fully-qualified path representing DeviceCategory resource.
1440
+ * @returns {string} A string representing the device_category.
1441
+ */
1442
+ matchDeviceCategoryFromDeviceCategoryName(deviceCategoryName) {
1443
+ return this.pathTemplates.deviceCategoryPathTemplate.match(deviceCategoryName).device_category;
1444
+ }
1445
+ /**
1446
+ * Return a fully-qualified deviceManufacturer resource name string.
1447
+ *
1448
+ * @param {string} network_code
1449
+ * @param {string} device_manufacturer
1450
+ * @returns {string} Resource name string.
1451
+ */
1452
+ deviceManufacturerPath(networkCode, deviceManufacturer) {
1453
+ return this.pathTemplates.deviceManufacturerPathTemplate.render({
1454
+ network_code: networkCode,
1455
+ device_manufacturer: deviceManufacturer,
1456
+ });
1457
+ }
1458
+ /**
1459
+ * Parse the network_code from DeviceManufacturer resource.
1460
+ *
1461
+ * @param {string} deviceManufacturerName
1462
+ * A fully-qualified path representing DeviceManufacturer resource.
1463
+ * @returns {string} A string representing the network_code.
1464
+ */
1465
+ matchNetworkCodeFromDeviceManufacturerName(deviceManufacturerName) {
1466
+ return this.pathTemplates.deviceManufacturerPathTemplate.match(deviceManufacturerName).network_code;
1467
+ }
1468
+ /**
1469
+ * Parse the device_manufacturer from DeviceManufacturer resource.
1470
+ *
1471
+ * @param {string} deviceManufacturerName
1472
+ * A fully-qualified path representing DeviceManufacturer resource.
1473
+ * @returns {string} A string representing the device_manufacturer.
1474
+ */
1475
+ matchDeviceManufacturerFromDeviceManufacturerName(deviceManufacturerName) {
1476
+ return this.pathTemplates.deviceManufacturerPathTemplate.match(deviceManufacturerName).device_manufacturer;
1477
+ }
1478
+ /**
1479
+ * Return a fully-qualified entitySignalsMapping resource name string.
1480
+ *
1481
+ * @param {string} network_code
1482
+ * @param {string} entity_signals_mapping
1483
+ * @returns {string} Resource name string.
1484
+ */
1485
+ entitySignalsMappingPath(networkCode, entitySignalsMapping) {
1486
+ return this.pathTemplates.entitySignalsMappingPathTemplate.render({
1487
+ network_code: networkCode,
1488
+ entity_signals_mapping: entitySignalsMapping,
1489
+ });
1490
+ }
1491
+ /**
1492
+ * Parse the network_code from EntitySignalsMapping resource.
1493
+ *
1494
+ * @param {string} entitySignalsMappingName
1495
+ * A fully-qualified path representing EntitySignalsMapping resource.
1496
+ * @returns {string} A string representing the network_code.
1497
+ */
1498
+ matchNetworkCodeFromEntitySignalsMappingName(entitySignalsMappingName) {
1499
+ return this.pathTemplates.entitySignalsMappingPathTemplate.match(entitySignalsMappingName).network_code;
1500
+ }
1501
+ /**
1502
+ * Parse the entity_signals_mapping from EntitySignalsMapping resource.
1503
+ *
1504
+ * @param {string} entitySignalsMappingName
1505
+ * A fully-qualified path representing EntitySignalsMapping resource.
1506
+ * @returns {string} A string representing the entity_signals_mapping.
1507
+ */
1508
+ matchEntitySignalsMappingFromEntitySignalsMappingName(entitySignalsMappingName) {
1509
+ return this.pathTemplates.entitySignalsMappingPathTemplate.match(entitySignalsMappingName).entity_signals_mapping;
1510
+ }
1511
+ /**
1512
+ * Return a fully-qualified geoTarget resource name string.
1513
+ *
1514
+ * @param {string} network_code
1515
+ * @param {string} geo_target
1516
+ * @returns {string} Resource name string.
1517
+ */
1518
+ geoTargetPath(networkCode, geoTarget) {
1519
+ return this.pathTemplates.geoTargetPathTemplate.render({
1520
+ network_code: networkCode,
1521
+ geo_target: geoTarget,
1522
+ });
1523
+ }
1524
+ /**
1525
+ * Parse the network_code from GeoTarget resource.
1526
+ *
1527
+ * @param {string} geoTargetName
1528
+ * A fully-qualified path representing GeoTarget resource.
1529
+ * @returns {string} A string representing the network_code.
1530
+ */
1531
+ matchNetworkCodeFromGeoTargetName(geoTargetName) {
1532
+ return this.pathTemplates.geoTargetPathTemplate.match(geoTargetName).network_code;
1533
+ }
1534
+ /**
1535
+ * Parse the geo_target from GeoTarget resource.
1536
+ *
1537
+ * @param {string} geoTargetName
1538
+ * A fully-qualified path representing GeoTarget resource.
1539
+ * @returns {string} A string representing the geo_target.
1540
+ */
1541
+ matchGeoTargetFromGeoTargetName(geoTargetName) {
1542
+ return this.pathTemplates.geoTargetPathTemplate.match(geoTargetName).geo_target;
1543
+ }
1544
+ /**
1545
+ * Return a fully-qualified label resource name string.
1546
+ *
1547
+ * @param {string} network_code
1548
+ * @param {string} label
1549
+ * @returns {string} Resource name string.
1550
+ */
1551
+ labelPath(networkCode, label) {
1552
+ return this.pathTemplates.labelPathTemplate.render({
1553
+ network_code: networkCode,
1554
+ label: label,
1555
+ });
1556
+ }
1557
+ /**
1558
+ * Parse the network_code from Label resource.
1559
+ *
1560
+ * @param {string} labelName
1561
+ * A fully-qualified path representing Label resource.
1562
+ * @returns {string} A string representing the network_code.
1563
+ */
1564
+ matchNetworkCodeFromLabelName(labelName) {
1565
+ return this.pathTemplates.labelPathTemplate.match(labelName).network_code;
1566
+ }
1567
+ /**
1568
+ * Parse the label from Label resource.
1569
+ *
1570
+ * @param {string} labelName
1571
+ * A fully-qualified path representing Label resource.
1572
+ * @returns {string} A string representing the label.
1573
+ */
1574
+ matchLabelFromLabelName(labelName) {
1575
+ return this.pathTemplates.labelPathTemplate.match(labelName).label;
1576
+ }
1577
+ /**
1578
+ * Return a fully-qualified lineItem resource name string.
1579
+ *
1580
+ * @param {string} network_code
1581
+ * @param {string} line_item
1582
+ * @returns {string} Resource name string.
1583
+ */
1584
+ lineItemPath(networkCode, lineItem) {
1585
+ return this.pathTemplates.lineItemPathTemplate.render({
1586
+ network_code: networkCode,
1587
+ line_item: lineItem,
1588
+ });
1589
+ }
1590
+ /**
1591
+ * Parse the network_code from LineItem resource.
1592
+ *
1593
+ * @param {string} lineItemName
1594
+ * A fully-qualified path representing LineItem resource.
1595
+ * @returns {string} A string representing the network_code.
1596
+ */
1597
+ matchNetworkCodeFromLineItemName(lineItemName) {
1598
+ return this.pathTemplates.lineItemPathTemplate.match(lineItemName).network_code;
1599
+ }
1600
+ /**
1601
+ * Parse the line_item from LineItem resource.
1602
+ *
1603
+ * @param {string} lineItemName
1604
+ * A fully-qualified path representing LineItem resource.
1605
+ * @returns {string} A string representing the line_item.
1606
+ */
1607
+ matchLineItemFromLineItemName(lineItemName) {
1608
+ return this.pathTemplates.lineItemPathTemplate.match(lineItemName).line_item;
1609
+ }
1610
+ /**
1611
+ * Return a fully-qualified liveStreamEvent resource name string.
1612
+ *
1613
+ * @param {string} network_code
1614
+ * @param {string} live_stream_event
1615
+ * @returns {string} Resource name string.
1616
+ */
1617
+ liveStreamEventPath(networkCode, liveStreamEvent) {
1618
+ return this.pathTemplates.liveStreamEventPathTemplate.render({
1619
+ network_code: networkCode,
1620
+ live_stream_event: liveStreamEvent,
1621
+ });
1622
+ }
1623
+ /**
1624
+ * Parse the network_code from LiveStreamEvent resource.
1625
+ *
1626
+ * @param {string} liveStreamEventName
1627
+ * A fully-qualified path representing LiveStreamEvent resource.
1628
+ * @returns {string} A string representing the network_code.
1629
+ */
1630
+ matchNetworkCodeFromLiveStreamEventName(liveStreamEventName) {
1631
+ return this.pathTemplates.liveStreamEventPathTemplate.match(liveStreamEventName).network_code;
1632
+ }
1633
+ /**
1634
+ * Parse the live_stream_event from LiveStreamEvent resource.
1635
+ *
1636
+ * @param {string} liveStreamEventName
1637
+ * A fully-qualified path representing LiveStreamEvent resource.
1638
+ * @returns {string} A string representing the live_stream_event.
1639
+ */
1640
+ matchLiveStreamEventFromLiveStreamEventName(liveStreamEventName) {
1641
+ return this.pathTemplates.liveStreamEventPathTemplate.match(liveStreamEventName).live_stream_event;
1642
+ }
1643
+ /**
1644
+ * Return a fully-qualified mobileCarrier resource name string.
1645
+ *
1646
+ * @param {string} network_code
1647
+ * @param {string} mobile_carrier
1648
+ * @returns {string} Resource name string.
1649
+ */
1650
+ mobileCarrierPath(networkCode, mobileCarrier) {
1651
+ return this.pathTemplates.mobileCarrierPathTemplate.render({
1652
+ network_code: networkCode,
1653
+ mobile_carrier: mobileCarrier,
1654
+ });
1655
+ }
1656
+ /**
1657
+ * Parse the network_code from MobileCarrier resource.
1658
+ *
1659
+ * @param {string} mobileCarrierName
1660
+ * A fully-qualified path representing MobileCarrier resource.
1661
+ * @returns {string} A string representing the network_code.
1662
+ */
1663
+ matchNetworkCodeFromMobileCarrierName(mobileCarrierName) {
1664
+ return this.pathTemplates.mobileCarrierPathTemplate.match(mobileCarrierName).network_code;
1665
+ }
1666
+ /**
1667
+ * Parse the mobile_carrier from MobileCarrier resource.
1668
+ *
1669
+ * @param {string} mobileCarrierName
1670
+ * A fully-qualified path representing MobileCarrier resource.
1671
+ * @returns {string} A string representing the mobile_carrier.
1672
+ */
1673
+ matchMobileCarrierFromMobileCarrierName(mobileCarrierName) {
1674
+ return this.pathTemplates.mobileCarrierPathTemplate.match(mobileCarrierName).mobile_carrier;
1675
+ }
1676
+ /**
1677
+ * Return a fully-qualified mobileDevice resource name string.
1678
+ *
1679
+ * @param {string} network_code
1680
+ * @param {string} mobile_device
1681
+ * @returns {string} Resource name string.
1682
+ */
1683
+ mobileDevicePath(networkCode, mobileDevice) {
1684
+ return this.pathTemplates.mobileDevicePathTemplate.render({
1685
+ network_code: networkCode,
1686
+ mobile_device: mobileDevice,
1687
+ });
1688
+ }
1689
+ /**
1690
+ * Parse the network_code from MobileDevice resource.
1691
+ *
1692
+ * @param {string} mobileDeviceName
1693
+ * A fully-qualified path representing MobileDevice resource.
1694
+ * @returns {string} A string representing the network_code.
1695
+ */
1696
+ matchNetworkCodeFromMobileDeviceName(mobileDeviceName) {
1697
+ return this.pathTemplates.mobileDevicePathTemplate.match(mobileDeviceName).network_code;
1698
+ }
1699
+ /**
1700
+ * Parse the mobile_device from MobileDevice resource.
1701
+ *
1702
+ * @param {string} mobileDeviceName
1703
+ * A fully-qualified path representing MobileDevice resource.
1704
+ * @returns {string} A string representing the mobile_device.
1705
+ */
1706
+ matchMobileDeviceFromMobileDeviceName(mobileDeviceName) {
1707
+ return this.pathTemplates.mobileDevicePathTemplate.match(mobileDeviceName).mobile_device;
1708
+ }
1709
+ /**
1710
+ * Return a fully-qualified mobileDeviceSubmodel resource name string.
1711
+ *
1712
+ * @param {string} network_code
1713
+ * @param {string} mobile_device_submodel
1714
+ * @returns {string} Resource name string.
1715
+ */
1716
+ mobileDeviceSubmodelPath(networkCode, mobileDeviceSubmodel) {
1717
+ return this.pathTemplates.mobileDeviceSubmodelPathTemplate.render({
1718
+ network_code: networkCode,
1719
+ mobile_device_submodel: mobileDeviceSubmodel,
1720
+ });
1721
+ }
1722
+ /**
1723
+ * Parse the network_code from MobileDeviceSubmodel resource.
1724
+ *
1725
+ * @param {string} mobileDeviceSubmodelName
1726
+ * A fully-qualified path representing MobileDeviceSubmodel resource.
1727
+ * @returns {string} A string representing the network_code.
1728
+ */
1729
+ matchNetworkCodeFromMobileDeviceSubmodelName(mobileDeviceSubmodelName) {
1730
+ return this.pathTemplates.mobileDeviceSubmodelPathTemplate.match(mobileDeviceSubmodelName).network_code;
1731
+ }
1732
+ /**
1733
+ * Parse the mobile_device_submodel from MobileDeviceSubmodel resource.
1734
+ *
1735
+ * @param {string} mobileDeviceSubmodelName
1736
+ * A fully-qualified path representing MobileDeviceSubmodel resource.
1737
+ * @returns {string} A string representing the mobile_device_submodel.
1738
+ */
1739
+ matchMobileDeviceSubmodelFromMobileDeviceSubmodelName(mobileDeviceSubmodelName) {
1740
+ return this.pathTemplates.mobileDeviceSubmodelPathTemplate.match(mobileDeviceSubmodelName).mobile_device_submodel;
1741
+ }
1742
+ /**
1743
+ * Return a fully-qualified network resource name string.
1744
+ *
1745
+ * @param {string} network_code
1746
+ * @returns {string} Resource name string.
1747
+ */
1748
+ networkPath(networkCode) {
1749
+ return this.pathTemplates.networkPathTemplate.render({
1750
+ network_code: networkCode,
1751
+ });
1752
+ }
1753
+ /**
1754
+ * Parse the network_code from Network resource.
1755
+ *
1756
+ * @param {string} networkName
1757
+ * A fully-qualified path representing Network resource.
1758
+ * @returns {string} A string representing the network_code.
1759
+ */
1760
+ matchNetworkCodeFromNetworkName(networkName) {
1761
+ return this.pathTemplates.networkPathTemplate.match(networkName).network_code;
1762
+ }
1763
+ /**
1764
+ * Return a fully-qualified operatingSystem resource name string.
1765
+ *
1766
+ * @param {string} network_code
1767
+ * @param {string} operating_system
1768
+ * @returns {string} Resource name string.
1769
+ */
1770
+ operatingSystemPath(networkCode, operatingSystem) {
1771
+ return this.pathTemplates.operatingSystemPathTemplate.render({
1772
+ network_code: networkCode,
1773
+ operating_system: operatingSystem,
1774
+ });
1775
+ }
1776
+ /**
1777
+ * Parse the network_code from OperatingSystem resource.
1778
+ *
1779
+ * @param {string} operatingSystemName
1780
+ * A fully-qualified path representing OperatingSystem resource.
1781
+ * @returns {string} A string representing the network_code.
1782
+ */
1783
+ matchNetworkCodeFromOperatingSystemName(operatingSystemName) {
1784
+ return this.pathTemplates.operatingSystemPathTemplate.match(operatingSystemName).network_code;
1785
+ }
1786
+ /**
1787
+ * Parse the operating_system from OperatingSystem resource.
1788
+ *
1789
+ * @param {string} operatingSystemName
1790
+ * A fully-qualified path representing OperatingSystem resource.
1791
+ * @returns {string} A string representing the operating_system.
1792
+ */
1793
+ matchOperatingSystemFromOperatingSystemName(operatingSystemName) {
1794
+ return this.pathTemplates.operatingSystemPathTemplate.match(operatingSystemName).operating_system;
1795
+ }
1796
+ /**
1797
+ * Return a fully-qualified operatingSystemVersion resource name string.
1798
+ *
1799
+ * @param {string} network_code
1800
+ * @param {string} operating_system_version
1801
+ * @returns {string} Resource name string.
1802
+ */
1803
+ operatingSystemVersionPath(networkCode, operatingSystemVersion) {
1804
+ return this.pathTemplates.operatingSystemVersionPathTemplate.render({
1805
+ network_code: networkCode,
1806
+ operating_system_version: operatingSystemVersion,
1807
+ });
1808
+ }
1809
+ /**
1810
+ * Parse the network_code from OperatingSystemVersion resource.
1811
+ *
1812
+ * @param {string} operatingSystemVersionName
1813
+ * A fully-qualified path representing OperatingSystemVersion resource.
1814
+ * @returns {string} A string representing the network_code.
1815
+ */
1816
+ matchNetworkCodeFromOperatingSystemVersionName(operatingSystemVersionName) {
1817
+ return this.pathTemplates.operatingSystemVersionPathTemplate.match(operatingSystemVersionName).network_code;
1818
+ }
1819
+ /**
1820
+ * Parse the operating_system_version from OperatingSystemVersion resource.
1821
+ *
1822
+ * @param {string} operatingSystemVersionName
1823
+ * A fully-qualified path representing OperatingSystemVersion resource.
1824
+ * @returns {string} A string representing the operating_system_version.
1825
+ */
1826
+ matchOperatingSystemVersionFromOperatingSystemVersionName(operatingSystemVersionName) {
1827
+ return this.pathTemplates.operatingSystemVersionPathTemplate.match(operatingSystemVersionName).operating_system_version;
1828
+ }
1829
+ /**
1830
+ * Return a fully-qualified order resource name string.
1831
+ *
1832
+ * @param {string} network_code
1833
+ * @param {string} order
1834
+ * @returns {string} Resource name string.
1835
+ */
1836
+ orderPath(networkCode, order) {
1837
+ return this.pathTemplates.orderPathTemplate.render({
1838
+ network_code: networkCode,
1839
+ order: order,
1840
+ });
1841
+ }
1842
+ /**
1843
+ * Parse the network_code from Order resource.
1844
+ *
1845
+ * @param {string} orderName
1846
+ * A fully-qualified path representing Order resource.
1847
+ * @returns {string} A string representing the network_code.
1848
+ */
1849
+ matchNetworkCodeFromOrderName(orderName) {
1850
+ return this.pathTemplates.orderPathTemplate.match(orderName).network_code;
1851
+ }
1852
+ /**
1853
+ * Parse the order from Order resource.
1854
+ *
1855
+ * @param {string} orderName
1856
+ * A fully-qualified path representing Order resource.
1857
+ * @returns {string} A string representing the order.
1858
+ */
1859
+ matchOrderFromOrderName(orderName) {
1860
+ return this.pathTemplates.orderPathTemplate.match(orderName).order;
1861
+ }
1862
+ /**
1863
+ * Return a fully-qualified placement resource name string.
1864
+ *
1865
+ * @param {string} network_code
1866
+ * @param {string} placement
1867
+ * @returns {string} Resource name string.
1868
+ */
1869
+ placementPath(networkCode, placement) {
1870
+ return this.pathTemplates.placementPathTemplate.render({
1871
+ network_code: networkCode,
1872
+ placement: placement,
1873
+ });
1874
+ }
1875
+ /**
1876
+ * Parse the network_code from Placement resource.
1877
+ *
1878
+ * @param {string} placementName
1879
+ * A fully-qualified path representing Placement resource.
1880
+ * @returns {string} A string representing the network_code.
1881
+ */
1882
+ matchNetworkCodeFromPlacementName(placementName) {
1883
+ return this.pathTemplates.placementPathTemplate.match(placementName).network_code;
1884
+ }
1885
+ /**
1886
+ * Parse the placement from Placement resource.
1887
+ *
1888
+ * @param {string} placementName
1889
+ * A fully-qualified path representing Placement resource.
1890
+ * @returns {string} A string representing the placement.
1891
+ */
1892
+ matchPlacementFromPlacementName(placementName) {
1893
+ return this.pathTemplates.placementPathTemplate.match(placementName).placement;
1894
+ }
1895
+ /**
1896
+ * Return a fully-qualified privateAuction resource name string.
1897
+ *
1898
+ * @param {string} network_code
1899
+ * @param {string} private_auction
1900
+ * @returns {string} Resource name string.
1901
+ */
1902
+ privateAuctionPath(networkCode, privateAuction) {
1903
+ return this.pathTemplates.privateAuctionPathTemplate.render({
1904
+ network_code: networkCode,
1905
+ private_auction: privateAuction,
1906
+ });
1907
+ }
1908
+ /**
1909
+ * Parse the network_code from PrivateAuction resource.
1910
+ *
1911
+ * @param {string} privateAuctionName
1912
+ * A fully-qualified path representing PrivateAuction resource.
1913
+ * @returns {string} A string representing the network_code.
1914
+ */
1915
+ matchNetworkCodeFromPrivateAuctionName(privateAuctionName) {
1916
+ return this.pathTemplates.privateAuctionPathTemplate.match(privateAuctionName).network_code;
1917
+ }
1918
+ /**
1919
+ * Parse the private_auction from PrivateAuction resource.
1920
+ *
1921
+ * @param {string} privateAuctionName
1922
+ * A fully-qualified path representing PrivateAuction resource.
1923
+ * @returns {string} A string representing the private_auction.
1924
+ */
1925
+ matchPrivateAuctionFromPrivateAuctionName(privateAuctionName) {
1926
+ return this.pathTemplates.privateAuctionPathTemplate.match(privateAuctionName).private_auction;
1927
+ }
1928
+ /**
1929
+ * Return a fully-qualified privateAuctionDeal resource name string.
1930
+ *
1931
+ * @param {string} network_code
1932
+ * @param {string} private_auction_deal
1933
+ * @returns {string} Resource name string.
1934
+ */
1935
+ privateAuctionDealPath(networkCode, privateAuctionDeal) {
1936
+ return this.pathTemplates.privateAuctionDealPathTemplate.render({
1937
+ network_code: networkCode,
1938
+ private_auction_deal: privateAuctionDeal,
1939
+ });
1940
+ }
1941
+ /**
1942
+ * Parse the network_code from PrivateAuctionDeal resource.
1943
+ *
1944
+ * @param {string} privateAuctionDealName
1945
+ * A fully-qualified path representing PrivateAuctionDeal resource.
1946
+ * @returns {string} A string representing the network_code.
1947
+ */
1948
+ matchNetworkCodeFromPrivateAuctionDealName(privateAuctionDealName) {
1949
+ return this.pathTemplates.privateAuctionDealPathTemplate.match(privateAuctionDealName).network_code;
1950
+ }
1951
+ /**
1952
+ * Parse the private_auction_deal from PrivateAuctionDeal resource.
1953
+ *
1954
+ * @param {string} privateAuctionDealName
1955
+ * A fully-qualified path representing PrivateAuctionDeal resource.
1956
+ * @returns {string} A string representing the private_auction_deal.
1957
+ */
1958
+ matchPrivateAuctionDealFromPrivateAuctionDealName(privateAuctionDealName) {
1959
+ return this.pathTemplates.privateAuctionDealPathTemplate.match(privateAuctionDealName).private_auction_deal;
1960
+ }
1961
+ /**
1962
+ * Return a fully-qualified programmaticBuyer resource name string.
1963
+ *
1964
+ * @param {string} network_code
1965
+ * @param {string} programmatic_buyer
1966
+ * @returns {string} Resource name string.
1967
+ */
1968
+ programmaticBuyerPath(networkCode, programmaticBuyer) {
1969
+ return this.pathTemplates.programmaticBuyerPathTemplate.render({
1970
+ network_code: networkCode,
1971
+ programmatic_buyer: programmaticBuyer,
1972
+ });
1973
+ }
1974
+ /**
1975
+ * Parse the network_code from ProgrammaticBuyer resource.
1976
+ *
1977
+ * @param {string} programmaticBuyerName
1978
+ * A fully-qualified path representing ProgrammaticBuyer resource.
1979
+ * @returns {string} A string representing the network_code.
1980
+ */
1981
+ matchNetworkCodeFromProgrammaticBuyerName(programmaticBuyerName) {
1982
+ return this.pathTemplates.programmaticBuyerPathTemplate.match(programmaticBuyerName).network_code;
1983
+ }
1984
+ /**
1985
+ * Parse the programmatic_buyer from ProgrammaticBuyer resource.
1986
+ *
1987
+ * @param {string} programmaticBuyerName
1988
+ * A fully-qualified path representing ProgrammaticBuyer resource.
1989
+ * @returns {string} A string representing the programmatic_buyer.
1990
+ */
1991
+ matchProgrammaticBuyerFromProgrammaticBuyerName(programmaticBuyerName) {
1992
+ return this.pathTemplates.programmaticBuyerPathTemplate.match(programmaticBuyerName).programmatic_buyer;
1993
+ }
1994
+ /**
1995
+ * Return a fully-qualified report resource name string.
1996
+ *
1997
+ * @param {string} network_code
1998
+ * @param {string} report
1999
+ * @returns {string} Resource name string.
2000
+ */
2001
+ reportPath(networkCode, report) {
2002
+ return this.pathTemplates.reportPathTemplate.render({
2003
+ network_code: networkCode,
2004
+ report: report,
2005
+ });
2006
+ }
2007
+ /**
2008
+ * Parse the network_code from Report resource.
2009
+ *
2010
+ * @param {string} reportName
2011
+ * A fully-qualified path representing Report resource.
2012
+ * @returns {string} A string representing the network_code.
2013
+ */
2014
+ matchNetworkCodeFromReportName(reportName) {
2015
+ return this.pathTemplates.reportPathTemplate.match(reportName).network_code;
2016
+ }
2017
+ /**
2018
+ * Parse the report from Report resource.
2019
+ *
2020
+ * @param {string} reportName
2021
+ * A fully-qualified path representing Report resource.
2022
+ * @returns {string} A string representing the report.
2023
+ */
2024
+ matchReportFromReportName(reportName) {
2025
+ return this.pathTemplates.reportPathTemplate.match(reportName).report;
2026
+ }
2027
+ /**
2028
+ * Return a fully-qualified role resource name string.
2029
+ *
2030
+ * @param {string} network_code
2031
+ * @param {string} role
2032
+ * @returns {string} Resource name string.
2033
+ */
2034
+ rolePath(networkCode, role) {
2035
+ return this.pathTemplates.rolePathTemplate.render({
2036
+ network_code: networkCode,
2037
+ role: role,
2038
+ });
2039
+ }
2040
+ /**
2041
+ * Parse the network_code from Role resource.
2042
+ *
2043
+ * @param {string} roleName
2044
+ * A fully-qualified path representing Role resource.
2045
+ * @returns {string} A string representing the network_code.
2046
+ */
2047
+ matchNetworkCodeFromRoleName(roleName) {
2048
+ return this.pathTemplates.rolePathTemplate.match(roleName).network_code;
2049
+ }
2050
+ /**
2051
+ * Parse the role from Role resource.
2052
+ *
2053
+ * @param {string} roleName
2054
+ * A fully-qualified path representing Role resource.
2055
+ * @returns {string} A string representing the role.
2056
+ */
2057
+ matchRoleFromRoleName(roleName) {
2058
+ return this.pathTemplates.rolePathTemplate.match(roleName).role;
2059
+ }
2060
+ /**
2061
+ * Return a fully-qualified site resource name string.
2062
+ *
2063
+ * @param {string} network_code
2064
+ * @param {string} site
2065
+ * @returns {string} Resource name string.
2066
+ */
2067
+ sitePath(networkCode, site) {
2068
+ return this.pathTemplates.sitePathTemplate.render({
2069
+ network_code: networkCode,
2070
+ site: site,
2071
+ });
2072
+ }
2073
+ /**
2074
+ * Parse the network_code from Site resource.
2075
+ *
2076
+ * @param {string} siteName
2077
+ * A fully-qualified path representing Site resource.
2078
+ * @returns {string} A string representing the network_code.
2079
+ */
2080
+ matchNetworkCodeFromSiteName(siteName) {
2081
+ return this.pathTemplates.sitePathTemplate.match(siteName).network_code;
2082
+ }
2083
+ /**
2084
+ * Parse the site from Site resource.
2085
+ *
2086
+ * @param {string} siteName
2087
+ * A fully-qualified path representing Site resource.
2088
+ * @returns {string} A string representing the site.
2089
+ */
2090
+ matchSiteFromSiteName(siteName) {
2091
+ return this.pathTemplates.sitePathTemplate.match(siteName).site;
2092
+ }
2093
+ /**
2094
+ * Return a fully-qualified taxonomyCategory resource name string.
2095
+ *
2096
+ * @param {string} network_code
2097
+ * @param {string} taxonomy_category
2098
+ * @returns {string} Resource name string.
2099
+ */
2100
+ taxonomyCategoryPath(networkCode, taxonomyCategory) {
2101
+ return this.pathTemplates.taxonomyCategoryPathTemplate.render({
2102
+ network_code: networkCode,
2103
+ taxonomy_category: taxonomyCategory,
2104
+ });
2105
+ }
2106
+ /**
2107
+ * Parse the network_code from TaxonomyCategory resource.
2108
+ *
2109
+ * @param {string} taxonomyCategoryName
2110
+ * A fully-qualified path representing TaxonomyCategory resource.
2111
+ * @returns {string} A string representing the network_code.
2112
+ */
2113
+ matchNetworkCodeFromTaxonomyCategoryName(taxonomyCategoryName) {
2114
+ return this.pathTemplates.taxonomyCategoryPathTemplate.match(taxonomyCategoryName).network_code;
2115
+ }
2116
+ /**
2117
+ * Parse the taxonomy_category from TaxonomyCategory resource.
2118
+ *
2119
+ * @param {string} taxonomyCategoryName
2120
+ * A fully-qualified path representing TaxonomyCategory resource.
2121
+ * @returns {string} A string representing the taxonomy_category.
2122
+ */
2123
+ matchTaxonomyCategoryFromTaxonomyCategoryName(taxonomyCategoryName) {
2124
+ return this.pathTemplates.taxonomyCategoryPathTemplate.match(taxonomyCategoryName).taxonomy_category;
2125
+ }
2126
+ /**
2127
+ * Return a fully-qualified team resource name string.
2128
+ *
2129
+ * @param {string} network_code
2130
+ * @param {string} team
2131
+ * @returns {string} Resource name string.
2132
+ */
2133
+ teamPath(networkCode, team) {
2134
+ return this.pathTemplates.teamPathTemplate.render({
2135
+ network_code: networkCode,
2136
+ team: team,
2137
+ });
2138
+ }
2139
+ /**
2140
+ * Parse the network_code from Team resource.
2141
+ *
2142
+ * @param {string} teamName
2143
+ * A fully-qualified path representing Team resource.
2144
+ * @returns {string} A string representing the network_code.
2145
+ */
2146
+ matchNetworkCodeFromTeamName(teamName) {
2147
+ return this.pathTemplates.teamPathTemplate.match(teamName).network_code;
2148
+ }
2149
+ /**
2150
+ * Parse the team from Team resource.
2151
+ *
2152
+ * @param {string} teamName
2153
+ * A fully-qualified path representing Team resource.
2154
+ * @returns {string} A string representing the team.
2155
+ */
2156
+ matchTeamFromTeamName(teamName) {
2157
+ return this.pathTemplates.teamPathTemplate.match(teamName).team;
2158
+ }
2159
+ /**
2160
+ * Return a fully-qualified user resource name string.
2161
+ *
2162
+ * @param {string} network_code
2163
+ * @param {string} user
2164
+ * @returns {string} Resource name string.
2165
+ */
2166
+ userPath(networkCode, user) {
2167
+ return this.pathTemplates.userPathTemplate.render({
2168
+ network_code: networkCode,
2169
+ user: user,
2170
+ });
2171
+ }
2172
+ /**
2173
+ * Parse the network_code from User resource.
2174
+ *
2175
+ * @param {string} userName
2176
+ * A fully-qualified path representing User resource.
2177
+ * @returns {string} A string representing the network_code.
2178
+ */
2179
+ matchNetworkCodeFromUserName(userName) {
2180
+ return this.pathTemplates.userPathTemplate.match(userName).network_code;
2181
+ }
2182
+ /**
2183
+ * Parse the user from User resource.
2184
+ *
2185
+ * @param {string} userName
2186
+ * A fully-qualified path representing User resource.
2187
+ * @returns {string} A string representing the user.
2188
+ */
2189
+ matchUserFromUserName(userName) {
2190
+ return this.pathTemplates.userPathTemplate.match(userName).user;
2191
+ }
2192
+ /**
2193
+ * Return a fully-qualified webProperty resource name string.
2194
+ *
2195
+ * @param {string} network_code
2196
+ * @param {string} web_property
2197
+ * @returns {string} Resource name string.
2198
+ */
2199
+ webPropertyPath(networkCode, webProperty) {
2200
+ return this.pathTemplates.webPropertyPathTemplate.render({
2201
+ network_code: networkCode,
2202
+ web_property: webProperty,
2203
+ });
2204
+ }
2205
+ /**
2206
+ * Parse the network_code from WebProperty resource.
2207
+ *
2208
+ * @param {string} webPropertyName
2209
+ * A fully-qualified path representing WebProperty resource.
2210
+ * @returns {string} A string representing the network_code.
2211
+ */
2212
+ matchNetworkCodeFromWebPropertyName(webPropertyName) {
2213
+ return this.pathTemplates.webPropertyPathTemplate.match(webPropertyName).network_code;
2214
+ }
2215
+ /**
2216
+ * Parse the web_property from WebProperty resource.
2217
+ *
2218
+ * @param {string} webPropertyName
2219
+ * A fully-qualified path representing WebProperty resource.
2220
+ * @returns {string} A string representing the web_property.
2221
+ */
2222
+ matchWebPropertyFromWebPropertyName(webPropertyName) {
2223
+ return this.pathTemplates.webPropertyPathTemplate.match(webPropertyName).web_property;
2224
+ }
2225
+ /**
2226
+ * Terminate the gRPC channel and close the client.
2227
+ *
2228
+ * The client will no longer be usable and all future behavior is undefined.
2229
+ * @returns {Promise} A promise that resolves when the client is closed.
2230
+ */
2231
+ close() {
2232
+ if (this.siteServiceStub && !this._terminated) {
2233
+ return this.siteServiceStub.then(stub => {
2234
+ this._log.info('ending gRPC channel');
2235
+ this._terminated = true;
2236
+ stub.close();
2237
+ });
2238
+ }
2239
+ return Promise.resolve();
2240
+ }
2241
+ }
2242
+ exports.SiteServiceClient = SiteServiceClient;
2243
+ //# sourceMappingURL=site_service_client.js.map