# coding: utf-8

"""
    Canva Connect API

    API for building integrations with Canva via a REST api

    The version of the OpenAPI document: latest
    Generated by OpenAPI Generator (https://openapi-generator.tech)

    Do not edit the class manually.
"""  # noqa: E501


from __future__ import annotations
import json
from enum import Enum
from typing_extensions import Self


class ExportErrorCode(str, Enum):
    """
    If the export failed, this specifies the reason why it failed. This can be one of the following:  - `license_required`: The design contains [premium elements](https://www.canva.com/help/premium-elements/) that haven't been purchased. You can either buy the elements or upgrade to a Canva plan (such as Canva Pro) that has premium features, then try again. Alternatively, you can set `export_quality` to `regular` to export your document in regular quality. - `internal_failure`: The service encountered an error when exporting your design.
    """

    """
    allowed enum values
    """
    LICENSE_REQUIRED = 'license_required'
    INTERNAL_FAILURE = 'internal_failure'

    @classmethod
    def from_json(cls, json_str: str) -> Self:
        """Create an instance of ExportErrorCode from a JSON string"""
        return cls(json.loads(json_str))


