6.0.0 • Published 5 years ago

@datafire/motaword v6.0.0

Weekly downloads
1
License
MIT
Repository
github
Last release
5 years ago

@datafire/motaword

Client library for MotaWord API

Installation and Usage

npm install --save @datafire/motaword
let motaword = require('@datafire/motaword').create({
  username: "",
  password: "",
  access_token: "",
  refresh_token: "",
  client_id: "",
  client_secret: "",
  redirect_uri: ""
});

.then(data => {
  console.log(data);
});

Description

Use MotaWord API to post and track your translation projects.

Actions

oauthCallback

Exchange the code passed to your redirect URI for an access_token

motaword.oauthCallback({
  "code": ""
}, context)

Input

  • input object
    • code required string

Output

  • output object
    • access_token string
    • refresh_token string
    • token_type string
    • scope string
    • expiration string

oauthRefresh

Exchange a refresh_token for an access_token

motaword.oauthRefresh(null, context)

Input

This action has no parameters

Output

  • output object
    • access_token string
    • refresh_token string
    • token_type string
    • scope string
    • expiration string

getEndpoints

The root endpoint will provide you a JSON Swagger definition.

motaword.getEndpoints(null, context)

Input

This action has no parameters

Output

  • output object

downloadAsync

Download async request files

motaword.downloadAsync({
  "async_request_key": ""
}, context)

Input

  • input object
    • async_request_key required string: Async operation key

Output

  • output string

getBlogPosts

Get blog posts - ordered by created desc by default

motaword.getBlogPosts({}, context)

Input

  • input object
    • locale string: Article language, default en. When no blog article is available and fallback=true is specified, it falls back to en.
    • fallback boolean: When true, and no article is found in the locale, it falls back to locale=en.
    • page integer
    • per_page integer

Output

getCommissions

Returns a commission list of current client.

motaword.getCommissions(null, context)

Input

This action has no parameters

Output

getCommissionsByFilter

Returns a commission list of current client.

motaword.getCommissionsByFilter({}, context)

Input

Output

getCorporateUsers

Get a list of users for this corporate id

motaword.getCorporateUsers({
  "corporateId": 0
}, context)

Input

  • input object
    • corporateId required integer: Corporate ID

Output

deleteAccount

Delete requester account

motaword.deleteAccount(null, context)

Input

This action has no parameters

Output

getDocuments

Get a list of your documents

motaword.getDocuments({}, context)

Input

  • input object
    • recent boolean: When true, this will return the most 4 recent active documents.
    • search string
    • type_filter string (values: ALL, TEXT_DOCUMENTS, PRESENTATIONS, SPREADSHEETS, PDFS, IMAGES, SUBTITLES, DESIGNS, LOCALIZATION, WEB, STYLE_GUIDES, GLOSSARIES)
    • language_code string: searches in source language of documents, in source and target languages of document's quote
    • page integer
    • per_page integer
    • order_by string (values: id, updated_at, created_at, name)
    • order_type string (values: asc, desc)
    • with[] array: Attach further information. Possible values 'preview' to fetch temporary preview URLs for Box.com or native PDF. This is NOT recommended to be used with list calls. Only use with[]=preview for single document/style guide calls.

Output

getSimilarDocuments

Find documents similar to this document. Optionally, include translation information.

motaword.getSimilarDocuments({
  "documentId": 0
}, context)

Input

  • input object
    • documentId required integer: Document ID
    • per_page integer: Determines the number of similar documents to return.
    • with[] array: Attach further information. Possible values 'preview' to fetch temporary preview URLs for Box.com or native PDF. This is NOT recommended to be used with list calls. Only use with[]=preview for single document/style guide calls.

Output

useAsDraft

Use the translation of given source manual document as manual draft source for the given target document.

motaword.useAsDraft({
  "documentId": 0
}, context)

Input

Output

useAsRegular

Use the translation of the given manual document as a regular file.

motaword.useAsRegular({
  "documentId": 0
}, context)

Input

Output

downgradeProofreader

motaword.downgradeProofreader(null, context)

Input

This action has no parameters

Output

getEarnings

Returns your vendor earnings. Includes real-time earnings from ongoing projects, and fixed earnings from completed projects. Also includes total earnings and string edits.

motaword.getEarnings(null, context)

Input

This action has no parameters

Output

getFormats

Get a list of supported formats for documents, style guides and extensions.

motaword.getFormats(null, context)

Input

This action has no parameters

Output

freezeAccount

Freeze requester account for project notifications

motaword.freezeAccount(null, context)

Input

This action has no parameters

Output

downloadGlobalGlossary

Download your corporate account's global glossary. This endpoint is available only for corporate account customers.

motaword.downloadGlobalGlossary(null, context)

Input

This action has no parameters

Output

  • output string

updateGlobalGlossary

Update your corporate account's global glossary. This endpoint is available only for corporate account customers.

motaword.updateGlobalGlossary({
  "glossary": ""
}, context)

Input

  • input object
    • glossary required string: Glossary file. Currently supported formats: .xlsx, .tbx

Output

getLanguages

Get a list of supported languages

motaword.getLanguages(null, context)

Input

This action has no parameters

Output

logLocation

Log user's current location. This data is used in our Intelligent Project Manager for various data analysis, including project prioritization for vendors and account validation.

motaword.logLocation({}, context)

Input

Output

makeProofreader

motaword.makeProofreader(null, context)

Input

This action has no parameters

Output

getMe

Get your user information, including client or vendor specific info.

motaword.getMe(null, context)

Input

This action has no parameters

Output

updateMe

Update your user information.

motaword.updateMe({}, context)

Input

Output

subscribeNotification

motaword.subscribeNotification({}, context)

Input

Output

unsubscribeNotification

motaword.unsubscribeNotification({}, context)

Input

Output

updatePassword

Update user password. Password should contain at least one uppercase, lowercase character and one number

motaword.updatePassword({}, context)

Input

Output

getPaymentInfo

Get your payment Info

motaword.getPaymentInfo(null, context)

Input

This action has no parameters

Output

updatePaymentInfo

Update payment info

motaword.updatePaymentInfo({}, context)

Input

Output

uploadProfilePicture

motaword.uploadProfilePicture({
  "profile_picture": ""
}, context)

Input

  • input object
    • profile_picture required string: Profile picture file contents. Accepted extensions are png, jpg.

Output

getProjects

Get a list of your projects

motaword.getProjects({}, context)

Input

  • input object
    • page integer
    • per_page integer
    • status[] array: Filter projects by status. Accepts multiple statuses. Possible values 'pending', 'started', 'completed'
    • with_pending boolean: deprecated. use status[] param.
    • with_started boolean: deprecated. use status[] param.
    • with_completed boolean: deprecated. use status[] param.
    • order_by string (values: id, status, delivery, price)
    • order_type string (values: asc, desc)

Output

createProject

Create a new project

motaword.createProject({}, context)

Input

  • input object
    • callback_url string: Optional. If you provide a callback URL, we will send POST callbacks when the status of the current project is changed. Possible status changes are, 'translated', 'proofread', 'completed'.
    • coupon_code string: Coupon code to redeem
    • custom array: Optional. This is a consistent custom data parameter that will be given to you in the response across every request of this project model. Values should be provided like this, custommy_key = my_value.
    • documents[] string: Optional. You can add as many files as you want in documents[] parameter. Or you add your documents later in separate calls.
    • glossaries[] string: Optional. Only one glossary is supported at the moment.
    • source_language string
    • styleguides[] string: Optional. You can add as many files as you want in styleguides[] parameter. Or you add your style guides later in separate calls.
    • target_languages[] array

Output

getVendorProjects

Get a list of your vendor projects

motaword.getVendorProjects({}, context)

Input

  • input object
    • joined boolean: Return only projects that this user has already joined
    • completed boolean: Return only projects that have been completed. When true, this makes joined true as well.
    • page integer
    • per_page integer

Output

deleteProject

Delete(cancel) a project.

motaword.deleteProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

getProject

Get single project

motaword.getProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • with[] array: Include detailed information. Possible values 'client', 'vendor', 'score'

Output

updateProject

Update project language pairs

motaword.updateProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • callback_url string: Optional. If you provide a callback URL, we will send POST callbacks when the status of the current project is changed. Possible status changes are, 'translated', 'proofread', 'completed'.
    • coupon_code string: Coupon code to redeem
    • custom array: Optional. This is a consistent custom data parameter that will be given to you in the response across every request of this project model. Values should be provided like this, custommy_key = my_value. If you previously provided one, it will be replaced.
    • source_language string
    • target_languages[] array

Output

triggerCallback

Trigger a call to your callback URL related to this project.

motaword.triggerCallback({
  "id": 0,
  "actionType": ""
}, context)

Input

  • input object
    • id required integer: Project ID
    • actionType required string (values: translated, proofread, completed): Callback type

Output

cancelProject

Cancel your translation project

motaword.cancelProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • reason string: Cancellation reason

Output

deliverProject

Deliver project

motaword.deliverProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

download

Download the latest translation package. You must have given a /package call beforehand and wait until the packaging status is 'completed'.

motaword.download({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

  • output string

downloadLanguage

Download only the translation package of this language. You must have given a /package call beforehand and wait until the packaging status is 'completed'.

motaword.downloadLanguage({
  "id": 0,
  "language": ""
}, context)

Input

  • input object
    • id required integer: Project ID
    • language required string: Language code. You can download the translation of only a specific language.

Output

  • output string

getInvoice

Get invoice details

motaword.getInvoice({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

downloadHtmlInvoice

Download invoice as html by project id.

motaword.downloadHtmlInvoice({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

  • output string

downloadPdfInvoice

Download invoice as pdf by project id.

motaword.downloadPdfInvoice({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

  • output string

launchProject

Launch your translation project

motaword.launchProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • bin string: Last 4 digits of the credit card you are using one-time. This parameter is only required when stripe_token is provided.
    • budget_code string: Optional with corporate accounts. Not available for others.
    • card_id integer: Optional. client, app, corporate_card methods require a credit card ID. credit method requires Stripe token and bin.
    • payment_code string: Optional. corporate payment method requires this.s
    • payment_method string (values: corporate, client, app, credit, corporate_card): Optional. Determines which method to use for payment. client, app, corporate_card methods require a credit card ID. credit method requires Stripe token and bin. corporate method follows corporate account policy automatically, either follows invoicing flow or automatically charges corporate's primary card.
    • stripe_token string: This is required if you are using a one-time credit card. This is the token generted from frontend via Stripe SDK. If you are using a one-time card with stripe_token, you must also provide bin, last 4 digits of the card.

Output

package

Package the translation project, make it ready to be downloaded.

motaword.package({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • async integer: If you want to package and download the translation synchronously, mark this parameter as '0'. It will package the translation and then return the packaged file in the response, identical to /download call after an asynchronous /package call.

Output

  • output string

trackPackage

This request will tell you the current progress of the translation packaging. You will use the 'key' provided by the /package call.

motaword.trackPackage({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • key string: This is the package tracking key provided in the response of a /package call.

Output

packageLanguage

Package the translation project, make it ready to be downloaded.

motaword.packageLanguage({
  "id": 0,
  "language": ""
}, context)

Input

  • input object
    • id required integer: Project ID
    • language required string: Language code. You can package the translation of only a specific language.
    • async integer: If you want to package and download the translation synchronously, mark this parameter as '0'. It will package the translation and then return the packaged file in the response, identical to /download call after an asynchronous /package call.

Output

getProgress

Get the progress of an already launched project.

motaword.getProgress({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • raw boolean: This will return a more raw progress information for translation and proofreading. For instance, when completed, we will return 100% for both tasks by default, whereas their actual progress may be lower than 100%.

Output

recreateProject

Recreate your translation project from scratch. This is a risky action, you will lose current translations.

motaword.recreateProject({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

submitProjectReports

Submit reports for a project

motaword.submitProjectReports({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • activity_type string: Activity Type
    • message string: Report Message

Output

deleteProjectWebhook

Delete project webhooks. Projects currently support registering only 1 webhook. This endpoint deletes the previously registered webhook.

motaword.deleteProjectWebhook({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

getProjectWebhooks

Get project information (includes callback_url for webhook). Currently projects can have only 1 webhook registered.

motaword.getProjectWebhooks({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID

Output

postProjectWebhook

Update project webhook URL

motaword.postProjectWebhook({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • body object
      • callback_url string: Webhook URL. We will send POST callbacks when the status of the current project is changed. Possible status changes are, 'translated', 'proofread', 'completed'.

Output

updateProjectWebhook

Update project webhook URL

motaword.updateProjectWebhook({
  "id": 0
}, context)

Input

  • input object
    • id required integer: Project ID
    • body object
      • callback_url string: Webhook URL. We will send POST callbacks when the status of the current project is changed. Possible status changes are, 'translated', 'proofread', 'completed'.

Output

getActivities

Get a list of realtime activities on the project, such as translation suggestion and translation approval.

motaword.getActivities({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • page integer
    • per_page integer

Output

getActivity

Get a single realtime activity.

motaword.getActivity({
  "projectId": 0,
  "activityId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • activityId required integer: Activity ID

Output

submitComment

Submit a comment to an activity.

motaword.submitComment({
  "projectId": 0,
  "activityId": 0,
  "comment": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • activityId required integer: Activity ID
    • comment required string: Comment text.

Output

getActivityComments

Get a list of comments belonging to this activity.

motaword.getActivityComments({
  "projectId": 0,
  "activityId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • activityId required integer: Activity ID

Output

getComments

Get a list of activity comments throughout the whole project.

motaword.getComments({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • page integer
    • per_page integer

Output

getProjectDocuments

Get a list of documents

motaword.getProjectDocuments({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • with[] array: Attach further information. Possible values 'preview' to fetch temporary preview URLs for Box.com or native PDF. This is NOT recommended to be used with list calls. Only use with[]=preview for single document/style guide calls.

Output

createProjectDocument

Upload a new document

motaword.createProjectDocument({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documents[] array: You can add as many files as you want in documents[] parameter.
    • schemes[] string: JSON string. If your documents have a scheme, as in cases of CSV files, use the same array index keys for schemes parameter to specify their schemes. See Document Schemes title in the API documentation.
    • source-links[] array: When provided, we will download the files from these URLs, in addition to files provded in documents parameter and then save as source documents

Output

deleteProjectDocument

Delete the document

motaword.deleteProjectDocument({
  "projectId": 0,
  "documentId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documentId required integer: Document ID

Output

getProjectDocument

Get single document

motaword.getProjectDocument({
  "projectId": 0,
  "documentId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documentId required integer: Document ID
    • with[] array: Attach further information. Possible values 'preview' to fetch temporary preview URLs for Box.com or native PDF. This is NOT recommended to be used with list calls. Only use with[]=preview for single document/style guide calls.

Output

updateProjectDocument

Update the document. File name and contents will replaced with the new one.

motaword.updateProjectDocument({
  "projectId": 0,
  "documentId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documentId required integer: Document ID
    • documents string: Single file data. The name is plural to provide a consistent naming convention.
    • schemes string: JSON string. If your documents have a scheme, as in cases of CSV files, use the same array index keys for schemes parameter to specify their schemes. See Document Schemes title in the API documentation.
    • source-link object

Output

downloadProjectDocument

Download a document

motaword.downloadProjectDocument({
  "projectId": 0,
  "documentId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documentId required integer: Document ID

Output

  • output string

getDocumentTranslations

Get a list of strings and its translations in the document.

motaword.getDocumentTranslations({
  "projectId": 0,
  "documentId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documentId required integer: Document ID

Output

getDocumentTranslationsForLanguage

Get a list of strings and its translations in the document for this target language of the project.

motaword.getDocumentTranslationsForLanguage({
  "projectId": 0,
  "documentId": 0,
  "language": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • documentId required integer: Document ID
    • language required string: Target language code.

Output

getGlossaries

Get a list of glossaries

motaword.getGlossaries({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID

Output

createGlossary

Upload a new glossary

motaword.createGlossary({
  "projectId": 0,
  "glossaries": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • glossaries required string: You can only add one glossary, even though the name suggests multiple glossaries. This may be updated in the future to support multiple glossaries.

Output

deleteGlossary

Delete the glossary

motaword.deleteGlossary({
  "projectId": 0,
  "glossaryId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • glossaryId required integer: Glossary ID

Output

getGlossary

Get single glossary

motaword.getGlossary({
  "projectId": 0,
  "glossaryId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • glossaryId required integer: Glossary ID

Output

updateGlossary

Update the glossary. File name and contents will replaced with the new one.

motaword.updateGlossary({
  "projectId": 0,
  "glossaryId": 0,
  "glossaries": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • glossaryId required integer: Glossary ID
    • glossaries required string: Single file data. The name is plural to provide a consistent naming convention.

Output

downloadGlossary

Download a glossary

motaword.downloadGlossary({
  "projectId": 0,
  "glossaryId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • glossaryId required integer: Glossary ID

Output

  • output string

getProjectStrings

Get a list of strings and its translations in the project.

motaword.getProjectStrings({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID

Output

packageProjectTranslationMemory

Get the translation memory of a project in TMX format

motaword.packageProjectTranslationMemory({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • async integer: If you want to package and download the translation memory synchronously, mark this parameter as '0'. It will package the translation memory and then return the packaged file in the response, identical to async/download call after an asynchronous /package call.
    • format string: Translation Memory file format

Output

packageProjectTranslationMemoryStatus

If package call was async, check the status of the request

motaword.packageProjectTranslationMemoryStatus({
  "projectId": 0,
  "async_request_key": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • async_request_key required string: Async operation key

Output

packageProjectTranslationMemoryForLanguage

Get the translation memory of a project in TMX format

motaword.packageProjectTranslationMemoryForLanguage({
  "projectId": 0,
  "languageCode": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • languageCode required string: Language Code
    • async integer: If you want to package and download the translation memory synchronously, mark this parameter as '0'. It will package the translation memory and then return the packaged file in the response, identical to async/download call after an asynchronous /package call.
    • format string: Translation Memory file format

Output

packageProjectTranslationMemoryForLanguageStatus

If package call was async, check the status of the request

motaword.packageProjectTranslationMemoryForLanguageStatus({
  "projectId": 0,
  "languageCode": "",
  "async_request_key": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • languageCode required string: Language Code
    • async_request_key required string: Async operation key

Output

getProjectStringsForLanguage

Get a list of strings and its translations in the project for this target language in the project.

motaword.getProjectStringsForLanguage({
  "projectId": 0,
  "language": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • language required string: Target language code

Output

getStyleGuides

Get a list of style guides

motaword.getStyleGuides({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • with[] array: Attach further information. Possible values 'preview' to fetch temporary preview URLs for Box.com or native PDF. This is NOT recommended to be used with list calls. Only use with[]=preview for single document/style guide calls.

Output

createStyleGuide

Upload a new style guide

motaword.createStyleGuide({
  "projectId": 0,
  "styleguides[]": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • styleguides[] required string: You can add as many files as you want in styleguides[] parameter.

Output

deleteStyleGuide

Delete the style guide

motaword.deleteStyleGuide({
  "projectId": 0,
  "styleGuideId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • styleGuideId required integer: Style Guide ID

Output

getStyleGuide

Get single style guide

motaword.getStyleGuide({
  "projectId": 0,
  "styleGuideId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • styleGuideId required integer: Style Guide ID
    • with[] array: Attach further information. Possible values 'preview' to fetch temporary preview URLs for Box.com or native PDF. This is NOT recommended to be used with list calls. Only use with[]=preview for single document/style guide calls.

Output

updateStyleGuide

Update the style guide. File name and contents will replaced with the new one.

motaword.updateStyleGuide({
  "projectId": 0,
  "styleGuideId": 0,
  "styleguides": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • styleGuideId required integer: Style guide ID
    • styleguides required string: Single file data. The name is plural to provide a consistent naming convention.

Output

downloadStyleGuide

Download a style guide

motaword.downloadStyleGuide({
  "projectId": 0,
  "styleGuideId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • styleGuideId required integer: Style Guide ID

Output

  • output string

getProjectTranslations

Deprecated. Use /projects/{projectId}/strings instead.

motaword.getProjectTranslations({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID

Output

getProjectTranslationsForLanguage

Deprecated. use /projects/{projectId}/strings/{language} instead.

motaword.getProjectTranslationsForLanguage({
  "projectId": 0,
  "language": ""
}, context)

Input

  • input object
    • projectId required integer: Project ID
    • language required string: Target language code

Output

getProjectVendors

Get a list of vendors.

motaword.getProjectVendors({
  "projectId": 0
}, context)

Input

  • input object
    • projectId required integer: Project ID

Output

getLanguagePairsReport

Returns a report of language pairs.

motaword.getLanguagePairsReport({}, context)

Input

Output

getProjectsReport

Returns a report of corporate account users.

motaword.getProjectsReport({}, context)

Input

Output

getUsersReport

Returns a report of corporate account users.

motaword.getUsersReport({}, context)

Input

Output

sendEmailConfirmation

Sends email confirmation email for current user

motaword.sendEmailConfirmation(null, context)

Input

This action has no parameters

Output

getResponsivity

Returns your vendor responsivity stats

motaword.getResponsivity({}, context)

Input

  • input object
    • period string (values: monthly, weekly): Period for calcualtion.

Output

searchEverywhere

Search everywhere! Including projects, documents, translations...

motaword.searchEverywhere({
  "query": ""
}, context)

Input

  • input object
    • query required string: Search query term
    • include[] array: Search in these entities. Current oprions are projects, documents, strings. Can be multiple. When not provided, we'll search through all entities.
    • page integer
    • per_page integer

Output

reindexDocuments

Reindex for search all of the client source and translation documents.

motaword.reindexDocuments(null, context)

Input

This action has no parameters

Output

checkDocumentsReindex

Check reindex status of the client source and translation documents.

motaword.checkDocumentsReindex({
  "async_request_key": ""
}, context)

Input

  • input object
    • async_request_key required string: Async operation key

Output

getStats

Returns your client and vendor statistics. This used to be called "summary" (\@deprecated).

motaword.getStats(null, context)

Input

This action has no parameters

Output

getCommissionStats

Returns the total commissions stats.

motaword.getCommissionStats(null, context)

Input

This action has no parameters

Output

getCommissionStatsByFilter

Returns the total commissions stats by report filter.

motaword.getCommissionStatsByFilter({}, context)

Input

Output

getPopularPairs

Returns the language pairs that you have ordered most.

motaword.getPopularPairs(null, context)

Input

This action has no parameters

Output

getProjectStats

Returns your project statistics.

motaword.getProjectStats(null, context)

Input

This action has no parameters

Output

getStringStats

Returns your string statistics.

motaword.getStringStats(null, context)

Input

This action has no parameters

Output

getStrings

Get a list of client/corporate strings (20 per page)

motaword.getStrings({}, context)

Input

  • input object
    • source_language string: Source Language Code
    • page integer: Requested page

Output

postStrings

Translate Strings with MT

motaword.postStrings({}, context)

Input

  • input object
    • body object
      • contents array
        • items string
      • source_language string
      • target_languages array
        • items string

Output

packageUserTranslationMemory

Get the translation memory of a client or corporate in TMX format

motaword.packageUserTranslationMemory({
  "languageCode": ""
}, context)

Input

  • input object
    • languageCode required string: Source Language Code
    • async integer: If you want to package and download the translation memory synchronously, mark this parameter as '0'. It will package the translation memory and then return the packaged file in the response, identical to async/download call after an asynchronous /package call.
    • email integer: If you don't need us to email the TMX, set this to '0'. Default is 1.

Output

packageUserTranslationMemoryForLanguageStatus

If package call was async, check the status of the request

motaword.packageUserTranslationMemoryForLanguageStatus({
  "languageCode": "",
  "async_request_key": ""
}, context)

Input

  • input object
    • languageCode required string: Language Code
    • async_request_key required string: Async operation key

Output

downloadGlobalStyleGuide

Download your corporate account's global style guide. This endpoint is available only for corporate account customers.

motaword.downloadGlobalStyleGuide(null, context)

Input

This action has no parameters

Output

  • output string

updateGlobalStyleGuide

Update your corporate account's global style guide. This endpoint is available only for corporate account customers.

motaword.updateGlobalStyleGuide({
  "styleguide": ""
}, context)

Input

  • input object
    • styleguide required string: Style guide file. Currently supported formats: .pdf, .docx, .txt

Output

getSwaggerJson

Get Swagger JSON

motaword.getSwaggerJson(null, context)

Input

This action has no parameters

Output

  • output object

getAccessToken

MotaWord API is using OAuth2 procedures when authenticating or authorizing your API call. Currently, we only allow Client Credential type flow.

motaword.getAccessToken({
  "grant_type": "",
  "scope": ""
}, context)

Input

  • input object
    • grant_type required string: OAuth2 grant type. Supports 'client_credentials', 'password' or 'refresh_token', 'user_id' available.
    • password string: MW Account password (to be used in password grant type)
    • refresh_token string: Refresh token value for refresh token flow.
    • scope required string: Authorization scope. Use 'privileged' for private endpoints.
    • user_id integer: Value for user_id grant type flow.
    • username string: MW Account email (to be used in password grant type)

Output

unfreezeAccount

Unfreeze requester account for project notifications

motaword.unfreezeAccount(null, context)

Input

This action has no parameters

Output

getUsers

Get a list of platform users

motaword.getUsers({}, context)

Input

  • input object
    • page integer
    • per_page integer
    • user_type string (values: vendor, all)

Output

sendPasswordReminder

Sends password reset email to the user's registered email address

motaword.sendPasswordReminder({}, context)

Input

Output

getUser

Get user information, including client or vendor specific info.

motaword.getUser({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

updateUser

motaword.updateUser({
  "userId": 0
}, context)

Input

Output

approveVendorApplication

motaword.approveVendorApplication({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

deleteUserAccount

Delete requester account

motaword.deleteUserAccount({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

getUserDocuments

Get a list of your documents

motaword.getUserDocuments({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID
    • recent boolean: When true, this will return the most 4 recent active documents.
    • search string
    • type_filter string (values: ALL, TEXT_DOCUMENTS, PRESENTATIONS, SPREADSHEETS, PDFS, IMAGES, SUBTITLES, DESIGNS, LOCALIZATION, WEB, STYLE_GUIDES, GLOSSARIES)
    • language_code string: searches in source language of documents, in source and target languages of document's quote
    • page integer
    • per_page integer
    • order_by string (values: id, updated_at, created_at, name)
    • order_type string (values: asc, desc)

Output

downgradeUserProofreader

motaword.downgradeUserProofreader({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

getUserEarnings

Returns your vendor earnings. Includes real-time earnings from ongoing projects, and fixed earnings from completed projects. Also includes total earnings and string edits.

motaword.getUserEarnings({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

freezeUserAccount

Freeze requester account for project notifications

motaword.freezeUserAccount({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

makeUserProofreader

motaword.makeUserProofreader({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

subscribeUserNotification

motaword.subscribeUserNotification({
  "userId": 0
}, context)

Input

Output

unsubscribeUserNotification

motaword.unsubscribeUserNotification({
  "userId": 0
}, context)

Input

Output

getUserPaymentInfo

Get user payment Info

motaword.getUserPaymentInfo({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

updateUserPaymentInfo

Update user payment info

motaword.updateUserPaymentInfo({
  "userId": 0
}, context)

Input

  • input object

Output

uploadUserProfilePicture

motaword.uploadUserProfilePicture({
  "userId": 0,
  "profile_picture": ""
}, context)

Input

  • input object
    • userId required integer: User ID
    • profile_picture required string: Profile picture file contents. Accepted extensions are png, jpg.

Output

rejectVendorApplication

motaword.rejectVendorApplication({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

sendUserEmailConfirmation

Sends email confirmation email for a user

motaword.sendUserEmailConfirmation({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

getUserResponsivity

Returns a user's vendor responsivity stats

motaword.getUserResponsivity({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID
    • period string (values: monthly, weekly): Period for calcualtion.

Output

getUserStats

Returns a user's client and vendor statistics. This used to be called "summary" (\@deprecated).

motaword.getUserStats({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

getUserPopularPairs

Returns the language pairs that the user has ordered most.

motaword.getUserPopularPairs({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

getUserProjectStats

Returns a user's project statistics.

motaword.getUserProjectStats({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

suspendUser

motaword.suspendUser({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID
    • body object
      • reason string: Suspension reason for vendor

Output

unfreezeUserAccount

Unfreeze requester account for project notifications

motaword.unfreezeUserAccount({
  "userId": 0
}, context)

Input

  • input object
    • userId required integer: User ID

Output

Definitions

Activity

  • Activity object
    • activity_at integer: Unix epoch time
    • id integer
    • links ActivityLinks
    • source_text string: Source text
    • target_text string: Target text of the activity, which is actually the translation of the source text.
    • translator integer: Unique identifier of the translator/proofreader of this activity.
    • type string (values: translated, proofread): Currently there are two available activity types; 'translated', 'proofread'.

ActivityLinks

ActivityList

Address

  • Address object
    • city string
    • country string
    • state string
    • street string
    • zip string

AsyncOperationStatus

  • AsyncOperationStatus object

AsyncOperationStatusEnum

  • AsyncOperationStatusEnum string (values: sent, started, completed, failed)

BillingAddress

  • BillingAddress
    • city string
    • country string
    • state string
    • street string
    • zip string
    • name string: addressing name, such as company name. used in billing address.

BlogArticle

  • BlogArticle object
    • announcement_type string (values: article, case, famous-translators, sales)
    • author string
    • content string: Article content
    • created_at string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • excerpt string: Article excerpt
    • id integer
    • language string: language code
    • links BlogArticleLinks
    • slug string
    • title string
    • topic string

BlogArticleLinks

BlogArticleList

CallbackResult

  • CallbackResult object
    • data Project
    • result string: Callback response returned from url.
    • type ProjectStatus
    • url string: The URL that received the callback.

ClientProjectStat

  • ClientProjectStat object
    • languages array
      • items string
    • month string
    • number_of_projects integer
    • total_spending number
    • week string

ClientProjectStats

ClientStats

  • ClientStats object
    • document_count integer
    • nps number
    • started_project_count integer
    • total_discounted Monetary
    • total_project_count integer
    • total_spending number
    • translator_count integer

ClientStringStats

  • ClientStringStats object
    • language_counts array
    • total_project_strings_count integer
    • total_tm_strings_count integer

ClientStringTranslation

  • ClientStringTranslation object
    • content string
    • last_changed string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • resource string
    • resource_id string
    • state string (values: Translated, Approved)
    • target_language string

ClientStringWithTranslations

  • ClientStringWithTranslations object
    • content string
    • language string
    • last_changed string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • translations array

ClientStrings

Comment

  • Comment object
    • comment string: Comment text.
    • commented_at integer: Unix epoch time
    • id integer
    • links CommentLinks

CommentLinks

CommentList

Commission

  • Commission object
    • amount Monetary
    • date string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • project Project
    • status string (values: completed, unclaimed, failed, sent, waiting, waiting_invoice)

CommissionList

CommissionStats

CreditCard

  • CreditCard object
    • bin string
    • id integer

Document

  • Document object
    • file_type string: Extension of the file
    • id integer
    • links DocumentLinks
    • manual_files ManualFiles
    • name string
    • review_in_manual_editor boolean
    • scheme object
    • source_language string
    • subject string
    • target_languages array
      • items string
    • uploaded_at integer: Unix epoch time
    • word_count integer

DocumentInSearch

  • DocumentInSearch
    • file_type string: Extension of the file
    • id integer
    • links DocumentLinks
    • manual_files ManualFiles
    • name string
    • review_in_manual_editor boolean
    • scheme object
    • source_language string
    • subject string
    • target_languages array
      • items string
    • uploaded_at integer: Unix epoch time
    • word_count integer
    • search_result_reason string

DocumentLinks

  • DocumentLinks

DocumentList

Earning

  • Earning object
    • amount number
    • currency string
    • due_date string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • status string (values: paid, pending, failed)
    • words integer
    • words_approved integer
    • words_translated integer

EarningWithTQS

  • EarningWithTQS
    • amount number
    • currency string
    • due_date string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • status string (values: paid, pending, failed)
    • words integer
    • words_approved integer
    • words_translated integer
    • is_above_average boolean: Is this score above or below the average among other vendors in the same project?
    • score number
    • strings_edited integer: The number of translated strings by this translator which was edited by a proofreader.
    • strings_translated integer: The number of translated strings by this translator.
    • project_id integer

Earnings

Email

  • Email object
    • email string

Error

  • Error object
    • code string
    • help string
    • http_code integer
    • message string

Formats

  • Formats object
    • documents object
      • extensions array
        • items string
      • mimes array
        • items string
    • glossaries object
      • extensions array
        • items string
    • styleguides object
      • extensions array
        • items string

Glossary

  • Glossary object
    • id integer
    • links DocumentLinks
    • name string
    • uploaded_at integer: Unix epoch time

GlossaryList

Href

  • Href object
    • href string

Invoice

  • Invoice object
    • amount number: Monetary amount
    • billing BillingAddress
    • currency string
    • id integer
    • invoice_no integer
    • invoiced_at string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • links InvoiceLinks
    • status string

InvoiceLinks

Language

  • Language object
    • code string
    • name string

LanguagePair

  • LanguagePair object
    • source_language string
    • target_language string

LanguagePairsReport

  • LanguagePairsReport object
    • meta PagingMeta
    • report array
      • items object
        • language_pair object
          • source_language string
          • target_language string
        • spending number
        • word_count integer

LanguageScore

  • LanguageScore number

LanguageStringStat

  • LanguageStringStat object
    • project_string_count integer
    • source_language string
    • tm_string_count integer

LinkedSourceDocument

  • LinkedSourceDocument object
    • name string
    • size integer: file size in bytes. optional.
    • source string (values: dropbox, googledrive, icloud): Preferred source names are listed as enum. If you have a custom file type, simply enter that name.
    • url string

LinksMeta

  • LinksMeta object

ListOrderType

  • ListOrderType string (values: asc, desc)

LocationUpdateContent

  • LocationUpdateContent object
    • lat required number: Latitude of location
    • lon required number: Longitude of location
    • timestamp integer

MachineTranslatedStrings

ManualFile

  • ManualFile object
    • driveFileId integer
    • isProofread boolean
    • isTranslated boolean
    • language string
    • proofreadingFileId integer
    • translationFileId integer

ManualFiles

Monetary

  • Monetary object
    • amount number
    • currency string

NotificationSubscription

  • NotificationSubscription object
    • device string (values: iOS, Android, Chrome, Firefox, Safari, Edge, Amazon, WindowsPhone, Windows, MacOS)
    • endpoint string: OneSignal calls this "player ID".
    • type string (values: OneSignal)

OperationStatus

OperationStatusEnum

  • OperationStatusEnum string (values: success, error)

Package

  • Package
    • status PackageStatusEnum
    • key string: This is the unique package tracking key. You can use this key to track the current progress of the translation packaging with /package/check call.

PackageStatus

PackageStatusEnum

  • PackageStatusEnum string (values: started, packaging, completed): The status of translation packaging. Possible values are 'started', 'packaging', 'completed'. When completed, you can make a /download call to download the last translation package.

PagingLinksMeta

  • PagingLinksMeta
    • self Href
    • next string
    • previous string

PagingMeta

  • PagingMeta object
    • paging object

PasswordUpdateContent

  • PasswordUpdateContent object
    • password string: New Password

PaymentInfo

PopularLanguagePairs

Progress

ProgressLink

ProgressSub

  • ProgressSub object
    • proofreading number
    • total number
    • translation number

Project

  • Project object
    • average_scores object
    • budget_code string
    • callback_url string: Callback URL to notify when project status changed.
    • client User
    • completed_on string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • created_at integer: Unix epoch time
    • custom object: Custom data provided while creating a new project.
    • delivery_at integer: Unix epoch time
    • errors array: A list of errors. Visible when creating a project and uploading your documents at the same time, in case of multiple errors.
    • id integer
    • is_manual boolean
    • links ProjectLinks
    • pairs VendorProjectPairs
    • price object
      • amount number
      • currency string
      • usd_amount number: USD is our base pricing currency. If currency is different, this will help.
    • price_without_discount object
      • amount number
      • currency string
      • usd_amount number: USD is our base pricing currency. If currency is different, this will help.
    • role VendorProjectRole
    • source ProjectSource
    • source_language string
    • status ProjectStatus
    • subjects array
      • items string
    • target_languages array
      • items string
    • tms_name string: TMS project name for this MW project. Requires privileged scope.
    • valid_until integer: Unix epoch time. Available only if status is pending.
    • vendor_word_count integer
    • word_count integer

ProjectInSearch

  • ProjectInSearch
    • average_scores object
    • budget_code string
    • callback_url string: Callback URL to notify when project status changed.
    • client User
    • completed_on string: the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
    • created_at integer: Unix epoch time
    • custom object: Custom data provided while creating a new project.
    • delivery_at integer: Unix epoch time
    • errors array: A list of errors. Visible when creating a project and uploading your documents at the same time, in case of multiple errors.
6.0.0

5 years ago

5.0.0

7 years ago

4.0.0

7 years ago

3.0.0

8 years ago

2.0.3

8 years ago

2.0.2

8 years ago

2.0.1

8 years ago

2.0.0

8 years ago

0.0.3

9 years ago

0.0.1

9 years ago