-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathopenapi.yml
1140 lines (1126 loc) · 37.3 KB
/
openapi.yml
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.3
info:
title: PlaceKit API Reference
description: |
[PlaceKit](https://placekit.io) is a worldwide geocoding API providing fast and accurate address autocomplete, store locator, and two-way geocoding for your app.
PlaceKit OpenAPI Specifications ([repository](https://github.com/placekit/api-reference))
termsOfService: https://placekit.io/terms
contact:
name: API Support
email: [email protected]
url: https://api.placekit.co
version: 1.4.0
servers:
- url: https://api.placekit.co
security:
- api_key: []
tags:
- name: Geocoding
description: |
PlaceKit Geocoding API endpoints is composed of two similar endpoints `/search` and `/reverse`.\
API clients are simple wrappers on top of this API.
- name: Live Patching
description: |
PlaceKit Live Patching feature enables users to create a data validation flow to fix data errors or add new addresses to their catalog, chose their validation flow and instantly publish it to their end-users.
A `private` API key is **required** to use Live Patching endpoints.
- name: Keys
description: |
Handle your API keys programmatically.
A `private` API key is required to use Keys endpoints.
paths:
/search:
post:
summary: Search for addresses
description: |
Performs a forward geocoding search.
It will return results around `coordinates` (if provided) and the best matching textual relevance.
**It is highly recommended** to set the `countries` parameter with the country you need results from for the best accuracy and revelance possible.
If your use case allows your users to search in any country, then you should ommit `countries` parameter and let the API defines the user's country by its IP.
To have the best location accuracy, you should set `coordinates` based on your users' position.
operationId: ForwardGeocoding
tags: [ Geocoding ]
requestBody:
description: Request parameters
required: false
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/parameters.query'
- $ref: '#/components/schemas/parameters'
responses:
200:
$ref: '#/components/responses/200'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
451:
$ref: '#/components/responses/451'
x-codeSamples:
- lang: curl
source:
$ref: './code_samples/curl/search.yaml#/source'
- lang: go
source:
$ref: './code_samples/go/search.yaml#/source'
- lang: js
source:
$ref: './code_samples/js/search.yaml#/source'
- lang: python
source:
$ref: './code_samples/python/search.yaml#/source'
- lang: ruby
source:
$ref: './code_samples/ruby/search.yaml#/source'
x-codegen-request-body-name: payload
/reverse:
post:
summary: Reverse geocoding
description: |
Performs a reverse geocoding search.
It will return the closest results around `coordinates`.
If `coordinates` are not provided, it will use the user's IP to approximate its coordinates but results will be less accurate (city level accuracy instead of street level accuracy).
operationId: ReverseGeocoding
tags: [ Geocoding ]
requestBody:
description: Request parameters
required: false
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/parameters'
- $ref: '#/components/schemas/parameters.countryByIP'
responses:
200:
$ref: '#/components/responses/200'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
451:
$ref: '#/components/responses/451'
x-codeSamples:
- lang: curl
source:
$ref: './code_samples/curl/reverse.yaml#/source'
- lang: go
source:
$ref: './code_samples/go/reverse.yaml#/source'
- lang: js
source:
$ref: './code_samples/js/reverse.yaml#/source'
- lang: python
source:
$ref: './code_samples/python/reverse.yaml#/source'
- lang: ruby
source:
$ref: './code_samples/ruby/reverse.yaml#/source'
x-codegen-request-body-name: payload
/patch/search:
post:
summary: List patch records
description: |
Get all patch records associated to the user.
You can refine the results by using the same parameters as the regular `/search` endpoint.
operationId: SearchPatches
tags: [ Live Patching ]
requestBody:
description: Request parameters (optional)
required: false
content:
application/json:
schema:
type: object
allOf:
- $ref: '#/components/schemas/parameters.status'
- $ref: '#/components/schemas/parameters.query'
- $ref: '#/components/schemas/parameters'
- $ref: '#/components/schemas/parameters.offset'
examples:
status:
summary: Filter by status
description: Select all `pending` patch records
value:
status: pending
query:
summary: Advanced filtering
value:
status: approved
query: London
types: ['city']
countries: ['fr', 'gb']
maxResults: 20
responses:
200:
$ref: '#/components/responses/200.patch.search'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
/patch:
post:
summary: Create a new patch record
description: |
To create a new patch record, you must provide all the required properties.
operationId: CreatePatch
tags: [ Live Patching ]
requestBody:
description: Request parameters
required: true
content:
application/json:
schema:
type: object
required:
- record
properties:
record:
required:
- name
- city
- county
- administrative
- country
- countrycode
- zipcode
- population
- coordinates
- type
allOf:
- $ref: '#/components/schemas/record'
status:
type: string
default: pending
description: |
Status of the current patch record.\
`pending`: the admin will need to validate the data. Once approved, the patch record will be avaiable to end-users.\
`approved`: the patch record will be immediately available to end-users.
example: pending
enum:
- pending
- approved
language:
type: string
description: |
[Two-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).\
Specify the language in which the patch record is written.
example: en
examples:
datafix:
summary: Create a new patch record
description: Create a new patch record
value:
record:
name: Avenue New Road
city: Rome
county: Roma Capitale
administrative: Lazio
country: Italy
countrycode: it
zipcode: ['00137']
population: 2776362
coordinates: 41.9518005, 12.5644911
type: street
status: pending
responses:
200:
$ref: '#/components/responses/200.patch'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
put:
summary: Fix an existing record
description: |
To fix an existing record, you must provide the exact record you want to fix as the `origin` object.\
You must also provide at least one of the property you want to modify in `update`.
If you want your patch record to be immediately available to your end-users, set the property `status` to `approved`.\
Otherwise, the patch record will be marked as `pending` and will require the app owner to validate it via the Dashboard or the API.
operationId: UpsertPatch
tags: [ Live Patching ]
requestBody:
description: Request parameters
required: true
content:
application/json:
schema:
type: object
required:
- origin
- update
properties:
origin:
required:
- name
- city
- county
- administrative
- country
- countrycode
- zipcode
- population
- coordinates
- type
allOf:
- $ref: '#/components/schemas/record'
update:
description: At least one property is necessary.
minProperties: 1
$ref: '#/components/schemas/record'
status:
type: string
default: pending
description: |
Status of the current patch record.\
`pending`: the admin will need to validate the data. Once approved, the patch record will be avaiable to end-users.\
`approved`: the patch record will be immediately available to end-users.
example: pending
enum:
- pending
- approved
language:
type: string
description: |
[Two-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).\
Specify the language in which the patch record is written.
example: en
examples:
datafix:
summary: Edit a record
description: Edit a record
value:
origin:
name: Avenue des Champs Élysées
city: Paris 8e Arrondissement
county: Paris
administrative: Île-de-France
country: France
countrycode: fr
zipcode: ['75008']
population: 2220445
coordinates: 48.871086, 2.3036339
type: street
update:
name: rue des Nouveaux Champs Élysées
zipcode: ['75020']
status: pending
responses:
200:
$ref: '#/components/responses/200.patch'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
description: The provided `origin` record could not be found
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
/patch/{id}:
get:
summary: Get a patch record
operationId: GetPatch
tags: [ Live Patching ]
parameters:
- $ref: '#/components/parameters/patch.id'
- $ref: '#/components/parameters/patch.language'
responses:
200:
$ref: '#/components/responses/200.patch'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
description: The provided patch record `id` could not be found
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
patch:
summary: Edit a patch record
operationId: UpdatePatch
tags: [ Live Patching ]
parameters:
- $ref: '#/components/parameters/patch.id'
requestBody:
description: Request parameters
required: false
content:
application/json:
schema:
type: object
properties:
update:
description: At least one property is necessary.
minProperties: 1
$ref: '#/components/schemas/record'
status:
type: string
description: |
Status of the current data fix.\
`pending`: the admin will need to validate the data. Once approved, the patch record will be avaiable to end-users.\
`approved`: the patch record will be immediately available to end-users.
example: pending
enum:
- pending
- approved
language:
type: string
description: |
[Two-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).\
Specify the language in which the patch record is written.
example: en
examples:
status:
summary: Update patch record status
value:
status: approved
datafix:
summary: Update patch record property
value:
update:
name: Rue des Nouveaux Champs Élysées
responses:
204:
$ref: '#/components/responses/204'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
description: The provided patch record `id` could not be found
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
delete:
summary: Delete a patch record
operationId: DeletePatch
tags: [ Live Patching ]
parameters:
- $ref: '#/components/parameters/patch.id'
responses:
204:
$ref: '#/components/responses/204'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
description: The provided patch record `id` could not be found
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
/patch/{id}/language/{language}:
delete:
summary: Delete a patch record translation
operationId: DeletePatchLanguage
tags: [ Live Patching ]
parameters:
- $ref: '#/components/parameters/patch.id'
- name: language
in: path
required: true
description: |
[Two-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).\
Delete patch record language translation. There must be at least another translation available.
schema:
type: string
format: ISO-639-1
responses:
204:
$ref: '#/components/responses/204'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
description: The provided patch record `id` could not be found
409:
description: Deletion impossible. There must be at least another translation available
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
/keys:
get:
summary: List API keys
description: Get all API keys associated to the current key's app.
operationId: GetKeys
tags: [ Keys ]
responses:
200:
description: Key operation successful
content:
application/json:
schema:
type: array
items:
type: object
$ref: '#/components/schemas/key'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
post:
summary: Create an API key
description: Get all API keys associated to the current key's app.
operationId: CreateKey
tags: [ Keys ]
requestBody:
description: Request parameters
required: false
content:
application/json:
schema:
type: object
properties:
role:
type: string
default: public
description: |
Public API keys are <b>read-only</b> and are expected to be exposed to the browser.\
A `public` API key can only perform Geocoding operations.\
It is <b>highly recommended</b> to set `domains` when a `public` API key is in use.
Private API keys are <b>read and write</b> and are meant to be used for admin use.\
A `private` API key can perform all operations.
enum:
- public
- private
domains:
type: array
uniqueItems: true
items:
type: string
format: FQDN | IPv4 | IPv6 | localhost
description: Allow list of domains or IPs from which the requests to the API are allowed. `localhost` and wildcard subdomains are supported.
example: "['dev.domain.com', '82.123.239.43', '*.domain.io', 'localhost']"
responses:
200:
$ref: '#/components/responses/200.key'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
/keys/{id}:
get:
summary: Get an API key
operationId: GetKey
tags: [ Keys ]
parameters:
- $ref: '#/components/parameters/key.id'
responses:
200:
$ref: '#/components/responses/200.key'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
patch:
summary: Update API key domains
operationId: UpdateKey
tags: [ Keys ]
parameters:
- $ref: '#/components/parameters/key.id'
requestBody:
description: Request parameters
required: false
content:
application/json:
schema:
type: object
properties:
domains:
type: array
uniqueItems: true
items:
type: string
format: FQDN | IPv4 | IPv6 | localhost
description: Allow list of domains or IPs from which the requests to the API are allowed. `localhost` and wildcard subdomains are supported.
example: "['dev.domain.com', '82.123.239.43', '*.domain.io', 'localhost']"
responses:
200:
$ref: '#/components/responses/200.key'
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
delete:
summary: Delete an API key
operationId: DeleteKey
tags: [ Keys ]
parameters:
- $ref: '#/components/parameters/key.id'
responses:
200:
description: API key deleted permanently.
401:
$ref: '#/components/responses/401'
403:
$ref: '#/components/responses/403'
404:
$ref: '#/components/responses/404'
412:
$ref: '#/components/responses/412'
422:
$ref: '#/components/responses/422'
429:
$ref: '#/components/responses/429'
components:
parameters:
patch.id:
name: id
in: path
required: true
description: Patch record unique identifier
schema:
type: string
format: md5
patch.language:
name: language
in: query
required: false
description: |
[Two-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).\
Default results are in their original language.\
By setting this parameter, you can change the language of the record, _if_ the translation is available.
schema:
type: string
format: ISO-639-1
key.id:
name: id
in: path
required: true
description: Key unique identifier
schema:
type: string
example: cln0clovg0001xpeh5oxv9tfs
schemas:
parameters:
type: object
properties:
countries:
type: array
description: |
Array of [two-letter ISO 3166-1 alpha-2 country codes](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).\
Limit the results to given countries.\
Select only one country for the best results.\
If not set, the API automatically selects the user's country defined by its IP.
example: ['fr']
items:
type: string
language:
type: string
description: |
[Two-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).\
Default results are in their original language.\
By setting this parameter, you can change the language of the results, _if_ the translation is available.
example: en
types:
type: array
description: |
Select the types of record to return.\
Prepend with `-` to omit a type.\
Returns all types by default.
items:
$ref: '#/components/schemas/types'
maxResults:
type: integer
description: Maximum number of results to return.
default: 5
minimum: 1
maximum: 20
coordinates:
type: string
description: |
GPS coordinates latitude and longitude.\
Used to improve relevancy of results around the given area.
example: 48.873662, 2.295063
countryByIP:
deprecated: true
type: boolean
default: false
description: |
Automatically select the country to search in via the user IP's detected location.\
Returned results will be coming from the user's country's IP.\
If set to `true`, the parameter `countries` acts as a fallback.
parameters.countryByIP:
type: object
deprecated: true
properties:
countryByIP:
deprecated: true
type: boolean
default: true
description: |
Automatically select the country to search in via the user IP's detected location.\
Returned results will be coming from the user's country's IP.\
If set to `true`, the parameter `countries` acts as a fallback.
parameters.offset:
type: object
properties:
offset:
type: integer
description: Get paginated results starting from the offset.
default: 0
minimum: 0
parameters.status:
type: object
properties:
status:
type: string
description: Select patch records with the corresponding status.
example: approved
enum:
- pending
- approved
parameters.query:
type: object
properties:
query:
type: string
description: Search query terms.
example: 42 avenue Champs Elysees Paris
default: ''
record:
type: object
properties:
name:
type: string
description: Name of the current record.
example: 42 Avenue des Champs Élysées
city:
type: string
description: City name.
example: Paris 8e Arrondissement
county:
type: string
description: County name (department).
example: Paris
administrative:
type: string
description: Administrative name (region).
example: Île-de-France
country:
type: string
description: Country name.
example: France
administrativecode:
type: string
description: |
[ISO 3166-2 administrative code](https://en.wikipedia.org/wiki/ISO_3166-2) (available in CA, ES, IE, IT, US).
example: 'CA'
citycode:
type: string
description: INSEE city code (only available for France cities).
example: '75108'
countrycode:
type: string
description: |
[Two-letter ISO 3166-1 country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
example: 'fr'
countycode:
type: string
description: |
[Two-letter ISO 3166-2 county code](https://en.wikipedia.org/wiki/ISO_3166-2) (available in FR and IT).
example: '75'
zipcode:
type: array
description: Postcodes associated with the record.
example:
- '75008'
items:
type: string
population:
type: integer
description: Population number of the record city.
example: 2220445
lat:
deprecated: true
type: number
description: |
Latitude value between `-90` and `90`.\
**Use `coordinates` instead.**
example: 48.871086
lng:
deprecated: true
type: number
description: |
Longitude value between `-180` and `180`.\
**Use `coordinates` instead.**
example: 2.3036339
coordinates:
type: string
description: GPS coordinates latitude and longitude of the current record.
example: 48.871086, 2.3036339
type:
type: string
description: Type of the record.
example: street
enum:
- administrative
- airport
- bus
- city
- country
- county
- street
- tourism
- townhall
- train
key:
type: object
properties:
id:
type: string
description: Key identifier.
example: cln0clovg0001xpeh5oxv9tfs
token:
type: string
description: |
API Key used to perform operations on the API.\
Set this key in the request header `x-placekit-api-key`.
example: pk_OGRVIUTnuxFEJUXNECjFrZ6sdVovGz1ojygkbzGXcbM=
appId:
type: string
description: App ID associated with this API key.
example: ULIMBXTYDH
role:
type: string
description: |
Public API keys are <b>read-only</b> and are expected to be exposed to the browser.\
A `public` API key can only perform Geocoding operations.\
It is <b>highly recommended</b> to set `domains` when a `public` API key is in use.
Private API keys are <b>read and write</b> and are meant to be used for admin use.\
A `private` API key can perform all operations.
enum:
- public
- private
domains:
type: array
uniqueItems: true
items:
type: string
format: FQDN | IPv4 | IPv6 | localhost
description: Allow list of domains or IPs from which the requests to the API are allowed. `localhost` and wildcard subdomains are supported.
example: "['dev.domain.com', '82.123.239.43', '*.domain.io', 'localhost']"
createdAt:
type: string
format: timestamp
description: Timestamp when the key was created.
example: 2023-09-26T13:23:27.077Z
updatedAt:
type: string
format: timestamp
description: Timestamp when the key was last modified.
example: 2023-09-26T13:24:37.862Z
patch.id:
type: object
properties:
id:
type: string
description: Data fix identifier.
example: c9ce0be25ff6a74405c8cfa040e5ba1f
patch.status:
type: object
properties:
status:
type: string
description: Patch record status.
example: pending
results:
type: object
properties:
results:
type: array
items:
allOf:
- type: object
properties:
highlight:
type: string
description: Name of the current record with highlighted matched words.
example: <mark>42 Avenue</mark> des <mark>Champs Élysées</mark>
- $ref: '#/components/schemas/record'
resultsCount:
type: integer
description: Number of items results found.
example: 2
maxResults:
type: integer
description: Maximum number of results items returned.
example: 5
results.query:
type: object
properties:
query:
type: string
description: Search text query used for this response.
example: '42 avenue Champs Elysees Paris'
results.offset:
type: object
properties:
offset:
type: integer
description: Offset used for this paginated response.
example: 0
results.totalResults:
type: object
properties:
totalResults:
type: integer
description: The total number of available records.
example: 2
types:
type: string
enum:
- administrative
- -administrative
- airport
- -airport
- bus
- -bus
- city
- -city
- country
- -country
- county
- -county
- street
- -street
- tourism
- -tourism
- townhall
- -townhall
- train
- -train
validationError:
type: object
properties:
value:
type: string
msg:
type: string
param:
type: string
location:
type: string