An overview of the end to end booking process

Sequence Diagram

The end to end process includes some existing processes, as well as new processes. The sequence of events is shown in the below diagram.

The interactions are detailed further here:

GetServices

This is existing process, using a CheckCapacitySummary query to the DoS, this is detailed in a separate specification.

Select

This is the process of the Consuming system user and the Patient agreeing on the most suitable service, and is outside the scope of this specification.

Find Endpoint

This is the process used in order to find the technical endpoint (or URL) of the FHIR server to be used in order to book appointments for the selected Service. This uses two LDAP queries to SDS, using the ASID from the selected DoS Service.

NB: The examples provided here are described against SDS in OpenTest.

The first query is to retrieve the nhsAS Object and takes the form:

ldapsearch -x -H ldap://192.168.128.11 -b "ou=services, o=nhs" "(uniqueIdentifier=[ASID-Value])"

The response will be something like this:

# extended LDIF
#
# LDAPv3
# base <ou=services, o=nhs> with scope subtree
# filter: (uniqueIdentifier=918999199203)
# requesting: ALL
#

# 918999199203, Services, nhs
dn: uniqueIdentifier=918999199203,ou=Services,o=nhs
nhsApproverURP: uniqueIdentifier=283886066515,uniqueIdentifier=747394079517,uid=828249614516,ou=people,o=nhs
nhsAsSvcIA: urn:nhs:names:services:psisquery:QUPC_IN160101UK05

~~~ Lots of rows removed here ~~~
nhsAsSvcIA: urn:nhs:names:services:careconnect:fhir:rest:create:appointment
nhsAsSvcIA: urn:nhs:names:services:careconnect:fhir:rest:read:slot
~~~ Lots of rows removed here ~~~

nhsAsSvcIA: urn:nhs:names:services:careconnect:fhir:rest:read:appointment
nhsDateApproved: 20151106145512
nhsDateRequested: 20151106145347
nhsIDCode: A91342
uniqueIdentifier: 918999199203
nhsMHSPartyKey: A91342-9199203
nhsRequestorURP: uniqueIdentifier=331622135514,uniqueIdentifier=747394079517, uid=828249614516,ou=people,o=nhs
nhsAsACF: CNST
nhsAsACF: DOLR
nhsAsACF: RBAC
nhsAsClient: A91342
nhsProductKey: 7374
objectClass: top
objectClass: nhsAs

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1

The important part of the above is the nhsMHSPartyKey value.

The second query is to retrieve the nhsMHS object, and takes the form:

ldapsearch -x -H ldap://192.168.128.11 -b "ou=services, o=nhs" "(&(nhsMhsPartyKey=[nhsMHSPartyKey goes here])(nhsMhsSvcIA=urn:nhs:names:services:careconnect:fhir:rest:read:slot))"

The response will be something like this:

# extended LDIF
#
# LDAPv3
# base <ou=services, o=nhs> with scope subtree
# filter: (&(nhsMhsPartyKey=A91342-9199203)(nhsMhsSvcIA=urn:nhs:names:services:careconnect:fhir:rest:read:slot))
# requesting: ALL
#

# S918999494042, Services, nhs
dn: uniqueIdentifier=S918999494042,ou=Services,o=nhs
nhsDateRequested: 20140718000000
nhsMHsSN: urn:nhs:names:services:careconnect
nhsMHSIsAuthenticated: none
nhsDateApproved: 20180201115957
nhsApproverURP: uniqueidentifier=555050304105,uniqueidentifier=555008548101,uid=555008545108,ou=people, o=nhs
nhsDateDNSApproved: 20180201115957
nhsMHSAckRequested: never
nhsDNSApprover: uniqueidentifier=555050304105,uniqueidentifier=555008548101,uid=555008545108,ou=people, o=nhs
nhsContractPropertyTemplateKey: 14
nhsProductKey: 11080
nhsMhsFQDN: vpn-client-1292.opentest.hscic.gov.uk
objectClass: nhsMhs
objectClass: top
uniqueIdentifier: S918999494042
nhsEPInteractionType: FHIR
nhsRequestorURP: SYSTEM
nhsMHSEndPoint: https://vpn-client-1292.opentest.hscic.gov.uk/
nhsMhsCPAId: S918999494042
nhsMHSPartyKey: A91342-9199203
nhsMHsIN: fhir:rest:create:appointment
nhsIDCode: A91342
nhsMhsSvcIA: urn:nhs:names:services:careconnect:fhir:rest:read:slot
nhsMHSDuplicateElimination: never
nhsMHSSyncReplyMode: None
nhsMHSServiceDescription: OpenTest vpn-client-1292.opentest.hscic.gov.uk

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1

The important part of the above is the nhsMHSEndPoint value.

Get Token

This is the process used to create an access token which can be used by the Provider system to verify the identity and assurance status of the Consuming system.

Current implementations of the nationally defined APIs follow the standard process for Spine core APIs as documented here:

This uses an unsigned token generated by the Consuming system.

The specific process for creating the access token will be implemented per use case; and so develepors must review the guidance in the specific standard for your use case. For example review the guidance in the UEC Appointment Bookings standard.

Get Slots

This is the process to find availability at the selected service, it is described in detail here.

Select

This is the process of the Consuming system user and the Patient agreeing on the most suitable Slot, and is outside the scope of this specification.

Book

This is the process of sending a booked appointment, including details of the Patient and an associated (CDA) document from the Consuming system to the Provider system, and is described in detail here.

FHIR Profiles: NHS Booking FHIR Profiles
How to Search for Slots: Search Slots
How to Book an Appointment: Book an Appointment

Glossary

A full list of Glossary terms used by NHS Projects can be found at the NHS Developer Network - Glossary.