Ellipse Gradient for Header

Azure OpenAI Service Integration Guide

Connect enterprise applications to Azure OpenAI Service through deployment-based REST APIs, secure authentication, synchronous inference, and asynchronous batch workflows.

Azure OpenAI Service integration options at a glance

Azure OpenAI Service primarily integrates through HTTPS REST APIs hosted at an Azure OpenAI resource endpoint. Martini can call chat completion, Responses, embeddings, image generation, audio, file, batch, and supported fine-tuning operations by supplying the API version, deployment name, and API key or Microsoft Entra ID token. Batch workloads are submitted asynchronously and monitored through status polling rather than a general-purpose webhook mechanism. Martini workflows can prepare prompts and files, validate structured responses, apply business rules, persist operation identifiers, and deliver results to applications, databases, Azure AI Search, or file stores. API versions, model capabilities, quotas, and regional availability should remain environment configuration.

Integration pointSupported by Azure OpenAI Service?Common use casesHow Martini supports it
REST APIsYesUse deployment-based endpoints for chat completions, Responses, embeddings, image generation, audio, files, batch processing, and supported fine-tuning operations. Requests generally include an API version and deployment name.Martini can consume the Azure OpenAI REST APIs from workflows, map source data into requests, validate responses, and route results to downstream APIs or databases.
Bulk / async / batch APIsYesSubmit supported workloads such as classification, embedding generation, summarization, or document enrichment as asynchronous batch jobs.Martini can create batch input files, submit jobs, persist batch identifiers, poll status on a schedule, retrieve results, and reconcile them to source identifiers.
File / attachment APIsYesUpload, list, retrieve, or delete files for supported features such as batch processing, assistants, or fine-tuning, subject to API version and feature availability.Martini can prepare files, call file operations, track file identifiers, and use Azure Blob Storage or another repository when large-file handling is more appropriate.
Webhooks / outbound callbacksLimitedNo general-purpose webhook mechanism was identified for all inference events. Asynchronous batch and fine-tuning operations generally use status retrieval or polling.Martini can expose an API for callbacks when a specific Azure feature provides them, but the standard pattern is a scheduled workflow that polls operation status with bounded retries.
AuthenticationYesAuthenticate with an Azure OpenAI API key in the api-key header or with a Microsoft Entra ID OAuth 2.0 bearer token governed by Azure permissions and roles.Martini can store keys and OAuth configuration in secrets or secure environment configuration and apply the selected authentication method to outbound API requests.
Scheduled synchronizationYesUse scheduled processing for batch status, fine-tuning status, file manifests, checkpoints, and other application-maintained incremental workloads.Martini can schedule workflows, persist checkpoints and operation identifiers, poll status, and publish completed results to target systems.
Database accessNot applicableAzure OpenAI Service is an API service rather than a general-purpose database. Databases, Azure AI Search, Azure Monitor, and Log Analytics are separate services.Martini can orchestrate Azure OpenAI with supported SQL databases and other endpoints, but database access is provided by those separate systems.

How Azure OpenAI Service exposes data and business events

Azure OpenAI Service REST APIs

Azure OpenAI Service exposes HTTPS REST APIs for chat completions, Responses, embeddings, image generation, audio, files, batch processing, and supported fine-tuning operations. Requests vary by API version and normally include the Azure resource endpoint, API version, deployment name where applicable, and authentication.

Martini implementation pattern

Martini implementation pattern: a workflow receives an application request or retrieves source data, constructs the deployment-specific REST request, applies API-key or Microsoft Entra ID authentication, validates the response and content-filter outcomes, and writes or returns a normalized result.

Implementation sequence

Receive the source request or retrieve source content
Resolve the endpoint, API version, and deployment configuration
Map source fields into the Azure OpenAI request
Authenticate and submit the REST request
Validate the response and safety-related outcomes
Write or return the normalized result

Azure OpenAI Service Batch API

The Batch API supports asynchronous processing for supported workloads such as classification, embeddings, summarization, and document enrichment. A batch is submitted, monitored through status retrieval, and followed by result download after completion.

Martini implementation pattern

Martini implementation pattern: a workflow creates a correctly formatted input file, submits the batch, persists the returned identifier and source correlation data, and a scheduled workflow polls status until a terminal state before retrieving and reconciling results.

Implementation sequence

Create and validate the batch input file
Submit the batch request
Persist the batch identifier and source checkpoints
Poll the batch status on a controlled schedule
Retrieve completed results
Match results to source identifiers and apply idempotency checks

Azure OpenAI Service file operations

File operations are available for supported features such as batch processing, assistants, or fine-tuning. Availability and fields depend on the API version and selected feature, so uploaded files should not be assumed to be universally usable.

Martini implementation pattern

Martini implementation pattern: a workflow obtains content from a repository, transforms it into the required file format, uploads it, stores the returned file identifier, and removes or archives the file according to the processing policy.

Implementation sequence

Retrieve or generate the source file
Validate size, format, and feature compatibility
Upload the file to Azure OpenAI
Persist the returned file identifier
Use the file in the supported operation
Apply retention and cleanup rules

Azure OpenAI Service asynchronous status polling

Batch and fine-tuning operations are asynchronous and generally expose status retrieval rather than a universal outbound callback. Azure OpenAI inference requests do not provide a general event stream for every operation.

Martini implementation pattern

Martini implementation pattern: Martini stores the operation identifier and source correlation ID, then uses a scheduled workflow or queue-driven process to poll with bounded retries, handle terminal failures, and publish completion results to an application or messaging endpoint.

Implementation sequence

Submit the asynchronous operation
Persist the operation identifier and correlation ID
Wait for the next scheduled polling interval
Retrieve the current operation status
Retry transient failures within a bounded window
Retrieve results or route terminal failures for review

Common Azure OpenAI Service integration patterns

Pattern 1: Summarize enterprise documents

When to use this pattern

Use this pattern when documents from a content repository or storage service must be summarized, classified, or enriched without embedding Azure OpenAI-specific request structures into every source application.

Integration direction
Microsoft SharePoint
Martini
Azure OpenAI Service
Microsoft SharePoint
Example Mapping
Azure OpenAI Service FieldCanonical FieldTarget Field
document.contentsourceTextmessages.content
document.idsourceDocumentIdmetadata.sourceId
document.titledocumentTitlesystem or user context
generated.summarysummarysummary field
Martini implementation pattern

A Martini API or trigger receives a document reference, retrieves content, chunks or transforms it, and calls the selected Azure OpenAI deployment. The workflow validates the generated response, distinguishes content filtering from transport errors, and writes an approved summary or classification with correlation and duplicate checks.

Martini capabilities used
  • workflows
  • API consumption
  • data mapping
  • business rules
  • response validation
  • error handling

Pattern 2: Assist customer-support responses

When to use this pattern

Use this pattern when support agents need generated response suggestions based on ticket content, customer context, and controlled response policies while retaining an approval step before customer communication.

Integration direction
ServiceNow
Martini
Azure OpenAI Service
ServiceNow
Example Mapping
Azure OpenAI Service FieldCanonical FieldTarget Field
incident.descriptioncaseDescriptionmessages.content
incident.numbercaseIdcorrelationId
customer.contextcustomerContextretrievedContext
generated.responsesuggestedResponsework note or draft response
Martini implementation pattern

Martini retrieves the case and permitted context, applies prompt, privacy, and approval rules, and invokes Azure OpenAI. It validates the output and content-filter status, stores a draft or returns it to the agent, and retries only transient failures without duplicating case updates.

Martini capabilities used
  • API-led integration
  • workflows
  • data mapping
  • business rules
  • secure configuration
  • idempotency
  • error handling

Pattern 3: Generate embeddings for semantic indexing

When to use this pattern

Use this pattern when product, knowledge-base, or document content must be converted into vectors and indexed for semantic or hybrid retrieval.

Integration direction
Microsoft SharePoint
Martini
Azure OpenAI Service
Azure AI Search
Example Mapping
Azure OpenAI Service FieldCanonical FieldTarget Field
document.textchunkTextembedding.input
document.idsourceIdsearch.documentKey
document.urlsourceUrlsearch.metadata.sourceUrl
embedding.vectorcontentVectorAzure AI Search vector field
Martini implementation pattern

Martini detects or receives source content, chunks it within context constraints, calls the embeddings API, and writes vectors with stable metadata to Azure AI Search or another supported store. Checkpoints and source identifiers make reprocessing safe when a request times out or a deployment changes.

Martini capabilities used
  • scheduled and event-driven workflows
  • API consumption
  • data transformation
  • mapping
  • checkpointing
  • retry handling

Pattern 4: Run asynchronous batch enrichment

When to use this pattern

Use this pattern for large offline workloads where submitting individual synchronous requests would be inefficient or difficult to control, such as bulk classification, summarization, or embedding generation.

Integration direction
Database
Martini
Azure OpenAI Service
Database
Example Mapping
Azure OpenAI Service FieldCanonical FieldTarget Field
source.idsourceIdbatch.custom_id
source.textinputTextbatch.request body
batch.idoperationIdprocessing.batchId
batch.resultenrichmentResulttarget.enrichment
Martini implementation pattern

Martini extracts a partitioned source set, creates and validates the batch file, submits it, and persists the batch identifier. A scheduled workflow polls status, retrieves results, reconciles them by stable source identifiers, applies idempotency checks, and updates the originating database or application.

Martini capabilities used
  • workflows
  • scheduled execution
  • file processing
  • API consumption
  • state management
  • business rules
  • error handling

Applications commonly integrated with Azure OpenAI Service

Azure OpenAI Service can be orchestrated with Microsoft applications, enterprise platforms, content repositories, and data services. These patterns use each product’s supported APIs and permissions; they do not imply a dedicated Azure OpenAI connector.

Application Scenario Direction Martini Pattern
Azure AI Search Use indexed enterprise content, vector or hybrid retrieval, embeddings, and enrichment to ground generated responses. Azure AI Search → Martini → Azure OpenAI Service Martini retrieves or receives search context, calls the selected Azure OpenAI deployment, validates the response, and can write embeddings or enrichment results back through the relevant API.
Microsoft SharePoint Summarize documents, classify content, extract metadata, and support question-answering over enterprise documents. Microsoft SharePoint → Martini → Azure OpenAI Service A Martini workflow retrieves document content through SharePoint APIs, chunks or transforms it, calls Azure OpenAI, and writes approved summaries or metadata back to SharePoint or another system.
Microsoft Dynamics 365 Summarize cases, draft service or sales responses, classify interactions, and enrich customer records. Microsoft Dynamics 365 → Martini → Azure OpenAI Service Martini receives selected Dynamics 365 data, applies prompt and data-handling rules, calls an Azure OpenAI deployment, validates the output, and updates Dynamics 365 only after required approval checks.
Microsoft Power Platform Add language generation and classification to Power Automate and Power Apps processes through controlled APIs. Microsoft Power Platform → Martini → Azure OpenAI Service Martini exposes a secured API or consumes a Power Platform request, transforms the payload into an Azure OpenAI request, and returns a stable response contract with validation and error handling.
Microsoft Copilot Studio Extend conversational experiences with enterprise data, business rules, and external API orchestration. Microsoft Copilot Studio → Martini → Azure OpenAI Service A Martini API receives the conversational context, retrieves supporting data, applies policy rules, calls Azure OpenAI where appropriate, and returns controlled results to Copilot Studio.
ServiceNow Summarize incidents, classify requests, draft knowledge content, and assist service-desk workflows. ServiceNow → Martini → Azure OpenAI Service Martini consumes ServiceNow API data, builds a constrained request, validates generated content and content-filter outcomes, and writes approved summaries or classifications back to ServiceNow.
Salesforce Enrich Cases, Leads, and Knowledge content with summarization, classification, and response drafting. Salesforce → Martini → Azure OpenAI Service A Martini workflow retrieves Salesforce content, normalizes it into an internal contract, calls Azure OpenAI, validates the generated result, and updates Salesforce with idempotency protection.
Jira Summarize issues, classify work items, draft release notes, and extract structured project information. Jira → Martini → Azure OpenAI Service Martini receives Jira issue data, applies project-specific prompt rules, invokes Azure OpenAI, validates structured output, and writes approved summaries or metadata to Jira.

How to build a Azure OpenAI Service integration in Martini

Objective

Configure the Azure OpenAI endpoint, API version, deployment name, and authentication without embedding credentials in workflow logic.

Instructions in Martini

  • Store API keys, OAuth configuration, endpoints, and deployment settings in Martini secrets or secure environment configuration.
  • Choose API-key authentication or Microsoft Entra ID according to the deployment architecture and Azure permissions.
  • Separate development, test, and production resources or deployments where required.

Objective

Select an event, API request, scheduled process, or queue-driven trigger that matches the workload and whether processing is synchronous or asynchronous.

Instructions in Martini

  • Use a Martini API or trigger for interactive requests.
  • Use a scheduler or queue-driven workflow for batch and fine-tuning status polling.
  • Persist source identifiers and checkpoints before beginning long-running processing.

Objective

Collect the document, ticket, issue, database content, or other source data that will become the Azure OpenAI request.

Instructions in Martini

  • Retrieve content from the source application or repository through its supported API.
  • Chunk, filter, or summarize large content to respect model context and token limits.
  • Avoid sending unnecessary sensitive data.

Objective

Build the end-to-end workflow that prepares the request, calls Azure OpenAI, and controls downstream processing.

Instructions in Martini

  • Construct the deployment-specific REST request with the required API version and parameters.
  • Apply business rules for model selection, prompt constraints, approvals, and content-filter outcomes.
  • Persist operation, batch, or file identifiers when processing is asynchronous.

Objective

Convert vendor-specific request and response structures into stable internal contracts suitable for downstream systems.

Instructions in Martini

  • Map source fields to messages, inputs, metadata, or batch request bodies.
  • Validate generated JSON or other structured output before using it downstream.
  • Normalize response identifiers, usage information where available, and failure categories.

Objective

Deliver approved output to the target application, database, search index, file store, or API consumer without creating duplicates.

Instructions in Martini

  • Apply correlation and idempotency checks before writing results.
  • Write summaries, classifications, embeddings, or approved drafts through the target system’s supported endpoint.
  • Route filtered, malformed, or business-rule-rejected output to a controlled review or failure path.

Common Azure OpenAI Service data objects used in integrations

ObjectTypical UseCommon target systemsMartini handling
Azure OpenAI resourceDefines the service endpoint, authentication boundary, quota allocation, and regional configuration.Azure administration, configuration stores, monitoring platformsMartini treats endpoint, region, API version, and security configuration as protected environment values rather than business records.
Model deploymentMaps a callable deployment name to a model and version with specific regional and quota characteristics.Configuration repositories, application APIs, operational dashboardsMartini resolves deployment names from environment configuration and records the deployment used for correlation and troubleshooting.
Chat completionRepresents a conversational generation request and response containing messages, parameters, and model output.ServiceNow, Salesforce, Dynamics 365, SharePoint, customer-service applicationsMartini maps source context into messages, applies prompt rules, validates the response, and routes approved output to the target system.
ResponseRepresents the newer unified generation API object for supported text and multimodal response scenarios.Enterprise APIs, content systems, workflow applicationsMartini normalizes version- and model-specific response structures into stable internal contracts before downstream processing.
EmbeddingRepresents a vector generated from text for semantic search, retrieval, classification, or similarity matching.Azure AI Search, vector-capable stores, databases, analytics applicationsMartini chunks source text, calls the embeddings operation, attaches source metadata, and writes vectors through the target store’s supported API.
Batch jobTracks an asynchronous collection of submitted requests and the availability of processing results.Source applications, file stores, databases, reporting platformsMartini persists the batch identifier, polls status, retrieves results, reconciles source identifiers, and prevents duplicate updates.

Authentication and security considerations

Authentication options

Azure OpenAI Service supports API keys and Microsoft Entra ID bearer tokens. API keys are sent in the api-key header, while OAuth 2.0 access tokens use the applicable Azure Cognitive Services scope and Azure role permissions.

Secure Martini configuration

  • Store API keys, OAuth client secrets, endpoints, deployment names, and API versions in Martini secrets or protected environment configuration.
  • Use least-privilege Azure permissions and distinguish data-plane inference access from resource and deployment management permissions.
  • Use managed identities where the Martini deployment architecture supports Azure-hosted identity flows; otherwise use an appropriately protected service principal or API key.
  • Limit logging of prompts, completions, tokens, customer data, and access tokens.

Operational considerations for Azure OpenAI Service integrations

Quotas and retries

Azure OpenAI applies quotas and rate limits that can produce HTTP 429 responses. Martini workflows should use bounded exponential backoff with jitter and should not retry authentication, validation, or other non-transient failures.

Versions and schemas

API versions, deployment names, model capabilities, response schemas, structured output behavior, and regional availability vary. Keep these values configurable and validate generated JSON or other structured output before downstream use.

Asynchronous processing

Batch and fine-tuning workflows require persisted identifiers, status polling, maximum processing windows, terminal failure paths, and reconciliation by stable source identifiers rather than response order.

Data and observability

  • Apply idempotency checks before submitting retryable work or writing results.
  • Track correlation IDs, deployment names, API versions, status codes, latency, throttling, content filtering, and downstream failures.
  • Respect token and context limits by filtering, chunking, or summarizing source content.
  • Consider regional processing, retention, encryption, and regulatory requirements before sending data to Azure OpenAI Service.

Why use Martini instead of scripts or point-to-point integrations?

Centralized orchestration

Martini separates enterprise applications from Azure OpenAI-specific endpoints, deployment names, API versions, prompt structures, and response formats. This makes it easier to reuse integration logic across applications.

Reliable processing

Workflows can coordinate synchronous calls, asynchronous batch jobs, scheduled polling, checkpoints, idempotency, retries, validation, and controlled failure paths instead of leaving these concerns in separate scripts.

Consistent governance

Martini provides a place to apply authentication, secrets management, data mapping, business rules, approval checks, and logging policies while limiting sensitive data exposure.

Reusable enterprise APIs

Martini can expose stable APIs that combine Azure OpenAI with document repositories, search services, databases, and business applications without requiring every consumer to understand Azure OpenAI request details.

Frequently asked questions

How can Azure OpenAI Service be integrated with enterprise systems?

Azure OpenAI Service is integrated primarily through HTTPS REST APIs hosted at an Azure OpenAI resource endpoint. Enterprise workflows can call chat completions, Responses, embeddings, image, audio, file, batch, and supported fine-tuning operations using an API version, deployment name where applicable, and API key or Microsoft Entra ID authentication. Asynchronous workloads are monitored through status retrieval or polling.

Can Martini integrate with Azure OpenAI Service?

Yes. Martini can consume Azure OpenAI Service REST APIs from workflows and APIs, authenticate with an API key or Microsoft Entra ID, transform enterprise data into model requests, validate responses, and route results to applications, databases, search indexes, or file stores.

Do I need a connector to integrate Azure OpenAI Service with Martini?

No. A dedicated Azure OpenAI Service connector is not required. Martini can use the vendor’s native REST APIs, authentication methods, file operations, batch endpoints, and status retrieval patterns. No native Martini Azure OpenAI connector is documented in the supplied context.

Is there any extra Lonti cost to integrate Azure OpenAI Service with Martini?

Lonti does not charge an additional per-connector or per-vendor fee to integrate Azure OpenAI Service with Martini. Integrations are subject to the provisioned capacity of the Martini environment. Separate costs may apply from Microsoft Azure, Azure OpenAI usage, infrastructure, or other third-party systems depending on subscription, usage, and deployment model.

Which Azure OpenAI Service integration methods should be used?

REST APIs are the documented primary method. Use synchronous inference endpoints for interactive requests, the Batch API for supported large offline workloads, file operations for feature-specific processing, and Microsoft Entra ID or API keys for authentication. No official GraphQL or SOAP API was identified.

Does Azure OpenAI Service send webhooks or events to Martini?

A general-purpose webhook or event stream for all Azure OpenAI inference operations was not identified. Batch and fine-tuning operations generally expose status retrieval, so Martini can persist the operation identifier and use a scheduled workflow or queue-driven process to poll with bounded retries.

How does synchronization with Azure OpenAI Service work?

Azure OpenAI Service is not a conventional record-based business system and does not provide general change-data capture for inference results. Martini typically uses application checkpoints, source identifiers, batch partitions, file manifests, queues, and persisted operation IDs to coordinate incremental processing and prevent duplicate updates.

Can Martini expose an API façade for Azure OpenAI Service?

Yes. Martini can expose a secured API that presents a stable enterprise contract while hiding Azure OpenAI endpoints, deployment names, API versions, prompt rules, validation, and retry behavior. The façade can also combine Azure OpenAI with retrieval, databases, approval workflows, or other enterprise services.