canonical: https://jentic.com/apis/fungenerators.com/fungenerators-barcode

# Fungenerators Barcode API

Fun Generators' Barcode API encodes a numeric value into a barcode image and decodes barcode images back into their numeric form. It supports many common industry-standard barcode types and exposes 4 endpoints: list of supported encode types, encode operation, list of supported decode types, and decode operation. The API is suited to back-office automations that emit barcodes for shipping labels, asset tags, or warehouse pick-lists, and to scanning workflows that lift codes off uploaded images.

## For AI agents

Encode a value into a barcode image or decode an uploaded barcode image into its numeric value across many industry standard types.

## Scope

Does not handle product-database lookups, price scraping, or QR code generation - use for barcode encoding and decoding of supported industry types only.

## Capabilities

- Encode a value into a barcode image for one of many supported types
- Decode an uploaded barcode image into its numeric or alphanumeric value
- List the barcode types supported for encoding before generating an image
- List the barcode types supported for decoding to set scanner expectations
- Embed barcode images directly into shipping labels and asset tags
- Lift codes off photographed barcodes inside operations workflows

## Use cases

### Shipping Label Barcode Generation

Warehouse and shipping teams need a barcode rendered onto each label. A label-rendering service calls GET `/barcode/encode` with the order number and barcode type and embeds the returned image into the printed label. Listing supported types via GET `/barcode/encode/types` lets the integration validate user-selected formats up front.

Example prompt: Call GET `/barcode/encode` for value 'ORD-12345' with type code128 and embed the resulting image in a shipping label

### Inventory Scan Decode

Operations teams uploading photographed barcodes from a warehouse-floor app POST the image to `/barcode/decode` and receive the numeric or alphanumeric value back. This decouples the mobile app from any embedded scanning library and keeps a server-side audit trail of every scan.

Example prompt: POST `/barcode/decode` with a base64 image of a UPC barcode and return the decoded numeric value

### Capability Discovery

Before exposing a barcode-type picker to end users, a UI calls GET `/barcode/encode/types` and GET `/barcode/decode/types` so the dropdown only shows formats the API actually supports. This avoids runtime failures when a user picks an unsupported encoding.

Example prompt: Call GET `/barcode/encode/types` and render only the listed types in the user-facing barcode picker

### Agent-Driven Label Workflow

An AI agent fields prompts like 'generate a barcode for SKU ABC-001' and chooses an appropriate type, encodes the value, and returns a base64 image. Through Jentic the bearer token stays vaulted and the agent only sees scoped operation results, so the same agent can serve many tenants safely.

Example prompt: Search Jentic for 'encode a barcode', load GET `/barcode/encode`, execute with value 'SKU-ABC-001' and type code128

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | `/barcode/encode/types` | List supported encoding barcode types |
| GET | `/barcode/encode` | Encode a value into a barcode image |
| GET | `/barcode/decode/types` | List supported decoding barcode types |
| POST | `/barcode/decode` | Decode an uploaded barcode image into its value |

## Key resources

- **Encode** — Generate a barcode image for a given value and type
- **Decode** — Decode an uploaded barcode image into its value
- **Encode Types** — List barcode types supported by the encode endpoint
- **Decode Types** — List barcode types supported by the decode endpoint

## Why Jentic

- **Setup:** Wiring the Fungenerators Barcode API by hand means passing your API key as a bearer token in the Authorization header, choosing the http or https api.fungenerators.com host, and reading the supported encode and decode types yourself. Through Jentic you install once, import the Barcode API from the API Directory, store the token once, and your agent calls it.
- **Permission scoping:** The Barcode API takes its input in query and body parameters rather than a resource path, so you limit the agent to the operations it needs, such as encoding a barcode or decoding one. You choose which operations it may call, and nothing outside that set runs.
- **Credential handling:** Your Fungenerators token is stored once, encrypted, by your own Jentic One instance and injected into the Authorization header at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'encode a barcode' or 'decode a barcode', and Jentic returns the matching GET `/barcode/encode` or POST `/barcode/decode` operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Fun Generators QR Code API** — Sister API for QR code encoding and decoding
- **Fun Generators UUID API** — Sister API for generating UUID values that can then be barcoded
- **Fun Generators Lottery API** — Sibling Fun Generators API in the same subscription family

## FAQ

### What authentication does the Fun Generators Barcode API use?

The Barcode API uses bearer-token authentication. The token is issued on the Fun Generators subscription page. Through Jentic the bearer token is stored encrypted in your Jentic One instance and injected into the Authorization header at execution time.

### Which barcode types can I encode with the Barcode API?

Call GET `/barcode/encode/types` to retrieve the live list of supported encoding formats. The API documents support for many industry-standard formats including Code 128, EAN, and UPC variants; the types endpoint is the authoritative source.

### Can I decode an uploaded image of a barcode?

Yes. POST `/barcode/decode` with the image payload and the API returns the decoded value. Use GET `/barcode/decode/types` first to confirm the format you expect to scan is supported by the decoder.

### What are the rate limits for the Fun Generators Barcode API?

Fun Generators applies per-subscription quotas rather than a documented per-second rate limit. Pace bulk encoding jobs and back off on any 429 responses; cache encoded images by value+type to avoid recomputing identical barcodes.

### How do I generate a barcode through Jentic?

Search Jentic for 'encode a barcode', load the GET `/barcode/encode` schema, and execute with value and type query parameters. The response includes the generated barcode image data.

### Is the Barcode API free?

Fun Generators runs a paid subscription model for its API family. Sign-up details and tier pricing are at http://fungenerators.com/api/barcode/. Plan integrations against a paid tier rather than a free trial for production usage.

### Can I limit what my agent is allowed to do with the Barcode API?

Yes. Because Jentic One is self-hosted, you set the rules that decide which operations and credentials your agent may use. The Barcode API takes its input in query and body parameters rather than a resource path, so you can restrict the agent to only the operations it needs, such as encoding a value with GET `/barcode/encode` or decoding an image with POST `/barcode/decode.` You choose which of these operations it may call, and nothing outside that set runs.
