Stato della traduzione

Track overall translation and proofreading progresses of each target language. Default response format is XML.

Richiesta

Note: Use the combination of project identifier, username, and account key to pass to this endpoint.

POST https://api.crowdin.com/api/project/{project-identifier}/status?login={username}&account-key={account-key}

Parametri

Nome Valore Descrizione
languages optional insieme Track overall translation and proofreading progresses for defined target languages. For this use Сrowdin language codes.
xml optional nella stringa Potrebbe non contenere alcun valore. Defines that response should be in XML format.
json opzionale nella stringa Potrebbe non contenere alcun valore. Definisce che la risposta dovrebbe essere in formato JSON.
jsonp opzionale nella stringa Nome della funzione di callback. Definisce che la risposta dovrebbe essere in formato JSONP.
Variabili
identificatore-progetto nella stringa Identificatore progetto.
accesso nella stringa Il tuo nome utente su Crowdin.
chiave-profilo nella stringa La chiave API del tuo profilo.

Risposta

If successful, this method returns a XML structure, as it is shown below.
<?xml version="1.0" encoding="UTF-8"?>
<status>
  <language>
    <name>French</name>
    <code>fr</code>
    <phrases>20</phrases>
    <translated>10</translated>
    <approved>5</approved>
    <words>50</words>
    <words_translated>35</words_translated>
    <words_approved>15</words_approved>
    <translated_progress>50</translated_progress>
    <approved_progress>25</approved_progress>
  </language>
  <language>
    <name>Rumeno</name>
    <code>ro</code>
    <phrases>20</phrases>
    <translated>0</translated>
    <approved>0</approved>
    <words>50</words>
    <words_translated>35</words_translated>
    <words_approved>15</words_approved>
    <translated_progress>0</translated_progress>
    <approved_progress>0</approved_progress>
  </language>
  <!-- ............each project language............-->
</status>
If QA checks is enabled, this method returns the following XML structure:
<?xml version="1.0" encoding="UTF-8"?>
<status>
  <language>
    <name>French</name>
    <code>fr</code>
    <phrases>20</phrases>
    <translated>10</translated>
    <approved>5</approved>
    <words>50</words>
    <words_translated>35</words_translated>
    <words_approved>15</words_approved>
    <translated_progress>50</translated_progress>
    <approved_progress>25</approved_progress>
    <qa_issues>10</qa_issues>
  </language>
  <!-- ............each project language............-->
</status>
Campione di risposta non riuscita:
<?xml version="1.0" encoding="UTF-8"?>
<error>
  <code>3</code>
  <message>Chiave API non valida</message>
</error>

Esempi

curl https://api.crowdin.com/api/project/{project-identifier}/status?login={username}&account-key={account-key}&jsonp=mycallback
<?php
$request_url = 'https://api.crowdin.com/api/project/{project-identifier}/status?login={username}&account-key={account-key}&xml';

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $request_url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);

$result = curl_exec($ch);
curl_close($ch);

echo $result;

Questo articolo è stato utile?