Skip to content

Commit

Permalink
Update data models to include accessChannel (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
openactive-bot authored Mar 1, 2021
1 parent 8366348 commit dbce867
Show file tree
Hide file tree
Showing 9 changed files with 65 additions and 31 deletions.
6 changes: 3 additions & 3 deletions OpenActive.NET.Generator/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion OpenActive.NET.Generator/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"author": "Nick Evans",
"license": "MIT",
"dependencies": {
"@openactive/data-models": "^2.0.170",
"@openactive/data-models": "^2.0.174",
"fs-extra": "^7.0.1",
"sync-request": "^6.0.0"
}
Expand Down
2 changes: 1 addition & 1 deletion OpenActive.NET/models/Course.cs
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ public override string ToString()
/// <example>
/// <code>
/// "author": {
/// "name": "Central Speedball Association",
/// "@type": "Organization",
/// "name": "Central Speedball Association",
/// "url": "http://www.speedball-world.com"
/// }
/// </code>
Expand Down
2 changes: 1 addition & 1 deletion OpenActive.NET/models/DataCatalog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,8 @@ public override string ToString()
/// <example>
/// <code>
/// "publisher": {
/// "@type": "Organization",
/// "name": "Central Speedball Association",
/// "type": "Organization",
/// "url": "http://www.speedball-world.com"
/// }
/// </code>
Expand Down
2 changes: 1 addition & 1 deletion OpenActive.NET/models/Dataset.cs
Original file line number Diff line number Diff line change
Expand Up @@ -229,8 +229,8 @@ public override string ToString()
/// <example>
/// <code>
/// "publisher": {
/// "@type": "Organization",
/// "name": "Central Speedball Association",
/// "type": "Organization",
/// "url": "http://www.speedball-world.com"
/// }
/// </code>
Expand Down
2 changes: 1 addition & 1 deletion OpenActive.NET/models/Event.cs
Original file line number Diff line number Diff line change
Expand Up @@ -479,8 +479,8 @@ public override string ToString()
/// <example>
/// <code>
/// "organizer": {
/// "name": "Central Speedball Association",
/// "@type": "Organization",
/// "name": "Central Speedball Association",
/// "url": "http://www.speedball-world.com"
/// }
/// </code>
Expand Down
2 changes: 1 addition & 1 deletion OpenActive.NET/models/FacilityUse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -315,8 +315,8 @@ public override string ToString()
/// <example>
/// <code>
/// "provider": {
/// "name": "Central Speedball Association",
/// "@type": "Organization",
/// "name": "Central Speedball Association",
/// "url": "http://www.speedball-world.com"
/// }
/// </code>
Expand Down
44 changes: 26 additions & 18 deletions OpenActive.NET/models/OrderItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,114 +55,122 @@ public override string ToString()
public new virtual Offer AcceptedOffer { get; set; }


/// <summary>
/// Channel through which the user can participate in the Opportunity. Not applicable for an OrderQuote.
/// </summary>
[DataMember(Name = "accessChannel", EmitDefaultValue = false, Order = 8)]
[JsonConverter(typeof(ValuesConverter))]
public virtual VirtualLocation AccessChannel { get; set; }


/// <summary>
/// PropertyValue that contains a text value usable for entrance. Not applicable for an OrderQuote.
/// </summary>
[DataMember(Name = "accessCode", EmitDefaultValue = false, Order = 8)]
[DataMember(Name = "accessCode", EmitDefaultValue = false, Order = 9)]
[JsonConverter(typeof(ValuesConverter))]
public new virtual List<PropertyValue> AccessCode { get; set; }


/// <summary>
/// ImageObject or Barcode that contains reference to an asset (e.g. Barcode, QR code image or PDF) usable for entrance. Not applicable for an OrderQuote.
/// </summary>
[DataMember(Name = "accessPass", EmitDefaultValue = false, Order = 9)]
[DataMember(Name = "accessPass", EmitDefaultValue = false, Order = 10)]
[JsonConverter(typeof(ValuesConverter))]
public virtual List<ImageObject> AccessPass { get; set; }


/// <summary>
/// Whether the event can be cancelled.
/// </summary>
[DataMember(Name = "allowCustomerCancellationFullRefund", EmitDefaultValue = false, Order = 10)]
[DataMember(Name = "allowCustomerCancellationFullRefund", EmitDefaultValue = false, Order = 11)]
[JsonConverter(typeof(ValuesConverter))]
public virtual bool? AllowCustomerCancellationFullRefund { get; set; }


/// <summary>
///
/// The person attending the Opportunity related to the OrderItem.
/// </summary>
[DataMember(Name = "attendee", EmitDefaultValue = false, Order = 11)]
[DataMember(Name = "attendee", EmitDefaultValue = false, Order = 12)]
[JsonConverter(typeof(ValuesConverter))]
public new virtual Person Attendee { get; set; }


/// <summary>
///
/// The properties of `schema:Person` that are required to describe an `attendee` for this `OrderItem`.
/// </summary>
[DataMember(Name = "attendeeDetailsRequired", EmitDefaultValue = false, Order = 12)]
[DataMember(Name = "attendeeDetailsRequired", EmitDefaultValue = false, Order = 13)]
[JsonConverter(typeof(ValuesConverter))]
public virtual List<Uri> AttendeeDetailsRequired { get; set; }


/// <summary>
/// A message set by the Seller in the event of Opportunity cancellation, only applicable for an Order and where the OrderItem has orderItemStatus set to https://openactive.io/SellerCancelled
/// A message set by the Seller in the event of Opportunity cancellation, only applicable for an `Order` and where the `OrderItem` has `orderItemStatus` set to `https://openactive.io/SellerCancelled`
/// </summary>
[DataMember(Name = "cancellationMessage", EmitDefaultValue = false, Order = 13)]
[DataMember(Name = "cancellationMessage", EmitDefaultValue = false, Order = 14)]
[JsonConverter(typeof(ValuesConverter))]
public virtual string CancellationMessage { get; set; }


/// <summary>
/// A message set by the Seller to trigger a notification to the Customer, only applicable for an Order and where the OrderItem has orderItemStatus set to https://openactive.io/OrderItemConfirmed or https://openactive.io/CustomerAttended
/// A message set by the Seller to trigger a notification to the Customer, only applicable for an `Order` and where the `OrderItem` has `orderItemStatus` set to `https://openactive.io/OrderItemConfirmed` or `https://openactive.io/CustomerAttended`
/// </summary>
[DataMember(Name = "customerNotice", EmitDefaultValue = false, Order = 14)]
[DataMember(Name = "customerNotice", EmitDefaultValue = false, Order = 15)]
[JsonConverter(typeof(ValuesConverter))]
public virtual string CustomerNotice { get; set; }


/// <summary>
/// Array of errors related to the OrderItem being included in the Order, only applicable for an OrderQuote.
/// </summary>
[DataMember(Name = "error", EmitDefaultValue = false, Order = 15)]
[DataMember(Name = "error", EmitDefaultValue = false, Order = 16)]
[JsonConverter(typeof(ValuesConverter))]
public new virtual List<OpenBookingError> Error { get; set; }


/// <summary>
/// The specific bookable Thing that has been selected by the Customer. See the [Modelling-Opportunity-Data] for more information on these types. Note that the Broker Request and Orders feed only require id within these objects to be included; in these contexts, all other properties are ignored.
/// </summary>
[DataMember(Name = "orderedItem", EmitDefaultValue = false, Order = 16)]
[DataMember(Name = "orderedItem", EmitDefaultValue = false, Order = 17)]
[JsonConverter(typeof(ValuesConverter))]
public new virtual Event OrderedItem { get; set; }


/// <summary>
/// PropertyValueSpecifications that describe fields in the orderItemIntakeForm.
/// </summary>
[DataMember(Name = "orderItemIntakeForm", EmitDefaultValue = false, Order = 17)]
[DataMember(Name = "orderItemIntakeForm", EmitDefaultValue = false, Order = 18)]
[JsonConverter(typeof(ValuesConverter))]
public virtual List<PropertyValueSpecification> OrderItemIntakeForm { get; set; }


/// <summary>
/// PropertyValues that contains a text value responses to the orderItemIntakeForm.
/// </summary>
[DataMember(Name = "orderItemIntakeFormResponse", EmitDefaultValue = false, Order = 18)]
[DataMember(Name = "orderItemIntakeFormResponse", EmitDefaultValue = false, Order = 19)]
[JsonConverter(typeof(ValuesConverter))]
public virtual List<PropertyValue> OrderItemIntakeFormResponse { get; set; }


/// <summary>
///
/// </summary>
[DataMember(Name = "orderItemStatus", EmitDefaultValue = false, Order = 19)]
[DataMember(Name = "orderItemStatus", EmitDefaultValue = false, Order = 20)]
[JsonConverter(typeof(ValuesConverter))]
public new virtual OrderItemStatus? OrderItemStatus { get; set; }


/// <summary>
/// An integer representing the order of OrderItems within the array.
/// </summary>
[DataMember(Name = "position", EmitDefaultValue = false, Order = 20)]
[DataMember(Name = "position", EmitDefaultValue = false, Order = 21)]
[JsonConverter(typeof(ValuesConverter))]
public new virtual long? Position { get; set; }


/// <summary>
/// Breakdown of tax payable for the OrderItem.
/// </summary>
[DataMember(Name = "unitTaxSpecification", EmitDefaultValue = false, Order = 21)]
[DataMember(Name = "unitTaxSpecification", EmitDefaultValue = false, Order = 22)]
[JsonConverter(typeof(ValuesConverter))]
public virtual List<TaxChargeSpecification> UnitTaxSpecification { get; set; }

Expand Down
34 changes: 30 additions & 4 deletions OpenActive.NET/models/VirtualLocation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ public override string ToString()


/// <summary>
/// The name of the livestream.
/// The name of the service that is providing remote access to the Opportunity.
/// </summary>
/// <example>
/// <code>
/// "name": "Zoom Room"
/// "name": "Zoom"
/// </code>
/// </example>
[DataMember(Name = "name", EmitDefaultValue = false, Order = 7)]
Expand All @@ -74,14 +74,40 @@ public override string ToString()


/// <summary>
/// The URL for the livestream.
/// The password or pin required to access the `VirtualLocation` from any device, without requiring the URL, e.g. the meeting password.
/// </summary>
/// <example>
/// <code>
/// "accessCode": "211277"
/// </code>
/// </example>
[DataMember(Name = "accessCode", EmitDefaultValue = false, Order = 9)]
[JsonConverter(typeof(ValuesConverter))]
public virtual string AccessCode { get; set; }


/// <summary>
/// The identifier required to access the `VirtualLocation` from any device, without requiring the URL, e.g. the meeting ID.
/// </summary>
/// <example>
/// <code>
/// "accessId": "123456789"
/// </code>
/// </example>
[DataMember(Name = "accessId", EmitDefaultValue = false, Order = 10)]
[JsonConverter(typeof(ValuesConverter))]
public virtual string AccessId { get; set; }


/// <summary>
/// The URL that enables remote access to the Opportunity, which should include encoded access credentials where possible.
/// </summary>
/// <example>
/// <code>
/// "url": "https://zoom.us/room/3fbCs0GVjgQ"
/// </code>
/// </example>
[DataMember(Name = "url", EmitDefaultValue = false, Order = 9)]
[DataMember(Name = "url", EmitDefaultValue = false, Order = 11)]
[JsonConverter(typeof(ValuesConverter))]
public virtual Uri Url { get; set; }

Expand Down

0 comments on commit dbce867

Please sign in to comment.