resources/segments/view/import

To import segments to a Word, Excel or Xliff file after offline editing.

URL

(POST) /resources/segments/view/import

PARAMETERS

The message body contains a JSON object:

scope

The scope object. It delimits the total range of segments and related resources that can be operated on.

Mandatory, object

settings


token

The token of file uploaded (with

media/upload

method).

Mandatory, string

doCommit

Boolean. if updates shall be committed or if we only need the report.

Mandatory, bool

writelocked

Boolean. Default is false.

If false then locked segments will not be updated from the imported file.

Even if this is true, the user must have the access right to change locked segments.

Optional, bool?


Mandatory, object


RESULTS

An Asynchronous operation formatted JSON.

When finished the JSON contains :

custom.filename

The name of file imported

string

custom.fileref

The token of the file uploaded for import.

string

custom.report


changes

Number. the total number of changes detected during analyze.

int

errors

Number. the total number of erroneous detected during analyze.

int

isFatal

Boolean. True if the import there was an error during import process.

bool

fatalDetails

Only if "fatal" is true: informations about the error.

string?

fieldChanges

List of fields updated.

object[]

importConflicts

Number. the total number of conflicted segments.

int

importUpdated

Number. the total number of updated segments.

int

nochanges

Number. The total number of segments without modification.

int

processed

Number. The total number of segments analyzed during import.

int

total

Number. The total number of segments.

int


object

 

 

JavaScript
{
	"trm": {
		"requestid":0,
		"isbatch":false,
		"status":"Finished",
		"statusText":"Finished!"
	},
	"custom":{
		"fileref":"d2f9c5c2371d44eb84fe651885f73948",
		"filename":"export_editortest1_en_es-es.docx",
		"report":{
			"isfatal":false,
			"fatal":null,
			"fatalDetails":null,
			"total":33,
			"processed":33,
			"errors":0,
			"changes":1,
			"fieldChanges":[
				{"type":0,"title":"Spanish (Spain)","count":1}
			],
			"nochanges":32,
			"importExecuted":false,
			"importUpdated":1,
			"importConflicts":0
		}
	}
}