Retrieve prompt version
Retrieve prompt version. When project_name is supplied the lookup is scoped to that project: a prompt belonging to a different project is never matched, and an unknown project name returns 404. Legacy prompts with no project are still resolved as a deprecated fallback, signalled by the X-Opik-Deprecation response header.
Request
If provided, resolves to the version mapped to this environment for the prompt; mutually exclusive with commit and version_number
If provided, resolves to the version with this sequential number (e.g. v3); mutually exclusive with commit and environment
If provided, scopes the search to the specified project; prompts belonging to other projects are never matched, and an unknown project name returns 404. Legacy prompts that are not scoped to any project are still matched as a deprecated fallback, signalled by the X-Opik-Deprecation response header.
Response headers
Present only when the prompt was resolved through the deprecated workspace-wide fallback, i.e. it has no project. Absent for project-scoped prompts.
Response
sequential version number in the format v<N>; null for masks
version type discriminator; defaults to prompt_version
Deprecated: use ‘environments’ instead