License API Dökümantasyonu
License API dökümantasyonuna hoş geldiniz. Aşağıda, her bir API son noktasının açıklamaları ve PHP ile entegrasyonu hakkında detaylı bilgiler bulunmaktadır. Verilen örnek kodlar, API ile nasıl etkileşimde bulunacağınızı gösterecektir.
API İsteği Yap
Kullanılabilir API Son Noktaları
1. Lisansı Askıya Alma (Suspend License)
https://apiv5.licenseapis.com/suspend?api_key=YOUR_API_KEY&product_code=PRODUCT_CODE&ip_address=IP_ADDRESS
PHP Örneği:
<?php
$apiKey = 'YOUR_API_KEY';
$productCode = 'PRODUCT_CODE';
$ipAddress = 'IP_ADDRESS';
$url = "https://apiv5.licenseapis.com/suspend?api_key=$apiKey&product_code=$productCode&ip_address=$ipAddress";
$response = file_get_contents($url);
$data = json_decode($response, true);
if ($data['status'] == 'success') {
echo 'Lisans başarıyla askıya alındı!';
} else {
echo 'Lisans askıya alınamadı.';
}
?>
2. Lisans Askıya Alma Kaldırma (Unsuspend License)
Askıya alınmış bir lisansı yeniden aktif hale getirir.
https://apiv5.licenseapis.com/unsuspend?api_key=YOUR_API_KEY&product_code=PRODUCT_CODE&ip_address=IP_ADDRESS
PHP Örneği:
<?php
$apiKey = 'YOUR_API_KEY';
$productCode = 'PRODUCT_CODE';
$ipAddress = 'IP_ADDRESS';
$url = "https://apiv5.licenseapis.com/unsuspend?api_key=$apiKey&product_code=$productCode&ip_address=$ipAddress";
$response = file_get_contents($url);
$data = json_decode($response, true);
if ($data['status'] == 'success') {
echo 'Lisans başarıyla askıya alma kaldırıldı!';
} else {
echo 'Lisans askıya alma kaldırılamadı.';
}
?>
3. Lisans Oluşturma (Create License)
Yeni bir lisans oluşturur.
https://apiv5.licenseapis.com/create-license?api_key=YOUR_API_KEY&product_code=PRODUCT_CODE&ip_address=IP_ADDRESS
PHP Örneği:
<?php
$apiKey = 'YOUR_API_KEY';
$productCode = 'PRODUCT_CODE';
$ipAddress = 'IP_ADDRESS';
$url = "https://apiv5.licenseapis.com/create-license?api_key=$apiKey&product_code=$productCode&ip_address=$ipAddress";
$response = file_get_contents($url);
$data = json_decode($response, true);
if ($data['status'] == 'success') {
echo 'Lisans başarıyla oluşturuldu!';
} else {
echo 'Lisans oluşturulamadı.';
}
?>
4. Lisans Sonlandırma (Terminate License)
Bir lisansı sonlandırır.
https://apiv5.licenseapis.com/terminate?api_key=YOUR_API_KEY&product_code=PRODUCT_CODE&ip_address=IP_ADDRESS
PHP Örneği:
<?php
$apiKey = 'YOUR_API_KEY';
$productCode = 'PRODUCT_CODE';
$ipAddress = 'IP_ADDRESS';
$url = "https://apiv5.licenseapis.com/terminate?api_key=$apiKey&product_code=$productCode&ip_address=$ipAddress";
$response = file_get_contents($url);
$data = json_decode($response, true);
if ($data['status'] == 'success') {
echo 'Lisans başarıyla sonlandırıldı!';
} else {
echo 'Lisans sonlandırılamadı.';
}
?>
5. Ürün Listesi (Product List)
Tüm mevcut ürünlerin listesini alır.
https://apiv5.licenseapis.com/productList?api_key=YOUR_API_KEY