Skip to the content.

Name

JSON schema example for a name entity

$idname.yml
$schemahttp://json-schema.org/draft-07/schema#

Properties

NameType
titleString
firstNameString
lastNameString

Example

{
    "title": "Mr",
    "firstName": "Seymour",
    "lastName": "Butts"
}

title

Title Title
Description The title of a name entity
TypeString
Required Yes
Default Mr
Enum
  • Mr
  • Mrs
  • Miss

firstName

Title First Name
Description The first name of a name entity
TypeString
Required Yes
Min Length 3
Max Length 100
Examples
  • Tom
  • Dick
  • Harry
  • lastName

    Title Last Name
    Description The last name of a name entity
    TypeString
    Required Yes
    Min Length 3
    Max Length 100
    Examples
  • Smith
  • Jones

  • Schema

    {
        "$id": "name.yml",
        "$schema": "http://json-schema.org/draft-07/schema#",
        "title": "Name",
        "description": "JSON schema example for a name entity",
        "type": "object",
        "examples": [
            {
                "title": "Mr",
                "firstName": "Seymour",
                "lastName": "Butts"
            }
        ],
        "properties": {
            "title": {
                "title": "Title",
                "description": "The title of a name entity",
                "type": "string",
                "default": "Mr",
                "enum": [
                    "Mr",
                    "Mrs",
                    "Miss"
                ]
            },
            "firstName": {
                "title": "First Name",
                "description": "The first name of a name entity",
                "type": "string",
                "minLength": 3,
                "maxLength": 100,
                "examples": [
                    "Tom",
                    "Dick",
                    "Harry"
                ]
            },
            "lastName": {
                "title": "Last Name",
                "description": "The last name of a name entity",
                "type": "string",
                "minLength": 3,
                "maxLength": 100,
                "examples": [
                    "Smith",
                    "Jones"
                ]
            }
        },
        "additionalProperties": false,
        "required": [
            "title",
            "firstName",
            "lastName"
        ]
    }