API Reference

    API Reference 개요

    Simple AI Inference에서 지원하는 API Reference는 다음과 같습니다.

    API명API상세 설명
    Chat Completions APIPOST /v1/chat/completionsOpenAI의 Completions API와 호환되며 OpenAI Python client에서 사용할 수 있습니다.
    Completions APIPOST /v1/completionsOpenAI의 Completions API와 호환되며 OpenAI Python client에서 사용할 수 있습니다.
    Embedding APIPOST /v1/embeddings텍스트를 고차원 벡터(임베딩)로 변환하여, 텍스트 간 유사도 계산, 클러스터링, 검색 등 다양한 자연어 처리(NLP) 작업에 활용할 수 있습니다.
    Rerank APIPOST /v2/rerank임베딩 모델이나 크로스 인코더 모델을 적용하여 단일 쿼리와 문서 목록의 각 항목 간 관련성을 예측합니다.
    Responses APIPOST /v1/responsesOpenAI의 Responses API와 호환되며 텍스트, 이미지, 파일 입력으로 텍스트 또는 JSON 출력을 생성할 수 있으며, 함수 호출 및 빌트인 도구를 지원합니다.
    Tokenize APIPOST /tokenize텍스트를 토큰 ID로 변환합니다. Completion 방식과 Chat 방식을 지원합니다.
    Models APIGET /v1/models배포된 모델의 목록을 반환합니다. OpenAI의 Models API와 호환됩니다.
    표. Simple AI Inference 지원 API 목록

    Chat Completions API

    POST /v1/chat/completions
    

    개요

    Chat Completions API는 OpenAI의 Completions API와 호환되며 OpenAI Python client에서 사용할 수 있습니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드POST
    Headersobject요청 시 필요한 헤더 정보{ “Content-Type”: “application/json”, “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parametersobject요청 본문에 포함되는 파라미터{“model”: “google/gemma-4-31B-it”, “messages”: [{“role”: “user”, “content”: “hello”}], “stream”: true }
    표. Chat Completions API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Chat Completions API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Chat Completions API - Query Parameters

    Body Parameters

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    model-string응답 생성에 사용할 모델을 지정“google/gemma-4-31B-it”
    messagesrolestring대화 내역을 포함하는 메시지 리스트[ { “role” : “user” , “content” : “message” }]
    frequency_penalty-number반복되는 토큰에 대한 패널티를 조정0-2.0 ~ 2.00.5
    logit_bias-object특정 토큰의 확률을 조정(예시: { “100”: 2.0 })nullKey: 토큰 ID, Value: -100 ~ 100{ “100”: 2.0 }
    logprobs-boolean상위 logprobs 개수의 토큰 확률을 반환falsetrue, falsetrue
    max_completion_tokens-integer최대 생성 토큰 수를 제한None0 ~ 모델 최대값100
    max_tokens (Deprecated)-integer최대 생성 토큰 수를 제한None0 ~ 모델 최대값100
    n-integer생성할 응답 개수를 지정13
    presence_penalty-number기존 텍스트에 포함된 토큰에 대한 패널티를 조정0-2.0 ~ 2.01.0
    seed-integer랜덤성 제어를 위한 시드 값을 지정None
    stop-string / array / null특정 문자열이 나타나면 생성을 중단null"\n"
    stream-boolean스트리밍 방식으로 결과를 반환할지 여부falsetrue/falsetrue
    stream_optionsinclude_usage, continuous_usage_statsobject스트리밍 옵션을 제어(예시: 사용량 통계 포함 여부)null{ “include_usage”: true }
    temperature-number생성 결과의 창의성을 조절(높을수록 무작위)10.0 ~ 1.00.7
    tool_choice-string어떤 Tool이 모델에 의해 호출될지 조정
    • none: Tool을 호출하지 않음
    • auto: 모델이 메시지를 생성할지 Tool을 호출할지 선택
    • required: 모델이 1개 이상의 Tool을 호출
    • tool이 없을 때: none
    • tool이 있을 때: auto
    tools-array모델이 호출할 수 있는 Tool의 리스트
    • functions만 Tool로 지원
    • 128 functions까지 지원
    None
    top_logprobs-integer0과 20사이의 정수 가장 확률이 높은 토큰의 수를 지정
    • 각각은 log 확률값과 연관됨
    • logprobs가 true로 선택되어야 함
    • completions에 대한 top k에 대한 확률값을 보여 줌
    None0 ~ 203
    top_p-number토큰의 샘플링 확률을 제한(높을수록 더 많은 토큰 고려)10.0 ~ 1.00.9
    prompt_safety_model-stringPrompt 검사를 위한 guard 모델 지정. 설정 시 guard 모델로 prompt를 먼저 검사하며, unsafe로 판단되면 guard 결과를 반환하고 safe이면 model 파라미터에 지정된 모델로 요청을 처리“meta-llama/Llama-Guard-4-12B”
    chat_template_kwargs-object템플릿 렌더러에 전달할 추가 키워드 인자. 모델별 reasoning 설정을 위해 사용(자세한 내용은 Reasoning 설정 참고)null{ “enable_thinking”: true }
    표. Chat Completions API - Body Parameters

    Example

    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/chat/completions \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "google/gemma-4-31B-it",
          "messages": [
          {
            "role": "assistant",
            "content": "You are a helpful assistant."
          },
          {
            "role": "user",
            "content": "한국의 수도는 어디입니까?"
          }
        ]
    }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/chat/completions \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "google/gemma-4-31B-it",
          "messages": [
          {
            "role": "assistant",
            "content": "You are a helpful assistant."
          },
          {
            "role": "user",
            "content": "한국의 수도는 어디입니까?"
          }
        ]
    }'
    코드 블럭. Chat Completions API Request Example

    Response

    200 OK

    NameTypeDescription
    idstring응답의 고유 식별자
    objectstring응답 객체의 타입(예시: “chat.completion”)
    createdinteger생성 시각(Unix timestamp, 초 단위)
    modelstring사용된 모델의 이름
    choicesarray생성된 응답 선택지 목록
    choices[].indexinteger해당 choice의 인덱스
    choices[].messageobject생성된 메시지 객체
    choices[].message.rolestring메시지 작성자의 역할(예시: “assistant”)
    choices[].message.contentstring생성된 메시지의 실제 내용
    choices[].message.reasoningstring생성된 추론 메시지의 실제 내용
    choices[].message.tool_callsarray (optional)도구 호출 정보(모델/설정에 따라 포함될 수 있음)
    choices[].finish_reasonstring or null응답이 종료된 이유(예시: “stop”, “length” 등)
    choices[].stop_reasonobject or null추가 중단 이유 세부 정보
    choices[].logprobsobject or null토큰 별 로그 확률 정보(설정에 따라 포함)
    usageobject토큰 사용량 통계
    usage.prompt_tokensinteger입력 프롬프트에 사용된 토큰 수
    usage.completion_tokensinteger생성된 응답에 사용된 토큰 수
    usage.total_tokensinteger전체 토큰 수(입력 + 출력)
    표. Chat Completions API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    400Bad Request
    422Prompt Guard 등 정책에 의해 요청이 거절된 경우
    500Internal Server Error
    표. Chat Completions API - Error Code

    Example

    배경색 변경
    {
      "id": "chatcmpl-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "object": "chat.completion",
      "created": 1749702816,
      "model": "google/gemma-4-31B-it",
      "choices": [
        {
          "index": 0,
          "message": {
            "role": "assistant",
            "reasoning": null,
            "content": "한국의 수도는 서울입니다.",
            "tool_calls": []
          },
          "logprobs": null,
          "finish_reason": "stop",
          "stop_reason": null
        }
      ],
      "usage": {
        "prompt_tokens": 54,
        "total_tokens": 62,
        "completion_tokens": 8,
        "prompt_tokens_details": null
      },
      "prompt_logprobs": null
    }
    {
      "id": "chatcmpl-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "object": "chat.completion",
      "created": 1749702816,
      "model": "google/gemma-4-31B-it",
      "choices": [
        {
          "index": 0,
          "message": {
            "role": "assistant",
            "reasoning": null,
            "content": "한국의 수도는 서울입니다.",
            "tool_calls": []
          },
          "logprobs": null,
          "finish_reason": "stop",
          "stop_reason": null
        }
      ],
      "usage": {
        "prompt_tokens": 54,
        "total_tokens": 62,
        "completion_tokens": 8,
        "prompt_tokens_details": null
      },
      "prompt_logprobs": null
    }
    코드 블럭. Chat Completions API Response Example

    Prompt Guard 응답

    prompt_safety_model 파라미터를 설정한 경우, guard 모델이 prompt를 먼저 검사합니다.

    • safe: model 파라미터에 지정된 모델로 요청이 그대로 처리됩니다.
    • unsafe: 아래와 같은 형태의 guard 결과를 반환하며 요청이 중단됩니다.
    배경색 변경
    {
      "guard_result": "unsafe",
      "categories": ["S1", "S2"],
      "categories_description": ["Violent Crimes", "Non-Violent Crimes"],
      "messages": [
        "Cannot fulfill the request due to violent content.",
        "Cannot respond as it may promote illegal activities."
      ]
    }
    {
      "guard_result": "unsafe",
      "categories": ["S1", "S2"],
      "categories_description": ["Violent Crimes", "Non-Violent Crimes"],
      "messages": [
        "Cannot fulfill the request due to violent content.",
        "Cannot respond as it may promote illegal activities."
      ]
    }
    코드 블럭. Chat Completions API Prompt Guard 응답 Example (unsafe)

    Reasoning 설정

    chat_template_kwargs 파라미터를 통해 모델별 reasoning(추론 모드) 설정을 제어할 수 있습니다. 모델마다 기본 동작과 지원하는 옵션이 다릅니다.

    모델기본 reasoningchat_template_kwargs 설정설명
    zai-org/GLM-5.2켜짐 (Think Max)
    • Think Max(기본): {“reasoning_effort”: “max”} 또는 생략 — 가장 깊은 추론
    • Think High: {“reasoning_effort”: “high”} — 균형된 깊이와 지연
    • Non-think: {“enable_thinking”: false} — 빠른 응답, 추론 없음
    reasoning_effort로 추론 깊이 조절, enable_thinking=false로 비활성화
    Qwen/Qwen3.6-27B켜짐
    • 비활성화: {“enable_thinking”: false}
    기본적으로 reasoning이 활성화되어 있으며, 필요시 비활성화 가능
    google/gemma-4-31B-it꺼짐
    • 활성화: {“enable_thinking”: true}
    기본적으로 reasoning이 비활성화되어 있으며, 필요시 활성화 가능
    openai/gpt-oss-120bmedium
    • {“reasoning_effort”: “low”}
    • {“reasoning_effort”: “medium”} (기본)
    • {“reasoning_effort”: “high”}
    reasoning_effort로 추론 깊이 조절 (기본값: medium)
    표. Chat Completions API - 모델별 Reasoning 설정
    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/chat/completions \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "zai-org/GLM-5.2",
        "messages": [
          {
            "role": "user",
            "content": "복잡한 수학 문제를 풀어주세요."
          }
        ],
        "chat_template_kwargs": {
          "reasoning_effort": "high"
        }
      }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/chat/completions \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "zai-org/GLM-5.2",
        "messages": [
          {
            "role": "user",
            "content": "복잡한 수학 문제를 풀어주세요."
          }
        ],
        "chat_template_kwargs": {
          "reasoning_effort": "high"
        }
      }'
    코드 블럭. Chat Completions API Reasoning 설정 Example

    참고

    Completions API

    POST /v1/completions
    

    개요

    Completions API는 OpenAI의 Completions API와 호환되며 OpenAI Python client에서 사용할 수 있습니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드POST
    Headersobject요청 시 필요한 헤더 정보{ “Content-Type”: “application/json”, “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parametersobject요청 본문에 포함되는 파라미터{“model”: “google/gemma-4-31B-it”, “prompt” : “hello”, “stream”: true }
    표. Completions API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Completions API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Completions API - Query Parameters

    Body Parameters

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    model-string응답 생성에 사용할 모델을 지정“google/gemma-4-31B-it”
    prompt-array, string사용자 입력 텍스트""
    echo-boolean입력 텍스트를 출력에 포함시킬지 여부falsetrue/falsetrue
    frequency_penalty-number반복되는 토큰에 대한 패널티를 조정0-2.0 ~ 2.00.5
    logit_bias-object특정 토큰의 확률을 조정 (예시: { “100”: 2.0 })nullKey: 토큰 ID, Value: -100~100{ “100”: 2.0 }
    logprobs-integer상위 logprobs 개수의 토큰 확률을 반환null1 ~ 55
    max_completion_tokens-integer최대 생성 토큰 수를 제한None0~모델 최대 값100
    max_tokens (Deprecated)-integer최대 생성 토큰 수를 제한None0~모델 최대 값100
    n-integer생성할 응답 개수를 지정13
    presence_penalty-number기존 텍스트에 포함된 토큰에 대한 패널티를 조정0-2.0 ~ 2.01.0
    seed-integer랜덤성 제어를 위한 시드값을 지정None
    stop-string / array / null특정 문자열이 나타나면 생성을 중단null"\n"
    stream-boolean스트리밍 방식으로 결과를 반환할지 여부falsetrue/falsetrue
    stream_optionsinclude_usage, continuous_usage_statsobject스트리밍 옵션을 제어 (예시: 사용량 통계 포함 여부)null{ “include_usage”: true }
    temperature-number생성 결과의 창의성을 조절 (높을수록 무작위)10.0 ~ 1.00.7
    top_p-number토큰의 샘플링 확률을 제한 (높을수록 더 많은 토큰 고려)10.0 ~ 1.00.9
    표. Completions API - Body Parameters

    Example

    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/completions \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "google/gemma-4-31B-it",
        "prompt": "한국의 수도는 어디입니까?",
        "temperature": 0.7
      }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/completions \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "google/gemma-4-31B-it",
        "prompt": "한국의 수도는 어디입니까?",
        "temperature": 0.7
      }'
    코드 블럭. Completions API Request Example

    Response

    200 OK

    NameTypeDescription
    idstring응답의 고유 식별자
    objectstring응답 객체의 타입(예시: “text_completion”)
    createdinteger생성 시각(Unix timestamp, 초 단위)
    modelstring사용된 모델의 이름
    choicesarray생성된 응답 선택지 목록
    choices[].indexnumber해당 choice의 인덱스
    choices[].textstring생성된 텍스트 객체
    choices[].logprobsobject토큰 별 로그 확률 정보(설정에 따라 포함)
    choices[].finish_reasonstring or null응답이 종료된 이유(예시: “stop”, “length” 등)
    choices[].stop_reasonobject or null추가 중단 이유 세부 정보
    choices[].prompt_logprobsobject or null입력 프롬프트 토큰별 로그 확률(널 가능)
    usageobject토큰 사용량 통계
    usage.prompt_tokensnumber입력 프롬프트에 사용된 토큰 수
    usage.total_tokensnumber전체 토큰 수(입력 + 출력)
    usage.completion_tokensnumber생성된 응답에 사용된 토큰 수
    usage.prompt_tokens_detailsobject프롬프트 토큰 사용 세부 정보
    표. Completions API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    400Bad Request
    422Prompt Guard 등 정책에 의해 요청이 거절된 경우
    500Internal Server Error
    표. Completions API - Error Code

    Example

    배경색 변경
    {
      "id": "cmpl-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "object": "text_completion",
      "created": 1749702612,
      "model": "google/gemma-4-31B-it",
      "choices": [
        {
          "index": 0,
          "text": " \nOur capital city is Seoul. \n\nA. 1\nB. ",
          "logprobs": null,
          "finish_reason": "length",
          "stop_reason": null,
          "prompt_logprobs": null
        }
      ],
      "usage": {
        "prompt_tokens": 9,
        "total_tokens": 25,
        "completion_tokens": 16,
        "prompt_tokens_details": null
      }
    }
    {
      "id": "cmpl-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "object": "text_completion",
      "created": 1749702612,
      "model": "google/gemma-4-31B-it",
      "choices": [
        {
          "index": 0,
          "text": " \nOur capital city is Seoul. \n\nA. 1\nB. ",
          "logprobs": null,
          "finish_reason": "length",
          "stop_reason": null,
          "prompt_logprobs": null
        }
      ],
      "usage": {
        "prompt_tokens": 9,
        "total_tokens": 25,
        "completion_tokens": 16,
        "prompt_tokens_details": null
      }
    }
    코드 블럭. Completions API Response Example

    참고

    Embedding API

    POST /v1/embeddings
    

    개요

    Embedding API는 주어진 텍스트를 고차원 벡터(임베딩)로 변환하여, 텍스트 간 유사도 계산, 클러스터링, 검색 등 다양한 자연어 처리(NLP) 작업에 활용할 수 있도록 지원합니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드POST
    Headersobject요청 시 필요한 헤더 정보{ “Content-Type”: “application/json”, “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parametersobject요청 본문에 포함되는 파라미터{ “model”: “Qwen/Qwen3-VL-Embedding-8B”, “input”: “What is the capital of France?”}
    표. Embedding API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Embedding API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Embedding API - Query Parameters

    Body Parameters

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    model-string응답 생성에 사용할 모델을 지정“Qwen/Qwen3-VL-Embedding-8B”
    input-array사용자의 검색 질의 또는 질문“What is the capital of France?"
    encoding_format-string임베딩을 반환할 형식을 지정“float”“float”, “base64”[0.01319122314453125,0.057220458984375, … (생략)
    truncate_prompt_tokens-integer입력 토큰 수를 제한> 0100
    표. Embedding API - Body Parameters

    Example

    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/embeddings \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "Qwen/Qwen3-VL-Embedding-8B",
        "input": "What is the capital of France?",
    	"encoding_format": "float"
      }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/embeddings \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "Qwen/Qwen3-VL-Embedding-8B",
        "input": "What is the capital of France?",
    	"encoding_format": "float"
      }'
    코드 블럭. Embedding API Request Example

    Response

    200 OK

    NameTypeDescription
    idstring응답의 고유 식별자
    objectstring응답 객체의 타입(예시: “list” )
    creatednumber생성 시각(Unix timestamp, 초 단위)
    modelstring사용된 모델의 이름
    dataarray임베딩 결과를 담은 객체 배열
    data.indexnumber입력 텍스트의 순서 인덱스 (예시: 입력 텍스트가 여러 개일 경우 순서를 나타냄)
    data.objectstring데이터 항목 타입
    data.embeddingarray입력 텍스트의 임베딩 벡터 값 (모델의 임베딩 차원에 따른 float 배열로 구성)
    usageobject토큰 사용량 통계
    usage.prompt_tokensnumber입력 프롬프트에 사용된 토큰 수
    usage.total_tokensnumber전체 토큰 수(입력 + 출력)
    usage.completion_tokensnumber생성된 응답에 사용된 토큰 수
    usage.prompt_tokens_detailsobject프롬프트 토큰의 세부 정보
    표. Embedding API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    400Bad Request
    422Prompt Guard 등 정책에 의해 요청이 거절된 경우
    500Internal Server Error
    표. Embedding API - Error Code

    Example

    배경색 변경
    {
      "id":"embd-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "object":"list",
      "created":1749035024,
      "model":"Qwen/Qwen3-VL-Embedding-8B",
      "data":[
        {
          "index":0,
          "object":"embedding",
          "embedding":
          [0.01319122314453125,0.057220458984375,-0.028533935546875,-0.0008697509765625,-0.01422119140625,0.033416748046875,-0.0062408447265625,-0.04364013671875,-0.004497528076171875,0.0008072853088378906,-0.0193328857421875,0.041168212890625,-0.019317626953125,-0.0188751220703125,-0.047088623046875,
          -0 ....(생략)
    
          -0.05706787109375,-0.0147705078125]
        }
      ],
      "usage":
      {
        "prompt_tokens":9,
        "total_tokens":9,
        "completion_tokens":0,
        "prompt_tokens_details":null
      }
    }
    {
      "id":"embd-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "object":"list",
      "created":1749035024,
      "model":"Qwen/Qwen3-VL-Embedding-8B",
      "data":[
        {
          "index":0,
          "object":"embedding",
          "embedding":
          [0.01319122314453125,0.057220458984375,-0.028533935546875,-0.0008697509765625,-0.01422119140625,0.033416748046875,-0.0062408447265625,-0.04364013671875,-0.004497528076171875,0.0008072853088378906,-0.0193328857421875,0.041168212890625,-0.019317626953125,-0.0188751220703125,-0.047088623046875,
          -0 ....(생략)
    
          -0.05706787109375,-0.0147705078125]
        }
      ],
      "usage":
      {
        "prompt_tokens":9,
        "total_tokens":9,
        "completion_tokens":0,
        "prompt_tokens_details":null
      }
    }
    코드 블럭. Embedding API Response Example

    참고

    Rerank API

    POST /v2/rerank
    

    개요

    Rerank API는 임베딩 모델이나 크로스 인코더 모델을 적용하여 단일 쿼리와 문서 목록의 각 항목 간 관련성을 예측할 수 있습니다. 일반적으로 문장 쌍의 점수는 두 문장 간 유사도를 0에서 1 사이의 범위로 나타냅니다.

    • Embedding 기반 모델: Query와 문서를 각각 벡터로 바꾼 뒤, 벡터간의 유사도(예시: 코사인 유사도)를 측정하여 점수를 계산합니다.
    • Reranker(Cross-Encoder) 기반 모델: Query와 문서를 한쌍으로 모델에 넣어서 평가합니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드POST
    Headersobject요청 시 필요한 헤더 정보{ “Content-Type”: “application/json”, “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parametersobject요청 본문에 포함되는 파라미터{ “model”: “Qwen/Qwen3-VL-Reranker-8B”, “query”: …, “documents”: […] }
    표. Rerank API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Rerank API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Rerank API - Query Parameters

    Body Parameters

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    model-string응답 생성에 사용할 모델을 지정“Qwen/Qwen3-VL-Reranker-8B”
    query-string사용자의 검색 질의 또는 질문“What is the capital of France?"
    documents-array재정렬 대상인 문서 목록최대 모델 입력 길이 제한[“The capital of France is Paris.”]
    top_n-integer반환할 상위 문서 개수를 지정(0이면 전체 반환)0> 05
    truncate_prompt_tokens-integer입력 토큰 수를 제한> 0100
    표. Rerank API - Body Parameters

    Example

    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v2/rerank \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "Qwen/Qwen3-VL-Reranker-8B",
        "query": "What is the capital of France?",
        "documents": [
          "The capital of France is Paris.",
          "France capital city is known for the Eiffel Tower.",
          "Paris is located in the north-central part of France."
        ],
        "top_n": 2, 
        "truncate_prompt_tokens": 512
      }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v2/rerank \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "Qwen/Qwen3-VL-Reranker-8B",
        "query": "What is the capital of France?",
        "documents": [
          "The capital of France is Paris.",
          "France capital city is known for the Eiffel Tower.",
          "Paris is located in the north-central part of France."
        ],
        "top_n": 2, 
        "truncate_prompt_tokens": 512
      }'
    코드 블럭. Rerank API Request Example

    Response

    200 OK

    NameTypeDescription
    idstringAPI 응답의 고유 식별자(UUID 형식)
    modelstring결과를 생성한 모델의 이름
    usageobject요청에 사용된 리소스 정보를 담은 객체
    usage.prompt_tokensinteger입력 프롬프트에 사용된 토큰 수
    usage.total_tokensinteger요청 처리에 사용된 총 토큰 수
    resultsarray쿼리와 관련된 문서들의 결과를 담은 배열
    results[].indexinteger결과 배열 내의 순서 번호
    results[].documentobject검색된 문서의 내용을 담은 객체
    results[].document.textstring검색된 문서의 실제 텍스트 내용
    results[].document.multi_modalobject or null멀티모달 문서 정보
    results[].relevance_scorefloat쿼리와 문서 간의 관련성을 나타내는 점수(0 ~ 1)
    표. Rerank API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    400Bad Request
    422Prompt Guard 등 정책에 의해 요청이 거절된 경우
    500Internal Server Error
    표. Rerank API - Error Code

    Example

    배경색 변경
    {
      "id": "score-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "model": "Qwen/Qwen3-VL-Reranker-8B",
      "usage": {
        "prompt_tokens": 54,
        "total_tokens": 54
      },
      "results": [
        {
          "index": 0,
          "document": {
            "text": "The capital of France is Paris.",
            "multi_modal": null
          },
          "relevance_score": 0.9237253665924072
        },
        {
          "index": 2,
          "document": {
            "text": "Paris is located in the north-central part of France.",
            "multi_modal": null
          },
          "relevance_score": 0.9181006550788879
        }
      ]
    }
    {
      "id": "score-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "model": "Qwen/Qwen3-VL-Reranker-8B",
      "usage": {
        "prompt_tokens": 54,
        "total_tokens": 54
      },
      "results": [
        {
          "index": 0,
          "document": {
            "text": "The capital of France is Paris.",
            "multi_modal": null
          },
          "relevance_score": 0.9237253665924072
        },
        {
          "index": 2,
          "document": {
            "text": "Paris is located in the north-central part of France.",
            "multi_modal": null
          },
          "relevance_score": 0.9181006550788879
        }
      ]
    }
    코드 블럭. Rerank API Response Example

    참고

    Responses API

    POST /v1/responses
    

    개요

    Responses API는 OpenAI의 Responses API와 호환되며 OpenAI Python client에서 사용할 수 있습니다. 텍스트, 이미지, 파일 입력으로 텍스트 또는 JSON 출력을 생성할 수 있으며, 함수 호출 및 빌트인 도구(web search, file search 등)를 지원합니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드POST
    Headersobject요청 시 필요한 헤더 정보{ “Content-Type”: “application/json”, “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parametersobject요청 본문에 포함되는 파라미터{“model”: “openai/gpt-oss-120b”, “input”: “한국의 수도는 어디입니까?” }
    표. Responses API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Responses API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Responses API - Query Parameters

    Body Parameters

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    model-string응답 생성에 사용할 모델 ID“openai/gpt-oss-120b”
    input-string / array모델에 대한 텍스트/이미지/파일 입력. 문자열 또는 InputItem 배열“Tell me a story” 또는 [{ “role” : “user”, “content” : “message” }]
    instructions-string모델 컨텍스트에 삽입되는 시스템(개발자) 메시지null“You are a helpful assistant."
    temperature-number샘플링 온도. 높을수록 무작위, 낮을수록 결정적10 ~ 20.7
    top_p-numbernucleus 샘플링 확률 제한. temperature와 함께 변경 권장하지 않음10 ~ 10.9
    top_logprobs-integer각 토큰 위치에서 반환할 최대 로그 확률 토큰 수null0 ~ 203
    stream-boolean스트리밍 방식으로 결과를 반환할지 여부falsetrue/falsetrue
    stream_optionsinclude_usageobject스트리밍 옵션을 제어(예시: 사용량 통계 포함 여부)null{ “include_usage”: true }
    tools-array모델이 호출할 수 있는 도구 목록(빌트인 도구 + function)
    • 빌트인 도구: web_search, file_search, code_interpreter 등
    • function: 128개까지 지원
    []
    tool_choice-string / object모델이 도구를 선택하는 방식
    • none: 도구를 호출하지 않음
    • auto: 모델이 메시지를 생성할지 도구를 호출할지 선택
    • required: 모델이 1개 이상의 도구를 호출
    • 도구가 없을 때: none
    • 도구가 있을 때: auto
    prompt_safety_model-stringPrompt 검사를 위한 guard 모델 지정. 설정 시 guard 모델로 prompt를 먼저 검사하며, unsafe로 판단되면 guard 결과를 반환하고 safe이면 model 파라미터에 지정된 모델로 요청을 처리“meta-llama/Llama-Guard-4-12B”
    chat_template_kwargs-object템플릿 렌더러에 전달할 추가 키워드 인자. 모델별 reasoning 설정을 위해 사용(gpt-oss-120b는 reasoning 파라미터 사용, 자세한 내용은 Reasoning 설정 참고)null{ “enable_thinking”: true }
    reasoning-objectgpt-oss-120b 모델의 reasoning 설정. effort 필드로 추론 깊이 지정(low/medium/high, 기본값 medium)null{ “effort”: “high” }
    표. Responses API - Body Parameters

    Example

    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/responses \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "input": "한국의 수도는 어디입니까?"
      }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/responses \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "input": "한국의 수도는 어디입니까?"
      }'
    코드 블럭. Responses API Request Example

    Response

    200 OK

    NameTypeDescription
    idstring응답의 고유 식별자
    objectstring응답 객체 타입(항상 “response”)
    created_atinteger생성 시각(Unix timestamp, 초 단위)
    completed_atinteger or null완료 시각(completed 상태일 때만 존재)
    statusstring응답 상태(completed/failed/in_progress/cancelled/queued/incomplete)
    modelstring사용된 모델 이름
    outputarray모델이 생성한 출력 항목 배열
    output[].typestring출력 항목 타입(예시: “message”)
    output[].idstring출력 항목 ID
    output[].statusstring항목 상태(예시: “completed”)
    output[].rolestring메시지 작성자 역할(예시: “assistant”)
    output[].contentarray콘텐츠 배열
    output[].content[].typestring콘텐츠 타입(예시: “output_text”)
    output[].content[].textstring생성된 텍스트
    output[].content[].annotationsarray어노테이션 배열
    errorobject or null오류 정보
    incomplete_detailsobject or null미완료 사유(reason: max_output_tokens / content_filter)
    instructionsstring or null시스템/개발자 메시지
    max_output_tokensinteger or null최대 출력 토큰 수
    parallel_tool_callsboolean병렬 도구 호출 허용 여부
    previous_response_idstring or null이전 응답 ID
    reasoningobject or nullreasoning 구성(effort, summary)
    storeboolean응답 저장 여부
    temperaturenumber샘플링 온도
    textobject텍스트 응답 구성(format 등)
    tool_choicestring / object도구 선택 방식
    toolsarray도구 목록
    top_pnumberTop P 값
    truncationstring잘라내기 전략
    usageobject토큰 사용량 통계
    usage.input_tokensinteger입력 토큰 수
    usage.input_tokens_details.cached_tokensinteger캐시된 토큰 수
    usage.output_tokensinteger출력 토큰 수
    usage.output_tokens_details.reasoning_tokensintegerreasoning 토큰 수
    usage.total_tokensinteger전체 토큰 수
    metadataobject메타데이터
    표. Responses API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    400Bad Request
    422Prompt Guard 등 정책에 의해 요청이 거절된 경우
    500Internal Server Error
    표. Responses API - Error Code

    Example

    배경색 변경
    {
      "id": "resp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
      "object": "response",
      "created_at": 1741476542,
      "status": "completed",
      "completed_at": 1741476543,
      "error": null,
      "incomplete_details": null,
      "instructions": null,
      "max_output_tokens": null,
      "model": "openai/gpt-oss-120b",
      "output": [
        {
          "type": "message",
          "id": "msg_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
          "status": "completed",
          "role": "assistant",
          "content": [
            {
              "type": "output_text",
              "text": "한국의 수도는 서울입니다.",
              "annotations": []
            }
          ]
        }
      ],
      "parallel_tool_calls": true,
      "previous_response_id": null,
      "reasoning": {
        "effort": null,
        "summary": null
      },
      "store": true,
      "temperature": 1.0,
      "text": {
        "format": {
          "type": "text"
        }
      },
      "tool_choice": "auto",
      "tools": [],
      "top_p": 1.0,
      "truncation": "disabled",
      "usage": {
        "input_tokens": 54,
        "input_tokens_details": {
          "cached_tokens": 0
        },
        "output_tokens": 8,
        "output_tokens_details": {
          "reasoning_tokens": 0
        },
        "total_tokens": 62
      },
      "metadata": {}
    }
    {
      "id": "resp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
      "object": "response",
      "created_at": 1741476542,
      "status": "completed",
      "completed_at": 1741476543,
      "error": null,
      "incomplete_details": null,
      "instructions": null,
      "max_output_tokens": null,
      "model": "openai/gpt-oss-120b",
      "output": [
        {
          "type": "message",
          "id": "msg_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
          "status": "completed",
          "role": "assistant",
          "content": [
            {
              "type": "output_text",
              "text": "한국의 수도는 서울입니다.",
              "annotations": []
            }
          ]
        }
      ],
      "parallel_tool_calls": true,
      "previous_response_id": null,
      "reasoning": {
        "effort": null,
        "summary": null
      },
      "store": true,
      "temperature": 1.0,
      "text": {
        "format": {
          "type": "text"
        }
      },
      "tool_choice": "auto",
      "tools": [],
      "top_p": 1.0,
      "truncation": "disabled",
      "usage": {
        "input_tokens": 54,
        "input_tokens_details": {
          "cached_tokens": 0
        },
        "output_tokens": 8,
        "output_tokens_details": {
          "reasoning_tokens": 0
        },
        "total_tokens": 62
      },
      "metadata": {}
    }
    코드 블럭. Responses API Response Example

    Prompt Guard 응답

    prompt_safety_model 파라미터를 설정한 경우, guard 모델이 prompt를 먼저 검사합니다.

    • safe: model 파라미터에 지정된 모델로 요청이 그대로 처리됩니다.
    • unsafe: 아래와 같은 형태의 guard 결과를 반환하며 요청이 중단됩니다.
    배경색 변경
    {
      "guard_result": "unsafe",
      "categories": ["S1", "S2"],
      "categories_description": ["Violent Crimes", "Non-Violent Crimes"],
      "messages": [
        "Cannot fulfill the request due to violent content.",
        "Cannot respond as it may promote illegal activities."
      ]
    }
    {
      "guard_result": "unsafe",
      "categories": ["S1", "S2"],
      "categories_description": ["Violent Crimes", "Non-Violent Crimes"],
      "messages": [
        "Cannot fulfill the request due to violent content.",
        "Cannot respond as it may promote illegal activities."
      ]
    }
    코드 블럭. Responses API Prompt Guard 응답 Example (unsafe)

    Reasoning 설정

    chat_template_kwargs 또는 reasoning 파라미터를 통해 모델별 reasoning(추론 모드) 설정을 제어할 수 있습니다.

    • gpt-oss-120b: reasoning 파라미터의 effort 필드로 추론 깊이를 지정합니다. (low/medium/high, 기본값 medium)
    • 기타 모델: chat_template_kwargs 파라미터를 사용하며, 설정 방법은 Chat Completions API - Reasoning 설정을 참고하세요.
    모델파라미터기본 reasoning설정 방법
    openai/gpt-oss-120breasoningmedium{ “effort”: “low” } / { “effort”: “medium” } (기본) / { “effort”: “high” }
    기타 모델chat_template_kwargs모델마다 상이Chat Completions API - Reasoning 설정 참고
    표. Responses API - 모델별 Reasoning 설정
    배경색 변경
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/responses \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "input": "복잡한 수학 문제를 풀어주세요.",
        "reasoning": {
          "effort": "high"
        }
      }'
    curl -X 'POST' \
       {Simple AI Inference 엔드포인트}/v1/responses \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "input": "복잡한 수학 문제를 풀어주세요.",
        "reasoning": {
          "effort": "high"
        }
      }'
    코드 블럭. Responses API Reasoning 설정 Example

    참고

    Tokenize API

    POST /tokenize
    

    개요

    Tokenize API는 텍스트를 토큰 ID로 변환합니다. Completion 방식(prompt 기반)과 Chat 방식(messages 기반) 두 가지 요청 타입을 지원합니다. vLLM의 Tokenize API와 호환됩니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드POST
    Headersobject요청 시 필요한 헤더 정보{ “Content-Type”: “application/json”, “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parametersobject요청 본문에 포함되는 파라미터{ “model”: “openai/gpt-oss-120b”, “prompt”: “Hello, world!” }
    표. Tokenize API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Tokenize API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Tokenize API - Query Parameters

    Body Parameters - 공통

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    model-string토큰화에 사용할 모델을 지정“openai/gpt-oss-120b”
    표. Tokenize API - Body Parameters (공통)

    Body Parameters - Completion 방식 (prompt 기반)

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    prompt-string토큰화할 텍스트“Hello, world!"
    add_special_tokens-booleantrue이면 특수 토큰(BOS 등)을 프롬프트에 추가truetrue / falsetrue
    return_token_strs-booleantrue이면 토큰 ID에 해당하는 토큰 문자열도 함께 반환falsetrue / falsetrue
    표. Tokenize API - Body Parameters (Completion 방식)

    Body Parameters - Chat 방식 (messages 기반)

    NameName SubtypeRequiredDescriptionDefault valueBoundary valueExample
    messagesrolestring대화 내역을 포함하는 메시지 리스트[{ “role”: “user”, “content”: “hi” }]
    add_generation_prompt-booleantrue이면 chat template에 생성 프롬프트를 추가. continue_final_message와 동시에 true로 설정 불가truetrue / falsetrue
    continue_final_message-booleantrue이면 마지막 메시지가 EOS 없이 열린 형태로 포맷됨. 모델이 새 메시지를 시작하는 대신 해당 메시지를 이어감. add_generation_prompt와 동시에 true로 설정 불가falsetrue / falsefalse
    add_special_tokens-booleantrue이면 chat template가 추가하는 특수 토큰 외에 BOS 등의 특수 토큰을 추가로 삽입. 대부분의 모델은 chat template가 특수 토큰을 처리하므로 기본값 false 사용 권장falsetrue / falsefalse
    return_token_strs-booleantrue이면 토큰 ID에 해당하는 토큰 문자열도 함께 반환falsetrue / falsetrue
    chat_template-string변환에 사용할 Jinja 템플릿. 토크나이저에 정의되지 않은 경우 제공 필요null
    chat_template_kwargs-object템플릿 렌더러에 전달할 추가 키워드 인자null{ “add_generation_prompt”: true }
    tools-array모델이 호출할 수 있는 Tool의 리스트null
    표. Tokenize API - Body Parameters (Chat 방식)

    Example

    배경색 변경
    curl -X 'POST' \
      {Simple AI Inference 엔드포인트}/tokenize \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "prompt": "Hello, world!"
      }'
    curl -X 'POST' \
      {Simple AI Inference 엔드포인트}/tokenize \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "prompt": "Hello, world!"
      }'
    curl -X 'POST' \
      {Simple AI Inference 엔드포인트}/tokenize \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "messages": [
          {
            "role": "user",
            "content": "hi"
          }
        ]
      }'
    curl -X 'POST' \
      {Simple AI Inference 엔드포인트}/tokenize \
      -H 'Authorization: bearer sai-xxxxxxx...' \
      -H 'Content-Type: application/json' \
      -d '{
        "model": "openai/gpt-oss-120b",
        "messages": [
          {
            "role": "user",
            "content": "hi"
          }
        ]
      }'
    코드 블럭. Tokenize API Request Example

    Response

    200 OK

    NameTypeDescription
    countinteger토큰화된 토큰의 개수
    max_model_leninteger모델이 지원하는 최대 토큰 길이
    tokensarray토큰화된 토큰 ID 목록
    token_strsarray or null토큰 ID에 해당하는 토큰 문자열 목록(return_token_strs가 true인 경우에만 반환)
    표. Tokenize API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    400Bad Request (model 필드 누락, request body 누락 등)
    404Model Not Found (지원하지 않는 모델)
    500Internal Server Error
    표. Tokenize API - Error Code

    Example

    배경색 변경
    {
      "max_model_len": 1024,
      "count": 6,
      "tokens": [638357778, 638357778, 399020470, 1618501362, 2382766391, 2765235376],
      "token_strs": null
    }
    {
      "max_model_len": 1024,
      "count": 6,
      "tokens": [638357778, 638357778, 399020470, 1618501362, 2382766391, 2765235376],
      "token_strs": null
    }
    {
      "max_model_len": 1024,
      "count": 6,
      "tokens": [638357778, 638357778, 399020470, 1618501362, 2382766391, 2765235376],
      "token_strs": ["<|im_start|>", "user", "<|im_sep|>", "hi", "<|im_end|>", ""]
    }
    {
      "max_model_len": 1024,
      "count": 6,
      "tokens": [638357778, 638357778, 399020470, 1618501362, 2382766391, 2765235376],
      "token_strs": ["<|im_start|>", "user", "<|im_sep|>", "hi", "<|im_end|>", ""]
    }
    코드 블럭. Tokenize API Response Example

    참고

    Models API

    GET /v1/models
    

    개요

    Models API는 Simple AI Inference 모델의 목록을 반환합니다. OpenAI의 Models API와 호환됩니다.

    Request

    Context

    KeyTypeDescriptionExample
    Base URLstringAPI 요청을 위한 Simple AI Inference URLSimple AI Inference 엔드포인트
    Request MethodstringAPI 요청에 사용되는 HTTP 메서드GET
    Headersobject요청 시 필요한 헤더 정보{ “Authorization”: “bearer sai-xxxxxxx…” }
    Body Parameters--GET 요청이므로 Body가 없습니다.
    표. Models API - Context

    Path Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Models API - Path Parameters

    Query Parameters

    NametypeRequiredDescriptionDefault valueBoundary valueExample
    None
    표. Models API - Query Parameters

    Body Parameters

    GET 요청이므로 Body가 없습니다.

    Example

    배경색 변경
    curl -X 'GET' \
      {Simple AI Inference 엔드포인트}/v1/models \
      -H 'Authorization: bearer sai-xxxxxxx...'
    curl -X 'GET' \
      {Simple AI Inference 엔드포인트}/v1/models \
      -H 'Authorization: bearer sai-xxxxxxx...'
    코드 블럭. Models API Request Example

    Response

    200 OK

    NameTypeDescription
    objectstring응답 객체의 타입(“list”)
    dataarray모델 객체 목록
    data[].idstring모델의 식별자
    data[].objectstring객체의 타입(“model”)
    data[].createdinteger모델이 생성된 시각(Unix timestamp, 초 단위)
    data[].owned_bystring모델의 소유자
    표. Models API - 200 OK

    Error Code

    HTTP status codeErrorCode 설명
    401Unauthorized (apikey 누락 또는 유효하지 않음)
    500Internal Server Error
    표. Models API - Error Code

    Example

    배경색 변경
    {
      "data": [
        {
          "id": "openai/gpt-oss-120b",
          "created": 1780979126,
          "object": "model",
          "owned_by": "SCP Simple AI Inference"
        },
        {
          "id": "Qwen/Qwen3-VL-Embedding-8B",
          "created": 1781512915,
          "object": "model",
          "owned_by": "SCP Simple AI Inference"
        },
        {
          "id": "Qwen/Qwen3-VL-Reranker-8B",
          "created": 1781512915,
          "object": "model",
          "owned_by": "SCP Simple AI Inference"
        }
      ],
      "object": "list"
    }
    {
      "data": [
        {
          "id": "openai/gpt-oss-120b",
          "created": 1780979126,
          "object": "model",
          "owned_by": "SCP Simple AI Inference"
        },
        {
          "id": "Qwen/Qwen3-VL-Embedding-8B",
          "created": 1781512915,
          "object": "model",
          "owned_by": "SCP Simple AI Inference"
        },
        {
          "id": "Qwen/Qwen3-VL-Reranker-8B",
          "created": 1781512915,
          "object": "model",
          "owned_by": "SCP Simple AI Inference"
        }
      ],
      "object": "list"
    }
    코드 블럭. Models API Response Example

    참고