curl --request GET \
--url https://api.uselora.com/v1/qr \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.uselora.com/v1/qr"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.uselora.com/v1/qr', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.uselora.com/v1/qr",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.uselora.com/v1/qr"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.uselora.com/v1/qr")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.uselora.com/v1/qr")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body"<string>"{
"error": "<string>",
"requestId": "<string>",
"code": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"requestId": "<string>",
"code": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"code": "plan_requires_upgrade",
"current_plan": "free",
"requestId": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"code": "plan_requires_upgrade",
"current_plan": "anonymous",
"required_capability": "removeWatermark",
"requestId": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"code": "rate_limit_exceeded",
"requestId": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"requestId": "<string>",
"code": "<string>",
"traceId": "<string>"
}Retrieve QR code
Generates a PNG image of a QR code for the given URL. Accepts both anonymous and Bearer-authenticated callers; anonymous responses encode a lora-links.com redirect URL, authenticated responses encode the destination verbatim and may use hideLogo on Basic / Business / Enterprise plans.
curl --request GET \
--url https://api.uselora.com/v1/qr \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.uselora.com/v1/qr"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.uselora.com/v1/qr', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.uselora.com/v1/qr",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.uselora.com/v1/qr"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.uselora.com/v1/qr")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.uselora.com/v1/qr")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body"<string>"{
"error": "<string>",
"requestId": "<string>",
"code": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"requestId": "<string>",
"code": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"code": "plan_requires_upgrade",
"current_plan": "free",
"requestId": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"code": "plan_requires_upgrade",
"current_plan": "anonymous",
"required_capability": "removeWatermark",
"requestId": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"code": "rate_limit_exceeded",
"requestId": "<string>",
"traceId": "<string>"
}{
"error": "<string>",
"requestId": "<string>",
"code": "<string>",
"traceId": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
The URL to generate a QR code for. Anonymous calls encode this destination behind a lora-links.com redirect (so Lora can layer analytics and abuse-blocking on the public flow); authenticated calls (Bearer API key) encode it verbatim.
32000"https://example.com"
The size of the QR code in pixels (64-2048). Defaults to 600 if not provided.
The level of error correction to use for the QR code. Defaults to L if not provided.
L, M, Q, H The foreground color of the QR code in hex format. Defaults to #000000 if not provided.
The background color of the QR code in hex format. Defaults to #ffffff if not provided.
Whether to hide the Lora logo overlay in the QR code. Requires an authenticated request (Authorization: Bearer …) with an API key on a Basic, Business, or Enterprise plan. Anonymous calls receive 403 plan_requires_upgrade; a valid Free-plan key receives 402 plan_requires_upgrade before QR options are evaluated.
The size of the margin around the QR code in modules (0-20). Defaults to 2 if not provided.
Response
The QR code as PNG bytes.
The response is of type file.
Was this page helpful?