Barcode Generator

Generate 1D barcodes (Code128, EAN-13, EAN-8, UPC-A, Code39, ITF-14, Codabar) via API.

Endpoint

POST https://www.acrewity.com/api/services/execute

Authentication

Include your API key in the Authorization header:

Authorization: Bearer YOUR_API_KEY

n8n Integration

This service is also available via our n8n community node: @acrewity/n8n-nodes-acrewity

Operations

Generate Barcode

Generate 1D barcodes (Code128, EAN-13, EAN-8, UPC-A, Code39, ITF-14, Codabar)

Operation ID: generate_barcode

Parameters

Parameter Type Required Default Description
text string Yes - Text or numbers to encode in barcode
format string No code128 Barcode format type Options: CODE128, EAN13, EAN8, UPC, CODE39, ITF14, codabar
width number No 2 Bar width multiplier
height number No 100 Barcode height in pixels
displayValue boolean No true Show text below barcode

Example Request

Product SKU Barcode (Code128):

{
  "service": "barcode-generator",
  "operation": "generate_barcode",
  "parameters": {
    "text": "SKU-2024-78432",
    "format": "CODE128",
    "width": 2,
    "height": 100,
    "displayValue": true
  }
}

Retail Product Barcode (EAN-13):

{
  "service": "barcode-generator",
  "operation": "generate_barcode",
  "parameters": {
    "text": "5901234123457",
    "format": "EAN13",
    "width": 2,
    "height": 80,
    "displayValue": true
  }
}

Shipping Barcode (Code39):

{
  "service": "barcode-generator",
  "operation": "generate_barcode",
  "parameters": {
    "text": "SHIP-2024-A1B2C3",
    "format": "CODE39",
    "width": 2,
    "height": 60
  }
}

Example Response

{
  "success": true,
  "result": {
    "data": {
      "filename": "barcode-1735567890123.png",
      "contentType": "image/png",
      "size": 4523,
      "content": "iVBORw0KGgoAAAANSUhEUgAA...",
      "downloadUrl": "/api/downloads/barcode-1735567890123.png",
      "downloadable": true,
      "metadata": {
        "text": "SKU-2024-78432",
        "format": "CODE128",
        "outputFormat": "png",
        "width": 2,
        "height": 100,
        "displayValue": true
      }
    }
  },
  "credits_used": 1
}

More Examples

See Visual Content Generation Examples for complete workflow examples including inventory labels, shipping labels, and retail products.