统一api

This commit is contained in:
2025-11-13 18:03:26 +08:00
parent a61b5fa2fd
commit 5ec950cc61
10 changed files with 30 additions and 2 deletions

21
Shared/KBAPI.h Normal file
View File

@@ -0,0 +1,21 @@
//
// KBAPI.h
// 统一管理所有接口路径的宏,避免在代码中散落硬编码字符串。
// 注意:这里的路径为相对 KB_BASE_URL 的“相对路径”,可带或不带开头的斜杠。
//
#ifndef KBAPI_h
#define KBAPI_h
// 用户与认证
#ifndef KB_API_USER_APPLE_LOGIN
#define API_APPLE_LOGIN @"/user/appleLogin" // Apple 登录
#endif
// 应用配置
#ifndef KB_API_APP_CONFIG
#define KB_API_APP_CONFIG @"app/config" // 获取 App 配置
#endif
#endif /* KBAPI_h */