메인 콘텐츠로 건너뛰기
GET
/
subscriptions
/
current
curl -X GET https://api.llmgenerator.com/api/v1/subscriptions/current \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
{
  "hasSubscription": true,
  "subscription": {
    "plan": "professional",
    "status": "active",
    "billingCycle": "monthly",
    "currentPeriodStart": "2024-01-15T00:00:00Z",
    "currentPeriodEnd": "2024-02-15T00:00:00Z",
    "cancelAtPeriodEnd": false
  },
  "planDetails": {
    "id": "professional",
    "name": "Professional",
    "monthlyCredits": 3000,
    "price": 12.99,
    "features": [
      "3,000 credits/month",
      "Priority support",
      "Advanced analytics"
    ]
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.llmgenerator.com/llms.txt

Use this file to discover all available pages before exploring further.

개요

플랜, 과금 주기, 갱신일 등 현재 구독 정보를 반환합니다. 세션 기반 인증(JWT 액세스 토큰)이 필요합니다.
서드파티 연동: API 키 인증을 사용할 때는 대신 GET /subscriptions/current/api를 사용하세요.

인증

Authorization
string
필수
JWT 액세스 토큰입니다. 형식: Bearer YOUR_ACCESS_TOKEN
curl -X GET https://api.llmgenerator.com/api/v1/subscriptions/current \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
{
  "hasSubscription": true,
  "subscription": {
    "plan": "professional",
    "status": "active",
    "billingCycle": "monthly",
    "currentPeriodStart": "2024-01-15T00:00:00Z",
    "currentPeriodEnd": "2024-02-15T00:00:00Z",
    "cancelAtPeriodEnd": false
  },
  "planDetails": {
    "id": "professional",
    "name": "Professional",
    "monthlyCredits": 3000,
    "price": 12.99,
    "features": [
      "3,000 credits/month",
      "Priority support",
      "Advanced analytics"
    ]
  }
}

응답 필드

hasSubscription
boolean
활성 구독 존재 여부입니다.
subscription
object
구독 세부 정보입니다(구독이 없으면 null).
planDetails
object
전체 플랜 정보입니다(구독이 없으면 null).

구독 상태

상태설명
active구독이 정상적으로 유효합니다
trialing체험 기간입니다
past_due결제 실패, 곧 일시중지될 수 있습니다
canceled구독이 완전히 종료되었습니다

오류 응답

401
error
인증 실패 — 토큰이 없거나 유효하지 않습니다.

GET /subscriptions/current/api

API 키 인증으로 사용자의 현재 구독 정보를 반환합니다. 서드파티 연동에 적합합니다.

인증

API 키 인증이 필요합니다. Authorization 헤더에 API 키를 넣습니다:
Authorization: Bearer llmgen_your_api_key_here

응답

/subscriptions/current와 동일합니다.
curl -X GET https://api.llmgenerator.com/api/v1/subscriptions/current/api \
  -H "Authorization: Bearer llmgen_your_api_key_here"