+ Pezzo API Key
-
+
Below you can find your Pezzo API key. This API key is provided to
the Pezzo client when executing prompts.
@@ -48,9 +49,9 @@ export const APIKeysPage = () => {
{providerApiKeysData && (
- Provider API Keys
+ Provider API Keys
-
+
In order to be able to test your prompts within the Pezzo Console,
you must provide an API key for each provider you wish to test. This
is optional.
diff --git a/apps/console/src/app/pages/environments/index.tsx b/apps/console/src/app/pages/environments/index.tsx
index 22be091d..12d68db7 100644
--- a/apps/console/src/app/pages/environments/index.tsx
+++ b/apps/console/src/app/pages/environments/index.tsx
@@ -1,20 +1,15 @@
import { PlusOutlined } from "@ant-design/icons";
-import { useQuery } from "@tanstack/react-query";
-import { Button, List, Typography } from "antd";
+import { Button, List, Spin, Typography, theme } from "antd";
import { InlineCodeSnippet } from "../../components/common/InlineCodeSnippet";
import { CreateEnvironmentModal } from "../../components/environments/CreateEnvironmentModal";
-import { GET_ALL_ENVIRONMENTS } from "../../graphql/queries/environments";
-import { gqlClient } from "../../lib/graphql";
import { useState } from "react";
+import { useEnvironments } from "../../lib/hooks/useEnvironments";
export const EnvironmentsPage = () => {
+ const { environments, isLoading } = useEnvironments();
const [isCreateEnvironmentModalOpen, setIsCreateEnvironmentModalOpen] =
useState(false);
-
- const { data } = useQuery({
- queryKey: ["environments"],
- queryFn: () => gqlClient.request(GET_ALL_ENVIRONMENTS),
- });
+ const { token } = theme.useToken();
return (
<>
@@ -23,30 +18,32 @@ export const EnvironmentsPage = () => {
onClose={() => setIsCreateEnvironmentModalOpen(false)}
onCreated={() => setIsCreateEnvironmentModalOpen(false)}
/>
- Environments
-