Background image
Featured blog post image

Mintlify Integration, Plan Validators, and Python Async Beta

New features to the Speakeasy Platform - July 24, 2024

Generation targets grow up so fast. You announce their alpha release, and before you know it, they’re off to beta… And it’s not only the Python Generator that’s maturing.

The Mintlify integration is now self-serve, and Terraform Generation just got even more fully featured with the addition of OpenAPI-based Plan Validators.

Read on for the details!

Mintlify Integration - Now Self-Serve

Making your API documentation SDK-based is easier than ever with our Mintlify integration now available for self-serve.

  1. Select the SDKs you want to include in your docs.
  2. Point Speakeasy workflow at your Mintlify repo.

That’s it! Now every new generation of your SDKs will automatically update your Mintlify repo.


Terraform Plan Validators

func (r *userResource) Schema(_ context.Context,
_ resource.SchemaRequest, resp *resource.SchemaResponse) {
resp.Schema = schema.Schema{
Attributes: map[string]schema.Attribute{
"username": stringattribute.String{
Required: true,
Description: "The username of the user.",
Validators: []validator.String{
stringvalidator.LengthBetween(6, 64),
stringvalidator.RegexMatches(
regexp.MustCompile(`^[a-z]+$`),
"must contain only lowercase alphanumeric characters",
),
},
},
},
}
}

With the latest Speakeasy release, Terraform Provider generation will now automatically convert additional OAS validation properties into Terraform configuration validators. This will ensure that Terraform users will receive upfront feedback about invalid configurations before they are applied.

Automatic OAS -> Terraform validation now includes:

  • For string types: ​maxLength​, ​minLength​, and ​pattern
  • For integer types: ​maximum​ and ​minimum
  • For array types: ​maxItems​, ​minItems​, and ​uniqueItems

Refer to the docs for more on validation capabilities.

Python Beta Release: Pydantic & Async

Last changelog we announced the alpha release of our new Python Generator with support for Async & Pydantic models. We’re now excited to announce the new generator is in beta!

All new SDKs will use the new generator by default. Existing production SDKs will be migrated by request.

For all the details on the new generator, read about our Python SDK design

🐝 New Features and Bug Fixes 🐛

Info Icon

NOTE

Based on the most recent CLI version: Speakeasy v1.345.0 (opens in a new tab)

The Platform

🐝 Feat: SSE Sentinel - enables API builders to specify a sentinel which indicates that a streaming response has no more content to send.
🐝 Feat: deepObject style Params now supported
🐛 Fix: Optional fields for error models are correctly marked.

TypeScript

🐛 Fix: Handle renamed object fields using x-speakeasy-name-override

Python

🐝 Feat: Make Python unset falsy
🐝 Feat: Support defaults and usage snippets for flattened request bodies
🐛 Fix: Fix handling of single member unions
🐛 Fix: Allow model_ prefixes on model fields
🐛 Fix: Handle renamed object fields using x-speakeasy-name-override
🐛 Fix: Added support for string unions

Terraform

🐝 Feat: Plan modifiers created automatically from OpenAPI attributes
🐝 Feat: Move custom plan modifiers to the same folder as the normal plan modifiers

C#

🐝 Feat: Improve NuGet metadata

Go

🐝 Feat: Add support for populating globals from env variables