Class: Yoomoney::Models::Payment

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/yoomoney/models/payment.rb

Overview

Defined Under Namespace

Modules: Confirmation, PaymentMethod Classes: AuthorizationDetails, CancellationDetails, Transfer

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(amount:, basket_id:) ⇒ Object

Parameters:



# File 'lib/yoomoney/models/payment.rb', line 148

Instance Attribute Details

#amountYoomoney::Models::MonetaryAmount

Сумма платежа.



17
# File 'lib/yoomoney/models/payment.rb', line 17

required :amount, -> { Yoomoney::MonetaryAmount }

#authorization_detailsYoomoney::Models::Payment::AuthorizationDetails?

Данные об авторизации платежа.



59
# File 'lib/yoomoney/models/payment.rb', line 59

optional :authorization_details, -> { Yoomoney::Payment::AuthorizationDetails }

#cancellation_detailsYoomoney::Models::Payment::CancellationDetails?

Комментарий к статусу canceled.



65
# File 'lib/yoomoney/models/payment.rb', line 65

optional :cancellation_details, -> { Yoomoney::Payment::CancellationDetails }

#captured_atTime?

Время подтверждения платежа.

Returns:

  • (Time, nil)


71
# File 'lib/yoomoney/models/payment.rb', line 71

optional :captured_at, Time

#created_atTime

Время создания заказа.

Returns:

  • (Time)


23
# File 'lib/yoomoney/models/payment.rb', line 23

required :created_at, Time

#dealYoomoney::Models::PaymentDealInfo?

Данные о сделке.



83
# File 'lib/yoomoney/models/payment.rb', line 83

optional :deal, -> { Yoomoney::PaymentDealInfo }

#descriptionString?

Описание транзакции.

Returns:

  • (String, nil)


89
# File 'lib/yoomoney/models/payment.rb', line 89

optional :description, String

#expires_atTime?

Время, до которого вы можете бесплатно отменить или подтвердить платеж.

Returns:

  • (Time, nil)


95
# File 'lib/yoomoney/models/payment.rb', line 95

optional :expires_at, Time

#idString

Идентификатор платежа.

Returns:

  • (String)


11
# File 'lib/yoomoney/models/payment.rb', line 11

required :id, String

#income_amountYoomoney::Models::MonetaryAmount?

Сумма платежа, которую получит магазин.



101
# File 'lib/yoomoney/models/payment.rb', line 101

optional :income_amount, -> { Yoomoney::MonetaryAmount }

#invoice_detailsString?

Данные о счете, который оплачивается.

Returns:

  • (String, nil)


107
# File 'lib/yoomoney/models/payment.rb', line 107

optional :invoice_details, String

#merchant_customer_idString?

Идентификатор покупателя в вашей системе.

Returns:

  • (String, nil)


113
# File 'lib/yoomoney/models/payment.rb', line 113

optional :merchant_customer_id, String

#metadataHash{Symbol=>String}?

Любые дополнительные данные, которые нужны вам для работы (например, номер заказа). Передаются в виде набора пар «ключ-значение» и возвращаются в ответе от ЮKassa. Ограничения: максимум 16 ключей, имя ключа не больше 32 символов, значение ключа не больше 512 символов, тип данных — строка в формате UTF-8.

Returns:

  • (Hash{Symbol=>String}, nil)


122
# File 'lib/yoomoney/models/payment.rb', line 122

optional :metadata, Yoomoney::Internal::Type::HashOf[String]

Признак оплаты заказа.

Returns:

  • (Boolean)


29
# File 'lib/yoomoney/models/payment.rb', line 29

required :paid, Yoomoney::Internal::Type::Boolean

#receipt_registrationSymbol, ...

Статус доставки данных для чека.



134
# File 'lib/yoomoney/models/payment.rb', line 134

optional :receipt_registration, enum: -> { Yoomoney::ReceiptRegistrationStatus }

#recipientYoomoney::Models::Recipient

Получатель платежа.



35
# File 'lib/yoomoney/models/payment.rb', line 35

required :recipient, -> { Yoomoney::Recipient }

#refundableBoolean

Возможность провести возврат по API.

Returns:

  • (Boolean)


41
# File 'lib/yoomoney/models/payment.rb', line 41

required :refundable, Yoomoney::Internal::Type::Boolean

#refunded_amountYoomoney::Models::MonetaryAmount?

Сумма, возвращенная пользователю.



140
# File 'lib/yoomoney/models/payment.rb', line 140

optional :refunded_amount, -> { Yoomoney::MonetaryAmount }

#statusSymbol, Yoomoney::Models::PaymentStatus

Статус платежа.

Returns:



47
# File 'lib/yoomoney/models/payment.rb', line 47

required :status, enum: -> { Yoomoney::PaymentStatus }

#test_Boolean

Признак тестовой операции.

Returns:

  • (Boolean)


53
# File 'lib/yoomoney/models/payment.rb', line 53

required :test_, Yoomoney::Internal::Type::Boolean, api_name: :test

#transfersArray<Yoomoney::Models::Payment::Transfer>?

Данные о распределении денег.

Returns:



146
# File 'lib/yoomoney/models/payment.rb', line 146

optional :transfers, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::Payment::Transfer] }

Class Method Details

.variantsArray(Yoomoney::Models::Payment::PaymentMethod::PaymentMethodBankCard, Yoomoney::Models::PaymentMethod, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodAlfabank, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodSberbank, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodYooMoney, Yoomoney::Models::PaymentMethod, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodMobileBalance, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodB2bSberbank, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodSbp, Yoomoney::Models::PaymentMethod, Yoomoney::Models::Payment::PaymentMethod::PaymentMethodElectronicCertificate, Yoomoney::Models::PaymentMethod)



# File 'lib/yoomoney/models/payment.rb', line 327