MCPcopy Index your code
hub / github.com/seerr-team/seerr / post

Method post

server/api/externalapi.ts:79–102  ·  view source on GitHub ↗
(
    endpoint: string,
    data?: Record<string, unknown>,
    config?: AxiosRequestConfig,
    ttl?: number
  )

Source from the content-addressed store, hash-verified

77 }
78
79 protected async post<T>(
80 endpoint: string,
81 data?: Record<string, unknown>,
82 config?: AxiosRequestConfig,
83 ttl?: number
84 ): Promise<T> {
85 const cacheKey = this.serializeCacheKey(endpoint, {
86 config: config?.params,
87 ...(data ? { data } : {}),
88 });
89
90 const cachedItem = this.cache?.get<T>(cacheKey);
91 if (cachedItem) {
92 return cachedItem;
93 }
94
95 const response = await this.axios.post<T>(endpoint, data, config);
96
97 if (this.cache && ttl !== 0) {
98 this.cache.set(cacheKey, response.data, ttl ?? DEFAULT_TTL);
99 }
100
101 return response.data;
102 }
103
104 protected async getRolling<T>(
105 endpoint: string,

Callers 15

updateRequestFunction · 0.80
modifyRequestFunction · 0.80
modifyRequestsFunction · 0.80
onClickWatchlistBtnFunction · 0.80
onClickHideItemBtnFunction · 0.80
updateIssueStatusFunction · 0.80
IssueDetailsFunction · 0.80
LocalLoginFunction · 0.80
JellyfinLoginFunction · 0.80
AddEmailModalFunction · 0.80
loginFunction · 0.80
importUsersFunction · 0.80

Calls 3

serializeCacheKeyMethod · 0.95
setMethod · 0.80
getMethod · 0.45

Tested by 3

loginAsFunction · 0.64
authenticatedAgentFunction · 0.64
getResetGuidFunction · 0.64