Class: EInvoiceAPI::Models::DocumentCreateFromPdfResponse::Item

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/e_invoice_api/models/document_create_from_pdf_response.rb

Instance Attribute 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(allowances: nil, amount_due: nil, attachments: nil, billing_address: nil, billing_address_recipient: nil, charges: nil, currency: nil, customer_address: nil, customer_address_recipient: nil, customer_email: nil, customer_id: nil, customer_name: nil, customer_tax_id: nil, direction: nil, document_type: nil, due_date: nil, invoice_date: nil, invoice_id: nil, invoice_total: nil, items: nil, note: nil, payment_details: nil, payment_term: nil, previous_unpaid_balance: nil, purchase_order: nil, remittance_address: nil, remittance_address_recipient: nil, service_address: nil, service_address_recipient: nil, service_end_date: nil, service_start_date: nil, shipping_address: nil, shipping_address_recipient: nil, state: nil, subtotal: nil, success: nil, tax_code: nil, tax_details: nil, total_discount: nil, total_tax: nil, ubl_document: nil, vatex: nil, vatex_note: nil, vendor_address: nil, vendor_address_recipient: nil, vendor_email: nil, vendor_name: nil, vendor_tax_id: nil) ⇒ Object

Some parameter documentations has been truncated, see EInvoiceAPI::Models::DocumentCreateFromPdfResponse for more details.

Parameters:

  • allowances (Array<EInvoiceAPI::Models::Allowance>, nil) (defaults to: nil)
  • amount_due (String, nil) (defaults to: nil)

    The amount due of the invoice. Must be positive and rounded to maximum 2 decimal

  • attachments (Array<EInvoiceAPI::Models::DocumentAttachmentCreate>, nil) (defaults to: nil)
  • billing_address (String, nil) (defaults to: nil)
  • billing_address_recipient (String, nil) (defaults to: nil)
  • charges (Array<EInvoiceAPI::Models::Charge>, nil) (defaults to: nil)
  • currency (Symbol, EInvoiceAPI::Models::CurrencyCode) (defaults to: nil)

    Currency of the invoice

  • customer_address (String, nil) (defaults to: nil)
  • customer_address_recipient (String, nil) (defaults to: nil)
  • customer_email (String, nil) (defaults to: nil)
  • customer_id (String, nil) (defaults to: nil)
  • customer_name (String, nil) (defaults to: nil)
  • customer_tax_id (String, nil) (defaults to: nil)
  • direction (Symbol, EInvoiceAPI::Models::DocumentDirection) (defaults to: nil)
  • document_type (Symbol, EInvoiceAPI::Models::DocumentType) (defaults to: nil)
  • due_date (Date, nil) (defaults to: nil)
  • invoice_date (Date, nil) (defaults to: nil)
  • invoice_id (String, nil) (defaults to: nil)
  • invoice_total (String, nil) (defaults to: nil)

    The total amount of the invoice (so invoice_total = subtotal + total_tax + total

  • items (Array<EInvoiceAPI::Models::DocumentCreateFromPdfResponse::Item>) (defaults to: nil)

    At least one line item is required

  • note (String, nil) (defaults to: nil)
  • payment_details (Array<EInvoiceAPI::Models::PaymentDetailCreate>, nil) (defaults to: nil)
  • payment_term (String, nil) (defaults to: nil)
  • previous_unpaid_balance (String, nil) (defaults to: nil)

    The previous unpaid balance of the invoice, if any. Must be positive and rounded

  • purchase_order (String, nil) (defaults to: nil)
  • remittance_address (String, nil) (defaults to: nil)
  • remittance_address_recipient (String, nil) (defaults to: nil)
  • service_address (String, nil) (defaults to: nil)
  • service_address_recipient (String, nil) (defaults to: nil)
  • service_end_date (Date, nil) (defaults to: nil)
  • service_start_date (Date, nil) (defaults to: nil)
  • shipping_address (String, nil) (defaults to: nil)
  • shipping_address_recipient (String, nil) (defaults to: nil)
  • state (Symbol, EInvoiceAPI::Models::DocumentState) (defaults to: nil)
  • subtotal (String, nil) (defaults to: nil)

    The taxable base of the invoice. Should be the sum of all line items - allowance

  • success (Boolean) (defaults to: nil)

    Whether the PDF was successfully converted into a compliant e-invoice

  • tax_code (Symbol, EInvoiceAPI::Models::DocumentCreateFromPdfResponse::TaxCode) (defaults to: nil)

    Tax category code of the invoice

  • tax_details (Array<EInvoiceAPI::Models::DocumentCreateFromPdfResponse::TaxDetail>, nil) (defaults to: nil)
  • total_discount (String, nil) (defaults to: nil)

    The total financial discount of the invoice (so discounts not subject to VAT). M

  • total_tax (String, nil) (defaults to: nil)

    The total tax of the invoice. Must be positive and rounded to maximum 2 decimals

  • ubl_document (String, nil) (defaults to: nil)

    The UBL document as an XML string

  • vatex (Symbol, EInvoiceAPI::Models::DocumentCreateFromPdfResponse::Vatex, nil) (defaults to: nil)

    VATEX code list for VAT exemption reasons

  • vatex_note (String, nil) (defaults to: nil)

    VAT exemption note of the invoice

  • vendor_address (String, nil) (defaults to: nil)
  • vendor_address_recipient (String, nil) (defaults to: nil)
  • vendor_email (String, nil) (defaults to: nil)
  • vendor_name (String, nil) (defaults to: nil)
  • vendor_tax_id (String, nil) (defaults to: nil)


375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 375

class Item < EInvoiceAPI::Internal::Type::BaseModel
  # @!attribute allowances
  #   The allowances of the line item.
  #
  #   @return [Array<EInvoiceAPI::Models::Allowance>, nil]
  optional :allowances, -> { EInvoiceAPI::Internal::Type::ArrayOf[EInvoiceAPI::Allowance] }, nil?: true

  # @!attribute amount
  #   The total amount of the line item, exclusive of VAT, after subtracting line
  #   level allowances and adding line level charges. Must be rounded to maximum 2
  #   decimals
  #
  #   @return [String, nil]
  optional :amount, String, nil?: true

  # @!attribute charges
  #   The charges of the line item.
  #
  #   @return [Array<EInvoiceAPI::Models::Charge>, nil]
  optional :charges, -> { EInvoiceAPI::Internal::Type::ArrayOf[EInvoiceAPI::Charge] }, nil?: true

  # @!attribute date
  #
  #   @return [nil]
  optional :date, NilClass

  # @!attribute description
  #   The description of the line item.
  #
  #   @return [String, nil]
  optional :description, String, nil?: true

  # @!attribute product_code
  #   The product code of the line item.
  #
  #   @return [String, nil]
  optional :product_code, String, nil?: true

  # @!attribute quantity
  #   The quantity of items (goods or services) that is the subject of the line item.
  #   Must be rounded to maximum 4 decimals
  #
  #   @return [String, nil]
  optional :quantity, String, nil?: true

  # @!attribute tax
  #   The total VAT amount for the line item. Must be rounded to maximum 2 decimals
  #
  #   @return [String, nil]
  optional :tax, String, nil?: true

  # @!attribute tax_rate
  #   The VAT rate of the line item expressed as percentage with 2 decimals
  #
  #   @return [String, nil]
  optional :tax_rate, String, nil?: true

  # @!attribute unit
  #   Unit of Measure Codes from UNECERec20 used in Peppol BIS Billing 3.0.
  #
  #   @return [Symbol, EInvoiceAPI::Models::UnitOfMeasureCode, nil]
  optional :unit, enum: -> { EInvoiceAPI::UnitOfMeasureCode }, nil?: true

  # @!attribute unit_price
  #   The unit price of the line item. Must be rounded to maximum 2 decimals
  #
  #   @return [String, nil]
  optional :unit_price, String, nil?: true

  # @!method initialize(allowances: nil, amount: nil, charges: nil, date: nil, description: nil, product_code: nil, quantity: nil, tax: nil, tax_rate: nil, unit: nil, unit_price: nil)
  #   Some parameter documentations has been truncated, see
  #   {EInvoiceAPI::Models::DocumentCreateFromPdfResponse::Item} for more details.
  #
  #   @param allowances [Array<EInvoiceAPI::Models::Allowance>, nil] The allowances of the line item.
  #
  #   @param amount [String, nil] The total amount of the line item, exclusive of VAT, after subtracting line leve
  #
  #   @param charges [Array<EInvoiceAPI::Models::Charge>, nil] The charges of the line item.
  #
  #   @param date [nil]
  #
  #   @param description [String, nil] The description of the line item.
  #
  #   @param product_code [String, nil] The product code of the line item.
  #
  #   @param quantity [String, nil] The quantity of items (goods or services) that is the subject of the line item.
  #
  #   @param tax [String, nil] The total VAT amount for the line item. Must be rounded to maximum 2 decimals
  #
  #   @param tax_rate [String, nil] The VAT rate of the line item expressed as percentage with 2 decimals
  #
  #   @param unit [Symbol, EInvoiceAPI::Models::UnitOfMeasureCode, nil] Unit of Measure Codes from UNECERec20 used in Peppol BIS Billing 3.0.
  #
  #   @param unit_price [String, nil] The unit price of the line item. Must be rounded to maximum 2 decimals
end

Instance Attribute Details

#allowancesArray<EInvoiceAPI::Models::Allowance>?

The allowances of the line item.

Returns:



380
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 380

optional :allowances, -> { EInvoiceAPI::Internal::Type::ArrayOf[EInvoiceAPI::Allowance] }, nil?: true

#amountString?

The total amount of the line item, exclusive of VAT, after subtracting line level allowances and adding line level charges. Must be rounded to maximum 2 decimals

Returns:

  • (String, nil)


388
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 388

optional :amount, String, nil?: true

#chargesArray<EInvoiceAPI::Models::Charge>?

The charges of the line item.

Returns:



394
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 394

optional :charges, -> { EInvoiceAPI::Internal::Type::ArrayOf[EInvoiceAPI::Charge] }, nil?: true

#datenil

Returns:

  • (nil)


399
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 399

optional :date, NilClass

#descriptionString?

The description of the line item.

Returns:

  • (String, nil)


405
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 405

optional :description, String, nil?: true

#product_codeString?

The product code of the line item.

Returns:

  • (String, nil)


411
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 411

optional :product_code, String, nil?: true

#quantityString?

The quantity of items (goods or services) that is the subject of the line item. Must be rounded to maximum 4 decimals

Returns:

  • (String, nil)


418
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 418

optional :quantity, String, nil?: true

#taxString?

The total VAT amount for the line item. Must be rounded to maximum 2 decimals

Returns:

  • (String, nil)


424
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 424

optional :tax, String, nil?: true

#tax_rateString?

The VAT rate of the line item expressed as percentage with 2 decimals

Returns:

  • (String, nil)


430
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 430

optional :tax_rate, String, nil?: true

#unitSymbol, ...

Unit of Measure Codes from UNECERec20 used in Peppol BIS Billing 3.0.

Returns:



436
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 436

optional :unit, enum: -> { EInvoiceAPI::UnitOfMeasureCode }, nil?: true

#unit_priceString?

The unit price of the line item. Must be rounded to maximum 2 decimals

Returns:

  • (String, nil)


442
# File 'lib/e_invoice_api/models/document_create_from_pdf_response.rb', line 442

optional :unit_price, String, nil?: true