Current section

Files

Jump to
mollie_api lib mollie_api model entity_payment_link.ex
Raw

lib/mollie_api/model/entity_payment_link.ex

# NOTE: This file is auto generated by OpenAPI Generator 7.17.0 (https://openapi-generator.tech).
# Do not edit this file manually.
defmodule MollieAPI.Model.EntityPaymentLink do
@moduledoc """
"""
@derive JSON.Encoder
defstruct [
:resource,
:id,
:mode,
:description,
:amount,
:minimumAmount,
:archived,
:redirectUrl,
:webhookUrl,
:lines,
:billingAddress,
:shippingAddress,
:profileId,
:reusable,
:createdAt,
:paidAt,
:expiresAt,
:allowedMethods,
:applicationFee,
:sequenceType,
:customerId,
:testmode,
:_links
]
@type t :: %__MODULE__{
:resource => String.t | nil,
:id => String.t | nil,
:mode => MollieAPI.Model.Mode.t | nil,
:description => String.t | nil,
:amount => MollieAPI.Model.AmountNullable.t | nil,
:minimumAmount => MollieAPI.Model.AmountNullable.t | nil,
:archived => boolean() | nil,
:redirectUrl => String.t | nil,
:webhookUrl => String.t | nil,
:lines => [MollieAPI.Model.PaymentLineItemResponse.t] | nil,
:billingAddress => MollieAPI.Model.PaymentAddress.t | nil,
:shippingAddress => MollieAPI.Model.PaymentAddress.t | nil,
:profileId => String.t | nil,
:reusable => boolean() | nil,
:createdAt => String.t | nil,
:paidAt => String.t | nil,
:expiresAt => String.t | nil,
:allowedMethods => [MollieAPI.Model.PaymentLinkMethodResponse.t] | nil,
:applicationFee => MollieAPI.Model.CreatePaymentLinkRequestApplicationFee.t | nil,
:sequenceType => MollieAPI.Model.PaymentLinkSequenceTypeResponse.t | nil,
:customerId => String.t | nil,
:testmode => boolean() | nil,
:_links => MollieAPI.Model.CreatePaymentLinkRequestLinks.t | nil
}
alias MollieAPI.Deserializer
def decode(value) do
value
|> Deserializer.deserialize(:mode, :struct, MollieAPI.Model.Mode)
|> Deserializer.deserialize(:amount, :struct, MollieAPI.Model.AmountNullable)
|> Deserializer.deserialize(:minimumAmount, :struct, MollieAPI.Model.AmountNullable)
|> Deserializer.deserialize(:lines, :list, MollieAPI.Model.PaymentLineItemResponse)
|> Deserializer.deserialize(:billingAddress, :struct, MollieAPI.Model.PaymentAddress)
|> Deserializer.deserialize(:shippingAddress, :struct, MollieAPI.Model.PaymentAddress)
|> Deserializer.deserialize(:allowedMethods, :list, MollieAPI.Model.PaymentLinkMethodResponse)
|> Deserializer.deserialize(:applicationFee, :struct, MollieAPI.Model.CreatePaymentLinkRequestApplicationFee)
|> Deserializer.deserialize(:sequenceType, :struct, MollieAPI.Model.PaymentLinkSequenceTypeResponse)
|> Deserializer.deserialize(:_links, :struct, MollieAPI.Model.CreatePaymentLinkRequestLinks)
end
end