xml-responses.js 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. 'use strict';
  2. const createdPartyRegistrationMinXml = `<ns2:oadrPayload xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://openadr.org/oadr-2.0b/2012/07" xmlns:ns3="http://docs.oasis-open.org/ns/energyinterop/201110" xmlns:ns4="http://docs.oasis-open.org/ns/energyinterop/201110/payloads" xmlns:ns5="urn:ietf:params:xml:ns:icalendar-2.0" xmlns:ns6="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:ns7="urn:ietf:params:xml:ns:icalendar-2.0:stream" xmlns:ns8="http://www.w3.org/2005/Atom" xmlns:ns9="http://docs.oasis-open.org/ns/emix/2011/06/power" xmlns:ns10="http://www.opengis.net/gml/3.2" xmlns:ns11="http://docs.oasis-open.org/ns/emix/2011/06/siscale" xmlns:ns12="http://www.w3.org/2009/xmldsig11#" xmlns:ns13="http://openadr.org/oadr-2.0b/2012/07/xmldsig-properties" xmlns:ns14="urn:un:unece:uncefact:codelist:standard:5:ISO42173A:2010-04-07">
  3. <ns2:oadrSignedObject>
  4. <ns2:oadrCreatedPartyRegistration ns3:schemaVersion="2.0b">
  5. <ns3:eiResponse>
  6. <ns3:responseCode>200</ns3:responseCode>
  7. <ns4:requestID>4323</ns4:requestID>
  8. </ns3:eiResponse>
  9. <ns3:vtnID>VTN_ID1</ns3:vtnID>
  10. <ns2:oadrProfiles>
  11. <ns2:oadrProfile>
  12. <ns2:oadrProfileName>2.0b</ns2:oadrProfileName>
  13. <ns2:oadrTransports>
  14. <ns2:oadrTransport>
  15. <ns2:oadrTransportName>simpleHttp</ns2:oadrTransportName>
  16. </ns2:oadrTransport>
  17. </ns2:oadrTransports>
  18. </ns2:oadrProfile>
  19. </ns2:oadrProfiles>
  20. </ns2:oadrCreatedPartyRegistration>
  21. </ns2:oadrSignedObject>
  22. </ns2:oadrPayload>`;
  23. const createdPartyRegistrationMaxXml = `<ns2:oadrPayload xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://openadr.org/oadr-2.0b/2012/07" xmlns:ns3="http://docs.oasis-open.org/ns/energyinterop/201110" xmlns:ns4="http://docs.oasis-open.org/ns/energyinterop/201110/payloads" xmlns:ns5="urn:ietf:params:xml:ns:icalendar-2.0" xmlns:ns6="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:ns7="urn:ietf:params:xml:ns:icalendar-2.0:stream" xmlns:ns8="http://www.w3.org/2005/Atom" xmlns:ns9="http://docs.oasis-open.org/ns/emix/2011/06/power" xmlns:ns10="http://www.opengis.net/gml/3.2" xmlns:ns11="http://docs.oasis-open.org/ns/emix/2011/06/siscale" xmlns:ns12="http://www.w3.org/2009/xmldsig11#" xmlns:ns13="http://openadr.org/oadr-2.0b/2012/07/xmldsig-properties" xmlns:ns14="urn:un:unece:uncefact:codelist:standard:5:ISO42173A:2010-04-07">
  24. <ns2:oadrSignedObject>
  25. <ns2:oadrCreatedPartyRegistration ns3:schemaVersion="2.0b">
  26. <ns3:eiResponse>
  27. <ns3:responseCode>200</ns3:responseCode>
  28. <ns3:responseDescription>OK</ns3:responseDescription>
  29. <ns4:requestID>4323</ns4:requestID>
  30. </ns3:eiResponse>
  31. <ns3:registrationID>3bd3c02dc6965c8b9240</ns3:registrationID>
  32. <ns3:venID>3f59d85fbdf3997dbeb1</ns3:venID>
  33. <ns3:vtnID>VTN_ID1</ns3:vtnID>
  34. <ns2:oadrProfiles>
  35. <ns2:oadrProfile>
  36. <ns2:oadrProfileName>2.0b</ns2:oadrProfileName>
  37. <ns2:oadrTransports>
  38. <ns2:oadrTransport>
  39. <ns2:oadrTransportName>simpleHttp</ns2:oadrTransportName>
  40. </ns2:oadrTransport>
  41. </ns2:oadrTransports>
  42. </ns2:oadrProfile>
  43. </ns2:oadrProfiles>
  44. <ns2:oadrRequestedOadrPollFreq>
  45. <ns5:duration>PT10S</ns5:duration>
  46. </ns2:oadrRequestedOadrPollFreq>
  47. </ns2:oadrCreatedPartyRegistration>
  48. </ns2:oadrSignedObject>
  49. </ns2:oadrPayload>`;
  50. const createdPartyRegistrationMissingRequiredXml = `<ns2:oadrPayload xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://openadr.org/oadr-2.0b/2012/07" xmlns:ns3="http://docs.oasis-open.org/ns/energyinterop/201110" xmlns:ns4="http://docs.oasis-open.org/ns/energyinterop/201110/payloads" xmlns:ns5="urn:ietf:params:xml:ns:icalendar-2.0" xmlns:ns6="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:ns7="urn:ietf:params:xml:ns:icalendar-2.0:stream" xmlns:ns8="http://www.w3.org/2005/Atom" xmlns:ns9="http://docs.oasis-open.org/ns/emix/2011/06/power" xmlns:ns10="http://www.opengis.net/gml/3.2" xmlns:ns11="http://docs.oasis-open.org/ns/emix/2011/06/siscale" xmlns:ns12="http://www.w3.org/2009/xmldsig11#" xmlns:ns13="http://openadr.org/oadr-2.0b/2012/07/xmldsig-properties" xmlns:ns14="urn:un:unece:uncefact:codelist:standard:5:ISO42173A:2010-04-07">
  51. <ns2:oadrSignedObject>
  52. <ns2:oadrCreatedPartyRegistration ns3:schemaVersion="2.0b">
  53. <ns3:eiResponse>
  54. <ns3:responseCode>200</ns3:responseCode>
  55. <ns4:requestID>4323</ns4:requestID>
  56. </ns3:eiResponse>
  57. <ns2:oadrProfiles>
  58. <ns2:oadrProfile>
  59. <ns2:oadrProfileName>2.0b</ns2:oadrProfileName>
  60. <ns2:oadrTransports>
  61. <ns2:oadrTransport>
  62. <ns2:oadrTransportName>simpleHttp</ns2:oadrTransportName>
  63. </ns2:oadrTransport>
  64. </ns2:oadrTransports>
  65. </ns2:oadrProfile>
  66. </ns2:oadrProfiles>
  67. </ns2:oadrCreatedPartyRegistration>
  68. </ns2:oadrSignedObject>
  69. </ns2:oadrPayload>`;
  70. const canceledPartyRegistrationMinXml = `<ns2:oadrPayload xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://openadr.org/oadr-2.0b/2012/07" xmlns:ns3="http://docs.oasis-open.org/ns/energyinterop/201110" xmlns:ns4="http://docs.oasis-open.org/ns/energyinterop/201110/payloads" xmlns:ns5="urn:ietf:params:xml:ns:icalendar-2.0" xmlns:ns6="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:ns7="urn:ietf:params:xml:ns:icalendar-2.0:stream" xmlns:ns8="http://www.w3.org/2005/Atom" xmlns:ns9="http://docs.oasis-open.org/ns/emix/2011/06/power" xmlns:ns10="http://www.opengis.net/gml/3.2" xmlns:ns11="http://docs.oasis-open.org/ns/emix/2011/06/siscale" xmlns:ns12="http://www.w3.org/2009/xmldsig11#" xmlns:ns13="http://openadr.org/oadr-2.0b/2012/07/xmldsig-properties" xmlns:ns14="urn:un:unece:uncefact:codelist:standard:5:ISO42173A:2010-04-07">
  71. <ns2:oadrSignedObject>
  72. <ns2:oadrCanceledPartyRegistration ns3:schemaVersion="2.0b">
  73. <ns3:eiResponse>
  74. <ns3:responseCode>200</ns3:responseCode>
  75. <ns4:requestID>334455</ns4:requestID>
  76. </ns3:eiResponse>
  77. </ns2:oadrCanceledPartyRegistration>
  78. </ns2:oadrSignedObject>
  79. </ns2:oadrPayload>`;
  80. const canceledPartyRegistrationMaxXml = `<ns2:oadrPayload xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://openadr.org/oadr-2.0b/2012/07" xmlns:ns3="http://docs.oasis-open.org/ns/energyinterop/201110" xmlns:ns4="http://docs.oasis-open.org/ns/energyinterop/201110/payloads" xmlns:ns5="urn:ietf:params:xml:ns:icalendar-2.0" xmlns:ns6="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:ns7="urn:ietf:params:xml:ns:icalendar-2.0:stream" xmlns:ns8="http://www.w3.org/2005/Atom" xmlns:ns9="http://docs.oasis-open.org/ns/emix/2011/06/power" xmlns:ns10="http://www.opengis.net/gml/3.2" xmlns:ns11="http://docs.oasis-open.org/ns/emix/2011/06/siscale" xmlns:ns12="http://www.w3.org/2009/xmldsig11#" xmlns:ns13="http://openadr.org/oadr-2.0b/2012/07/xmldsig-properties" xmlns:ns14="urn:un:unece:uncefact:codelist:standard:5:ISO42173A:2010-04-07">
  81. <ns2:oadrSignedObject>
  82. <ns2:oadrCanceledPartyRegistration ns3:schemaVersion="2.0b">
  83. <ns3:eiResponse>
  84. <ns3:responseCode>200</ns3:responseCode>
  85. <ns3:responseDescription>OK</ns3:responseDescription>
  86. <ns4:requestID>334455</ns4:requestID>
  87. </ns3:eiResponse>
  88. <ns3:registrationID>3bd3c02dc6965c8b9240</ns3:registrationID>
  89. <ns3:venID>3f59d85fbdf3997dbeb1</ns3:venID>
  90. </ns2:oadrCanceledPartyRegistration>
  91. </ns2:oadrSignedObject>
  92. </ns2:oadrPayload>`;
  93. const canceledPartyRegistrationMissingRequiredXml = `<ns2:oadrPayload xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://openadr.org/oadr-2.0b/2012/07" xmlns:ns3="http://docs.oasis-open.org/ns/energyinterop/201110" xmlns:ns4="http://docs.oasis-open.org/ns/energyinterop/201110/payloads" xmlns:ns5="urn:ietf:params:xml:ns:icalendar-2.0" xmlns:ns6="http://docs.oasis-open.org/ns/emix/2011/06" xmlns:ns7="urn:ietf:params:xml:ns:icalendar-2.0:stream" xmlns:ns8="http://www.w3.org/2005/Atom" xmlns:ns9="http://docs.oasis-open.org/ns/emix/2011/06/power" xmlns:ns10="http://www.opengis.net/gml/3.2" xmlns:ns11="http://docs.oasis-open.org/ns/emix/2011/06/siscale" xmlns:ns12="http://www.w3.org/2009/xmldsig11#" xmlns:ns13="http://openadr.org/oadr-2.0b/2012/07/xmldsig-properties" xmlns:ns14="urn:un:unece:uncefact:codelist:standard:5:ISO42173A:2010-04-07">
  94. <ns2:oadrSignedObject>
  95. <ns2:oadrCanceledPartyRegistration ns3:schemaVersion="2.0b">
  96. <ns3:eiResponse>
  97. <ns4:requestID>334455</ns4:requestID>
  98. </ns3:eiResponse>
  99. </ns2:oadrCanceledPartyRegistration>
  100. </ns2:oadrSignedObject>
  101. </ns2:oadrPayload>`;
  102. module.exports = {
  103. canceledPartyRegistrationMinXml,
  104. canceledPartyRegistrationMaxXml,
  105. canceledPartyRegistrationMissingRequiredXml,
  106. createdPartyRegistrationMinXml,
  107. createdPartyRegistrationMaxXml,
  108. createdPartyRegistrationMissingRequiredXml,
  109. };