e-invoice-api 0.5.3 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,11 +9,16 @@ module EInvoiceAPI
9
9
  # @return [EInvoiceAPI::Resources::Documents::Ubl]
10
10
  attr_reader :ubl
11
11
 
12
+ # Some parameter documentations has been truncated, see
13
+ # {EInvoiceAPI::Models::DocumentCreateParams} for more details.
14
+ #
12
15
  # Create a new invoice or credit note
13
16
  #
14
- # @overload create(amount_due: nil, attachments: nil, billing_address: nil, billing_address_recipient: 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, tax_details: nil, total_discount: nil, total_tax: nil, vendor_address: nil, vendor_address_recipient: nil, vendor_email: nil, vendor_name: nil, vendor_tax_id: nil, request_options: {})
17
+ # @overload create(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, tax_code: nil, tax_details: nil, total_discount: nil, total_tax: nil, vatex: nil, vatex_note: nil, vendor_address: nil, vendor_address_recipient: nil, vendor_email: nil, vendor_name: nil, vendor_tax_id: nil, request_options: {})
18
+ #
19
+ # @param allowances [Array<EInvoiceAPI::Models::DocumentCreate::Allowance>, nil]
15
20
  #
16
- # @param amount_due [Float, String, nil]
21
+ # @param amount_due [Float, String, nil] The amount due of the invoice. Must be positive and rounded to maximum 2 decimal
17
22
  #
18
23
  # @param attachments [Array<EInvoiceAPI::Models::DocumentAttachmentCreate>, nil]
19
24
  #
@@ -21,6 +26,8 @@ module EInvoiceAPI
21
26
  #
22
27
  # @param billing_address_recipient [String, nil]
23
28
  #
29
+ # @param charges [Array<EInvoiceAPI::Models::DocumentCreate::Charge>, nil]
30
+ #
24
31
  # @param currency [Symbol, EInvoiceAPI::Models::CurrencyCode] Currency of the invoice
25
32
  #
26
33
  # @param customer_address [String, nil]
@@ -45,9 +52,9 @@ module EInvoiceAPI
45
52
  #
46
53
  # @param invoice_id [String, nil]
47
54
  #
48
- # @param invoice_total [Float, String, nil]
55
+ # @param invoice_total [Float, String, nil] The total amount of the invoice (so invoice_total = subtotal + total_tax + total
49
56
  #
50
- # @param items [Array<EInvoiceAPI::Models::DocumentCreate::Item>, nil]
57
+ # @param items [Array<EInvoiceAPI::Models::DocumentCreate::Item>] At least one line item is required
51
58
  #
52
59
  # @param note [String, nil]
53
60
  #
@@ -55,7 +62,7 @@ module EInvoiceAPI
55
62
  #
56
63
  # @param payment_term [String, nil]
57
64
  #
58
- # @param previous_unpaid_balance [Float, String, nil]
65
+ # @param previous_unpaid_balance [Float, String, nil] The previous unpaid balance of the invoice, if any. Must be positive and rounded
59
66
  #
60
67
  # @param purchase_order [String, nil]
61
68
  #
@@ -77,13 +84,19 @@ module EInvoiceAPI
77
84
  #
78
85
  # @param state [Symbol, EInvoiceAPI::Models::DocumentState]
79
86
  #
80
- # @param subtotal [Float, String, nil]
87
+ # @param subtotal [Float, String, nil] The taxable base of the invoice. Should be the sum of all line items - allowance
88
+ #
89
+ # @param tax_code [Symbol, EInvoiceAPI::Models::DocumentCreate::TaxCode] Tax category code of the invoice
81
90
  #
82
91
  # @param tax_details [Array<EInvoiceAPI::Models::DocumentCreate::TaxDetail>, nil]
83
92
  #
84
- # @param total_discount [Float, String, nil]
93
+ # @param total_discount [Float, String, nil] The total financial discount of the invoice (so discounts not subject to VAT). M
94
+ #
95
+ # @param total_tax [Float, String, nil] The total tax of the invoice. Must be positive and rounded to maximum 2 decimals
96
+ #
97
+ # @param vatex [Symbol, EInvoiceAPI::Models::DocumentCreate::Vatex, nil] VATEX code list for VAT exemption reasons
85
98
  #
86
- # @param total_tax [Float, String, nil]
99
+ # @param vatex_note [String, nil] VAT exemption note of the invoice
87
100
  #
88
101
  # @param vendor_address [String, nil]
89
102
  #
@@ -3,11 +3,16 @@
3
3
  module EInvoiceAPI
4
4
  module Resources
5
5
  class Validate
6
+ # Some parameter documentations has been truncated, see
7
+ # {EInvoiceAPI::Models::ValidateValidateJsonParams} for more details.
8
+ #
6
9
  # Validate if the JSON document can be converted to a valid UBL document
7
10
  #
8
- # @overload validate_json(amount_due: nil, attachments: nil, billing_address: nil, billing_address_recipient: 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, tax_details: nil, total_discount: nil, total_tax: nil, vendor_address: nil, vendor_address_recipient: nil, vendor_email: nil, vendor_name: nil, vendor_tax_id: nil, request_options: {})
11
+ # @overload validate_json(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, tax_code: nil, tax_details: nil, total_discount: nil, total_tax: nil, vatex: nil, vatex_note: nil, vendor_address: nil, vendor_address_recipient: nil, vendor_email: nil, vendor_name: nil, vendor_tax_id: nil, request_options: {})
9
12
  #
10
- # @param amount_due [Float, String, nil]
13
+ # @param allowances [Array<EInvoiceAPI::Models::DocumentCreate::Allowance>, nil]
14
+ #
15
+ # @param amount_due [Float, String, nil] The amount due of the invoice. Must be positive and rounded to maximum 2 decimal
11
16
  #
12
17
  # @param attachments [Array<EInvoiceAPI::Models::DocumentAttachmentCreate>, nil]
13
18
  #
@@ -15,6 +20,8 @@ module EInvoiceAPI
15
20
  #
16
21
  # @param billing_address_recipient [String, nil]
17
22
  #
23
+ # @param charges [Array<EInvoiceAPI::Models::DocumentCreate::Charge>, nil]
24
+ #
18
25
  # @param currency [Symbol, EInvoiceAPI::Models::CurrencyCode] Currency of the invoice
19
26
  #
20
27
  # @param customer_address [String, nil]
@@ -39,9 +46,9 @@ module EInvoiceAPI
39
46
  #
40
47
  # @param invoice_id [String, nil]
41
48
  #
42
- # @param invoice_total [Float, String, nil]
49
+ # @param invoice_total [Float, String, nil] The total amount of the invoice (so invoice_total = subtotal + total_tax + total
43
50
  #
44
- # @param items [Array<EInvoiceAPI::Models::DocumentCreate::Item>, nil]
51
+ # @param items [Array<EInvoiceAPI::Models::DocumentCreate::Item>] At least one line item is required
45
52
  #
46
53
  # @param note [String, nil]
47
54
  #
@@ -49,7 +56,7 @@ module EInvoiceAPI
49
56
  #
50
57
  # @param payment_term [String, nil]
51
58
  #
52
- # @param previous_unpaid_balance [Float, String, nil]
59
+ # @param previous_unpaid_balance [Float, String, nil] The previous unpaid balance of the invoice, if any. Must be positive and rounded
53
60
  #
54
61
  # @param purchase_order [String, nil]
55
62
  #
@@ -71,13 +78,19 @@ module EInvoiceAPI
71
78
  #
72
79
  # @param state [Symbol, EInvoiceAPI::Models::DocumentState]
73
80
  #
74
- # @param subtotal [Float, String, nil]
81
+ # @param subtotal [Float, String, nil] The taxable base of the invoice. Should be the sum of all line items - allowance
82
+ #
83
+ # @param tax_code [Symbol, EInvoiceAPI::Models::DocumentCreate::TaxCode] Tax category code of the invoice
75
84
  #
76
85
  # @param tax_details [Array<EInvoiceAPI::Models::DocumentCreate::TaxDetail>, nil]
77
86
  #
78
- # @param total_discount [Float, String, nil]
87
+ # @param total_discount [Float, String, nil] The total financial discount of the invoice (so discounts not subject to VAT). M
88
+ #
89
+ # @param total_tax [Float, String, nil] The total tax of the invoice. Must be positive and rounded to maximum 2 decimals
90
+ #
91
+ # @param vatex [Symbol, EInvoiceAPI::Models::DocumentCreate::Vatex, nil] VATEX code list for VAT exemption reasons
79
92
  #
80
- # @param total_tax [Float, String, nil]
93
+ # @param vatex_note [String, nil] VAT exemption note of the invoice
81
94
  #
82
95
  # @param vendor_address [String, nil]
83
96
  #
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module EInvoiceAPI
4
- VERSION = "0.5.3"
4
+ VERSION = "0.7.0"
5
5
  end