curl --request POST \
--url https://api.iklim.co/v1/alarms/geometries/register \
--header 'Content-Type: application/json' \
--data '
{
"registrationId": "f7587d9e-2481-4b4c-818d-c8d1946851b7",
"recipientId": "Recipient 1",
"boundary": {
"cityId": 6,
"districtId": 557,
"neighborhoodId": 55766
},
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1",
"url": "https://api.customer.com/alerts/callback",
"httpMethod": "POST",
"contentType": "application/json",
"authentication": {
"type": "API_KEY",
"username": "alert-user",
"password": "******"
},
"requestHeaders": {
"source": "iklim.co",
"custom-header": "value"
},
"deliveryPolicy": {
"timeout": 60,
"maxRetries": 3,
"retryDelay": 10
}
},
"filter": {
"lightning": {
"type": "FLASH_CLOUD_TO_GROUND",
"peakCurrent": -12.5,
"inCloudHeight": 4500
},
"thunderstorm": {
"intersectsAffectedPolygon": true,
"intersectsCellPolygon": false,
"severityThreshold": "MEDIUM",
"speedThreshold": 20
},
"precipitation": {
"intensities": [
"LIGHT",
"MODERATE"
]
}
}
}
'import requests
url = "https://api.iklim.co/v1/alarms/geometries/register"
payload = {
"registrationId": "f7587d9e-2481-4b4c-818d-c8d1946851b7",
"recipientId": "Recipient 1",
"boundary": {
"cityId": 6,
"districtId": 557,
"neighborhoodId": 55766
},
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1",
"url": "https://api.customer.com/alerts/callback",
"httpMethod": "POST",
"contentType": "application/json",
"authentication": {
"type": "API_KEY",
"username": "alert-user",
"password": "******"
},
"requestHeaders": {
"source": "iklim.co",
"custom-header": "value"
},
"deliveryPolicy": {
"timeout": 60,
"maxRetries": 3,
"retryDelay": 10
}
},
"filter": {
"lightning": {
"type": "FLASH_CLOUD_TO_GROUND",
"peakCurrent": -12.5,
"inCloudHeight": 4500
},
"thunderstorm": {
"intersectsAffectedPolygon": True,
"intersectsCellPolygon": False,
"severityThreshold": "MEDIUM",
"speedThreshold": 20
},
"precipitation": { "intensities": ["LIGHT", "MODERATE"] }
}
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
registrationId: 'f7587d9e-2481-4b4c-818d-c8d1946851b7',
recipientId: 'Recipient 1',
boundary: {cityId: 6, districtId: 557, neighborhoodId: 55766},
webhook: {
accountId: '2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1',
url: 'https://api.customer.com/alerts/callback',
httpMethod: 'POST',
contentType: 'application/json',
authentication: {type: 'API_KEY', username: 'alert-user', password: '******'},
requestHeaders: {source: 'iklim.co', 'custom-header': 'value'},
deliveryPolicy: {timeout: 60, maxRetries: 3, retryDelay: 10}
},
filter: {
lightning: {type: 'FLASH_CLOUD_TO_GROUND', peakCurrent: -12.5, inCloudHeight: 4500},
thunderstorm: {
intersectsAffectedPolygon: true,
intersectsCellPolygon: false,
severityThreshold: 'MEDIUM',
speedThreshold: 20
},
precipitation: {intensities: ['LIGHT', 'MODERATE']}
}
})
};
fetch('https://api.iklim.co/v1/alarms/geometries/register', 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.iklim.co/v1/alarms/geometries/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'registrationId' => 'f7587d9e-2481-4b4c-818d-c8d1946851b7',
'recipientId' => 'Recipient 1',
'boundary' => [
'cityId' => 6,
'districtId' => 557,
'neighborhoodId' => 55766
],
'webhook' => [
'accountId' => '2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1',
'url' => 'https://api.customer.com/alerts/callback',
'httpMethod' => 'POST',
'contentType' => 'application/json',
'authentication' => [
'type' => 'API_KEY',
'username' => 'alert-user',
'password' => '******'
],
'requestHeaders' => [
'source' => 'iklim.co',
'custom-header' => 'value'
],
'deliveryPolicy' => [
'timeout' => 60,
'maxRetries' => 3,
'retryDelay' => 10
]
],
'filter' => [
'lightning' => [
'type' => 'FLASH_CLOUD_TO_GROUND',
'peakCurrent' => -12.5,
'inCloudHeight' => 4500
],
'thunderstorm' => [
'intersectsAffectedPolygon' => true,
'intersectsCellPolygon' => false,
'severityThreshold' => 'MEDIUM',
'speedThreshold' => 20
],
'precipitation' => [
'intensities' => [
'LIGHT',
'MODERATE'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.iklim.co/v1/alarms/geometries/register"
payload := strings.NewReader("{\n \"registrationId\": \"f7587d9e-2481-4b4c-818d-c8d1946851b7\",\n \"recipientId\": \"Recipient 1\",\n \"boundary\": {\n \"cityId\": 6,\n \"districtId\": 557,\n \"neighborhoodId\": 55766\n },\n \"webhook\": {\n \"accountId\": \"2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1\",\n \"url\": \"https://api.customer.com/alerts/callback\",\n \"httpMethod\": \"POST\",\n \"contentType\": \"application/json\",\n \"authentication\": {\n \"type\": \"API_KEY\",\n \"username\": \"alert-user\",\n \"password\": \"******\"\n },\n \"requestHeaders\": {\n \"source\": \"iklim.co\",\n \"custom-header\": \"value\"\n },\n \"deliveryPolicy\": {\n \"timeout\": 60,\n \"maxRetries\": 3,\n \"retryDelay\": 10\n }\n },\n \"filter\": {\n \"lightning\": {\n \"type\": \"FLASH_CLOUD_TO_GROUND\",\n \"peakCurrent\": -12.5,\n \"inCloudHeight\": 4500\n },\n \"thunderstorm\": {\n \"intersectsAffectedPolygon\": true,\n \"intersectsCellPolygon\": false,\n \"severityThreshold\": \"MEDIUM\",\n \"speedThreshold\": 20\n },\n \"precipitation\": {\n \"intensities\": [\n \"LIGHT\",\n \"MODERATE\"\n ]\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.iklim.co/v1/alarms/geometries/register")
.header("Content-Type", "application/json")
.body("{\n \"registrationId\": \"f7587d9e-2481-4b4c-818d-c8d1946851b7\",\n \"recipientId\": \"Recipient 1\",\n \"boundary\": {\n \"cityId\": 6,\n \"districtId\": 557,\n \"neighborhoodId\": 55766\n },\n \"webhook\": {\n \"accountId\": \"2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1\",\n \"url\": \"https://api.customer.com/alerts/callback\",\n \"httpMethod\": \"POST\",\n \"contentType\": \"application/json\",\n \"authentication\": {\n \"type\": \"API_KEY\",\n \"username\": \"alert-user\",\n \"password\": \"******\"\n },\n \"requestHeaders\": {\n \"source\": \"iklim.co\",\n \"custom-header\": \"value\"\n },\n \"deliveryPolicy\": {\n \"timeout\": 60,\n \"maxRetries\": 3,\n \"retryDelay\": 10\n }\n },\n \"filter\": {\n \"lightning\": {\n \"type\": \"FLASH_CLOUD_TO_GROUND\",\n \"peakCurrent\": -12.5,\n \"inCloudHeight\": 4500\n },\n \"thunderstorm\": {\n \"intersectsAffectedPolygon\": true,\n \"intersectsCellPolygon\": false,\n \"severityThreshold\": \"MEDIUM\",\n \"speedThreshold\": 20\n },\n \"precipitation\": {\n \"intensities\": [\n \"LIGHT\",\n \"MODERATE\"\n ]\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.iklim.co/v1/alarms/geometries/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"registrationId\": \"f7587d9e-2481-4b4c-818d-c8d1946851b7\",\n \"recipientId\": \"Recipient 1\",\n \"boundary\": {\n \"cityId\": 6,\n \"districtId\": 557,\n \"neighborhoodId\": 55766\n },\n \"webhook\": {\n \"accountId\": \"2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1\",\n \"url\": \"https://api.customer.com/alerts/callback\",\n \"httpMethod\": \"POST\",\n \"contentType\": \"application/json\",\n \"authentication\": {\n \"type\": \"API_KEY\",\n \"username\": \"alert-user\",\n \"password\": \"******\"\n },\n \"requestHeaders\": {\n \"source\": \"iklim.co\",\n \"custom-header\": \"value\"\n },\n \"deliveryPolicy\": {\n \"timeout\": 60,\n \"maxRetries\": 3,\n \"retryDelay\": 10\n }\n },\n \"filter\": {\n \"lightning\": {\n \"type\": \"FLASH_CLOUD_TO_GROUND\",\n \"peakCurrent\": -12.5,\n \"inCloudHeight\": 4500\n },\n \"thunderstorm\": {\n \"intersectsAffectedPolygon\": true,\n \"intersectsCellPolygon\": false,\n \"severityThreshold\": \"MEDIUM\",\n \"speedThreshold\": 20\n },\n \"precipitation\": {\n \"intensities\": [\n \"LIGHT\",\n \"MODERATE\"\n ]\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"registrationId": "f7587d9e-2481-4b4c-818d-c8d1946851b7",
"recipientId": "Recipient 1",
"boundary": {
"cityId": 6,
"districtId": 557,
"neighborhoodId": 55766
},
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1",
"url": "https://api.customer.com/alerts/callback",
"httpMethod": "POST",
"contentType": "application/json",
"authentication": {
"username": "alert-user",
"password": "******"
},
"requestHeaders": {
"source": "iklim.co",
"custom-header": "value"
},
"deliveryPolicy": {
"timeout": 60,
"maxRetries": 3,
"retryDelay": 10
}
},
"filter": {
"lightning": {
"type": "FLASH_CLOUD_TO_GROUND",
"peakCurrent": -12.5,
"inCloudHeight": 4500
},
"thunderstorm": {
"intersectsAffectedPolygon": true,
"intersectsCellPolygon": false,
"severityThreshold": "MEDIUM",
"speedThreshold": 20
},
"precipitation": {
"intensities": [
"LIGHT",
"MODERATE"
]
}
},
"createdAt": "2025-01-01T10:15:30Z",
"updatedAt": "2025-01-01T11:15:30Z",
"warnings": [
"warning-1",
"warning-2"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}Alarm kaydı oluştur
Seçilen sınırlar için webhook ve filtreleriyle kayıt oluşturur.
Webhook yaşam döngüsü
Her hesap için yalnızca bir webhook yapılandırması saklanır.
- İlk kayıt: Tam
webhookyapılandırmasınıaccountIdgöndermeden iletin. API bu yapılandırmayı oturum açmış kullanıcının hesabıyla ilişkilendirerek saklar. - İkinci ve sonraki kayıtlar: Hesap ID’sini
GET /v1/users/meendpoint’inden alın ve yalnızca aşağıdaki hesap referansını gönderin.
{
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1"
}
}
API ilgili hesap için webhook bulunduğunu doğrular ve kayıtlı URL, kimlik doğrulama, istek başlıkları ve teslimat politikasını yeniden kullanır. Gönderilen accountId için webhook bulunamazsa kayıt işlemi başarısız olur. Mevcut webhook’u değiştirmek için update işlemini kullanın.
curl --request POST \
--url https://api.iklim.co/v1/alarms/geometries/register \
--header 'Content-Type: application/json' \
--data '
{
"registrationId": "f7587d9e-2481-4b4c-818d-c8d1946851b7",
"recipientId": "Recipient 1",
"boundary": {
"cityId": 6,
"districtId": 557,
"neighborhoodId": 55766
},
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1",
"url": "https://api.customer.com/alerts/callback",
"httpMethod": "POST",
"contentType": "application/json",
"authentication": {
"type": "API_KEY",
"username": "alert-user",
"password": "******"
},
"requestHeaders": {
"source": "iklim.co",
"custom-header": "value"
},
"deliveryPolicy": {
"timeout": 60,
"maxRetries": 3,
"retryDelay": 10
}
},
"filter": {
"lightning": {
"type": "FLASH_CLOUD_TO_GROUND",
"peakCurrent": -12.5,
"inCloudHeight": 4500
},
"thunderstorm": {
"intersectsAffectedPolygon": true,
"intersectsCellPolygon": false,
"severityThreshold": "MEDIUM",
"speedThreshold": 20
},
"precipitation": {
"intensities": [
"LIGHT",
"MODERATE"
]
}
}
}
'import requests
url = "https://api.iklim.co/v1/alarms/geometries/register"
payload = {
"registrationId": "f7587d9e-2481-4b4c-818d-c8d1946851b7",
"recipientId": "Recipient 1",
"boundary": {
"cityId": 6,
"districtId": 557,
"neighborhoodId": 55766
},
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1",
"url": "https://api.customer.com/alerts/callback",
"httpMethod": "POST",
"contentType": "application/json",
"authentication": {
"type": "API_KEY",
"username": "alert-user",
"password": "******"
},
"requestHeaders": {
"source": "iklim.co",
"custom-header": "value"
},
"deliveryPolicy": {
"timeout": 60,
"maxRetries": 3,
"retryDelay": 10
}
},
"filter": {
"lightning": {
"type": "FLASH_CLOUD_TO_GROUND",
"peakCurrent": -12.5,
"inCloudHeight": 4500
},
"thunderstorm": {
"intersectsAffectedPolygon": True,
"intersectsCellPolygon": False,
"severityThreshold": "MEDIUM",
"speedThreshold": 20
},
"precipitation": { "intensities": ["LIGHT", "MODERATE"] }
}
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
registrationId: 'f7587d9e-2481-4b4c-818d-c8d1946851b7',
recipientId: 'Recipient 1',
boundary: {cityId: 6, districtId: 557, neighborhoodId: 55766},
webhook: {
accountId: '2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1',
url: 'https://api.customer.com/alerts/callback',
httpMethod: 'POST',
contentType: 'application/json',
authentication: {type: 'API_KEY', username: 'alert-user', password: '******'},
requestHeaders: {source: 'iklim.co', 'custom-header': 'value'},
deliveryPolicy: {timeout: 60, maxRetries: 3, retryDelay: 10}
},
filter: {
lightning: {type: 'FLASH_CLOUD_TO_GROUND', peakCurrent: -12.5, inCloudHeight: 4500},
thunderstorm: {
intersectsAffectedPolygon: true,
intersectsCellPolygon: false,
severityThreshold: 'MEDIUM',
speedThreshold: 20
},
precipitation: {intensities: ['LIGHT', 'MODERATE']}
}
})
};
fetch('https://api.iklim.co/v1/alarms/geometries/register', 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.iklim.co/v1/alarms/geometries/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'registrationId' => 'f7587d9e-2481-4b4c-818d-c8d1946851b7',
'recipientId' => 'Recipient 1',
'boundary' => [
'cityId' => 6,
'districtId' => 557,
'neighborhoodId' => 55766
],
'webhook' => [
'accountId' => '2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1',
'url' => 'https://api.customer.com/alerts/callback',
'httpMethod' => 'POST',
'contentType' => 'application/json',
'authentication' => [
'type' => 'API_KEY',
'username' => 'alert-user',
'password' => '******'
],
'requestHeaders' => [
'source' => 'iklim.co',
'custom-header' => 'value'
],
'deliveryPolicy' => [
'timeout' => 60,
'maxRetries' => 3,
'retryDelay' => 10
]
],
'filter' => [
'lightning' => [
'type' => 'FLASH_CLOUD_TO_GROUND',
'peakCurrent' => -12.5,
'inCloudHeight' => 4500
],
'thunderstorm' => [
'intersectsAffectedPolygon' => true,
'intersectsCellPolygon' => false,
'severityThreshold' => 'MEDIUM',
'speedThreshold' => 20
],
'precipitation' => [
'intensities' => [
'LIGHT',
'MODERATE'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.iklim.co/v1/alarms/geometries/register"
payload := strings.NewReader("{\n \"registrationId\": \"f7587d9e-2481-4b4c-818d-c8d1946851b7\",\n \"recipientId\": \"Recipient 1\",\n \"boundary\": {\n \"cityId\": 6,\n \"districtId\": 557,\n \"neighborhoodId\": 55766\n },\n \"webhook\": {\n \"accountId\": \"2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1\",\n \"url\": \"https://api.customer.com/alerts/callback\",\n \"httpMethod\": \"POST\",\n \"contentType\": \"application/json\",\n \"authentication\": {\n \"type\": \"API_KEY\",\n \"username\": \"alert-user\",\n \"password\": \"******\"\n },\n \"requestHeaders\": {\n \"source\": \"iklim.co\",\n \"custom-header\": \"value\"\n },\n \"deliveryPolicy\": {\n \"timeout\": 60,\n \"maxRetries\": 3,\n \"retryDelay\": 10\n }\n },\n \"filter\": {\n \"lightning\": {\n \"type\": \"FLASH_CLOUD_TO_GROUND\",\n \"peakCurrent\": -12.5,\n \"inCloudHeight\": 4500\n },\n \"thunderstorm\": {\n \"intersectsAffectedPolygon\": true,\n \"intersectsCellPolygon\": false,\n \"severityThreshold\": \"MEDIUM\",\n \"speedThreshold\": 20\n },\n \"precipitation\": {\n \"intensities\": [\n \"LIGHT\",\n \"MODERATE\"\n ]\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.iklim.co/v1/alarms/geometries/register")
.header("Content-Type", "application/json")
.body("{\n \"registrationId\": \"f7587d9e-2481-4b4c-818d-c8d1946851b7\",\n \"recipientId\": \"Recipient 1\",\n \"boundary\": {\n \"cityId\": 6,\n \"districtId\": 557,\n \"neighborhoodId\": 55766\n },\n \"webhook\": {\n \"accountId\": \"2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1\",\n \"url\": \"https://api.customer.com/alerts/callback\",\n \"httpMethod\": \"POST\",\n \"contentType\": \"application/json\",\n \"authentication\": {\n \"type\": \"API_KEY\",\n \"username\": \"alert-user\",\n \"password\": \"******\"\n },\n \"requestHeaders\": {\n \"source\": \"iklim.co\",\n \"custom-header\": \"value\"\n },\n \"deliveryPolicy\": {\n \"timeout\": 60,\n \"maxRetries\": 3,\n \"retryDelay\": 10\n }\n },\n \"filter\": {\n \"lightning\": {\n \"type\": \"FLASH_CLOUD_TO_GROUND\",\n \"peakCurrent\": -12.5,\n \"inCloudHeight\": 4500\n },\n \"thunderstorm\": {\n \"intersectsAffectedPolygon\": true,\n \"intersectsCellPolygon\": false,\n \"severityThreshold\": \"MEDIUM\",\n \"speedThreshold\": 20\n },\n \"precipitation\": {\n \"intensities\": [\n \"LIGHT\",\n \"MODERATE\"\n ]\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.iklim.co/v1/alarms/geometries/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"registrationId\": \"f7587d9e-2481-4b4c-818d-c8d1946851b7\",\n \"recipientId\": \"Recipient 1\",\n \"boundary\": {\n \"cityId\": 6,\n \"districtId\": 557,\n \"neighborhoodId\": 55766\n },\n \"webhook\": {\n \"accountId\": \"2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1\",\n \"url\": \"https://api.customer.com/alerts/callback\",\n \"httpMethod\": \"POST\",\n \"contentType\": \"application/json\",\n \"authentication\": {\n \"type\": \"API_KEY\",\n \"username\": \"alert-user\",\n \"password\": \"******\"\n },\n \"requestHeaders\": {\n \"source\": \"iklim.co\",\n \"custom-header\": \"value\"\n },\n \"deliveryPolicy\": {\n \"timeout\": 60,\n \"maxRetries\": 3,\n \"retryDelay\": 10\n }\n },\n \"filter\": {\n \"lightning\": {\n \"type\": \"FLASH_CLOUD_TO_GROUND\",\n \"peakCurrent\": -12.5,\n \"inCloudHeight\": 4500\n },\n \"thunderstorm\": {\n \"intersectsAffectedPolygon\": true,\n \"intersectsCellPolygon\": false,\n \"severityThreshold\": \"MEDIUM\",\n \"speedThreshold\": 20\n },\n \"precipitation\": {\n \"intensities\": [\n \"LIGHT\",\n \"MODERATE\"\n ]\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"registrationId": "f7587d9e-2481-4b4c-818d-c8d1946851b7",
"recipientId": "Recipient 1",
"boundary": {
"cityId": 6,
"districtId": 557,
"neighborhoodId": 55766
},
"webhook": {
"accountId": "2f04f1b5-1c0a-4c4e-b0a7-0ba6e9b7f2e1",
"url": "https://api.customer.com/alerts/callback",
"httpMethod": "POST",
"contentType": "application/json",
"authentication": {
"username": "alert-user",
"password": "******"
},
"requestHeaders": {
"source": "iklim.co",
"custom-header": "value"
},
"deliveryPolicy": {
"timeout": 60,
"maxRetries": 3,
"retryDelay": 10
}
},
"filter": {
"lightning": {
"type": "FLASH_CLOUD_TO_GROUND",
"peakCurrent": -12.5,
"inCloudHeight": 4500
},
"thunderstorm": {
"intersectsAffectedPolygon": true,
"intersectsCellPolygon": false,
"severityThreshold": "MEDIUM",
"speedThreshold": 20
},
"precipitation": {
"intensities": [
"LIGHT",
"MODERATE"
]
}
},
"createdAt": "2025-01-01T10:15:30Z",
"updatedAt": "2025-01-01T11:15:30Z",
"warnings": [
"warning-1",
"warning-2"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}{
"timestamp": "YYYY-mm-DDTHH:MM:SS.nnnnnnnnn",
"status": "XXX",
"error": "Error Name",
"message": "Error Message",
"path": "/endpoint/uri/here",
"messages": [
"<string>"
]
}Gövde
Kayıt gövdesi (sınır, webhook ve filtreler)
Kayıt UUID
"f7587d9e-2481-4b4c-818d-c8d1946851b7"
Alıcı kimliği. Alıcı kimliği tekil ve US-ASCII karakter setine uygun olmalıdır.
"Recipient 1"
Alarm kayıt sınırı
Alarm koşulları için izlenecek coğrafi kapsamı tanımlar. Somut sınır türü type ayırt edici alanı ile seçilir; yalnızca seçilen alt türe ait alanlar gönderilmelidir.
- ADMINISTRATIVE – il (
cityId), ilçe (districtId) ve isteğe bağlı mahalle (neighborhoodId) ile tanımlanan idari sınır. - POLYGON – dış halka koordinatlarıyla (WGS84) tanımlanan serbest kapalı poligon.
- H3INDEX – tek bir Uber H3 hücre adresiyle tanımlanan sınır.
- Option 1
- Option 2
- Option 3
Show child attributes
Show child attributes
Webhook yapılandırması
Show child attributes
Show child attributes
Alarm filtreleri
Show child attributes
Show child attributes
Yanıt
İşlem başarılı
Kayıt cevabı (zaman damgaları ve uyarılar)
Kayıt UUID
"f7587d9e-2481-4b4c-818d-c8d1946851b7"
Alıcı kimliği. Alıcı kimliği tekil ve US-ASCII karakter setine uygun olmalıdır.
"Recipient 1"
Alarm kayıt sınırı
Alarm koşulları için izlenecek coğrafi kapsamı tanımlar. Somut sınır türü type ayırt edici alanı ile seçilir; yalnızca seçilen alt türe ait alanlar gönderilmelidir.
- ADMINISTRATIVE – il (
cityId), ilçe (districtId) ve isteğe bağlı mahalle (neighborhoodId) ile tanımlanan idari sınır. - POLYGON – dış halka koordinatlarıyla (WGS84) tanımlanan serbest kapalı poligon.
- H3INDEX – tek bir Uber H3 hücre adresiyle tanımlanan sınır.
- Option 1
- Option 2
- Option 3
Show child attributes
Show child attributes
Webhook yapılandırması
Show child attributes
Show child attributes
Alarm filtreleri
Show child attributes
Show child attributes
Oluşturulma zamanı
"2025-01-01T10:15:30Z"
Güncellenme zamanı
"2025-01-01T11:15:30Z"
Uyarılar
["warning-1", "warning-2"]