v1
latestOpenAPI 3.0.02026-07-148098.2 KBSearch for a relationship
Overview
Use this endpoint to search for relationship records. Most commonly you would use this endpoint to get all the relationships for a given organisation, based on its ODS code.
For relationships, this API returns the following details:
- related organisation ODS code
- relationship type and relationship name
- relationship legal start and end dates
- relationship operational start and end dates
you can search using various combinations of:
- Primary-Organisation - known within the ORD products as the Source Organisation
- Participating-Organisation - known within the ORD products as the Target Organisation
- relationship status
It is also possible to return the relevant Organization Resources in these searches using the _include parameter
Query parameters
The organisation's ID - also known as its ODS code. If you already know the ODS code, consider using the 'Get organsiation details' endpoint instead.
The ‘source’ organisation which has a relationship.
referred to as the SourceOrganisation in the ORD schema
Must be a valid Organisation code with relationships to return results
The ‘Target’ or related organisation.
Referred to as the Target Organisation in the ORD schema Must be a valid Organisation code with relationships to return results
Whether the organisation's relationship record is still in active use.
Number of results to return.
Enables you return related resources.
OrganizationAffiliation:primary-organization will include Organization resource records for the ‘Source’ Organisations in the search results
OrganizationAffiliation:participating-organization will include Organization resource records for all the ‘Target’ Organisations in the search results
you can include both primary and participating organization resources by including multiple _include parameters
Return a count of the matching resources, without returning the actual matches.
Response
Valid request that returns any FHIR OrganizationAffiliation resources that match the search criteria (which may be 0).