crowdin-client

Crowdin HTTP client for node.js

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
crowdin-client
010.1.54 years ago7 years agoMinified + gzip package size for crowdin-client in KB

Readme

Crowdin Client
npm version Build Status
Subset of Crowdin HTTP API.

Upload branched translations

import Crowdin from 'crowdin-client';

const crowdin = new Crowdin({
  accountKey: 'YOUR_KEY',
  login: 'YOUR_USERNAME',
  project: 'YOUR_PROJECT',
});

const promise = crowdin.createOrUpdateVersionedFile(
  'master',
  'my_project.pot',
  '/path/to/my_project.pot',
  'template/for/generated/po/%two_letters_code%.po',
);

Download branched translations

import Crowdin from 'crowdin-client';

const crowdin = new Crowdin({
  accountKey: 'YOUR_KEY',
  login: 'YOUR_USERNAME',
  project: 'YOUR_PROJECT',
});

crowdin.downloadTranslations('all', 'master').then(buffer => {
  // there is your buffer with zipped translations
});