mirror of
https://github.com/siop-spelev/siop2.git
synced 2026-08-08 12:41:54 +00:00
- migration : Asset.underContract + WorkOrder.periodKey avec unicité [assetId, periodKey] — l'idempotence de la génération est EN BASE (deux appels concurrents ne doublent jamais une grille) - génération : une grille par appareil sous contrat, périodicités ancrées sur la mise en service (mensuelles toujours dues), premier contrôle (toutes les tâches) pour un appareil sans historique, échéance fin de mois, événement GENERATED ; déclenchement manuel (cron au durcissement) - gabarits administrables (désactivé = exclu des générations suivantes) ; GET /preventive/status (générées, terminées, en retard, premiers contrôles) - compteurs : GET meters (2 compteurs, récents d'abord) ; relevé strictement croissant, refus motivé sinon - contrat +7 opérations (48) ; 50 tests verts (94,7 % / 78 %) ; smoke test prod : juillet généré (9 grilles, 8 premiers contrôles), 2e appel à zéro Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
5457 lines
158 KiB
JSON
5457 lines
158 KiB
JSON
{
|
||
"openapi": "3.1.0",
|
||
"info": {
|
||
"title": "SIOP V2 API",
|
||
"version": "0.1.0",
|
||
"description": "GMAO ascenseurs — contrat R0 (auth, démo-login ADR-002, profil, santé). Généré depuis packages/shared/src/contract.ts — NE PAS ÉDITER À LA MAIN."
|
||
},
|
||
"paths": {
|
||
"/auth/login": {
|
||
"post": {
|
||
"operationId": "login",
|
||
"summary": "Connexion par e-mail et mot de passe",
|
||
"tags": [
|
||
"auth"
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/LoginRequest"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Jeton émis",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AuthResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"401": {
|
||
"description": "Identifiants invalides ou compte inactif"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/auth/demo-accounts": {
|
||
"get": {
|
||
"operationId": "listDemoAccounts",
|
||
"summary": "Comptes de démonstration (ADR-002 — jamais de secret)",
|
||
"tags": [
|
||
"auth",
|
||
"demo"
|
||
],
|
||
"x-demo-only": true,
|
||
"description": "ADR-002 : cette route est absente (404) quand DEMO_MODE n’est pas actif.",
|
||
"responses": {
|
||
"200": {
|
||
"description": "Comptes isDemo actifs",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/DemoAccountsResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/auth/demo-login": {
|
||
"post": {
|
||
"operationId": "demoLogin",
|
||
"summary": "Connexion 1 clic sur un compte de démonstration (ADR-002)",
|
||
"tags": [
|
||
"auth",
|
||
"demo"
|
||
],
|
||
"x-demo-only": true,
|
||
"description": "ADR-002 : cette route est absente (404) quand DEMO_MODE n’est pas actif.",
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/DemoLoginRequest"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Jeton émis",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AuthResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"403": {
|
||
"description": "Le compte n’est pas un compte de démonstration"
|
||
},
|
||
"404": {
|
||
"description": "Compte inconnu"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/users/me": {
|
||
"get": {
|
||
"operationId": "getMe",
|
||
"summary": "Profil courant + matrice de permissions du rôle",
|
||
"tags": [
|
||
"users"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Profil",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/MeResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"401": {
|
||
"description": "Non authentifié"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/auth/activate": {
|
||
"post": {
|
||
"operationId": "activateAccount",
|
||
"summary": "Activer un compte invité (lien 7 jours) — connecte directement",
|
||
"tags": [
|
||
"auth"
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ActivateRequest"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Compte activé et connecté",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AuthResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"400": {
|
||
"description": "Lien invalide ou expiré"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/categories": {
|
||
"get": {
|
||
"operationId": "listCategories",
|
||
"summary": "Référentiels administrables (catégories d’équipement, types d’organes)",
|
||
"tags": [
|
||
"categories"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/CategoriesResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createCategory",
|
||
"summary": "Ajouter une catégorie",
|
||
"tags": [
|
||
"categories"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/CategoryCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créée",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/Category"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Nom déjà utilisé pour ce type"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/categories/{id}": {
|
||
"patch": {
|
||
"operationId": "updateCategory",
|
||
"summary": "Renommer ou (dés)activer — jamais de suppression si utilisée",
|
||
"tags": [
|
||
"categories"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/CategoryUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mise à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/Category"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/locations": {
|
||
"get": {
|
||
"operationId": "listLocations",
|
||
"summary": "Sites et zones (liste plate, le client construit l’arbre)",
|
||
"tags": [
|
||
"locations"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/LocationsResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createLocation",
|
||
"summary": "Créer un site (sans parent) ou une zone (profondeur max 2)",
|
||
"tags": [
|
||
"locations"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/LocationCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créé",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/Location"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"400": {
|
||
"description": "Hiérarchie trop profonde"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/locations/{id}": {
|
||
"patch": {
|
||
"operationId": "updateLocation",
|
||
"summary": "Modifier un emplacement",
|
||
"tags": [
|
||
"locations"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/LocationUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mis à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/Location"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnu"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/assets": {
|
||
"get": {
|
||
"operationId": "listAssets",
|
||
"summary": "Inventaire des appareils",
|
||
"tags": [
|
||
"assets"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetsResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createAsset",
|
||
"summary": "Créer un appareil (avec ses organes) — le QR découle de la référence",
|
||
"tags": [
|
||
"assets"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créé",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Référence déjà utilisée"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/assets/{id}": {
|
||
"get": {
|
||
"operationId": "getAsset",
|
||
"summary": "Fiche appareil (identité + organes)",
|
||
"tags": [
|
||
"assets"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Fiche",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnu"
|
||
}
|
||
}
|
||
},
|
||
"patch": {
|
||
"operationId": "updateAsset",
|
||
"summary": "Modifier un appareil (dont son statut d’équipement)",
|
||
"tags": [
|
||
"assets"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mis à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnu"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/assets/{id}/components": {
|
||
"post": {
|
||
"operationId": "addAssetComponent",
|
||
"summary": "Ajouter un organe (jamais d’emplacement propre)",
|
||
"tags": [
|
||
"assets"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetComponentCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Ajouté",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssetComponent"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"400": {
|
||
"description": "Le type choisi n’est pas un type d’organe"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/assets/{id}/components/{componentId}": {
|
||
"delete": {
|
||
"operationId": "removeAssetComponent",
|
||
"summary": "Retirer un organe",
|
||
"tags": [
|
||
"assets"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
},
|
||
{
|
||
"name": "componentId",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"204": {
|
||
"description": "Retiré"
|
||
},
|
||
"404": {
|
||
"description": "Inconnu"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/teams": {
|
||
"get": {
|
||
"operationId": "listTeams",
|
||
"summary": "Équipes et leurs membres",
|
||
"tags": [
|
||
"teams"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TeamsResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createTeam",
|
||
"summary": "Créer une équipe",
|
||
"tags": [
|
||
"teams"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TeamCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créée",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/Team"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Nom déjà utilisé"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/teams/{id}": {
|
||
"patch": {
|
||
"operationId": "updateTeam",
|
||
"summary": "Modifier une équipe (nom, description, membres)",
|
||
"tags": [
|
||
"teams"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TeamUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mise à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/Team"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/users": {
|
||
"get": {
|
||
"operationId": "listUsers",
|
||
"summary": "Personnes (statut dérivé : actif / invité / désactivé)",
|
||
"tags": [
|
||
"users"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/UsersResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/roles": {
|
||
"get": {
|
||
"operationId": "listRoles",
|
||
"summary": "Les 7 rôles (pour l’invitation)",
|
||
"tags": [
|
||
"users"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RolesResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/users/invitations": {
|
||
"post": {
|
||
"operationId": "inviteUser",
|
||
"summary": "Inviter — crée le compte inactif et émet le lien d’activation (7 j)",
|
||
"tags": [
|
||
"users"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/InvitationCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Invitation émise",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/InvitationResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Email déjà utilisé"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/users/{id}/invitation": {
|
||
"post": {
|
||
"operationId": "resendInvitation",
|
||
"summary": "Régénérer le lien d’activation d’un compte non activé",
|
||
"tags": [
|
||
"users"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"201": {
|
||
"description": "Nouveau lien",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/InvitationResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Compte déjà activé"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/users/{id}": {
|
||
"patch": {
|
||
"operationId": "updateUser",
|
||
"summary": "Modifier une personne (rôle, équipes, activation du compte)",
|
||
"tags": [
|
||
"users"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/UserUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mise à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/UserAdmin"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/preventive/templates": {
|
||
"get": {
|
||
"operationId": "listTaskTemplates",
|
||
"summary": "Gabarits de tâches du préventif (périodicité en mois)",
|
||
"tags": [
|
||
"preventive"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TaskTemplatesResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createTaskTemplate",
|
||
"summary": "Ajouter un gabarit",
|
||
"tags": [
|
||
"preventive"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TaskTemplateCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créé",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TaskTemplate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Libellé déjà utilisé"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/preventive/templates/{id}": {
|
||
"patch": {
|
||
"operationId": "updateTaskTemplate",
|
||
"summary": "Modifier / (dés)activer un gabarit — jamais de suppression si utilisé",
|
||
"tags": [
|
||
"preventive"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TaskTemplateUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mis à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TaskTemplate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnu"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/preventive/generate": {
|
||
"post": {
|
||
"operationId": "generatePreventive",
|
||
"summary": "Générer la grille du mois — IDEMPOTENT (regénérer ne double rien)",
|
||
"tags": [
|
||
"preventive"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/PreventiveGenerate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Résumé de génération",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/PreventiveGenerationResult"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/preventive/status": {
|
||
"get": {
|
||
"operationId": "getPreventiveStatus",
|
||
"summary": "État du mois courant (générées, terminées, en retard, premiers contrôles)",
|
||
"tags": [
|
||
"preventive"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "État",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/PreventiveStatus"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/assets/{id}/meters": {
|
||
"get": {
|
||
"operationId": "getAssetMeters",
|
||
"summary": "Compteurs de l’appareil (relevés récents d’abord)",
|
||
"tags": [
|
||
"meters"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Compteurs",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/MetersResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Appareil inconnu"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/assets/{id}/meter-readings": {
|
||
"post": {
|
||
"operationId": "addMeterReading",
|
||
"summary": "Enregistrer un relevé — strictement croissant",
|
||
"tags": [
|
||
"meters"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/MeterReadingCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Relevé enregistré",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/MetersResponse"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"400": {
|
||
"description": "Relevé inférieur ou égal au précédent"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders": {
|
||
"get": {
|
||
"operationId": "listWorkOrders",
|
||
"summary": "Ordres de travail (sans « voir autre » : seulement les siens)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrdersResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createWorkOrder",
|
||
"summary": "Créer un OT (statut Ouvert)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créé",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders/{id}": {
|
||
"get": {
|
||
"operationId": "getWorkOrder",
|
||
"summary": "Fiche OT (activité, checklist, bilan, transitions autorisées, blocages de clôture)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Fiche",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnu (ou hors de son périmètre)"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders/{id}/transition": {
|
||
"post": {
|
||
"operationId": "transitionWorkOrder",
|
||
"summary": "Changer l’état (machine à états stricte ; DONE exige bilan + checklist)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/TransitionRequest"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "État changé",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Transition interdite ou clôture bloquée (garde)"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders/{id}/comments": {
|
||
"post": {
|
||
"operationId": "commentWorkOrder",
|
||
"summary": "Commenter (activité chronologique)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/CommentCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Commentaire ajouté",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders/{id}/assignees": {
|
||
"put": {
|
||
"operationId": "setWorkOrderAssignees",
|
||
"summary": "Assigner (remplace la liste)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/AssigneesUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Assignés",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders/{id}/report": {
|
||
"put": {
|
||
"operationId": "upsertWorkOrderReport",
|
||
"summary": "Renseigner le bilan codé (null efface un champ)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ReportUpsert"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Bilan enregistré",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"400": {
|
||
"description": "Valeur hors référentiel du champ"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/work-orders/{id}/checklist/{itemId}": {
|
||
"patch": {
|
||
"operationId": "patchChecklistItem",
|
||
"summary": "Régler une tâche de la grille (Fait / N-A / à faire)",
|
||
"tags": [
|
||
"work-orders"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
},
|
||
{
|
||
"name": "itemId",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ChecklistPatch"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Tâche réglée",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ChecklistItem"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Tâche inconnue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/requests": {
|
||
"get": {
|
||
"operationId": "listRequests",
|
||
"summary": "Demandes (sans « voir autre » : seulement les siennes)",
|
||
"tags": [
|
||
"requests"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RequestsResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createRequest",
|
||
"summary": "Signaler (interne — le portail public QR arrive en R2.4)",
|
||
"tags": [
|
||
"requests"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RequestCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Demande créée",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RequestSummary"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/requests/{id}/approve": {
|
||
"post": {
|
||
"operationId": "approveRequest",
|
||
"summary": "Approuver → crée l’OT lié (1-1, jamais de doublon)",
|
||
"tags": [
|
||
"requests"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RequestApprove"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "OT créé et lié",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/WorkOrderDetail"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Demande déjà traitée"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/requests/{id}/reject": {
|
||
"post": {
|
||
"operationId": "rejectRequest",
|
||
"summary": "Rejeter — motif obligatoire, lisible côté demandeur",
|
||
"tags": [
|
||
"requests"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RequestReject"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Rejetée",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/RequestSummary"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Demande déjà traitée"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/reference-values": {
|
||
"get": {
|
||
"operationId": "listReferenceValues",
|
||
"summary": "Référentiels du bilan codé (6 champs)",
|
||
"tags": [
|
||
"reference-values"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "Liste",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ReferenceValuesResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"post": {
|
||
"operationId": "createReferenceValue",
|
||
"summary": "Ajouter une valeur de référentiel",
|
||
"tags": [
|
||
"reference-values"
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ReferenceValueCreate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"201": {
|
||
"description": "Créée",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ReferenceValue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"409": {
|
||
"description": "Libellé déjà présent pour ce champ"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/reference-values/{id}": {
|
||
"patch": {
|
||
"operationId": "updateReferenceValue",
|
||
"summary": "Renommer ou (dés)activer — jamais de suppression si utilisée",
|
||
"tags": [
|
||
"reference-values"
|
||
],
|
||
"parameters": [
|
||
{
|
||
"name": "id",
|
||
"in": "path",
|
||
"required": true,
|
||
"schema": {
|
||
"type": "string",
|
||
"format": "uuid"
|
||
}
|
||
}
|
||
],
|
||
"security": [
|
||
{
|
||
"bearerAuth": []
|
||
}
|
||
],
|
||
"requestBody": {
|
||
"required": true,
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ReferenceValueUpdate"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"responses": {
|
||
"200": {
|
||
"description": "Mise à jour",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/ReferenceValue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"404": {
|
||
"description": "Inconnue"
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"/health": {
|
||
"get": {
|
||
"operationId": "getHealth",
|
||
"summary": "État des dépendances (base, Redis, stockage)",
|
||
"tags": [
|
||
"health"
|
||
],
|
||
"responses": {
|
||
"200": {
|
||
"description": "État agrégé",
|
||
"content": {
|
||
"application/json": {
|
||
"schema": {
|
||
"$ref": "#/components/schemas/HealthResponse"
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"components": {
|
||
"schemas": {
|
||
"AuthResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"accessToken": {
|
||
"type": "string"
|
||
},
|
||
"user": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"email": {
|
||
"type": "string",
|
||
"format": "email",
|
||
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"role": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string",
|
||
"enum": [
|
||
"Administrateur",
|
||
"Dispatcher",
|
||
"Technicien",
|
||
"Technicien limité",
|
||
"Gestionnaire",
|
||
"Demandeur",
|
||
"Vue seule"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"isDemo": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"email",
|
||
"displayName",
|
||
"role",
|
||
"isDemo"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"required": [
|
||
"accessToken",
|
||
"user"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"LoginRequest": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"email": {
|
||
"type": "string",
|
||
"format": "email",
|
||
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
|
||
},
|
||
"password": {
|
||
"type": "string",
|
||
"minLength": 1
|
||
}
|
||
},
|
||
"required": [
|
||
"email",
|
||
"password"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"DemoAccountsResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"accounts": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"roleName": {
|
||
"type": "string",
|
||
"enum": [
|
||
"Administrateur",
|
||
"Dispatcher",
|
||
"Technicien",
|
||
"Technicien limité",
|
||
"Gestionnaire",
|
||
"Demandeur",
|
||
"Vue seule"
|
||
]
|
||
},
|
||
"initials": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 3
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"roleName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"accounts"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"DemoLoginRequest": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"userId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
},
|
||
"required": [
|
||
"userId"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"MeResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"email": {
|
||
"type": "string",
|
||
"format": "email",
|
||
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"role": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string",
|
||
"enum": [
|
||
"Administrateur",
|
||
"Dispatcher",
|
||
"Technicien",
|
||
"Technicien limité",
|
||
"Gestionnaire",
|
||
"Demandeur",
|
||
"Vue seule"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"isDemo": {
|
||
"type": "boolean"
|
||
},
|
||
"permissions": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"objectCategory": {
|
||
"type": "string",
|
||
"enum": [
|
||
"WORK_ORDERS",
|
||
"REQUESTS",
|
||
"ASSETS",
|
||
"LOCATIONS",
|
||
"METERS",
|
||
"PARTS",
|
||
"PURCHASE_ORDERS",
|
||
"PEOPLE_TEAMS",
|
||
"ANALYTICS",
|
||
"SETTINGS"
|
||
]
|
||
},
|
||
"canView": {
|
||
"type": "boolean"
|
||
},
|
||
"canViewOther": {
|
||
"type": "boolean"
|
||
},
|
||
"canCreate": {
|
||
"type": "boolean"
|
||
},
|
||
"canEdit": {
|
||
"type": "boolean"
|
||
},
|
||
"canDelete": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"required": [
|
||
"objectCategory",
|
||
"canView",
|
||
"canViewOther",
|
||
"canCreate",
|
||
"canEdit",
|
||
"canDelete"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"email",
|
||
"displayName",
|
||
"role",
|
||
"isDemo",
|
||
"permissions"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ActivateRequest": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"token": {
|
||
"type": "string",
|
||
"minLength": 10
|
||
},
|
||
"password": {
|
||
"type": "string",
|
||
"minLength": 8
|
||
}
|
||
},
|
||
"required": [
|
||
"token",
|
||
"password"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"CategoriesResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"categories": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"kind": {
|
||
"type": "string",
|
||
"enum": [
|
||
"EQUIPMENT",
|
||
"COMPONENT_TYPE"
|
||
]
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
},
|
||
"usageCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"kind",
|
||
"name",
|
||
"isActive",
|
||
"usageCount"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"categories"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"Category": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"kind": {
|
||
"type": "string",
|
||
"enum": [
|
||
"EQUIPMENT",
|
||
"COMPONENT_TYPE"
|
||
]
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
},
|
||
"usageCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"kind",
|
||
"name",
|
||
"isActive",
|
||
"usageCount"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"CategoryCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"kind": {
|
||
"type": "string",
|
||
"enum": [
|
||
"EQUIPMENT",
|
||
"COMPONENT_TYPE"
|
||
]
|
||
},
|
||
"name": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 80
|
||
}
|
||
},
|
||
"required": [
|
||
"kind",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"CategoryUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 80
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"LocationsResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"locations": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
},
|
||
"parentId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"address": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"city": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"guardianName": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"guardianPhone": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"latitude": {
|
||
"anyOf": [
|
||
{
|
||
"type": "number"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"longitude": {
|
||
"anyOf": [
|
||
{
|
||
"type": "number"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"assetCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name",
|
||
"parentId",
|
||
"address",
|
||
"city",
|
||
"guardianName",
|
||
"guardianPhone",
|
||
"latitude",
|
||
"longitude",
|
||
"assetCount"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"locations"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"Location": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
},
|
||
"parentId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"address": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"city": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"guardianName": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"guardianPhone": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"latitude": {
|
||
"anyOf": [
|
||
{
|
||
"type": "number"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"longitude": {
|
||
"anyOf": [
|
||
{
|
||
"type": "number"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"assetCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name",
|
||
"parentId",
|
||
"address",
|
||
"city",
|
||
"guardianName",
|
||
"guardianPhone",
|
||
"latitude",
|
||
"longitude",
|
||
"assetCount"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"LocationCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 120
|
||
},
|
||
"parentId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"address": {
|
||
"type": "string",
|
||
"maxLength": 200
|
||
},
|
||
"city": {
|
||
"type": "string",
|
||
"maxLength": 80
|
||
},
|
||
"guardianName": {
|
||
"type": "string",
|
||
"maxLength": 120
|
||
},
|
||
"guardianPhone": {
|
||
"type": "string",
|
||
"maxLength": 40
|
||
},
|
||
"latitude": {
|
||
"type": "number",
|
||
"minimum": -90,
|
||
"maximum": 90
|
||
},
|
||
"longitude": {
|
||
"type": "number",
|
||
"minimum": -180,
|
||
"maximum": 180
|
||
}
|
||
},
|
||
"required": [
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"LocationUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 120
|
||
},
|
||
"parentId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"address": {
|
||
"type": "string",
|
||
"maxLength": 200
|
||
},
|
||
"city": {
|
||
"type": "string",
|
||
"maxLength": 80
|
||
},
|
||
"guardianName": {
|
||
"type": "string",
|
||
"maxLength": 120
|
||
},
|
||
"guardianPhone": {
|
||
"type": "string",
|
||
"maxLength": 40
|
||
},
|
||
"latitude": {
|
||
"type": "number",
|
||
"minimum": -90,
|
||
"maximum": 90
|
||
},
|
||
"longitude": {
|
||
"type": "number",
|
||
"minimum": -180,
|
||
"maximum": 180
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"AssetsResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"assets": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"brand": {
|
||
"type": "string"
|
||
},
|
||
"model": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"serialNumber": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"commissionedAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"loadKg": {
|
||
"anyOf": [
|
||
{
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"floors": {
|
||
"anyOf": [
|
||
{
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"IN_SERVICE",
|
||
"OUT_OF_SERVICE",
|
||
"UNDER_MAINTENANCE"
|
||
]
|
||
},
|
||
"categoryId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"categoryName": {
|
||
"type": "string"
|
||
},
|
||
"locationId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"locationName": {
|
||
"type": "string"
|
||
},
|
||
"siteName": {
|
||
"type": "string"
|
||
},
|
||
"componentCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"brand",
|
||
"model",
|
||
"serialNumber",
|
||
"commissionedAt",
|
||
"loadKg",
|
||
"floors",
|
||
"status",
|
||
"categoryId",
|
||
"categoryName",
|
||
"locationId",
|
||
"locationName",
|
||
"siteName",
|
||
"componentCount"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"assets"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"AssetDetail": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"brand": {
|
||
"type": "string"
|
||
},
|
||
"model": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"serialNumber": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"commissionedAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"loadKg": {
|
||
"anyOf": [
|
||
{
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"floors": {
|
||
"anyOf": [
|
||
{
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"IN_SERVICE",
|
||
"OUT_OF_SERVICE",
|
||
"UNDER_MAINTENANCE"
|
||
]
|
||
},
|
||
"categoryId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"categoryName": {
|
||
"type": "string"
|
||
},
|
||
"locationId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"locationName": {
|
||
"type": "string"
|
||
},
|
||
"siteName": {
|
||
"type": "string"
|
||
},
|
||
"componentCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"components": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"typeId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"typeName": {
|
||
"type": "string"
|
||
},
|
||
"designation": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"typeId",
|
||
"typeName",
|
||
"designation"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"brand",
|
||
"model",
|
||
"serialNumber",
|
||
"commissionedAt",
|
||
"loadKg",
|
||
"floors",
|
||
"status",
|
||
"categoryId",
|
||
"categoryName",
|
||
"locationId",
|
||
"locationName",
|
||
"siteName",
|
||
"componentCount",
|
||
"components"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"AssetCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"reference": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 30
|
||
},
|
||
"brand": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 80
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"maxLength": 80
|
||
},
|
||
"serialNumber": {
|
||
"type": "string",
|
||
"maxLength": 80
|
||
},
|
||
"commissionedAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
"loadKg": {
|
||
"type": "integer",
|
||
"exclusiveMinimum": 0,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"floors": {
|
||
"type": "integer",
|
||
"exclusiveMinimum": 0,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"categoryId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"locationId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"components": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"typeId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"designation": {
|
||
"type": "string",
|
||
"maxLength": 120
|
||
}
|
||
},
|
||
"required": [
|
||
"typeId"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"reference",
|
||
"brand",
|
||
"categoryId",
|
||
"locationId"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"AssetUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"reference": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 30
|
||
},
|
||
"brand": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 80
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"maxLength": 80
|
||
},
|
||
"serialNumber": {
|
||
"type": "string",
|
||
"maxLength": 80
|
||
},
|
||
"commissionedAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
"loadKg": {
|
||
"type": "integer",
|
||
"exclusiveMinimum": 0,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"floors": {
|
||
"type": "integer",
|
||
"exclusiveMinimum": 0,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"categoryId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"locationId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"IN_SERVICE",
|
||
"OUT_OF_SERVICE",
|
||
"UNDER_MAINTENANCE"
|
||
]
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"AssetComponent": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"typeId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"typeName": {
|
||
"type": "string"
|
||
},
|
||
"designation": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"typeId",
|
||
"typeName",
|
||
"designation"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"AssetComponentCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"typeId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"designation": {
|
||
"type": "string",
|
||
"maxLength": 120
|
||
}
|
||
},
|
||
"required": [
|
||
"typeId"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TeamsResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"teams": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
},
|
||
"description": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"members": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"roleName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"roleName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name",
|
||
"description",
|
||
"members"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"teams"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"Team": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
},
|
||
"description": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"members": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"roleName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"roleName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name",
|
||
"description",
|
||
"members"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TeamCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 80
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"maxLength": 200
|
||
},
|
||
"memberIds": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TeamUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 80
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"maxLength": 200
|
||
},
|
||
"memberIds": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"UsersResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"users": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"email": {
|
||
"type": "string",
|
||
"format": "email",
|
||
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"phone": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"role": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string",
|
||
"enum": [
|
||
"Administrateur",
|
||
"Dispatcher",
|
||
"Technicien",
|
||
"Technicien limité",
|
||
"Gestionnaire",
|
||
"Demandeur",
|
||
"Vue seule"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"teams": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"active",
|
||
"invited",
|
||
"disabled"
|
||
]
|
||
},
|
||
"isDemo": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"email",
|
||
"displayName",
|
||
"phone",
|
||
"role",
|
||
"teams",
|
||
"status",
|
||
"isDemo"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"users"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"RolesResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"roles": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string",
|
||
"enum": [
|
||
"Administrateur",
|
||
"Dispatcher",
|
||
"Technicien",
|
||
"Technicien limité",
|
||
"Gestionnaire",
|
||
"Demandeur",
|
||
"Vue seule"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"roles"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"InvitationResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"userId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"activationToken": {
|
||
"type": "string"
|
||
},
|
||
"expiresAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"required": [
|
||
"userId",
|
||
"activationToken",
|
||
"expiresAt"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"InvitationCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"email": {
|
||
"type": "string",
|
||
"format": "email",
|
||
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
|
||
},
|
||
"displayName": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 120
|
||
},
|
||
"roleId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"teamIds": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
},
|
||
"phone": {
|
||
"type": "string",
|
||
"maxLength": 40
|
||
}
|
||
},
|
||
"required": [
|
||
"email",
|
||
"displayName",
|
||
"roleId"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"UserAdmin": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"email": {
|
||
"type": "string",
|
||
"format": "email",
|
||
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"phone": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"role": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string",
|
||
"enum": [
|
||
"Administrateur",
|
||
"Dispatcher",
|
||
"Technicien",
|
||
"Technicien limité",
|
||
"Gestionnaire",
|
||
"Demandeur",
|
||
"Vue seule"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"teams": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"name": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"name"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"active",
|
||
"invited",
|
||
"disabled"
|
||
]
|
||
},
|
||
"isDemo": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"email",
|
||
"displayName",
|
||
"phone",
|
||
"role",
|
||
"teams",
|
||
"status",
|
||
"isDemo"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"UserUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"displayName": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 120
|
||
},
|
||
"phone": {
|
||
"type": "string",
|
||
"maxLength": 40
|
||
},
|
||
"roleId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"teamIds": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"TaskTemplatesResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"templates": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
},
|
||
"periodMonths": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"isRegulatory": {
|
||
"type": "boolean"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
},
|
||
"componentTypeId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"componentTypeName": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label",
|
||
"periodMonths",
|
||
"isRegulatory",
|
||
"isActive",
|
||
"componentTypeId",
|
||
"componentTypeName"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"templates"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TaskTemplate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
},
|
||
"periodMonths": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"isRegulatory": {
|
||
"type": "boolean"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
},
|
||
"componentTypeId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"componentTypeName": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label",
|
||
"periodMonths",
|
||
"isRegulatory",
|
||
"isActive",
|
||
"componentTypeId",
|
||
"componentTypeName"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TaskTemplateCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"label": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 200
|
||
},
|
||
"periodMonths": {
|
||
"type": "integer",
|
||
"minimum": 1,
|
||
"maximum": 60
|
||
},
|
||
"componentTypeId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"isRegulatory": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"required": [
|
||
"label",
|
||
"periodMonths"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TaskTemplateUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"label": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 200
|
||
},
|
||
"periodMonths": {
|
||
"type": "integer",
|
||
"minimum": 1,
|
||
"maximum": 60
|
||
},
|
||
"componentTypeId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"isRegulatory": {
|
||
"type": "boolean"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"PreventiveGenerationResult": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"month": {
|
||
"type": "string"
|
||
},
|
||
"created": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"skipped": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"firstControls": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"references": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"month",
|
||
"created",
|
||
"skipped",
|
||
"firstControls",
|
||
"references"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"PreventiveGenerate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"month": {
|
||
"type": "string",
|
||
"pattern": "^\\d{4}-(0[1-9]|1[0-2])$"
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"PreventiveStatus": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"month": {
|
||
"type": "string"
|
||
},
|
||
"assetsUnderContract": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"generated": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"done": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"late": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"firstControls": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"month",
|
||
"assetsUnderContract",
|
||
"generated",
|
||
"done",
|
||
"late",
|
||
"firstControls"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"MetersResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"meters": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"kind": {
|
||
"type": "string",
|
||
"enum": [
|
||
"RUNNING_HOURS",
|
||
"STARTS"
|
||
]
|
||
},
|
||
"readings": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"value": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
},
|
||
"readBy": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"createdAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"value",
|
||
"readBy",
|
||
"createdAt"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"kind",
|
||
"readings"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"meters"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"MeterReadingCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"kind": {
|
||
"type": "string",
|
||
"enum": [
|
||
"RUNNING_HOURS",
|
||
"STARTS"
|
||
]
|
||
},
|
||
"value": {
|
||
"type": "integer",
|
||
"minimum": 0,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"kind",
|
||
"value"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"WorkOrdersResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"workOrders": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"title": {
|
||
"type": "string"
|
||
},
|
||
"type": {
|
||
"type": "string",
|
||
"enum": [
|
||
"CORRECTIVE",
|
||
"PREVENTIVE",
|
||
"WORKS"
|
||
]
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"OPEN",
|
||
"IN_PROGRESS",
|
||
"ON_HOLD",
|
||
"DONE",
|
||
"CANCELLED"
|
||
]
|
||
},
|
||
"priority": {
|
||
"type": "string",
|
||
"enum": [
|
||
"NONE",
|
||
"LOW",
|
||
"MEDIUM",
|
||
"HIGH",
|
||
"PERSON_TRAPPED"
|
||
]
|
||
},
|
||
"assetId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"assetReference": {
|
||
"type": "string"
|
||
},
|
||
"siteName": {
|
||
"type": "string"
|
||
},
|
||
"dueDate": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"assignees": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"createdAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"title",
|
||
"type",
|
||
"status",
|
||
"priority",
|
||
"assetId",
|
||
"assetReference",
|
||
"siteName",
|
||
"dueDate",
|
||
"assignees",
|
||
"createdAt"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"workOrders"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"WorkOrderDetail": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"title": {
|
||
"type": "string"
|
||
},
|
||
"type": {
|
||
"type": "string",
|
||
"enum": [
|
||
"CORRECTIVE",
|
||
"PREVENTIVE",
|
||
"WORKS"
|
||
]
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"OPEN",
|
||
"IN_PROGRESS",
|
||
"ON_HOLD",
|
||
"DONE",
|
||
"CANCELLED"
|
||
]
|
||
},
|
||
"priority": {
|
||
"type": "string",
|
||
"enum": [
|
||
"NONE",
|
||
"LOW",
|
||
"MEDIUM",
|
||
"HIGH",
|
||
"PERSON_TRAPPED"
|
||
]
|
||
},
|
||
"assetId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"assetReference": {
|
||
"type": "string"
|
||
},
|
||
"siteName": {
|
||
"type": "string"
|
||
},
|
||
"dueDate": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"assignees": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"createdAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
"description": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"locationName": {
|
||
"type": "string"
|
||
},
|
||
"startedAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"completedAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"cancelledAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"createdBy": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"request": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"requesterLabel": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"requesterLabel"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"events": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"kind": {
|
||
"type": "string"
|
||
},
|
||
"message": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"by": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"createdAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"kind",
|
||
"message",
|
||
"by",
|
||
"createdAt"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"checklist": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
},
|
||
"state": {
|
||
"type": "string",
|
||
"enum": [
|
||
"PENDING",
|
||
"DONE",
|
||
"NA"
|
||
]
|
||
},
|
||
"doneBy": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"doneAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label",
|
||
"state",
|
||
"doneBy",
|
||
"doneAt"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"report": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"note": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"doorState": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"cabinPosition": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"anomaly": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"externalCause": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"actionTaken": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"componentConcerned": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"note",
|
||
"doorState",
|
||
"cabinPosition",
|
||
"anomaly",
|
||
"externalCause",
|
||
"actionTaken",
|
||
"componentConcerned"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"allowedTransitions": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"enum": [
|
||
"OPEN",
|
||
"IN_PROGRESS",
|
||
"ON_HOLD",
|
||
"DONE",
|
||
"CANCELLED"
|
||
]
|
||
}
|
||
},
|
||
"closureBlockers": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"title",
|
||
"type",
|
||
"status",
|
||
"priority",
|
||
"assetId",
|
||
"assetReference",
|
||
"siteName",
|
||
"dueDate",
|
||
"assignees",
|
||
"createdAt",
|
||
"description",
|
||
"locationName",
|
||
"startedAt",
|
||
"completedAt",
|
||
"cancelledAt",
|
||
"createdBy",
|
||
"request",
|
||
"events",
|
||
"checklist",
|
||
"report",
|
||
"allowedTransitions",
|
||
"closureBlockers"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"WorkOrderCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"title": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 200
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"maxLength": 2000
|
||
},
|
||
"type": {
|
||
"type": "string",
|
||
"enum": [
|
||
"CORRECTIVE",
|
||
"PREVENTIVE",
|
||
"WORKS"
|
||
]
|
||
},
|
||
"priority": {
|
||
"type": "string",
|
||
"enum": [
|
||
"NONE",
|
||
"LOW",
|
||
"MEDIUM",
|
||
"HIGH",
|
||
"PERSON_TRAPPED"
|
||
]
|
||
},
|
||
"assetId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"dueDate": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
"assigneeIds": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"title",
|
||
"type",
|
||
"assetId"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"TransitionRequest": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"to": {
|
||
"type": "string",
|
||
"enum": [
|
||
"OPEN",
|
||
"IN_PROGRESS",
|
||
"ON_HOLD",
|
||
"DONE",
|
||
"CANCELLED"
|
||
]
|
||
},
|
||
"comment": {
|
||
"type": "string",
|
||
"maxLength": 500
|
||
}
|
||
},
|
||
"required": [
|
||
"to"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"CommentCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"message": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 1000
|
||
}
|
||
},
|
||
"required": [
|
||
"message"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"AssigneesUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"assigneeIds": {
|
||
"maxItems": 10,
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"assigneeIds"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ReportUpsert": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"note": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"maxLength": 2000
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"doorStateId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"cabinPositionId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"anomalyId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"externalCauseId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"actionTakenId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"componentConcernedId": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"ChecklistItem": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
},
|
||
"state": {
|
||
"type": "string",
|
||
"enum": [
|
||
"PENDING",
|
||
"DONE",
|
||
"NA"
|
||
]
|
||
},
|
||
"doneBy": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"displayName": {
|
||
"type": "string"
|
||
},
|
||
"initials": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"displayName",
|
||
"initials"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"doneAt": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"label",
|
||
"state",
|
||
"doneBy",
|
||
"doneAt"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ChecklistPatch": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"state": {
|
||
"type": "string",
|
||
"enum": [
|
||
"PENDING",
|
||
"DONE",
|
||
"NA"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"state"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"RequestsResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"requests": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"description": {
|
||
"type": "string"
|
||
},
|
||
"isPersonTrapped": {
|
||
"type": "boolean"
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"RECEIVED",
|
||
"APPROVED",
|
||
"REJECTED"
|
||
]
|
||
},
|
||
"rejectionReason": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"assetId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"assetReference": {
|
||
"type": "string"
|
||
},
|
||
"siteName": {
|
||
"type": "string"
|
||
},
|
||
"requesterLabel": {
|
||
"type": "string"
|
||
},
|
||
"workOrder": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"OPEN",
|
||
"IN_PROGRESS",
|
||
"ON_HOLD",
|
||
"DONE",
|
||
"CANCELLED"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"status"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"createdAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"description",
|
||
"isPersonTrapped",
|
||
"status",
|
||
"rejectionReason",
|
||
"assetId",
|
||
"assetReference",
|
||
"siteName",
|
||
"requesterLabel",
|
||
"workOrder",
|
||
"createdAt"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"requests"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"RequestSummary": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"description": {
|
||
"type": "string"
|
||
},
|
||
"isPersonTrapped": {
|
||
"type": "boolean"
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"RECEIVED",
|
||
"APPROVED",
|
||
"REJECTED"
|
||
]
|
||
},
|
||
"rejectionReason": {
|
||
"anyOf": [
|
||
{
|
||
"type": "string"
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"assetId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"assetReference": {
|
||
"type": "string"
|
||
},
|
||
"siteName": {
|
||
"type": "string"
|
||
},
|
||
"requesterLabel": {
|
||
"type": "string"
|
||
},
|
||
"workOrder": {
|
||
"anyOf": [
|
||
{
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"reference": {
|
||
"type": "string"
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"OPEN",
|
||
"IN_PROGRESS",
|
||
"ON_HOLD",
|
||
"DONE",
|
||
"CANCELLED"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"status"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
{
|
||
"type": "null"
|
||
}
|
||
]
|
||
},
|
||
"createdAt": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"reference",
|
||
"description",
|
||
"isPersonTrapped",
|
||
"status",
|
||
"rejectionReason",
|
||
"assetId",
|
||
"assetReference",
|
||
"siteName",
|
||
"requesterLabel",
|
||
"workOrder",
|
||
"createdAt"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"RequestCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"assetId": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 2000
|
||
},
|
||
"isPersonTrapped": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"required": [
|
||
"assetId",
|
||
"description"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"RequestApprove": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"title": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 200
|
||
},
|
||
"priority": {
|
||
"type": "string",
|
||
"enum": [
|
||
"NONE",
|
||
"LOW",
|
||
"MEDIUM",
|
||
"HIGH",
|
||
"PERSON_TRAPPED"
|
||
]
|
||
},
|
||
"assigneeIds": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
}
|
||
},
|
||
"dueDate": {
|
||
"type": "string",
|
||
"format": "date-time",
|
||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"RequestReject": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"reason": {
|
||
"type": "string",
|
||
"minLength": 3,
|
||
"maxLength": 500
|
||
}
|
||
},
|
||
"required": [
|
||
"reason"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ReferenceValuesResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"referenceValues": {
|
||
"type": "array",
|
||
"items": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"field": {
|
||
"type": "string",
|
||
"enum": [
|
||
"DOOR_STATE",
|
||
"CABIN_POSITION",
|
||
"ANOMALY",
|
||
"EXTERNAL_CAUSE",
|
||
"ACTION_TAKEN",
|
||
"COMPONENT_CONCERNED"
|
||
]
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
},
|
||
"usageCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"field",
|
||
"label",
|
||
"isActive",
|
||
"usageCount"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"referenceValues"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ReferenceValue": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"format": "uuid",
|
||
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
||
},
|
||
"field": {
|
||
"type": "string",
|
||
"enum": [
|
||
"DOOR_STATE",
|
||
"CABIN_POSITION",
|
||
"ANOMALY",
|
||
"EXTERNAL_CAUSE",
|
||
"ACTION_TAKEN",
|
||
"COMPONENT_CONCERNED"
|
||
]
|
||
},
|
||
"label": {
|
||
"type": "string"
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
},
|
||
"usageCount": {
|
||
"type": "integer",
|
||
"minimum": -9007199254740991,
|
||
"maximum": 9007199254740991
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"field",
|
||
"label",
|
||
"isActive",
|
||
"usageCount"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ReferenceValueCreate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"field": {
|
||
"type": "string",
|
||
"enum": [
|
||
"DOOR_STATE",
|
||
"CABIN_POSITION",
|
||
"ANOMALY",
|
||
"EXTERNAL_CAUSE",
|
||
"ACTION_TAKEN",
|
||
"COMPONENT_CONCERNED"
|
||
]
|
||
},
|
||
"label": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 120
|
||
}
|
||
},
|
||
"required": [
|
||
"field",
|
||
"label"
|
||
],
|
||
"additionalProperties": false
|
||
},
|
||
"ReferenceValueUpdate": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"label": {
|
||
"type": "string",
|
||
"minLength": 1,
|
||
"maxLength": 120
|
||
},
|
||
"isActive": {
|
||
"type": "boolean"
|
||
}
|
||
},
|
||
"additionalProperties": false
|
||
},
|
||
"HealthResponse": {
|
||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||
"type": "object",
|
||
"properties": {
|
||
"status": {
|
||
"type": "string",
|
||
"enum": [
|
||
"ok",
|
||
"degraded"
|
||
]
|
||
},
|
||
"services": {
|
||
"type": "object",
|
||
"properties": {
|
||
"database": {
|
||
"type": "string",
|
||
"enum": [
|
||
"up",
|
||
"down"
|
||
]
|
||
},
|
||
"redis": {
|
||
"type": "string",
|
||
"enum": [
|
||
"up",
|
||
"down"
|
||
]
|
||
},
|
||
"storage": {
|
||
"type": "string",
|
||
"enum": [
|
||
"up",
|
||
"down"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"database",
|
||
"redis",
|
||
"storage"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"required": [
|
||
"status",
|
||
"services"
|
||
],
|
||
"additionalProperties": false
|
||
}
|
||
},
|
||
"securitySchemes": {
|
||
"bearerAuth": {
|
||
"type": "http",
|
||
"scheme": "bearer",
|
||
"bearerFormat": "JWT"
|
||
}
|
||
}
|
||
}
|
||
}
|