qrcode.model ============ .. py:module:: qrcode.model Classes ------- .. autoapisummary:: qrcode.model.QrCode Module Contents --------------- .. py:class:: QrCode(payload: str | bytes, border: int | None = None, box_size: int | None = None, fill_color: str | None = None, back_color: str | None = None, img_format: str | None = None, encoding: Literal['base64'] | None = None) Generates QR Codes .. py:attribute:: _border :value: 4 .. py:attribute:: _box_size :value: 10 .. py:attribute:: _fill_color :value: 'black' .. py:attribute:: _back_color :value: 'white' .. py:attribute:: _format :value: 'png' .. py:attribute:: _encoding :value: None .. py:attribute:: payload .. py:attribute:: border :value: 4 .. py:attribute:: box_size :value: 10 .. py:attribute:: fill_color :value: 'black' .. py:attribute:: back_color :value: 'white' .. py:attribute:: img_format :value: 'png' .. py:attribute:: encoding :value: None .. py:method:: from_payload(payload: str | bytes) -> io.BytesIO :classmethod: .. py:property:: image :type: io.BytesIO Create an image from the payload .. py:property:: encoded_image :type: bytes .. py:property:: content_type :type: str