# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator 2.3.33.0
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class CertificateRequestRecordApiModel(Model):
    """Certificate request record model.

    :param request_id: Request id
    :type request_id: str
    :param entity_id: Application id
    :type entity_id: str
    :param group_id: Trust group
    :type group_id: str
    :param state: Request state. Possible values include: 'New', 'Approved',
     'Rejected', 'Failure', 'Completed', 'Accepted'
    :type state: str or ~azure-iiot-opc-vault.models.CertificateRequestState
    :param type: Request type. Possible values include: 'SigningRequest',
     'KeyPairRequest'
    :type type: str or ~azure-iiot-opc-vault.models.CertificateRequestType
    :param error_info: Error diagnostics
    :type error_info: object
    :param submitted: Request time
    :type submitted:
     ~azure-iiot-opc-vault.models.VaultOperationContextApiModel
    :param approved: Approved or rejected
    :type approved: ~azure-iiot-opc-vault.models.VaultOperationContextApiModel
    :param accepted: Finished
    :type accepted: ~azure-iiot-opc-vault.models.VaultOperationContextApiModel
    """

    _attribute_map = {
        'request_id': {'key': 'requestId', 'type': 'str'},
        'entity_id': {'key': 'entityId', 'type': 'str'},
        'group_id': {'key': 'groupId', 'type': 'str'},
        'state': {'key': 'state', 'type': 'CertificateRequestState'},
        'type': {'key': 'type', 'type': 'CertificateRequestType'},
        'error_info': {'key': 'errorInfo', 'type': 'object'},
        'submitted': {'key': 'submitted', 'type': 'VaultOperationContextApiModel'},
        'approved': {'key': 'approved', 'type': 'VaultOperationContextApiModel'},
        'accepted': {'key': 'accepted', 'type': 'VaultOperationContextApiModel'},
    }

    def __init__(self, request_id=None, entity_id=None, group_id=None, state=None, type=None, error_info=None, submitted=None, approved=None, accepted=None):
        super(CertificateRequestRecordApiModel, self).__init__()
        self.request_id = request_id
        self.entity_id = entity_id
        self.group_id = group_id
        self.state = state
        self.type = type
        self.error_info = error_info
        self.submitted = submitted
        self.approved = approved
        self.accepted = accepted
