Document the style profile endpoints - #424
Closed
lawl-dev wants to merge 3 commits into
Closed
Conversation
Add API reference for the /v3/style_profiles endpoints: list, retrieve, create, partially update, and delete. A style profile bundles glossaries, style rule lists, translation memories, and example documents behind a single style_profile_id, so one ID stands for a whole translation configuration. Adds the ManageStyleProfiles tag, the StyleProfile and StyleProfileId schemas, five endpoint pages, and the matching navigation group. Character limits are stated in prose in the field descriptions rather than encoded in the schema, per the OpenAPI conventions in CLAUDE.md. openapi.json was regenerated with: yq -o=json '.' api-reference/openapi.yaml > api-reference/openapi.json
lawl-dev
force-pushed
the
docs/style-profiles-api
branch
from
September 1, 2026 12:06
a712d10 to
30689ad
Compare
added 2 commits
September 1, 2026 14:20
Add spoken_terms_id to the style profile schema and to the create and update request bodies. A style profile links at most one Spoken Terms collection, applied when the profile is used for speech rather than text, and the tag description explains why the field is singular. Document the error path: a spoken_terms_id sent on a plan without DeepL Voice returns 403, and a value that is not a valid UUID, or that names a collection the account cannot access, returns 400 naming the field. On update an empty string unlinks the collection. Deleting a style profile unlinks the collection rather than deleting it, like the rest of the bundle. openapi.json was regenerated with: yq -o=json '.' api-reference/openapi.yaml > api-reference/openapi.json
…language The one-translation-memory-per-source-language rule was documented but its counterpart for style rule lists was not, so a caller linking two lists for the same target language only learned about the limit from a 400. openapi.json was regenerated with: yq -o=json '.' api-reference/openapi.yaml > api-reference/openapi.json
Contributor
Author
|
Closing in favour of #427, the same three commits on a branch in this repository instead of a fork. The |
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.
Adds API reference documentation for the
/v3/style_profilesendpoints.A style profile bundles your other customizations, glossaries, style rule lists, translation memories, example documents and one Spoken Terms collection, behind a single
style_profile_id, so one ID stands for a whole translation configuration instead of a list of individual parameters.Endpoints documented
GET/v3/style_profilesstyle_profiles:readGET/v3/style_profiles/{style_profile_id}style_profiles:readPOST/v3/style_profilesstyle_profiles:writePATCH/v3/style_profiles/{style_profile_id}style_profiles:writeDELETE/v3/style_profiles/{style_profile_id}style_profiles:writeBehavior called out in the descriptions
400message names the list the bad ID was passed inPATCHleaves absent fields unchanged. An empty string clearsdescriptionandindustry, an emptynameis a400, and each component list that is sent replaces that linked set in fullDELETEreturns204 No Contentand only unlinks the bundled glossaries, style rule lists, translation memories, example documents and Spoken Terms collection. They are not deleted404on delete, the same status as an unknown IDspoken_terms_idis singular, not a list. A profile links at most one Spoken Terms collection, applied when the profile is used for speech rather than text. On update, an empty string unlinks it, the same clearing conventiondescriptionandindustryuse403when aspoken_terms_idis sent on a plan without DeepL Voice, and400naming the field for a value that is not a valid UUID or that names a collection the account cannot access456when the account has reached its style profile limit, and403when the plan does not include creating style profilesChanges
api-reference/openapi.yaml: the two paths, theManageStyleProfilestag, and theStyleProfileandStyleProfileIdschemasapi-reference/openapi.json: regenerated withyq -o=json '.' api-reference/openapi.yaml > api-reference/openapi.jsonapi-reference/style-profiles/: five endpoint pagesdocs.json: a Style Profiles group under Customize, next to the other customization resourcesA question for the reviewer
Field character limits are stated in prose in the field descriptions rather than encoded as
maxLengthormaximumin the schema, following the OpenAPI conventions inCLAUDE.md.Worth a second opinion, though: the neighboring customization endpoints do encode their limits in the schema, so the spec now reads two ways depending on which resource you look at. Would you rather these fields match the neighbors, or keep them as they are and treat this as the pattern to move toward? Happy to change it either way, just say which.
Verification
yqparses the YAML and every new$refresolves. The regenerated JSON is identical to the previous one apart from the additionsmint broken-linkspassesmint broken-links --check-anchorsreports the same six pre-existing anchors asmainand nothing newOpened as a draft because the endpoints are not released yet.