@golemio/pid 3.15.3-dev.1840989210 → 3.15.3-dev.1841156396
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.
- package/db/example/22_jis_events.sql +56 -0
- package/db/migrations/postgresql/20250522144056-add-new-attributes-to-event.js +53 -0
- package/db/migrations/postgresql/sqls/20250522144056-add-new-attributes-to-event-down.sql +5 -0
- package/db/migrations/postgresql/sqls/20250522144056-add-new-attributes-to-event-up.sql +4 -0
- package/dist/integration-engine/jis/transformations/JISEventsTransformation.js +3 -0
- package/dist/integration-engine/jis/transformations/JISEventsTransformation.js.map +1 -1
- package/dist/output-gateway/index.js +4 -0
- package/dist/output-gateway/index.js.map +1 -1
- package/dist/output-gateway/jis/controllers/v1/V1EventsController.d.ts +12 -0
- package/dist/output-gateway/jis/controllers/v1/V1EventsController.js +71 -0
- package/dist/output-gateway/jis/controllers/v1/V1EventsController.js.map +1 -0
- package/dist/output-gateway/jis/data-access/JISEventsRepository.d.ts +18 -0
- package/dist/output-gateway/jis/data-access/JISEventsRepository.js +76 -0
- package/dist/output-gateway/jis/data-access/JISEventsRepository.js.map +1 -0
- package/dist/output-gateway/jis/data-access/JISEventsRopidGTFSRoutesRepository.d.ts +12 -0
- package/dist/output-gateway/jis/data-access/JISEventsRopidGTFSRoutesRepository.js +40 -0
- package/dist/output-gateway/jis/data-access/JISEventsRopidGTFSRoutesRepository.js.map +1 -0
- package/dist/output-gateway/jis/data-access/RopidGTFSRoutesRepository.d.ts +12 -0
- package/dist/output-gateway/jis/data-access/RopidGTFSRoutesRepository.js +39 -0
- package/dist/output-gateway/jis/data-access/RopidGTFSRoutesRepository.js.map +1 -0
- package/dist/output-gateway/jis/domain/IJISEventsInterfaces.d.ts +36 -0
- package/dist/output-gateway/jis/domain/IJISEventsInterfaces.js +3 -0
- package/dist/output-gateway/jis/domain/IJISEventsInterfaces.js.map +1 -0
- package/dist/output-gateway/jis/helpers/TranslationHelper.d.ts +4 -0
- package/dist/output-gateway/jis/helpers/TranslationHelper.js +48 -0
- package/dist/output-gateway/jis/helpers/TranslationHelper.js.map +1 -0
- package/dist/output-gateway/jis/ioc/Di.d.ts +3 -0
- package/dist/output-gateway/jis/ioc/Di.js +27 -0
- package/dist/output-gateway/jis/ioc/Di.js.map +1 -0
- package/dist/output-gateway/jis/ioc/OgJisToken.d.ts +8 -0
- package/dist/output-gateway/jis/ioc/OgJisToken.js +20 -0
- package/dist/output-gateway/jis/ioc/OgJisToken.js.map +1 -0
- package/dist/output-gateway/jis/routers/v1/V1JISRouter.d.ts +12 -0
- package/dist/output-gateway/jis/routers/v1/V1JISRouter.js +33 -0
- package/dist/output-gateway/jis/routers/v1/V1JISRouter.js.map +1 -0
- package/dist/output-gateway/jis/routers/v1/index.d.ts +1 -0
- package/dist/output-gateway/jis/routers/v1/index.js +6 -0
- package/dist/output-gateway/jis/routers/v1/index.js.map +1 -0
- package/dist/output-gateway/jis/transofrmations/JISEventsCustomFormatTransformation.d.ts +10 -0
- package/dist/output-gateway/jis/transofrmations/JISEventsCustomFormatTransformation.js +72 -0
- package/dist/output-gateway/jis/transofrmations/JISEventsCustomFormatTransformation.js.map +1 -0
- package/dist/output-gateway/pid/ioc/Di.js +0 -1
- package/dist/output-gateway/pid/ioc/Di.js.map +1 -1
- package/dist/schema-definitions/jis/datasources/JISEventsJsonSchema.js +17 -0
- package/dist/schema-definitions/jis/datasources/JISEventsJsonSchema.js.map +1 -1
- package/dist/schema-definitions/jis/datasources/interfaces/IJISEvent.d.ts +5 -0
- package/dist/schema-definitions/jis/models/JISEventsModel.d.ts +6 -3
- package/dist/schema-definitions/jis/models/JISEventsModel.js +20 -0
- package/dist/schema-definitions/jis/models/JISEventsModel.js.map +1 -1
- package/dist/schema-definitions/jis/models/interfaces/IJISEvent.d.ts +3 -0
- package/docs/openapi-input.yaml +35 -1
- package/docs/openapi-output.yaml +267 -0
- package/package.json +1 -1
package/docs/openapi-input.yaml
CHANGED
|
@@ -571,6 +571,22 @@ components:
|
|
|
571
571
|
nullable: true
|
|
572
572
|
example: "2024-03-03T14:22:20.958Z"
|
|
573
573
|
description: The start and end date/time of the event validity
|
|
574
|
+
display_period:
|
|
575
|
+
type: object
|
|
576
|
+
required:
|
|
577
|
+
- start
|
|
578
|
+
- end
|
|
579
|
+
properties:
|
|
580
|
+
start:
|
|
581
|
+
type: string
|
|
582
|
+
format: date-time
|
|
583
|
+
example: "2024-02-29T11:22:20.958Z"
|
|
584
|
+
end:
|
|
585
|
+
type: string
|
|
586
|
+
format: date-time
|
|
587
|
+
nullable: true
|
|
588
|
+
example: "2024-03-03T14:22:20.958Z"
|
|
589
|
+
description: The start and end date/time of the event visibility
|
|
574
590
|
effect:
|
|
575
591
|
type: string
|
|
576
592
|
example: DETOUR
|
|
@@ -613,6 +629,20 @@ components:
|
|
|
613
629
|
- cs
|
|
614
630
|
- en
|
|
615
631
|
description: Localized descriptions of the event
|
|
632
|
+
description_html:
|
|
633
|
+
type: object
|
|
634
|
+
properties:
|
|
635
|
+
cs:
|
|
636
|
+
type: string
|
|
637
|
+
description: Event description in Czech in html format
|
|
638
|
+
en:
|
|
639
|
+
type: string
|
|
640
|
+
nullable: true
|
|
641
|
+
description: Event description in English in html format
|
|
642
|
+
required:
|
|
643
|
+
- cs
|
|
644
|
+
- en
|
|
645
|
+
description: Localized descriptions of the event in html format
|
|
616
646
|
url:
|
|
617
647
|
type: object
|
|
618
648
|
properties:
|
|
@@ -824,11 +854,15 @@ components:
|
|
|
824
854
|
},
|
|
825
855
|
"severity_level": "SEVERE",
|
|
826
856
|
"active_period": { "start": "2024-02-07T12:11:00.000Z", "end": null },
|
|
857
|
+
"display_period": { "start": "2024-02-07T12:11:00.000Z", "end": null },
|
|
827
858
|
"effect": "MODIFIED_SERVICE",
|
|
828
859
|
"effect_detail": { "cs": "Provoz omezen" },
|
|
829
860
|
"description_text": {
|
|
830
861
|
"cs": "V Libni je omezen provoz tramvají. Důvodem je technická závada trolejbusu na kolejích."
|
|
831
862
|
},
|
|
863
|
+
"description_html": {
|
|
864
|
+
"cs": "<p>V Libni je omezen provoz tramvají. Důvodem je technická závada trolejbusu na kolejích.</p>"
|
|
865
|
+
},
|
|
832
866
|
"url": {
|
|
833
867
|
"cs": "https://dpp.cz/omezeni-a-mimoradne-udalosti/detail/test-0"
|
|
834
868
|
},
|
|
@@ -893,4 +927,4 @@ components:
|
|
|
893
927
|
"created_timestamp": "2024-11-08T10:44:34.701Z",
|
|
894
928
|
"last_modified_timestamp": "2024-11-08T10:44:34.701Z"
|
|
895
929
|
}
|
|
896
|
-
]
|
|
930
|
+
]
|
package/docs/openapi-output.yaml
CHANGED
|
@@ -44,6 +44,8 @@ tags:
|
|
|
44
44
|
|
|
45
45
|
- name: 🕒 Public Departures (v2)
|
|
46
46
|
description: <img src="https://img.shields.io/badge/opendata-available-green" alt="golemioapi-opendata-badge" />
|
|
47
|
+
- name: 🪧 JIS (v1)
|
|
48
|
+
description: <img src="https://img.shields.io/badge/opendata-available-green" alt="golemioapi-opendata-badge" />
|
|
47
49
|
|
|
48
50
|
paths:
|
|
49
51
|
/v2/gtfs/services:
|
|
@@ -1740,6 +1742,53 @@ paths:
|
|
|
1740
1742
|
maxItems: 0
|
|
1741
1743
|
items:
|
|
1742
1744
|
type: object
|
|
1745
|
+
/v1/jis/events/custom-format:
|
|
1746
|
+
get:
|
|
1747
|
+
tags:
|
|
1748
|
+
- 🪧 JIS (v1)
|
|
1749
|
+
summary: Get all published events in custom format for external use
|
|
1750
|
+
parameters:
|
|
1751
|
+
- name: displayPeriodStart
|
|
1752
|
+
in: query
|
|
1753
|
+
required: false
|
|
1754
|
+
schema:
|
|
1755
|
+
type: string
|
|
1756
|
+
format: date-time
|
|
1757
|
+
example: "2024-02-29T11:22:20.958Z"
|
|
1758
|
+
description: Start of the display period
|
|
1759
|
+
- name: displayPeriodEnd
|
|
1760
|
+
in: query
|
|
1761
|
+
required: false
|
|
1762
|
+
schema:
|
|
1763
|
+
type: string
|
|
1764
|
+
format: date-time
|
|
1765
|
+
example: "2024-03-03T14:22:20.958Z"
|
|
1766
|
+
description: End of the display period
|
|
1767
|
+
- name: organizationNames
|
|
1768
|
+
in: query
|
|
1769
|
+
required: false
|
|
1770
|
+
schema:
|
|
1771
|
+
type: array
|
|
1772
|
+
items:
|
|
1773
|
+
type: string
|
|
1774
|
+
example: "ROPID"
|
|
1775
|
+
description: List of organization names to filter events by.
|
|
1776
|
+
responses:
|
|
1777
|
+
200:
|
|
1778
|
+
description: OK
|
|
1779
|
+
content:
|
|
1780
|
+
application/json:
|
|
1781
|
+
schema:
|
|
1782
|
+
type: array
|
|
1783
|
+
items:
|
|
1784
|
+
$ref: "#/components/schemas/EventCustomFormat"
|
|
1785
|
+
400:
|
|
1786
|
+
$ref: "#/components/responses/BadRequestError"
|
|
1787
|
+
401:
|
|
1788
|
+
$ref: "#/components/responses/UnauthorizedError"
|
|
1789
|
+
|
|
1790
|
+
|
|
1791
|
+
|
|
1743
1792
|
|
|
1744
1793
|
|
|
1745
1794
|
|
|
@@ -3274,3 +3323,221 @@ components:
|
|
|
3274
3323
|
type: boolean
|
|
3275
3324
|
example: true
|
|
3276
3325
|
nullable: true
|
|
3326
|
+
EventId:
|
|
3327
|
+
type: string
|
|
3328
|
+
format: uuid
|
|
3329
|
+
example: 1b75c16b-d5a3-40ca-8560-5a7dc011655d
|
|
3330
|
+
Effect:
|
|
3331
|
+
type: object
|
|
3332
|
+
properties:
|
|
3333
|
+
cs:
|
|
3334
|
+
type: string
|
|
3335
|
+
example: Zpoždění
|
|
3336
|
+
en:
|
|
3337
|
+
type: string
|
|
3338
|
+
example: Delay
|
|
3339
|
+
nullable: true
|
|
3340
|
+
required:
|
|
3341
|
+
- cs
|
|
3342
|
+
RouteType:
|
|
3343
|
+
type: number
|
|
3344
|
+
example: 0
|
|
3345
|
+
enum:
|
|
3346
|
+
- 0
|
|
3347
|
+
- 1
|
|
3348
|
+
- 2
|
|
3349
|
+
- 3
|
|
3350
|
+
- 4
|
|
3351
|
+
- 7
|
|
3352
|
+
- 11
|
|
3353
|
+
description: |
|
|
3354
|
+
0 - tram \
|
|
3355
|
+
1 - metro \
|
|
3356
|
+
2 - rail \
|
|
3357
|
+
3 - bus \
|
|
3358
|
+
4 - ferry \
|
|
3359
|
+
7 - funicular \
|
|
3360
|
+
11 - trolleybus
|
|
3361
|
+
|
|
3362
|
+
InformedEntityRoute:
|
|
3363
|
+
type: object
|
|
3364
|
+
properties:
|
|
3365
|
+
id:
|
|
3366
|
+
type: string
|
|
3367
|
+
example: L13
|
|
3368
|
+
route_short_name:
|
|
3369
|
+
type: string
|
|
3370
|
+
example: "13"
|
|
3371
|
+
route_long_name:
|
|
3372
|
+
type: string
|
|
3373
|
+
example: "Čechovo náměstí - Olšanské hřbitovy"
|
|
3374
|
+
route_type:
|
|
3375
|
+
$ref: "#/components/schemas/RouteType"
|
|
3376
|
+
required:
|
|
3377
|
+
- id
|
|
3378
|
+
- route_short_name
|
|
3379
|
+
- route_type
|
|
3380
|
+
- route_long_name
|
|
3381
|
+
|
|
3382
|
+
EventCustomFormat:
|
|
3383
|
+
type: object
|
|
3384
|
+
required:
|
|
3385
|
+
- id
|
|
3386
|
+
- type
|
|
3387
|
+
- header_text
|
|
3388
|
+
- cause
|
|
3389
|
+
- cause_detail
|
|
3390
|
+
- severity_level
|
|
3391
|
+
- active_period
|
|
3392
|
+
- display_period
|
|
3393
|
+
- effects
|
|
3394
|
+
- description_text
|
|
3395
|
+
- description_html
|
|
3396
|
+
- url
|
|
3397
|
+
- organization_name
|
|
3398
|
+
- created_timestamp
|
|
3399
|
+
- last_modified_timestamp
|
|
3400
|
+
properties:
|
|
3401
|
+
id:
|
|
3402
|
+
$ref: "#/components/schemas/EventId"
|
|
3403
|
+
description: Unique identifier of the event in the UUIDv4 format
|
|
3404
|
+
type:
|
|
3405
|
+
type: string
|
|
3406
|
+
example: INCIDENT
|
|
3407
|
+
enum:
|
|
3408
|
+
- INCIDENT
|
|
3409
|
+
- DISRUPTION
|
|
3410
|
+
- SERVICE_CHANGE
|
|
3411
|
+
header_text:
|
|
3412
|
+
type: object
|
|
3413
|
+
properties:
|
|
3414
|
+
cs:
|
|
3415
|
+
type: string
|
|
3416
|
+
example: Nehoda Jiřího z Poděbrad
|
|
3417
|
+
en:
|
|
3418
|
+
type: string
|
|
3419
|
+
example: Accident at Jiřího z Poděbrad
|
|
3420
|
+
nullable: true
|
|
3421
|
+
required:
|
|
3422
|
+
- cs
|
|
3423
|
+
cause:
|
|
3424
|
+
type: object
|
|
3425
|
+
properties:
|
|
3426
|
+
cs:
|
|
3427
|
+
type: string
|
|
3428
|
+
example: Nehoda
|
|
3429
|
+
en:
|
|
3430
|
+
type: string
|
|
3431
|
+
example: Accident
|
|
3432
|
+
nullable: true
|
|
3433
|
+
required:
|
|
3434
|
+
- cs
|
|
3435
|
+
cause_detail:
|
|
3436
|
+
type: object
|
|
3437
|
+
properties:
|
|
3438
|
+
cs:
|
|
3439
|
+
type: string
|
|
3440
|
+
example: Nehoda na křižovatce
|
|
3441
|
+
en:
|
|
3442
|
+
type: string
|
|
3443
|
+
example: Accident at the intersection
|
|
3444
|
+
nullable: true
|
|
3445
|
+
required:
|
|
3446
|
+
- cs
|
|
3447
|
+
severity_level:
|
|
3448
|
+
type: string
|
|
3449
|
+
example: SEVERE
|
|
3450
|
+
enum:
|
|
3451
|
+
- INFO
|
|
3452
|
+
- WARNING
|
|
3453
|
+
- SEVERE
|
|
3454
|
+
description: |
|
|
3455
|
+
INFO - priority 3 \
|
|
3456
|
+
WARNING - priority 2 \
|
|
3457
|
+
SEVERE - priority 1
|
|
3458
|
+
active_period:
|
|
3459
|
+
type: object
|
|
3460
|
+
required:
|
|
3461
|
+
- start
|
|
3462
|
+
- end
|
|
3463
|
+
properties:
|
|
3464
|
+
start:
|
|
3465
|
+
type: string
|
|
3466
|
+
format: date-time
|
|
3467
|
+
example: "2024-02-29T11:22:20.958Z"
|
|
3468
|
+
end:
|
|
3469
|
+
type: string
|
|
3470
|
+
format: date-time
|
|
3471
|
+
nullable: true
|
|
3472
|
+
example: "2024-03-03T14:22:20.958Z"
|
|
3473
|
+
description: The start and end date/time of the event validity
|
|
3474
|
+
display_period:
|
|
3475
|
+
type: object
|
|
3476
|
+
required:
|
|
3477
|
+
- start
|
|
3478
|
+
- end
|
|
3479
|
+
properties:
|
|
3480
|
+
start:
|
|
3481
|
+
type: string
|
|
3482
|
+
format: date-time
|
|
3483
|
+
example: "2024-02-29T11:22:20.958Z"
|
|
3484
|
+
end:
|
|
3485
|
+
type: string
|
|
3486
|
+
format: date-time
|
|
3487
|
+
nullable: true
|
|
3488
|
+
example: "2024-03-03T14:22:20.958Z"
|
|
3489
|
+
description: The start and end date/time when the event should be displayed
|
|
3490
|
+
effects:
|
|
3491
|
+
type: array
|
|
3492
|
+
minItems: 1
|
|
3493
|
+
items:
|
|
3494
|
+
$ref: "#/components/schemas/Effect"
|
|
3495
|
+
description_text:
|
|
3496
|
+
type: object
|
|
3497
|
+
properties:
|
|
3498
|
+
cs:
|
|
3499
|
+
type: string
|
|
3500
|
+
description: Event description in Czech in plain text
|
|
3501
|
+
en:
|
|
3502
|
+
type: string
|
|
3503
|
+
nullable: true
|
|
3504
|
+
description: Event description in English in plain text
|
|
3505
|
+
required:
|
|
3506
|
+
- cs
|
|
3507
|
+
description: Localized descriptions of the event in plain text
|
|
3508
|
+
description_html:
|
|
3509
|
+
type: object
|
|
3510
|
+
properties:
|
|
3511
|
+
cs:
|
|
3512
|
+
type: string
|
|
3513
|
+
description: Event description in Czech in HTML format
|
|
3514
|
+
en:
|
|
3515
|
+
type: string
|
|
3516
|
+
nullable: true
|
|
3517
|
+
description: Event description in English in HTML format
|
|
3518
|
+
required:
|
|
3519
|
+
- cs
|
|
3520
|
+
description: Localized descriptions of the event in HTML format
|
|
3521
|
+
organization_name:
|
|
3522
|
+
type: string
|
|
3523
|
+
example: ROPID
|
|
3524
|
+
informed_entity:
|
|
3525
|
+
type: object
|
|
3526
|
+
nullable: true
|
|
3527
|
+
properties:
|
|
3528
|
+
routes:
|
|
3529
|
+
type: array
|
|
3530
|
+
nullable: true
|
|
3531
|
+
items:
|
|
3532
|
+
type: object
|
|
3533
|
+
$ref: "#/components/schemas/InformedEntityRoute"
|
|
3534
|
+
last_modified_timestamp:
|
|
3535
|
+
type: string
|
|
3536
|
+
format: date-time
|
|
3537
|
+
example: "2024-02-29T12:22:20.958Z"
|
|
3538
|
+
description: Timestamp from when the event was last modified in VYMI
|
|
3539
|
+
created_timestamp:
|
|
3540
|
+
type: string
|
|
3541
|
+
format: date-time
|
|
3542
|
+
example: "2024-02-29T12:22:20.958Z"
|
|
3543
|
+
description: Timestamp from when the event was created in VYMI
|