UNPKG

@arizeai/phoenix-client

Version:

A client for the Phoenix API

14 lines 544 B
import { createClient } from "../client.js"; import { getPromptBySelector } from "../utils/getPromptBySelector.js"; /** * Get a prompt from the Phoenix API. * * @param params - The parameters to get a prompt. * @returns The prompt version, or null if it does not exist. */ export async function getPrompt({ client: _client, prompt: _prompt, }) { const client = _client ?? createClient(); const promptVersion = await getPromptBySelector({ client, prompt: _prompt }); return promptVersion; } //# sourceMappingURL=getPrompt.js.map