MCPcopy Create free account
hub / github.com/astercloud/aster / buildHeaders

Function buildHeaders

ui/src/composables/useAsterClient.ts:22–34  ·  view source on GitHub ↗
(additionalHeaders: Record<string, string> = {})

Source from the content-addressed store, hash-verified

20
21 // 构建请求头
22 const buildHeaders = (additionalHeaders: Record<string, string> = {}) => {
23 const headers: Record<string, string> = {
24 "Content-Type": "application/json",
25 ...additionalHeaders,
26 };
27
28 // 如果有 API Key,添加到请求头
29 if (apiKey) {
30 headers["X-API-Key"] = apiKey;
31 }
32
33 return headers;
34 };
35
36 // 创建 Aster Client 并添加 agent 管理方法
37 const client = {

Callers 10

listFunction · 0.85
getFunction · 0.85
createFunction · 0.85
updateFunction · 0.85
deleteFunction · 0.85
chatFunction · 0.85
chatDirectFunction · 0.85
executeFunction · 0.85
joinFunction · 0.85
leaveFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected