Project locales Resource

REST interface for configured project locales.

See Also
Version Locales Version locales

GET /projects/p/{projectSlug}/locales

Returns list of active locales for a single project. This may be the list of locales inherited from the server.

Response Codes
code condition
200 Content contains a list of locale details
404 The project is not found
Response Body
media type data type description
application/json array of Locale Details (JSON) OK 200 containing the list of LocaleDetails NOT FOUND 404 if the project does not exist
application/vnd.zanata.project.locales+json array of Locale Details (JSON)
application/vnd.zanata.project.locales+xml list of Locale Details (XML)
application/xml list of Locale Details (XML)

Example

Request
GET /projects/p/{projectSlug}/locales
Accept: application/json

              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
[ {
  "localeId" : "es-ES",
  "displayName" : "Spanish (Spain)",
  "alias" : "es",
  "nativeName" : "Español",
  "enabled" : true,
  "enabledByDefault" : true,
  "pluralForms" : "nplurals=2; plural=(n != 1)",
  "rtl" : true
} ]
                
              
See Also
Version Locales Version locales

GET /projects/p/{projectSlug}/locales/source

Returns list of active source locales of all documents for a single project.

Response Codes
code condition
200 Content contains a list of source locale details
404 The project is not found
Response Body
media type data type description
application/json array of SourceLocaleDetails (JSON) OK 200 containing the list of SourceLocaleDetails NOT FOUND 404 if the project does not exist

Example

Request
GET /projects/p/{projectSlug}/locales/source
Accept: application/json

              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
[ {
  "docCount" : 12345,
  "localeDetails" : {
    "localeId" : "es-ES",
    "displayName" : "Spanish (Spain)",
    "alias" : "es",
    "nativeName" : "Español",
    "enabled" : true,
    "enabledByDefault" : true,
    "pluralForms" : "nplurals=2; plural=(n != 1)",
    "rtl" : true
  }
} ]