merge_ruby_client 2.0.0 → 2.1.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.
Files changed (159) hide show
  1. checksums.yaml +4 -4
  2. data/lib/merge_ruby_client/accounting/accounting_periods/client.rb +2 -2
  3. data/lib/merge_ruby_client/accounting/accounts/client.rb +2 -2
  4. data/lib/merge_ruby_client/accounting/attachments/client.rb +2 -2
  5. data/lib/merge_ruby_client/accounting/audit_trail/client.rb +2 -2
  6. data/lib/merge_ruby_client/accounting/balance_sheets/client.rb +2 -2
  7. data/lib/merge_ruby_client/accounting/bank_feed_accounts/client.rb +2 -2
  8. data/lib/merge_ruby_client/accounting/bank_feed_transactions/client.rb +2 -2
  9. data/lib/merge_ruby_client/accounting/cash_flow_statements/client.rb +2 -2
  10. data/lib/merge_ruby_client/accounting/client.rb +7 -0
  11. data/lib/merge_ruby_client/accounting/company_info/client.rb +2 -2
  12. data/lib/merge_ruby_client/accounting/contacts/client.rb +173 -4
  13. data/lib/merge_ruby_client/accounting/credit_notes/client.rb +2 -2
  14. data/lib/merge_ruby_client/accounting/employees/client.rb +35 -8
  15. data/lib/merge_ruby_client/accounting/expense_reports/client.rb +765 -0
  16. data/lib/merge_ruby_client/accounting/expense_reports/types/expense_reports_lines_list_request_expand.rb +73 -0
  17. data/lib/merge_ruby_client/accounting/expense_reports/types/expense_reports_list_request_expand.rb +25 -0
  18. data/lib/merge_ruby_client/accounting/expense_reports/types/expense_reports_retrieve_request_expand.rb +25 -0
  19. data/lib/merge_ruby_client/accounting/expenses/client.rb +6 -6
  20. data/lib/merge_ruby_client/accounting/general_ledger_transactions/client.rb +2 -2
  21. data/lib/merge_ruby_client/accounting/income_statements/client.rb +2 -2
  22. data/lib/merge_ruby_client/accounting/invoices/client.rb +6 -6
  23. data/lib/merge_ruby_client/accounting/issues/client.rb +2 -2
  24. data/lib/merge_ruby_client/accounting/items/client.rb +2 -2
  25. data/lib/merge_ruby_client/accounting/journal_entries/client.rb +6 -6
  26. data/lib/merge_ruby_client/accounting/linked_accounts/client.rb +2 -2
  27. data/lib/merge_ruby_client/accounting/payment_methods/client.rb +2 -2
  28. data/lib/merge_ruby_client/accounting/payment_terms/client.rb +2 -2
  29. data/lib/merge_ruby_client/accounting/payments/client.rb +6 -6
  30. data/lib/merge_ruby_client/accounting/projects/client.rb +35 -8
  31. data/lib/merge_ruby_client/accounting/purchase_orders/client.rb +6 -6
  32. data/lib/merge_ruby_client/accounting/sync_status/client.rb +2 -2
  33. data/lib/merge_ruby_client/accounting/tax_rates/client.rb +2 -2
  34. data/lib/merge_ruby_client/accounting/tracking_categories/client.rb +2 -2
  35. data/lib/merge_ruby_client/accounting/transactions/client.rb +2 -2
  36. data/lib/merge_ruby_client/accounting/transactions/types/transactions_list_request_expand.rb +32 -0
  37. data/lib/merge_ruby_client/accounting/transactions/types/transactions_retrieve_request_expand.rb +32 -0
  38. data/lib/merge_ruby_client/accounting/types/expense_report.rb +869 -0
  39. data/lib/merge_ruby_client/accounting/types/expense_report_company.rb +56 -0
  40. data/lib/merge_ruby_client/accounting/types/expense_report_line.rb +921 -0
  41. data/lib/merge_ruby_client/accounting/types/expense_report_line_account.rb +55 -0
  42. data/lib/merge_ruby_client/accounting/types/expense_report_line_company.rb +56 -0
  43. data/lib/merge_ruby_client/accounting/types/expense_report_line_contact.rb +55 -0
  44. data/lib/merge_ruby_client/accounting/types/expense_report_line_employee.rb +57 -0
  45. data/lib/merge_ruby_client/accounting/types/expense_report_line_project.rb +55 -0
  46. data/lib/merge_ruby_client/accounting/types/expense_report_line_request.rb +899 -0
  47. data/lib/merge_ruby_client/accounting/types/expense_report_line_request_account.rb +55 -0
  48. data/lib/merge_ruby_client/accounting/types/expense_report_line_request_company.rb +56 -0
  49. data/lib/merge_ruby_client/accounting/types/expense_report_line_request_contact.rb +55 -0
  50. data/lib/merge_ruby_client/accounting/types/expense_report_line_request_employee.rb +57 -0
  51. data/lib/merge_ruby_client/accounting/types/expense_report_line_request_project.rb +55 -0
  52. data/lib/merge_ruby_client/accounting/types/expense_report_line_request_tax_rate.rb +55 -0
  53. data/lib/merge_ruby_client/accounting/types/expense_report_line_tax_rate.rb +55 -0
  54. data/lib/merge_ruby_client/accounting/types/expense_report_request.rb +819 -0
  55. data/lib/merge_ruby_client/accounting/types/expense_report_request_accounting_period.rb +56 -0
  56. data/lib/merge_ruby_client/accounting/types/expense_report_request_company.rb +56 -0
  57. data/lib/merge_ruby_client/accounting/types/expense_report_request_employee.rb +57 -0
  58. data/lib/merge_ruby_client/accounting/types/expense_report_response.rb +101 -0
  59. data/lib/merge_ruby_client/accounting/types/expense_report_status_enum.rb +16 -0
  60. data/lib/merge_ruby_client/accounting/types/external_target_field_api_response.rb +12 -1
  61. data/lib/merge_ruby_client/accounting/types/field_mapping_api_instance_response.rb +12 -1
  62. data/lib/merge_ruby_client/accounting/types/item.rb +18 -1
  63. data/lib/merge_ruby_client/accounting/types/paginated_expense_report_line_list.rb +80 -0
  64. data/lib/merge_ruby_client/accounting/types/paginated_expense_report_list.rb +80 -0
  65. data/lib/merge_ruby_client/accounting/types/patched_contact_request.rb +188 -0
  66. data/lib/merge_ruby_client/accounting/types/patched_contact_request_addresses_item.rb +55 -0
  67. data/lib/merge_ruby_client/accounting/types/remote_field_class.rb +9 -1
  68. data/lib/merge_ruby_client/accounting/vendor_credits/client.rb +2 -2
  69. data/lib/merge_ruby_client/ats/activities/client.rb +2 -2
  70. data/lib/merge_ruby_client/ats/applications/client.rb +2 -2
  71. data/lib/merge_ruby_client/ats/attachments/client.rb +2 -2
  72. data/lib/merge_ruby_client/ats/audit_trail/client.rb +2 -2
  73. data/lib/merge_ruby_client/ats/candidates/client.rb +2 -2
  74. data/lib/merge_ruby_client/ats/departments/client.rb +2 -2
  75. data/lib/merge_ruby_client/ats/eeocs/client.rb +2 -2
  76. data/lib/merge_ruby_client/ats/interviews/client.rb +2 -2
  77. data/lib/merge_ruby_client/ats/issues/client.rb +2 -2
  78. data/lib/merge_ruby_client/ats/job_interview_stages/client.rb +2 -2
  79. data/lib/merge_ruby_client/ats/job_postings/client.rb +2 -2
  80. data/lib/merge_ruby_client/ats/jobs/client.rb +4 -4
  81. data/lib/merge_ruby_client/ats/linked_accounts/client.rb +2 -2
  82. data/lib/merge_ruby_client/ats/offers/client.rb +2 -2
  83. data/lib/merge_ruby_client/ats/offices/client.rb +2 -2
  84. data/lib/merge_ruby_client/ats/reject_reasons/client.rb +2 -2
  85. data/lib/merge_ruby_client/ats/scorecards/client.rb +2 -2
  86. data/lib/merge_ruby_client/ats/sync_status/client.rb +2 -2
  87. data/lib/merge_ruby_client/ats/tags/client.rb +2 -2
  88. data/lib/merge_ruby_client/ats/types/event_type_enum.rb +1 -0
  89. data/lib/merge_ruby_client/ats/users/client.rb +2 -2
  90. data/lib/merge_ruby_client/crm/accounts/client.rb +4 -4
  91. data/lib/merge_ruby_client/crm/association_types/client.rb +2 -2
  92. data/lib/merge_ruby_client/crm/associations/client.rb +10 -2
  93. data/lib/merge_ruby_client/crm/audit_trail/client.rb +2 -2
  94. data/lib/merge_ruby_client/crm/contacts/client.rb +4 -4
  95. data/lib/merge_ruby_client/crm/custom_object_classes/client.rb +2 -2
  96. data/lib/merge_ruby_client/crm/custom_objects/client.rb +4 -4
  97. data/lib/merge_ruby_client/crm/engagement_types/client.rb +4 -4
  98. data/lib/merge_ruby_client/crm/engagements/client.rb +4 -4
  99. data/lib/merge_ruby_client/crm/issues/client.rb +2 -2
  100. data/lib/merge_ruby_client/crm/leads/client.rb +4 -4
  101. data/lib/merge_ruby_client/crm/linked_accounts/client.rb +2 -2
  102. data/lib/merge_ruby_client/crm/notes/client.rb +4 -4
  103. data/lib/merge_ruby_client/crm/opportunities/client.rb +4 -4
  104. data/lib/merge_ruby_client/crm/stages/client.rb +4 -4
  105. data/lib/merge_ruby_client/crm/sync_status/client.rb +2 -2
  106. data/lib/merge_ruby_client/crm/tasks/client.rb +4 -4
  107. data/lib/merge_ruby_client/crm/types/remote_field_class.rb +9 -1
  108. data/lib/merge_ruby_client/crm/users/client.rb +4 -4
  109. data/lib/merge_ruby_client/filestorage/audit_trail/client.rb +2 -2
  110. data/lib/merge_ruby_client/filestorage/drives/client.rb +2 -2
  111. data/lib/merge_ruby_client/filestorage/files/client.rb +28 -10
  112. data/lib/merge_ruby_client/filestorage/folders/client.rb +2 -2
  113. data/lib/merge_ruby_client/filestorage/groups/client.rb +2 -2
  114. data/lib/merge_ruby_client/filestorage/issues/client.rb +2 -2
  115. data/lib/merge_ruby_client/filestorage/linked_accounts/client.rb +2 -2
  116. data/lib/merge_ruby_client/filestorage/sync_status/client.rb +2 -2
  117. data/lib/merge_ruby_client/filestorage/users/client.rb +2 -2
  118. data/lib/merge_ruby_client/hris/audit_trail/client.rb +2 -2
  119. data/lib/merge_ruby_client/hris/bank_info/client.rb +2 -2
  120. data/lib/merge_ruby_client/hris/benefits/client.rb +2 -2
  121. data/lib/merge_ruby_client/hris/companies/client.rb +2 -2
  122. data/lib/merge_ruby_client/hris/dependents/client.rb +8 -4
  123. data/lib/merge_ruby_client/hris/employee_payroll_runs/client.rb +2 -2
  124. data/lib/merge_ruby_client/hris/employees/client.rb +8 -4
  125. data/lib/merge_ruby_client/hris/employer_benefits/client.rb +2 -2
  126. data/lib/merge_ruby_client/hris/employments/client.rb +2 -2
  127. data/lib/merge_ruby_client/hris/groups/client.rb +2 -2
  128. data/lib/merge_ruby_client/hris/issues/client.rb +2 -2
  129. data/lib/merge_ruby_client/hris/linked_accounts/client.rb +2 -2
  130. data/lib/merge_ruby_client/hris/locations/client.rb +2 -2
  131. data/lib/merge_ruby_client/hris/pay_groups/client.rb +2 -2
  132. data/lib/merge_ruby_client/hris/payroll_runs/client.rb +2 -2
  133. data/lib/merge_ruby_client/hris/sync_status/client.rb +2 -2
  134. data/lib/merge_ruby_client/hris/teams/client.rb +2 -2
  135. data/lib/merge_ruby_client/hris/time_off/client.rb +2 -2
  136. data/lib/merge_ruby_client/hris/time_off_balances/client.rb +2 -2
  137. data/lib/merge_ruby_client/hris/timesheet_entries/client.rb +2 -2
  138. data/lib/merge_ruby_client/hris/types/benefit.rb +9 -9
  139. data/lib/merge_ruby_client/ticketing/accounts/client.rb +2 -2
  140. data/lib/merge_ruby_client/ticketing/attachments/client.rb +2 -2
  141. data/lib/merge_ruby_client/ticketing/audit_trail/client.rb +2 -2
  142. data/lib/merge_ruby_client/ticketing/collections/client.rb +4 -4
  143. data/lib/merge_ruby_client/ticketing/comments/client.rb +2 -2
  144. data/lib/merge_ruby_client/ticketing/contacts/client.rb +2 -2
  145. data/lib/merge_ruby_client/ticketing/issues/client.rb +2 -2
  146. data/lib/merge_ruby_client/ticketing/linked_accounts/client.rb +2 -2
  147. data/lib/merge_ruby_client/ticketing/projects/client.rb +4 -4
  148. data/lib/merge_ruby_client/ticketing/roles/client.rb +2 -2
  149. data/lib/merge_ruby_client/ticketing/sync_status/client.rb +2 -2
  150. data/lib/merge_ruby_client/ticketing/tags/client.rb +2 -2
  151. data/lib/merge_ruby_client/ticketing/teams/client.rb +2 -2
  152. data/lib/merge_ruby_client/ticketing/tickets/client.rb +14 -10
  153. data/lib/merge_ruby_client/ticketing/types/patched_ticket_request.rb +9 -9
  154. data/lib/merge_ruby_client/ticketing/types/remote_field_class.rb +9 -1
  155. data/lib/merge_ruby_client/ticketing/users/client.rb +2 -2
  156. data/lib/merge_ruby_client.rb +7 -7
  157. data/lib/requests.rb +2 -2
  158. data/lib/types_export.rb +230 -201
  159. metadata +32 -2
@@ -0,0 +1,921 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "date"
4
+ require_relative "expense_report_line_account"
5
+ require_relative "transaction_currency_enum"
6
+ require_relative "expense_report_line_employee"
7
+ require_relative "expense_report_line_project"
8
+ require_relative "expense_report_line_company"
9
+ require_relative "expense_report_line_contact"
10
+ require_relative "expense_report_line_tax_rate"
11
+ require_relative "remote_field"
12
+ require "ostruct"
13
+ require "json"
14
+
15
+ module Merge
16
+ module Accounting
17
+ # # The ExpenseReportLine Object
18
+ # ### Description
19
+ # The `ExpenseReportLine` object represents an individual line item within an
20
+ # expense report, containing details about
21
+ # a specific expense such as amount, description, and associated metadata.
22
+ # ### Usage Example
23
+ # Fetch from the `GET ExpenseReport` endpoint and expand the lines field to view
24
+ # all line items in the expense report.
25
+ class ExpenseReportLine
26
+ # @return [String]
27
+ attr_reader :id
28
+ # @return [String] The third-party API ID of the matching object.
29
+ attr_reader :remote_id
30
+ # @return [DateTime] The datetime that this object was created by Merge.
31
+ attr_reader :created_at
32
+ # @return [DateTime] The datetime that this object was modified by Merge.
33
+ attr_reader :modified_at
34
+ # @return [Merge::Accounting::ExpenseReportLineAccount]
35
+ attr_reader :account
36
+ # @return [String] Description of the individual expense.
37
+ attr_reader :description
38
+ # @return [DateTime] The date the individual expense was incurred.
39
+ attr_reader :expense_date
40
+ # @return [Float] The amount of the expense for the line item.
41
+ attr_reader :amount
42
+ # @return [Merge::Accounting::TransactionCurrencyEnum] Currency of the expense line (if different from the report currency).
43
+ # * `XUA` - ADB Unit of Account
44
+ # * `AFN` - Afghan Afghani
45
+ # * `AFA` - Afghan Afghani (1927–2002)
46
+ # * `ALL` - Albanian Lek
47
+ # * `ALK` - Albanian Lek (1946–1965)
48
+ # * `DZD` - Algerian Dinar
49
+ # * `ADP` - Andorran Peseta
50
+ # * `AOA` - Angolan Kwanza
51
+ # * `AOK` - Angolan Kwanza (1977–1991)
52
+ # * `AON` - Angolan New Kwanza (1990–2000)
53
+ # * `AOR` - Angolan Readjusted Kwanza (1995–1999)
54
+ # * `ARA` - Argentine Austral
55
+ # * `ARS` - Argentine Peso
56
+ # * `ARM` - Argentine Peso (1881–1970)
57
+ # * `ARP` - Argentine Peso (1983–1985)
58
+ # * `ARL` - Argentine Peso Ley (1970–1983)
59
+ # * `AMD` - Armenian Dram
60
+ # * `AWG` - Aruban Florin
61
+ # * `AUD` - Australian Dollar
62
+ # * `ATS` - Austrian Schilling
63
+ # * `AZN` - Azerbaijani Manat
64
+ # * `AZM` - Azerbaijani Manat (1993–2006)
65
+ # * `BSD` - Bahamian Dollar
66
+ # * `BHD` - Bahraini Dinar
67
+ # * `BDT` - Bangladeshi Taka
68
+ # * `BBD` - Barbadian Dollar
69
+ # * `BYN` - Belarusian Ruble
70
+ # * `BYB` - Belarusian Ruble (1994–1999)
71
+ # * `BYR` - Belarusian Ruble (2000–2016)
72
+ # * `BEF` - Belgian Franc
73
+ # * `BEC` - Belgian Franc (convertible)
74
+ # * `BEL` - Belgian Franc (financial)
75
+ # * `BZD` - Belize Dollar
76
+ # * `BMD` - Bermudan Dollar
77
+ # * `BTN` - Bhutanese Ngultrum
78
+ # * `BOB` - Bolivian Boliviano
79
+ # * `BOL` - Bolivian Boliviano (1863–1963)
80
+ # * `BOV` - Bolivian Mvdol
81
+ # * `BOP` - Bolivian Peso
82
+ # * `BAM` - Bosnia-Herzegovina Convertible Mark
83
+ # * `BAD` - Bosnia-Herzegovina Dinar (1992–1994)
84
+ # * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997)
85
+ # * `BWP` - Botswanan Pula
86
+ # * `BRC` - Brazilian Cruzado (1986–1989)
87
+ # * `BRZ` - Brazilian Cruzeiro (1942–1967)
88
+ # * `BRE` - Brazilian Cruzeiro (1990–1993)
89
+ # * `BRR` - Brazilian Cruzeiro (1993–1994)
90
+ # * `BRN` - Brazilian New Cruzado (1989–1990)
91
+ # * `BRB` - Brazilian New Cruzeiro (1967–1986)
92
+ # * `BRL` - Brazilian Real
93
+ # * `GBP` - British Pound
94
+ # * `BND` - Brunei Dollar
95
+ # * `BGL` - Bulgarian Hard Lev
96
+ # * `BGN` - Bulgarian Lev
97
+ # * `BGO` - Bulgarian Lev (1879–1952)
98
+ # * `BGM` - Bulgarian Socialist Lev
99
+ # * `BUK` - Burmese Kyat
100
+ # * `BIF` - Burundian Franc
101
+ # * `XPF` - CFP Franc
102
+ # * `KHR` - Cambodian Riel
103
+ # * `CAD` - Canadian Dollar
104
+ # * `CVE` - Cape Verdean Escudo
105
+ # * `KYD` - Cayman Islands Dollar
106
+ # * `XAF` - Central African CFA Franc
107
+ # * `CLE` - Chilean Escudo
108
+ # * `CLP` - Chilean Peso
109
+ # * `CLF` - Chilean Unit of Account (UF)
110
+ # * `CNX` - Chinese People’s Bank Dollar
111
+ # * `CNY` - Chinese Yuan
112
+ # * `CNH` - Chinese Yuan (offshore)
113
+ # * `COP` - Colombian Peso
114
+ # * `COU` - Colombian Real Value Unit
115
+ # * `KMF` - Comorian Franc
116
+ # * `CDF` - Congolese Franc
117
+ # * `CRC` - Costa Rican Colón
118
+ # * `HRD` - Croatian Dinar
119
+ # * `HRK` - Croatian Kuna
120
+ # * `CUC` - Cuban Convertible Peso
121
+ # * `CUP` - Cuban Peso
122
+ # * `CYP` - Cypriot Pound
123
+ # * `CZK` - Czech Koruna
124
+ # * `CSK` - Czechoslovak Hard Koruna
125
+ # * `DKK` - Danish Krone
126
+ # * `DJF` - Djiboutian Franc
127
+ # * `DOP` - Dominican Peso
128
+ # * `NLG` - Dutch Guilder
129
+ # * `XCD` - East Caribbean Dollar
130
+ # * `DDM` - East German Mark
131
+ # * `ECS` - Ecuadorian Sucre
132
+ # * `ECV` - Ecuadorian Unit of Constant Value
133
+ # * `EGP` - Egyptian Pound
134
+ # * `GQE` - Equatorial Guinean Ekwele
135
+ # * `ERN` - Eritrean Nakfa
136
+ # * `EEK` - Estonian Kroon
137
+ # * `ETB` - Ethiopian Birr
138
+ # * `EUR` - Euro
139
+ # * `XBA` - European Composite Unit
140
+ # * `XEU` - European Currency Unit
141
+ # * `XBB` - European Monetary Unit
142
+ # * `XBC` - European Unit of Account (XBC)
143
+ # * `XBD` - European Unit of Account (XBD)
144
+ # * `FKP` - Falkland Islands Pound
145
+ # * `FJD` - Fijian Dollar
146
+ # * `FIM` - Finnish Markka
147
+ # * `FRF` - French Franc
148
+ # * `XFO` - French Gold Franc
149
+ # * `XFU` - French UIC-Franc
150
+ # * `GMD` - Gambian Dalasi
151
+ # * `GEK` - Georgian Kupon Larit
152
+ # * `GEL` - Georgian Lari
153
+ # * `DEM` - German Mark
154
+ # * `GHS` - Ghanaian Cedi
155
+ # * `GHC` - Ghanaian Cedi (1979–2007)
156
+ # * `GIP` - Gibraltar Pound
157
+ # * `XAU` - Gold
158
+ # * `GRD` - Greek Drachma
159
+ # * `GTQ` - Guatemalan Quetzal
160
+ # * `GWP` - Guinea-Bissau Peso
161
+ # * `GNF` - Guinean Franc
162
+ # * `GNS` - Guinean Syli
163
+ # * `GYD` - Guyanaese Dollar
164
+ # * `HTG` - Haitian Gourde
165
+ # * `HNL` - Honduran Lempira
166
+ # * `HKD` - Hong Kong Dollar
167
+ # * `HUF` - Hungarian Forint
168
+ # * `IMP` - IMP
169
+ # * `ISK` - Icelandic Króna
170
+ # * `ISJ` - Icelandic Króna (1918–1981)
171
+ # * `INR` - Indian Rupee
172
+ # * `IDR` - Indonesian Rupiah
173
+ # * `IRR` - Iranian Rial
174
+ # * `IQD` - Iraqi Dinar
175
+ # * `IEP` - Irish Pound
176
+ # * `ILS` - Israeli New Shekel
177
+ # * `ILP` - Israeli Pound
178
+ # * `ILR` - Israeli Shekel (1980–1985)
179
+ # * `ITL` - Italian Lira
180
+ # * `JMD` - Jamaican Dollar
181
+ # * `JPY` - Japanese Yen
182
+ # * `JOD` - Jordanian Dinar
183
+ # * `KZT` - Kazakhstani Tenge
184
+ # * `KES` - Kenyan Shilling
185
+ # * `KWD` - Kuwaiti Dinar
186
+ # * `KGS` - Kyrgystani Som
187
+ # * `LAK` - Laotian Kip
188
+ # * `LVL` - Latvian Lats
189
+ # * `LVR` - Latvian Ruble
190
+ # * `LBP` - Lebanese Pound
191
+ # * `LSL` - Lesotho Loti
192
+ # * `LRD` - Liberian Dollar
193
+ # * `LYD` - Libyan Dinar
194
+ # * `LTL` - Lithuanian Litas
195
+ # * `LTT` - Lithuanian Talonas
196
+ # * `LUL` - Luxembourg Financial Franc
197
+ # * `LUC` - Luxembourgian Convertible Franc
198
+ # * `LUF` - Luxembourgian Franc
199
+ # * `MOP` - Macanese Pataca
200
+ # * `MKD` - Macedonian Denar
201
+ # * `MKN` - Macedonian Denar (1992–1993)
202
+ # * `MGA` - Malagasy Ariary
203
+ # * `MGF` - Malagasy Franc
204
+ # * `MWK` - Malawian Kwacha
205
+ # * `MYR` - Malaysian Ringgit
206
+ # * `MVR` - Maldivian Rufiyaa
207
+ # * `MVP` - Maldivian Rupee (1947–1981)
208
+ # * `MLF` - Malian Franc
209
+ # * `MTL` - Maltese Lira
210
+ # * `MTP` - Maltese Pound
211
+ # * `MRU` - Mauritanian Ouguiya
212
+ # * `MRO` - Mauritanian Ouguiya (1973–2017)
213
+ # * `MUR` - Mauritian Rupee
214
+ # * `MXV` - Mexican Investment Unit
215
+ # * `MXN` - Mexican Peso
216
+ # * `MXP` - Mexican Silver Peso (1861–1992)
217
+ # * `MDC` - Moldovan Cupon
218
+ # * `MDL` - Moldovan Leu
219
+ # * `MCF` - Monegasque Franc
220
+ # * `MNT` - Mongolian Tugrik
221
+ # * `MAD` - Moroccan Dirham
222
+ # * `MAF` - Moroccan Franc
223
+ # * `MZE` - Mozambican Escudo
224
+ # * `MZN` - Mozambican Metical
225
+ # * `MZM` - Mozambican Metical (1980–2006)
226
+ # * `MMK` - Myanmar Kyat
227
+ # * `NAD` - Namibian Dollar
228
+ # * `NPR` - Nepalese Rupee
229
+ # * `ANG` - Netherlands Antillean Guilder
230
+ # * `TWD` - New Taiwan Dollar
231
+ # * `NZD` - New Zealand Dollar
232
+ # * `NIO` - Nicaraguan Córdoba
233
+ # * `NIC` - Nicaraguan Córdoba (1988–1991)
234
+ # * `NGN` - Nigerian Naira
235
+ # * `KPW` - North Korean Won
236
+ # * `NOK` - Norwegian Krone
237
+ # * `OMR` - Omani Rial
238
+ # * `PKR` - Pakistani Rupee
239
+ # * `XPD` - Palladium
240
+ # * `PAB` - Panamanian Balboa
241
+ # * `PGK` - Papua New Guinean Kina
242
+ # * `PYG` - Paraguayan Guarani
243
+ # * `PEI` - Peruvian Inti
244
+ # * `PEN` - Peruvian Sol
245
+ # * `PES` - Peruvian Sol (1863–1965)
246
+ # * `PHP` - Philippine Peso
247
+ # * `XPT` - Platinum
248
+ # * `PLN` - Polish Zloty
249
+ # * `PLZ` - Polish Zloty (1950–1995)
250
+ # * `PTE` - Portuguese Escudo
251
+ # * `GWE` - Portuguese Guinea Escudo
252
+ # * `QAR` - Qatari Rial
253
+ # * `XRE` - RINET Funds
254
+ # * `RHD` - Rhodesian Dollar
255
+ # * `RON` - Romanian Leu
256
+ # * `ROL` - Romanian Leu (1952–2006)
257
+ # * `RUB` - Russian Ruble
258
+ # * `RUR` - Russian Ruble (1991–1998)
259
+ # * `RWF` - Rwandan Franc
260
+ # * `SVC` - Salvadoran Colón
261
+ # * `WST` - Samoan Tala
262
+ # * `SAR` - Saudi Riyal
263
+ # * `RSD` - Serbian Dinar
264
+ # * `CSD` - Serbian Dinar (2002–2006)
265
+ # * `SCR` - Seychellois Rupee
266
+ # * `SLL` - Sierra Leonean Leone
267
+ # * `XAG` - Silver
268
+ # * `SGD` - Singapore Dollar
269
+ # * `SKK` - Slovak Koruna
270
+ # * `SIT` - Slovenian Tolar
271
+ # * `SBD` - Solomon Islands Dollar
272
+ # * `SOS` - Somali Shilling
273
+ # * `ZAR` - South African Rand
274
+ # * `ZAL` - South African Rand (financial)
275
+ # * `KRH` - South Korean Hwan (1953–1962)
276
+ # * `KRW` - South Korean Won
277
+ # * `KRO` - South Korean Won (1945–1953)
278
+ # * `SSP` - South Sudanese Pound
279
+ # * `SUR` - Soviet Rouble
280
+ # * `ESP` - Spanish Peseta
281
+ # * `ESA` - Spanish Peseta (A account)
282
+ # * `ESB` - Spanish Peseta (convertible account)
283
+ # * `XDR` - Special Drawing Rights
284
+ # * `LKR` - Sri Lankan Rupee
285
+ # * `SHP` - St. Helena Pound
286
+ # * `XSU` - Sucre
287
+ # * `SDD` - Sudanese Dinar (1992–2007)
288
+ # * `SDG` - Sudanese Pound
289
+ # * `SDP` - Sudanese Pound (1957–1998)
290
+ # * `SRD` - Surinamese Dollar
291
+ # * `SRG` - Surinamese Guilder
292
+ # * `SZL` - Swazi Lilangeni
293
+ # * `SEK` - Swedish Krona
294
+ # * `CHF` - Swiss Franc
295
+ # * `SYP` - Syrian Pound
296
+ # * `STN` - São Tomé & Príncipe Dobra
297
+ # * `STD` - São Tomé & Príncipe Dobra (1977–2017)
298
+ # * `TVD` - TVD
299
+ # * `TJR` - Tajikistani Ruble
300
+ # * `TJS` - Tajikistani Somoni
301
+ # * `TZS` - Tanzanian Shilling
302
+ # * `XTS` - Testing Currency Code
303
+ # * `THB` - Thai Baht
304
+ # * `XXX` - The codes assigned for transactions where no currency is involved
305
+ # * `TPE` - Timorese Escudo
306
+ # * `TOP` - Tongan Paʻanga
307
+ # * `TTD` - Trinidad & Tobago Dollar
308
+ # * `TND` - Tunisian Dinar
309
+ # * `TRY` - Turkish Lira
310
+ # * `TRL` - Turkish Lira (1922–2005)
311
+ # * `TMT` - Turkmenistani Manat
312
+ # * `TMM` - Turkmenistani Manat (1993–2009)
313
+ # * `USD` - US Dollar
314
+ # * `USN` - US Dollar (Next day)
315
+ # * `USS` - US Dollar (Same day)
316
+ # * `UGX` - Ugandan Shilling
317
+ # * `UGS` - Ugandan Shilling (1966–1987)
318
+ # * `UAH` - Ukrainian Hryvnia
319
+ # * `UAK` - Ukrainian Karbovanets
320
+ # * `AED` - United Arab Emirates Dirham
321
+ # * `UYW` - Uruguayan Nominal Wage Index Unit
322
+ # * `UYU` - Uruguayan Peso
323
+ # * `UYP` - Uruguayan Peso (1975–1993)
324
+ # * `UYI` - Uruguayan Peso (Indexed Units)
325
+ # * `UZS` - Uzbekistani Som
326
+ # * `VUV` - Vanuatu Vatu
327
+ # * `VES` - Venezuelan Bolívar
328
+ # * `VEB` - Venezuelan Bolívar (1871–2008)
329
+ # * `VEF` - Venezuelan Bolívar (2008–2018)
330
+ # * `VND` - Vietnamese Dong
331
+ # * `VNN` - Vietnamese Dong (1978–1985)
332
+ # * `CHE` - WIR Euro
333
+ # * `CHW` - WIR Franc
334
+ # * `XOF` - West African CFA Franc
335
+ # * `YDD` - Yemeni Dinar
336
+ # * `YER` - Yemeni Rial
337
+ # * `YUN` - Yugoslavian Convertible Dinar (1990–1992)
338
+ # * `YUD` - Yugoslavian Hard Dinar (1966–1990)
339
+ # * `YUM` - Yugoslavian New Dinar (1994–2002)
340
+ # * `YUR` - Yugoslavian Reformed Dinar (1992–1993)
341
+ # * `ZWN` - ZWN
342
+ # * `ZRN` - Zairean New Zaire (1993–1998)
343
+ # * `ZRZ` - Zairean Zaire (1971–1993)
344
+ # * `ZMW` - Zambian Kwacha
345
+ # * `ZMK` - Zambian Kwacha (1968–2012)
346
+ # * `ZWD` - Zimbabwean Dollar (1980–2008)
347
+ # * `ZWR` - Zimbabwean Dollar (2008)
348
+ # * `ZWL` - Zimbabwean Dollar (2009)
349
+ attr_reader :currency
350
+ # @return [String] Exchange rate used if the line item is in a foreign currency.
351
+ attr_reader :exchange_rate
352
+ # @return [Boolean] Whether the expense line is billable to a client or project.
353
+ attr_reader :is_billable
354
+ # @return [Array<String>] The related tracking categories associated with the expense report (Department,
355
+ # Location, Class, Expense Category)
356
+ attr_reader :tracking_categories
357
+ # @return [Merge::Accounting::ExpenseReportLineEmployee] Identifier for the employee who submitted or is associated with the expense
358
+ # report
359
+ attr_reader :employee
360
+ # @return [Merge::Accounting::ExpenseReportLineProject]
361
+ attr_reader :project
362
+ # @return [Merge::Accounting::ExpenseReportLineCompany] The subsidiary that the expense report is created in
363
+ attr_reader :company
364
+ # @return [Merge::Accounting::ExpenseReportLineContact]
365
+ attr_reader :contact
366
+ # @return [Float] Quantity for the expense line (e.g., miles driven, items purchased).
367
+ attr_reader :quantity
368
+ # @return [Float] Price per unit for the expense line (if applicable).
369
+ attr_reader :unit_price
370
+ # @return [Boolean] Whether the expense line is non-reimbursable (e.g., paid via company card).
371
+ attr_reader :non_reimbursable
372
+ # @return [Float] Tax amount applicable for the line item.
373
+ attr_reader :tax_amount
374
+ # @return [Boolean] Whether the amount is inclusive of tax.
375
+ attr_reader :inclusive_of_tax
376
+ # @return [Merge::Accounting::ExpenseReportLineTaxRate]
377
+ attr_reader :tax_rate
378
+ # @return [Boolean] Indicates whether or not this object has been deleted in the third party
379
+ # platform. Full coverage deletion detection is a premium add-on. Native deletion
380
+ # detection is offered for free with limited coverage. [Learn
381
+ # more](https://docs.merge.dev/integrations/hris/supported-features/).
382
+ attr_reader :remote_was_deleted
383
+ # @return [Array<Merge::Accounting::RemoteField>]
384
+ attr_reader :remote_fields
385
+ # @return [OpenStruct] Additional properties unmapped to the current class definition
386
+ attr_reader :additional_properties
387
+ # @return [Object]
388
+ attr_reader :_field_set
389
+ protected :_field_set
390
+
391
+ OMIT = Object.new
392
+
393
+ # @param id [String]
394
+ # @param remote_id [String] The third-party API ID of the matching object.
395
+ # @param created_at [DateTime] The datetime that this object was created by Merge.
396
+ # @param modified_at [DateTime] The datetime that this object was modified by Merge.
397
+ # @param account [Merge::Accounting::ExpenseReportLineAccount]
398
+ # @param description [String] Description of the individual expense.
399
+ # @param expense_date [DateTime] The date the individual expense was incurred.
400
+ # @param amount [Float] The amount of the expense for the line item.
401
+ # @param currency [Merge::Accounting::TransactionCurrencyEnum] Currency of the expense line (if different from the report currency).
402
+ # * `XUA` - ADB Unit of Account
403
+ # * `AFN` - Afghan Afghani
404
+ # * `AFA` - Afghan Afghani (1927–2002)
405
+ # * `ALL` - Albanian Lek
406
+ # * `ALK` - Albanian Lek (1946–1965)
407
+ # * `DZD` - Algerian Dinar
408
+ # * `ADP` - Andorran Peseta
409
+ # * `AOA` - Angolan Kwanza
410
+ # * `AOK` - Angolan Kwanza (1977–1991)
411
+ # * `AON` - Angolan New Kwanza (1990–2000)
412
+ # * `AOR` - Angolan Readjusted Kwanza (1995–1999)
413
+ # * `ARA` - Argentine Austral
414
+ # * `ARS` - Argentine Peso
415
+ # * `ARM` - Argentine Peso (1881–1970)
416
+ # * `ARP` - Argentine Peso (1983–1985)
417
+ # * `ARL` - Argentine Peso Ley (1970–1983)
418
+ # * `AMD` - Armenian Dram
419
+ # * `AWG` - Aruban Florin
420
+ # * `AUD` - Australian Dollar
421
+ # * `ATS` - Austrian Schilling
422
+ # * `AZN` - Azerbaijani Manat
423
+ # * `AZM` - Azerbaijani Manat (1993–2006)
424
+ # * `BSD` - Bahamian Dollar
425
+ # * `BHD` - Bahraini Dinar
426
+ # * `BDT` - Bangladeshi Taka
427
+ # * `BBD` - Barbadian Dollar
428
+ # * `BYN` - Belarusian Ruble
429
+ # * `BYB` - Belarusian Ruble (1994–1999)
430
+ # * `BYR` - Belarusian Ruble (2000–2016)
431
+ # * `BEF` - Belgian Franc
432
+ # * `BEC` - Belgian Franc (convertible)
433
+ # * `BEL` - Belgian Franc (financial)
434
+ # * `BZD` - Belize Dollar
435
+ # * `BMD` - Bermudan Dollar
436
+ # * `BTN` - Bhutanese Ngultrum
437
+ # * `BOB` - Bolivian Boliviano
438
+ # * `BOL` - Bolivian Boliviano (1863–1963)
439
+ # * `BOV` - Bolivian Mvdol
440
+ # * `BOP` - Bolivian Peso
441
+ # * `BAM` - Bosnia-Herzegovina Convertible Mark
442
+ # * `BAD` - Bosnia-Herzegovina Dinar (1992–1994)
443
+ # * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997)
444
+ # * `BWP` - Botswanan Pula
445
+ # * `BRC` - Brazilian Cruzado (1986–1989)
446
+ # * `BRZ` - Brazilian Cruzeiro (1942–1967)
447
+ # * `BRE` - Brazilian Cruzeiro (1990–1993)
448
+ # * `BRR` - Brazilian Cruzeiro (1993–1994)
449
+ # * `BRN` - Brazilian New Cruzado (1989–1990)
450
+ # * `BRB` - Brazilian New Cruzeiro (1967–1986)
451
+ # * `BRL` - Brazilian Real
452
+ # * `GBP` - British Pound
453
+ # * `BND` - Brunei Dollar
454
+ # * `BGL` - Bulgarian Hard Lev
455
+ # * `BGN` - Bulgarian Lev
456
+ # * `BGO` - Bulgarian Lev (1879–1952)
457
+ # * `BGM` - Bulgarian Socialist Lev
458
+ # * `BUK` - Burmese Kyat
459
+ # * `BIF` - Burundian Franc
460
+ # * `XPF` - CFP Franc
461
+ # * `KHR` - Cambodian Riel
462
+ # * `CAD` - Canadian Dollar
463
+ # * `CVE` - Cape Verdean Escudo
464
+ # * `KYD` - Cayman Islands Dollar
465
+ # * `XAF` - Central African CFA Franc
466
+ # * `CLE` - Chilean Escudo
467
+ # * `CLP` - Chilean Peso
468
+ # * `CLF` - Chilean Unit of Account (UF)
469
+ # * `CNX` - Chinese People’s Bank Dollar
470
+ # * `CNY` - Chinese Yuan
471
+ # * `CNH` - Chinese Yuan (offshore)
472
+ # * `COP` - Colombian Peso
473
+ # * `COU` - Colombian Real Value Unit
474
+ # * `KMF` - Comorian Franc
475
+ # * `CDF` - Congolese Franc
476
+ # * `CRC` - Costa Rican Colón
477
+ # * `HRD` - Croatian Dinar
478
+ # * `HRK` - Croatian Kuna
479
+ # * `CUC` - Cuban Convertible Peso
480
+ # * `CUP` - Cuban Peso
481
+ # * `CYP` - Cypriot Pound
482
+ # * `CZK` - Czech Koruna
483
+ # * `CSK` - Czechoslovak Hard Koruna
484
+ # * `DKK` - Danish Krone
485
+ # * `DJF` - Djiboutian Franc
486
+ # * `DOP` - Dominican Peso
487
+ # * `NLG` - Dutch Guilder
488
+ # * `XCD` - East Caribbean Dollar
489
+ # * `DDM` - East German Mark
490
+ # * `ECS` - Ecuadorian Sucre
491
+ # * `ECV` - Ecuadorian Unit of Constant Value
492
+ # * `EGP` - Egyptian Pound
493
+ # * `GQE` - Equatorial Guinean Ekwele
494
+ # * `ERN` - Eritrean Nakfa
495
+ # * `EEK` - Estonian Kroon
496
+ # * `ETB` - Ethiopian Birr
497
+ # * `EUR` - Euro
498
+ # * `XBA` - European Composite Unit
499
+ # * `XEU` - European Currency Unit
500
+ # * `XBB` - European Monetary Unit
501
+ # * `XBC` - European Unit of Account (XBC)
502
+ # * `XBD` - European Unit of Account (XBD)
503
+ # * `FKP` - Falkland Islands Pound
504
+ # * `FJD` - Fijian Dollar
505
+ # * `FIM` - Finnish Markka
506
+ # * `FRF` - French Franc
507
+ # * `XFO` - French Gold Franc
508
+ # * `XFU` - French UIC-Franc
509
+ # * `GMD` - Gambian Dalasi
510
+ # * `GEK` - Georgian Kupon Larit
511
+ # * `GEL` - Georgian Lari
512
+ # * `DEM` - German Mark
513
+ # * `GHS` - Ghanaian Cedi
514
+ # * `GHC` - Ghanaian Cedi (1979–2007)
515
+ # * `GIP` - Gibraltar Pound
516
+ # * `XAU` - Gold
517
+ # * `GRD` - Greek Drachma
518
+ # * `GTQ` - Guatemalan Quetzal
519
+ # * `GWP` - Guinea-Bissau Peso
520
+ # * `GNF` - Guinean Franc
521
+ # * `GNS` - Guinean Syli
522
+ # * `GYD` - Guyanaese Dollar
523
+ # * `HTG` - Haitian Gourde
524
+ # * `HNL` - Honduran Lempira
525
+ # * `HKD` - Hong Kong Dollar
526
+ # * `HUF` - Hungarian Forint
527
+ # * `IMP` - IMP
528
+ # * `ISK` - Icelandic Króna
529
+ # * `ISJ` - Icelandic Króna (1918–1981)
530
+ # * `INR` - Indian Rupee
531
+ # * `IDR` - Indonesian Rupiah
532
+ # * `IRR` - Iranian Rial
533
+ # * `IQD` - Iraqi Dinar
534
+ # * `IEP` - Irish Pound
535
+ # * `ILS` - Israeli New Shekel
536
+ # * `ILP` - Israeli Pound
537
+ # * `ILR` - Israeli Shekel (1980–1985)
538
+ # * `ITL` - Italian Lira
539
+ # * `JMD` - Jamaican Dollar
540
+ # * `JPY` - Japanese Yen
541
+ # * `JOD` - Jordanian Dinar
542
+ # * `KZT` - Kazakhstani Tenge
543
+ # * `KES` - Kenyan Shilling
544
+ # * `KWD` - Kuwaiti Dinar
545
+ # * `KGS` - Kyrgystani Som
546
+ # * `LAK` - Laotian Kip
547
+ # * `LVL` - Latvian Lats
548
+ # * `LVR` - Latvian Ruble
549
+ # * `LBP` - Lebanese Pound
550
+ # * `LSL` - Lesotho Loti
551
+ # * `LRD` - Liberian Dollar
552
+ # * `LYD` - Libyan Dinar
553
+ # * `LTL` - Lithuanian Litas
554
+ # * `LTT` - Lithuanian Talonas
555
+ # * `LUL` - Luxembourg Financial Franc
556
+ # * `LUC` - Luxembourgian Convertible Franc
557
+ # * `LUF` - Luxembourgian Franc
558
+ # * `MOP` - Macanese Pataca
559
+ # * `MKD` - Macedonian Denar
560
+ # * `MKN` - Macedonian Denar (1992–1993)
561
+ # * `MGA` - Malagasy Ariary
562
+ # * `MGF` - Malagasy Franc
563
+ # * `MWK` - Malawian Kwacha
564
+ # * `MYR` - Malaysian Ringgit
565
+ # * `MVR` - Maldivian Rufiyaa
566
+ # * `MVP` - Maldivian Rupee (1947–1981)
567
+ # * `MLF` - Malian Franc
568
+ # * `MTL` - Maltese Lira
569
+ # * `MTP` - Maltese Pound
570
+ # * `MRU` - Mauritanian Ouguiya
571
+ # * `MRO` - Mauritanian Ouguiya (1973–2017)
572
+ # * `MUR` - Mauritian Rupee
573
+ # * `MXV` - Mexican Investment Unit
574
+ # * `MXN` - Mexican Peso
575
+ # * `MXP` - Mexican Silver Peso (1861–1992)
576
+ # * `MDC` - Moldovan Cupon
577
+ # * `MDL` - Moldovan Leu
578
+ # * `MCF` - Monegasque Franc
579
+ # * `MNT` - Mongolian Tugrik
580
+ # * `MAD` - Moroccan Dirham
581
+ # * `MAF` - Moroccan Franc
582
+ # * `MZE` - Mozambican Escudo
583
+ # * `MZN` - Mozambican Metical
584
+ # * `MZM` - Mozambican Metical (1980–2006)
585
+ # * `MMK` - Myanmar Kyat
586
+ # * `NAD` - Namibian Dollar
587
+ # * `NPR` - Nepalese Rupee
588
+ # * `ANG` - Netherlands Antillean Guilder
589
+ # * `TWD` - New Taiwan Dollar
590
+ # * `NZD` - New Zealand Dollar
591
+ # * `NIO` - Nicaraguan Córdoba
592
+ # * `NIC` - Nicaraguan Córdoba (1988–1991)
593
+ # * `NGN` - Nigerian Naira
594
+ # * `KPW` - North Korean Won
595
+ # * `NOK` - Norwegian Krone
596
+ # * `OMR` - Omani Rial
597
+ # * `PKR` - Pakistani Rupee
598
+ # * `XPD` - Palladium
599
+ # * `PAB` - Panamanian Balboa
600
+ # * `PGK` - Papua New Guinean Kina
601
+ # * `PYG` - Paraguayan Guarani
602
+ # * `PEI` - Peruvian Inti
603
+ # * `PEN` - Peruvian Sol
604
+ # * `PES` - Peruvian Sol (1863–1965)
605
+ # * `PHP` - Philippine Peso
606
+ # * `XPT` - Platinum
607
+ # * `PLN` - Polish Zloty
608
+ # * `PLZ` - Polish Zloty (1950–1995)
609
+ # * `PTE` - Portuguese Escudo
610
+ # * `GWE` - Portuguese Guinea Escudo
611
+ # * `QAR` - Qatari Rial
612
+ # * `XRE` - RINET Funds
613
+ # * `RHD` - Rhodesian Dollar
614
+ # * `RON` - Romanian Leu
615
+ # * `ROL` - Romanian Leu (1952–2006)
616
+ # * `RUB` - Russian Ruble
617
+ # * `RUR` - Russian Ruble (1991–1998)
618
+ # * `RWF` - Rwandan Franc
619
+ # * `SVC` - Salvadoran Colón
620
+ # * `WST` - Samoan Tala
621
+ # * `SAR` - Saudi Riyal
622
+ # * `RSD` - Serbian Dinar
623
+ # * `CSD` - Serbian Dinar (2002–2006)
624
+ # * `SCR` - Seychellois Rupee
625
+ # * `SLL` - Sierra Leonean Leone
626
+ # * `XAG` - Silver
627
+ # * `SGD` - Singapore Dollar
628
+ # * `SKK` - Slovak Koruna
629
+ # * `SIT` - Slovenian Tolar
630
+ # * `SBD` - Solomon Islands Dollar
631
+ # * `SOS` - Somali Shilling
632
+ # * `ZAR` - South African Rand
633
+ # * `ZAL` - South African Rand (financial)
634
+ # * `KRH` - South Korean Hwan (1953–1962)
635
+ # * `KRW` - South Korean Won
636
+ # * `KRO` - South Korean Won (1945–1953)
637
+ # * `SSP` - South Sudanese Pound
638
+ # * `SUR` - Soviet Rouble
639
+ # * `ESP` - Spanish Peseta
640
+ # * `ESA` - Spanish Peseta (A account)
641
+ # * `ESB` - Spanish Peseta (convertible account)
642
+ # * `XDR` - Special Drawing Rights
643
+ # * `LKR` - Sri Lankan Rupee
644
+ # * `SHP` - St. Helena Pound
645
+ # * `XSU` - Sucre
646
+ # * `SDD` - Sudanese Dinar (1992–2007)
647
+ # * `SDG` - Sudanese Pound
648
+ # * `SDP` - Sudanese Pound (1957–1998)
649
+ # * `SRD` - Surinamese Dollar
650
+ # * `SRG` - Surinamese Guilder
651
+ # * `SZL` - Swazi Lilangeni
652
+ # * `SEK` - Swedish Krona
653
+ # * `CHF` - Swiss Franc
654
+ # * `SYP` - Syrian Pound
655
+ # * `STN` - São Tomé & Príncipe Dobra
656
+ # * `STD` - São Tomé & Príncipe Dobra (1977–2017)
657
+ # * `TVD` - TVD
658
+ # * `TJR` - Tajikistani Ruble
659
+ # * `TJS` - Tajikistani Somoni
660
+ # * `TZS` - Tanzanian Shilling
661
+ # * `XTS` - Testing Currency Code
662
+ # * `THB` - Thai Baht
663
+ # * `XXX` - The codes assigned for transactions where no currency is involved
664
+ # * `TPE` - Timorese Escudo
665
+ # * `TOP` - Tongan Paʻanga
666
+ # * `TTD` - Trinidad & Tobago Dollar
667
+ # * `TND` - Tunisian Dinar
668
+ # * `TRY` - Turkish Lira
669
+ # * `TRL` - Turkish Lira (1922–2005)
670
+ # * `TMT` - Turkmenistani Manat
671
+ # * `TMM` - Turkmenistani Manat (1993–2009)
672
+ # * `USD` - US Dollar
673
+ # * `USN` - US Dollar (Next day)
674
+ # * `USS` - US Dollar (Same day)
675
+ # * `UGX` - Ugandan Shilling
676
+ # * `UGS` - Ugandan Shilling (1966–1987)
677
+ # * `UAH` - Ukrainian Hryvnia
678
+ # * `UAK` - Ukrainian Karbovanets
679
+ # * `AED` - United Arab Emirates Dirham
680
+ # * `UYW` - Uruguayan Nominal Wage Index Unit
681
+ # * `UYU` - Uruguayan Peso
682
+ # * `UYP` - Uruguayan Peso (1975–1993)
683
+ # * `UYI` - Uruguayan Peso (Indexed Units)
684
+ # * `UZS` - Uzbekistani Som
685
+ # * `VUV` - Vanuatu Vatu
686
+ # * `VES` - Venezuelan Bolívar
687
+ # * `VEB` - Venezuelan Bolívar (1871–2008)
688
+ # * `VEF` - Venezuelan Bolívar (2008–2018)
689
+ # * `VND` - Vietnamese Dong
690
+ # * `VNN` - Vietnamese Dong (1978–1985)
691
+ # * `CHE` - WIR Euro
692
+ # * `CHW` - WIR Franc
693
+ # * `XOF` - West African CFA Franc
694
+ # * `YDD` - Yemeni Dinar
695
+ # * `YER` - Yemeni Rial
696
+ # * `YUN` - Yugoslavian Convertible Dinar (1990–1992)
697
+ # * `YUD` - Yugoslavian Hard Dinar (1966–1990)
698
+ # * `YUM` - Yugoslavian New Dinar (1994–2002)
699
+ # * `YUR` - Yugoslavian Reformed Dinar (1992–1993)
700
+ # * `ZWN` - ZWN
701
+ # * `ZRN` - Zairean New Zaire (1993–1998)
702
+ # * `ZRZ` - Zairean Zaire (1971–1993)
703
+ # * `ZMW` - Zambian Kwacha
704
+ # * `ZMK` - Zambian Kwacha (1968–2012)
705
+ # * `ZWD` - Zimbabwean Dollar (1980–2008)
706
+ # * `ZWR` - Zimbabwean Dollar (2008)
707
+ # * `ZWL` - Zimbabwean Dollar (2009)
708
+ # @param exchange_rate [String] Exchange rate used if the line item is in a foreign currency.
709
+ # @param is_billable [Boolean] Whether the expense line is billable to a client or project.
710
+ # @param tracking_categories [Array<String>] The related tracking categories associated with the expense report (Department,
711
+ # Location, Class, Expense Category)
712
+ # @param employee [Merge::Accounting::ExpenseReportLineEmployee] Identifier for the employee who submitted or is associated with the expense
713
+ # report
714
+ # @param project [Merge::Accounting::ExpenseReportLineProject]
715
+ # @param company [Merge::Accounting::ExpenseReportLineCompany] The subsidiary that the expense report is created in
716
+ # @param contact [Merge::Accounting::ExpenseReportLineContact]
717
+ # @param quantity [Float] Quantity for the expense line (e.g., miles driven, items purchased).
718
+ # @param unit_price [Float] Price per unit for the expense line (if applicable).
719
+ # @param non_reimbursable [Boolean] Whether the expense line is non-reimbursable (e.g., paid via company card).
720
+ # @param tax_amount [Float] Tax amount applicable for the line item.
721
+ # @param inclusive_of_tax [Boolean] Whether the amount is inclusive of tax.
722
+ # @param tax_rate [Merge::Accounting::ExpenseReportLineTaxRate]
723
+ # @param remote_was_deleted [Boolean] Indicates whether or not this object has been deleted in the third party
724
+ # platform. Full coverage deletion detection is a premium add-on. Native deletion
725
+ # detection is offered for free with limited coverage. [Learn
726
+ # more](https://docs.merge.dev/integrations/hris/supported-features/).
727
+ # @param remote_fields [Array<Merge::Accounting::RemoteField>]
728
+ # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
729
+ # @return [Merge::Accounting::ExpenseReportLine]
730
+ def initialize(tracking_categories:, id: OMIT, remote_id: OMIT, created_at: OMIT, modified_at: OMIT, account: OMIT, description: OMIT,
731
+ expense_date: OMIT, amount: OMIT, currency: OMIT, exchange_rate: OMIT, is_billable: OMIT, employee: OMIT, project: OMIT, company: OMIT, contact: OMIT, quantity: OMIT, unit_price: OMIT, non_reimbursable: OMIT, tax_amount: OMIT, inclusive_of_tax: OMIT, tax_rate: OMIT, remote_was_deleted: OMIT, remote_fields: OMIT, additional_properties: nil)
732
+ @id = id if id != OMIT
733
+ @remote_id = remote_id if remote_id != OMIT
734
+ @created_at = created_at if created_at != OMIT
735
+ @modified_at = modified_at if modified_at != OMIT
736
+ @account = account if account != OMIT
737
+ @description = description if description != OMIT
738
+ @expense_date = expense_date if expense_date != OMIT
739
+ @amount = amount if amount != OMIT
740
+ @currency = currency if currency != OMIT
741
+ @exchange_rate = exchange_rate if exchange_rate != OMIT
742
+ @is_billable = is_billable if is_billable != OMIT
743
+ @tracking_categories = tracking_categories
744
+ @employee = employee if employee != OMIT
745
+ @project = project if project != OMIT
746
+ @company = company if company != OMIT
747
+ @contact = contact if contact != OMIT
748
+ @quantity = quantity if quantity != OMIT
749
+ @unit_price = unit_price if unit_price != OMIT
750
+ @non_reimbursable = non_reimbursable if non_reimbursable != OMIT
751
+ @tax_amount = tax_amount if tax_amount != OMIT
752
+ @inclusive_of_tax = inclusive_of_tax if inclusive_of_tax != OMIT
753
+ @tax_rate = tax_rate if tax_rate != OMIT
754
+ @remote_was_deleted = remote_was_deleted if remote_was_deleted != OMIT
755
+ @remote_fields = remote_fields if remote_fields != OMIT
756
+ @additional_properties = additional_properties
757
+ @_field_set = {
758
+ "id": id,
759
+ "remote_id": remote_id,
760
+ "created_at": created_at,
761
+ "modified_at": modified_at,
762
+ "account": account,
763
+ "description": description,
764
+ "expense_date": expense_date,
765
+ "amount": amount,
766
+ "currency": currency,
767
+ "exchange_rate": exchange_rate,
768
+ "is_billable": is_billable,
769
+ "tracking_categories": tracking_categories,
770
+ "employee": employee,
771
+ "project": project,
772
+ "company": company,
773
+ "contact": contact,
774
+ "quantity": quantity,
775
+ "unit_price": unit_price,
776
+ "non_reimbursable": non_reimbursable,
777
+ "tax_amount": tax_amount,
778
+ "inclusive_of_tax": inclusive_of_tax,
779
+ "tax_rate": tax_rate,
780
+ "remote_was_deleted": remote_was_deleted,
781
+ "remote_fields": remote_fields
782
+ }.reject do |_k, v|
783
+ v == OMIT
784
+ end
785
+ end
786
+
787
+ # Deserialize a JSON object to an instance of ExpenseReportLine
788
+ #
789
+ # @param json_object [String]
790
+ # @return [Merge::Accounting::ExpenseReportLine]
791
+ def self.from_json(json_object:)
792
+ struct = JSON.parse(json_object, object_class: OpenStruct)
793
+ parsed_json = JSON.parse(json_object)
794
+ id = parsed_json["id"]
795
+ remote_id = parsed_json["remote_id"]
796
+ created_at = (DateTime.parse(parsed_json["created_at"]) unless parsed_json["created_at"].nil?)
797
+ modified_at = (DateTime.parse(parsed_json["modified_at"]) unless parsed_json["modified_at"].nil?)
798
+ if parsed_json["account"].nil?
799
+ account = nil
800
+ else
801
+ account = parsed_json["account"].to_json
802
+ account = Merge::Accounting::ExpenseReportLineAccount.from_json(json_object: account)
803
+ end
804
+ description = parsed_json["description"]
805
+ expense_date = (DateTime.parse(parsed_json["expense_date"]) unless parsed_json["expense_date"].nil?)
806
+ amount = parsed_json["amount"]
807
+ currency = parsed_json["currency"]
808
+ exchange_rate = parsed_json["exchange_rate"]
809
+ is_billable = parsed_json["is_billable"]
810
+ tracking_categories = parsed_json["tracking_categories"]
811
+ if parsed_json["employee"].nil?
812
+ employee = nil
813
+ else
814
+ employee = parsed_json["employee"].to_json
815
+ employee = Merge::Accounting::ExpenseReportLineEmployee.from_json(json_object: employee)
816
+ end
817
+ if parsed_json["project"].nil?
818
+ project = nil
819
+ else
820
+ project = parsed_json["project"].to_json
821
+ project = Merge::Accounting::ExpenseReportLineProject.from_json(json_object: project)
822
+ end
823
+ if parsed_json["company"].nil?
824
+ company = nil
825
+ else
826
+ company = parsed_json["company"].to_json
827
+ company = Merge::Accounting::ExpenseReportLineCompany.from_json(json_object: company)
828
+ end
829
+ if parsed_json["contact"].nil?
830
+ contact = nil
831
+ else
832
+ contact = parsed_json["contact"].to_json
833
+ contact = Merge::Accounting::ExpenseReportLineContact.from_json(json_object: contact)
834
+ end
835
+ quantity = parsed_json["quantity"]
836
+ unit_price = parsed_json["unit_price"]
837
+ non_reimbursable = parsed_json["non_reimbursable"]
838
+ tax_amount = parsed_json["tax_amount"]
839
+ inclusive_of_tax = parsed_json["inclusive_of_tax"]
840
+ if parsed_json["tax_rate"].nil?
841
+ tax_rate = nil
842
+ else
843
+ tax_rate = parsed_json["tax_rate"].to_json
844
+ tax_rate = Merge::Accounting::ExpenseReportLineTaxRate.from_json(json_object: tax_rate)
845
+ end
846
+ remote_was_deleted = parsed_json["remote_was_deleted"]
847
+ remote_fields = parsed_json["remote_fields"]&.map do |item|
848
+ item = item.to_json
849
+ Merge::Accounting::RemoteField.from_json(json_object: item)
850
+ end
851
+ new(
852
+ id: id,
853
+ remote_id: remote_id,
854
+ created_at: created_at,
855
+ modified_at: modified_at,
856
+ account: account,
857
+ description: description,
858
+ expense_date: expense_date,
859
+ amount: amount,
860
+ currency: currency,
861
+ exchange_rate: exchange_rate,
862
+ is_billable: is_billable,
863
+ tracking_categories: tracking_categories,
864
+ employee: employee,
865
+ project: project,
866
+ company: company,
867
+ contact: contact,
868
+ quantity: quantity,
869
+ unit_price: unit_price,
870
+ non_reimbursable: non_reimbursable,
871
+ tax_amount: tax_amount,
872
+ inclusive_of_tax: inclusive_of_tax,
873
+ tax_rate: tax_rate,
874
+ remote_was_deleted: remote_was_deleted,
875
+ remote_fields: remote_fields,
876
+ additional_properties: struct
877
+ )
878
+ end
879
+
880
+ # Serialize an instance of ExpenseReportLine to a JSON object
881
+ #
882
+ # @return [String]
883
+ def to_json(*_args)
884
+ @_field_set&.to_json
885
+ end
886
+
887
+ # Leveraged for Union-type generation, validate_raw attempts to parse the given
888
+ # hash and check each fields type against the current object's property
889
+ # definitions.
890
+ #
891
+ # @param obj [Object]
892
+ # @return [Void]
893
+ def self.validate_raw(obj:)
894
+ obj.id&.is_a?(String) != false || raise("Passed value for field obj.id is not the expected type, validation failed.")
895
+ obj.remote_id&.is_a?(String) != false || raise("Passed value for field obj.remote_id is not the expected type, validation failed.")
896
+ obj.created_at&.is_a?(DateTime) != false || raise("Passed value for field obj.created_at is not the expected type, validation failed.")
897
+ obj.modified_at&.is_a?(DateTime) != false || raise("Passed value for field obj.modified_at is not the expected type, validation failed.")
898
+ obj.account.nil? || Merge::Accounting::ExpenseReportLineAccount.validate_raw(obj: obj.account)
899
+ obj.description&.is_a?(String) != false || raise("Passed value for field obj.description is not the expected type, validation failed.")
900
+ obj.expense_date&.is_a?(DateTime) != false || raise("Passed value for field obj.expense_date is not the expected type, validation failed.")
901
+ obj.amount&.is_a?(Float) != false || raise("Passed value for field obj.amount is not the expected type, validation failed.")
902
+ obj.currency&.is_a?(Merge::Accounting::TransactionCurrencyEnum) != false || raise("Passed value for field obj.currency is not the expected type, validation failed.")
903
+ obj.exchange_rate&.is_a?(String) != false || raise("Passed value for field obj.exchange_rate is not the expected type, validation failed.")
904
+ obj.is_billable&.is_a?(Boolean) != false || raise("Passed value for field obj.is_billable is not the expected type, validation failed.")
905
+ obj.tracking_categories.is_a?(Array) != false || raise("Passed value for field obj.tracking_categories is not the expected type, validation failed.")
906
+ obj.employee.nil? || Merge::Accounting::ExpenseReportLineEmployee.validate_raw(obj: obj.employee)
907
+ obj.project.nil? || Merge::Accounting::ExpenseReportLineProject.validate_raw(obj: obj.project)
908
+ obj.company.nil? || Merge::Accounting::ExpenseReportLineCompany.validate_raw(obj: obj.company)
909
+ obj.contact.nil? || Merge::Accounting::ExpenseReportLineContact.validate_raw(obj: obj.contact)
910
+ obj.quantity&.is_a?(Float) != false || raise("Passed value for field obj.quantity is not the expected type, validation failed.")
911
+ obj.unit_price&.is_a?(Float) != false || raise("Passed value for field obj.unit_price is not the expected type, validation failed.")
912
+ obj.non_reimbursable&.is_a?(Boolean) != false || raise("Passed value for field obj.non_reimbursable is not the expected type, validation failed.")
913
+ obj.tax_amount&.is_a?(Float) != false || raise("Passed value for field obj.tax_amount is not the expected type, validation failed.")
914
+ obj.inclusive_of_tax&.is_a?(Boolean) != false || raise("Passed value for field obj.inclusive_of_tax is not the expected type, validation failed.")
915
+ obj.tax_rate.nil? || Merge::Accounting::ExpenseReportLineTaxRate.validate_raw(obj: obj.tax_rate)
916
+ obj.remote_was_deleted&.is_a?(Boolean) != false || raise("Passed value for field obj.remote_was_deleted is not the expected type, validation failed.")
917
+ obj.remote_fields&.is_a?(Array) != false || raise("Passed value for field obj.remote_fields is not the expected type, validation failed.")
918
+ end
919
+ end
920
+ end
921
+ end