Project Details

Get Crowdin Project details.

Request

POST https://api.crowdin.com/api/project/{project-identifier}/info?key={project-key}

Parameters

Name Value Description
xml optional string May not contain value. Defines that response should be in XML format.
json optional string May not contain value. Defines that response should be in JSON format.
jsonp optional string Callback function name. Defines that response should be in JSONP format.
Variables
project-identifier required string Should contain the project identifier.
project-key required string Project API key.

Response

If successful, this method returns a XML structure, as it is shown below.
<?xml version="1.0" encoding="ISO-8859-1"?>
<info>
  <languages> <!-- all project languages -->
    <item>
    <name>French</name>
    <code>fr</code>
    </item>
    <item>
    <name>Spanish</name>
    <code>es-ES</code>
    </item>
  </languages>
  <files> <!-- project files details -->
    <item>
    <node_type>directory</node_type>
    <id>1</id>
    <name>test</name>
    <files>
      <item>
        <node_type>file</node_type>
        <id>2</id>
        <name>market-info.txt</name>
        <created>2013-05-19 16:08:13</created>
        <last_updated>2013-05-20 21:02:13</last_updated>
        <last_accessed>2013-05-21 12:10:48</last_accessed>
        <last_revision>1</last_revision>
      </item>
      <item>
        <node_type>file</node_type>
        <id>3</id>
        <name>strings.xml</name>
        <created>2013-05-19 16:38:15</created>
        <last_updated>2013-05-20 21:42:11</last_updated>
        <last_accessed>0000-00-00 00:00:00</last_accessed>
        <last_revision>1</last_revision>
      </item>
    </files>
    </item>
    <item>
      <node_type>file</node_type>
      <id>4</id>
      <name>strings.xml</name>
      <created>2013-05-19 16:40:09</created>
      <last_updated>2013-05-21 09:31:48</last_updated>
      <last_accessed>2013-05-21 10:21:01</last_accessed>
      <last_revision>1</last_revision>
    </item>
  </files>
  <details> <!-- project details -->
    <source_language>
      <name>English</name>
      <code>en</code>
    </source_language>
    <name>test-project</name>
    <identifier>test-project</identifier>
    <created>2013-05-19 16:40:52</created>
    <description>project description</description>
    <join_policy>open</join_policy>
    <last_build>2013-05-20 23:01:18</last_build>
    <last_activity>2013-05-21 12:10:48</last_activity>
    <total_strings_count>438</total_strings_count>
    <total_words_count>4238</total_words_count>
    <duplicate_strings_count>228</duplicate_strings_count>
    <duplicate_words_count>2249</duplicate_words_count>
    <participants_count>4</participants_count>
    <invite_url>
      <item>
        <language>Ukrainian</language>
        <translator>
          https://crowdin.com/project/test-project/invite?d=d5l6k4h685v6p483v6q4r44303
        </translator>
        <proofreader>
          https://crowdin.com/project/test-project/invite?d=95l625i6r4v6p483v6q4r44303
        </proofreader>
      </item>
    </invite_url>
  </details>
</info>

Note!

last_updated field indicates last update of the file and last_accessed indicates last activity in the file (e. g. submitting a suggestion). If there were no activities such as last_build, last_activity or last_updated, the dates is shown in following format 0000-00-00 00:00:00.
If the language access policy is "Open" the invite URL section will look like the following:
<?xml version="1.0" encoding="ISO-8859-1"?>
<invite_url>
  <translator>
    https://crowdin.com/project/test-project/invite
  </translator>
  <proofreader>
    https://crowdin.com/project/test-project/invite?d=95l625i6r4v6p483v6q4r44303
  </proofreader>
</invite_url>
Unsuccessful response sample:
<?xml version="1.0" encoding="ISO-8859-1"?>
<error>
  <code>3</code>
  <message>API key is not valid</message>
</error>

Examples

curl https://api.crowdin.com/api/project/{project-identifier}/info?key={project-key}&jsonp=mycallback
<?php
$request_url = 'https://api.crowdin.com/api/project/{project-identifier}/info?key={project-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;