> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hiperai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 건강검진

> Check if the API is running and healthy. No authentication required.

# 건강검진

API가 실행 중이고 정상인지 확인하세요. 인증이 필요하지 않습니다.

## 엔드포인트

```
GET /health
```

## 설명

이 엔드포인트를 사용하면 SecureAI 외부 API가 실행 중이고 정상인지 확인할 수 있습니다. 이 끝점에는 인증이 필요하지 않습니다.

## 요청

```bash theme={null}
curl -X GET "https://{customer.name}.hiperai.ai/api/external/health"
```

## 응답

### 성공 응답 (200)

```json theme={null}
{
  "success": true,
  "status": "healthy",
  "timestamp": "2024-01-15T10:30:00.000Z",
  "version": "1.0.0"
}
```

### 응답 필드

| 필드          | 유형  | 설명                       | 예                            |
| ----------- | --- | ------------------------ | ---------------------------- |
| `success`   | 부울  | 성공적인 상태 확인을 위해 항상 true   | `true`                       |
| `status`    | 문자열 | API의 상태                  | `"healthy"`                  |
| `timestamp` | 문자열 | ISO 8601 형식의 현재 서버 타임스탬프 | `"2024-01-15T10:30:00.000Z"` |
| `version`   | 문자열 | 현재 API 버전                | `"1.0.0"`                    |

## 사용 예

### 자바스크립트/Node.js

```javascript theme={null}
const response = await fetch('https://{customer.name}.hiperai.ai/api/external/health');
const data = await response.json();
console.log('API Status:', data.status);
```

### 파이썬

```python theme={null}
import requests

response = requests.get('https://{customer.name}.hiperai.ai/api/external/health')
data = response.json()
print('API Status:', data['status'])
```

### cURL

```bash theme={null}
curl -X GET "https://{customer.name}.hiperai.ai/api/external/health"
```

## 메모

* 이 엔드포인트에는 인증이 필요하지 않습니다.
* 이 엔드포인트를 사용하여 API 가용성을 모니터링하세요.
* 응답에는 호환성 확인을 위한 현재 API 버전이 포함됩니다.


## OpenAPI

````yaml GET /health
openapi: 3.0.3
info:
  title: SecureAI External API
  description: >
    SecureAI External API provides AI chat completion and image generation
    capabilities with knowledge base retrieval, 

    security policies, and comprehensive usage tracking. This API is designed
    for external developers 

    and integrations using API key authentication.


    ## Key Features

    - **RAG (Retrieval-Augmented Generation)**: Automatically search knowledge
    bases for relevant context

    - **Multi-Model Support**: OpenAI, Anthropic, Google, Meta, and other AI
    models

    - **Model Redundancy & Failover**: Caller-defined failover chains (primary +
    fallbacks) with per-attempt timeouts

    - **OpenAI-Compatible Endpoint**: Point any OpenAI SDK at `/api/external/v1`
    — no code changes

    - **Image Generation**: Generate and edit images using Google Gemini 2.5
    Flash Image

    - **Speech-to-Speech (S2S)**: Real-time voice conversations using OpenAI
    Realtime API with WebRTC

    - **Security Policies**: SMLTP policy enforcement, per-call Prompt Shield,
    and signed compliance receipts

    - **Usage Tracking**: Comprehensive usage monitoring, self-service quota,
    and rate limiting

    - **Knowledge Base Integration**: Access to personal and shared knowledge
    bases

    - **User Management**: Complete user, group, and role management
    capabilities

    - **Audit Logging**: Comprehensive activity and security audit logs


    ## Authentication

    All endpoints (except health check) require API key authentication using
    Bearer token:

    ```

    Authorization: Bearer sk-your-api-key-here

    ```


    ## Billing and Usage

    By default, API requests are billed to the user account that owns the API
    key. You can specify 

    a different user to bill by including the `user_id` parameter in your
    request. This allows for:

    - Multi-tenant applications with per-user billing

    - Flexible completion limit management

    - Per-user "Usage by Model" settings


    ## Rate Limits

    - Default: 60 requests per minute, 1000 requests per hour

    - Daily limits: 100 requests (configurable)

    - Monthly limits: 10,000 requests (configurable)


    ## Base URL

    ```

    https://secureai.hiperai.ai/api/external

    ```
  version: 1.1.0
  contact:
    name: SecureAI Support
    email: support@secureai.hiperai.ai
  license:
    name: Proprietary
    url: https://secureai.hiperai.ai/terms
servers:
  - url: https://secureai.hiperai.ai/api/external
    description: Production server
  - url: http://localhost:3010/api/external
    description: Development server
security:
  - ApiKeyAuth: []
tags:
  - name: System
    description: System health and status endpoints
  - name: Discovery
    description: Endpoints to discover available models, indexes, and policies
  - name: Chat
    description: AI chat completion endpoints
  - name: User Management
    description: Endpoints for managing user accounts and roles
  - name: Index Management
    description: Endpoints for managing knowledge base indexes
  - name: Group Management
    description: Endpoints for managing user groups
  - name: SMLTP Security
    description: Endpoints for managing SMLTP security policies and audit logs
  - name: Role Management
    description: Endpoints for managing user roles
  - name: Activity Logs
    description: Endpoints for retrieving activity logs
externalDocs:
  description: SecureAI Documentation
  url: https://secureai.hiperai.ai/docs
paths:
  /health:
    get:
      tags:
        - System
      summary: Health Check
      description: Check if the API is running and healthy. No authentication required.
      responses:
        '200':
          description: API is healthy
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  status:
                    type: string
                    example: healthy
                  timestamp:
                    type: string
                    format: date-time
                    example: '2024-01-15T10:30:00.000Z'
                  version:
                    type: string
                    example: 1.0.0
components:
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      description: |
        API key authentication using Bearer token format.
        Example: `Authorization: Bearer sk-your-api-key-here`

````