package payp.mard2p.api.v0.models import com.fasterxml.jackson.annotation.JsonIgnoreProperties import com.fasterxml.jackson.annotation.JsonProperty import java.io.Serializable import kotlin.Double import kotlin.Int import kotlin.Long import kotlin.String /** * This code was generated by [models.generator.kotlin.KotlinGenerator] * Payment is defined by the app specifically to emit users transactions. */ @JsonIgnoreProperties(ignoreUnknown=true) data class Payment( @JsonProperty("payid") @get:JsonProperty("payid") val payid: Long, @JsonProperty("actorid") @get:JsonProperty("actorid") val actorid: String, @JsonProperty("amount") @get:JsonProperty("amount") val amount: Double, @JsonProperty("ref_accountid") @get:JsonProperty("ref_accountid") val refAccountid: Long, @JsonProperty("payment_method") @get:JsonProperty("payment_method") val paymentMethod: String, @JsonProperty("operatorid") @get:JsonProperty("operatorid") val operatorid: String, @JsonProperty("phone") @get:JsonProperty("phone") val phone: Long, @JsonProperty("pin") @get:JsonProperty("pin") val pin: Int, @JsonProperty("currency") @get:JsonProperty("currency") val currency: String, @JsonProperty("payment_context") @get:JsonProperty("payment_context") val paymentContext: String ) : Serializable { fun toJsonString(): String = payp.mard2p.api.v0.models.JacksonObjectMapperFactory.create().writeValueAsString(this) companion object { fun parseJson(json: String): Payment = payp.mard2p.api.v0.models.JacksonObjectMapperFactory.create().readValue( json, Payment::class.java) } }