MCPcopy Create free account
hub / github.com/TaskingAI/TaskingAI / fetchActionsList

Function fetchActionsList

frontend/src/components/playground/index.tsx:444–464  ·  view source on GitHub ↗
(params: Record<string, any>)

Source from the content-addressed store, hash-verified

442 setModelLimit(value.limit)
443 }
444 const fetchActionsList = async (params: Record<string, any>) => {
445 try {
446 const res: any = await getActionsList(params)
447 const data = res.data.map((item: any) => {
448 return {
449 ...item,
450 key: item.action_id,
451 method: getFirstMethodAndEndpoint(item.openapi_schema)?.method,
452 endpoint: getFirstMethodAndEndpoint(item.openapi_schema)?.endpoint
453 }
454 })
455
456 setActionList(data)
457 setHasActionMore(res.has_more)
458 } catch (error) {
459 console.log(error)
460 const apiResponse = error as ApiErrorResponse
461 const message = apiResponse.response.data.error.message
462 toast.error(message)
463 }
464 }
465 const fetchModelsList = async (params: Record<string, any>) => {
466
467 try {

Callers 2

initialFunctionFunction · 0.70
handleActionRequestFunction · 0.70

Calls 2

getActionsListFunction · 0.90

Tested by

no test coverage detected