MCPcopy Create free account
hub / github.com/Tron521/codex-console-temp / Sub2ApiService

Class Sub2ApiService

src/database/models.py:287–299  ·  view source on GitHub ↗

Sub2API 服务配置表

Source from the content-addressed store, hash-verified

285
286
287class Sub2ApiService(Base):
288 """Sub2API 服务配置表"""
289 __tablename__ = 'sub2api_services'
290
291 id = Column(Integer, primary_key=True, autoincrement=True)
292 name = Column(String(100), nullable=False) # 服务名称
293 api_url = Column(String(500), nullable=False) # API URL (host)
294 api_key = Column(Text, nullable=False) # x-api-key
295 target_type = Column(String(50), nullable=False, default='sub2api') # sub2api/newapi
296 enabled = Column(Boolean, default=True)
297 priority = Column(Integer, default=0) # 优先级
298 created_at = Column(DateTime, default=utcnow_naive)
299 updated_at = Column(DateTime, default=utcnow_naive, onupdate=utcnow_naive)
300
301
302class Codex2ApiService(Base):

Callers 1

create_sub2api_serviceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected