hdo-storting-importer 0.3.8 → 0.4.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 (46) hide show
  1. checksums.yaml +4 -4
  2. data/features/convert.feature +19 -19
  3. data/lib/hdo/storting_importer/category.rb +6 -6
  4. data/lib/hdo/storting_importer/committee.rb +4 -4
  5. data/lib/hdo/storting_importer/committee_membership.rb +7 -7
  6. data/lib/hdo/storting_importer/district.rb +4 -4
  7. data/lib/hdo/storting_importer/governing_period.rb +4 -4
  8. data/lib/hdo/storting_importer/parliament_issue.rb +6 -6
  9. data/lib/hdo/storting_importer/parliament_period.rb +6 -6
  10. data/lib/hdo/storting_importer/parliament_session.rb +7 -7
  11. data/lib/hdo/storting_importer/party.rb +6 -6
  12. data/lib/hdo/storting_importer/party_membership.rb +6 -6
  13. data/lib/hdo/storting_importer/promise.rb +10 -10
  14. data/lib/hdo/storting_importer/proposition.rb +9 -9
  15. data/lib/hdo/storting_importer/representative.rb +21 -21
  16. data/lib/hdo/storting_importer/schema/category.json +2 -2
  17. data/lib/hdo/storting_importer/schema/committee.json +1 -1
  18. data/lib/hdo/storting_importer/schema/committee_membership.json +6 -6
  19. data/lib/hdo/storting_importer/schema/district.json +1 -1
  20. data/lib/hdo/storting_importer/schema/governing_period.json +5 -5
  21. data/lib/hdo/storting_importer/schema/parliament_issue.json +6 -6
  22. data/lib/hdo/storting_importer/schema/parliament_period.json +5 -5
  23. data/lib/hdo/storting_importer/schema/parliament_session.json +5 -5
  24. data/lib/hdo/storting_importer/schema/party.json +4 -4
  25. data/lib/hdo/storting_importer/schema/party_membership.json +6 -6
  26. data/lib/hdo/storting_importer/schema/promise.json +1 -1
  27. data/lib/hdo/storting_importer/schema/proposition.json +3 -3
  28. data/lib/hdo/storting_importer/schema/representative.json +9 -9
  29. data/lib/hdo/storting_importer/schema/vote.json +4 -4
  30. data/lib/hdo/storting_importer/version.rb +1 -1
  31. data/lib/hdo/storting_importer/vote.rb +15 -15
  32. data/lib/hdo/storting_importer.rb +0 -2
  33. data/spec/hdo/storting_importer/category_spec.rb +3 -3
  34. data/spec/hdo/storting_importer/committee_membership_spec.rb +7 -7
  35. data/spec/hdo/storting_importer/committee_spec.rb +1 -1
  36. data/spec/hdo/storting_importer/district_spec.rb +1 -1
  37. data/spec/hdo/storting_importer/governing_period_spec.rb +3 -3
  38. data/spec/hdo/storting_importer/parliament_issue_spec.rb +4 -4
  39. data/spec/hdo/storting_importer/parliament_period_spec.rb +5 -5
  40. data/spec/hdo/storting_importer/parliament_session_spec.rb +5 -5
  41. data/spec/hdo/storting_importer/party_membership_spec.rb +6 -6
  42. data/spec/hdo/storting_importer/party_spec.rb +5 -5
  43. data/spec/hdo/storting_importer/promise_spec.rb +1 -1
  44. data/spec/hdo/storting_importer/representative_spec.rb +16 -16
  45. data/spec/hdo/storting_importer/vote_spec.rb +21 -21
  46. metadata +3 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5af832dfe75f36ebe57837c1765372a3006db7ce
4
- data.tar.gz: 188fc6fa520a69fa71e3fc062bcfdc35942e8dc8
3
+ metadata.gz: caec1b7f38dd610a7482f789ef4957f3d94e00c7
4
+ data.tar.gz: f4e44a467ad3c43852b15f2a691c6d2f0300898a
5
5
  SHA512:
6
- metadata.gz: 9f0014cc7fc871d881a6bd035d346a340cc475dc856e93690f925726f365041943072f9e01fd49e1a2f0a4e774b9f16fe008e47aae0f4006c09f0125e1074163
7
- data.tar.gz: c05a862e059dfa37ac2e6d7a2b95b144e156429c17427d850877ede306996b56c680adefec25e93cfb952c912d398941c6e1c9e2cf4541ad41a9ad506748f256
6
+ metadata.gz: c2d4698c08db85f21d58a8986e477f5478caaa1582ec2f057d4f6788950ab1181d00c6f5a78cdb54ab6be3e94361431541629ee133f04f8afd636e29f0a9ac6f
7
+ data.tar.gz: c59796448cefa43002fc12efc881aaae4e8e6e889c41c003cb8e7a54a7e4374f68ce552bc4018b33f3500546c9e9e279027fff9d3f44d7a75606172e5f2fc6af
@@ -110,97 +110,97 @@ Feature: Import data
110
110
  [
111
111
  {
112
112
  "kind": "hdo#district",
113
- "externalId": "AA",
113
+ "external_id": "AA",
114
114
  "name": "Aust-Agder"
115
115
  },
116
116
  {
117
117
  "kind": "hdo#district",
118
- "externalId": "VA",
118
+ "external_id": "VA",
119
119
  "name": "Vest-Agder"
120
120
  },
121
121
  {
122
122
  "kind": "hdo#district",
123
- "externalId": "Ak",
123
+ "external_id": "Ak",
124
124
  "name": "Akershus"
125
125
  },
126
126
  {
127
127
  "kind": "hdo#district",
128
- "externalId": "Bu",
128
+ "external_id": "Bu",
129
129
  "name": "Buskerud"
130
130
  },
131
131
  {
132
132
  "kind": "hdo#district",
133
- "externalId": "Fi",
133
+ "external_id": "Fi",
134
134
  "name": "Finnmark"
135
135
  },
136
136
  {
137
137
  "kind": "hdo#district",
138
- "externalId": "He",
138
+ "external_id": "He",
139
139
  "name": "Hedmark"
140
140
  },
141
141
  {
142
142
  "kind": "hdo#district",
143
- "externalId": "Ho",
143
+ "external_id": "Ho",
144
144
  "name": "Hordaland"
145
145
  },
146
146
  {
147
147
  "kind": "hdo#district",
148
- "externalId": "MR",
148
+ "external_id": "MR",
149
149
  "name": "Møre og Romsdal"
150
150
  },
151
151
  {
152
152
  "kind": "hdo#district",
153
- "externalId": "No",
153
+ "external_id": "No",
154
154
  "name": "Nordland"
155
155
  },
156
156
  {
157
157
  "kind": "hdo#district",
158
- "externalId": "Op",
158
+ "external_id": "Op",
159
159
  "name": "Oppland"
160
160
  },
161
161
  {
162
162
  "kind": "hdo#district",
163
- "externalId": "Os",
163
+ "external_id": "Os",
164
164
  "name": "Oslo"
165
165
  },
166
166
  {
167
167
  "kind": "hdo#district",
168
- "externalId": "Ro",
168
+ "external_id": "Ro",
169
169
  "name": "Rogaland"
170
170
  },
171
171
  {
172
172
  "kind": "hdo#district",
173
- "externalId": "SF",
173
+ "external_id": "SF",
174
174
  "name": "Sogn og Fjordane"
175
175
  },
176
176
  {
177
177
  "kind": "hdo#district",
178
- "externalId": "Te",
178
+ "external_id": "Te",
179
179
  "name": "Telemark"
180
180
  },
181
181
  {
182
182
  "kind": "hdo#district",
183
- "externalId": "Tr",
183
+ "external_id": "Tr",
184
184
  "name": "Troms"
185
185
  },
186
186
  {
187
187
  "kind": "hdo#district",
188
- "externalId": "NT",
188
+ "external_id": "NT",
189
189
  "name": "Nord-Trøndelag"
190
190
  },
191
191
  {
192
192
  "kind": "hdo#district",
193
- "externalId": "ST",
193
+ "external_id": "ST",
194
194
  "name": "Sør-Trøndelag"
195
195
  },
196
196
  {
197
197
  "kind": "hdo#district",
198
- "externalId": "Ve",
198
+ "external_id": "Ve",
199
199
  "name": "Vestfold"
200
200
  },
201
201
  {
202
202
  "kind": "hdo#district",
203
- "externalId": "Øs",
203
+ "external_id": "Øs",
204
204
  "name": "Østfold"
205
205
  }
206
206
  ]
@@ -49,8 +49,8 @@ module Hdo
49
49
  end
50
50
 
51
51
  def self.from_hash(data)
52
- obj = new data['externalId'], data['name']
53
- obj.children = Array(data['subCategories']).map { |e| from_hash(e) }
52
+ obj = new data['external_id'], data['name']
53
+ obj.children = Array(data['sub_categories']).map { |e| from_hash(e) }
54
54
 
55
55
  obj
56
56
  end
@@ -67,12 +67,12 @@ module Hdo
67
67
 
68
68
  def to_hash
69
69
  h = {
70
- 'kind' => self.class.kind,
71
- 'externalId' => @external_id,
72
- 'name' => @name
70
+ 'kind' => self.class.kind,
71
+ 'external_id' => @external_id,
72
+ 'name' => @name
73
73
  }
74
74
 
75
- h['subCategories'] = @children.map { |e| e.to_hash } if @children.any?
75
+ h['sub_categories'] = @children.map { |e| e.to_hash } if @children.any?
76
76
 
77
77
  h
78
78
  end
@@ -31,7 +31,7 @@ module Hdo
31
31
  end
32
32
 
33
33
  def self.from_hash(hash)
34
- new hash['externalId'], hash['name']
34
+ new hash['external_id'], hash['name']
35
35
  end
36
36
 
37
37
  def initialize(external_id, name)
@@ -41,9 +41,9 @@ module Hdo
41
41
 
42
42
  def to_hash
43
43
  {
44
- 'kind' => self.class.kind,
45
- 'externalId' => @external_id,
46
- 'name' => @name
44
+ 'kind' => self.class.kind,
45
+ 'external_id' => @external_id,
46
+ 'name' => @name
47
47
  }
48
48
  end
49
49
 
@@ -20,9 +20,9 @@ module Hdo
20
20
  def self.from_hash(hash)
21
21
  binding.pry unless Hash === hash
22
22
 
23
- new hash['externalId'],
24
- (Date.parse(hash['startDate']) if hash['startDate']),
25
- (Date.parse(hash['endDate']) if hash['endDate'])
23
+ new hash['external_id'],
24
+ (Date.parse(hash['start_date']) if hash['start_date']),
25
+ (Date.parse(hash['end_date']) if hash['end_date'])
26
26
  end
27
27
 
28
28
  attr_reader :external_id, :start_date, :end_date
@@ -35,10 +35,10 @@ module Hdo
35
35
 
36
36
  def to_hash
37
37
  {
38
- 'kind' => self.class.kind,
39
- 'externalId' => external_id,
40
- 'startDate' => (start_date.strftime("%Y-%m-%d") if start_date),
41
- 'endDate' => (end_date.strftime("%Y-%m-%d") if end_date)
38
+ 'kind' => self.class.kind,
39
+ 'external_id' => external_id,
40
+ 'start_date' => (start_date.strftime("%Y-%m-%d") if start_date),
41
+ 'end_date' => (end_date.strftime("%Y-%m-%d") if end_date)
42
42
  }
43
43
  end
44
44
 
@@ -31,7 +31,7 @@ module Hdo
31
31
  end
32
32
 
33
33
  def self.from_hash(hash)
34
- new hash['externalId'], hash['name']
34
+ new hash['external_id'], hash['name']
35
35
  end
36
36
 
37
37
  def initialize(external_id, name)
@@ -41,9 +41,9 @@ module Hdo
41
41
 
42
42
  def to_hash
43
43
  {
44
- 'kind' => self.class.kind,
45
- 'externalId' => @external_id,
46
- 'name' => @name
44
+ 'kind' => self.class.kind,
45
+ 'external_id' => @external_id,
46
+ 'name' => @name
47
47
  }
48
48
  end
49
49
 
@@ -32,7 +32,7 @@ module Hdo
32
32
  end
33
33
 
34
34
  def self.from_hash(hash)
35
- new hash['startDate'], hash['endDate']
35
+ new hash['start_date'], hash['end_date']
36
36
  end
37
37
 
38
38
  def initialize(start_date, end_date = nil)
@@ -42,9 +42,9 @@ module Hdo
42
42
 
43
43
  def to_hash
44
44
  {
45
- 'kind' => self.class.kind,
46
- 'startDate' => @start_date && @start_date.iso8601,
47
- 'endDate' => @end_date && @end_date.iso8601
45
+ 'kind' => self.class.kind,
46
+ 'start_date' => @start_date && @start_date.iso8601,
47
+ 'end_date' => @end_date && @end_date.iso8601
48
48
  }
49
49
  end
50
50
 
@@ -67,14 +67,14 @@ module Hdo
67
67
  end
68
68
 
69
69
  def self.from_hash(hash)
70
- new hash['externalId'],
70
+ new hash['external_id'],
71
71
  hash['summary'],
72
72
  hash['description'],
73
73
  hash['type'],
74
74
  hash['status'],
75
- hash['lastUpdate'],
75
+ hash['last_update'],
76
76
  hash['reference'],
77
- hash['documentGroup'],
77
+ hash['document_group'],
78
78
  hash['committee'],
79
79
  hash['categories']
80
80
  end
@@ -100,14 +100,14 @@ module Hdo
100
100
  def to_hash
101
101
  {
102
102
  'kind' => self.class.kind,
103
- 'externalId' => @external_id,
103
+ 'external_id' => @external_id,
104
104
  'summary' => @summary,
105
105
  'description' => @description,
106
106
  'type' => @type,
107
107
  'status' => @status,
108
- 'lastUpdate' => @last_update,
108
+ 'last_update' => @last_update,
109
109
  'reference' => @reference,
110
- 'documentGroup' => @document_group,
110
+ 'document_group' => @document_group,
111
111
  'committee' => @committee,
112
112
  'categories' => @categories
113
113
  }
@@ -23,9 +23,9 @@ module Hdo
23
23
  end
24
24
 
25
25
  def self.from_hash(hash)
26
- new hash['externalId'],
27
- hash['startDate'] && Date.parse(hash['startDate']),
28
- hash['endDate'] && Date.parse(hash['endDate'])
26
+ new hash['external_id'],
27
+ hash['start_date'] && Date.parse(hash['start_date']),
28
+ hash['end_date'] && Date.parse(hash['end_date'])
29
29
  end
30
30
 
31
31
  def self.example(overrides = nil)
@@ -47,9 +47,9 @@ module Hdo
47
47
  def to_hash
48
48
  {
49
49
  'kind' => self.class.kind,
50
- 'externalId' => @external_id,
51
- 'startDate' => @start_date && @start_date.iso8601,
52
- 'endDate' => @end_date && @end_date.iso8601
50
+ 'external_id' => @external_id,
51
+ 'start_date' => @start_date && @start_date.iso8601,
52
+ 'end_date' => @end_date && @end_date.iso8601
53
53
  }
54
54
  end
55
55
 
@@ -23,9 +23,9 @@ module Hdo
23
23
  end
24
24
 
25
25
  def self.from_hash(hash)
26
- new hash['externalId'],
27
- hash['startDate'] && Date.parse(hash['startDate']),
28
- hash['endDate'] && Date.parse(hash['endDate'])
26
+ new hash['external_id'],
27
+ hash['start_date'] && Date.parse(hash['start_date']),
28
+ hash['end_date'] && Date.parse(hash['end_date'])
29
29
  end
30
30
 
31
31
  def self.example(overrides = nil)
@@ -46,10 +46,10 @@ module Hdo
46
46
 
47
47
  def to_hash
48
48
  {
49
- 'kind' => self.class.kind,
50
- 'externalId' => @external_id,
51
- 'startDate' => @start_date && @start_date.iso8601,
52
- 'endDate' => @end_date && @end_date.iso8601
49
+ 'kind' => self.class.kind,
50
+ 'external_id' => @external_id,
51
+ 'start_date' => @start_date && @start_date.iso8601,
52
+ 'end_date' => @end_date && @end_date.iso8601
53
53
  }
54
54
  end
55
55
 
@@ -33,10 +33,10 @@ module Hdo
33
33
  end
34
34
 
35
35
  def self.from_hash(hash)
36
- obj = new hash['externalId'],
36
+ obj = new hash['external_id'],
37
37
  hash['name']
38
38
 
39
- obj.governing_periods = Array(hash['governingPeriods']).map do |gp|
39
+ obj.governing_periods = Array(hash['governing_periods']).map do |gp|
40
40
  GoverningPeriod.from_hash gp
41
41
  end
42
42
 
@@ -55,13 +55,13 @@ module Hdo
55
55
 
56
56
  def to_hash
57
57
  h = {
58
- 'kind' => self.class.kind,
59
- 'externalId' => @external_id,
60
- 'name' => @name,
58
+ 'kind' => self.class.kind,
59
+ 'external_id' => @external_id,
60
+ 'name' => @name,
61
61
  }
62
62
 
63
63
  if @governing_periods
64
- h['governingPeriods'] = @governing_periods.map { |e| e.to_hash }
64
+ h['governing_periods'] = @governing_periods.map { |e| e.to_hash }
65
65
  end
66
66
 
67
67
  h
@@ -18,9 +18,9 @@ module Hdo
18
18
  end
19
19
 
20
20
  def self.from_hash(hash)
21
- new hash['externalId'],
22
- (Date.parse(hash['startDate']) if hash['startDate']),
23
- (Date.parse(hash['endDate']) if hash['endDate'])
21
+ new hash['external_id'],
22
+ (Date.parse(hash['start_date']) if hash['start_date']),
23
+ (Date.parse(hash['end_date']) if hash['end_date'])
24
24
  end
25
25
 
26
26
  attr_reader :external_id, :start_date, :end_date
@@ -34,9 +34,9 @@ module Hdo
34
34
  def to_hash
35
35
  {
36
36
  'kind' => self.class.kind,
37
- 'externalId' => external_id,
38
- 'startDate' => (start_date.strftime("%Y-%m-%d") if start_date),
39
- 'endDate' => (end_date.strftime("%Y-%m-%d") if end_date)
37
+ 'external_id' => external_id,
38
+ 'start_date' => (start_date.strftime("%Y-%m-%d") if start_date),
39
+ 'end_date' => (end_date.strftime("%Y-%m-%d") if end_date)
40
40
  }
41
41
  end
42
42
 
@@ -125,7 +125,7 @@ module Hdo
125
125
  end
126
126
 
127
127
  def self.from_hash(hash)
128
- pr = new hash['externalId'],
128
+ pr = new hash['external_id'],
129
129
  hash['parties'],
130
130
  hash['body'],
131
131
  hash['general'],
@@ -150,15 +150,15 @@ module Hdo
150
150
 
151
151
  def to_hash
152
152
  {
153
- 'kind' => self.class.kind,
154
- 'externalId' => @external_id,
155
- 'parties' => @parties,
156
- 'general' => @general,
157
- 'categories' => @categories,
158
- 'source' => @source,
159
- 'page' => @page,
160
- 'body' => @body,
161
- 'period' => @period
153
+ 'kind' => self.class.kind,
154
+ 'external_id' => @external_id,
155
+ 'parties' => @parties,
156
+ 'general' => @general,
157
+ 'categories' => @categories,
158
+ 'source' => @source,
159
+ 'page' => @page,
160
+ 'body' => @body,
161
+ 'period' => @period
162
162
  }
163
163
  end
164
164
 
@@ -25,11 +25,11 @@ module Hdo
25
25
 
26
26
  def self.from_hash(hash)
27
27
  arr = [
28
- hash['externalId'],
28
+ hash['external_id'],
29
29
  hash['description'],
30
- hash['onBehalfOf'],
30
+ hash['on_behalf_of'],
31
31
  hash['body'],
32
- hash['deliveredBy'] && Representative.from_hash(hash['deliveredBy']),
32
+ hash['delivered_by'] && Representative.from_hash(hash['delivered_by']),
33
33
  ]
34
34
 
35
35
  new(*arr)
@@ -67,14 +67,14 @@ module Hdo
67
67
 
68
68
  def to_hash
69
69
  h = {
70
- 'kind' => self.class.kind,
71
- 'externalId' => @external_id,
72
- 'description' => @description,
73
- 'onBehalfOf' => @on_behalf_of,
74
- 'body' => @body
70
+ 'kind' => self.class.kind,
71
+ 'external_id' => @external_id,
72
+ 'description' => @description,
73
+ 'on_behalf_of' => @on_behalf_of,
74
+ 'body' => @body
75
75
  }
76
76
 
77
- h['deliveredBy'] = @delivered_by.to_hash if @delivered_by
77
+ h['delivered_by'] = @delivered_by.to_hash if @delivered_by
78
78
 
79
79
  h
80
80
  end
@@ -23,8 +23,8 @@ module Hdo
23
23
  '1975-07-07T00:00:00',
24
24
  '0001-01-01T00:00:00',
25
25
  'Akershus',
26
- [PartyMembership.from_hash("externalId" => 'H', 'startDate' => '2011-10-01', 'endDate' => nil)],
27
- [CommitteeMembership.from_hash('externalId' => 'JUSTIS', 'startDate' => '2011-10-01', 'endDate' => nil)]
26
+ [PartyMembership.from_hash("external_id" => 'H', 'start_date' => '2011-10-01', 'end_date' => nil)],
27
+ [CommitteeMembership.from_hash('external_id' => 'JUSTIS', 'start_date' => '2011-10-01', 'end_date' => nil)]
28
28
  )
29
29
 
30
30
  if overrides
@@ -85,18 +85,18 @@ module Hdo
85
85
  end
86
86
 
87
87
  def self.from_hash(hash)
88
- v = new hash['externalId'],
89
- hash['firstName'],
90
- hash['lastName'],
88
+ v = new hash['external_id'],
89
+ hash['first_name'],
90
+ hash['last_name'],
91
91
  hash['gender'],
92
- hash['dateOfBirth'],
93
- hash['dateOfDeath'],
92
+ hash['date_of_birth'],
93
+ hash['date_of_death'],
94
94
  hash['district'],
95
95
  Array(hash['parties']).map { |e| PartyMembership.from_hash(e) },
96
96
  Array(hash['committees']).map { |e| CommitteeMembership.from_hash(e) }
97
97
 
98
- v.vote_result = hash['voteResult']
99
- v.permanent_substitute_for = hash['permanentSubstituteFor']
98
+ v.vote_result = hash['vote_result']
99
+ v.permanent_substitute_for = hash['permanent_substitute_for']
100
100
 
101
101
  v
102
102
  end
@@ -126,20 +126,20 @@ module Hdo
126
126
 
127
127
  def to_hash
128
128
  h = {
129
- 'kind' => self.class.kind,
130
- 'externalId' => @external_id,
131
- 'firstName' => @first_name,
132
- 'lastName' => @last_name,
133
- 'gender' => @gender,
134
- 'dateOfBirth' => @date_of_birth,
135
- 'dateOfDeath' => @date_of_death,
136
- 'district' => @district,
137
- 'parties' => @parties.map { |e| e.to_hash },
138
- 'committees' => @committees.map { |e| e.to_hash }
129
+ 'kind' => self.class.kind,
130
+ 'external_id' => @external_id,
131
+ 'first_name' => @first_name,
132
+ 'last_name' => @last_name,
133
+ 'gender' => @gender,
134
+ 'date_of_birth' => @date_of_birth,
135
+ 'date_of_death' => @date_of_death,
136
+ 'district' => @district,
137
+ 'parties' => @parties.map { |e| e.to_hash },
138
+ 'committees' => @committees.map { |e| e.to_hash }
139
139
  }
140
140
 
141
- h['voteResult'] = @vote_result if @vote_result
142
- h['permanentSubstituteFor'] = @permanent_substitute_for if @permanent_substitute_for
141
+ h['vote_result'] = @vote_result if @vote_result
142
+ h['permanent_substitute_for'] = @permanent_substitute_for if @permanent_substitute_for
143
143
 
144
144
  h
145
145
  end
@@ -9,7 +9,7 @@
9
9
  "default": "hdo#category",
10
10
  "required": true
11
11
  },
12
- "externalId": {
12
+ "external_id": {
13
13
  "type": "string",
14
14
  "description": "A unique identifier for the category.",
15
15
  "required": true
@@ -19,7 +19,7 @@
19
19
  "type": "string",
20
20
  "required": true
21
21
  },
22
- "subCategories": {
22
+ "sub_categories": {
23
23
  "description": "A list of subcategories.",
24
24
  "type":"array",
25
25
  "items":{
@@ -9,7 +9,7 @@
9
9
  "default": "hdo#committee",
10
10
  "required": true
11
11
  },
12
- "externalId": {
12
+ "external_id": {
13
13
  "type": "string",
14
14
  "description": "A unique identifier for the committee.",
15
15
  "required": true
@@ -1,26 +1,26 @@
1
1
  {
2
- "id": "hdo#committeeMembership",
2
+ "id": "hdo#committee_membership",
3
3
  "description": "a representative's committee associations for the given dates",
4
4
  "type":"object",
5
5
  "properties": {
6
6
  "kind": {
7
7
  "type": "string",
8
- "description": "This is always 'hdo#committeeMembership'",
9
- "default": "hdo#committeeMembership",
8
+ "description": "This is always 'hdo#committee_membership'",
9
+ "default": "hdo#committee_membership",
10
10
  "required": true
11
11
  },
12
- "externalId": {
12
+ "external_id": {
13
13
  "type": "string",
14
14
  "description": "An ID uniquely identifying the committee (matching externalId of hdo#committee)",
15
15
  "required": true
16
16
  },
17
- "startDate": {
17
+ "start_date": {
18
18
  "type": "string",
19
19
  "description": "The date the association started.",
20
20
  "format": "date",
21
21
  "required": true
22
22
  },
23
- "endDate": {
23
+ "end_date": {
24
24
  "type": "string",
25
25
  "description": "The date the association ended. Can be null if the association is current.",
26
26
  "format": "date",
@@ -9,7 +9,7 @@
9
9
  "default": "hdo#district",
10
10
  "required": true
11
11
  },
12
- "externalId": {
12
+ "external_id": {
13
13
  "type": "string",
14
14
  "description": "A unique identifier for the district.",
15
15
  "required": true
@@ -1,21 +1,21 @@
1
1
  {
2
- "id": "hdo#governingPeriod",
2
+ "id": "hdo#governing_period",
3
3
  "description": "a period where a party is in government",
4
4
  "type":"object",
5
5
  "properties": {
6
6
  "kind": {
7
7
  "type": "string",
8
- "description": "This is always 'hdo#governingPeriod'",
9
- "default": "hdo#governingPeriod",
8
+ "description": "This is always 'hdo#governing_period'",
9
+ "default": "hdo#governing_period",
10
10
  "required": true
11
11
  },
12
- "startDate": {
12
+ "start_date": {
13
13
  "type": "string",
14
14
  "description": "The date the period started.",
15
15
  "format": "date",
16
16
  "required": true
17
17
  },
18
- "endDate": {
18
+ "end_date": {
19
19
  "type": "string",
20
20
  "description": "The date the period ended. Can be null if the period is current.",
21
21
  "format": "date",