-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjune12exercise.py
954 lines (947 loc) · 39 KB
/
june12exercise.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
import requests
import json
ottawa_wards_response = requests.get(
"https://represent.opennorth.ca/boundaries/?sets=ottawa-wards"
)
ottawa_wards_response.json()
{
"meta": {
"previous": None,
"next": "/boundaries/?sets=ottawa-wards&offset=20&limit=20",
"offset": 0,
"limit": 20,
"related": {
"centroids_url": "/boundaries/centroid?sets=ottawa-wards",
"simple_shapes_url": "/boundaries/simple_shape?sets=ottawa-wards",
"shapes_url": "/boundaries/shape?sets=ottawa-wards",
},
"total_count": 23,
},
"objects": [
{
"name": "Barrhaven",
"external_id": "3",
"url": "/boundaries/ottawa-wards/barrhaven/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "West Carleton-March",
"external_id": "5",
"url": "/boundaries/ottawa-wards/west-carleton-march/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Somerset",
"external_id": "14",
"url": "/boundaries/ottawa-wards/somerset/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Rideau-Goulbourn",
"external_id": "21",
"url": "/boundaries/ottawa-wards/rideau-goulbourn/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Cumberland",
"external_id": "19",
"url": "/boundaries/ottawa-wards/cumberland/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Orléans",
"external_id": "1",
"url": "/boundaries/ottawa-wards/orleans/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Innes",
"external_id": "2",
"url": "/boundaries/ottawa-wards/innes/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Rideau-Rockcliffe",
"external_id": "13",
"url": "/boundaries/ottawa-wards/rideau-rockcliffe/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Rideau-Vanier",
"external_id": "12",
"url": "/boundaries/ottawa-wards/rideau-vanier/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Stittsville",
"external_id": "6",
"url": "/boundaries/ottawa-wards/stittsville/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Alta Vista",
"external_id": "18",
"url": "/boundaries/ottawa-wards/alta-vista/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Gloucester-Southgate",
"external_id": "10",
"url": "/boundaries/ottawa-wards/gloucester-southgate/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Kitchissippi",
"external_id": "15",
"url": "/boundaries/ottawa-wards/kitchissippi/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Capital",
"external_id": "17",
"url": "/boundaries/ottawa-wards/capital/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "River",
"external_id": "16",
"url": "/boundaries/ottawa-wards/river/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Knoxdale-Merivale",
"external_id": "9",
"url": "/boundaries/ottawa-wards/knoxdale-merivale/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Kanata North",
"external_id": "4",
"url": "/boundaries/ottawa-wards/kanata-north/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Gloucester-South Nepean",
"external_id": "22",
"url": "/boundaries/ottawa-wards/gloucester-south-nepean/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "College",
"external_id": "8",
"url": "/boundaries/ottawa-wards/college/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
{
"name": "Beacon Hill-Cyrville",
"external_id": "11",
"url": "/boundaries/ottawa-wards/beacon-hill-cyrville/",
"boundary_set_name": "Ottawa ward",
"related": {"boundary_set_url": "/boundary-sets/ottawa-wards/"},
},
],
}
for object in ottawa_wards_response.json()["objects"]:
print(object["name"])
Barrhaven
West Carleton-March
Somerset
Rideau-Goulbourn
Cumberland
Orléans
Innes
Rideau-Rockcliffe
Rideau-Vanier
Stittsville
Alta Vista
Gloucester-Southgate
Kitchissippi
Capital
River
Knoxdale-Merivale
Kanata North
Gloucester-South Nepean
College
Beacon Hill-Cyrville
hoc_reps_response = requests.get(
"https://represent.opennorth.ca/representatives/house-of-commons/"
)
hoc_reps_response.json()
{
"meta": {
"limit": 20,
"previous": None,
"total_count": 336,
"next": "/representatives/house-of-commons/?limit=20&offset=20",
"offset": 0,
},
"objects": [
{
"gender": "",
"party_name": "Liberal",
"first_name": "Mike",
"offices": [
{
"fax": "1 613 996-8652",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-5321",
"type": "legislature",
},
{
"fax": "1 613 354-0913",
"postal": "20-B Richmond Blvd (Main Office)\n\nNapanee ON K7R 4A4",
"tel": "1 866 471-3800",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35039/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/BossioMike_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Mike-Bossio(88786)",
"personal_url": "http://www.mikebossiomp.ca",
"elected_office": "MP",
"district_name": "Hastings—Lennox and Addington",
"name": "Mike Bossio",
"last_name": "Bossio",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Anita",
"offices": [
{
"fax": "1 613 996-9880",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-0984",
"type": "legislature",
},
{
"fax": "1 613 993-6501",
"postal": "1315 Richmond road (Main Office)\n\nOttawa ON K2B 7Y4",
"tel": "1 613 990-7720",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35079/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/VandenbeldAnita_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Anita-Vandenbeld(71738)",
"personal_url": "http://www.anitamp.ca",
"elected_office": "MP",
"district_name": "Ottawa West—Nepean",
"name": "Anita Vandenbeld",
"last_name": "Vandenbeld",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Robert",
"offices": [
{
"fax": "1 613 996-1759",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-1161",
"type": "legislature",
},
{
"fax": "1 807 468-4896",
"postal": "301 First Avenue S (Main Office)\nSuite 202\nKenora ON P9N 1W2",
"tel": "1 807 468-2170",
"type": "constituency",
},
{
"fax": "1 807 737-1812",
"postal": "53 Front Street\nSuite 1-A\nSioux Lookout ON P8T 1A0",
"tel": "1 807 737-4934",
"type": "constituency",
},
{
"postal": "66 Keith Avenue\nSuite 2\nDryden ON P8N 3K8",
"tel": "1 807 407-4758",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35042/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/NaultRobert_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Robert-D-Nault(709)",
"personal_url": "http://bnault.liberal.ca",
"elected_office": "MP",
"district_name": "Kenora",
"name": "Robert Nault",
"last_name": "Nault",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Peter",
"offices": [
{
"fax": "1 613 952-0874",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 957-3744",
"type": "legislature",
},
{
"fax": "1 450 510-2383",
"postal": "223 St. Charles Avenue (Main Office)\n\nVaudreuil-Dorion QC J7V 2L6",
"tel": "1 450 510-2305",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/24074/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/SchiefkePeter_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Peter-Schiefke(88649)",
"personal_url": "http://pschiefke.liberal.ca/en",
"elected_office": "MP",
"district_name": "Vaudreuil—Soulanges",
"name": "Peter Schiefke",
"last_name": "Schiefke",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Gagan",
"offices": [
{
"fax": "1 613 943-1768",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 943-1762",
"type": "legislature",
},
{
"fax": "1 905 812-8464",
"postal": "6990 Financial Drive (Main Office)\nUnit 8G\nMississauga ON L5N 8J4",
"tel": "1 905 812-1811",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35063/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/SikandGagan_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Gagan-Sikand(88858)",
"personal_url": "http://gsikand.liberal.ca",
"elected_office": "MP",
"district_name": "Mississauga—Streetsville",
"name": "Gagan Sikand",
"last_name": "Sikand",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Conservative",
"first_name": "Larry",
"offices": [
{
"fax": "1 613 952-0979",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-5191",
"type": "legislature",
},
{
"fax": "1 519 371-1752",
"postal": "1131 - 2nd Avenue East (Main Office)\nSuite 208\nOwen Sound ON N4K 2J1",
"tel": "1 519 371-1059",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35014/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/MillerLarry_CPC.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Larry-Miller(25522)",
"personal_url": "http://www.larrymiller.ca",
"elected_office": "MP",
"district_name": "Bruce—Grey—Owen Sound",
"name": "Larry Miller",
"last_name": "Miller",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "People's Party",
"first_name": "Maxime",
"offices": [
{
"fax": "1 613 995-0687",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-8053",
"type": "legislature",
},
{
"fax": "1 418 227-3093",
"postal": "11535 1st Avenue (Main Office)\nSuite 430\nSaint-Georges QC G5Y 7H5",
"tel": "1 418 227-2171",
"type": "constituency",
},
{
"fax": "1 418 387-8124",
"postal": "1068 Vachon Blvd North\nSuite 225\nSainte-Marie QC G6E 1M6",
"tel": "1 418 387-4224",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/24007/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/BernierMaxime_CPC.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Maxime-Bernier(35309)",
"personal_url": "http://maximebernier.ca",
"elected_office": "MP",
"district_name": "Beauce",
"name": "Maxime Bernier",
"last_name": "Bernier",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Rémi",
"offices": [
{
"fax": "1 613 995-5184",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 995-1013",
"type": "legislature",
},
{
"fax": "1 418 562-7655",
"postal": "290 Saint-Jérôme Avenue (Main Office)\n\nMatane QC G4W 3A9",
"tel": "1 418 562-0343",
"type": "constituency",
},
{
"postal": "598 C Perron Blvd\n\nCarleton-sur-Mer QC G0C 1J0",
"tel": "1 418 364-6254",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/24006/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/MasséRémi_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Remi-Masse(88397)",
"personal_url": "",
"elected_office": "MP",
"district_name": "Avignon—La Mitis—Matane—Matapédia",
"name": "Rémi Massé",
"last_name": "Massé",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "NDP",
"first_name": "Brian",
"offices": [
{
"fax": "1 613 992-5397",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-1541",
"type": "legislature",
},
{
"fax": "1 519 255-7913",
"postal": "1398 Ouellette Avenue (Main Office)\nSuite 2\nWindsor ON N8X 1J8",
"tel": "1 519 255-1631",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35117/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/MasseBrian_NDP.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Brian-Masse(9137)",
"personal_url": "http://brianmasse.ca",
"elected_office": "MP",
"district_name": "Windsor West",
"name": "Brian Masse",
"last_name": "Masse",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Steven",
"offices": [
{
"fax": "1 613 992-1037",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-4351",
"type": "legislature",
},
{
"fax": "1 819 561-0005",
"postal": "160 de l'Hôpital Blvd (Main Office)\nSuite 204\nGatineau QC J8T 8J1",
"tel": "1 819 561-5555",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/24027/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/MacKinnonSteven_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Steven-MacKinnon(88468)",
"personal_url": "http://smackinnon.liberal.ca/en",
"elected_office": "MP",
"district_name": "Gatineau",
"name": "Steven MacKinnon",
"last_name": "MacKinnon",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Conservative",
"first_name": "Bob",
"offices": [
{
"fax": "1 613 947-4527",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 947-4524",
"type": "legislature",
},
{
"fax": "1 250 787-1195",
"postal": "9916 - 100th Avenue (Main Office)\n\nFort St. John BC V1J 1Y5",
"tel": "1 250 787-1192",
"type": "constituency",
},
{
"fax": "1 250 561-7983",
"postal": "1520 - 3rd Avenue\n\nPrince George BC V2L 3G4",
"tel": "1 855 767-4567",
"type": "constituency",
},
{
"fax": "1 250 719-6838",
"postal": "10421 - 10th Street\n\nDawson Creek BC V1G 3T4",
"tel": "1 250 719-6848",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/59024/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/ZimmerBob_CPC.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Bob-Zimmer(72035)",
"personal_url": "http://www.bobzimmer.ca",
"elected_office": "MP",
"district_name": "Prince George—Peace River—Northern Rockies",
"name": "Bob Zimmer",
"last_name": "Zimmer",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "NDP",
"first_name": "Linda",
"offices": [
{
"fax": "1 613 995-5342",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 995-7325",
"type": "legislature",
},
{
"fax": "1 780 495-8403",
"postal": "10049 - 81st Avenue (Main Office)\n\nEdmonton AB T6E 1W7",
"tel": "1 780 495-8404",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/48019/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/DuncanLinda_NDP.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Linda-Duncan(35873)",
"personal_url": "http://lindaduncanmp.ca",
"elected_office": "MP",
"district_name": "Edmonton Strathcona",
"name": "Linda Duncan",
"last_name": "Duncan",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Bloc Québécois",
"first_name": "Gabriel",
"offices": [
{
"fax": "1 613 995-2818",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-6910",
"type": "legislature",
},
{
"fax": "1 450 752-1719",
"postal": "436 St-Viateur (Main Office)\n\nJoliette QC J6E 3B2",
"tel": "1 450 752-1940",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/24031/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/SteMarieGabriel_BQ.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Gabriel-Ste-Marie(88485)",
"personal_url": "http://gabrielstemarie.quebec",
"elected_office": "MP",
"district_name": "Joliette",
"name": "Gabriel Ste-Marie",
"last_name": "Ste-Marie",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Adam",
"offices": [
{
"fax": "1 613 992-6301",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-2352",
"type": "legislature",
},
{
"fax": "1 416 533-2236",
"postal": "280 Spadina Avenue (Main Office)\nSuite 307\nToronto ON M5T 2C7",
"tel": "1 416 533-2710",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35101/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/VaughanAdam_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Adam-Vaughan(54434)",
"personal_url": "http://www.adamvaughanmp.ca",
"elected_office": "MP",
"district_name": "Spadina—Fort York",
"name": "Adam Vaughan",
"last_name": "Vaughan",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Bernadette",
"offices": [
{
"fax": "1 613 996-0878",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-0877",
"type": "legislature",
},
{
"fax": "1 902 527-5656",
"postal": "129 Aberdeen Road (Main Office)\nSuite 106\nBridgewater NS B4V 2S7",
"tel": "1 902 527-5655",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/12009/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/JordanBernadette_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Bernadette-Jordan(88340)",
"personal_url": "http://bernadettejordan.ca",
"elected_office": "MP",
"district_name": "South Shore—St. Margarets",
"name": "Bernadette Jordan",
"last_name": "Jordan",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Jim",
"offices": [
{
"fax": "1 613 992-9586",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-9475",
"type": "legislature",
},
{
"fax": "1 204 984-3979",
"postal": "611 Corydon Avenue (Main Office)\nSuite 102\nWinnipeg MB R3L 0P3",
"tel": "1 204 983-1355",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/46014/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/CarrJim_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Jim-Carr(89059)",
"personal_url": "http://www.jimcarrmp.ca",
"elected_office": "MP",
"district_name": "Winnipeg South Centre",
"name": "Jim Carr",
"last_name": "Carr",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "Angelo",
"offices": [
{
"fax": "1 613 992-8556",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-0611",
"type": "legislature",
},
{
"fax": "1 450 661-5623",
"postal": "3131 de la Concorde East (Main Office)\nSuite 300\nLaval QC H7E 4W4",
"tel": "1 450 661-4117",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/24004/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/IaconoAngelo_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Angelo-Iacono(71337)",
"personal_url": "http://aiacono.liberal.ca/en",
"elected_office": "MP",
"district_name": "Alfred-Pellan",
"name": "Angelo Iacono",
"last_name": "Iacono",
"email": "",
},
{
"gender": "",
"party_name": "Conservative",
"first_name": "Diane",
"offices": [
{
"fax": "1 613 996-9749",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-4974",
"type": "legislature",
},
{
"fax": "1 519 426-0003",
"postal": "76 Kent Street South (Main Office)\n\nSimcoe ON N3Y 2Y1",
"tel": "1 866 496-3400",
"type": "constituency",
},
{
"postal": "231 Chestnut Street\n\nDunnville ON N1A 2H2",
"tel": "1 866 496-3400",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35033/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/FinleyDiane_CPC.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Diane-Finley(25501)",
"personal_url": "http://dianefinley.ca",
"elected_office": "MP",
"district_name": "Haldimand—Norfolk",
"name": "Diane Finley",
"last_name": "Finley",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Liberal",
"first_name": "MaryAnn",
"offices": [
{
"fax": "1 613 996-9125",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 992-7148",
"type": "legislature",
},
{
"fax": "1 204 984-6415",
"postal": "1575 Main Street (Main Office)\n\nWinnipeg MB R2W 3W5",
"tel": "1 204 984-6322",
"type": "constituency",
},
{
"postal": "1215 Henderson Hwy\n\nWinnipeg MB R2G 1L8",
"tel": "1 204 984-0382",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/46006/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/MihychukMaryAnn_Lib.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/MaryAnn-Mihychuk(89037)",
"personal_url": "http://mmihychuk.liberal.ca",
"elected_office": "MP",
"district_name": "Kildonan—St. Paul",
"name": "MaryAnn Mihychuk",
"last_name": "Mihychuk",
"email": "[email protected]",
},
{
"gender": "",
"party_name": "Conservative",
"first_name": "Lisa",
"offices": [
{
"fax": "1 613 992-0851",
"postal": "House of Commons\nOttawa ON K1A 0A6",
"tel": "1 613 996-7046",
"type": "legislature",
},
{
"fax": "1 905 693-0704",
"postal": "86 Main Street East (Main Office)\n\nMilton ON L9T 1N3",
"tel": "1 905 693-0166",
"type": "constituency",
},
],
"representative_set_name": "House of Commons",
"extra": {},
"related": {
"representative_set_url": "/representative-sets/house-of-commons/",
"boundary_url": "/boundaries/federal-electoral-districts/35057/",
},
"source_url": "http://www.parl.gc.ca/Parliamentarians/en/members?view=ListAll",
"photo_url": "http://www.ourcommons.ca/Parliamentarians/Images/OfficialMPPhotos/42/RaittLisa_CPC.jpg",
"url": "http://www.parl.gc.ca/Parliamentarians/en/members/Lisa-Raitt(54325)",
"personal_url": "http://lisaraittmp.ca",
"elected_office": "MP",
"district_name": "Milton",
"name": "Lisa Raitt",
"last_name": "Raitt",
"email": "[email protected]",
},
],
}
hoc_reps_response.json().keys()
dict_keys(["meta", "objects"])
for object in hoc_reps_response.json()["objects"]:
print(object["name"])
Mike Bossio
Anita Vandenbeld
Robert Nault
Peter Schiefke
Gagan Sikand
Larry Miller
Maxime Bernier
Rémi Massé
Brian Masse
Steven MacKinnon
Bob Zimmer
Linda Duncan
Gabriel Ste-Marie
Adam Vaughan
Bernadette Jordan
Jim Carr
Angelo Iacono
Diane Finley
MaryAnn Mihychuk
Lisa Raitt