Merge pull request #5435 from ougfh/add-filtering-to-apis-explorer

Filter returned fields in apis explorer
This commit is contained in:
Patrik Oldsberg
2021-04-28 01:19:05 +02:00
committed by GitHub
2 changed files with 18 additions and 1 deletions
@@ -34,7 +34,19 @@ export const ApiExplorerPage = () => {
const createComponentLink = useRouteRef(createComponentRouteRef);
const catalogApi = useApi(catalogApiRef);
const { loading, error, value: catalogResponse } = useAsync(() => {
return catalogApi.getEntities({ filter: { kind: 'API' } });
return catalogApi.getEntities({
filter: { kind: 'API' },
fields: [
'apiVersion',
'kind',
'metadata',
'relations',
'spec.lifecycle',
'spec.owner',
'spec.type',
'spec.system',
],
});
}, [catalogApi]);
return (