https://github.com/rosvik/qr.248.no
https://github.com/rosvik/qr.248.no
Last synced: 6 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/rosvik/qr.248.no
- Owner: rosvik
- License: lgpl-2.1
- Created: 2024-01-07T23:30:54.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-07-28T23:43:05.000Z (11 months ago)
- Last Synced: 2025-07-29T01:20:36.109Z (11 months ago)
- Language: Rust
- Homepage: https://qr.248.no
- Size: 93.8 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# qr.248.no
A simple Rust-based tool and API that allows you to generate QR codes.
A QR code to this repository can be found at https://qr.248.no/qr.png?data=https%3A%2F%2Fgithub.com%2Frosvik%2Fqr.248.no&size=500
## How to Use
### Setup
```bash
cargo run
```
The API will start running on `http://127.0.0.1:2339`.
### Usage
`GET /?data=&size=`
Parameters:
- `data`: The data to be encoded in the QR code.
- `size`: The width and height of the image in pixels. The generator doesn't usually give a image of the exact size requested, but rounds to a larger size where the "QR pixels" are an even amount of "image pixels". _Default: 1000_
- `format`: The format of the generated image. Supports `png`, `jpg`/`jpeg`, `bmp` and `svg`. The format can either be given as a url param, or as file extension to the route name. (`/image.jpg` or `/image?format=jpg`) _Defaults to `png`_
Example:
```bash
curl "http://127.0.0.1:2339/image-name.png?data=https://example.com/&size=300"
```