Skip to content

Releases: DrHazemAli/AzureSoraSDK

v1.0.2

10 Jun 16:53

Choose a tag to compare

πŸš€ Azure OpenAI Sora SDK v1.0.2

πŸ”§ Critical Fixes

Azure API Compliance

  • Fixed Invalid Parameters: Resolved "Invalid parameter" errors by aligning with official Azure OpenAI Sora API
    • Changed durationInSeconds β†’ n_seconds parameter name
    • Removed unsupported parameters: aspectRatio, frameRate, seed, quality, style
    • Updated API version defaults: "preview" for video generation, "2024-02-15-preview" for prompt enhancement

Response Format Corrections

  • Job Creation: Fixed response field from jobId β†’ id
  • Job Status: Updated to support generations array with proper generation IDs
  • Timestamps: Corrected to Unix timestamps with underscores (created_at, finished_at, expires_at)
  • Error Handling: Updated to use failure_reason field instead of error object structure

Job Status Support

  • Added support for all Azure job status values: queued, preprocessing, processing, running, succeeded, failed, cancelled
  • Fixed video URL construction: {endpoint}/openai/v1/video/generations/{generationId}/content/video

✨ New Features

Aspect Ratio Utilities

  • CalculateDimensionsFromAspectRatio(): Calculate width/height from aspect ratio string with 8-pixel rounding
  • GetCommonDimensions(): Get preset dimensions for common aspect ratios (16:9, 4:3, 1:1, 9:16, 3:4, 21:9)
  • Quality Presets: Support for low, medium, high, ultra quality levels
  • New Method Overload: SubmitVideoJobAsync accepting aspect ratio and quality instead of explicit dimensions

πŸ”¨ Technical Improvements

Build & Compatibility

  • C# Language Version: Fixed compatibility with .NET 6 SDK (changed from C# 11.0 to 10.0)
  • Validation Framework: Enhanced with proper ValidationException handling using DataAnnotations
  • JSON Serialization: Corrected to use snake_case format (n_seconds, top_p) for API compliance

Testing & Quality

  • Comprehensive Test Coverage: Updated all tests to match Azure API response formats
  • Mock Response Alignment: Tests now use actual Azure API structure
  • Parameter Validation: Added extensive validation tests for new utilities
  • CI/CD Compatibility: Resolved all build and test failures

πŸ› οΈ Breaking Changes

  • Parameter name change: DurationInSeconds β†’ NSeconds in VideoGenerationRequest
  • Removed unsupported parameters from API requests
  • Changed default API versions for different service endpoints

πŸ“š Documentation Updates

  • Updated all documentation to reflect Azure API compliance
  • Added examples for new aspect ratio utilities
  • Enhanced troubleshooting guide with current Azure job status values
  • Updated API reference with correct parameter names and formats

πŸ”— Azure OpenAI Sora API Compliance

This release ensures 100% compliance with the official Azure OpenAI Sora API specification as documented at:

πŸ“¦ What's Changed

  • Fix: Azure API compliance - resolve invalid parameters, fix response format.
  • Added aspect ratio utilities

Addressed Issues

  • Fixed: Incorrect parameter name for duration of video [#3]
  • Fixed: Invalid default API version and response object [#2]

Full Changelog: v1.0.1...v1.0.2

v1.0.1

10 Jun 14:14

Choose a tag to compare

πŸ› Bug Fixes

  • Fixed incorrect API endpoint URLs for video generation (#1)
    • Changed from /openai/deployments/{deploymentName}/video/jobs to /openai/v1/video/generations/jobs
    • Updated both job submission and status check endpoints to match Azure OpenAI documentation
  • Updated unit tests to validate the correct API endpoint format

✨ New Features

  • Added GitHub Packages registry support
    • Package now available on both NuGet.org and GitHub Packages
    • Added NuGet.config template with environment variable support
    • Updated GitHub Actions workflow to publish to both registries

πŸ“š Documentation

  • Added comprehensive GitHub wiki documentation (9 pages)
    • Installation guide
    • Getting started tutorial
    • Configuration reference
    • API documentation
    • Code examples
    • Error handling guide
    • Troubleshooting guide
    • Contributing guidelines
  • Added CHANGELOG.md for version tracking
  • Enhanced README with links to wiki and changelog

Installation

From NuGet.org:

dotnet add package AzureSoraSDK --version 1.0.1

From GitHub Packages:

dotnet add package AzureSoraSDK --version 1.0.1 --source https://nuget.pkg.github.com/DrHazemAli/index.json

Full Changelog: v1.0.0...v1.0.1
Full Changelog: 1.0.0...1.0.1

v1.0.0

07 Jun 16:17

Choose a tag to compare

Initial Release