Skip to content

Commit 779d51b

Browse files
committed
chore: update fueling API to 2024-2
BREAKING CHANGE: Update Fueling API
1 parent e822fd3 commit 779d51b

20 files changed

+165
-28
lines changed

library/src/main/java/cloud/pace/sdk/api/fueling/FuelingAPI.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import cloud.pace.sdk.api.API
1212
/** Fueling API */
1313
object FuelingAPI {
1414

15-
const val VERSION = "2022-1"
15+
const val VERSION = "2024-2"
1616
internal val baseUrl = "${API.baseUrl}/fueling/$VERSION/"
1717

1818
class DiscountAPI

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/ApproachingResponseModel.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ class ApproachingResponse : Resource() {
3030
private var transactions: HasMany<Transaction> = HasMany()
3131
fun getTransactions() = transactions.get(document)
3232

33+
private var unsupportedPaymentMethodKinds: HasMany<PaymentMethodKind> = HasMany()
34+
fun getUnsupportedPaymentMethodKinds() = unsupportedPaymentMethodKinds.get(document)
35+
3336
private var unsupportedPaymentMethods: HasMany<PaymentMethod> = HasMany()
3437
fun getUnsupportedPaymentMethods() = unsupportedPaymentMethods.get(document)
3538
}

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/FuelPriceModel.kt

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ class FuelPrice : Resource() {
6666
@Json(name = "dieselGtl")
6767
DIESELGTL("dieselGtl"),
6868

69+
@SerializedName("dieselB0")
70+
@Json(name = "dieselB0")
71+
DIESELB0("dieselB0"),
72+
6973
@SerializedName("dieselB7")
7074
@Json(name = "dieselB7")
7175
DIESELB7("dieselB7"),
@@ -74,10 +78,30 @@ class FuelPrice : Resource() {
7478
@Json(name = "dieselB15")
7579
DIESELB15("dieselB15"),
7680

81+
@SerializedName("dieselB20")
82+
@Json(name = "dieselB20")
83+
DIESELB20("dieselB20"),
84+
85+
@SerializedName("dieselBMix")
86+
@Json(name = "dieselBMix")
87+
DIESELBMIX("dieselBMix"),
88+
7789
@SerializedName("dieselPremium")
7890
@Json(name = "dieselPremium")
7991
DIESELPREMIUM("dieselPremium"),
8092

93+
@SerializedName("dieselHvo")
94+
@Json(name = "dieselHvo")
95+
DIESELHVO("dieselHvo"),
96+
97+
@SerializedName("dieselRed")
98+
@Json(name = "dieselRed")
99+
DIESELRED("dieselRed"),
100+
101+
@SerializedName("dieselSynthetic")
102+
@Json(name = "dieselSynthetic")
103+
DIESELSYNTHETIC("dieselSynthetic"),
104+
81105
@SerializedName("lpg")
82106
@Json(name = "lpg")
83107
LPG("lpg"),

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/FuelPriceResponseModel.kt

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ class FuelPriceResponse : Resource() {
6666
@Json(name = "dieselGtl")
6767
DIESELGTL("dieselGtl"),
6868

69+
@SerializedName("dieselB0")
70+
@Json(name = "dieselB0")
71+
DIESELB0("dieselB0"),
72+
6973
@SerializedName("dieselB7")
7074
@Json(name = "dieselB7")
7175
DIESELB7("dieselB7"),
@@ -74,10 +78,30 @@ class FuelPriceResponse : Resource() {
7478
@Json(name = "dieselB15")
7579
DIESELB15("dieselB15"),
7680

81+
@SerializedName("dieselB20")
82+
@Json(name = "dieselB20")
83+
DIESELB20("dieselB20"),
84+
85+
@SerializedName("dieselBMix")
86+
@Json(name = "dieselBMix")
87+
DIESELBMIX("dieselBMix"),
88+
7789
@SerializedName("dieselPremium")
7890
@Json(name = "dieselPremium")
7991
DIESELPREMIUM("dieselPremium"),
8092

93+
@SerializedName("dieselHvo")
94+
@Json(name = "dieselHvo")
95+
DIESELHVO("dieselHvo"),
96+
97+
@SerializedName("dieselRed")
98+
@Json(name = "dieselRed")
99+
DIESELRED("dieselRed"),
100+
101+
@SerializedName("dieselSynthetic")
102+
@Json(name = "dieselSynthetic")
103+
DIESELSYNTHETIC("dieselSynthetic"),
104+
81105
@SerializedName("lpg")
82106
@Json(name = "lpg")
83107
LPG("lpg"),

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/PaymentMethodKindModel.kt

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,22 +41,15 @@ This field is optional and if not present should be assumed to indicate `implici
4141
/* data privacy information */
4242
class DataPrivacy {
4343

44-
/* Localized hint that data privacy terms apply. The hint comes formatted in multiple ways, which are all equally valid if given. Additional formats might be added in the future. */
45-
var hint: Hint? = null
46-
4744
/* Localized data privacy terms. The terms come formatted in multiple ways, which are all equally valid if given. Additional formats might be added in the future. */
4845
var terms: Terms? = null
4946

50-
/* Localized hint that data privacy terms apply. The hint comes formatted in multiple ways, which are all equally valid if given. Additional formats might be added in the future. */
51-
class Hint {
52-
53-
/* Hint formatted as markdown. Contains only links to the reference <code>terms</code>. Does not contain other links. Other than that, only contains markdown syntax for <a href="https://daringfireball.net/projects/markdown/syntax#p">Paragraphs and Line Breaks</a> and <a href="https://daringfireball.net/projects/markdown/syntax#em">Emphasis</a>. */
54-
var markdown: String? = null
55-
}
56-
5747
/* Localized data privacy terms. The terms come formatted in multiple ways, which are all equally valid if given. Additional formats might be added in the future. */
5848
class Terms {
5949

50+
/* Terms formatted as markdown. Does not contain external resources like images. */
51+
var html: String? = null
52+
6053
/* Terms formatted as markdown. Does not contain external resources like images. */
6154
var markdown: String? = null
6255
}

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/ProcessPaymentResponseModel.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ class ProcessPaymentResponse : Resource() {
2020

2121
/* Amount that was discounted. Only if any discounts were applied earlier. */
2222
var discountAmount: Double? = null
23+
24+
/* Driver/vehicle identification */
25+
var driverVehicleID: String? = null
2326
var gasStationId: String? = null
2427

2528
/* Mileage in meters */
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/*
2+
* PLEASE DO NOT EDIT!
3+
*
4+
* Generated by SwagGen with Kotlin template.
5+
* https://github.com/pace/SwagGen
6+
*/
7+
8+
package cloud.pace.sdk.api.fueling.generated.model
9+
10+
class Product {
11+
12+
var name: String? = null
13+
}

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/PumpModel.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ class Pump : Resource() {
1717

1818
var vat: VAT? = null
1919

20+
/* Only if status is locked: available fuel products at the given pump */
21+
var availableProducts: List<Product>? = null
22+
2023
/* Currency as specified in ISO-4217. */
2124
var currency: String? = null
2225

library/src/main/java/cloud/pace/sdk/api/fueling/generated/model/PumpResponseModel.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ class PumpResponse : Resource() {
1717

1818
var vat: VAT? = null
1919

20+
/* Only if status is locked: available fuel products at the given pump */
21+
var availableProducts: List<Product>? = null
22+
2023
/* Currency as specified in ISO-4217. */
2124
var currency: String? = null
2225

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/*
2+
* PLEASE DO NOT EDIT!
3+
*
4+
* Generated by SwagGen with Kotlin template.
5+
* https://github.com/pace/SwagGen
6+
*/
7+
8+
package cloud.pace.sdk.api.fueling.generated.model
9+
10+
class TransactionMetadata {
11+
12+
var key: String? = null
13+
var value: String? = null
14+
}

0 commit comments

Comments
 (0)