SID:SampleReplaceStempseudonym

Uit Kennisnet Developers Documentatie
Versie door Fleischeuers01 (overleg | bijdragen) op 1 jun 2017 om 10:24 (Nieuwe pagina aangemaakt met '==Request== <syntaxhighlight lang="xml" line highlight="28"> POST https://service-t.id.school/eck/ws/201703/ HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: te...')
(wijz) ← Oudere versie | Huidige versie (wijz) | Nieuwere versie → (wijz)
Naar navigatie springen Naar zoeken springen

Nummervoorziening-symbol.png Nummervoorziening: SampleReplaceStempseudonym

Request

POST https://service-t.id.school/eck/ws/201703/ HTTP/1.1
Accept-Encoding: gzip,deflate
Content-Type: text/xml;charset=UTF-8
SOAPAction: "http://id.school/eck/schemas/v1_0/replaceStampseudonym"
Content-Length: 870
Host: service-t.id.school
Connection: Keep-Alive
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)

<soapenv:Envelope 
	xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" 
	xmlns:v1="http://id.school/eck/schemas/v1_0">
   <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
   	<wsa:Action>
   		http://id.school/eck/schemas/v1_0/replaceStampseudonym
   	</wsa:Action>
   	wsa:From>
   	<wsa:Address>
   		http://www.w3.org/2005/08/addressing/anonymous?oin=0000000700019HY34567
   	</wsa:Address>
   </wsa:From>
   <wsa:MessageID>uuid:95013a44-1583-49bc-8ffb-fce6eafb0840</wsa:MessageID>
   <wsa:To>https://service-t.id.school/eck/ws/201703/</wsa:To>
</soapenv:Header>
   <soapenv:Body>
      <v1:replaceStampseudonymRequest>
         <v1:hpgnOld>1f600cb5a432a31f6f877528324f4eca08b2006d50bb8d6374591be4ea995828</v1:hpgnOld>
         <v1:hpgnNew>8a333608fc1c31ff37618d12f76be459078ddddd227fa8031458a72b662b6f93</v1:hpgnNew>
         <v1:effectiveDate>2017-06-01T13:26:30.806+01:00</v1:effectiveDate>
      </v1:replaceStampseudonymRequest>
   </soapenv:Body>
</soapenv:Envelope>

Response

The stempseudonym that is returned by this function (line 22 in the response) is the stempseudonym that is associated to the new hashed PGN, starting at effectiveDate if given or now. This stempseudonym used to be associated with hpgnOld in the request. Starting effectiveDate or now, the hashed PGN n hpgnOld can no longer be used (see below).

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Header>
      <Action xmlns="http://www.w3.org/2005/08/addressing">
         http://id.school/eck/schemas/v1_0/SchoolID/replaceStampseudonymResponse
      </Action>
      <MessageID xmlns="http://www.w3.org/2005/08/addressing">
         urn:uuid:2544795a-729a-4887-bbbf-ac0fba5ab08c
      </MessageID>
      <To xmlns="http://www.w3.org/2005/08/addressing">
         http://www.w3.org/2005/08/addressing/anonymous?oin=0000000700019HY34567
      </To>
      <RelatesTo xmlns="http://www.w3.org/2005/08/addressing">
         uuid:95013a44-1583-49bc-8ffb-fce6eafb0840
      </RelatesTo>
      <From xmlns="http://www.w3.org/2005/08/addressing">
         <Address>http://www.w3.org/2005/08/addressing/anonymous?oin=00000003272448340000</Address>
      </From>
   </soap:Header>
   <soap:Body>
      <replaceStampseudonymResponse xmlns="http://id.school/eck/schemas/v1_0">
         <stampseudonym>
            https://id.school/sppilot/b87d57ea2b40fe0cfb7cf29b3d162dc1e5cb8ca5e040a3208fec5220c0d65a5cfbe627afe67c8e779e045a5049c8e61caf592da5f17d4c872017fa5352498436
         </stampseudonym>
      </replaceStampseudonymResponse>
   </soap:Body>
</soap:Envelope>

Followup request

The error that is returned when a hashed PGN is used that was substituted:

POST https://service-t.id.school/eck/ws/201703/ HTTP/1.1
Accept-Encoding: gzip,deflate
Content-Type: text/xml;charset=UTF-8
SOAPAction: "http://id.school/eck/schemas/v1_0/retrieveStampseudonym"
Content-Length: 768
Host: service-t.id.school
Connection: Keep-Alive
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)

<soapenv:Envelope 
  xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" 
  xmlns:v1="http://id.school/eck/schemas/v1_0">
   <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
     <wsa:Action>http://id.school/eck/schemas/v1_0/retrieveStampseudonym</wsa:Action>
     <wsa:From>
       <wsa:Address>
         http://www.w3.org/2005/08/addressing/anonymous?oin=0000000700019HY34567
       </wsa:Address>
     </wsa:From>
     <wsa:MessageID>uuid:8d9076aa-6b39-437b-91a9-e6d250ff8eeb</wsa:MessageID>
     <wsa:To>https://service-t.id.school/eck/ws/201703/</wsa:To>
   </soapenv:Header>
   <soapenv:Body>
      <v1:retrieveStampseudonymRequest>
         <v1:hpgn>1f600cb5a432a31f6f877528324f4eca08b2006d50bb8d6374591be4ea995828</v1:hpgn>
      </v1:retrieveStampseudonymRequest>
   </soapenv:Body>
</soapevn:Envelope>

Gets the response:

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Header>
      <Action xmlns="http://www.w3.org/2005/08/addressing">
         http://id.school/eck/schemas/v1_0/SchoolID/retrieveStampseudonym/Fault/SOAPFaultException
      </Action>
      <MessageID xmlns="http://www.w3.org/2005/08/addressing">
         urn:uuid:7fe9e263-2e25-443a-8ee0-2c3f4d4560be
      </MessageID>
      <To xmlns="http://www.w3.org/2005/08/addressing">
         http://www.w3.org/2005/08/addressing/anonymous?oin=0000000700019HY34567
      </To>
      <RelatesTo xmlns="http://www.w3.org/2005/08/addressing">
         uuid:8d9076aa-6b39-437b-91a9-e6d250ff8eeb
      </RelatesTo>
      <From xmlns="http://www.w3.org/2005/08/addressing">
         <Address>http://www.w3.org/2005/08/addressing/anonymous?oin=00000003272448340000</Address>
      </From>
   </soap:Header>
   <soap:Body>
      <soap:Fault>
         <faultcode>soap:SERVER</faultcode>
         <faultstring>Fout geconstateerd bij het verwerken van een aanroep van 'retrieveStampseudonym': Het aangeleverde HPgn is geblokkeerd</faultstring>
         <faultactor>BlockedHPgnException</faultactor>
         <detail>
            <message>Het aangeleverde HPgn is geblokkeerd</message>
         </detail>
      </soap:Fault>
   </soap:Body>
</soap:Envelope>