{
  "$defs": {
    "competence": {
      "additionalProperties": false,
      "description": "Any competence used to complete professional tasks (tools proficiency as \"Excel\", technologies mastered as \"JAVA\", practices learned as \"TDD\", hardware you know how to handle as vehicles or construction tools, and know-how domains as \"banking\" or \"russia\")",
      "properties": {
        "description": {
          "examples": [
            "Formule modeling and complex calculations",
            "Web apps developing",
            "Writing tests first and then coding to pass then",
            "Driving 15-wheeler over the country",
            "Experience in the financial sector"
          ],
          "type": "string"
        },
        "name": {
          "examples": [
            "Excel",
            "JAVA",
            "TDD",
            "Class 8 trucks",
            "banking"
          ],
          "type": "string"
        },
        "type": {
          "enum": [
            "tool",
            "technology",
            "practice",
            "hardware",
            "domain"
          ],
          "type": "string"
        }
      },
      "required": [
        "name",
        "type"
      ],
      "type": "object"
    },
    "contactMean": {
      "$comment": "TBD Same component used in significativeRelationships and careerPreferences/contact (to be refactor to a common definition)",
      "additionalProperties": true,
      "anyOf": [
        {
          "additionalProperties": true,
          "properties": {
            "publicProfiles": {
              "additionalItems": false,
              "description": "Online services that provide a way to contact a person without exposing mail or phone number.",
              "items": {
                "additionalProperties": false,
                "properties": {
                  "URL": {
                    "examples": [
                      "https://www.getmanfred.com/mac/david",
                      "https://www.linkedin.com/in/satyanadella/"
                    ],
                    "format": "uri",
                    "type": "string"
                  },
                  "type": {
                    "$comment": "TBD Refactor to extract the enumeration \"public link type\" to a common definition file, to be completed with more external services.",
                    "enum": [
                      "manfred",
                      "linkedin",
                      "stackoverflow",
                      "xing",
                      "other"
                    ],
                    "type": "string"
                  }
                },
                "required": [
                  "type",
                  "URL"
                ],
                "type": "object"
              },
              "minContains": 1,
              "minItems": 1,
              "type": "array",
              "uniqueItems": true
            }
          },
          "required": [
            "publicProfiles"
          ],
          "type": "object"
        },
        {
          "additionalProperties": true,
          "properties": {
            "phoneNumbers": {
              "additionalItems": false,
              "items": {
                "additionalProperties": false,
                "properties": {
                  "countryCode": {
                    "description": "Country calling code as defined in International Telecommunication Union (ITU) standards E.123 and E.164.",
                    "examples": [
                      34,
                      1
                    ],
                    "type": "number"
                  },
                  "number": {
                    "$comment": "TBD refactor to validate the phone number depending on the Country Code",
                    "examples": [
                      "616100584",
                      "(555) 555-1234"
                    ],
                    "type": "string"
                  }
                },
                "required": [
                  "countryCode",
                  "number"
                ],
                "type": "object"
              },
              "minContains": 1,
              "minItems": 1,
              "type": "array",
              "uniqueItems": true
            }
          },
          "required": [
            "phoneNumbers"
          ],
          "type": "object"
        },
        {
          "additionalProperties": true,
          "properties": {
            "contactMails": {
              "additionalItems": false,
              "items": {
                "examples": [
                  "your.name@mail.com"
                ],
                "format": "email",
                "type": "string"
              },
              "minContains": 1,
              "minItems": 1,
              "type": "array",
              "uniqueItems": true
            }
          },
          "required": [
            "contactMails"
          ],
          "type": "object"
        }
      ],
      "description": "A way to contact a specific person",
      "type": "object"
    },
    "contractType": {
      "description": "Types of Contracts",
      "enum": [
        "permanent",
        "temporary",
        "freelance",
        "internship"
      ],
      "type": "string"
    },
    "image": {
      "$comment": "TDB: to be refactor to extract an image  \"object\" within a definitions section or schema",
      "additionalProperties": true,
      "description": "picture, thumbnail or avatar",
      "oneOf": [
        {
          "additionalProperties": true,
          "description": "A link to the image",
          "properties": {
            "link": {
              "examples": [
                "https://images.assetsdelivery.com/compings_v2/thesomeday123/thesomeday1231709/thesomeday123170900021.jpg"
              ],
              "format": "uri",
              "type": "string"
            }
          },
          "required": [
            "link"
          ],
          "type": "object"
        },
        {
          "additionalProperties": true,
          "description": "Image data encoded in base64",
          "properties": {
            "data": {
              "examples": [
                "iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAApgAAAKYB3X3/OAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAANCSURBVEiJtZZPbBtFFMZ/M7ubXdtdb1xSFyeilBapySVU8h8OoFaooFSqiihIVIpQBKci6KEg9Q6H9kovIHoCIVQJJCKE1ENFjnAgcaSGC6rEnxBwA04Tx43t2FnvDAfjkNibxgHxnWb2e/u992bee7tCa00YFsffekFY+nUzFtjW0LrvjRXrCDIAaPLlW0nHL0SsZtVoaF98mLrx3pdhOqLtYPHChahZcYYO7KvPFxvRl5XPp1sN3adWiD1ZAqD6XYK1b/dvE5IWryTt2udLFedwc1+9kLp+vbbpoDh+6TklxBeAi9TL0taeWpdmZzQDry0AcO+jQ12RyohqqoYoo8RDwJrU+qXkjWtfi8Xxt58BdQuwQs9qC/afLwCw8tnQbqYAPsgxE1S6F3EAIXux2oQFKm0ihMsOF71dHYx+f3NND68ghCu1YIoePPQN1pGRABkJ6Bus96CutRZMydTl+TvuiRW1m3n0eDl0vRPcEysqdXn+jsQPsrHMquGeXEaY4Yk4wxWcY5V/9scqOMOVUFthatyTy8QyqwZ+kDURKoMWxNKr2EeqVKcTNOajqKoBgOE28U4tdQl5p5bwCw7BWquaZSzAPlwjlithJtp3pTImSqQRrb2Z8PHGigD4RZuNX6JYj6wj7O4TFLbCO/Mn/m8R+h6rYSUb3ekokRY6f/YukArN979jcW+V/S8g0eT/N3VN3kTqWbQ428m9/8k0P/1aIhF36PccEl6EhOcAUCrXKZXXWS3XKd2vc/TRBG9O5ELC17MmWubD2nKhUKZa26Ba2+D3P+4/MNCFwg59oWVeYhkzgN/JDR8deKBoD7Y+ljEjGZ0sosXVTvbc6RHirr2reNy1OXd6pJsQ+gqjk8VWFYmHrwBzW/n+uMPFiRwHB2I7ih8ciHFxIkd/3Omk5tCDV1t+2nNu5sxxpDFNx+huNhVT3/zMDz8usXC3ddaHBj1GHj/As08fwTS7Kt1HBTmyN29vdwAw+/wbwLVOJ3uAD1wi/dUH7Qei66PfyuRj4Ik9is+hglfbkbfR3cnZm7chlUWLdwmprtCohX4HUtlOcQjLYCu+fzGJH2QRKvP3UNz8bWk1qMxjGTOMThZ3kvgLI5AzFfo379UAAAAASUVORK5CYII="
              ],
              "type": "string"
            },
            "encoding": {
              "const": "base64",
              "type": "string"
            },
            "mediaType": {
              "enum": [
                "image/png",
                "image/jpeg"
              ],
              "type": "string"
            }
          },
          "required": [
            "data",
            "mediaType",
            "encoding"
          ],
          "type": "object"
        }
      ],
      "properties": {
        "alt": {
          "description": "Alternative description of the image",
          "examples": [
            "picture of Mike Gomez"
          ],
          "type": "string"
        }
      },
      "type": "object"
    },
    "location": {
      "additionalProperties": false,
      "properties": {
        "address": {
          "examples": [
            "",
            "33 West 23rd Street, 2nd Floor",
            "Rua Emilia Pardo Baz\u00e1n 18, 6\u00baB"
          ],
          "type": "string"
        },
        "country": {
          "$comment": "TDB: link to a enum of ISO-3166 codes in a external definition file",
          "description": "Country where you live",
          "examples": [
            "US"
          ],
          "type": "string"
        },
        "municipality": {
          "$comment": "TBD It could be validated depending on the Country/Region values.",
          "description": "City or town where you live.",
          "examples": [
            "San Francisco",
            "A Coru\u00f1a",
            "Hamburg",
            "La Rochelle"
          ],
          "type": "string"
        },
        "notes": {
          "examples": [
            "Please, use the security code '6535' to get access to the mail boxes."
          ],
          "type": "string"
        },
        "postalCode": {
          "examples": [
            "90001",
            "SW1W 0NY",
            "15001"
          ],
          "type": "string"
        },
        "region": {
          "$comment": "TBD It could be validated depending on the Country value.",
          "description": "Region (State, L\u00e4nder, County, Community...) where you live.",
          "examples": [
            "California",
            "Galicia",
            "Bayern",
            "Hampshire"
          ],
          "type": "string"
        }
      },
      "type": "object"
    },
    "organizationType": {
      "$comment": "TBD Refactor to extract the enumeration \"OrganizationType\" (used in jobs/roles/organization or careerPreferences/preferredOrganizations) to a common definition file.",
      "description": "Types of Organization",
      "enum": [
        "freelance",
        "publicAdministration",
        "NGO",
        "startup",
        "SME",
        "bigCorp",
        "academicalInstitution",
        "other"
      ],
      "type": "string"
    },
    "person": {
      "$comment": "TBD Same component used in rol/referrals, #/experience/jobs/organization/projects/project/referrals and significativeRelationships, to be refactor to a common definition.",
      "additionalProperties": false,
      "description": "A Person data",
      "properties": {
        "avatar": {
          "$ref": "#/$defs/image"
        },
        "birthday": {
          "description": "Person's birth date in format yyyy-mm-dd",
          "examples": [
            "1977-07-26"
          ],
          "format": "date",
          "type": "string"
        },
        "contact": {
          "$ref": "#/$defs/contactMean"
        },
        "description": {
          "examples": [
            "Daniel was the perfect leader and he achieved all the goals assigned to the Departement but the most important thing is he's also a great colleague."
          ],
          "type": "string"
        },
        "location": {
          "$ref": "#/$defs/location"
        },
        "name": {
          "examples": [
            "Sharon",
            "Tatiana",
            "Goran"
          ],
          "type": "string"
        },
        "surnames": {
          "description": "Surname o Surnames of the person",
          "examples": [
            "Vlaovic-Sorensen",
            "Varoufakis",
            "Ahmed"
          ],
          "type": "string"
        },
        "title": {
          "description": "Role, relationship or activity related to the person.",
          "examples": [
            "My supervisor",
            "I work with her for 5 years"
          ],
          "maxLength": 255,
          "type": "string"
        }
      },
      "required": [
        "name",
        "surnames",
        "title"
      ],
      "type": "object"
    },
    "projectType": {
      "description": "Types of Projects",
      "enum": [
        "proBono",
        "openSource",
        "sideProject",
        "personalAchievement",
        "other"
      ],
      "type": "string"
    },
    "publicArtifactType": {
      "description": "Types of Public Artifacts",
      "enum": [
        "post",
        "talk",
        "sideProject",
        "achievement",
        "launch",
        "video"
      ],
      "type": "string"
    },
    "publicEntityDetails": {
      "additionalProperties": true,
      "description": "Organization, Company, Institution, Administration, Project or Initiative related to my career.",
      "properties": {
        "URL": {
          "examples": [
            "https://www.stanford.edu/"
          ],
          "format": "uri",
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "image": {
          "$ref": "#/$defs/image"
        },
        "location": {
          "$ref": "#/$defs/location"
        },
        "name": {
          "examples": [
            "Stanford University",
            "IBM",
            "Project Management Institute"
          ],
          "type": "string"
        }
      },
      "required": [
        "name"
      ],
      "type": "object"
    },
    "recommendationType": {
      "description": "Types of Recommendations",
      "enum": [
        "reading",
        "video",
        "podcast",
        "web",
        "other"
      ],
      "type": "string"
    },
    "role": {
      "additionalProperties": false,
      "description": "roles developed within an organization",
      "properties": {
        "challenges": {
          "additionalItems": true,
          "items": {
            "additionalProperties": false,
            "properties": {
              "actions": {
                "additionalItems": true,
                "items": {
                  "type": "string"
                },
                "minContains": 1,
                "minItems": 1,
                "type": "array"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "description"
            ],
            "type": "object"
          },
          "minContains": 1,
          "type": "array",
          "uniqueItems": true
        },
        "competences": {
          "additionalItems": false,
          "items": {
            "$ref": "#/$defs/competence"
          },
          "minItems": 1,
          "type": "array",
          "uniqueItems": true
        },
        "finishDate": {
          "examples": [
            "2022-02-14"
          ],
          "format": "date",
          "type": "string"
        },
        "name": {
          "examples": [
            "Developer"
          ],
          "type": "string"
        },
        "notes": {
          "description": "Notes and information about the role",
          "type": "string"
        },
        "referrals": {
          "$comment": "Professional Referrals about my activity in one specific rol.",
          "additionalItems": false,
          "items": {
            "$ref": "#/$defs/person"
          },
          "minItems": 1,
          "type": "array",
          "uniqueItems": true
        },
        "startDate": {
          "examples": [
            "2019-06-20"
          ],
          "format": "date",
          "type": "string"
        }
      },
      "required": [
        "name",
        "startDate"
      ],
      "type": "object"
    },
    "studyType": {
      "description": "Types of studies:\n\n* \"officialDegree\" is a degree accredited by the government (University Degree) or an external, recognized and independent agency (some MBAs).\n* \"certification\" is a degree accredited by a private institution (eg. Oracle Database Admin Certification or Projecr Management Institute PMP)\n* \"unaccredited\" is a course without any accreditation (eg. Coursera or Platzi courses), but this doesn't mean that is not valid, legit, or has poor quality\n* \"selfTraining\" is the study designed, managed and evaluated just by the own learner.",
      "enum": [
        "officialDegree",
        "certification",
        "unaccredited",
        "selfTraining"
      ],
      "type": "string"
    },
    "tags": {
      "additionalItems": false,
      "description": "A list of tags with random values to provide the candidates a way to segment and categorize elements in their CV.",
      "items": {
        "examples": [
          "cooking",
          "not available",
          "february"
        ],
        "type": "string"
      },
      "type": "array",
      "uniqueItems": true
    }
  },
  "$id": "http://github.com/manfred/mac/schema.json",
  "$schema": "https://json-schema.org/draft/2019-09/schema",
  "additionalProperties": true,
  "description": "An open CV format",
  "properties": {
    "aboutMe": {
      "additionalProperties": false,
      "description": "Main data of the CV author",
      "properties": {
        "currentSalary": {
          "additionalProperties": false,
          "properties": {
            "amount": {
              "type": "integer"
            },
            "currency": {
              "type": "string"
            },
            "relevantPerks": {
              "additionalItems": true,
              "items": {
                "type": "string"
              },
              "type": "array"
            }
          },
          "required": [
            "currency",
            "amount"
          ],
          "type": "object"
        },
        "interestingFacts": {
          "additionalItems": true,
          "description": "Facts that define you: your IDE, your favorite books,  your football team...",
          "items": {
            "additionalProperties": false,
            "properties": {
              "fact": {
                "type": "string"
              },
              "topic": {
                "examples": [
                  "First computer",
                  "My football team"
                ],
                "type": "string"
              }
            },
            "required": [
              "fact"
            ],
            "type": "object"
          },
          "minItems": 1,
          "type": "array",
          "uniqueItems": true
        },
        "noticePeriod": {
          "type": "integer"
        },
        "profile": {
          "$ref": "#/$defs/person"
        },
        "recommendations": {
          "additionalItems": false,
          "description": "Content I like and recommend that can help define me as a professional.",
          "items": {
            "additionalProperties": false,
            "properties": {
              "URL": {
                "type": "string"
              },
              "authors": {
                "additionalItems": false,
                "items": {
                  "$ref": "#/$defs/person"
                },
                "minItems": 1,
                "type": "array",
                "uniqueItems": true
              },
              "summary": {
                "type": "string"
              },
              "title": {
                "type": "string"
              },
              "type": {
                "$ref": "#/$defs/recommendationType"
              }
            },
            "required": [
              "title"
            ],
            "type": "object"
          },
          "minContains": 1,
          "type": "array"
        },
        "relevantLinks": {
          "additionalItems": true,
          "items": {
            "additionalProperties": false,
            "properties": {
              "URL": {
                "format": "uri",
                "type": "string"
              },
              "description": {
                "type": "string"
              },
              "type": {
                "enum": [
                  "linkedin",
                  "github",
                  "twitter",
                  "website",
                  "other"
                ],
                "type": "string"
              }
            },
            "required": [
              "type",
              "URL"
            ],
            "type": "object"
          },
          "minItems": 1,
          "type": "array",
          "uniqueItems": true
        },
        "relevantYearsOfExperience": {
          "description": "Relevant years of experience related with desired professional roles and goals.",
          "type": "number"
        },
        "significativeRelationships": {
          "additionalItems": false,
          "description": "Friends or colleagues with whom I have worked or not, whose relationship with me can help define me as a professional.",
          "items": {
            "$ref": "#/$defs/person"
          },
          "minItems": 1,
          "type": "array",
          "uniqueItems": true
        }
      },
      "type": "object"
    },
    "careerPreferences": {
      "additionalProperties": false,
      "properties": {
        "contact": {
          "$ref": "#/$defs/contactMean"
        },
        "goals": {
          "additionalItems": false,
          "description": "Personal and Professional goals to match with company needs and requirements.",
          "items": {
            "additionalProperties": false,
            "properties": {
              "description": {
                "examples": [
                  "Write and speak German fluently",
                  "Manage people, resources and goals",
                  "Work in a startup "
                ],
                "type": "string"
              },
              "title": {
                "examples": [
                  "Learn German",
                  "Become Team Leader",
                  "Work in a Silicon Valley Company"
                ],
                "type": "string"
              }
            },
            "type": "object"
          },
          "maxContains": 1,
          "type": "array"
        },
        "preferences": {
          "additionalProperties": false,
          "properties": {
            "discardedCompetences": {
              "additionalItems": false,
              "description": "Skills, tools, domains or methodologies I don't like to work with",
              "items": {
                "$ref": "#/$defs/competence"
              },
              "minItems": 1,
              "type": "array"
            },
            "discardedOrganizations": {
              "additionalItems": false,
              "description": "Type of organizations where I don't want to work",
              "items": {
                "$ref": "#/$defs/organizationType"
              },
              "minItems": 1,
              "type": "array"
            },
            "discardedRoles": {
              "additionalItems": false,
              "description": "Type of roles I don't like to adopt",
              "items": {
                "examples": [
                  "Project Manager",
                  "CIO"
                ],
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "preferredCompetences": {
              "additionalItems": false,
              "description": "Skills, tools, domains or methodologies I like to work with",
              "items": {
                "$ref": "#/$defs/competence"
              },
              "minContains": 1,
              "minItems": 1,
              "type": "array"
            },
            "preferredOrganizations": {
              "additionalItems": false,
              "description": "Type of organizations where I want to work",
              "items": {
                "$ref": "#/$defs/organizationType"
              },
              "minItems": 1,
              "type": "array"
            },
            "preferredRoles": {
              "additionalItems": false,
              "items": {
                "examples": [
                  "Product Manager",
                  "Chef",
                  "Teacher"
                ],
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            }
          },
          "type": "object"
        },
        "requirements": {
          "additionalProperties": false,
          "properties": {
            "compensation": {
              "additionalProperties": false,
              "properties": {
                "equity": {
                  "additionalProperties": false,
                  "properties": {
                    "comments": {
                      "examples": [
                        ""
                      ],
                      "type": "string"
                    },
                    "from": {
                      "examples": [
                        1.5,
                        0.3,
                        30
                      ],
                      "type": "number"
                    },
                    "mustHave": {
                      "description": "If equity is a must have to accept a new position",
                      "type": "boolean"
                    },
                    "upto": {
                      "examples": [
                        10
                      ],
                      "type": "number"
                    }
                  },
                  "required": [
                    "mustHave",
                    "from"
                  ],
                  "type": "object"
                },
                "perks": {
                  "additionalProperties": true,
                  "allOf": [
                    {
                      "additionalProperties": true,
                      "properties": {
                        "mustHave": {
                          "additionalItems": false,
                          "description": "Perks a new position must have to be considered",
                          "items": {
                            "$comment": "TBD to be validated against an external enumeration of perks",
                            "examples": [
                              "Health Insurance"
                            ],
                            "type": "string"
                          },
                          "minItems": 1,
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    {
                      "additionalProperties": true,
                      "properties": {
                        "niceToHave": {
                          "additionalItems": false,
                          "description": "Perks a new position should have to be considered",
                          "items": {
                            "$comment": "TBD to be validated against an external enumeration of perks",
                            "examples": [
                              "Free Meals"
                            ],
                            "type": "string"
                          },
                          "minItems": 1,
                          "type": "array"
                        }
                      },
                      "type": "object"
                    }
                  ],
                  "type": "object"
                },
                "salary": {
                  "additionalProperties": false,
                  "properties": {
                    "comments": {
                      "type": "string"
                    },
                    "currency": {
                      "$comment": "TBD refactor to validate against an enum based on ISO 4217 currency codes.",
                      "examples": [
                        "USD",
                        "EUR",
                        "CNY"
                      ],
                      "maxLength": 3,
                      "minLength": 3,
                      "type": "string"
                    },
                    "from": {
                      "examples": [
                        50000
                      ],
                      "type": "integer"
                    },
                    "upto": {
                      "examples": [
                        100000
                      ],
                      "type": "integer"
                    }
                  },
                  "required": [
                    "currency",
                    "from"
                  ],
                  "type": "object"
                }
              },
              "required": [
                "salary"
              ],
              "type": "object"
            },
            "contractTypes": {
              "additionalItems": false,
              "items": {
                "$ref": "#/$defs/contractType"
              },
              "minItems": 1,
              "type": "array"
            },
            "location": {
              "additionalProperties": false,
              "properties": {
                "comments": {
                  "examples": [
                    "I don't want to work in the Financial District. There are no decent donuts shops"
                  ],
                  "type": "string"
                },
                "openToRelocate": {
                  "default": false,
                  "type": "boolean"
                },
                "openToRemote": {
                  "default": true,
                  "type": "boolean"
                },
                "remoteOnly": {
                  "default": false,
                  "type": "boolean"
                },
                "workingAreas": {
                  "additionalItems": false,
                  "items": {
                    "additionalProperties": false,
                    "properties": {
                      "distanceFromMunicipality": {
                        "additionalProperties": false,
                        "properties": {
                          "amount": {
                            "examples": [
                              20
                            ],
                            "type": "integer"
                          },
                          "unit": {
                            "description": "Unit of measure, Kilometers or Miles",
                            "enum": [
                              "Km",
                              "Mi"
                            ],
                            "type": "string"
                          }
                        },
                        "required": [
                          "unit",
                          "amount"
                        ],
                        "type": "object"
                      },
                      "location": {
                        "$ref": "#/$defs/location"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                }
              },
              "type": "object"
            }
          },
          "type": "object"
        },
        "status": {
          "enum": [
            "openToOffers",
            "searchingActively",
            "notAvailable"
          ],
          "type": "string"
        }
      },
      "required": [
        "contact"
      ],
      "type": "object"
    },
    "experience": {
      "additionalProperties": true,
      "allOf": [
        {
          "additionalProperties": true,
          "properties": {
            "jobs": {
              "additionalItems": true,
              "items": {
                "$comment": "TBD Refactor to extract the entity \"organization\" to a common definitions file.",
                "additionalProperties": true,
                "description": "Company, Public Institution, or NGO where you work or have worked for a salary.",
                "properties": {
                  "organization": {
                    "$ref": "#/$defs/publicEntityDetails"
                  },
                  "roles": {
                    "additionalItems": false,
                    "items": {
                      "$ref": "#/$defs/role"
                    },
                    "minItems": 1,
                    "type": "array"
                  },
                  "type": {
                    "$ref": "#/$defs/organizationType"
                  }
                },
                "required": [
                  "organization",
                  "roles"
                ],
                "type": "object"
              },
              "minItems": 1,
              "type": "array"
            }
          },
          "type": "object"
        },
        {
          "additionalProperties": true,
          "properties": {
            "projects": {
              "additionalItems": false,
              "items": {
                "additionalProperties": false,
                "properties": {
                  "details": {
                    "$ref": "#/$defs/publicEntityDetails"
                  },
                  "roles": {
                    "additionalItems": true,
                    "items": {
                      "$ref": "#/$defs/role"
                    },
                    "minItems": 1,
                    "type": "array"
                  },
                  "type": {
                    "$ref": "#/$defs/projectType"
                  }
                },
                "required": [
                  "roles"
                ],
                "type": "object"
              },
              "minContains": 1,
              "minItems": 1,
              "type": "array"
            }
          },
          "type": "object"
        },
        {
          "additionalProperties": true,
          "properties": {
            "publicArtifacts": {
              "additionalItems": false,
              "items": {
                "additionalProperties": false,
                "properties": {
                  "details": {
                    "$ref": "#/$defs/publicEntityDetails"
                  },
                  "publishingDate": {
                    "format": "date",
                    "type": "string"
                  },
                  "relatedCompetences": {
                    "additionalItems": false,
                    "items": {
                      "$ref": "#/$defs/competence"
                    },
                    "minContains": 1,
                    "type": "array"
                  },
                  "tags": {
                    "$ref": "#/$defs/tags"
                  },
                  "type": {
                    "$ref": "#/$defs/publicArtifactType"
                  }
                },
                "required": [
                  "details"
                ],
                "type": "object"
              },
              "minContains": 1,
              "type": "array"
            }
          },
          "type": "object"
        }
      ],
      "type": "object"
    },
    "knowledge": {
      "additionalProperties": false,
      "properties": {
        "hardSkills": {
          "additionalItems": true,
          "description": "hardSkills are a subset of competence types (tool, technology or hardware).",
          "items": {
            "additionalProperties": false,
            "properties": {
              "level": {
                "enum": [
                  "basic",
                  "intermediate",
                  "high",
                  "expert"
                ],
                "type": "string"
              },
              "skill": {
                "$ref": "#/$defs/competence"
              }
            },
            "type": "object"
          },
          "type": "array"
        },
        "languages": {
          "additionalItems": true,
          "items": {
            "additionalProperties": false,
            "dependentRequired": {
              "level": [
                "name"
              ]
            },
            "properties": {
              "level": {
                "$comment": "TBD make it required.",
                "enum": [
                  "Elementary proficiency",
                  "Limited working proficiency",
                  "Professional working proficiency",
                  "Full professional proficiency",
                  "Native or bilingual proficiency"
                ],
                "type": "string"
              },
              "name": {
                "description": "A language expressed as a [ISO 639-1 code](https://en.wikipedia.org/wiki/ISO_639-1)",
                "examples": [
                  "EN"
                ],
                "type": "string"
              }
            },
            "required": [
              "name"
            ],
            "type": "object"
          },
          "minItems": 1,
          "type": "array"
        },
        "softSkills": {
          "additionalItems": true,
          "description": "softSkills are a subset of competence types (practice or domain)",
          "items": {
            "additionalProperties": false,
            "properties": {
              "level": {
                "enum": [
                  "basic",
                  "intermediate",
                  "high",
                  "expert"
                ],
                "type": "string"
              },
              "skill": {
                "$ref": "#/$defs/competence"
              }
            },
            "type": "object"
          },
          "minItems": 1,
          "type": "array"
        },
        "studies": {
          "additionalItems": false,
          "items": {
            "additionalProperties": false,
            "properties": {
              "degreeAchieved": {
                "description": "If studies finished achieving the linked degree",
                "type": "boolean"
              },
              "description": {
                "examples": [
                  "Computer Science Grade"
                ],
                "type": "string"
              },
              "finishDate": {
                "description": "date when studies finished (if finished), with or without obtaining a degree, in format yyyy-mm-dd",
                "format": "date",
                "type": "string"
              },
              "institution": {
                "$ref": "#/$defs/publicEntityDetails"
              },
              "linkedCompetences": {
                "additionalItems": false,
                "items": {
                  "$ref": "#/$defs/competence"
                },
                "minContains": 1,
                "type": "array"
              },
              "name": {
                "examples": [
                  "Software Engineering",
                  "Certified ScrumMaster"
                ],
                "type": "string"
              },
              "startDate": {
                "description": "date when studies started in format yyyy-mm-dd",
                "format": "date",
                "type": "string"
              },
              "studyType": {
                "$ref": "#/$defs/studyType"
              }
            },
            "required": [
              "studyType",
              "degreeAchieved",
              "name",
              "startDate"
            ],
            "type": "object"
          },
          "minContains": 1,
          "minItems": 1,
          "type": "array"
        }
      },
      "type": "object"
    },
    "settings": {
      "additionalProperties": false,
      "description": "CV Settings",
      "properties": {
        "MACversion": {
          "description": "Schema version which validated the JSON",
          "examples": [
            "0.2"
          ],
          "type": "string"
        },
        "language": {
          "$comment": "TDB: link to a enum of ISO-639 codes in a external definition file",
          "description": "The language of the CV expressed as a [ISO 639-1 code](https://en.wikipedia.org/wiki/ISO_639-1)",
          "examples": [
            "EN",
            "EN-US"
          ],
          "type": "string"
        },
        "lastUpdate": {
          "description": "Last time the CV was updated",
          "format": "date",
          "type": "string"
        }
      },
      "required": [
        "language"
      ],
      "type": "object"
    }
  },
  "required": [
    "settings",
    "aboutMe",
    "careerPreferences"
  ],
  "title": "Manfred Awesomic CV",
  "type": "object"
}