-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathpinball-map.yaml
1120 lines (1120 loc) · 28.7 KB
/
pinball-map.yaml
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
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.1
info:
title: Pinball Map API
description: An API to fetch data about pinball machine locations, operators, and scores.
version: v1
servers:
- url: https://pinballmap.com/api/v1
tags:
- name: Events
- name: Location machine xrefs
- name: Location types
- name: Locations
- name: Machine score xrefs
- name: Machines
- name: Operators
- name: Regions
- name: Zones
paths:
/region/{region}/events.json:
get:
tags:
- Events
summary: All events
operationId: getEvents
description: Get all events for a single region
parameters:
- name: region
in: path
required: true
schema:
type: string
- name: sorted
in: query
description: If present, sort/group by event category
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
events:
type: array
items:
$ref: '#/components/schemas/Event'
/region/{region}/location_machine_xrefs.json:
get:
tags:
- Location machine xrefs
summary: Machines at locations in a region
description: Get all machines at locations in a single region.
operationId: getRegionLocationMachine
parameters:
- name: region
in: path
required: true
schema:
type: string
- name: limit
in: query
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
location_machine_xrefs:
type: array
items:
$ref: "#/components/schemas/Location_machine_xref"
"404":
description: Not Found
/location_machine_xrefs/{id}.json:
get:
tags:
- Location machine xrefs
summary: Single lmx
description: Get info about a single location machine xref
operationId: GetLmxById
parameters:
- name: id
in: path
required: true
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
location_machine:
$ref: "#/components/schemas/Location_machine_xref"
"404":
description: Not Found
/location_machine_xrefs/top_n_machines.json:
get:
tags:
- Location machine xrefs
summary: Top N machines
description: Show the top N machines
operationId: getTopN
parameters:
- name: n
in: query
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
machines:
type: array
items:
$ref: "#/components/schemas/Machine"
"404":
description: Not Found
/location_types.json:
get:
tags:
- Location types
summary: Location types
description: Fetch all location types
operationId: listLocationTypes
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
location_types:
type: array
items:
$ref: "#/components/schemas/Location_type"
/region/{region}/locations.json:
get:
tags:
- Locations
description: Fetch locations for a single region
summary: Locations for a regions
operationId: getLocationsInRegion
parameters:
- name: region
in: path
required: true
schema:
type: string
- name: by_location_name
in: query
schema:
type: string
- name: by_location_id
in: query
schema:
type: integer
- name: by_machine_id
in: query
schema:
type: integer
- name: by_ipdb_id
in: query
schema:
type: integer
- name: by_opdb_id
in: query
schema:
type: integer
- name: by_machine_name
in: query
schema:
type: string
- name: by_city_id
in: query
schema:
type: string
- name: by_state_id
in: query
schema:
type: string
- name: by_machine_group_id
in: query
schema:
type: string
- name: by_zone_id
in: query
schema:
type: integer
- name: by_operator_id
in: query
schema:
type: integer
- name: by_type_id
in: query
schema:
type: integer
- name: by_at_least_n_machines_type
in: query
description: Only locations with N or more machines
schema:
type: integer
- name: by_is_stern_army
in: query
description: Send only locations labeled as Stern Army
schema:
type: integer
- name: no_details
in: query
description: Omit lmx/condition data from pull
schema:
type: integer
- name: regionless_only
in: query
description: Show only regionless locations
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
locations:
type: array
items:
$ref: "#/components/schemas/Location"
"404":
description: Not Found
/locations/closest_by_lat_lon.json:
get:
tags:
- Locations
description: Returns the closest location to transmitted lat/lon
summary: Closest to lat/lon
operationId: getLocationNearby
parameters:
- name: lat
in: query
required: true
schema:
type: string
- name: lon
in: query
required: true
schema:
type: string
- name: by_type_id
in: query
schema:
type: integer
- name: by_machine_id
in: query
schema:
type: integer
- name: by_operator_id
in: query
schema:
type: integer
- name: by_at_least_n_machines_type
in: query
description: Only locations with N or more machines
schema:
type: integer
- name: max_distance
in: query
description: "Closest location within 'max_distance' miles, with a max of 500"
schema:
type: string
- name: no_details
in: query
description: Omit data that app does not need from pull
schema:
type: integer
- name: send_all_within_distance
in: query
description: Send all locations within max_distance param, or 50 miles.
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
location:
type: array
items:
$ref: "#/components/schemas/Location"
"404":
description: Not Found
/locations/within_bounding_box.json:
get:
tags:
- Locations
summary: Locations in box
description: Returns locations within transmitted bounding box
operationId: getLocationsInBox
parameters:
- name: swlat
in: query
required: true
schema:
type: string
- name: swlon
in: query
required: true
schema:
type: string
- name: nelat
in: query
required: true
schema:
type: string
- name: nelon
in: query
required: true
schema:
type: string
- name: by_type_id
in: query
schema:
type: integer
- name: by_machine_id
in: query
schema:
type: integer
- name: by_operator_id
in: query
schema:
type: integer
- name: by_at_least_n_machines_type
in: query
description: Only locations with N or more machines
schema:
type: integer
- name: no_details
in: query
description: Omit data that app does not need from pull
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
locations:
type: array
items:
$ref: "#/components/schemas/Location"
"404":
description: Not Found
/locations/{id}.json:
get:
tags:
- Locations
summary: Single location
description: Get location by id
operationId: getLocationById
parameters:
- name: id
in: path
required: true
schema:
type: integer
- name: no_details
in: query
description: Omit lmx/condition data
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
$ref: "#/components/schemas/Location"
"404":
description: Not Found
/locations/{id}/machine_details.json:
get:
tags:
- Locations
summary: Machine details at location
description: Display the details of the machines at this location
operationId: getMachineDetails
parameters:
- name: id
in: path
required: true
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
machines:
type: array
items:
$ref: "#/components/schemas/Machine"
"404":
description: Not Found
/locations/top_cities.json:
get:
tags:
- Locations
summary: Top cities by number of locations
description: Fetch top 10 cities by number of locations
operationId: listTopCitiesLocations
responses:
"200":
description: Success
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/City"
/locations/top_cities_by_machine.json:
get:
tags:
- Locations
summary: Top cities by number of machines
description: Fetch top 10 cities by number of machines
operationId: listTopCitiesMachines
responses:
"200":
description: Success
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/City"
/locations/type_count.json:
get:
tags:
- Locations
summary: Count location types
description: Fetch a count of each location type
operationId: getTypeCounts
responses:
"200":
description: Success
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/Type_count"
/region/{region}/machine_score_xrefs.json:
get:
tags:
- Machine score xrefs
summary: Region high scores
description: Fetch all high scores for a region
operationId: getRegionHighScores
parameters:
- name: region
in: path
required: true
schema:
type: string
- name: zone_id
in: query
schema:
type: integer
- name: limit
in: query
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
machine_score_xrefs:
type: array
items:
$ref: "#/components/schemas/Machine_score_xref"
/machine_score_xrefs/{id}.json:
get:
tags:
- Machine score xrefs
summary: High scores for a location's machine
description: View all high scores for a location's machine
operationId: getMachineHighScores
parameters:
- name: id
in: path
required: true
description: The location machine ID, NOT the machine score ID
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
/machines.json:
get:
tags:
- Machines
summary: All machines
description: Fetch all machines
operationId: getAllMachines
parameters:
- name: no_details
in: query
description: Omit unnecessary metadata for initial app loading
schema:
type: integer
- name: region_id
in: query
schema:
type: integer
- name: manufacturer
in: query
description: show only machines from this manufacturer
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
machines:
type: array
items:
$ref: '#/components/schemas/Machine'
/operators.json:
get:
tags:
- Operators
summary: All operators
description: Fetch all operators for all regions
operationId: listOperators
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
operators:
type: array
items:
$ref: '#/components/schemas/Operator'
/region/{region}/operators.json:
get:
tags:
- Operators
summary: All operators in region
description: Fetch all operators in a certain region
operationId: listOperatorsInRegion
parameters:
- name: region
in: path
required: true
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
operators:
type: array
items:
$ref: '#/components/schemas/Operator'
/regions/location_and_machine_counts.json:
get:
tags:
- Regions
summary: Location and machine counts
description: Get location and machine counts
operationId: listMachineCounts
parameters:
- name: region_name
in: query
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
num_locations:
type: integer
example: 8778
num_lmxes:
type: integer
example: 35493
/regions/closest_by_lat_lon.json:
get:
tags:
- Regions
summary: Nearest region
description: Find closest region based on lat/lon
operationId: findNearestRegion
parameters:
- name: lat
in: query
required: true
schema:
type: string
- name: lon
in: query
required: true
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
region:
$ref: '#/components/schemas/Region'
/regions.json:
get:
tags:
- Regions
summary: All regions
description: Fetch all regions
operationId: listRegions
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
regions:
type: array
items:
$ref: '#/components/schemas/Region'
/regions/{id}.json:
get:
tags:
- Regions
summary: Single region
description: Fetch information for a single region
operationId: getRegionById
parameters:
- name: id
in: path
required: true
schema:
type: integer
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
regions:
type: array
items:
$ref: '#/components/schemas/Region'
/region/{region}/zones.json:
get:
tags:
- zones
summary: Region zones
description: Fetch zones for a single region
operationId: getZonesInRegion
parameters:
- name: region
in: path
required: true
schema:
type: string
responses:
"200":
description: Success
content:
application/json:
schema:
type: object
properties:
zones:
type: array
items:
$ref: '#/components/schemas/Zone'
components:
schemas:
Event:
type: object
properties:
id:
type: integer
example: 108293
region_id:
type: integer
example: 4
name:
type: string
example: On Tilt Pinball League
long_desc:
type: string
example: On Tilt Pinball League Season 11!!!!\nStandard IFPA Sanctioned Pinball League meeting Bi-Weekly. Lowest Score dropped at end of season.\nMeet dates:\nWeek 1 January 26, 2023\nWeek 2 February 9, 2023\nWeek 3 February 23, 2023\nWeek 4 March 9, 2023\nWeek 5 March 23, 2023\nWeek 6 April 6, 2023\nWeek 7 April ...\n7128 Van Nuys Blvd, Los Angeles, CA,
external_link:
type: string
example: https://fb.me/e/5f1yUqz3R
category_no:
type: string
description: String instead of null
example: null
start_date:
type: string
example: '2023-01-26'
end_date:
type: string
example: '2023-05-18'
location_id:
type: integer
example: null
created_at:
type: string
example: '2022-12-23T16:01:02.082-08:00'
updated_at:
type: string
example: '2022-12-23T16:01:02.082-08:00'
category:
type: string
example: IFPA Sanctioned Events
external_location_name:
type: string
example: null
ifpa_calendar_id:
type: integer
example: 57740
ifpa_tournament_id:
type: integer
example: 57740
Location:
type: object
properties:
id:
type: integer
example: 13527
name:
type: string
example: Dyno Bar (Aero Club)
street:
type: string
example: 3367 India St
city:
type: string
example: San Diego
state:
type: string
example: CA
zip:
type: string
example: '92103'
phone:
type: string
example: (619) 297-7211
lat:
type: string
example: '32.7381229'
lon:
type: string
example: '-117.1765576'
website:
type: string
example: http://www.dynobarsd.com/
created_at:
type: string
example: '2019-11-12T12:04:04.203-08:00'
updated_at:
type: string
example: '2023-05-07T16:57:03.652-07:00'
zone_id:
type: integer
example: 40
region_id:
type: integer
example: 4
location_type_id:
type: integer
example: 3
description:
type: string
example: "Pincraft Pinball is the premier pinball operator in San Diego! To report problems contact [email protected] or 860-287-2137.\r\nAmusement Connect card operated system - game cards/credits are also valid at Club Marina and Harbor Town Pub!"
operator_id:
type: integer
example: 151
date_last_updated:
type: string
example: '2023-05-07'
last_updated_by_user_id:
type: integer
example: 485
is_stern_army:
type: boolean
example: false
country:
type: string
example: US
ic_active:
type: boolean
example: true
Machine:
type: object
properties:
id:
type: integer
example: 3643
name:
type: string
example: James Bond 007 (60th Anniversary)
is_active:
type: boolean
example: false
created_at:
type: string
example: '2022-09-22T16:26:51.146-07:00'
updated_at:
type: string
example: '2023-04-18T20:08:38.946-07:00'
ipdb_link:
type: string
example: null
year:
type: integer
example: 2022
manufacturer:
type: string
example: Stern
machine_group_id:
type: integer
example: null
ipdb_id:
type: integer
example: null
opdb_id:
type: string
example: Ge1Dy-M9Rrp
opdb_img:
type: string
example: null
opdb_img_height:
type: integer
example: null
opdb_img_width:
type: integer
example: null
machine_type:
type: string
example: ss
machine_display:
type: string
example: lcd
ic_eligible:
type: boolean
example: true
Location_machine_xref:
type: object
properties:
id:
type: integer
example: 130078
created_at:
type: string
example: '2023-05-07T16:57:26.948-07:00'
updated_at:
type: string
example: '2023-05-07T16:57:26.948-07:00'
location_id:
type: integer
example: 13527
machine_id:
type: integer
example: 3643
condition:
type: string
example: null
condition_date:
type: string
example: null
ip:
type: string
example: null
user_id:
type: integer
example: 485
machine_score_xrefs_count:
type: integer
example: null
ic_enabled:
type: boolean
example: null
location:
$ref: '#/components/schemas/Location'
machine:
$ref: '#/components/schemas/Machine'
Location_type:
type: object
properties:
id:
type: integer
example: 68
created_at:
type: string
example: '2017-05-31T10:25:59.487-07:00'
updated_at:
type: string
example: '2021-04-18T22:32:53.750-07:00'
name:
type: string
example: Airport
icon:
type: string
example: airport
library:
type: string
example: material-community
City:
type: object
properties:
city:
type: string
example: Portland
state:
type: string
example: OR
location_count:
type: integer
example: 164
id:
type: integer
example: null
Type_count:
type: object
properties:
name:
type: string
example: Bar
type_count:
type: integer
example: 1875
id:
type: integer
example: null
Machine_score_xref:
type: object
properties:
id:
type: integer
example: 12770
location_machine_xref_id:
type: integer
example: 47413