{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "properties": {
        "id": {
            "type": "string"
        },
        "customerNumber": {
            "type": "string"
        },
        "title": {
            "type": "string"
        },
        "firstName": {
            "type": "string"
        },
        "middleName": {
            "type": "string"
        },
        "lastName": {
            "type": "string"
        },
        "contactEmail": {
            "type": "string"
        },
        "contactPhone": {
            "type": "string"
        },
        "preferredLanguage": {
            "type": "string",
            "default": "en_US"
        },
        "preferredCurrency": {
            "type": "string",
            "default": "USD"
        },
        "accounts": {
            "type": "array",
            "description": "A list of OAuth accounts, associated with a customer's profile.",
            "items": {
                "type": "string"
            }
        },
        "addresses": {
            "type": "array",
            "items": {
                "$schema": "http://json-schema.org/draft-04/schema#",
                "type": "object",
                "properties": {
                    "id": {
                        "type": "string"
                    },
                    "contactName": {
                        "type": "string"
                    },
                    "companyName": {
                        "type": "string"
                    },
                    "street": {
                        "type": "string"
                    },
                    "streetNumber": {
                        "type": "string"
                    },
                    "streetAppendix": {
                        "type": "string"
                    },
                    "zipCode": {
                        "type": "string"
                    },
                    "city": {
                        "type": "string"
                    },
                    "country": {
                        "type": "string"
                    },
                    "state": {
                        "type": "string"
                    },
                    "contactPhone": {
                        "type": "string"
                    },
                    "tags": {
                        "type": "array",
                        "description": "Values like: Billing / Shipping or any other custom tag",
                        "items": {
                            "type": "string"
                        }
                    },
                    "isDefault": {
                        "type": "boolean"
                    }
                },
                "required": [
                    "contactName",
                    "isDefault"
                ]
            }
        },
        "defaultAddress": {
            "$schema": "http://json-schema.org/draft-04/schema#",
            "type": "object",
            "properties": {
                "id": {
                    "type": "string"
                },
                "contactName": {
                    "type": "string"
                },
                "companyName": {
                    "type": "string"
                },
                "street": {
                    "type": "string"
                },
                "streetNumber": {
                    "type": "string"
                },
                "streetAppendix": {
                    "type": "string"
                },
                "zipCode": {
                    "type": "string"
                },
                "city": {
                    "type": "string"
                },
                "country": {
                    "type": "string"
                },
                "state": {
                    "type": "string"
                },
                "contactPhone": {
                    "type": "string"
                },
                "tags": {
                    "type": "array",
                    "description": "Values like: Billing / Shipping or any other custom tag",
                    "items": {
                        "type": "string"
                    }
                },
                "isDefault": {
                    "type": "boolean"
                }
            },
            "required": [
                "contactName",
                "isDefault"
            ],
            "description": "Default address of the customer"
        }
    },
    "required": [
        "contactEmail"
    ]
}