@digdir/dialogporten-schema 1.117.2 → 1.117.3-c3248af

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digdir/dialogporten-schema",
3
- "version": "1.117.2",
3
+ "version": "1.117.3-c3248af",
4
4
  "description": "GraphQl schema and OpenAPI spec for Dialogporten",
5
5
  "engines": {
6
6
  "node": "24"
@@ -10,7 +10,7 @@ type Queries @authorize(policy: "enduser") {
10
10
  searchDialogs(input: SearchDialogInput!): SearchDialogsPayload!
11
11
  limits: Limits!
12
12
  parties: [AuthorizedParty!]!
13
- serviceResources: ServiceResourceMetadata!
13
+ serviceResources(parties: [String!], includeUnauthorized: Boolean! = false): ServiceResourceMetadata!
14
14
  }
15
15
 
16
16
  type Mutations @authorize(policy: "enduser") {
@@ -566,6 +566,8 @@ type ServiceResourceMetadataServiceOwner {
566
566
 
567
567
  type ServiceResourceMetadataServiceResource {
568
568
  id: String!
569
+ resourceType: String!
570
+ status: String!
569
571
  isDelegable: Boolean!
570
572
  minimumAuthenticationLevel: Int!
571
573
  name: [Localization!]!
package/src/index.js CHANGED
@@ -10,7 +10,7 @@ type Queries @authorize(policy: "enduser") {
10
10
  searchDialogs(input: SearchDialogInput!): SearchDialogsPayload!
11
11
  limits: Limits!
12
12
  parties: [AuthorizedParty!]!
13
- serviceResources: ServiceResourceMetadata!
13
+ serviceResources(parties: [String!], includeUnauthorized: Boolean! = false): ServiceResourceMetadata!
14
14
  }
15
15
 
16
16
  type Mutations @authorize(policy: "enduser") {
@@ -566,6 +566,8 @@ type ServiceResourceMetadataServiceOwner {
566
566
 
567
567
  type ServiceResourceMetadataServiceResource {
568
568
  id: String!
569
+ resourceType: String!
570
+ status: String!
569
571
  isDelegable: Boolean!
570
572
  minimumAuthenticationLevel: Int!
571
573
  name: [Localization!]!
@@ -312,59 +312,83 @@
312
312
  "type": "object"
313
313
  },
314
314
  "ProblemDetails": {
315
- "additionalProperties": false,
315
+ "additionalProperties": {
316
+ "nullable": true
317
+ },
316
318
  "properties": {
319
+ "code": {
320
+ "nullable": true,
321
+ "type": "string"
322
+ },
317
323
  "detail": {
318
324
  "nullable": true,
319
325
  "type": "string"
320
326
  },
321
327
  "errors": {
322
- "items": {
323
- "$ref": "#/components/schemas/ProblemDetails_Error"
328
+ "additionalProperties": {
329
+ "items": {
330
+ "type": "string"
331
+ },
332
+ "type": "array"
324
333
  },
325
- "nullable": true,
326
- "type": "array"
334
+ "type": "object"
327
335
  },
328
336
  "instance": {
329
- "default": "/api/route",
337
+ "nullable": true,
330
338
  "type": "string"
331
339
  },
332
340
  "status": {
333
- "default": 400,
334
341
  "format": "int32",
342
+ "nullable": true,
335
343
  "type": "integer"
336
344
  },
345
+ "statusDescription": {
346
+ "nullable": true,
347
+ "type": "string"
348
+ },
337
349
  "title": {
338
- "default": "One or more validation errors occurred.",
350
+ "nullable": true,
339
351
  "type": "string"
340
352
  },
341
353
  "traceId": {
342
- "default": "0HMPNHL0JHL76:00000001",
354
+ "nullable": true,
343
355
  "type": "string"
344
356
  },
345
357
  "type": {
346
- "default": "https://www.rfc-editor.org/rfc/rfc7231#section-6.5.1",
358
+ "nullable": true,
347
359
  "type": "string"
360
+ },
361
+ "validationErrors": {
362
+ "items": {
363
+ "$ref": "#/components/schemas/ProblemDetails_Error"
364
+ },
365
+ "nullable": true,
366
+ "type": "array"
348
367
  }
349
368
  },
350
369
  "type": "object"
351
370
  },
352
371
  "ProblemDetails_Error": {
353
- "additionalProperties": false,
372
+ "additionalProperties": {
373
+ "nullable": true
374
+ },
354
375
  "properties": {
355
376
  "code": {
356
377
  "nullable": true,
357
378
  "type": "string"
358
379
  },
359
- "name": {
360
- "default": "Error or field name",
380
+ "detail": {
381
+ "nullable": true,
361
382
  "type": "string"
362
383
  },
363
- "reason": {
364
- "default": "Error reason",
365
- "type": "string"
384
+ "paths": {
385
+ "items": {
386
+ "type": "string"
387
+ },
388
+ "nullable": true,
389
+ "type": "array"
366
390
  },
367
- "severity": {
391
+ "title": {
368
392
  "nullable": true,
369
393
  "type": "string"
370
394
  }
@@ -688,6 +712,121 @@
688
712
  },
689
713
  "type": "object"
690
714
  },
715
+ "V1CommonServiceResourceMetadata_ServiceResourceMetadataAccessPackage": {
716
+ "additionalProperties": false,
717
+ "properties": {
718
+ "links": {
719
+ "$ref": "#/components/schemas/DigdirDomainDialogportenApplicationCommon_Link"
720
+ },
721
+ "name": {
722
+ "items": {
723
+ "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
724
+ },
725
+ "nullable": true,
726
+ "type": "array"
727
+ },
728
+ "urn": {
729
+ "type": "string"
730
+ }
731
+ },
732
+ "type": "object"
733
+ },
734
+ "V1CommonServiceResourceMetadata_ServiceResourceMetadataItem": {
735
+ "additionalProperties": false,
736
+ "properties": {
737
+ "accessPackages": {
738
+ "items": {
739
+ "$ref": "#/components/schemas/V1CommonServiceResourceMetadata_ServiceResourceMetadataAccessPackage"
740
+ },
741
+ "nullable": true,
742
+ "type": "array"
743
+ },
744
+ "roles": {
745
+ "items": {
746
+ "$ref": "#/components/schemas/V1CommonServiceResourceMetadata_ServiceResourceMetadataRole"
747
+ },
748
+ "nullable": true,
749
+ "type": "array"
750
+ },
751
+ "serviceOwner": {
752
+ "$ref": "#/components/schemas/V1CommonServiceResourceMetadata_ServiceResourceMetadataServiceOwner"
753
+ },
754
+ "serviceResource": {
755
+ "$ref": "#/components/schemas/V1CommonServiceResourceMetadata_ServiceResourceMetadataServiceResource"
756
+ }
757
+ },
758
+ "type": "object"
759
+ },
760
+ "V1CommonServiceResourceMetadata_ServiceResourceMetadataRole": {
761
+ "additionalProperties": false,
762
+ "properties": {
763
+ "links": {
764
+ "$ref": "#/components/schemas/DigdirDomainDialogportenApplicationCommon_Link"
765
+ },
766
+ "name": {
767
+ "items": {
768
+ "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
769
+ },
770
+ "nullable": true,
771
+ "type": "array"
772
+ },
773
+ "urn": {
774
+ "type": "string"
775
+ }
776
+ },
777
+ "type": "object"
778
+ },
779
+ "V1CommonServiceResourceMetadata_ServiceResourceMetadataServiceOwner": {
780
+ "additionalProperties": false,
781
+ "properties": {
782
+ "code": {
783
+ "type": "string"
784
+ },
785
+ "name": {
786
+ "items": {
787
+ "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
788
+ },
789
+ "nullable": true,
790
+ "type": "array"
791
+ },
792
+ "orgNumber": {
793
+ "type": "string"
794
+ }
795
+ },
796
+ "type": "object"
797
+ },
798
+ "V1CommonServiceResourceMetadata_ServiceResourceMetadataServiceResource": {
799
+ "additionalProperties": false,
800
+ "properties": {
801
+ "id": {
802
+ "type": "string"
803
+ },
804
+ "isDelegable": {
805
+ "type": "boolean"
806
+ },
807
+ "links": {
808
+ "$ref": "#/components/schemas/DigdirDomainDialogportenApplicationCommon_Link"
809
+ },
810
+ "minimumAuthenticationLevel": {
811
+ "format": "int32",
812
+ "type": "integer"
813
+ },
814
+ "name": {
815
+ "items": {
816
+ "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
817
+ },
818
+ "nullable": true,
819
+ "type": "array"
820
+ },
821
+ "resourceType": {
822
+ "type": "string"
823
+ },
824
+ "status": {
825
+ "type": "string"
826
+ }
827
+ },
828
+ "type": "object"
829
+ },
691
830
  "V1EndUserCommon_AcceptedLanguage": {
692
831
  "additionalProperties": false,
693
832
  "properties": {
@@ -1945,7 +2084,8 @@
1945
2084
  "additionalProperties": false,
1946
2085
  "properties": {
1947
2086
  "content": {
1948
- "description": "The content of the dialog in search results.",
2087
+ "description": "The content of the dialog in search results. May be null for API-only dialogs, which are not required to have content.",
2088
+ "nullable": true,
1949
2089
  "oneOf": [
1950
2090
  {
1951
2091
  "$ref": "#/components/schemas/V1EndUserDialogsQueriesSearch_Content"
@@ -2648,6 +2788,33 @@
2648
2788
  },
2649
2789
  "type": "object"
2650
2790
  },
2791
+ "V1EndUserServiceResourcesQueriesSearch_AuthorizedServiceResources": {
2792
+ "additionalProperties": false,
2793
+ "properties": {
2794
+ "items": {
2795
+ "items": {
2796
+ "$ref": "#/components/schemas/V1CommonServiceResourceMetadata_ServiceResourceMetadataItem"
2797
+ },
2798
+ "nullable": true,
2799
+ "type": "array"
2800
+ }
2801
+ },
2802
+ "type": "object"
2803
+ },
2804
+ "V1EndUserServiceResourcesSearch_AuthorizedServiceResourcesRequest": {
2805
+ "additionalProperties": false,
2806
+ "properties": {
2807
+ "acceptedLanguages": {
2808
+ "nullable": true,
2809
+ "oneOf": [
2810
+ {
2811
+ "$ref": "#/components/schemas/V1EndUserCommon_AcceptedLanguages"
2812
+ }
2813
+ ]
2814
+ }
2815
+ },
2816
+ "type": "object"
2817
+ },
2651
2818
  "V1MetadataLimitsQueriesGet_EndUserSearchLimits": {
2652
2819
  "additionalProperties": false,
2653
2820
  "properties": {
@@ -2719,116 +2886,7 @@
2719
2886
  "properties": {
2720
2887
  "items": {
2721
2888
  "items": {
2722
- "$ref": "#/components/schemas/V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataItem"
2723
- },
2724
- "nullable": true,
2725
- "type": "array"
2726
- }
2727
- },
2728
- "type": "object"
2729
- },
2730
- "V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataAccessPackage": {
2731
- "additionalProperties": false,
2732
- "properties": {
2733
- "links": {
2734
- "$ref": "#/components/schemas/DigdirDomainDialogportenApplicationCommon_Link"
2735
- },
2736
- "name": {
2737
- "items": {
2738
- "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
2739
- },
2740
- "nullable": true,
2741
- "type": "array"
2742
- },
2743
- "urn": {
2744
- "type": "string"
2745
- }
2746
- },
2747
- "type": "object"
2748
- },
2749
- "V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataItem": {
2750
- "additionalProperties": false,
2751
- "properties": {
2752
- "accessPackages": {
2753
- "items": {
2754
- "$ref": "#/components/schemas/V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataAccessPackage"
2755
- },
2756
- "nullable": true,
2757
- "type": "array"
2758
- },
2759
- "roles": {
2760
- "items": {
2761
- "$ref": "#/components/schemas/V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataRole"
2762
- },
2763
- "nullable": true,
2764
- "type": "array"
2765
- },
2766
- "serviceOwner": {
2767
- "$ref": "#/components/schemas/V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataServiceOwner"
2768
- },
2769
- "serviceResource": {
2770
- "$ref": "#/components/schemas/V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataServiceResource"
2771
- }
2772
- },
2773
- "type": "object"
2774
- },
2775
- "V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataRole": {
2776
- "additionalProperties": false,
2777
- "properties": {
2778
- "links": {
2779
- "$ref": "#/components/schemas/DigdirDomainDialogportenApplicationCommon_Link"
2780
- },
2781
- "name": {
2782
- "items": {
2783
- "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
2784
- },
2785
- "nullable": true,
2786
- "type": "array"
2787
- },
2788
- "urn": {
2789
- "type": "string"
2790
- }
2791
- },
2792
- "type": "object"
2793
- },
2794
- "V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataServiceOwner": {
2795
- "additionalProperties": false,
2796
- "properties": {
2797
- "code": {
2798
- "type": "string"
2799
- },
2800
- "name": {
2801
- "items": {
2802
- "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
2803
- },
2804
- "nullable": true,
2805
- "type": "array"
2806
- },
2807
- "orgNumber": {
2808
- "type": "string"
2809
- }
2810
- },
2811
- "type": "object"
2812
- },
2813
- "V1MetadataServiceResourcesQueriesGet_ServiceResourceMetadataServiceResource": {
2814
- "additionalProperties": false,
2815
- "properties": {
2816
- "id": {
2817
- "type": "string"
2818
- },
2819
- "isDelegable": {
2820
- "type": "boolean"
2821
- },
2822
- "links": {
2823
- "$ref": "#/components/schemas/DigdirDomainDialogportenApplicationCommon_Link"
2824
- },
2825
- "minimumAuthenticationLevel": {
2826
- "format": "int32",
2827
- "type": "integer"
2828
- },
2829
- "name": {
2830
- "items": {
2831
- "$ref": "#/components/schemas/V1CommonLocalizations_Localization"
2889
+ "$ref": "#/components/schemas/V1CommonServiceResourceMetadata_ServiceResourceMetadataItem"
2832
2890
  },
2833
2891
  "nullable": true,
2834
2892
  "type": "array"
@@ -8450,6 +8508,88 @@
8450
8508
  ]
8451
8509
  }
8452
8510
  },
8511
+ "/api/v1/enduser/serviceresources": {
8512
+ "get": {
8513
+ "description": "Returns the same service resource metadata as the public metadata endpoint, filtered to the resources the calling end user is authorized to use. Optionally narrowed by one or more party URNs.",
8514
+ "operationId": "V1EndUserServiceResourcesSearch_AuthorizedServiceResources",
8515
+ "parameters": [
8516
+ {
8517
+ "description": "Filter by one or more party URNs. Parties the caller is not authorized for are silently ignored.",
8518
+ "explode": true,
8519
+ "in": "query",
8520
+ "name": "party",
8521
+ "schema": {
8522
+ "items": {
8523
+ "type": "string"
8524
+ },
8525
+ "nullable": true,
8526
+ "type": "array"
8527
+ },
8528
+ "style": "form"
8529
+ },
8530
+ {
8531
+ "in": "header",
8532
+ "name": "accept-Language",
8533
+ "schema": {
8534
+ "nullable": true,
8535
+ "oneOf": [
8536
+ {
8537
+ "$ref": "#/components/schemas/V1EndUserCommon_AcceptedLanguages"
8538
+ }
8539
+ ]
8540
+ }
8541
+ }
8542
+ ],
8543
+ "responses": {
8544
+ "200": {
8545
+ "content": {
8546
+ "application/json": {
8547
+ "schema": {
8548
+ "$ref": "#/components/schemas/V1EndUserServiceResourcesQueriesSearch_AuthorizedServiceResources"
8549
+ }
8550
+ }
8551
+ },
8552
+ "description": "Authorized service resource metadata."
8553
+ },
8554
+ "401": {
8555
+ "description": "Unauthorized"
8556
+ },
8557
+ "403": {
8558
+ "description": "Forbidden"
8559
+ },
8560
+ "503": {
8561
+ "content": {
8562
+ "text/plain": {
8563
+ "schema": {
8564
+ "example": "Service Unavailable",
8565
+ "type": "string"
8566
+ }
8567
+ }
8568
+ },
8569
+ "description": "Service Unavailable, used when Dialogporten is in maintenance mode",
8570
+ "headers": {
8571
+ "Retry-After": {
8572
+ "description": "Delay before retrying the request. Datetime format RFC1123",
8573
+ "schema": {
8574
+ "type": "string"
8575
+ }
8576
+ }
8577
+ }
8578
+ }
8579
+ },
8580
+ "security": [
8581
+ {
8582
+ "JWTBearerAuth": [
8583
+ "digdir:dialogporten"
8584
+ ]
8585
+ }
8586
+ ],
8587
+ "summary": "Gets the service resources the authenticated end user is authorized to use.",
8588
+ "tags": [
8589
+ "Enduser"
8590
+ ]
8591
+ }
8592
+ },
8453
8593
  "/api/v1/metadata/limits": {
8454
8594
  "get": {
8455
8595
  "description": "Returns the active limits for EndUser and ServiceOwner search filters.",
@@ -11531,4 +11671,4 @@
11531
11671
  }
11532
11672
  }
11533
11673
  }
11534
- }
11674
+ }