Class AzureOpenAiProviderConfig

All Implemented Interfaces:
Describable<AiProviderConfig>, Serializable

public class AzureOpenAiProviderConfig extends AiProviderConfig
Azure OpenAI, using the classic dated-api-version REST surface. See AzureOpenAiProvider for the wire contract and why the generic OpenAI-compatible adapter cannot express it.
See Also:
  • Field Details

    • DEFAULT_API_VERSION

      public static final String DEFAULT_API_VERSION
      Last GA (non-preview) dated api-version for chat completions as of this plugin release.
      See Also:
  • Constructor Details

    • AzureOpenAiProviderConfig

      @DataBoundConstructor public AzureOpenAiProviderConfig(String endpoint, String deploymentName, String credentialsId)
  • Method Details

    • getEndpoint

      public String getEndpoint()
    • getDeploymentName

      public String getDeploymentName()
    • getCredentialsId

      public String getCredentialsId()
    • getApiVersion

      public String getApiVersion()
    • setApiVersion

      @DataBoundSetter public void setApiVersion(String apiVersion)
    • getModel

      public String getModel()
      The deployment name doubles as the model identifier for display, since it determines the model on Azure's side.
      Specified by:
      getModel in class AiProviderConfig
    • createProvider

      public AiProvider createProvider(com.fasterxml.jackson.databind.ObjectMapper objectMapper, int timeoutSeconds)
      Description copied from class: AiProviderConfig
      Builds a provider bound to this configuration's resolved settings, ready to make one (or more) AiProvider.chatCompletion(io.jenkins.plugins.changeinvestigator.ai.AiAnalysisRequest) calls. Resolving the credential happens inside this method, not before it, so the plaintext secret's lifetime is limited to the call that actually needs it.
      Specified by:
      createProvider in class AiProviderConfig
      Parameters:
      objectMapper - shared Jackson mapper for building/parsing request and response JSON
      timeoutSeconds - administrator-configured connect/request timeout (a global, not per-provider, setting - see ChangeInvestigatorGlobalConfiguration)