Library and tool for encoding and decoding of the by square standard.

Supports creation of PAY, INVOICE and INVOICE ITEMS by square QR code
images in PNG format.

 --version

      Prints the version number of this library to standard output.

Arguments for encoding and decoding:

 --encode [-e]

      Reads XML from input and prints base32hex string to output.

 --decode [-d]

      Reads base32hex string from input and prints XML to output.

 --lines [-s]

      Enables batch processing by reading the standard input line by line.
      Every input (XML or base32hex string) must be on a separate line.
      Make sure to remove any end of line characters from XML input data.
      OS default new line characters are written after output (error) line.
      Works only with --encode or --decode argument. Ignores empty lines.

 --line-id

      Used only with '--lines' argument, ignored otherwise.
      Program expects a string ID at the beginning of a line separated
      by the character colon ':' from the input data.
      If colon is found, the ID is written to output or error line.

      Example input:  'pay_id_001:<Pay>...</Pay>'
      Example output: 'pay_id_001:0001CF3GE...'
      Example error:  'pay_id_001:Error message ...'

 --sequence

      Encode from sequence instead of XML.
      Used only with '--encode', ignored otherwise.
      Prints InvoiceID to output (or error) separated with TAB from result.

 --invoice-id

      Used only with arguments '--encode --sequence --lines', ignored otherwise.
      Prints InvoiceID to the beginning of the output (or error) line.

Arguments for creating QR code images in PNG format without logo.

 --size=pixels (default=0)

      Size of the QR code image in pixels.

 --no-logo

      Creates QR code images without by square logo.

Arguments for creating QR code images with by square logo:

 --logo-dir=PATH [-l] (default=./logo)

      Path to the logo directory containing by square logo images in PNG format.

 --input-type=xml|base32hex|image [-i] (default=xml)

      The type of data to expect from standard input when creating a QR code.

 --type=pay|invoice [-t] (deafult=pay)

      Specifies the by square type explicitly. Only used with --input-type=image

 --rotation=bottom|top|left|right [-r] (default=bottom)

      Logo rotation, meaning the placement of text in relation to the QR code.

 --variation=dark|medium|light|gray [-v] (default=dark)

      Text and frame color variation.

 --no-frame

      Uses logo image without frame around the QR code for electronic devices.
