{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "properties": {
        "items": {
            "type": "array",
            "items": {
                "title": "Application Certificate Authority",
                "description": "Schema for a single Application Certificate Authority",
                "type": "object",
                "properties": {
                    "id": {
                        "type": "string",
                        "pattern": "^[A-Fa-f\\d]{24}$"
                    },
                    "applicationCertificateAuthorityId": {
                        "type": "string",
                        "pattern": "^[A-Fa-f\\d]{24}$"
                    },
                    "applicationId": {
                        "type": "string",
                        "pattern": "^[A-Fa-f\\d]{24}$"
                    },
                    "creationDate": {
                        "type": "string",
                        "format": "date-time"
                    },
                    "lastUpdated": {
                        "type": "string",
                        "format": "date-time"
                    },
                    "status": {
                        "type": "string",
                        "enum": [
                            "active",
                            "inactive"
                        ]
                    },
                    "name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255
                    },
                    "description": {
                        "type": "string",
                        "maxLength": 32767
                    },
                    "caBundle": {
                        "type": "string",
                        "maxLength": 32767,
                        "minLength": 50
                    },
                    "caInfo": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "serialNumber": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 1024
                                },
                                "fingerprint": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 1024
                                },
                                "commonName": {
                                    "type": "string",
                                    "maxLength": 1024
                                },
                                "issuerName": {
                                    "type": "string",
                                    "maxLength": 1024
                                },
                                "notValidBefore": {
                                    "type": "string",
                                    "format": "date-time"
                                },
                                "notValidAfter": {
                                    "type": "string",
                                    "format": "date-time"
                                }
                            }
                        }
                    }
                }
            }
        },
        "count": {
            "type": "integer"
        },
        "totalCount": {
            "type": "integer"
        },
        "perPage": {
            "type": "integer"
        },
        "page": {
            "type": "integer"
        },
        "filter": {
            "type": "string"
        },
        "filterField": {
            "type": "string"
        },
        "sortField": {
            "type": "string"
        },
        "sortDirection": {
            "type": "string",
            "enum": [
                "asc",
                "desc",
                "ASC",
                "DESC",
                ""
            ]
        },
        "applicationId": {
            "type": "string",
            "pattern": "^[A-Fa-f\\d]{24}$"
        }
    }
}