@orchestrator-ui/orchestrator-ui-components
Version:
Library of UI Components used to display the workflow orchestrator frontend
24 lines (20 loc) • 653 B
text/typescript
import { BaseQueryTypes, orchestratorApi } from '@/rtk';
import { GraphQLPageInfo } from '@/types';
export type AgentExportResponse = {
page: object[];
pageInfo?: GraphQLPageInfo;
};
const agentExportApi = orchestratorApi.injectEndpoints({
endpoints: (builder) => ({
getAgentExport: builder.query<AgentExportResponse, string>({
query: (downloadUrl) => ({
url: downloadUrl,
method: 'GET',
}),
extraOptions: {
baseQueryType: BaseQueryTypes.fetch,
},
}),
}),
});
export const { useLazyGetAgentExportQuery } = agentExportApi;