From 268c42057c2b4a792ce65ab298f74d0c19a73356 Mon Sep 17 00:00:00 2001
From: anssari1 <3754234+anssari1@users.noreply.github.com>
Date: Thu, 5 Dec 2024 13:24:08 +0000
Subject: [PATCH] chore: Publish v5.3.0-SNAPSHOT
---
code/README.md | 2 +-
code/pom.xml | 10 +-
.../sdk/rapid/models/TraderDetailsInner.kt | 5 +-
.../ChangeRoomDetailsOperationParams.kt | 74 +++++
.../operations/CommitChangeOperationParams.kt | 74 +++++
.../DeleteHeldBookingOperationParams.kt | 67 +++++
.../operations/DeleteRoomOperationParams.kt | 75 +++++
...etAdditionalAvailabilityOperationParams.kt | 190 ++++++++++++
.../GetAvailabilityOperationParams.kt | 275 ++++++++++++++++++
.../GetBookingReceiptOperationParams.kt | 19 ++
.../GetCalendarAvailabilityOperationParams.kt | 10 +
.../GetPaymentOptionsOperationParams.kt | 47 +++
.../GetPropertyContentOperationParams.kt | 247 ++++++++++++++++
.../GetPropertyGuestReviewsOperationParams.kt | 19 ++
.../operations/GetRegionOperationParams.kt | 10 +
.../operations/GetRegionsOperationParams.kt | 11 +
...ReservationByItineraryIdOperationParams.kt | 93 ++++++
.../GetReservationOperationParams.kt | 18 ++
.../PostItineraryOperationParams.kt | 61 ++++
.../PostPaymentSessionsOperationParams.kt | 58 ++++
.../operations/PriceCheckOperationParams.kt | 84 ++++++
...utCompletePaymentSessionOperationParams.kt | 66 +++++
.../PutResumeBookingOperationParams.kt | 66 +++++
23 files changed, 1571 insertions(+), 10 deletions(-)
diff --git a/code/README.md b/code/README.md
index e35bc0fe41..5bc512db28 100644
--- a/code/README.md
+++ b/code/README.md
@@ -5,7 +5,7 @@
com.expediagroup
rapid-sdk
- 5.2.0
+ 5.3.0-SNAPSHOT
```
diff --git a/code/pom.xml b/code/pom.xml
index 9db399bdc3..61093c688b 100644
--- a/code/pom.xml
+++ b/code/pom.xml
@@ -4,9 +4,9 @@
4.0.0
com.expediagroup
rapid-sdk
- 5.2.0
+ 5.3.0-SNAPSHOT
EG rapid-sdk for Java
- EG rapid-sdk v5.2.0
+ EG rapid-sdk v5.3.0-SNAPSHOT
https://github.com/ExpediaGroup/test-sdk
2022
jar
@@ -82,7 +82,7 @@
2.0.21
1.9.0
2.3.13
- 0.26.0
+ 0.26.1
2.0.16
1.7.0
3.2.7
@@ -131,7 +131,7 @@
com.fasterxml.jackson
jackson-bom
- 2.18.1
+ 2.18.2
pom
import
@@ -153,7 +153,7 @@
com.fasterxml.jackson.core
jackson-annotations
- 2.18.1
+ 2.18.2
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/models/TraderDetailsInner.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/models/TraderDetailsInner.kt
index d2ff0e80f6..1cca6c44f8 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/models/TraderDetailsInner.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/models/TraderDetailsInner.kt
@@ -33,8 +33,6 @@ package com.expediagroup.sdk.rapid.models
import com.expediagroup.sdk.core.model.exception.client.PropertyConstraintViolationException
import com.expediagroup.sdk.rapid.models.TraderAddress
import com.fasterxml.jackson.annotation.JsonProperty
-import com.fasterxml.jackson.annotation.JsonSetter
-import com.fasterxml.jackson.annotation.Nulls
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
import javax.validation.Valid
import javax.validation.Validation
@@ -55,10 +53,9 @@ import javax.validation.constraints.NotNull
data class TraderDetailsInner(
// The trader contact message.
@JsonProperty("contact_message")
- @JsonSetter(nulls = Nulls.AS_EMPTY)
@field:NotNull
@field:Valid
- val contactMessage: kotlin.String? = "",
+ val contactMessage: kotlin.String,
// The trader name.
@JsonProperty("name")
@field:Valid
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/ChangeRoomDetailsOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/ChangeRoomDetailsOperationParams.kt
index 7bfa1b39a1..6d7e22cb55 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/ChangeRoomDetailsOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/ChangeRoomDetailsOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -90,8 +92,18 @@ data class ChangeRoomDetailsOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -132,6 +144,68 @@ data class ChangeRoomDetailsOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: ChangeRoomDetailsOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val roomId =
+ params?.get("roomId")
+
+ roomId?.let {
+ builder.roomId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): ChangeRoomDetailsOperationParams {
val params =
ChangeRoomDetailsOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/CommitChangeOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/CommitChangeOperationParams.kt
index 97214d1cd5..0e644cf6b7 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/CommitChangeOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/CommitChangeOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -90,8 +92,18 @@ data class CommitChangeOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -132,6 +144,68 @@ data class CommitChangeOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: CommitChangeOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val roomId =
+ params?.get("roomId")
+
+ roomId?.let {
+ builder.roomId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): CommitChangeOperationParams {
val params =
CommitChangeOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteHeldBookingOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteHeldBookingOperationParams.kt
index 609ec032f3..5010955ede 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteHeldBookingOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteHeldBookingOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -84,9 +86,20 @@ data class DeleteHeldBookingOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error"),
+
POST_STAY_CANCEL("post_stay_cancel")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -121,6 +134,60 @@ data class DeleteHeldBookingOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: DeleteHeldBookingOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): DeleteHeldBookingOperationParams {
val params =
DeleteHeldBookingOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteRoomOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteRoomOperationParams.kt
index 440adfcef8..de5e777948 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteRoomOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/DeleteRoomOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -90,9 +92,20 @@ data class DeleteRoomOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error"),
+
POST_STAY_CANCEL("post_stay_cancel")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -133,6 +146,68 @@ data class DeleteRoomOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: DeleteRoomOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val roomId =
+ params?.get("roomId")
+
+ roomId?.let {
+ builder.roomId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): DeleteRoomOperationParams {
val params =
DeleteRoomOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAdditionalAvailabilityOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAdditionalAvailabilityOperationParams.kt
index 11e8c900fa..49a0806641 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAdditionalAvailabilityOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAdditionalAvailabilityOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -154,39 +156,88 @@ data class GetAdditionalAvailabilityOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error"),
+
NO_AVAILABILITY("no_availability"),
+
FORBIDDEN("forbidden")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Exclusion(
val value: kotlin.String
) {
REFUNDABLE_DAMAGE_DEPOSIT("refundable_damage_deposit"),
+
CARD_ON_FILE("card_on_file")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Filter(
val value: kotlin.String
) {
REFUNDABLE("refundable"),
+
EXPEDIA_COLLECT("expedia_collect"),
+
PROPERTY_COLLECT("property_collect")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Include(
val value: kotlin.String
) {
SALE_SCENARIO_PERIOD_MOBILE_PROMOTION("sale_scenario.mobile_promotion")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class RateOption(
val value: kotlin.String
) {
MEMBER("member"),
+
NET_RATES("net_rates"),
+
CROSS_SELL("cross_sell")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -305,6 +356,145 @@ data class GetAdditionalAvailabilityOperationParams
*/
fun currency(currency: kotlin.String) = apply { this.currency = currency }
+ companion object {
+ @JvmStatic
+ fun from(link: GetAdditionalAvailabilityOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val propertyId =
+ params?.get("propertyId")
+
+ propertyId?.let {
+ builder.propertyId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+ val checkin =
+ params?.get("checkin")
+
+ checkin?.let {
+ builder.checkin(
+ it
+ )
+ }
+ val checkout =
+ params?.get("checkout")
+
+ checkout?.let {
+ builder.checkout(
+ it
+ )
+ }
+ val exclusion =
+ params?.getAll("exclusion")
+ ?.mapNotNull { Exclusion.from(it) }
+ params?.get("exclusion")
+ ?.let { Exclusion.from(it) }
+
+ exclusion?.let {
+ builder.exclusion(
+ it
+ )
+ }
+ val filter =
+ params?.getAll("filter")
+ ?.mapNotNull { Filter.from(it) }
+ params?.get("filter")
+ ?.let { Filter.from(it) }
+
+ filter?.let {
+ builder.filter(
+ it
+ )
+ }
+ val include =
+ params?.getAll("include")
+ ?.mapNotNull { Include.from(it) }
+ params?.get("include")
+ ?.let { Include.from(it) }
+
+ include?.let {
+ builder.include(
+ it
+ )
+ }
+ val occupancy =
+ params?.getAll("occupancy")
+ params?.get("occupancy")
+
+ occupancy?.let {
+ builder.occupancy(
+ it
+ )
+ }
+ val rateOption =
+ params?.getAll("rateOption")
+ ?.mapNotNull { RateOption.from(it) }
+ params?.get("rateOption")
+ ?.let { RateOption.from(it) }
+
+ rateOption?.let {
+ builder.rateOption(
+ it
+ )
+ }
+ val salesChannel =
+ params?.get("salesChannel")
+
+ salesChannel?.let {
+ builder.salesChannel(
+ it
+ )
+ }
+ val currency =
+ params?.get("currency")
+
+ currency?.let {
+ builder.currency(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): GetAdditionalAvailabilityOperationParams {
val params =
GetAdditionalAvailabilityOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAvailabilityOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAvailabilityOperationParams.kt
index 7ed938e50b..76b8deac7e 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAvailabilityOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetAvailabilityOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -215,46 +217,104 @@ data class GetAvailabilityOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Exclusion(
val value: kotlin.String
) {
REFUNDABLE_DAMAGE_DEPOSIT("refundable_damage_deposit"),
+
CARD_ON_FILE("card_on_file")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Filter(
val value: kotlin.String
) {
REFUNDABLE("refundable"),
+
EXPEDIA_COLLECT("expedia_collect"),
+
PROPERTY_COLLECT("property_collect")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Include(
val value: kotlin.String
) {
UNAVAILABLE_REASON("unavailable_reason"),
+
SALE_SCENARIO_PERIOD_MOBILE_PROMOTION("sale_scenario.mobile_promotion"),
+
ROOMS_PERIOD_RATES_PERIOD_MARKETING_FEE_INCENTIVES("rooms.rates.marketing_fee_incentives")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class RateOption(
val value: kotlin.String
) {
MEMBER("member"),
+
NET_RATES("net_rates"),
+
CROSS_SELL("cross_sell")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class TravelPurpose(
val value: kotlin.String
) {
LEISURE("leisure"),
+
BUSINESS("business")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -439,6 +499,221 @@ data class GetAvailabilityOperationParams
*/
fun platformName(platformName: kotlin.String) = apply { this.platformName = platformName }
+ companion object {
+ @JvmStatic
+ fun from(link: GetAvailabilityOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val checkin =
+ params?.get("checkin")
+
+ checkin?.let {
+ builder.checkin(
+ it
+ )
+ }
+ val checkout =
+ params?.get("checkout")
+
+ checkout?.let {
+ builder.checkout(
+ it
+ )
+ }
+ val currency =
+ params?.get("currency")
+
+ currency?.let {
+ builder.currency(
+ it
+ )
+ }
+ val countryCode =
+ params?.get("countryCode")
+
+ countryCode?.let {
+ builder.countryCode(
+ it
+ )
+ }
+ val language =
+ params?.get("language")
+
+ language?.let {
+ builder.language(
+ it
+ )
+ }
+ val occupancy =
+ params?.getAll("occupancy")
+ params?.get("occupancy")
+
+ occupancy?.let {
+ builder.occupancy(
+ it
+ )
+ }
+ val propertyId =
+ params?.getAll("propertyId")
+ params?.get("propertyId")
+
+ propertyId?.let {
+ builder.propertyId(
+ it
+ )
+ }
+ val ratePlanCount =
+ params?.get("ratePlanCount")
+
+ ratePlanCount?.let {
+ builder.ratePlanCount(
+ it
+ .toBigDecimal()
+ )
+ }
+ val salesChannel =
+ params?.get("salesChannel")
+
+ salesChannel?.let {
+ builder.salesChannel(
+ it
+ )
+ }
+ val salesEnvironment =
+ params?.get("salesEnvironment")
+
+ salesEnvironment?.let {
+ builder.salesEnvironment(
+ it
+ )
+ }
+ val amenityCategory =
+ params?.getAll("amenityCategory")
+ params?.get("amenityCategory")
+
+ amenityCategory?.let {
+ builder.amenityCategory(
+ it
+ )
+ }
+ val exclusion =
+ params?.getAll("exclusion")
+ ?.mapNotNull { Exclusion.from(it) }
+ params?.get("exclusion")
+ ?.let { Exclusion.from(it) }
+
+ exclusion?.let {
+ builder.exclusion(
+ it
+ )
+ }
+ val filter =
+ params?.getAll("filter")
+ ?.mapNotNull { Filter.from(it) }
+ params?.get("filter")
+ ?.let { Filter.from(it) }
+
+ filter?.let {
+ builder.filter(
+ it
+ )
+ }
+ val include =
+ params?.getAll("include")
+ ?.mapNotNull { Include.from(it) }
+ params?.get("include")
+ ?.let { Include.from(it) }
+
+ include?.let {
+ builder.include(
+ it
+ )
+ }
+ val rateOption =
+ params?.getAll("rateOption")
+ ?.mapNotNull { RateOption.from(it) }
+ params?.get("rateOption")
+ ?.let { RateOption.from(it) }
+
+ rateOption?.let {
+ builder.rateOption(
+ it
+ )
+ }
+ val travelPurpose =
+ params?.get("travelPurpose")
+ ?.let { TravelPurpose.from(it) }
+
+ travelPurpose?.let {
+ builder.travelPurpose(
+ it
+ )
+ }
+ val billingTerms =
+ params?.get("billingTerms")
+
+ billingTerms?.let {
+ builder.billingTerms(
+ it
+ )
+ }
+ val partnerPointOfSale =
+ params?.get("partnerPointOfSale")
+
+ partnerPointOfSale?.let {
+ builder.partnerPointOfSale(
+ it
+ )
+ }
+ val paymentTerms =
+ params?.get("paymentTerms")
+
+ paymentTerms?.let {
+ builder.paymentTerms(
+ it
+ )
+ }
+ val platformName =
+ params?.get("platformName")
+
+ platformName?.let {
+ builder.platformName(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): GetAvailabilityOperationParams {
val params =
GetAvailabilityOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetBookingReceiptOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetBookingReceiptOperationParams.kt
index 810ebf2845..c891bd4c19 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetBookingReceiptOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetBookingReceiptOperationParams.kt
@@ -63,15 +63,34 @@ data class GetBookingReceiptOperationParams(
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Branding(
val value: kotlin.String
) {
EXPEDIA_GROUP("expedia_group"),
+
UNBRANDED("unbranded")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetCalendarAvailabilityOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetCalendarAvailabilityOperationParams.kt
index 3e694f6012..5248816aec 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetCalendarAvailabilityOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetCalendarAvailabilityOperationParams.kt
@@ -58,8 +58,18 @@ data class GetCalendarAvailabilityOperationParams(
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPaymentOptionsOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPaymentOptionsOperationParams.kt
index c4228cfd11..bb6357f111 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPaymentOptionsOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPaymentOptionsOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -100,6 +102,51 @@ data class GetPaymentOptionsOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: GetPaymentOptionsOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val propertyId =
+ params?.get("propertyId")
+
+ propertyId?.let {
+ builder.propertyId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): GetPaymentOptionsOperationParams {
val params =
GetPaymentOptionsOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyContentOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyContentOperationParams.kt
index b49c5c251a..42019a448d 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyContentOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyContentOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -256,7 +258,16 @@ data class GetPropertyContentOperationParams
val value: kotlin.String
) {
EXPEDIA_COLLECT("expedia_collect"),
+
PROPERTY_COLLECT("property_collect")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -489,6 +500,242 @@ data class GetPropertyContentOperationParams
*/
fun platformName(platformName: kotlin.String) = apply { this.platformName = platformName }
+ companion object {
+ @JvmStatic
+ fun from(link: GetPropertyContentOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val language =
+ params?.get("language")
+
+ language?.let {
+ builder.language(
+ it
+ )
+ }
+ val supplySource =
+ params?.get("supplySource")
+
+ supplySource?.let {
+ builder.supplySource(
+ it
+ )
+ }
+ val allInclusive =
+ params?.getAll("allInclusive")
+ params?.get("allInclusive")
+
+ allInclusive?.let {
+ builder.allInclusive(
+ it
+ )
+ }
+ val amenityId =
+ params?.getAll("amenityId")
+ params?.get("amenityId")
+
+ amenityId?.let {
+ builder.amenityId(
+ it
+ )
+ }
+ val attributeId =
+ params?.getAll("attributeId")
+ params?.get("attributeId")
+
+ attributeId?.let {
+ builder.attributeId(
+ it
+ )
+ }
+ val brandId =
+ params?.getAll("brandId")
+ params?.get("brandId")
+
+ brandId?.let {
+ builder.brandId(
+ it
+ )
+ }
+ val businessModel =
+ params?.getAll("businessModel")
+ ?.mapNotNull { BusinessModel.from(it) }
+ params?.get("businessModel")
+ ?.let { BusinessModel.from(it) }
+
+ businessModel?.let {
+ builder.businessModel(
+ it
+ )
+ }
+ val categoryId =
+ params?.getAll("categoryId")
+ params?.get("categoryId")
+
+ categoryId?.let {
+ builder.categoryId(
+ it
+ )
+ }
+ val categoryIdExclude =
+ params?.getAll("categoryIdExclude")
+ params?.get("categoryIdExclude")
+
+ categoryIdExclude?.let {
+ builder.categoryIdExclude(
+ it
+ )
+ }
+ val chainId =
+ params?.getAll("chainId")
+ params?.get("chainId")
+
+ chainId?.let {
+ builder.chainId(
+ it
+ )
+ }
+ val countryCode =
+ params?.getAll("countryCode")
+ params?.get("countryCode")
+
+ countryCode?.let {
+ builder.countryCode(
+ it
+ )
+ }
+ val dateAddedEnd =
+ params?.get("dateAddedEnd")
+
+ dateAddedEnd?.let {
+ builder.dateAddedEnd(
+ it
+ )
+ }
+ val dateAddedStart =
+ params?.get("dateAddedStart")
+
+ dateAddedStart?.let {
+ builder.dateAddedStart(
+ it
+ )
+ }
+ val dateUpdatedEnd =
+ params?.get("dateUpdatedEnd")
+
+ dateUpdatedEnd?.let {
+ builder.dateUpdatedEnd(
+ it
+ )
+ }
+ val dateUpdatedStart =
+ params?.get("dateUpdatedStart")
+
+ dateUpdatedStart?.let {
+ builder.dateUpdatedStart(
+ it
+ )
+ }
+ val include =
+ params?.getAll("include")
+ params?.get("include")
+
+ include?.let {
+ builder.include(
+ it
+ )
+ }
+ val multiUnit =
+ params?.get("multiUnit")
+
+ multiUnit?.let {
+ builder.multiUnit(
+ it
+ .toBoolean()
+ )
+ }
+ val propertyId =
+ params?.getAll("propertyId")
+ params?.get("propertyId")
+
+ propertyId?.let {
+ builder.propertyId(
+ it
+ )
+ }
+ val propertyRatingMax =
+ params?.get("propertyRatingMax")
+
+ propertyRatingMax?.let {
+ builder.propertyRatingMax(
+ it
+ )
+ }
+ val propertyRatingMin =
+ params?.get("propertyRatingMin")
+
+ propertyRatingMin?.let {
+ builder.propertyRatingMin(
+ it
+ )
+ }
+ val spokenLanguageId =
+ params?.getAll("spokenLanguageId")
+ params?.get("spokenLanguageId")
+
+ spokenLanguageId?.let {
+ builder.spokenLanguageId(
+ it
+ )
+ }
+ val billingTerms =
+ params?.get("billingTerms")
+
+ billingTerms?.let {
+ builder.billingTerms(
+ it
+ )
+ }
+ val partnerPointOfSale =
+ params?.get("partnerPointOfSale")
+
+ partnerPointOfSale?.let {
+ builder.partnerPointOfSale(
+ it
+ )
+ }
+ val paymentTerms =
+ params?.get("paymentTerms")
+
+ paymentTerms?.let {
+ builder.paymentTerms(
+ it
+ )
+ }
+ val platformName =
+ params?.get("platformName")
+
+ platformName?.let {
+ builder.platformName(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): GetPropertyContentOperationParams {
val params =
GetPropertyContentOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyGuestReviewsOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyGuestReviewsOperationParams.kt
index 2ad991a1b3..fdc4eda3bf 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyGuestReviewsOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetPropertyGuestReviewsOperationParams.kt
@@ -79,15 +79,34 @@ data class GetPropertyGuestReviewsOperationParams(
val value: kotlin.String
) {
LANGUAGE("language")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class TripReason(
val value: kotlin.String
) {
BUSINESS("business"),
+
LEISURE("leisure"),
+
FRIENDS_AND_FAMILY("friends_and_family"),
+
BUSINESS_AND_LEISURE("business_and_leisure")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionOperationParams.kt
index 366b5dcd7c..83086c72ba 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionOperationParams.kt
@@ -78,8 +78,18 @@ data class GetRegionOperationParams(
val value: kotlin.String
) {
DETAILS("details"),
+
PROPERTY_IDS("property_ids"),
+
PROPERTY_IDS_EXPANDED("property_ids_expanded")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionsOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionsOperationParams.kt
index 243877aaa4..f5a55d10b7 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionsOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetRegionsOperationParams.kt
@@ -108,9 +108,20 @@ data class GetRegionsOperationParams(
val value: kotlin.String
) {
STANDARD("standard"),
+
DETAILS("details"),
+
PROPERTY_IDS("property_ids"),
+
PROPERTY_IDS_EXPANDED("property_ids_expanded")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationByItineraryIdOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationByItineraryIdOperationParams.kt
index e6a0efc21f..d3e6d1229d 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationByItineraryIdOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationByItineraryIdOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -99,14 +101,32 @@ data class GetReservationByItineraryIdOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Include(
val value: kotlin.String
) {
HISTORY("history")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -159,6 +179,79 @@ data class GetReservationByItineraryIdOperationParams
>
) = apply { this.include = include }
+ companion object {
+ @JvmStatic
+ fun from(link: GetReservationByItineraryIdOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+ val email =
+ params?.get("email")
+
+ email?.let {
+ builder.email(
+ it
+ )
+ }
+ val include =
+ params?.getAll("include")
+ ?.mapNotNull { Include.from(it) }
+ params?.get("include")
+ ?.let { Include.from(it) }
+
+ include?.let {
+ builder.include(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): GetReservationByItineraryIdOperationParams {
val params =
GetReservationByItineraryIdOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationOperationParams.kt
index 162841069c..1c6569417c 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/GetReservationOperationParams.kt
@@ -65,14 +65,32 @@ data class GetReservationOperationParams(
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
enum class Include(
val value: kotlin.String
) {
HISTORY("history")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostItineraryOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostItineraryOperationParams.kt
index dd4e3c92e1..32991474f1 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostItineraryOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostItineraryOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -78,11 +80,24 @@ data class PostItineraryOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error"),
+
PRICE_MISMATCH("price_mismatch"),
+
CC_DECLINED("cc_declined"),
+
ROOMS_UNAVAILABLE("rooms_unavailable")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -111,6 +126,52 @@ data class PostItineraryOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: PostItineraryOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): PostItineraryOperationParams {
val params =
PostItineraryOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostPaymentSessionsOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostPaymentSessionsOperationParams.kt
index 0ab2b08411..7beaa31f5f 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostPaymentSessionsOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PostPaymentSessionsOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -78,8 +80,18 @@ data class PostPaymentSessionsOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -108,6 +120,52 @@ data class PostPaymentSessionsOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: PostPaymentSessionsOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): PostPaymentSessionsOperationParams {
val params =
PostPaymentSessionsOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PriceCheckOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PriceCheckOperationParams.kt
index 0451ce128d..28cdc47b7f 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PriceCheckOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PriceCheckOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -96,10 +98,22 @@ data class PriceCheckOperationParams
val value: kotlin.String
) {
AVAILABLE("available"),
+
PRICE_CHANGED("price_changed"),
+
SOLD_OUT("sold_out"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
UNKNOWN_INTERNAL_ERROR("unknown_internal_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -146,6 +160,76 @@ data class PriceCheckOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: PriceCheckOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val propertyId =
+ params?.get("propertyId")
+
+ propertyId?.let {
+ builder.propertyId(
+ it
+ )
+ }
+ val roomId =
+ params?.get("roomId")
+
+ roomId?.let {
+ builder.roomId(
+ it
+ )
+ }
+ val rateId =
+ params?.get("rateId")
+
+ rateId?.let {
+ builder.rateId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): PriceCheckOperationParams {
val params =
PriceCheckOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutCompletePaymentSessionOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutCompletePaymentSessionOperationParams.kt
index f4ad24a7a5..36905874be 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutCompletePaymentSessionOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutCompletePaymentSessionOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -84,8 +86,18 @@ data class PutCompletePaymentSessionOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -120,6 +132,60 @@ data class PutCompletePaymentSessionOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: PutCompletePaymentSessionOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): PutCompletePaymentSessionOperationParams {
val params =
PutCompletePaymentSessionOperationParams(
diff --git a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutResumeBookingOperationParams.kt b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutResumeBookingOperationParams.kt
index 9fa3fa241d..4286e415d0 100644
--- a/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutResumeBookingOperationParams.kt
+++ b/code/src/main/kotlin/com/expediagroup/sdk/rapid/operations/PutResumeBookingOperationParams.kt
@@ -21,7 +21,9 @@ import com.fasterxml.jackson.annotation.JsonProperty
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
import io.ktor.http.Headers
import io.ktor.http.Parameters
+import io.ktor.http.parseUrlEncodedParameters
import org.hibernate.validator.messageinterpolation.ParameterMessageInterpolator
+import java.net.URI
import javax.validation.Valid
import javax.validation.Validation
import javax.validation.constraints.NotNull
@@ -84,8 +86,18 @@ data class PutResumeBookingOperationParams
val value: kotlin.String
) {
STANDARD("standard"),
+
SERVICE_UNAVAILABLE("service_unavailable"),
+
INTERNAL_SERVER_ERROR("internal_server_error")
+
+ ;
+
+ companion object {
+ private val map = entries.associateBy { it.value }
+
+ infix fun from(value: kotlin.String) = map[value]
+ }
}
class Builder(
@@ -120,6 +132,60 @@ data class PutResumeBookingOperationParams
*/
fun token(token: kotlin.String) = apply { this.token = token }
+ companion object {
+ @JvmStatic
+ fun from(link: PutResumeBookingOperationLink): Builder {
+ val uri = link.href?.let { URI(it) }
+ val params = uri?.query?.parseUrlEncodedParameters()
+
+ val builder = Builder()
+
+ val itineraryId =
+ params?.get("itineraryId")
+
+ itineraryId?.let {
+ builder.itineraryId(
+ it
+ )
+ }
+ val customerIp =
+ params?.get("customerIp")
+
+ customerIp?.let {
+ builder.customerIp(
+ it
+ )
+ }
+ val customerSessionId =
+ params?.get("customerSessionId")
+
+ customerSessionId?.let {
+ builder.customerSessionId(
+ it
+ )
+ }
+ val test =
+ params?.get("test")
+ ?.let { Test.from(it) }
+
+ test?.let {
+ builder.test(
+ it
+ )
+ }
+ val token =
+ params?.get("token")
+
+ token?.let {
+ builder.token(
+ it
+ )
+ }
+
+ return builder
+ }
+ }
+
fun build(): PutResumeBookingOperationParams {
val params =
PutResumeBookingOperationParams(