curl --request POST \
--url https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"filters": [
{
"clients": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"createdByUsers": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"createdFrom": "2023-11-07T05:31:56Z",
"createdTo": "2023-11-07T05:31:56Z",
"domains": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"filename": "<string>",
"keyName": "<string>",
"lastModifiedFrom": "2023-11-07T05:31:56Z",
"lastModifiedTo": "2023-11-07T05:31:56Z",
"modifiedByUsers": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"projects": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"subdomains": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
]
}
],
"sourceMatchCase": true,
"sourceQuery": "<string>",
"sourceUseRegex": true,
"targetLangs": [
"<string>"
],
"targetMatchCase": true,
"targetQuery": "<string>",
"targetUseRegex": true,
"tuId": "<string>"
}
'import requests
url = "https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent"
payload = {
"filters": [
{
"clients": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"createdByUsers": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"createdFrom": "2023-11-07T05:31:56Z",
"createdTo": "2023-11-07T05:31:56Z",
"domains": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"filename": "<string>",
"keyName": "<string>",
"lastModifiedFrom": "2023-11-07T05:31:56Z",
"lastModifiedTo": "2023-11-07T05:31:56Z",
"modifiedByUsers": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"projects": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"subdomains": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }]
}
],
"sourceMatchCase": True,
"sourceQuery": "<string>",
"sourceUseRegex": True,
"targetLangs": ["<string>"],
"targetMatchCase": True,
"targetQuery": "<string>",
"targetUseRegex": True,
"tuId": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
filters: [
{
clients: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
createdByUsers: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
createdFrom: '2023-11-07T05:31:56Z',
createdTo: '2023-11-07T05:31:56Z',
domains: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
filename: '<string>',
keyName: '<string>',
lastModifiedFrom: '2023-11-07T05:31:56Z',
lastModifiedTo: '2023-11-07T05:31:56Z',
modifiedByUsers: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
projects: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
subdomains: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}]
}
],
sourceMatchCase: true,
sourceQuery: '<string>',
sourceUseRegex: true,
targetLangs: ['<string>'],
targetMatchCase: true,
targetQuery: '<string>',
targetUseRegex: true,
tuId: '<string>'
})
};
fetch('https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'filters' => [
[
'clients' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'createdByUsers' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'createdFrom' => '2023-11-07T05:31:56Z',
'createdTo' => '2023-11-07T05:31:56Z',
'domains' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'filename' => '<string>',
'keyName' => '<string>',
'lastModifiedFrom' => '2023-11-07T05:31:56Z',
'lastModifiedTo' => '2023-11-07T05:31:56Z',
'modifiedByUsers' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'projects' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'subdomains' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
]
]
],
'sourceMatchCase' => true,
'sourceQuery' => '<string>',
'sourceUseRegex' => true,
'targetLangs' => [
'<string>'
],
'targetMatchCase' => true,
'targetQuery' => '<string>',
'targetUseRegex' => true,
'tuId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent"
payload := strings.NewReader("{\n \"filters\": [\n {\n \"clients\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdFrom\": \"2023-11-07T05:31:56Z\",\n \"createdTo\": \"2023-11-07T05:31:56Z\",\n \"domains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"filename\": \"<string>\",\n \"keyName\": \"<string>\",\n \"lastModifiedFrom\": \"2023-11-07T05:31:56Z\",\n \"lastModifiedTo\": \"2023-11-07T05:31:56Z\",\n \"modifiedByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"projects\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"subdomains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ]\n }\n ],\n \"sourceMatchCase\": true,\n \"sourceQuery\": \"<string>\",\n \"sourceUseRegex\": true,\n \"targetLangs\": [\n \"<string>\"\n ],\n \"targetMatchCase\": true,\n \"targetQuery\": \"<string>\",\n \"targetUseRegex\": true,\n \"tuId\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"filters\": [\n {\n \"clients\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdFrom\": \"2023-11-07T05:31:56Z\",\n \"createdTo\": \"2023-11-07T05:31:56Z\",\n \"domains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"filename\": \"<string>\",\n \"keyName\": \"<string>\",\n \"lastModifiedFrom\": \"2023-11-07T05:31:56Z\",\n \"lastModifiedTo\": \"2023-11-07T05:31:56Z\",\n \"modifiedByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"projects\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"subdomains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ]\n }\n ],\n \"sourceMatchCase\": true,\n \"sourceQuery\": \"<string>\",\n \"sourceUseRegex\": true,\n \"targetLangs\": [\n \"<string>\"\n ],\n \"targetMatchCase\": true,\n \"targetQuery\": \"<string>\",\n \"targetUseRegex\": true,\n \"tuId\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"filters\": [\n {\n \"clients\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdFrom\": \"2023-11-07T05:31:56Z\",\n \"createdTo\": \"2023-11-07T05:31:56Z\",\n \"domains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"filename\": \"<string>\",\n \"keyName\": \"<string>\",\n \"lastModifiedFrom\": \"2023-11-07T05:31:56Z\",\n \"lastModifiedTo\": \"2023-11-07T05:31:56Z\",\n \"modifiedByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"projects\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"subdomains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ]\n }\n ],\n \"sourceMatchCase\": true,\n \"sourceQuery\": \"<string>\",\n \"sourceUseRegex\": true,\n \"targetLangs\": [\n \"<string>\"\n ],\n \"targetMatchCase\": true,\n \"targetQuery\": \"<string>\",\n \"targetUseRegex\": true,\n \"tuId\": \"<string>\"\n}"
response = http.request(request)
puts response.read_bodySearch TM content
Overview
- Searches TM content within a single Translation Memory (TM), matching against source and/or target segment text, with optional metadata filters.
Interpreting found results
- Searching a TARGET locale → response contains the matching target TUV plus the source TUV for that TU.
- Searching a SOURCE locale → response contains the full TU (matching source TUV and all target TUVs). One TU counts as a single found item, but the UI should render N
<srcTUV, targetTUV>pairs.
Query modes
- The operator (
sourceOperator|targetOperator) defaults toCONTAINSfor every query mode (the same default as the TM search UI). UseISto match the whole segment. - Exact query (plain text, no wildcard markers, regex disabled): if
sourceOperator|targetOperator=IS|IS_NOT(exact mode) the whole field must (not) match exactly; ifCONTAINS|DOES_NOT_CONTAIN(contains mode) the text may appear anywhere within the field. - Wildcard query (
sourceUseRegex|targetUseRegex=false): uses?(single character) and*(multi-character) placeholders. Both expand within a single word only (they never cross whitespace) and may appear anywhere in the word — e.g.trans*matchestranslation/transfer;*orningandmor*ngmatchmorning;tr?nslatematchestranslate/trenslate. Limits: max 5*and 10?per query. - Regex query (
sourceUseRegex|targetUseRegex=true): withCONTAINS(default)REGEXPsearches for substrings (not whole-word by default); withISthe expression must match the whole segment. The engine is Lucene’s automaton engine (Elasticsearch fleet: EU on 8.19.x pending reindex, other envs on 9.4.x — Lucene 9–10), not PCRE: it supports\w,\W,\d,\D,\s,\Sbut not word boundaries\b/\B, look-around, or back-references. Unicode property classes (\p{L},\P{Nd}, …) are broadened internally and re-validated exactly, so e.g.\p{L}\.\p{L}\.returns correct results. A construct the engine cannot evaluate returns “Unsupported regular expression”; a malformed expression returns “Invalid regular expression”. Prefer wildcard queries for word-based matching.
CONTAINS / IS semantics (non-regex queries)
CONTAINSis a phrase (substring) match: the query text must appear in the segment as one contiguous sequence, in the given word order. It is not an “any word” match — e.g.small carmatchesthe small car is redbut neithersmall blue carnorcar small.ISrequires the whole segment to equal the query (after whitespace normalization).- Matching is case-insensitive unless
sourceMatchCase|targetMatchCase=true. - Double quotes have no special meaning here (unlike the
searchandwildCardSearchendpoints) — they are searched as literal characters, so"small car"only matches segments that actually contain the quote characters. Do not wrap the query in quotes;CONTAINSalready performs phrase matching. - A query may end or start in the middle of a word only when at least one other word of the query matches a whole word — e.g.
good mornmatchesgood morning, butmornalone does not. Use a wildcard (morn*) for partial-word matching. - Languages written without spaces (Chinese, Japanese, Korean, Thai) are matched as a contiguous character sequence as well.
Metadata filters
filtersaccepts multiple metadata filter criteria (projects, domain, subdomains, …); AND logic is applied across them.
Plan gating
- This is a Business/Enterprise (or legacy Ultimate/Enterprise) feature. When the caller’s organization is not entitled to it, the response is
501 Not ImplementedwitherrorCode: TRANS_MEMORY_SEARCH_NOT_ENABLED— distinct from an unimplemented endpoint — so callers can tell “not entitled” apart from “not built”.
Defaults & limitations
- Whitespace is normalized; the wildcard processor can filter out Phrase tags.
- Even wildcard results are post-filtered to enforce correct word order.
- A single query is capped at 10,000 matches. If more than 10,000 segments match, only the first 10,000 are returned and
totalElementswill not exceed that cap.
Execution & performance notes
REGEXPuses non-analyzed normalized fields; additional post-validation ensures fidelity to the original query text.- Matching TUVs are collected until
batchSizeis reached; only then are sibling TUVs from the same TU loaded. - For pagination (changing
index), ES results are re-processed to keeptotalElementsaccurate. - Non-regex queries first retrieve candidate segments sharing at least one word with the query (for Chinese/Japanese: at least one character), then validate each candidate against the exact query sequence. All candidates are validated to compute
totalElements, so queries consisting of very common words or characters can be slow on large TMs. - If the search exceeds the time limit (about 1 minute), the response is
400 Bad Request(“Search query for this TM takes too long…”); refine the query or add filters.
curl --request POST \
--url https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"filters": [
{
"clients": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"createdByUsers": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"createdFrom": "2023-11-07T05:31:56Z",
"createdTo": "2023-11-07T05:31:56Z",
"domains": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"filename": "<string>",
"keyName": "<string>",
"lastModifiedFrom": "2023-11-07T05:31:56Z",
"lastModifiedTo": "2023-11-07T05:31:56Z",
"modifiedByUsers": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"projects": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
],
"subdomains": [
{
"uid": "3HYnHHLkTPJfMxBCDbPXFe"
}
]
}
],
"sourceMatchCase": true,
"sourceQuery": "<string>",
"sourceUseRegex": true,
"targetLangs": [
"<string>"
],
"targetMatchCase": true,
"targetQuery": "<string>",
"targetUseRegex": true,
"tuId": "<string>"
}
'import requests
url = "https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent"
payload = {
"filters": [
{
"clients": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"createdByUsers": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"createdFrom": "2023-11-07T05:31:56Z",
"createdTo": "2023-11-07T05:31:56Z",
"domains": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"filename": "<string>",
"keyName": "<string>",
"lastModifiedFrom": "2023-11-07T05:31:56Z",
"lastModifiedTo": "2023-11-07T05:31:56Z",
"modifiedByUsers": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"projects": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }],
"subdomains": [{ "uid": "3HYnHHLkTPJfMxBCDbPXFe" }]
}
],
"sourceMatchCase": True,
"sourceQuery": "<string>",
"sourceUseRegex": True,
"targetLangs": ["<string>"],
"targetMatchCase": True,
"targetQuery": "<string>",
"targetUseRegex": True,
"tuId": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
filters: [
{
clients: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
createdByUsers: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
createdFrom: '2023-11-07T05:31:56Z',
createdTo: '2023-11-07T05:31:56Z',
domains: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
filename: '<string>',
keyName: '<string>',
lastModifiedFrom: '2023-11-07T05:31:56Z',
lastModifiedTo: '2023-11-07T05:31:56Z',
modifiedByUsers: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
projects: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}],
subdomains: [{uid: '3HYnHHLkTPJfMxBCDbPXFe'}]
}
],
sourceMatchCase: true,
sourceQuery: '<string>',
sourceUseRegex: true,
targetLangs: ['<string>'],
targetMatchCase: true,
targetQuery: '<string>',
targetUseRegex: true,
tuId: '<string>'
})
};
fetch('https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'filters' => [
[
'clients' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'createdByUsers' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'createdFrom' => '2023-11-07T05:31:56Z',
'createdTo' => '2023-11-07T05:31:56Z',
'domains' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'filename' => '<string>',
'keyName' => '<string>',
'lastModifiedFrom' => '2023-11-07T05:31:56Z',
'lastModifiedTo' => '2023-11-07T05:31:56Z',
'modifiedByUsers' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'projects' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
],
'subdomains' => [
[
'uid' => '3HYnHHLkTPJfMxBCDbPXFe'
]
]
]
],
'sourceMatchCase' => true,
'sourceQuery' => '<string>',
'sourceUseRegex' => true,
'targetLangs' => [
'<string>'
],
'targetMatchCase' => true,
'targetQuery' => '<string>',
'targetUseRegex' => true,
'tuId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent"
payload := strings.NewReader("{\n \"filters\": [\n {\n \"clients\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdFrom\": \"2023-11-07T05:31:56Z\",\n \"createdTo\": \"2023-11-07T05:31:56Z\",\n \"domains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"filename\": \"<string>\",\n \"keyName\": \"<string>\",\n \"lastModifiedFrom\": \"2023-11-07T05:31:56Z\",\n \"lastModifiedTo\": \"2023-11-07T05:31:56Z\",\n \"modifiedByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"projects\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"subdomains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ]\n }\n ],\n \"sourceMatchCase\": true,\n \"sourceQuery\": \"<string>\",\n \"sourceUseRegex\": true,\n \"targetLangs\": [\n \"<string>\"\n ],\n \"targetMatchCase\": true,\n \"targetQuery\": \"<string>\",\n \"targetUseRegex\": true,\n \"tuId\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"filters\": [\n {\n \"clients\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdFrom\": \"2023-11-07T05:31:56Z\",\n \"createdTo\": \"2023-11-07T05:31:56Z\",\n \"domains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"filename\": \"<string>\",\n \"keyName\": \"<string>\",\n \"lastModifiedFrom\": \"2023-11-07T05:31:56Z\",\n \"lastModifiedTo\": \"2023-11-07T05:31:56Z\",\n \"modifiedByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"projects\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"subdomains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ]\n }\n ],\n \"sourceMatchCase\": true,\n \"sourceQuery\": \"<string>\",\n \"sourceUseRegex\": true,\n \"targetLangs\": [\n \"<string>\"\n ],\n \"targetMatchCase\": true,\n \"targetQuery\": \"<string>\",\n \"targetUseRegex\": true,\n \"tuId\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://cloud.memsource.com/web/api2/v1/transMemories/{transMemoryUid}/searchContent")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"filters\": [\n {\n \"clients\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"createdFrom\": \"2023-11-07T05:31:56Z\",\n \"createdTo\": \"2023-11-07T05:31:56Z\",\n \"domains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"filename\": \"<string>\",\n \"keyName\": \"<string>\",\n \"lastModifiedFrom\": \"2023-11-07T05:31:56Z\",\n \"lastModifiedTo\": \"2023-11-07T05:31:56Z\",\n \"modifiedByUsers\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"projects\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ],\n \"subdomains\": [\n {\n \"uid\": \"3HYnHHLkTPJfMxBCDbPXFe\"\n }\n ]\n }\n ],\n \"sourceMatchCase\": true,\n \"sourceQuery\": \"<string>\",\n \"sourceUseRegex\": true,\n \"targetLangs\": [\n \"<string>\"\n ],\n \"targetMatchCase\": true,\n \"targetQuery\": \"<string>\",\n \"targetUseRegex\": true,\n \"tuId\": \"<string>\"\n}"
response = http.request(request)
puts response.read_bodyAuthorizations
Get a token from auth/login endpoint and then pass it in the Authorization HTTP header in every subsequent API call. For more information visit our help center.
Path Parameters
Translation memory UID
Query Parameters
Start index for pagination (default: 0)
x >= 0Batch size, accepts values between 1 and 100, default 50
0 <= x <= 100Body
Search TM content request payload
Filter for related metadata (e.g. project, client, ...). It's possible to provide multiple filter criteria of same type (AND logic applied)
Show child attributes
Show child attributes
If true, sourceQuery will be considered case-sensitive
Matching operator for sourceQuery. Default: CONTAINS
IS, IS_NOT, CONTAINS, DOES_NOT_CONTAIN Query string for source part of segment. Provide either sourceQuery or targetQuery (not both)
If true, sourceQuery will be considered to be regular expression
Target languages/locales of the given TM to search in. Example: en_us
If true, targetQuery will be considered case-sensitive
Matching operator for targetQuery. Default: CONTAINS
IS, IS_NOT, CONTAINS, DOES_NOT_CONTAIN Query string for target part of segment. Provide either sourceQuery or targetQuery (not both)
If true, targetQuery will be considered to be regular expression
ID of the translation unit
Response
OK
Was this page helpful?