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

Function addEntitiesToCollection

tests/src/utils.ts:207–222  ·  view source on GitHub ↗
(
	baseUrl: string,
	userApiKey: string,
	userId: string,
	collectionName: string,
	entities: { entityId: string; entityLot: EntityLot }[],
)

Source from the content-addressed store, hash-verified

205}
206
207export async function addEntitiesToCollection(
208 baseUrl: string,
209 userApiKey: string,
210 userId: string,
211 collectionName: string,
212 entities: { entityId: string; entityLot: EntityLot }[],
213) {
214 const client = getGraphqlClient(baseUrl);
215 const response = await client.request(
216 DeployAddEntitiesToCollectionJobDocument,
217 { input: { entities, collectionName, creatorUserId: userId } },
218 { Authorization: `Bearer ${userApiKey}` },
219 );
220 await waitFor(1000);
221 return response;
222}
223
224export async function createCollection(
225 baseUrl: string,

Callers 2

cache.test.tsFile · 0.90

Calls 2

getGraphqlClientFunction · 0.85
waitForFunction · 0.85

Tested by

no test coverage detected