link.proto 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. // Copyright 2020 Google LLC
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. syntax = "proto3";
  15. package google.actions.sdk.v2.conversation;
  16. option go_package = "google.golang.org/genproto/googleapis/actions/sdk/v2/conversation;conversation";
  17. option java_multiple_files = true;
  18. option java_outer_classname = "LinkProto";
  19. option java_package = "com.google.actions.sdk.v2.conversation";
  20. // Link content.
  21. message Link {
  22. // Name of the link
  23. string name = 1;
  24. // What happens when a user opens the link
  25. OpenUrl open = 2;
  26. }
  27. // Action taken when a user opens a link.
  28. message OpenUrl {
  29. // The url field which could be any of:
  30. // - http/https urls for opening an App-linked App or a webpage
  31. string url = 1;
  32. // Indicates a hint for the url type.
  33. UrlHint hint = 2;
  34. }
  35. // Different types of url hints.
  36. enum UrlHint {
  37. // Unspecified
  38. LINK_UNSPECIFIED = 0;
  39. // URL that points directly to AMP content, or to a canonical URL
  40. // which refers to AMP content via <link rel="amphtml">.
  41. AMP = 1;
  42. }