curl -X GET 'https://verification.didit.me/v3/events/enrichment-metrics/?days=30' \
-H 'x-api-key: YOUR_API_KEY'from didit import Didit
# Reads DIDIT_API_KEY.
client = Didit()
result = client.monitoring_events.retrieve_enrichment_metrics()
print(result)import Didit from "@didit-protocol/sdk-node";
// Reads DIDIT_API_KEY.
const didit = new Didit();
const result = await didit.monitoringEvents.retrieveEnrichmentMetrics();
console.log(result);ctx := context.Background()
// Reads DIDIT_API_KEY.
client := didit.NewClient()
result, err := client.MonitoringEvents.RetrieveEnrichmentMetrics(ctx, didit.MonitoringEventsRetrieveEnrichmentMetricsParams{})
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", result)import me.didit.Didit;
// Reads DIDIT_API_KEY.
Didit client = new Didit();
var result = client.monitoringEvents().retrieveEnrichmentMetrics();
System.out.println(result);<?php
require 'vendor/autoload.php';
use Didit\DiditClient;
// Reads DIDIT_API_KEY.
$didit = new DiditClient();
$result = $didit->monitoringEvents->retrieveEnrichmentMetrics();
print_r($result->toArray());require "didit"
# Reads DIDIT_API_KEY.
didit = Didit::Client.new
result = didit.monitoring_events.retrieve_enrichment_metrics
puts result.to_husing System;
using System.Text.Json;
using Didit;
// Reads DIDIT_API_KEY.
using var client = new DiditClient();
var result = await client.MonitoringEvents.RetrieveEnrichmentMetricsAsync();
Console.WriteLine(JsonSerializer.Serialize(result));{
"events_ingested": 128450,
"events_rejected": 214,
"enrichment_lookups": 41230,
"enrichment_cache_hits": 40118,
"enrichment_provider_calls": 1112,
"enrichment_skipped_low_value": 74320,
"unique_ips_seen": 1112,
"period_days": 30,
"cache_hit_rate": 0.973,
"unique_ip_ratio": 0.0087,
"provider_calls_per_1k_events": 8.66
}Event Enrichment Metrics API
Read event ingestion and IP-enrichment counters for a period: cache hit rate, unique-IP ratio and fresh lookups per thousand events.
curl -X GET 'https://verification.didit.me/v3/events/enrichment-metrics/?days=30' \
-H 'x-api-key: YOUR_API_KEY'from didit import Didit
# Reads DIDIT_API_KEY.
client = Didit()
result = client.monitoring_events.retrieve_enrichment_metrics()
print(result)import Didit from "@didit-protocol/sdk-node";
// Reads DIDIT_API_KEY.
const didit = new Didit();
const result = await didit.monitoringEvents.retrieveEnrichmentMetrics();
console.log(result);ctx := context.Background()
// Reads DIDIT_API_KEY.
client := didit.NewClient()
result, err := client.MonitoringEvents.RetrieveEnrichmentMetrics(ctx, didit.MonitoringEventsRetrieveEnrichmentMetricsParams{})
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", result)import me.didit.Didit;
// Reads DIDIT_API_KEY.
Didit client = new Didit();
var result = client.monitoringEvents().retrieveEnrichmentMetrics();
System.out.println(result);<?php
require 'vendor/autoload.php';
use Didit\DiditClient;
// Reads DIDIT_API_KEY.
$didit = new DiditClient();
$result = $didit->monitoringEvents->retrieveEnrichmentMetrics();
print_r($result->toArray());require "didit"
# Reads DIDIT_API_KEY.
didit = Didit::Client.new
result = didit.monitoring_events.retrieve_enrichment_metrics
puts result.to_husing System;
using System.Text.Json;
using Didit;
// Reads DIDIT_API_KEY.
using var client = new DiditClient();
var result = await client.MonitoringEvents.RetrieveEnrichmentMetricsAsync();
Console.WriteLine(JsonSerializer.Serialize(result));{
"events_ingested": 128450,
"events_rejected": 214,
"enrichment_lookups": 41230,
"enrichment_cache_hits": 40118,
"enrichment_provider_calls": 1112,
"enrichment_skipped_low_value": 74320,
"unique_ips_seen": 1112,
"period_days": 30,
"cache_hit_rate": 0.973,
"unique_ip_ratio": 0.0087,
"provider_calls_per_1k_events": 8.66
}Authorizations
Your application's API key, from Developers -> API keys in the Business Console. The primary key has full access. A named key can be scoped: none, read or write per resource, limited to some workflows or to approved sessions, to a list of IP addresses, and to an expiry date. 401 means the key is wrong, revoked or expired; 403 means no key was sent, the key has no access to this resource or action, or the request came from an address outside its IP list; 404 on a session route means the session is outside the key's workflows or statuses. A key without media access receives image, video and PDF URLs as null, and a key without sessions write receives session links and tokens as null. See https://docs.didit.me/console/api-keys.
Query Parameters
Length of the period in days. Defaults to 30; values are clamped to 1 to 365, and a non-integer value falls back to 30. The value applied is returned as period_days.
1 <= x <= 365Response
Counters and ratios for the period.
New events stored. Idempotent replays are not counted.
Items rejected inside batch requests (server and device lanes). A rejected single-event request is not counted.
Events whose public IP address was resolved, from the cache or freshly.
Lookups answered from the cache.
Lookups that needed a fresh resolution of the address.
Low-value telemetry events whose address was not already known. They never trigger a fresh resolution of their own.
Addresses that needed a fresh resolution.
The days value applied after clamping.
enrichment_cache_hits / enrichment_lookups, rounded to 4 decimals. Null when there were no lookups.
unique_ips_seen / events_ingested, rounded to 4 decimals. Null when no events were ingested.
Fresh resolutions per 1000 ingested events, rounded to 2 decimals. Null when no events were ingested.