Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Depending on the project configuration, the operation will typically do everything needed to get translation workflows runningready and going: Save files to project, mark online, pre-translate and word count, create and assign jobs.

...

PARAMETERS

The URL parameters are:

idpid

The invoice project’s ID.

int, Mandatory

The request BODY contains a JSON payload object with the new invoice’s these properties:

properties

Optional. Use if you want to update any of the properties.

Refer to Invoice Properties Record and notable the section “UPDATING”

object, Optional

lines

Optional. Use if you want to replace the existing invoice lines with a new set of lines.

An array if invoice lines. You must submit at least 1 line.

See Invoice Line Record and make sure to read the notes on Inserting and Updating lines.

object[], Optional

distribution

This is optional. It will be populated with the presets configured in the client record by default (which usually is what is wanted).

If you want to customize this section, submit this object: Invoice Distribution Record

object?, Optionalfiles

An array with one or more records, each describing a file to be uploaded. The records include the token referencing an uploaded a file. Example:

Code Block
[
    {
        "token": "77ca3562-ff01f5882dd1",
        "name": "myfolder/myfile.docx"
    }
]

See detailed description further down.

object[], Mandatory

src

The source language code. This must be a valid project language.

string, Mandatory

trgs

The languages to translate to. These must be valid project languages. Example:

Code Block
"trgs": [ "es-ES", "fr-FR" ]

string[], Mandatory

deadline

Optional deadline for completion of work. Deadlines are assigned to the jobs that are created with the workflow. Example:

Code Block
"deadline": "2024-04-03T06:00:00Z"

datetime?, Optional

workflow

Optional, selects "Default" if not specified. Fine-tune how workflows are created:

  • Default : Create jobs according to the project’s Workflow & Suppliers configuration. Recommended value.

  • None : Do not create any jobs.

string, Optional

allowUpdates

Optional. Default is true.

  • true: You are allowed to replace existing files with new versions. In such cases, the file is replaced, a new set of jobs will be created and the new jobs will be assigned to the same workers as before.

  • false: Any attempt to replace an existing file will return an error.

bool?, Optional

jobsCfs

Optional custom fields to assign to all jobs created for a file’s workflow. See Custom Field Collection Record for details.

Example:

Code Block
"fields": [
    {
        "title": "Activity",
        "value": "Fulltime"
    },
    {
        "id": 4,
        "value": "A-221"
    }    
  ]

RESULTS

The result is the updated invoice document.

...