Versions Compared

Key

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

You start by connecting to a Beebox project. Upon connection you obtain a session token. This token is included with all subsequent calls.

URL

(GET) http://localhost{server:8089port}/api/connect?projectaccount=&login=&pwd=&waitsecsdomain=&connector=&versionui=

PARAMETERS

The url parameters are:

projectaccount

The identifier of the project to connect to. You can find this id in the project settings page:

login

You can create credentials individually per each project. Go to the project "Settings", then select "Connectors & API" and create login/password. These credentials can access data in the specific project and basic API methods only. Typically, these credentials would are perfect for CMS (Content Management System) connectors.

Alternatively, you can use the administrator credentials. In that case you need to follow special rules.

password

 

waitsecs

Optional number. Default is 10.

Indicates the timeout in seconds for this call. Purpose: Whenever the Beebox executes automated operations, it blocks login attempts. This parameter indicates how long the login method waits before it returns an error.

connector

Free text that identifies your connector. For example “Drupal by xy” or “Magento”. Keep it a short product name.

version

Free text containing the version number of your connector. For example "1.1.0"Mandatory. The Account ID. This is the same value as entered when logging in online.

login

Mandatory. The User Login. This is the same value as entered when logging in online.

password

Mandatory. The User Password. This is the same value as entered when logging in online.

domain

Mandatory. Specifies the Wordbee Translator functionality you want to work with. These value are supported:

  • InstantTranslation : To interface with the Wordbee Translator instant translation tool.

 

ui

Optional. The user interface language. Default value is "en" if not specified. Permitted values are:

  • en (English)
  • fr (French)
  • de (German)
  • es (Spanish)
  • ja (Japanese)
  • nl (Dutch)

The API will localize certain strings like language names accordingly in results.

 

RESULTS

The API returns a session token which you include with JSON object which includes the session token for all subsequent API calls.

It is important to systematically verify the HTTP status code. If authentication succeeds, the method returns HTTP code 200 (success). All other HTTP codes point to an error.

 

tokenThe session token which you must include with all subsequent API calls.
platform

If the server is busy due to a running server operation, the method will wait for the amount of seconds specified in the “waitsecs” parameter. If the server is still busy after this period, the method fails with an error id "BUSY". In that case please wait a few seconds and retry.

 

...

titleHTTP status codes

...

The owner of the Wordbee Translator instance.
companyThe company name of the connected user.
userThe name of the connected user.
InstantTranslation

Included if you connected to this application domain.

See xxx for description.

EXAMPLE

In this example we connected with ...&domain=InstantTranslation:

 

Code Block
{
  "token": "14c78440-7d7a-4504-9f46-4fa322fecdb5",


  "platform": "Alpha Ltd.",
  "company": "John Howard Translations",
  "user": "John Howard",


  "InstantTranslation": {
    "urlTerms": null,
    "deadlineMandatory": true,
    "deadlineMinLeadHours": 12
  }
}

 

ERROR HANDLING

If the HTTP status code is different from 200, the connect method failed. What exactly went wrong is detailed with the HTTP error result.

Make sure to read this section: Error Handling.

 

DISCONNECTING

Always invalidate your token when you no longer need it. Failing to do so may put on hold automatic operations.

See API - Disconnect.