spec: align glossary, translation memory, and usage response schemas with the live API#397
Merged
Merged
Conversation
Contributor
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
seekuehe
approved these changes
Jul 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Comparing the spec against live API responses shows a few places where the declared schemas are slightly off from what the API returns. This PR aligns them. The spec still validates as OpenAPI 3.0.3;
openapi.jsonregenerates via the workflow.1. v3 glossary responses include
entry_countper dictionaryPOST /v3/glossaries(201),GET/PATCH /v3/glossaries/{glossary_id}, and the list endpoint all return:GlossaryDictionarydidn't declareentry_count, even though the spec's own response examples already include it. Added asreadOnly(the same schema is used in create/patch request bodies, where it isn't sent). The v2 glossary schema already documents this field.2.
GET /v3/glossaries/{glossary_id}/entriesreturns a wrapper objectThe spec declared the 200 response is a
GlossaryDictionary. The actual response:{ "dictionaries": [ { "source_lang": "en", "target_lang": "de", "entries": "hello\tHallo", "entries_format": "tsv" } ] }Now declared as an object with a
dictionariesarray ofMultilingualGlossaryEntries(this endpoint does not returnentry_count).3. Translation memories include timestamps
Every item in
GET /v3/translation_memoriesreturnscreation_timeandupdated_time(ISO 8601), neither declared:{ "translation_memory_id": "…", "name": "…", "source_language": "en", "target_languages": ["de"], "segment_count": 1, "creation_time": "2026-04-01T16:34:25.223Z", "updated_time": "2026-04-01T16:34:25.264Z" }Added as optional
date-timefields.4.
GET /v2/usagedocument quota fieldsKeys belonging to CAT-tool (non-API) subscriptions return the document quota fields, and only those (no character fields):
{ "team_document_count": 0, "document_count": 0, "team_document_limit": 20, "document_limit": 20 }None of the four were declared; added as optional integers alongside the existing character fields.
5. The v3 read/delete operations can return 400
Eight operations declared 401 and up but not 400. Five are id-based reads/deletes where the API demonstrably returns 400 on a malformed id (
GET /v3/glossaries/{id},GET/DELETE /v3/style_rules/{id},GET/DELETE /v3/style_rules/{id}/custom_instructions/{id}):The other three are the list endpoints (
GET /v3/glossaries,GET /v3/translation_memories,GET /v3/style_rules), where a 400 wasn't reproducible with malformed query parameters; they are declared for consistency with the v2 equivalents (GET /v2/glossaries,GET /v2/glossary-language-pairs,GET /v2/languages), which all declare 400. Happy to drop those three if you'd rather only document reproduced behavior.All use the existing
BadRequest/BadRequestGlossariesresponse components.