SubRequest.cs 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Threading.Tasks;
  5. using System.Xml.Serialization;
  6. namespace ApiProcessToken.Models.edu
  7. {
  8. [XmlRoot(ElementName = "document", Namespace = "")]
  9. public class DocumentDto
  10. {
  11. [XmlElement(DataType = "string", ElementName = "charge")]
  12. public string charge { get; set; }
  13. [XmlElement(DataType = "string", ElementName = "reason")]
  14. public string reason { get; set; }
  15. [XmlElement(DataType = "string", ElementName = "hangup")]
  16. public string hangup { get; set; }
  17. [XmlElement(ElementName = "recording_url")]
  18. public string recording_url { get; set; }
  19. }
  20. //[XmlRoot(ElementName = "document", Namespace = "")]
  21. //public class DocumentDto
  22. //{
  23. // [XmlElement(DataType = "string", ElementName = "username")]
  24. // public string username { get; set; }
  25. // [XmlElement(DataType = "string", ElementName = "password")]
  26. // public string password { get; set; }
  27. // [XmlElement(DataType = "string", ElementName = "serviceid")]
  28. // public string serviceid { get; set; }
  29. // [XmlElement(DataType = "string", ElementName = "msisdn")]
  30. // public string msisdn { get; set; }
  31. // [XmlElement(DataType = "string", ElementName = "chargetime")]
  32. // public string chargetime { get; set; }
  33. // [XmlElement(DataType = "string", ElementName = "params")]
  34. // public string params1 { get; set; }
  35. // [XmlElement(DataType = "string", ElementName = "mode")]
  36. // public string mode { get; set; }
  37. // [XmlElement(DataType = "string", ElementName = "amount")]
  38. // public string amount { get; set; }
  39. // [XmlElement(DataType = "string", ElementName = "command")]
  40. // public string command { get; set; }
  41. // [XmlElement(DataType = "string", ElementName = "transaction")]
  42. // public string transaction { get; set; }
  43. //}
  44. [XmlRoot(ElementName = "subRequest", Namespace = "http://contentws/xsd")]
  45. public class SubRequest
  46. {
  47. [XmlElement(ElementName = "username", Namespace = "http://contentws/xsd")]
  48. public string Username { get; set; }
  49. [XmlElement(ElementName = "password", Namespace = "http://contentws/xsd")]
  50. public string Password { get; set; }
  51. [XmlElement(ElementName = "serviceid", Namespace = "http://contentws/xsd")]
  52. public string Serviceid { get; set; }
  53. [XmlElement(ElementName = "msisdn", Namespace = "http://contentws/xsd")]
  54. public string Msisdn { get; set; }
  55. [XmlElement(ElementName = "chargetime", Namespace = "http://contentws/xsd")]
  56. public string Chargetime { get; set; }
  57. [XmlElement(ElementName = "params", Namespace = "http://contentws/xsd")]
  58. public string Params { get; set; }
  59. [XmlElement(ElementName = "mode", Namespace = "http://contentws/xsd")]
  60. public string Mode { get; set; }
  61. [XmlElement(ElementName = "amount", Namespace = "http://contentws/xsd")]
  62. public string Amount { get; set; }
  63. [XmlElement(ElementName = "command", Namespace = "http://contentws/xsd")]
  64. public string Command { get; set; }
  65. [XmlElement(ElementName = "transaction", Namespace = "http://contentws/xsd")]
  66. public string Transaction { get; set; }
  67. [XmlAttribute(AttributeName = "xmlns")]
  68. public string Xmlns { get; set; }
  69. }
  70. [XmlRoot(ElementName = "Body", Namespace = "http://schemas.xmlsoap.org/soap/envelope/")]
  71. public class Body
  72. {
  73. [XmlElement(ElementName = "subRequest", Namespace = "http://contentws/xsd")]
  74. public SubRequest SubRequest { get; set; }
  75. }
  76. [XmlRoot(ElementName = "Envelope", Namespace = "http://schemas.xmlsoap.org/soap/envelope/")]
  77. public class Envelope
  78. {
  79. [XmlElement(ElementName = "Body", Namespace = "http://schemas.xmlsoap.org/soap/envelope/")]
  80. public Body Body { get; set; }
  81. [XmlAttribute(AttributeName = "S", Namespace = "http://www.w3.org/2000/xmlns/")]
  82. public string S { get; set; }
  83. }
  84. }