{
  "openapi": "3.0.1",
  "info": {
    "title": "Personvern External API",
    "description": "\n## Generelt\n\nInneholder funksjonalitet for å ivareta innbyggeres personvernrettigheter på Helsenorge.no og i Helsesektoren generelt. Dette inkluderer blant annet:\n\n* Personverninnstillinger (reservasjoner, samtykker og tilgangsbegrensninger)\n* Inkluderingsbiletter \n* Hvem innbygger kan representere eller bli representert av (representasjonsforhold) på Helsenorge.no\n\n## Dokumentasjon\n\n* [Informasjon om Personvern APIer](https://helsenorge.atlassian.net/wiki/x/JIByFg)",
    "version": "external"
  },
  "paths": {
    "/v1/settinnbyggersinkludering": {
      "post": {
        "tags": [
          "Inkluderinger"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/settinnbyggersinkludering/v1": {
      "post": {
        "tags": [
          "Inkluderinger"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/innstillingdefinisjon/v1": {
      "post": {
        "tags": [
          "Innstilling definisjoner"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonRequest"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonRequest"
              }
            }
          }
        },
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonResponse"
                }
              }
            }
          }
        }
      },
      "patch": {
        "tags": [
          "Innstilling definisjoner"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonRequest"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonRequest"
              }
            }
          }
        },
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "204": {
            "description": "No Content",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonResponse"
                }
              }
            }
          }
        }
      }
    },
    "/personverninnstillinger/hentinnbyggerspiforpart/v2": {
      "post": {
        "tags": [
          "Innstillinger"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Request"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Request"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Request"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Request"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Response"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/personverninnstillinger/sjekkinnbyggerspistatus/v2": {
      "post": {
        "tags": [
          "Innstillinger"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Request"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Request"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Request"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Request"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Response"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/personverninnstillinger/hentinnbyggereaktivepifordefinisjon/v2": {
      "get": {
        "tags": [
          "Innstillinger"
        ],
        "parameters": [
          {
            "name": "definisjonGuid",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "partKode",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "pagingReference",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggereAktivePiForDefinisjonV2Response"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/personverninnstillinger/hentinnbyggersopplastedebevis/v2": {
      "post": {
        "tags": [
          "Innstillinger"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Request"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Request"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Request"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Request"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Response"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/personverninnstillinger/settinnbyggerspersonverninnstilling/v2": {
      "post": {
        "tags": [
          "Innstillinger"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SettInnbyggersPersonvernInnstillingV2Request"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SettInnbyggersPersonvernInnstillingV2Request"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SettInnbyggersPersonvernInnstillingV2Request"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.SettInnbyggersPersonvernInnstillingV2Request"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SettInnbyggersPersonvernInnstillingResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/part/v1": {
      "post": {
        "tags": [
          "Part"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePartRequest"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePartRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePartRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePartRequest"
              }
            }
          }
        },
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreatePartResponse"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Part"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePartRequest"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePartRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePartRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePartRequest"
              }
            }
          }
        },
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "204": {
            "description": "No Content",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.UpdatePartResponse"
                }
              }
            }
          }
        }
      }
    },
    "/representasjonsforhold/v1": {
      "get": {
        "tags": [
          "Representasjonsforhold"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.GetRepresentasjonsforholdV1Response"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v1/ungdomsapp": {
      "delete": {
        "tags": [
          "Ungdomsapp"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SletteUngdomsSamtykkeResponse"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Ungdomsapp"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreateUngdomsSamtykkeResponse"
                }
              }
            }
          }
        }
      }
    },
    "/ungdomsapp/v1": {
      "delete": {
        "tags": [
          "Ungdomsapp"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.SletteUngdomsSamtykkeResponse"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Ungdomsapp"
        ],
        "parameters": [
          {
            "name": "X-hn-isdebug",
            "in": "header",
            "schema": {
              "type": "Boolean"
            }
          }
        ],
        "responses": {
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Common.Http.ErrorResponse"
                }
              }
            }
          },
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.CreateUngdomsSamtykkeResponse"
                }
              }
            }
          }
        }
      }
    },
    "/health": {
      "get": {
        "tags": [
          "Health"
        ],
        "responses": {
          "200": {
            "description": "API is healthy"
          },
          "503": {
            "description": "API is not healthy"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "EHelse.Abstractions.Exceptions.ErrorCategory": {
        "enum": [
          "Unknown",
          "SessionExpired",
          "ClientValidationError",
          "ServerValidationError",
          "DataMappingError",
          "EndpointIsDown",
          "ConfigError",
          "EndpointUnknownError",
          "Critical"
        ],
        "type": "string",
        "x-enumNames": [
          "Unknown",
          "SessionExpired",
          "ClientValidationError",
          "ServerValidationError",
          "DataMappingError",
          "EndpointIsDown",
          "ConfigError",
          "EndpointUnknownError",
          "Critical"
        ]
      },
      "EHelse.Common.Api.Abstractions.Entities.BaseRequest": {
        "type": "object",
        "additionalProperties": false
      },
      "EHelse.Common.Api.Abstractions.Entities.BaseResponse": {
        "type": "object",
        "additionalProperties": false
      },
      "EHelse.Common.Http.ErrorResponse": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "nullable": true
          },
          "message": {
            "type": "string",
            "nullable": true
          },
          "errorCategory": {
            "$ref": "#/components/schemas/EHelse.Abstractions.Exceptions.ErrorCategory"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.CreatePartRequest": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "navn": {
            "type": "string",
            "nullable": true
          },
          "kortNavn": {
            "type": "string",
            "nullable": true
          },
          "beskrivelse": {
            "type": "string",
            "nullable": true
          },
          "uri": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.CreatePartResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonRequest": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "definisjonMalGuid": {
            "type": "string",
            "format": "uuid"
          },
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "navn": {
            "type": "string",
            "nullable": true
          },
          "beskrivelse": {
            "type": "string",
            "nullable": true
          },
          "visning": {
            "type": "string",
            "nullable": true
          },
          "fullstendigTekstInnhold": {
            "type": "string",
            "nullable": true
          },
          "kravTilLesingAvFullstendigTekst": {
            "type": "boolean"
          },
          "sortering": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "replikering": {
            "type": "boolean"
          },
          "relasjoner": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.DataTypes.PersonverninnstillingDefinisjoner.Relasjon"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.CreatePersonverninnstillingDefinisjonResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.CreateUngdomsSamtykkeResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.DataTypes.Inkludering.InkluderingType": {
        "enum": [
          "Inkludert",
          "Deltager",
          "Oppfort"
        ],
        "type": "string",
        "x-enumNames": [
          "Inkludert",
          "Deltager",
          "Oppfort"
        ]
      },
      "EHelse.Personvern.ExternalEntities.v1.DataTypes.PersonvernInnstilling.PersonvernInnstillingType": {
        "enum": [
          "samtykke",
          "reservasjon",
          "tilgangsbegrensning"
        ],
        "type": "string",
        "x-enumNames": [
          "samtykke",
          "reservasjon",
          "tilgangsbegrensning"
        ]
      },
      "EHelse.Personvern.ExternalEntities.v1.DataTypes.PersonverninnstillingDefinisjoner.Relasjon": {
        "type": "object",
        "properties": {
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "relasjonType": {
            "type": "string",
            "nullable": true
          },
          "beskrivelse": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.DataTypes.Representasjon.Representasjonsforhold": {
        "type": "object",
        "properties": {
          "eksternProfilGuid": {
            "type": "string",
            "format": "uuid"
          },
          "fornavn": {
            "type": "string",
            "nullable": true
          },
          "mellomnavn": {
            "type": "string",
            "nullable": true
          },
          "etternavn": {
            "type": "string",
            "nullable": true
          },
          "representasjonsforholdType": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.DataTypes.Representasjon.Tilleggsinfo": {
        "type": "object",
        "properties": {
          "harBarnMedAnnenAdresse": {
            "type": "boolean"
          },
          "harBarnOver11": {
            "type": "boolean"
          },
          "harBarnOver16": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.GetRepresentasjonsforholdV1Response": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "properties": {
          "representasjonsforhold": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.DataTypes.Representasjon.Representasjonsforhold"
            },
            "nullable": true
          },
          "tilleggsinfo": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.DataTypes.Representasjon.Tilleggsinfo"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.SettInkluderingRequest": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "personvernInnstillingDefinisjonId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "inkluderingType": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.DataTypes.Inkludering.InkluderingType"
          },
          "aktiv": {
            "type": "boolean",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.SettInnbyggersPersonvernInnstillingResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "properties": {
          "returKode": {
            "type": "string",
            "nullable": true
          },
          "instansEndret": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.SletteUngdomsSamtykkeResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.UpdatePartRequest": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "navn": {
            "type": "string",
            "nullable": true
          },
          "kortNavn": {
            "type": "string",
            "nullable": true
          },
          "beskrivelse": {
            "type": "string",
            "nullable": true
          },
          "uri": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.UpdatePartResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonRequest": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "visning": {
            "type": "string",
            "nullable": true
          },
          "kravTilLesingAvFullstendigTekst": {
            "type": "boolean",
            "nullable": true
          },
          "sortering": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "replikering": {
            "type": "boolean",
            "nullable": true
          },
          "status": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v1.UpdatePersonverninnstillingDefinisjonResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.DetaljertAngivelseFasteMetadata": {
        "type": "object",
        "properties": {
          "kategoriOpplysninger": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          },
          "rolleTilPasient": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.DetaljertAngivelseInnbyggerMetadata": {
        "type": "object",
        "properties": {
          "navngittHelseperson": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningData"
            },
            "nullable": true
          },
          "helseforetak": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningData"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.InnbyggerTidsbegrensning": {
        "type": "object",
        "properties": {
          "perioder": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.Periode"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.OmfangElement": {
        "type": "object",
        "properties": {
          "omfangKode": {
            "type": "string",
            "nullable": true
          },
          "logiskOmfang": {
            "type": "string",
            "nullable": true
          },
          "presisering": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.OpplastetBevisV2": {
        "type": "object",
        "properties": {
          "sekvensnummer": {
            "type": "integer",
            "format": "int32"
          },
          "regsitrertTidspunkt": {
            "type": "string",
            "format": "date-time"
          },
          "historisk": {
            "type": "boolean"
          },
          "signertBevisMimeType": {
            "type": "string",
            "nullable": true
          },
          "signertBevisInnhold": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.Periode": {
        "type": "object",
        "properties": {
          "fraDato": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "tilDato": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.PersonvernInnstillingHentInnbyggereV2": {
        "type": "object",
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "reInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonInnbyggerMetadata"
          },
          "saInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeInnbyggerMetadata"
          },
          "tbInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningInnbyggerMetadata"
          },
          "sekvensnummer": {
            "type": "integer",
            "format": "int32"
          },
          "opprettetTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "sistEndretTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.PersonvernInnstillingV2": {
        "type": "object",
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "definisjonGuid": {
            "type": "string",
            "nullable": true,
            "readOnly": true
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "typePi": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v1.DataTypes.PersonvernInnstilling.PersonvernInnstillingType"
          },
          "aktiv": {
            "type": "boolean"
          },
          "saMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeMetadata"
          },
          "reMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonMetadata"
          },
          "tbMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningMetadata"
          },
          "sekvensnummer": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "opprettetTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "sistEndretTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonFasteMetadata": {
        "type": "object",
        "properties": {
          "tidsbegrensning": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.Tidsbegrensning"
          },
          "omfangElementer": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.OmfangElement"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonInnbyggerMetadata": {
        "type": "object",
        "properties": {
          "tidsbegrensning": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.InnbyggerTidsbegrensning"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonMetadata": {
        "type": "object",
        "properties": {
          "reFasteMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonFasteMetadata"
          },
          "reInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonInnbyggerMetadata"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeFasteMetadata": {
        "type": "object",
        "properties": {
          "tidsbegrensning": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.Tidsbegrensning"
          },
          "omfangElementer": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.OmfangElement"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeInnbyggerMetadata": {
        "type": "object",
        "properties": {
          "tidsbegrensning": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.InnbyggerTidsbegrensning"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeMetadata": {
        "type": "object",
        "properties": {
          "saFasteMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeFasteMetadata"
          },
          "saInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeInnbyggerMetadata"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.Tidsbegrensning": {
        "type": "object",
        "properties": {
          "tidsbegrensetFra": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "tidsbegrensetTil": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningData": {
        "type": "object",
        "properties": {
          "nummer": {
            "type": "string",
            "nullable": true
          },
          "navn": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningFasteMetadata": {
        "type": "object",
        "properties": {
          "tidsbegrensning": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.Tidsbegrensning"
          },
          "omfangElementer": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningerOmfangElement"
            },
            "nullable": true
          },
          "detaljertAngivelse": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.DetaljertAngivelseFasteMetadata"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningInnbyggerMetadata": {
        "type": "object",
        "properties": {
          "tidsbegrensning": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.InnbyggerTidsbegrensning"
          },
          "detaljertAngivelse": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.DetaljertAngivelseInnbyggerMetadata"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningMetadata": {
        "type": "object",
        "properties": {
          "tbFasteMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningFasteMetadata"
          },
          "tbInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningInnbyggerMetadata"
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningerOmfangElement": {
        "type": "object",
        "properties": {
          "omfangKode": {
            "type": "string",
            "nullable": true
          },
          "logiskOmfang": {
            "type": "string",
            "nullable": true
          },
          "typeAngivelse": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.HentInnbyggereAktivePiForDefinisjonV2Response": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "properties": {
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "typePi": {
            "type": "string",
            "nullable": true
          },
          "pagingReference": {
            "type": "integer",
            "format": "int32"
          },
          "saFasteMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeFasteMetadata"
          },
          "reFasteMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonFasteMetadata"
          },
          "tbFasteMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningFasteMetadata"
          },
          "personvernInnstillinger": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.PersonvernInnstillingHentInnbyggereV2"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Request": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "definisjonGuid": {
            "type": "string",
            "nullable": true
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.HentInnbyggersOpplastedeBevisV2Response": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "typePi": {
            "type": "string",
            "nullable": true
          },
          "aktiv": {
            "type": "boolean"
          },
          "sekvensnummer": {
            "type": "integer",
            "format": "int32"
          },
          "sistEndretTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "opplastedeBevis": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.OpplastetBevisV2"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Request": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.HentInnbyggersPiV2Response": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "properties": {
          "funnet": {
            "type": "boolean",
            "readOnly": true
          },
          "personvernInnstillinger": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.PersonvernInnstillingV2"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.SettInnbyggersPersonvernInnstillingV2Request": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "typePi": {
            "type": "string",
            "nullable": true
          },
          "aktiv": {
            "type": "boolean"
          },
          "tidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "saInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeInnbyggerMetadata"
          },
          "reInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonInnbyggerMetadata"
          },
          "tbInnbyggerMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningInnbyggerMetadata"
          },
          "signertBevisMimeType": {
            "type": "string",
            "nullable": true
          },
          "signertBevisInnhold": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Request": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseRequest"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "EHelse.Personvern.ExternalEntities.v2.SjekkInnbyggersPiStatusV2Response": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/EHelse.Common.Api.Abstractions.Entities.BaseResponse"
          }
        ],
        "properties": {
          "innbyggerFnr": {
            "type": "string",
            "nullable": true
          },
          "definisjonGuid": {
            "type": "string",
            "format": "uuid"
          },
          "definisjonNavn": {
            "type": "string",
            "nullable": true
          },
          "partKode": {
            "type": "string",
            "nullable": true
          },
          "typePi": {
            "type": "string",
            "nullable": true,
            "readOnly": true
          },
          "aktiv": {
            "type": "boolean"
          },
          "sekvensnummer": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "opprettetTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "sistEndretTidspunkt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "SaMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.SamtykkeMetadata"
          },
          "ReMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.ReservasjonMetadata"
          },
          "TbMetadata": {
            "$ref": "#/components/schemas/EHelse.Personvern.ExternalEntities.v2.DataTypes.TilgangsbegrensningMetadata"
          }
        },
        "additionalProperties": false
      }
    },
    "securitySchemes": {
      "JWT": {
        "type": "apiKey",
        "description": "JWT Authorization header using the Bearer scheme. Example: \"Authorization: Bearer {token}\"",
        "name": "Authorization",
        "in": "header"
      }
    }
  },
  "security": [
    {
      "JWT": []
    }
  ],
  "servers": [
    {
      "url": "/personvern"
    }
  ]
}