AdImpressionParameters.cs 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. using System;
  2. namespace Unity.Services.Analytics
  3. {
  4. /// <summary>
  5. /// Helper struct to handle arguments for recording an AdImpression event.
  6. /// </summary>
  7. public struct AdImpressionParameters
  8. {
  9. /// <summary>
  10. /// Indicates whether the Ad view was successful or not.
  11. /// </summary>
  12. public AdCompletionStatus AdCompletionStatus;
  13. /// <summary>
  14. /// The Ad SDK that provided the Ad.
  15. /// </summary>
  16. public AdProvider AdProvider;
  17. /// <summary>
  18. /// The unique identifier for the placement where the Ad appeared as integrated into the game.
  19. /// </summary>
  20. public string PlacementID;
  21. /// <summary>
  22. /// If there is a place in the game that can show Ads from multiple networks, there won’t be a single placementId. This field compensates for that by providing a single name for your placement. Ideally, this would be an easily human-readable name such as ‘revive’ or ‘daily bonus’.
  23. /// This value is here for reporting purposes only.
  24. /// </summary>
  25. public string PlacementName;
  26. /// <summary>
  27. /// Optional.
  28. /// The placementType should indicate what type of Ad is shown.
  29. /// This value is here for reporting purposes only.
  30. /// </summary>
  31. public AdPlacementType? PlacementType;
  32. /// <summary>
  33. /// Optional.
  34. /// The estimated ECPM in USD, you should populate this value if you can.
  35. /// </summary>
  36. public double? AdEcpmUsd;
  37. /// <summary>
  38. /// Optional.
  39. /// The Ad SDK version you are using.
  40. /// </summary>
  41. public string SdkVersion;
  42. /// <summary>
  43. /// Optional.
  44. /// </summary>
  45. public string AdImpressionID;
  46. /// <summary>
  47. /// Optional.
  48. /// </summary>
  49. public string AdStoreDstID;
  50. /// <summary>
  51. /// Optional.
  52. /// </summary>
  53. public string AdMediaType;
  54. /// <summary>
  55. /// Optional.
  56. /// </summary>
  57. public Int64? AdTimeWatchedMs;
  58. /// <summary>
  59. /// Optional.
  60. /// </summary>
  61. public Int64? AdTimeCloseButtonShownMs;
  62. /// <summary>
  63. /// Optional.
  64. /// </summary>
  65. public Int64? AdLengthMs;
  66. /// <summary>
  67. /// Optional.
  68. /// </summary>
  69. public bool? AdHasClicked;
  70. /// <summary>
  71. /// Optional.
  72. /// </summary>
  73. public string AdSource;
  74. /// <summary>
  75. /// Optional.
  76. /// </summary>
  77. public string AdStatusCallback;
  78. }
  79. }