nordlet 0.6.5 → 0.6.8
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.
- checksums.yaml +4 -4
- data/lib/nordlet/account/client.rb +130 -7
- data/lib/nordlet/account/types/brand_get_account_request.rb +9 -0
- data/lib/nordlet/account/types/brand_get_account_response.rb +17 -0
- data/lib/nordlet/account/types/brand_update_account_request.rb +17 -0
- data/lib/nordlet/account/types/brand_update_account_response.rb +17 -0
- data/lib/nordlet/account/types/companies_convert_to_live_account_request.rb +11 -0
- data/lib/nordlet/account/types/companies_convert_to_live_account_response.rb +13 -0
- data/lib/nordlet/account/types/companies_create_account_response.rb +10 -0
- data/lib/nordlet/account/types/companies_create_account_response_vat_period.rb +17 -0
- data/lib/nordlet/account/types/me_account_response_billing.rb +2 -0
- data/lib/nordlet/account/types/me_account_response_companies_item.rb +10 -0
- data/lib/nordlet/account/types/me_account_response_companies_item_vat_period.rb +17 -0
- data/lib/nordlet/account/types/me_account_response_user.rb +2 -0
- data/lib/nordlet/bank/client.rb +183 -14
- data/lib/nordlet/bank/types/reconciliation_get_bank_request.rb +15 -0
- data/lib/nordlet/bank/types/reconciliation_get_bank_response.rb +35 -0
- data/lib/nordlet/bank/types/reconciliation_get_bank_response_statement_balance_source.rb +14 -0
- data/lib/nordlet/bank/types/reconciliation_get_bank_response_unbooked_lines_item.rb +39 -0
- data/lib/nordlet/bank/types/reconciliation_get_bank_response_unbooked_lines_item_status.rb +15 -0
- data/lib/nordlet/bank/types/transactions_ignore_bank_request.rb +13 -0
- data/lib/nordlet/bank/types/transactions_ignore_bank_response.rb +39 -0
- data/lib/nordlet/bank/types/transactions_ignore_bank_response_status.rb +15 -0
- data/lib/nordlet/bank/types/transactions_import_bank_request.rb +4 -0
- data/lib/nordlet/bank/types/transactions_import_bank_response.rb +2 -0
- data/lib/nordlet/bank/types/transactions_import_bank_response_duplicates_item.rb +17 -0
- data/lib/nordlet/bank/types/transactions_list_bank_response_rows_item.rb +2 -0
- data/lib/nordlet/bank/types/transactions_list_bank_response_rows_item_status.rb +1 -0
- data/lib/nordlet/bank/types/transactions_match_bank_request.rb +2 -0
- data/lib/nordlet/bank/types/transactions_match_bank_request_remainder.rb +13 -0
- data/lib/nordlet/bank/types/transactions_match_bank_request_remainder_treatment.rb +15 -0
- data/lib/nordlet/bank/types/transactions_match_bank_response.rb +2 -0
- data/lib/nordlet/bank/types/transactions_match_bank_response_status.rb +1 -0
- data/lib/nordlet/bank/types/transactions_match_many_bank_response.rb +2 -0
- data/lib/nordlet/bank/types/transactions_match_many_bank_response_status.rb +1 -0
- data/lib/nordlet/bank/types/transactions_post_bank_request.rb +25 -0
- data/lib/nordlet/bank/types/transactions_post_bank_response.rb +39 -0
- data/lib/nordlet/bank/types/transactions_post_bank_response_status.rb +15 -0
- data/lib/nordlet/bank/types/transactions_record_bank_response.rb +2 -0
- data/lib/nordlet/bank/types/transactions_record_bank_response_status.rb +1 -0
- data/lib/nordlet/bank/types/transactions_unignore_bank_request.rb +11 -0
- data/lib/nordlet/bank/types/transactions_unignore_bank_response.rb +39 -0
- data/lib/nordlet/bank/types/transactions_unignore_bank_response_status.rb +15 -0
- data/lib/nordlet/bank/types/transactions_unmatch_bank_response.rb +2 -0
- data/lib/nordlet/bank/types/transactions_unmatch_bank_response_status.rb +1 -0
- data/lib/nordlet/billing/client.rb +50 -10
- data/lib/nordlet/billing/types/account_get_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/account_get_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/account_set_account_type_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/account_set_account_type_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/account_set_auto_top_up_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/account_set_auto_top_up_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/account_set_overdraft_cap_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/account_set_overdraft_cap_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/account_set_plan_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/account_set_plan_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/flat_rate_confirm_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/flat_rate_confirm_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/flat_rate_create_billing_request.rb +2 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_request.rb +9 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response.rb +55 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_account_type.rb +14 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_auto_top_up.rb +15 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_month_to_date.rb +25 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_plan.rb +16 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_plans_value.rb +19 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_site.rb +14 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_status.rb +15 -0
- data/lib/nordlet/billing/types/free_sandbox_start_billing_response_top_up.rb +13 -0
- data/lib/nordlet/billing/types/subscription_cancel_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/subscription_cancel_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/topup_confirm_billing_response.rb +2 -0
- data/lib/nordlet/billing/types/topup_confirm_billing_response_month_to_date.rb +0 -2
- data/lib/nordlet/billing/types/topup_create_billing_request.rb +2 -0
- data/lib/nordlet/calendar/client.rb +3 -1
- data/lib/nordlet/capture/client.rb +6 -188
- data/lib/nordlet/capture/types/documents_confirm_capture_response_invoice.rb +6 -0
- data/lib/nordlet/capture/types/documents_confirm_capture_response_invoice_status.rb +1 -0
- data/lib/nordlet/capture/types/documents_confirm_capture_response_opposite_invoice.rb +6 -0
- data/lib/nordlet/capture/types/documents_confirm_capture_response_opposite_invoice_status.rb +1 -0
- data/lib/nordlet/cash/client.rb +11 -10
- data/lib/nordlet/declarations/client.rb +7 -3
- data/lib/nordlet/declarations/types/configs_list_declarations_response_rows_item_fields_item.rb +2 -0
- data/lib/nordlet/declarations/types/configs_update_declarations_response_fields_item.rb +2 -0
- data/lib/nordlet/hr/client.rb +3 -2
- data/lib/nordlet/ledger/client.rb +46 -5
- data/lib/nordlet/ledger/types/journal_transactions_get_ledger_response.rb +2 -0
- data/lib/nordlet/ledger/types/journal_transactions_reverse_ledger_request.rb +15 -0
- data/lib/nordlet/ledger/types/journal_transactions_reverse_ledger_response.rb +27 -0
- data/lib/nordlet/ledger/types/journal_transactions_reverse_ledger_response_status.rb +14 -0
- data/lib/nordlet/ledger/types/periods_lock_ledger_response.rb +2 -0
- data/lib/nordlet/ledger/types/periods_lock_ledger_response_warnings_item.rb +17 -0
- data/lib/nordlet/ledger/types/periods_lock_ledger_response_warnings_item_code.rb +21 -0
- data/lib/nordlet/partners/client.rb +10 -8
- data/lib/nordlet/public/types/invoices_get_public_response.rb +2 -0
- data/lib/nordlet/purchases/client.rb +77 -20
- data/lib/nordlet/purchases/types/invoices_create_purchases_request.rb +6 -0
- data/lib/nordlet/purchases/types/invoices_create_purchases_response.rb +8 -0
- data/lib/nordlet/purchases/types/invoices_create_purchases_response_status.rb +1 -0
- data/lib/nordlet/purchases/types/invoices_create_purchases_response_warnings_item.rb +13 -0
- data/lib/nordlet/purchases/types/invoices_get_purchases_response.rb +6 -0
- data/lib/nordlet/purchases/types/invoices_get_purchases_response_status.rb +1 -0
- data/lib/nordlet/purchases/types/invoices_list_purchases_response_rows_item.rb +6 -0
- data/lib/nordlet/purchases/types/invoices_list_purchases_response_rows_item_status.rb +1 -0
- data/lib/nordlet/purchases/types/invoices_register_purchases_response.rb +8 -0
- data/lib/nordlet/purchases/types/invoices_register_purchases_response_status.rb +1 -0
- data/lib/nordlet/purchases/types/invoices_register_purchases_response_warnings_item.rb +13 -0
- data/lib/nordlet/purchases/types/invoices_reverse_purchases_request.rb +15 -0
- data/lib/nordlet/purchases/types/invoices_reverse_purchases_response.rb +71 -0
- data/lib/nordlet/purchases/types/invoices_reverse_purchases_response_lines_item.rb +53 -0
- data/lib/nordlet/purchases/types/invoices_reverse_purchases_response_payment_status.rb +15 -0
- data/lib/nordlet/purchases/types/invoices_reverse_purchases_response_status.rb +15 -0
- data/lib/nordlet/{capture/types/documents_upload_capture_response_extraction_document_type.rb → purchases/types/invoices_reverse_purchases_response_type.rb} +2 -2
- data/lib/nordlet/purchases/types/invoices_update_purchases_request.rb +6 -0
- data/lib/nordlet/purchases/types/invoices_update_purchases_response.rb +6 -0
- data/lib/nordlet/purchases/types/invoices_update_purchases_response_status.rb +1 -0
- data/lib/nordlet/reference/client.rb +8 -2
- data/lib/nordlet/reference/types/vat_resolve_reference_request.rb +2 -0
- data/lib/nordlet/reference/types/vat_resolve_reference_request_side.rb +14 -0
- data/lib/nordlet/reference/types/vat_resolve_reference_response.rb +2 -0
- data/lib/nordlet/reports/client.rb +42 -0
- data/lib/nordlet/reports/types/period_checklist_reports_request.rb +11 -0
- data/lib/nordlet/reports/types/period_checklist_reports_response.rb +17 -0
- data/lib/nordlet/reports/types/period_checklist_reports_response_items_item.rb +17 -0
- data/lib/nordlet/reports/types/period_checklist_reports_response_items_item_code.rb +21 -0
- data/lib/nordlet/sales/client.rb +19 -8
- data/lib/nordlet/sales/types/invoices_create_sales_response.rb +2 -0
- data/lib/nordlet/sales/types/invoices_create_sales_response_warnings_item.rb +13 -0
- data/lib/nordlet/sales/types/invoices_issue_sales_response.rb +2 -0
- data/lib/nordlet/sales/types/invoices_issue_sales_response_warnings_item.rb +13 -0
- data/lib/nordlet/sales/types/invoices_view_sales_response.rb +2 -0
- data/lib/nordlet/version.rb +1 -1
- data/lib/nordlet.rb +55 -19
- data/reference.md +1672 -1145
- metadata +57 -21
- data/lib/nordlet/capture/types/documents_upload_capture_request.rb +0 -15
- data/lib/nordlet/capture/types/documents_upload_capture_response.rb +0 -43
- data/lib/nordlet/capture/types/documents_upload_capture_response_extraction.rb +0 -33
- data/lib/nordlet/capture/types/documents_upload_capture_response_extraction_lines_item.rb +0 -25
- data/lib/nordlet/capture/types/documents_upload_capture_response_extraction_opposite_lines_item.rb +0 -25
- data/lib/nordlet/capture/types/documents_upload_capture_response_extraction_supplier.rb +0 -19
- data/lib/nordlet/capture/types/documents_upload_capture_response_status.rb +0 -16
- data/lib/nordlet/capture/types/inbound_email_capture_request.rb +0 -27
- data/lib/nordlet/capture/types/inbound_email_capture_request_attachments_item.rb +0 -21
- data/lib/nordlet/capture/types/inbound_email_capture_request_to.rb +0 -15
- data/lib/nordlet/capture/types/inbound_email_capture_request_to_full_item.rb +0 -11
- data/lib/nordlet/capture/types/inbound_email_capture_response.rb +0 -15
- data/lib/nordlet/capture/types/settings_get_capture_request.rb +0 -9
- data/lib/nordlet/capture/types/settings_get_capture_response.rb +0 -17
- data/lib/nordlet/capture/types/settings_regenerate_intake_capture_request.rb +0 -9
- data/lib/nordlet/capture/types/settings_regenerate_intake_capture_response.rb +0 -17
- data/lib/nordlet/capture/types/settings_update_capture_request.rb +0 -13
- data/lib/nordlet/capture/types/settings_update_capture_response.rb +0 -17
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Purchases
|
|
5
|
+
module Types
|
|
6
|
+
class InvoicesRegisterPurchasesResponseWarningsItem < Internal::Types::Model
|
|
7
|
+
field :code, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :message, -> { String }, optional: false, nullable: false
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Purchases
|
|
5
|
+
module Types
|
|
6
|
+
class InvoicesReversePurchasesRequest < Internal::Types::Model
|
|
7
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :reason, -> { String }, optional: false, nullable: false
|
|
10
|
+
|
|
11
|
+
field :date, -> { String }, optional: true, nullable: false
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Purchases
|
|
5
|
+
module Types
|
|
6
|
+
class InvoicesReversePurchasesResponse < Internal::Types::Model
|
|
7
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :partner_id, -> { String }, optional: false, nullable: false, api_name: "partnerId"
|
|
10
|
+
|
|
11
|
+
field :type, -> { Nordlet::Purchases::Types::InvoicesReversePurchasesResponseType }, optional: false, nullable: false
|
|
12
|
+
|
|
13
|
+
field :status, -> { Nordlet::Purchases::Types::InvoicesReversePurchasesResponseStatus }, optional: false, nullable: false
|
|
14
|
+
|
|
15
|
+
field :payment_status, -> { Nordlet::Purchases::Types::InvoicesReversePurchasesResponsePaymentStatus }, optional: false, nullable: false, api_name: "paymentStatus"
|
|
16
|
+
|
|
17
|
+
field :document_number, -> { String }, optional: false, nullable: false, api_name: "documentNumber"
|
|
18
|
+
|
|
19
|
+
field :document_date, -> { String }, optional: false, nullable: false, api_name: "documentDate"
|
|
20
|
+
|
|
21
|
+
field :due_date, -> { String }, optional: false, nullable: true, api_name: "dueDate"
|
|
22
|
+
|
|
23
|
+
field :registration_date, -> { String }, optional: false, nullable: true, api_name: "registrationDate"
|
|
24
|
+
|
|
25
|
+
field :currency, -> { String }, optional: false, nullable: false
|
|
26
|
+
|
|
27
|
+
field :net_total, -> { String }, optional: false, nullable: false, api_name: "netTotal"
|
|
28
|
+
|
|
29
|
+
field :vat_total, -> { String }, optional: false, nullable: false, api_name: "vatTotal"
|
|
30
|
+
|
|
31
|
+
field :gross_total, -> { String }, optional: false, nullable: false, api_name: "grossTotal"
|
|
32
|
+
|
|
33
|
+
field :paid_amount, -> { String }, optional: false, nullable: false, api_name: "paidAmount"
|
|
34
|
+
|
|
35
|
+
field :journal_transaction_id, -> { String }, optional: false, nullable: true, api_name: "journalTransactionId"
|
|
36
|
+
|
|
37
|
+
field :reversed_at, -> { String }, optional: false, nullable: true, api_name: "reversedAt"
|
|
38
|
+
|
|
39
|
+
field :reversal_journal_transaction_id, -> { String }, optional: false, nullable: true, api_name: "reversalJournalTransactionId"
|
|
40
|
+
|
|
41
|
+
field :reversal_reason, -> { String }, optional: false, nullable: true, api_name: "reversalReason"
|
|
42
|
+
|
|
43
|
+
field :credited_invoice_id, -> { String }, optional: false, nullable: true, api_name: "creditedInvoiceId"
|
|
44
|
+
|
|
45
|
+
field :purchase_order_id, -> { String }, optional: false, nullable: true, api_name: "purchaseOrderId"
|
|
46
|
+
|
|
47
|
+
field :operation_type_id, -> { String }, optional: false, nullable: true, api_name: "operationTypeId"
|
|
48
|
+
|
|
49
|
+
field :notes, -> { String }, optional: false, nullable: true
|
|
50
|
+
|
|
51
|
+
field :intrastat_transport_mode, -> { String }, optional: false, nullable: true, api_name: "intrastatTransportMode"
|
|
52
|
+
|
|
53
|
+
field :intrastat_delivery_terms, -> { String }, optional: false, nullable: true, api_name: "intrastatDeliveryTerms"
|
|
54
|
+
|
|
55
|
+
field :intrastat_region, -> { String }, optional: false, nullable: true, api_name: "intrastatRegion"
|
|
56
|
+
|
|
57
|
+
field :intrastat_nature_of_transaction, -> { String }, optional: false, nullable: true, api_name: "intrastatNatureOfTransaction"
|
|
58
|
+
|
|
59
|
+
field :einvoice_number, -> { String }, optional: false, nullable: true, api_name: "einvoiceNumber"
|
|
60
|
+
|
|
61
|
+
field :document_ref, -> { String }, optional: false, nullable: true, api_name: "documentRef"
|
|
62
|
+
|
|
63
|
+
field :created_at, -> { String }, optional: false, nullable: false, api_name: "createdAt"
|
|
64
|
+
|
|
65
|
+
field :updated_at, -> { String }, optional: false, nullable: false, api_name: "updatedAt"
|
|
66
|
+
|
|
67
|
+
field :lines, -> { Internal::Types::Array[Nordlet::Purchases::Types::InvoicesReversePurchasesResponseLinesItem] }, optional: false, nullable: false
|
|
68
|
+
end
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
end
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Purchases
|
|
5
|
+
module Types
|
|
6
|
+
class InvoicesReversePurchasesResponseLinesItem < Internal::Types::Model
|
|
7
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :item_id, -> { String }, optional: false, nullable: true, api_name: "itemId"
|
|
10
|
+
|
|
11
|
+
field :description, -> { String }, optional: false, nullable: false
|
|
12
|
+
|
|
13
|
+
field :unit, -> { String }, optional: false, nullable: false
|
|
14
|
+
|
|
15
|
+
field :quantity, -> { String }, optional: false, nullable: false
|
|
16
|
+
|
|
17
|
+
field :unit_factor, -> { String }, optional: false, nullable: false, api_name: "unitFactor"
|
|
18
|
+
|
|
19
|
+
field :base_quantity, -> { String }, optional: false, nullable: false, api_name: "baseQuantity"
|
|
20
|
+
|
|
21
|
+
field :unit_price_excl_vat, -> { String }, optional: false, nullable: true, api_name: "unitPriceExclVat"
|
|
22
|
+
|
|
23
|
+
field :unit_price_incl_vat, -> { String }, optional: false, nullable: true, api_name: "unitPriceInclVat"
|
|
24
|
+
|
|
25
|
+
field :vat_rate_percent, -> { String }, optional: false, nullable: false, api_name: "vatRatePercent"
|
|
26
|
+
|
|
27
|
+
field :vat_classifier_code, -> { String }, optional: false, nullable: true, api_name: "vatClassifierCode"
|
|
28
|
+
|
|
29
|
+
field :cost_center_id, -> { String }, optional: false, nullable: true, api_name: "costCenterId"
|
|
30
|
+
|
|
31
|
+
field :project_id, -> { String }, optional: false, nullable: true, api_name: "projectId"
|
|
32
|
+
|
|
33
|
+
field :account_code, -> { String }, optional: false, nullable: true, api_name: "accountCode"
|
|
34
|
+
|
|
35
|
+
field :deferral_start_date, -> { String }, optional: false, nullable: true, api_name: "deferralStartDate"
|
|
36
|
+
|
|
37
|
+
field :deferral_end_date, -> { String }, optional: false, nullable: true, api_name: "deferralEndDate"
|
|
38
|
+
|
|
39
|
+
field :lot_number, -> { String }, optional: false, nullable: true, api_name: "lotNumber"
|
|
40
|
+
|
|
41
|
+
field :expiry_date, -> { String }, optional: false, nullable: true, api_name: "expiryDate"
|
|
42
|
+
|
|
43
|
+
field :line_net, -> { String }, optional: false, nullable: false, api_name: "lineNet"
|
|
44
|
+
|
|
45
|
+
field :line_vat, -> { String }, optional: false, nullable: false, api_name: "lineVat"
|
|
46
|
+
|
|
47
|
+
field :line_gross, -> { String }, optional: false, nullable: false, api_name: "lineGross"
|
|
48
|
+
|
|
49
|
+
field :sort_order, -> { Integer }, optional: false, nullable: false, api_name: "sortOrder"
|
|
50
|
+
end
|
|
51
|
+
end
|
|
52
|
+
end
|
|
53
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Purchases
|
|
5
|
+
module Types
|
|
6
|
+
module InvoicesReversePurchasesResponsePaymentStatus
|
|
7
|
+
extend Nordlet::Internal::Types::Enum
|
|
8
|
+
|
|
9
|
+
UNPAID = "unpaid"
|
|
10
|
+
PARTIAL = "partial"
|
|
11
|
+
PAID = "paid"
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Purchases
|
|
5
|
+
module Types
|
|
6
|
+
module InvoicesReversePurchasesResponseStatus
|
|
7
|
+
extend Nordlet::Internal::Types::Enum
|
|
8
|
+
|
|
9
|
+
DRAFT = "draft"
|
|
10
|
+
REGISTERED = "registered"
|
|
11
|
+
REVERSED = "reversed"
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
module Nordlet
|
|
4
|
-
module
|
|
4
|
+
module Purchases
|
|
5
5
|
module Types
|
|
6
|
-
module
|
|
6
|
+
module InvoicesReversePurchasesResponseType
|
|
7
7
|
extend Nordlet::Internal::Types::Enum
|
|
8
8
|
|
|
9
9
|
INVOICE = "invoice"
|
|
@@ -33,6 +33,12 @@ module Nordlet
|
|
|
33
33
|
field :einvoice_number, -> { String }, optional: true, nullable: false, api_name: "einvoiceNumber"
|
|
34
34
|
|
|
35
35
|
field :lines, -> { Internal::Types::Array[Nordlet::Purchases::Types::InvoicesUpdatePurchasesRequestLinesItem] }, optional: true, nullable: false
|
|
36
|
+
|
|
37
|
+
field :net_total, -> { String }, optional: true, nullable: false, api_name: "netTotal"
|
|
38
|
+
|
|
39
|
+
field :vat_total, -> { String }, optional: true, nullable: false, api_name: "vatTotal"
|
|
40
|
+
|
|
41
|
+
field :gross_total, -> { String }, optional: true, nullable: false, api_name: "grossTotal"
|
|
36
42
|
end
|
|
37
43
|
end
|
|
38
44
|
end
|
|
@@ -34,6 +34,12 @@ module Nordlet
|
|
|
34
34
|
|
|
35
35
|
field :journal_transaction_id, -> { String }, optional: false, nullable: true, api_name: "journalTransactionId"
|
|
36
36
|
|
|
37
|
+
field :reversed_at, -> { String }, optional: false, nullable: true, api_name: "reversedAt"
|
|
38
|
+
|
|
39
|
+
field :reversal_journal_transaction_id, -> { String }, optional: false, nullable: true, api_name: "reversalJournalTransactionId"
|
|
40
|
+
|
|
41
|
+
field :reversal_reason, -> { String }, optional: false, nullable: true, api_name: "reversalReason"
|
|
42
|
+
|
|
37
43
|
field :credited_invoice_id, -> { String }, optional: false, nullable: true, api_name: "creditedInvoiceId"
|
|
38
44
|
|
|
39
45
|
field :purchase_order_id, -> { String }, optional: false, nullable: true, api_name: "purchaseOrderId"
|
|
@@ -469,7 +469,8 @@ module Nordlet
|
|
|
469
469
|
# (422). `side` says whether the type is for sale lines, purchase lines or both, `scheme` is its VAT scheme and
|
|
470
470
|
# `nameEn` its English name; both are null for a type the company added itself. A type without a rate takes the
|
|
471
471
|
# line's `vatRatePercent` on the sides where `rateFromLine` is true, and 0% elsewhere. Filterable by `code`,
|
|
472
|
-
# `countryCode` and `
|
|
472
|
+
# `countryCode`, `ratePercent`, `side` and `scheme`; `side` and `scheme` take `eq`, `ne` and `in`, and `side`
|
|
473
|
+
# `sale` or `purchase` also matches the types for both sides. Sortable by `code` and `ratePercent`.
|
|
473
474
|
#
|
|
474
475
|
# @param request_options [Hash]
|
|
475
476
|
# @param params [Nordlet::Reference::Types::VatClassifiersListReferenceRequest]
|
|
@@ -615,7 +616,12 @@ module Nordlet
|
|
|
615
616
|
# from the partner's address or VAT number, business status from the VAT number) or from `customerCountryCode` and
|
|
616
617
|
# `customerIsBusiness`; `date` defaults to the company's current date; when `belowDistanceSalesThreshold` is not
|
|
617
618
|
# given, the distance-sales threshold is tracked from the company's ledger. Answers 422 when the partner has
|
|
618
|
-
# neither an address country nor a VAT code.
|
|
619
|
+
# neither an address country nor a VAT code. `vatTypeCodes` lists the codes of the VAT types of the company's
|
|
620
|
+
# country that fit the treatment and are valid on `date` (for `vatClassifierCode` on a line), empty when none is
|
|
621
|
+
# known; when they all belong to one of the schemes `intra_eu_b2b` and `reverse_charge`, `scheme` is that scheme.
|
|
622
|
+
# With `side` `purchase` the partner (or `customerCountryCode` and `customerIsBusiness`) is the supplier, the
|
|
623
|
+
# treatment is that of the supplier's supply to this company, `vatTypeCodes` are purchase types, and the
|
|
624
|
+
# marketplace, platform-service and special-goods fields are not used.
|
|
619
625
|
#
|
|
620
626
|
# @param request_options [Hash]
|
|
621
627
|
# @param params [Nordlet::Reference::Types::VatResolveReferenceRequest]
|
|
@@ -12,6 +12,8 @@ module Nordlet
|
|
|
12
12
|
|
|
13
13
|
field :supply_type, -> { Nordlet::Reference::Types::VatResolveReferenceRequestSupplyType }, optional: true, nullable: false, api_name: "supplyType"
|
|
14
14
|
|
|
15
|
+
field :side, -> { Nordlet::Reference::Types::VatResolveReferenceRequestSide }, optional: true, nullable: false
|
|
16
|
+
|
|
15
17
|
field :date, -> { String }, optional: true, nullable: false
|
|
16
18
|
|
|
17
19
|
field :below_distance_sales_threshold, -> { Internal::Types::Boolean }, optional: true, nullable: false, api_name: "belowDistanceSalesThreshold"
|
|
@@ -19,6 +19,8 @@ module Nordlet
|
|
|
19
19
|
field :legal_basis, -> { String }, optional: false, nullable: false, api_name: "legalBasis"
|
|
20
20
|
|
|
21
21
|
field :notes, -> { Internal::Types::Array[String] }, optional: false, nullable: false
|
|
22
|
+
|
|
23
|
+
field :vat_type_codes, -> { Internal::Types::Array[String] }, optional: false, nullable: false, api_name: "vatTypeCodes"
|
|
22
24
|
end
|
|
23
25
|
end
|
|
24
26
|
end
|
|
@@ -626,6 +626,48 @@ module Nordlet
|
|
|
626
626
|
end
|
|
627
627
|
end
|
|
628
628
|
|
|
629
|
+
# Lists what is still open for `period`: a month (`YYYY-MM`) or the fiscal year that ends in `YYYY`. Items: draft
|
|
630
|
+
# sale documents (invoices, credit notes and advance invoices with an issue date in the period) and draft purchase
|
|
631
|
+
# documents dated in the period, bank lines dated in the period with status `new`, assets with depreciation months
|
|
632
|
+
# not posted up to the period end, expense deferral rows due by the period end and not posted, active recurring
|
|
633
|
+
# invoices whose next run date is on or before the period end, payroll runs of the period's months still in draft,
|
|
634
|
+
# and for a fiscal year the issued sale and registered purchase documents in a currency other than the base
|
|
635
|
+
# currency still open at the year end. Each item carries the `count` and the `ids` of the documents, rows, assets,
|
|
636
|
+
# recurring invoices or runs; an item with nothing open is left out. `ledger/periods/lock` returns the same items
|
|
637
|
+
# as `warnings`.
|
|
638
|
+
#
|
|
639
|
+
# @param request_options [Hash]
|
|
640
|
+
# @param params [Nordlet::Reports::Types::PeriodChecklistReportsRequest]
|
|
641
|
+
# @option request_options [String] :base_url
|
|
642
|
+
# @option request_options [Hash{String => Object}] :additional_headers
|
|
643
|
+
# @option request_options [Hash{String => Object}] :additional_query_parameters
|
|
644
|
+
# @option request_options [Hash{String => Object}] :additional_body_parameters
|
|
645
|
+
# @option request_options [Integer] :timeout_in_seconds
|
|
646
|
+
#
|
|
647
|
+
# @return [Nordlet::Reports::Types::PeriodChecklistReportsResponse]
|
|
648
|
+
def period_checklist(request_options: {}, **params)
|
|
649
|
+
params = Nordlet::Internal::Types::Utils.normalize_keys(params)
|
|
650
|
+
request = Nordlet::Internal::JSON::Request.new(
|
|
651
|
+
base_url: request_options[:base_url],
|
|
652
|
+
method: "POST",
|
|
653
|
+
path: "v1/reports/period-checklist",
|
|
654
|
+
body: Nordlet::Reports::Types::PeriodChecklistReportsRequest.new(params).to_h,
|
|
655
|
+
request_options: request_options
|
|
656
|
+
)
|
|
657
|
+
begin
|
|
658
|
+
response = @client.send(request)
|
|
659
|
+
rescue Net::HTTPRequestTimeout
|
|
660
|
+
raise Nordlet::Errors::TimeoutError
|
|
661
|
+
end
|
|
662
|
+
code = response.code.to_i
|
|
663
|
+
if code.between?(200, 299)
|
|
664
|
+
Nordlet::Reports::Types::PeriodChecklistReportsResponse.load(response.body)
|
|
665
|
+
else
|
|
666
|
+
error_class = Nordlet::Errors::ResponseError.subclass_for_code(code)
|
|
667
|
+
raise error_class.new(response.body, code: code)
|
|
668
|
+
end
|
|
669
|
+
end
|
|
670
|
+
|
|
629
671
|
# Registered purchase invoices of a period (by registration date) from partners in another EU country, summed per
|
|
630
672
|
# partner country and VAT rate: net and VAT in the base currency and the number of documents, credit notes
|
|
631
673
|
# counting negative. The partner's country is the country code of its address, else the first two characters of
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Reports
|
|
5
|
+
module Types
|
|
6
|
+
class PeriodChecklistReportsResponse < Internal::Types::Model
|
|
7
|
+
field :period, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :from_date, -> { String }, optional: false, nullable: false, api_name: "fromDate"
|
|
10
|
+
|
|
11
|
+
field :to_date, -> { String }, optional: false, nullable: false, api_name: "toDate"
|
|
12
|
+
|
|
13
|
+
field :items, -> { Internal::Types::Array[Nordlet::Reports::Types::PeriodChecklistReportsResponseItemsItem] }, optional: false, nullable: false
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Reports
|
|
5
|
+
module Types
|
|
6
|
+
class PeriodChecklistReportsResponseItemsItem < Internal::Types::Model
|
|
7
|
+
field :code, -> { Nordlet::Reports::Types::PeriodChecklistReportsResponseItemsItemCode }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :count, -> { Integer }, optional: false, nullable: false
|
|
10
|
+
|
|
11
|
+
field :message, -> { String }, optional: false, nullable: false
|
|
12
|
+
|
|
13
|
+
field :ids, -> { Internal::Types::Array[String] }, optional: false, nullable: false
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Reports
|
|
5
|
+
module Types
|
|
6
|
+
module PeriodChecklistReportsResponseItemsItemCode
|
|
7
|
+
extend Nordlet::Internal::Types::Enum
|
|
8
|
+
|
|
9
|
+
DRAFT_SALE_DOCUMENTS = "draft_sale_documents"
|
|
10
|
+
DRAFT_PURCHASE_DOCUMENTS = "draft_purchase_documents"
|
|
11
|
+
UNBOOKED_BANK_LINES = "unbooked_bank_lines"
|
|
12
|
+
DEPRECIATION_NOT_POSTED = "depreciation_not_posted"
|
|
13
|
+
DEFERRALS_NOT_POSTED = "deferrals_not_posted"
|
|
14
|
+
RECURRING_INVOICES_NOT_GENERATED = "recurring_invoices_not_generated"
|
|
15
|
+
PAYROLL_RUNS_NOT_APPROVED = "payroll_runs_not_approved"
|
|
16
|
+
OPEN_FX_RECEIVABLES = "open_fx_receivables"
|
|
17
|
+
OPEN_FX_PAYABLES = "open_fx_payables"
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
data/lib/nordlet/sales/client.rb
CHANGED
|
@@ -15,7 +15,11 @@ module Nordlet
|
|
|
15
15
|
# `sales/invoices/issue`. Answers 422 when a credit note credits a proforma, another credit note or a document
|
|
16
16
|
# that is not issued, when the credited document has another partner or currency, when an OSS or IOSS document has
|
|
17
17
|
# no EU `vatCountryCode`, when the lines carry VAT but the company is not a VAT payer or the VAT scheme charges
|
|
18
|
-
# none, or when the operation type or document series is for another document type.
|
|
18
|
+
# none, or when the operation type or document series is for another document type. `warnings` lists what does not
|
|
19
|
+
# refuse the document but needs a look: `vat_type_not_valid_on_date` (a line VAT type is not valid on the issue
|
|
20
|
+
# date, else today), `vat_type_domestic_for_eu_partner` (a domestic VAT type for a partner VAT-registered in
|
|
21
|
+
# another EU country), `vat_type_intra_eu_for_domestic_partner` (an intra-EU VAT type for a partner in the company
|
|
22
|
+
# country) and `vat_type_intra_eu_without_vat_number` (an intra-EU VAT type for a partner without a VAT number).
|
|
19
23
|
#
|
|
20
24
|
# @param request_options [Hash]
|
|
21
25
|
# @param params [Nordlet::Sales::Types::InvoicesCreateSalesRequest]
|
|
@@ -123,9 +127,11 @@ module Nordlet
|
|
|
123
127
|
# Return a sale document as its customer sees it: the seller as printed on it (the snapshot taken at issue, else
|
|
124
128
|
# the company), the buyer with address and e-mail, the lines, the totals, `paidOn` (the date of the latest payment
|
|
125
129
|
# once the document is paid), `payUrl` (as in `sales/invoices/payment-link`; null while `cardPaymentReceived`),
|
|
126
|
-
# `cardPaymentReceived` (a completed card payment was received and the invoice waits for the payout settlement)
|
|
127
|
-
#
|
|
128
|
-
#
|
|
130
|
+
# `cardPaymentReceived` (a completed card payment was received and the invoice waits for the payout settlement),
|
|
131
|
+
# `sentWith` (the name the public invoice page prints in its "Sent with" line: Nordlet, or the brand name of the
|
|
132
|
+
# white-label partner who pays for the company, null when that partner has set no name) and `token`, the
|
|
133
|
+
# document's customer token for `public/invoices/get` and `public/invoices/pdf`, created on first use; `token` is
|
|
134
|
+
# null on a draft.
|
|
129
135
|
#
|
|
130
136
|
# @param request_options [Hash]
|
|
131
137
|
# @param params [Nordlet::Sales::Types::InvoicesViewSalesRequest]
|
|
@@ -310,8 +316,10 @@ module Nordlet
|
|
|
310
316
|
end
|
|
311
317
|
end
|
|
312
318
|
|
|
313
|
-
# Render an issued invoice as the national e-invoicing payload for the company country:
|
|
314
|
-
# (
|
|
319
|
+
# Render an issued invoice as the national e-invoicing payload for the company country: SII or Veri*Factu (ES),
|
|
320
|
+
# Factur-X (FR), myDATA (GR), Fiskalizacija (HR), NAV Online Számla (HU), FatturaPA (IT), KSeF FA(3) (PL), AT
|
|
321
|
+
# comunicação de faturas (PT) or UBL CIUS-RO (RO). Review the warnings - data the invoice does not carry is
|
|
322
|
+
# flagged, never invented.
|
|
315
323
|
#
|
|
316
324
|
# @param request_options [Hash]
|
|
317
325
|
# @param params [Nordlet::Sales::Types::InvoicesEinvoiceXMLSalesRequest]
|
|
@@ -503,7 +511,9 @@ module Nordlet
|
|
|
503
511
|
# `intercompany.invoice_mirrored` when the partner is linked to another company of the group (a draft purchase
|
|
504
512
|
# invoice is created there). Answers 409 when the document is already issued or locked or the accounting period is
|
|
505
513
|
# locked, 422 when the lines carry VAT under a scheme that charges none, when credit notes would exceed the
|
|
506
|
-
# credited total, or when `returnToStock` is used on anything but a credit note of an invoice.
|
|
514
|
+
# credited total, or when `returnToStock` is used on anything but a credit note of an invoice. `warnings` carries
|
|
515
|
+
# the VAT type warnings of `sales/invoices/create` and `document_date_before_last_number` when the document is
|
|
516
|
+
# dated before the last number issued in its series.
|
|
507
517
|
#
|
|
508
518
|
# @param request_options [Hash]
|
|
509
519
|
# @param params [Nordlet::Sales::Types::InvoicesIssueSalesRequest]
|
|
@@ -1406,7 +1416,8 @@ module Nordlet
|
|
|
1406
1416
|
# type), issues it when `autoIssue` is set and e-mails it when `autoSend` is set, then moves the schedule to its
|
|
1407
1417
|
# next occurrence (or to `finished` after the last one) and emits `recurring_invoice.generated`. A failure to
|
|
1408
1418
|
# issue or send comes back in `error` and is stored as `lastError`; the draft stays. Answers 409 when the schedule
|
|
1409
|
-
# is finished, 422 when the template is a credit note
|
|
1419
|
+
# is finished or its `nextRunDate` is after the company's current date, 422 when the template is a credit note
|
|
1420
|
+
# template or has no lines.
|
|
1410
1421
|
#
|
|
1411
1422
|
# @param request_options [Hash]
|
|
1412
1423
|
# @param params [Nordlet::Sales::Types::RecurringInvoicesGenerateSalesRequest]
|
|
@@ -137,6 +137,8 @@ module Nordlet
|
|
|
137
137
|
field :lines, -> { Internal::Types::Array[Nordlet::Sales::Types::InvoicesCreateSalesResponseLinesItem] }, optional: false, nullable: false
|
|
138
138
|
|
|
139
139
|
field :vat_evidence, -> { Nordlet::Sales::Types::InvoicesCreateSalesResponseVatEvidence }, optional: false, nullable: true, api_name: "vatEvidence"
|
|
140
|
+
|
|
141
|
+
field :warnings, -> { Internal::Types::Array[Nordlet::Sales::Types::InvoicesCreateSalesResponseWarningsItem] }, optional: false, nullable: false
|
|
140
142
|
end
|
|
141
143
|
end
|
|
142
144
|
end
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Sales
|
|
5
|
+
module Types
|
|
6
|
+
class InvoicesCreateSalesResponseWarningsItem < Internal::Types::Model
|
|
7
|
+
field :code, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :message, -> { String }, optional: false, nullable: false
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -137,6 +137,8 @@ module Nordlet
|
|
|
137
137
|
field :lines, -> { Internal::Types::Array[Nordlet::Sales::Types::InvoicesIssueSalesResponseLinesItem] }, optional: false, nullable: false
|
|
138
138
|
|
|
139
139
|
field :vat_evidence, -> { Nordlet::Sales::Types::InvoicesIssueSalesResponseVatEvidence }, optional: false, nullable: true, api_name: "vatEvidence"
|
|
140
|
+
|
|
141
|
+
field :warnings, -> { Internal::Types::Array[Nordlet::Sales::Types::InvoicesIssueSalesResponseWarningsItem] }, optional: false, nullable: false
|
|
140
142
|
end
|
|
141
143
|
end
|
|
142
144
|
end
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Nordlet
|
|
4
|
+
module Sales
|
|
5
|
+
module Types
|
|
6
|
+
class InvoicesIssueSalesResponseWarningsItem < Internal::Types::Model
|
|
7
|
+
field :code, -> { String }, optional: false, nullable: false
|
|
8
|
+
|
|
9
|
+
field :message, -> { String }, optional: false, nullable: false
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -38,6 +38,8 @@ module Nordlet
|
|
|
38
38
|
|
|
39
39
|
field :card_payment_received, -> { Internal::Types::Boolean }, optional: false, nullable: false, api_name: "cardPaymentReceived"
|
|
40
40
|
|
|
41
|
+
field :sent_with, -> { String }, optional: false, nullable: true, api_name: "sentWith"
|
|
42
|
+
|
|
41
43
|
field :seller, -> { Nordlet::Sales::Types::InvoicesViewSalesResponseSeller }, optional: false, nullable: false
|
|
42
44
|
|
|
43
45
|
field :buyer, -> { Nordlet::Sales::Types::InvoicesViewSalesResponseBuyer }, optional: false, nullable: false
|
data/lib/nordlet/version.rb
CHANGED