The secrets update.
Parameters for atomically updating secrets.
Optionalclient?: {An instance of the Phoenix client. If not provided, the client will be created using the default configuration.
Call a DELETE endpoint
Call a GET endpoint
Get the Phoenix server version, returning a cached value if available.
The version is first populated from the x-phoenix-server-version
response header on any API call. If no version has been seen yet,
this method fetches GET /arize_phoenix_version to populate the cache.
Call a HEAD endpoint
Call a OPTIONS endpoint
Call a PATCH endpoint
Call a POST endpoint
Call a PUT endpoint
Call a TRACE endpoint
Unregister middleware
Register middleware
Ordered secret updates. When a key occurs more than once, the server applies only its last occurrence.
The names of the keys that were upserted and deleted.
import { upsertOrDeleteSecrets } from "@arizeai/phoenix-client/secrets";
const apiKey = process.env.OPENAI_API_KEY;
if (!apiKey) throw new Error("OPENAI_API_KEY is required");
const result = await upsertOrDeleteSecrets({
secrets: [
{ key: "OPENAI_API_KEY", value: apiKey },
{ key: "OLD_PROVIDER_API_KEY", value: null },
],
});
Atomically create, update, or delete a batch of Phoenix secrets.
A non-null value creates or updates a secret, while
nulldeletes it. Duplicate keys use the last occurrence in the batch. The result contains key names only; submitted values are never returned or logged.