{
  "openapi": "3.0.4",
  "info": {
    "title": "Vsp.User",
    "description": "",
    "version": "v1"
  },
  "servers": [
    {
      "url": "/user"
    }
  ],
  "paths": {
    "/providers/employers/{employerId}/departmentuserconfigurations": {
      "get": {
        "tags": [
          "Department user configurations"
        ],
        "summary": "Department user configurations.",
        "description": "**Activity name**:\n  - `GetDepartmentUserConfigurationsByEmployerId`\n\nRetrieves a list of the department user configurations by employer id.\nEach department is returned with its assigned department manager, enriched with access status and login information.",
        "parameters": [
          {
            "name": "employerId",
            "in": "path",
            "description": "The unique identifier of the employer.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "example": "3b34f479-7b46-4944-b579-acee7257e0cc"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "text/csv": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.BadRequestListResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.UnauthorizedResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.ForbiddenResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found"
          },
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/providers/employers/{employerId}/employeruserconfigurations": {
      "get": {
        "tags": [
          "Employer user configurations"
        ],
        "summary": "Employer user configuration overview.",
        "description": "**Activity name**:\n  - `GetEmployerUserConfigurationsByEmployerId`\n\nRetrieves a list of employer user configurations by employer id.\nEach employer user is returned with enriched access status and login information, and associated responsibilities.",
        "parameters": [
          {
            "name": "employerId",
            "in": "path",
            "description": "The unique identifier of the employer.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "example": "3b34f479-7b46-4944-b579-acee7257e0cc"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "text/csv": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              },
              "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.BadRequestListResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.UnauthorizedResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.ForbiddenResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found"
          },
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/RecommendedAction/{employerId}": {
      "get": {
        "tags": [
          "RecommendedAction"
        ],
        "parameters": [
          {
            "name": "employerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Vsp.ApiBase.OpenApi.Examples.BadRequestListResponse": {
        "type": "object",
        "properties": {
          "totalSize": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32"
          },
          "currentPage": {
            "type": "integer",
            "format": "int32"
          },
          "version": {
            "$ref": "#/components/schemas/Vsp.Infrastructure.ResourceVersionModel"
          },
          "messages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.ApiBase.OpenApi.Examples.BadRequestOperationMessage"
            },
            "nullable": true
          },
          "_embedded": {
            "type": "array",
            "items": { },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Vsp.ApiBase.OpenApi.Examples.BadRequestOperationMessage": {
        "type": "object",
        "properties": {
          "messageCode": {
            "type": "string",
            "nullable": true
          },
          "type": {
            "type": "string"
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "properties": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Vsp.ApiBase.OpenApi.Examples.ForbiddenResponse": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string"
          },
          "errorCode": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Vsp.ApiBase.OpenApi.Examples.UnauthorizedResponse": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]": {
        "type": "object",
        "properties": {
          "totalSize": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32"
          },
          "currentPage": {
            "type": "integer",
            "format": "int32"
          },
          "version": {
            "$ref": "#/components/schemas/Vsp.Infrastructure.ResourceVersionModel"
          },
          "messages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.Infrastructure.OperationMessage"
            },
            "nullable": true
          },
          "_embedded": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Vsp.Infrastructure.ListResult`1[[Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel, Vsp.User.Domain, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]": {
        "type": "object",
        "properties": {
          "totalSize": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32"
          },
          "currentPage": {
            "type": "integer",
            "format": "int32"
          },
          "version": {
            "$ref": "#/components/schemas/Vsp.Infrastructure.ResourceVersionModel"
          },
          "messages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.Infrastructure.OperationMessage"
            },
            "nullable": true
          },
          "_embedded": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Vsp.Infrastructure.OperationMessage": {
        "type": "object",
        "properties": {
          "exception": {
            "nullable": true
          },
          "messageCode": {
            "type": "string",
            "nullable": true
          },
          "messageType": {
            "enum": [
              0,
              1,
              2,
              3,
              4,
              5,
              6
            ],
            "type": "integer",
            "format": "int32"
          },
          "type": {
            "type": "string"
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "id": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "code": {
            "type": "integer",
            "format": "int32"
          },
          "properties": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Vsp.Infrastructure.ResourceVersionModel": {
        "type": "object",
        "properties": {
          "obsoleteDate": {
            "type": "string",
            "format": "date",
            "nullable": true
          },
          "resourceVersion": {
            "type": "string",
            "format": "date"
          }
        },
        "additionalProperties": false
      },
      "Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.ArchiveModel": {
        "type": "object",
        "properties": {
          "isArchived": {
            "type": "boolean",
            "description": "The indicator whether the entity is archived, this is a calculated field where IsArchived = ArchivedDate is before or on Today.",
            "example": true
          },
          "archivedDate": {
            "type": "string",
            "description": "The date on which the entity was or is going to be archived.",
            "format": "date",
            "nullable": true,
            "example": "2026-01-01"
          }
        },
        "additionalProperties": false,
        "description": "Represents the archive details of an entity."
      },
      "Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentManagerModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier of the user.",
            "format": "uuid",
            "example": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
          },
          "initials": {
            "type": "string",
            "description": "The initials of the user.",
            "nullable": true,
            "example": "J.D."
          },
          "prefix": {
            "type": "string",
            "description": "The prefix of the user's last name.",
            "nullable": true,
            "example": "van"
          },
          "lastName": {
            "type": "string",
            "description": "The last name of the user.",
            "nullable": true,
            "example": "Jansen"
          },
          "formattedName": {
            "type": "string",
            "description": "The formatted full name of the user.",
            "nullable": true,
            "example": "J.D. van Jansen"
          },
          "emailAddress": {
            "type": "string",
            "description": "The email address of the user.",
            "nullable": true,
            "example": "j.d.jansen@contoso.com"
          },
          "username": {
            "type": "string",
            "description": "The username of the user.",
            "nullable": true,
            "example": "jdjansen"
          },
          "accessStatus": {
            "$ref": "#/components/schemas/Vsp.User.Domain.Shared.Models.KeyValueModel"
          },
          "dateTimeLastLogin": {
            "type": "string",
            "description": "The date and time of the last login of the user.",
            "format": "date-time",
            "nullable": true,
            "example": "2024-01-01T08:30:00Z"
          },
          "hasAccessToSubDepartments": {
            "type": "boolean",
            "description": "The indicator whether the department manager has access to sub-departments.",
            "example": true
          },
          "userResponsibilities": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.User.Domain.Shared.Models.UserResponsibilityModel"
            },
            "description": "The user responsibilities assigned to the department manager.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "Represents a department manager."
      },
      "Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier of the department.",
            "format": "uuid",
            "example": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
          },
          "code": {
            "type": "integer",
            "description": "The numeric code of the department.",
            "format": "int32",
            "example": 1
          },
          "description": {
            "type": "string",
            "description": "The description of the department.",
            "nullable": true,
            "example": "Human Resources"
          },
          "subDepartmentOf": {
            "$ref": "#/components/schemas/Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.SubDepartmentModel"
          },
          "archive": {
            "$ref": "#/components/schemas/Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.ArchiveModel"
          },
          "numberOfActiveEmployments": {
            "type": "integer",
            "description": "The number of active employments within the department.",
            "format": "int32",
            "example": 12
          }
        },
        "additionalProperties": false,
        "description": "Represents a department."
      },
      "Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentUserConfigurationModel": {
        "type": "object",
        "properties": {
          "department": {
            "$ref": "#/components/schemas/Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentModel"
          },
          "departmentManager": {
            "$ref": "#/components/schemas/Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.DepartmentManagerModel"
          }
        },
        "additionalProperties": false,
        "description": "Represents a department user configuration overview, combining a department with an optional department manager."
      },
      "Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.SubDepartmentModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier of the sub-department.",
            "format": "uuid"
          },
          "archive": {
            "$ref": "#/components/schemas/Vsp.User.Domain.DepartmentUserConfiguration.v20180101.Models.ArchiveModel"
          }
        },
        "additionalProperties": false,
        "description": "Represents a sub-department reference."
      },
      "Vsp.User.Domain.EmployerUserConfiguration.v20180101.Models.EmployerUserConfigurationModel": {
        "type": "object",
        "properties": {
          "employerUser": {
            "$ref": "#/components/schemas/Vsp.User.Domain.Shared.Models.UserMinimizedModel"
          },
          "userResponsibilities": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vsp.User.Domain.Shared.Models.UserResponsibilityModel"
            },
            "description": "The user responsibilities assigned to the user.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "Overview model for employer user configuration."
      },
      "Vsp.User.Domain.Shared.Models.KeyValueModel": {
        "type": "object",
        "properties": {
          "key": {
            "type": "integer",
            "description": "The numeric key.",
            "format": "int32",
            "example": 0
          },
          "value": {
            "type": "string",
            "description": "The descriptive value.",
            "nullable": true,
            "example": "HasAccessToClient"
          }
        },
        "additionalProperties": false,
        "description": "Represents a key-value pair with an integer key and a string value."
      },
      "Vsp.User.Domain.Shared.Models.UserMinimizedModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier of the user.",
            "format": "uuid",
            "example": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
          },
          "initials": {
            "type": "string",
            "description": "The initials of the user.",
            "nullable": true,
            "example": "J.D."
          },
          "prefix": {
            "type": "string",
            "description": "The prefix of the user's last name.",
            "nullable": true,
            "example": "van"
          },
          "lastName": {
            "type": "string",
            "description": "The last name of the user.",
            "nullable": true,
            "example": "Jansen"
          },
          "formattedName": {
            "type": "string",
            "description": "The formatted full name of the user.",
            "nullable": true,
            "example": "J.D. van Jansen"
          },
          "emailAddress": {
            "type": "string",
            "description": "The email address of the user.",
            "nullable": true,
            "example": "j.d.jansen@contoso.com"
          },
          "username": {
            "type": "string",
            "description": "The username of the user.",
            "nullable": true,
            "example": "jdjansen"
          },
          "accessStatus": {
            "$ref": "#/components/schemas/Vsp.User.Domain.Shared.Models.KeyValueModel"
          },
          "dateTimeLastLogin": {
            "type": "string",
            "description": "The date and time of the last login of the user.",
            "format": "date-time",
            "nullable": true,
            "example": "2024-01-01T08:30:00Z"
          }
        },
        "additionalProperties": false,
        "description": "Represents a minimized user model with common properties shared across user types."
      },
      "Vsp.User.Domain.Shared.Models.UserResponsibilityModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier of the responsibility.",
            "format": "uuid",
            "example": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
          },
          "name": {
            "type": "string",
            "description": "The name of the responsibility.",
            "nullable": true,
            "example": "Budgetbeheer"
          },
          "deviatingHandler": {
            "type": "string",
            "description": "The deviating handler assigned to the responsibility.",
            "nullable": true,
            "example": "Piet de Vries"
          }
        },
        "additionalProperties": false,
        "description": "Represents a user responsibility."
      }
    },
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "flows": {
          "password": {
            "tokenUrl": "https://oauth.loket.nl/token",
            "scopes": { }
          }
        }
      },
      "Bearer": {
        "type": "apiKey",
        "description": "Authorization header using the Bearer scheme. \n Enter 'Bearer' [space] and then your token in the text input below.\nExample: \"Bearer 12345abcdef\"",
        "name": "Authorization",
        "in": "header"
      }
    }
  },
  "security": [
    {
      "oauth2": [ ]
    },
    {
      "Bearer": [ ]
    }
  ],
  "tags": [
    {
      "name": "Department user configurations",
      "description": "Department user configurations (NL: Afdelingmanager configuraties)"
    },
    {
      "name": "Employer user configurations",
      "description": "Employer user configurations"
    }
  ]
}