Documentation

SourceStringApi extends AbstractApi
in package

Source strings are the text units for translation. Instead of modifying source files, you can manage source strings one by one.

Use API to add, edit, or delete some specific strings in the source-based and files-based projects.

Table of Contents

Methods

batchOperations()  : mixed
String Batch Operations
create()  : SourceString|null
Add String
delete()  : mixed
Delete String
get()  : SourceString
Get String
list()  : ModelCollection
List Strings
update()  : SourceString|null
Edit String

Methods

batchOperations()

String Batch Operations

public batchOperations(int $projectId, array<string|int, mixed> $data) : mixed
Parameters
$projectId : int
$data : array<string|int, mixed>

string $data[op] required Patch operation to perform (replace, add, remove)
string $data[path] required value $data[value] required object, string, int, or bool

Tags
link

API Documentation

link

API Documentation Enterprise

create()

Add String

public create(int $projectId, array<string|int, mixed> $data) : SourceString|null
Parameters
$projectId : int
$data : array<string|int, mixed>

string $data[identifier] Required for strings-based projects or file-based projects if scheme of CSV file includes identifier column
string $data[text] required
integer $data[fileId]
string $data[context]
bool $data[isHidden]
integer $data[maxLength]

Tags
link

API Documentation

link

API Documentation Enterprise

Return values
SourceString|null

        
On this page

Search results