html Code Examples | LUTERAS

LUTERAS TECH

Code Examples

cURL Example

curl -X POST https://luteras.com/api/v1/licenses/verify \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
    "license_key":"YOUR_LICENSE_KEY"
}'

Python Example

import requests

url = "https://luteras.com/api/v1/licenses/verify"

headers = {
    "x-api-key": "YOUR_API_KEY"
}

payload = {
    "license_key": "YOUR_LICENSE_KEY"
}

response = requests.post(
    url,
    json=payload,
    headers=headers
)

print(response.json())

JavaScript Example

const response = await fetch(
  "https://luteras.com/api/v1/licenses/verify",
  {
    method: "POST",
    headers: {
      "x-api-key": "YOUR_API_KEY",
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      license_key: "YOUR_LICENSE_KEY"
    })
  }
);

console.log(await response.json());

PHP Example

<?php

$ch = curl_init();

curl_setopt_array($ch, [
    CURLOPT_URL => "https://luteras.com/api/v1/licenses/verify",
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_POST => true,
    CURLOPT_HTTPHEADER => [
        "x-api-key: YOUR_API_KEY",
        "Content-Type: application/json"
    ],
    CURLOPT_POSTFIELDS => json_encode([
        "license_key" => "YOUR_LICENSE_KEY"
    ])
]);

$response = curl_exec($ch);

echo $response;
?>
← Previous