{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "title": "CalculatePredictiveAreaByEntityRequest",
    "type": "object",
    "description": "API Path: /predict/v1/area/byEntity, get predictive area by entities",
    "properties": {
        "user_id": {
            "type": "string",
            "description": "user id"
        },
        "device_id": {
            "type": "string",
            "description": "device id"
        },
        "location": {
            "$ref": "/resources/schema/common/v1/LatLon.json",
            "description": "current location of user"
        },
        "area_type": {
            "$ref": "/resources/schema/predict/v1/AreaType.json",
            "description": "Area Type, e.g. HOME_AREA"
        },
        "entities": {
            "type": "array",
            "items": {
                "$ref": "/resources/schema/predict/v1/SupportEntity.json",
                "description": "entities used in area generation"
            }
        },
        "locale": {
            "type": "string",
            "description": "locale"
        },
        "constraint": {
            "$ref": "/resources/schema/predict/v1/Constraint.json",
            "description": "constraint related with area result"
        },
        "limit": {
            "type": "integer",
            "description": "maximum number of area in the result"
        },
        "previous_areas": {
            "type": "array",
            "items": {
                "$ref": "/resources/schema/predict/v1/PredictiveArea.json"
            }
        }
    },
    "required": [
        "area_type"
    ]
}
