MCPcopy
hub / github.com/IgnisDa/ryot / getCollectionContents

Function getCollectionContents

tests/src/utils.ts:171–191  ·  view source on GitHub ↗
(
	baseUrl: string,
	userApiKey: string,
	collectionId: string,
)

Source from the content-addressed store, hash-verified

169}
170
171export async function getCollectionContents(
172 baseUrl: string,
173 userApiKey: string,
174 collectionId: string,
175) {
176 const client = getGraphqlClient(baseUrl);
177 const { collectionContents } = await client.request(
178 CollectionContentsDocument,
179 {
180 input: {
181 collectionId,
182 sort: {
183 order: GraphqlSortOrder.Desc,
184 by: CollectionContentsSortBy.LastUpdatedOn,
185 },
186 },
187 },
188 { Authorization: `Bearer ${userApiKey}` },
189 );
190 return collectionContents.response.results.items;
191}
192
193export async function progressUpdate(
194 baseUrl: string,

Callers 1

cache.test.tsFile · 0.90

Calls 1

getGraphqlClientFunction · 0.85

Tested by

no test coverage detected