Subscription constructor

const Subscription({
  1. @Default(R5ResourceType.Subscription) @JsonKey(unknownEnumValue: R5ResourceType.Subscription) R5ResourceType resourceType,
  2. @JsonKey(includeFromJson: true, includeToJson: false) int? dbId,
  3. @JsonKey(name: 'id') FhirId? fhirId,
  4. FhirMeta? meta,
  5. FhirUri? implicitRules,
  6. @JsonKey(name: '_implicitRules') Element? implicitRulesElement,
  7. FhirCode? language,
  8. @JsonKey(name: '_language') Element? languageElement,
  9. Narrative? text,
  10. List<Resource>? contained,
  11. @JsonKey(name: 'extension') List<FhirExtension>? extension_,
  12. List<FhirExtension>? modifierExtension,
  13. List<Identifier>? identifier,
  14. String? name,
  15. @JsonKey(name: '_name') Element? nameElement,
  16. FhirCode? status,
  17. @JsonKey(name: '_status') Element? statusElement,
  18. required FhirCanonical topic,
  19. List<ContactPoint>? contact,
  20. FhirInstant? end,
  21. @JsonKey(name: '_end') Element? endElement,
  22. Reference? managingEntity,
  23. String? reason,
  24. @JsonKey(name: '_reason') Element? reasonElement,
  25. List<SubscriptionFilterBy>? filterBy,
  26. required Coding channelType,
  27. FhirUrl? endpoint,
  28. @JsonKey(name: '_endpoint') Element? endpointElement,
  29. List<SubscriptionParameter>? parameter,
  30. FhirUnsignedInt? heartbeatPeriod,
  31. @JsonKey(name: '_heartbeatPeriod') Element? heartbeatPeriodElement,
  32. FhirUnsignedInt? timeout,
  33. @JsonKey(name: '_timeout') Element? timeoutElement,
  34. FhirCode? contentType,
  35. @JsonKey(name: '_contentType') Element? contentTypeElement,
  36. FhirCode? content,
  37. @JsonKey(name: '_content') Element? contentElement,
  38. FhirPositiveInt? maxCount,
  39. @JsonKey(name: '_maxCount') Element? maxCountElement,
})

Subscription The subscription resource describes a particular client's request to be notified about a SubscriptionTopic.

resourceType This is a Subscription resource

id The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.

meta The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.

implicitRules A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc.

implicitRulesElement ("_implicitRules") Extensions for implicitRules

language The base language in which the resource is written.

languageElement ("_language") Extensions for language

text A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it "clinically safe" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.

contained These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, nor can they have their own independent transaction scope. This is allowed to be a Parameters resource if and only if it is referenced by a resource that provides context/meaning.

extension_ ("extension") May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.

modifierExtension May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).

identifier A formal identifier that is used to identify this code system when it is represented in other formats, or referenced in a specification, model, design or an instance.

name A natural language name identifying the subscription.

nameElement ("_name") Extensions for name

status The status of the subscription, which marks the server state for managing the subscription.

statusElement ("_status") Extensions for status

topic The reference to the subscription topic to be notified about.

contact Contact details for a human to contact about the subscription. The primary use of this for system administrator troubleshooting.

end The time for the server to turn the subscription off.

endElement ("_end") Extensions for end

managingEntity Entity with authorization to make subsequent revisions to the Subscription and also determines what data the subscription is authorized to disclose.

reason A description of why this subscription is defined.

reasonElement ("_reason") Extensions for reason

filterBy The filter properties to be applied to narrow the subscription topic stream. When multiple filters are applied, evaluates to true if all the conditions applicable to that resource are met; otherwise it returns false (i.e., logical AND).

channelType The type of channel to send notifications on.

endpoint The url that describes the actual end-point to send notifications to.

endpointElement ("_endpoint") Extensions for endpoint

parameter Channel-dependent information to send as part of the notification (e.g., HTTP Headers).

heartbeatPeriod If present, a 'heartbeat' notification (keep-alive) is sent via this channel with an interval period equal to this elements integer value in seconds. If not present, a heartbeat notification is not sent.

heartbeatPeriodElement ("_heartbeatPeriod") Extensions for heartbeatPeriod

timeout If present, the maximum amount of time a server will allow before failing a notification attempt.

timeoutElement ("_timeout") Extensions for timeout

contentType The MIME type to send the payload in - e.g., application/fhir+xml or application/fhir+json. Note that:

  • clients may request notifications in a specific FHIR version by using the FHIR Version Parameter - e.g., application/fhir+json; fhirVersion=4.0.
  • additional MIME types can be allowed by channels - e.g., text/plain and text/html are defined by the Email channel.

contentTypeElement ("_contentType") Extensions for contentType

content How much of the resource content to deliver in the notification payload. The choices are an empty payload, only the resource id, or the full resource content.

contentElement ("_content") Extensions for content

maxCount If present, the maximum number of events that will be included in a notification bundle. Note that this is not a strict limit on the number of entries in a bundle, as dependent resources can be included.

maxCountElement ("_maxCount") Extensions for maxCount

Implementation

const factory Subscription({
  /// [resourceType] This is a Subscription resource
  @Default(R5ResourceType.Subscription)
  @JsonKey(unknownEnumValue: R5ResourceType.Subscription)
  R5ResourceType resourceType,
  @JsonKey(includeFromJson: true, includeToJson: false) int? dbId,

  /// [id] The logical id of the resource, as used in the URL for the
  ///  resource. Once assigned, this value never changes.
  @JsonKey(name: 'id') FhirId? fhirId,

  /// [meta] The metadata about the resource. This is content that is
  ///  maintained by the infrastructure. Changes to the content might not
  ///  always be associated with version changes to the resource.
  FhirMeta? meta,

  /// [implicitRules] A reference to a set of rules that were followed when
  ///  the resource was constructed, and which must be understood when
  ///  processing the content. Often, this is a reference to an
  ///  implementation guide that defines the special rules along with other
  ///  profiles etc.
  FhirUri? implicitRules,

  /// [implicitRulesElement] ("_implicitRules") Extensions for implicitRules
  @JsonKey(name: '_implicitRules') Element? implicitRulesElement,

  /// [language] The base language in which the resource is written.
  FhirCode? language,

  /// [languageElement] ("_language") Extensions for language
  @JsonKey(name: '_language') Element? languageElement,

  /// [text] A human-readable narrative that contains a summary of the
  ///  resource and can be used to represent the content of the resource to a
  ///  human. The narrative need not encode all the structured data, but is
  ///  required to contain sufficient detail to make it "clinically safe" for
  ///  a human to just read the narrative. Resource definitions may define
  ///  what content should be represented in the narrative to ensure clinical
  ///  safety.
  Narrative? text,

  /// [contained] These resources do not have an independent existence apart
  ///  from the resource that contains them - they cannot be identified
  ///  independently, nor can they have their own independent transaction
  ///  scope. This is allowed to be a Parameters resource if and only if it
  ///  is referenced by a resource that provides context/meaning.
  List<Resource>? contained,

  /// [extension_] ("extension") May be used to represent additional
  ///  information that is not part of the basic definition of the resource.
  ///  To make the use of extensions safe and managable, there is a strict
  ///  set of governance applied to the definition and use of extensions.
  ///  Though any implementer can define an extension, there is a set of
  ///  requirements that SHALL be met as part of the definition of the
  ///  extension.
  @JsonKey(name: 'extension') List<FhirExtension>? extension_,

  /// [modifierExtension] May be used to represent additional information
  ///  that is not part of the basic definition of the resource and that
  ///  modifies the understanding of the element that contains it and/or the
  ///  understanding of the containing element's descendants. Usually
  ///  modifier elements provide negation or qualification. To make the use
  ///  of extensions safe and managable, there is a strict set of governance
  ///  applied to the definition and use of extensions. Though any
  ///  implementer is allowed to define an extension, there is a set of
  ///  requirements that SHALL be met as part of the definition of the
  ///  extension. Applications processing a resource are required to check
  ///  for modifier extensions.Modifier extensions SHALL NOT change the
  ///  meaning of any elements on Resource or DomainResource (including
  ///  cannot change the meaning of modifierExtension itself).
  List<FhirExtension>? modifierExtension,

  /// [identifier] A formal identifier that is used to identify this code
  ///  system when it is represented in other formats, or referenced in a
  ///  specification, model, design or an instance.
  List<Identifier>? identifier,

  /// [name] A natural language name identifying the subscription.
  String? name,

  /// [nameElement] ("_name") Extensions for name
  @JsonKey(name: '_name') Element? nameElement,

  /// [status] The status of the subscription, which marks the server state
  ///  for managing the subscription.
  FhirCode? status,

  /// [statusElement] ("_status") Extensions for status
  @JsonKey(name: '_status') Element? statusElement,

  /// [topic] The reference to the subscription topic to be notified about.
  required FhirCanonical topic,

  /// [contact] Contact details for a human to contact about the
  ///  subscription. The primary use of this for system administrator
  ///  troubleshooting.
  List<ContactPoint>? contact,

  /// [end] The time for the server to turn the subscription off.
  FhirInstant? end,

  /// [endElement] ("_end") Extensions for end
  @JsonKey(name: '_end') Element? endElement,

  /// [managingEntity] Entity with authorization to make subsequent revisions
  ///  to the Subscription and also determines what data the subscription is
  ///  authorized to disclose.
  Reference? managingEntity,

  /// [reason] A description of why this subscription is defined.
  String? reason,

  /// [reasonElement] ("_reason") Extensions for reason
  @JsonKey(name: '_reason') Element? reasonElement,

  /// [filterBy] The filter properties to be applied to narrow the
  ///  subscription topic stream.  When multiple filters are applied,
  ///  evaluates to true if all the conditions applicable to that resource
  ///  are met; otherwise it returns false (i.e., logical AND).
  List<SubscriptionFilterBy>? filterBy,

  /// [channelType] The type of channel to send notifications on.
  required Coding channelType,

  /// [endpoint] The url that describes the actual end-point to send
  ///  notifications to.
  FhirUrl? endpoint,

  /// [endpointElement] ("_endpoint") Extensions for endpoint
  @JsonKey(name: '_endpoint') Element? endpointElement,

  /// [parameter] Channel-dependent information to send as part of the
  ///  notification (e.g., HTTP Headers).
  List<SubscriptionParameter>? parameter,

  /// [heartbeatPeriod] If present, a 'heartbeat' notification (keep-alive)
  ///  is sent via this channel with an interval period equal to this
  ///  elements integer value in seconds.  If not present, a heartbeat
  ///  notification is not sent.
  FhirUnsignedInt? heartbeatPeriod,

  /// [heartbeatPeriodElement] ("_heartbeatPeriod") Extensions for
  ///  heartbeatPeriod
  @JsonKey(name: '_heartbeatPeriod') Element? heartbeatPeriodElement,

  /// [timeout] If present, the maximum amount of time a server will allow
  ///  before failing a notification attempt.
  FhirUnsignedInt? timeout,

  /// [timeoutElement] ("_timeout") Extensions for timeout
  @JsonKey(name: '_timeout') Element? timeoutElement,

  /// [contentType] The MIME type to send the payload in - e.g.,
  ///  `application/fhir+xml` or `application/fhir+json`. Note that:
  /// * clients may request notifications in a specific FHIR version by using
  ///  the [FHIR Version Parameter](http.html#version-parameter) - e.g.,
  ///  `application/fhir+json; fhirVersion=4.0`.
  /// * additional MIME types can be allowed by channels - e.g., `text/plain`
  ///  and `text/html` are defined by the Email channel.
  FhirCode? contentType,

  /// [contentTypeElement] ("_contentType") Extensions for contentType
  @JsonKey(name: '_contentType') Element? contentTypeElement,

  /// [content] How much of the resource content to deliver in the
  ///  notification payload. The choices are an empty payload, only the
  ///  resource id, or the full resource content.
  FhirCode? content,

  /// [contentElement] ("_content") Extensions for content
  @JsonKey(name: '_content') Element? contentElement,

  /// [maxCount] If present, the maximum number of events that will be
  ///  included in a notification bundle. Note that this is not a strict
  ///  limit on the number of entries in a bundle, as dependent resources can
  ///  be included.
  FhirPositiveInt? maxCount,

  /// [maxCountElement] ("_maxCount") Extensions for maxCount
  @JsonKey(name: '_maxCount') Element? maxCountElement,
}) = _Subscription;