Skip to content
K

Customisation Options

Configuration options available when generating QR codes.

The table below documents the available customisation options for QR codes generated using our app and APIs. It also outlines whether a configuration option requires a premium license key to work, or if it’s available on the free tier.

ParameterDescriptionPremium Feature?Default Value
PixelsPerModule (Required)Number of pixels per module. For example, 20 pixels per module will result in an image approximately 400x400px.No20
Content (Required)URL encoded content to be embedded within the QR code, such as a URL or text.NoNone
PrimaryColorColor of the code pattern. Must be a valid HEX code.No#000
SecondaryColorColor of the code background. Must be a valid HEX code. Default:No#FFF
EnableMarginAdds a margin around the outside of the QR code. Default: trueNotrue
ErrorCorrectionLevelUses Reed-Solomon Code to correct QR code content if partially unreadable. Accepted values: Q, H, L, MNoM
SizeSize of QR code in pixels. Default: 150No150
HeadingOptional heading string below the QR codeYesNone
SubtitleOptional subtitle string below the QR codeYesNone
FileTypeFile format for QR code. Accepted values: Svg, Jpg, Png, Gif, Ascii. Default: SvgNoSvg
LicenseLicense key to avoid watermark and use paid featuresYesN/A

If you’re using our Airtable automation script, you can use all of the above customisations. Simply append any of the above values to the URL specified within the script. For example, the snippet below adds support for the Heading and Subtitle fields:

// Fetch the field and value for the heading field
let headingContentField = table.getField(Your Heading Field");
var headingContent = record.getCellValueAsString(headingContentField);
// Fetch the field and value for the subtitle field
let subtitleContentField = table.getField(Your Subtitle Field");
var subtitleContent = record.getCellValueAsString(headingContentField);
// Update the 'url' below to include support for the heading and subtitle fields
// Note the addition of '&heading=' + encodeURIComponent(headingContent) + '&subtitle=' + encodeURIComponent(subtitleContent)
updatedRecord.fields[imageAttachmentField.name] = [
{
url: 'https://qrcodegenerator.api.littleappy.co/api/qrcode/basic?Content=' + encodeURIComponent(content) + '&heading=' + encodeURIComponent(headingContent) + '&subtitle=' + encodeURIComponent(subtitleContent) + '&FileType=Png&ErrorCorrectionLevel=' + errorCorrectionLevel + '&PixelsPerModule=20&License=' + encodeURIComponent(licenseKey),
filename: record.id + ".png"
}
];