//! HTTP request handlers.
//!
//! # Return Type Convention
//!
//! Handlers follow a consistent return type pattern based on HTTP semantics:
//!
//! - **POST endpoints that create resources** (assertions, votes, epochs, supersessions, sources):
//!   Return `Result<(StatusCode, Json<T>)>` with `StatusCode::CREATED` (201)
//!
//! - **POST endpoints that modify state** (set quota, decay ranks):
//!   Return `Result<Json<T>>` with implicit `StatusCode::OK` (200)
//!
//! - **GET endpoints** (all queries, health, audit):
//!   Return `Result<Json<T>>` with implicit `StatusCode::OK` (200)
//!
//! This pattern is enforced by OpenAPI annotations and integration tests.

pub mod admin;
pub mod admission;
#[cfg(feature = "aphoria")]
pub mod aphoria;
#[cfg(feature = "aphoria")]
mod aphoria_helpers;
pub mod api_keys;
pub mod assert;
pub mod audit;
pub mod circuit_breaker;
pub mod concepts;
pub mod constraints;
pub mod epoch;
pub mod escalation;
pub mod gold_standard;
pub mod health;
pub mod layered;
pub mod meter;
pub mod metrics;
pub mod quarantine;
pub mod query;
pub mod skeptic;
pub mod source;
pub mod source_registry;
pub mod supersede;
pub mod trace;
pub mod vote;

pub use admin::decay_trust_ranks;
pub use admission::get_admission_status;
pub use api_keys::{create_api_key, list_api_keys, revoke_api_key, rotate_api_key, update_api_key};
pub use assert::create_assertion;
pub use audit::{get_audit, list_audits};
pub use circuit_breaker::{get_circuit_status, list_tripped_circuits, reset_circuit};
pub use constraints::constraints_query;
pub use epoch::create_epoch;
pub use escalation::{list_escalations, resolve_escalation};
pub use gold_standard::{
    create_gold_standard, list_gold_standards, remove_gold_standard, verify_agent,
};
pub use health::health_check;
pub use layered::layered_query;
pub use meter::{get_quota_status, set_quota_limit};
pub use quarantine::{approve_quarantine, get_quarantine, list_quarantine, reject_quarantine};
pub use query::query_assertions;
pub use skeptic::skeptic_query;
pub use source::{get_provenance, store_source};
pub use source_registry::{
    export_source_impact, get_source, get_source_impact, list_sources, quarantine_source,
    register_source, restore_source, update_source_status,
};
pub use supersede::supersede;
pub use trace::trace;
pub use vote::create_vote;

pub use concepts::{
    create_alias, delete_alias, list_aliases, parse_concept_path, resolve_alias, suggest_aliases,
};
pub use metrics::metrics_handler;

#[cfg(feature = "aphoria")]
pub use aphoria::{
    bless, export_policy, get_patterns, import_policy, list_scans, push_community_observations,
    push_observations, scan,
};
