The Crowdin API adds a TM Segment Batch Operations method:
PATCH /tms/{tmId}/segments (api.tms.segments.patchBatch)
The request body is an array of JSON Patch operations:
add with path /- and a segment create form as value — create a TM segment
add with path /{segmentId}/records/- and value { languageId, text } — append a record to a segment
remove with path /{segmentId} — delete a segment
remove with path /{segmentId}/records/{recordId} — delete a segment record
replace with path /{segmentId}/records/{recordId}/text and a string value — update record text
The 200 response returns the collection of updated TM segments.
Note: the single-segment Edit TM Segment method (api.tms.segments.patch) request body is now formally defined as a discriminated union of add/replace/remove operations with op and path required — the wire format is unchanged, but generated types may need regeneration.
Client libraries should add the batch method. Available in both Crowdin and Crowdin Enterprise.
References:
The Crowdin API adds a TM Segment Batch Operations method:
PATCH /tms/{tmId}/segments(api.tms.segments.patchBatch)The request body is an array of JSON Patch operations:
addwith path/-and a segment create form asvalue— create a TM segmentaddwith path/{segmentId}/records/-andvalue{ languageId, text }— append a record to a segmentremovewith path/{segmentId}— delete a segmentremovewith path/{segmentId}/records/{recordId}— delete a segment recordreplacewith path/{segmentId}/records/{recordId}/textand a stringvalue— update record textThe
200response returns the collection of updated TM segments.Note: the single-segment Edit TM Segment method (
api.tms.segments.patch) request body is now formally defined as a discriminated union of add/replace/remove operations withopandpathrequired — the wire format is unchanged, but generated types may need regeneration.Client libraries should add the batch method. Available in both Crowdin and Crowdin Enterprise.
References: