All URIs are relative to https://api.phrase.com/v2
Method | HTTP request | Description |
---|---|---|
searchInAccount | POST /accounts/{account_id}/search | Search across projects |
\Phrase\Model\AccountSearchResult searchInAccount($account_id, $search_in_account_parameters, $x_phrase_app_otp)
Search across projects
Search for keys and translations in all account projects
Note: Search is limited to 10000 results and may not include recently updated data depending on the project sizes.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$config = Phrase\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY');
$config = Phrase\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'token');
$apiInstance = new Phrase\Api\SearchApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$account_id = 'account_id_example'; // string | Account ID
$search_in_account_parameters = new \Phrase\Model\SearchInAccountParameters(); // \Phrase\Model\SearchInAccountParameters |
$x_phrase_app_otp = 'x_phrase_app_otp_example'; // string | Two-Factor-Authentication token (optional)
try {
$result = $apiInstance->searchInAccount($account_id, $search_in_account_parameters, $x_phrase_app_otp);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling SearchApi->searchInAccount: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
account_id | string | Account ID | |
search_in_account_parameters | \Phrase\Model\SearchInAccountParameters | ||
x_phrase_app_otp | string | Two-Factor-Authentication token (optional) | [optional] |
\Phrase\Model\AccountSearchResult
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]