Skip to content

Conversation

dhofheinz
Copy link

@dhofheinz dhofheinz commented Oct 7, 2025

Description

Adds Azure OpenAI Assistants API example to complement the existing Azure chat completion example.

Changes

  • Created examples/azure/assistants.ts demonstrating how to use the Assistants API with Azure OpenAI
  • Follows the same authentication pattern as examples/azure/chat.ts (Azure AD with AzureOpenAI client)
  • Includes assistant creation, thread management, and polling for completion
  • Uses API version 2024-10-01-preview consistent with other Azure examples

Context

Addresses #701 where users requested Azure Assistants API integration/example. The maintainer (@rattrayalex) explicitly welcomed a PR adding this example.

Testing

  • File follows TypeScript conventions from existing examples
  • Uses same shebang and structure as other example files
  • Executable permissions set to match repository patterns

Fixes #701


Note: I understand that this repository is auto-generated and my pull request may not be merged. However, per CONTRIBUTING.md, the examples/ directory is protected from generator overwrites, ensuring this example file will persist. This example provides immediate value for Azure OpenAI users working with Assistants API.

- Add azure/assistants.ts demonstrating Assistants API usage with Azure OpenAI
- Uses AzureOpenAI client with Azure AD authentication
- Follows pattern from existing azure/chat.ts example
- Addresses issue openai#701
@dhofheinz dhofheinz requested a review from a team as a code owner October 7, 2025 01:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature Request] Assistants API integration/example with Azure OpenAI
1 participant