Documentation of NHR PoRS2 REST API

REST API are described in the table below.

Base URLs:

Links in the URI column (GET calls only) is based on values related to registration GLN 5798009811578 or values related to client certificate.

Ressource URI Method Data Status Description
Metadata /list/documentstandards GET XML described in documentstandardlist.xsd 200, 404, 500 Provides list of the document standards in NHR
Metadata /list/{documentstandardid}/profiles GET XML described in profilelist.xsd 200, 404, 500 Provides list of the profiles in the selected document standard. {documentstandardid} must be the numeric ID value
Metadata /list/{documentstandardid}/roles GET XML described in rolelist.xsd 200, 404, 500 Provides list of the roles in the selected document standard
Metadata /list/{documentstandardid}/documenttypes GET XML described in documenttypelist.xsd 200, 404, 500 Provides list of the document types in the selected document standard
Metadata /list/{documentstandardid}/profile/{profileid}/roles GET XML described in rolelist.xsd 200, 404, 500 Provides list of the roles in the selected document standard and selected profile
Metadata /list/{documentstandardid}/profile/{profileid}/role/{roleid}/documenttypes GET XML described in documenttypelist.xsd 200, 404, 500 Provides list of the document types in the selected profile + role
Metadata /list/keytypes GET XML described in keytypelist.xsd 200, 404, 500 Provides list of the key types in NHR
Metadata /list/networktypes GET XML described in networkTypelist.xsd 200, 404, 500 Provides list of the network types in NHR
Business /business GET XML described in business.xsd 200, 404, 405, 500 Provides list of own business
Business /business PUT XML described in business.xsd 200, 404, 405, 500 Create/update Business, if id=0 then it is create, else update
Business /business/isAgreementAccepted GET Text 200, 401 OK (200) or ERROR (401) if client certificate has accepted the NemHandel Agreement.
Business /business/agreement/text GET Text 200 The the NemHandel Agreement text.
Business /business/agreement PUT (empty) 200, 400, 404, 405, 500 Accept the NemHandel Agreement for the used certificate. The old negative hit is cached for 1 minute
Participants /participant/list GET XML described in participantlist.xsd 200, 404, 405, 500 Provides list of all Participants owned by this CVR [*PagingEnabled]
Participants /participant/list/group/{groupId} GET XML described in participantlist.xsd 200, 404, 405, 500 Provides list of all Participants owned by this CVR, being part of group with specified ID [*PagingEnabled]
Participants /participant/list/unitcvr/{cvr} GET XML described in participantlist.xsd 200, 404, 405, 500 Provides list of all Participants owned by this CVR, where unitCVR is the specified CVR [*PagingEnabled]
Participant /participant/{id} GET XML described in participant.xsd 200, 404, 500 Provides the actual Participant based on id, including bindings and ownerBusiness. If Participant is not found, status 404 is returned.
Participant /participant/{keytype}/{key} GET XML described in participant.xsd 200, 404, 500 Provides the actual Participant based on keytype (String) and key, including bindings and ownerBusiness. If Participant is not found, status 404 is returned.
Participant /participant PUT XML described in updateparticipant.xsd 200, 201, 405, 500 Create/update Participant - if id=0 then it is create, else update
Participant /participant/{id} DELETE N/A 200, 404, 409, 500 Fully delete Participant (incl. bindings).
Groups /group/list GET XML described in grouplist.xsd 200, 404, 405, 500 Provides list of all groups owned by CVR [*PagingEnabled]
Group /group/{id} GET XML described in group.xsd 200, 404, 405, 500 Provides specific group based on id
Group /group PUT XML described in updategroup.xsd 200, 201, 409, 500 Create/update Group - if id=0 then it is create, else update
Group /group/{id} DELETE N/A 200, 404, 409, 500 Delete group
Services /service/list GET XML described in service.xsd 200, 404, 405, 500 Provides list of all services owned by CVR [*PagingEnabled]
Service /service/{id} GET XML described in service.xsd / aggregatedservice.xsd 200, 404, 405, 500 Provides specific service based on id - can be ReceiverService or AggregatedService
Service /service PUT XML described in updatereceiverservice.xsd 200, 201, 409, 500 Create/update service - if id=0 then it is create, else update
Service /service/{id} DELETE N/A 200, 404, 409, 500 Delete service
Aggregeret service /service/aggregated/{id} GET XML described in aggregatedservice.xsd 200, 404, 405, 500 Provides aggregated service based on id
Aggregated service /service/aggregated PUT XML described in updateaggregatedservice.xsd 200, 201, 409, 500 Create/update aggregated service - if id=0 then it is create, else update
Aggregated service /service/aggregated/{id} DELETE N/A 200, 409, 500 Delete aggregated service
Profilings /profiling/list GET XML described in profilinglist.xsd 200, 404, 405, 500 Provides list of all profilings owned by CVR [*PagingEnabled]
Profiling /profiling/{id} GET XML described in profiling.xsd 200, 404, 405, 500 Provides specific profiling based on id
Profilering /profiling PUT XML described in updateprofiling.xsd 200, 201, 409, 500 Create/update profiling - if id=0 then it is create, else update
Profilering /profiling/{id} DELETE N/A 200, 404, 409, 500 Delete profiling

A ZIP-file with all XSD-files can be downloaded as xsd.zip

PagingEnabled

When Paging is enabled, the following query parameters are possible to use:

page The page number to fetch
sort The field to sort by
order The order to sort by: ASC or DESC
pagesize Number of elements to return per page

JSON format

REST service resources are by default returned as xml. If JSON is needed as representation, then set Accept header in HTTP request to application/json

Status codes

Status code is always returned as part of the HTTP Status header. Values for status codes are: