# GraphDefinition

Canonical page: https://docs.ovok.com/api/fhir/r4/graph-definition

A formal computable definition of a graph of resources - that is, a coherent set of resources that form a graph by following references. The Graph Definition resource defines a set and makes rules about the set.

These interaction paths describe standard FHIR R4 patterns. Availability can depend on the API capabilities enabled for your Ovok project.

| **Interaction** | **Method** | **Path** |
| --- | --- | --- |
| Read | `GET` | `/fhir/R4/GraphDefinition/[id]` |
| Vread | `GET` | `/fhir/R4/GraphDefinition/[id]/_history/[vid]` |
| Update | `PUT` | `/fhir/R4/GraphDefinition/[id]` |
| Patch | `PATCH` | `/fhir/R4/GraphDefinition/[id]` |
| Delete | `DELETE` | `/fhir/R4/GraphDefinition/[id]` |
| Create | `POST` | `/fhir/R4/GraphDefinition` |
| Search | `GET` | `/fhir/R4/GraphDefinition` |
| History | `GET` | `/fhir/R4/GraphDefinition/[id]/_history` |

## Top-level elements [#top-level-elements]

| **Element** | **Type** | **Cardinality** | **Description** |
| --- | --- | --- | --- |
| <span id="element-id"></span>`id` | [string](/fhir-elements/primitive/string) | `0..1` | Logical id of this artifact |
| <span id="element-meta"></span>`meta` | [Meta](/fhir-elements/complex/meta) | `0..1` | Metadata about the resource |
| <span id="element-implicit-rules"></span>`implicitRules` | [uri](/fhir-elements/primitive/uri) | `0..1` | A set of rules under which this content was created |
| <span id="element-language"></span>`language` | [code](/fhir-elements/primitive/code) | `0..1` | Language of the resource content |
| <span id="element-text"></span>`text` | [Narrative](/fhir-elements/complex/narrative) | `0..1` | Text summary of the resource, for human interpretation |
| <span id="element-contained"></span>`contained` | [Resource](/fhir-elements/foundation/resource) | `0..*` | Contained, inline Resources |
| <span id="element-extension"></span>`extension` | [Extension](/fhir-elements/complex/extension) | `0..*` | Additional content defined by implementations |
| <span id="element-modifier-extension"></span>`modifierExtension` | [Extension](/fhir-elements/complex/extension) | `0..*` | Extensions that cannot be ignored |
| <span id="element-url"></span>`url` | [uri](/fhir-elements/primitive/uri) | `0..1` | Canonical identifier for this graph definition, represented as a URI (globally unique) |
| <span id="element-version"></span>`version` | [string](/fhir-elements/primitive/string) | `0..1` | Business version of the graph definition |
| <span id="element-name"></span>`name` | [string](/fhir-elements/primitive/string) | `1..1` | Name for this graph definition (computer friendly) |
| <span id="element-status"></span>`status` | [code](/fhir-elements/primitive/code) | `1..1` | draft \| active \| retired \| unknown |
| <span id="element-experimental"></span>`experimental` | [boolean](/fhir-elements/primitive/boolean) | `0..1` | For testing purposes, not real usage |
| <span id="element-date"></span>`date` | [dateTime](/fhir-elements/primitive/date-time) | `0..1` | Date last changed |
| <span id="element-publisher"></span>`publisher` | [string](/fhir-elements/primitive/string) | `0..1` | Name of the publisher (organization or individual) |
| <span id="element-contact"></span>`contact` | [ContactDetail](/fhir-elements/complex/contact-detail) | `0..*` | Contact details for the publisher |
| <span id="element-description"></span>`description` | [markdown](/fhir-elements/primitive/markdown) | `0..1` | Natural language description of the graph definition |
| <span id="element-use-context"></span>`useContext` | [UsageContext](/fhir-elements/complex/usage-context) | `0..*` | The context that the content is intended to support |
| <span id="element-jurisdiction"></span>`jurisdiction` | [CodeableConcept](/fhir-elements/complex/codeable-concept) | `0..*` | Intended jurisdiction for graph definition (if applicable) |
| <span id="element-purpose"></span>`purpose` | [markdown](/fhir-elements/primitive/markdown) | `0..1` | Why this graph definition is defined |
| <span id="element-start"></span>`start` | [code](/fhir-elements/primitive/code) | `1..1` | Type of resource at which the graph starts |
| <span id="element-profile"></span>`profile` | [canonical](/fhir-elements/primitive/canonical) | `0..1` | Profile on base resource |
| <span id="element-link"></span>`link` | [BackboneElement](/fhir-elements/complex/backbone-element) | `0..*` | Links this graph makes rules about |

## Resource-specific search parameters [#resource-specific-search-parameters]

| **Parameter** | **Type** | **Description** |
| --- | --- | --- |
| `context` | token | Multiple Resources: CapabilityStatement: A use context assigned to the capability statement ; CodeSystem: A use context assigned to the code system ; CompartmentDefinition: A use context assigned to the compartment definition ; ConceptMap: A use context assigned to the concept map ; GraphDefinition: A use context assigned to the graph definition ; ImplementationGuide: A use context assigned to the implementation guide ; MessageDefinition: A use context assigned to the message definition ; NamingSystem: A use context assigned to the naming system ; OperationDefinition: A use context assigned to the operation definition ; SearchParameter: A use context assigned to the search parameter ; StructureDefinition: A use context assigned to the structure definition ; StructureMap: A use context assigned to the structure map ; TerminologyCapabilities: A use context assigned to the terminology capabilities ; ValueSet: A use context assigned to the value set  |
| `context-quantity` | quantity | Multiple Resources: CapabilityStatement: A quantity- or range-valued use context assigned to the capability statement ; CodeSystem: A quantity- or range-valued use context assigned to the code system ; CompartmentDefinition: A quantity- or range-valued use context assigned to the compartment definition ; ConceptMap: A quantity- or range-valued use context assigned to the concept map ; GraphDefinition: A quantity- or range-valued use context assigned to the graph definition ; ImplementationGuide: A quantity- or range-valued use context assigned to the implementation guide ; MessageDefinition: A quantity- or range-valued use context assigned to the message definition ; NamingSystem: A quantity- or range-valued use context assigned to the naming system ; OperationDefinition: A quantity- or range-valued use context assigned to the operation definition ; SearchParameter: A quantity- or range-valued use context assigned to the search parameter ; StructureDefinition: A quantity- or range-valued use context assigned to the structure definition ; StructureMap: A quantity- or range-valued use context assigned to the structure map ; TerminologyCapabilities: A quantity- or range-valued use context assigned to the terminology capabilities ; ValueSet: A quantity- or range-valued use context assigned to the value set  |
| `context-type` | token | Multiple Resources: CapabilityStatement: A type of use context assigned to the capability statement ; CodeSystem: A type of use context assigned to the code system ; CompartmentDefinition: A type of use context assigned to the compartment definition ; ConceptMap: A type of use context assigned to the concept map ; GraphDefinition: A type of use context assigned to the graph definition ; ImplementationGuide: A type of use context assigned to the implementation guide ; MessageDefinition: A type of use context assigned to the message definition ; NamingSystem: A type of use context assigned to the naming system ; OperationDefinition: A type of use context assigned to the operation definition ; SearchParameter: A type of use context assigned to the search parameter ; StructureDefinition: A type of use context assigned to the structure definition ; StructureMap: A type of use context assigned to the structure map ; TerminologyCapabilities: A type of use context assigned to the terminology capabilities ; ValueSet: A type of use context assigned to the value set  |
| `context-type-quantity` | composite | Multiple Resources: CapabilityStatement: A use context type and quantity- or range-based value assigned to the capability statement ; CodeSystem: A use context type and quantity- or range-based value assigned to the code system ; CompartmentDefinition: A use context type and quantity- or range-based value assigned to the compartment definition ; ConceptMap: A use context type and quantity- or range-based value assigned to the concept map ; GraphDefinition: A use context type and quantity- or range-based value assigned to the graph definition ; ImplementationGuide: A use context type and quantity- or range-based value assigned to the implementation guide ; MessageDefinition: A use context type and quantity- or range-based value assigned to the message definition ; NamingSystem: A use context type and quantity- or range-based value assigned to the naming system ; OperationDefinition: A use context type and quantity- or range-based value assigned to the operation definition ; SearchParameter: A use context type and quantity- or range-based value assigned to the search parameter ; StructureDefinition: A use context type and quantity- or range-based value assigned to the structure definition ; StructureMap: A use context type and quantity- or range-based value assigned to the structure map ; TerminologyCapabilities: A use context type and quantity- or range-based value assigned to the terminology capabilities ; ValueSet: A use context type and quantity- or range-based value assigned to the value set  |
| `context-type-value` | composite | Multiple Resources: CapabilityStatement: A use context type and value assigned to the capability statement ; CodeSystem: A use context type and value assigned to the code system ; CompartmentDefinition: A use context type and value assigned to the compartment definition ; ConceptMap: A use context type and value assigned to the concept map ; GraphDefinition: A use context type and value assigned to the graph definition ; ImplementationGuide: A use context type and value assigned to the implementation guide ; MessageDefinition: A use context type and value assigned to the message definition ; NamingSystem: A use context type and value assigned to the naming system ; OperationDefinition: A use context type and value assigned to the operation definition ; SearchParameter: A use context type and value assigned to the search parameter ; StructureDefinition: A use context type and value assigned to the structure definition ; StructureMap: A use context type and value assigned to the structure map ; TerminologyCapabilities: A use context type and value assigned to the terminology capabilities ; ValueSet: A use context type and value assigned to the value set  |
| `date` | date | Multiple Resources: CapabilityStatement: The capability statement publication date ; CodeSystem: The code system publication date ; CompartmentDefinition: The compartment definition publication date ; ConceptMap: The concept map publication date ; GraphDefinition: The graph definition publication date ; ImplementationGuide: The implementation guide publication date ; MessageDefinition: The message definition publication date ; NamingSystem: The naming system publication date ; OperationDefinition: The operation definition publication date ; SearchParameter: The search parameter publication date ; StructureDefinition: The structure definition publication date ; StructureMap: The structure map publication date ; TerminologyCapabilities: The terminology capabilities publication date ; ValueSet: The value set publication date  |
| `description` | string | Multiple Resources: CapabilityStatement: The description of the capability statement ; CodeSystem: The description of the code system ; CompartmentDefinition: The description of the compartment definition ; ConceptMap: The description of the concept map ; GraphDefinition: The description of the graph definition ; ImplementationGuide: The description of the implementation guide ; MessageDefinition: The description of the message definition ; NamingSystem: The description of the naming system ; OperationDefinition: The description of the operation definition ; SearchParameter: The description of the search parameter ; StructureDefinition: The description of the structure definition ; StructureMap: The description of the structure map ; TerminologyCapabilities: The description of the terminology capabilities ; ValueSet: The description of the value set  |
| `jurisdiction` | token | Multiple Resources: CapabilityStatement: Intended jurisdiction for the capability statement ; CodeSystem: Intended jurisdiction for the code system ; ConceptMap: Intended jurisdiction for the concept map ; GraphDefinition: Intended jurisdiction for the graph definition ; ImplementationGuide: Intended jurisdiction for the implementation guide ; MessageDefinition: Intended jurisdiction for the message definition ; NamingSystem: Intended jurisdiction for the naming system ; OperationDefinition: Intended jurisdiction for the operation definition ; SearchParameter: Intended jurisdiction for the search parameter ; StructureDefinition: Intended jurisdiction for the structure definition ; StructureMap: Intended jurisdiction for the structure map ; TerminologyCapabilities: Intended jurisdiction for the terminology capabilities ; ValueSet: Intended jurisdiction for the value set  |
| `name` | string | Multiple Resources: CapabilityStatement: Computationally friendly name of the capability statement ; CodeSystem: Computationally friendly name of the code system ; CompartmentDefinition: Computationally friendly name of the compartment definition ; ConceptMap: Computationally friendly name of the concept map ; GraphDefinition: Computationally friendly name of the graph definition ; ImplementationGuide: Computationally friendly name of the implementation guide ; MessageDefinition: Computationally friendly name of the message definition ; NamingSystem: Computationally friendly name of the naming system ; OperationDefinition: Computationally friendly name of the operation definition ; SearchParameter: Computationally friendly name of the search parameter ; StructureDefinition: Computationally friendly name of the structure definition ; StructureMap: Computationally friendly name of the structure map ; TerminologyCapabilities: Computationally friendly name of the terminology capabilities ; ValueSet: Computationally friendly name of the value set  |
| `publisher` | string | Multiple Resources: CapabilityStatement: Name of the publisher of the capability statement ; CodeSystem: Name of the publisher of the code system ; CompartmentDefinition: Name of the publisher of the compartment definition ; ConceptMap: Name of the publisher of the concept map ; GraphDefinition: Name of the publisher of the graph definition ; ImplementationGuide: Name of the publisher of the implementation guide ; MessageDefinition: Name of the publisher of the message definition ; NamingSystem: Name of the publisher of the naming system ; OperationDefinition: Name of the publisher of the operation definition ; SearchParameter: Name of the publisher of the search parameter ; StructureDefinition: Name of the publisher of the structure definition ; StructureMap: Name of the publisher of the structure map ; TerminologyCapabilities: Name of the publisher of the terminology capabilities ; ValueSet: Name of the publisher of the value set  |
| `start` | token | Type of resource at which the graph starts |
| `status` | token | Multiple Resources: CapabilityStatement: The current status of the capability statement ; CodeSystem: The current status of the code system ; CompartmentDefinition: The current status of the compartment definition ; ConceptMap: The current status of the concept map ; GraphDefinition: The current status of the graph definition ; ImplementationGuide: The current status of the implementation guide ; MessageDefinition: The current status of the message definition ; NamingSystem: The current status of the naming system ; OperationDefinition: The current status of the operation definition ; SearchParameter: The current status of the search parameter ; StructureDefinition: The current status of the structure definition ; StructureMap: The current status of the structure map ; TerminologyCapabilities: The current status of the terminology capabilities ; ValueSet: The current status of the value set  |
| `url` | uri | Multiple Resources: CapabilityStatement: The uri that identifies the capability statement ; CodeSystem: The uri that identifies the code system ; CompartmentDefinition: The uri that identifies the compartment definition ; ConceptMap: The uri that identifies the concept map ; GraphDefinition: The uri that identifies the graph definition ; ImplementationGuide: The uri that identifies the implementation guide ; MessageDefinition: The uri that identifies the message definition ; OperationDefinition: The uri that identifies the operation definition ; SearchParameter: The uri that identifies the search parameter ; StructureDefinition: The uri that identifies the structure definition ; StructureMap: The uri that identifies the structure map ; TerminologyCapabilities: The uri that identifies the terminology capabilities ; ValueSet: The uri that identifies the value set  |
| `version` | token | Multiple Resources: CapabilityStatement: The business version of the capability statement ; CodeSystem: The business version of the code system ; CompartmentDefinition: The business version of the compartment definition ; ConceptMap: The business version of the concept map ; GraphDefinition: The business version of the graph definition ; ImplementationGuide: The business version of the implementation guide ; MessageDefinition: The business version of the message definition ; OperationDefinition: The business version of the operation definition ; SearchParameter: The business version of the search parameter ; StructureDefinition: The business version of the structure definition ; StructureMap: The business version of the structure map ; TerminologyCapabilities: The business version of the terminology capabilities ; ValueSet: The business version of the value set  |

## Reference [#reference]

Official FHIR R4 spec: [GraphDefinition](https://hl7.org/fhir/R4/graphdefinition.html).  
Maturity: Trial Use 1 (FMM 1).
