Skip to content

Add default values to API playground for translate, rephrase, and correct endpoints#373

Merged
shirgoldbird merged 3 commits into
mainfrom
fix/playground-default-values
Jun 16, 2026
Merged

Add default values to API playground for translate, rephrase, and correct endpoints#373
shirgoldbird merged 3 commits into
mainfrom
fix/playground-default-values

Conversation

@shirgoldbird

Copy link
Copy Markdown
Member

Summary

  • Adds x-default values to the text array field on /v2/translate, /v2/write/rephrase, and /v2/write/correct so the Mintlify playground pre-populates with example text instead of requiring users to manually click "Add an item"
  • Adds x-default for target_lang on /v2/translate (set to DE) since it's also required
  • Changes applied to both openapi.yaml and openapi.json

Test plan

  • Verify the translate playground at /api-reference/translate/request-translation?playground=open pre-fills text and target_lang
  • Verify the rephrase playground at /api-reference/improve-text/request-text-improvement?playground=open pre-fills text
  • Verify the correct playground at /api-reference/improve-text/correct-text?playground=open pre-fills text
  • Confirm clicking "Send" with only an API key works without manually adding array items

🤖 Generated with Claude Code

@mintlify

mintlify Bot commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
deepl-c950b784 🟢 Ready View Preview Jun 16, 2026, 3:40 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

Adds x-default to required fields on playground endpoints so users
don't need to manually populate them before sending a request:
- /v2/translate: text, target_lang
- /v2/write/rephrase: text
- /v2/write/correct: text
- /v3/languages: resource
- POST /v3/style_rules: name, language
- POST /v3/style_rules/{style_id}/custom_instructions: label, prompt

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@shirgoldbird shirgoldbird force-pushed the fix/playground-default-values branch from b7deb86 to 06d3d7c Compare June 16, 2026 16:04
@shirgoldbird shirgoldbird merged commit 744d815 into main Jun 16, 2026
3 checks passed
@shirgoldbird shirgoldbird deleted the fix/playground-default-values branch June 16, 2026 16:09
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.

1 participant