-
Notifications
You must be signed in to change notification settings - Fork 8
Localisation
The Localisation API allows you to receive translated text resources that Huddle uses within its own applications.
Please note that JSON and JSONP (MediaType#JSONP_support) are currently the only return types for all of the endpoints of this API. Also you do not require a OAuth2 token.
You can retrieve the cultures that currently have translations.
GET /localisation/cultures HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"fr":"/localisation/cultures/fr/categories",
"en-gb":"/localisation/cultures/en-gb/categories
}
You can retrieve all of the categories.
GET /localisation/cultures/categories HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"categories":
[
{
"links":
[
{"rel":"self","href":"/localisation/categories/filesappdetails"}
],
"id":"filesappdetails"
}
]
}
You can retrieve all of the categories for a culture.
GET /localisation/cultures/en-gb/categories HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"categories":
[
{
"links":
[
{"rel":"self","href":"/localisation/cultures/en-gb/categories/filesappdetails"}
],
"id":"filesappdetails"
}
]
}
You can retrieve a category's resources in multiple languages. The language code must be a valid ISO language code (please see Language codes).
The Localisation API supports requests for cultures it does not yet have translations for. If this is the case, you will be returned "en-gb" resources.
Note that Localisation API currently supports the current formats only:
- 2 letter code e.g. fr (French)
- 3 letter code e.g. syr (Syriac)
- 2 letter code with 2 letter sub culture e.g. en-gb (English United Kingdom)
- 3 letter code with 2 letter sub culture e.g. gsw-fr (Alsatian France)
There are two different end points for retrieving resources. One where you can specify the language code in the URL and another one where you can specify it in the Accept-Language header
GET /localisation/cultures/en-gb/categories/filesappdetails HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"category": "filesappdetails",
"resources": {
"a_resource":"Hello",
"go_button":"Go"
}
}
GET /localisation/cultures/fr/categories/filesappdetails HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"category": "filesappdetails",
"resources": {
"a_resource":"Bonjour",
"go_button":"Aller"
}
}
GET /localisation/cultures/categories/filesappdetails HTTP/1.1
Accept-Language: en-gb
HTTP/1.1 200 OK
Content-Type: application/json
{
"category": "filesappdetails",
"resources": {
"a_resource":"Hello",
"go_button":"Go"
}
}
- Basic concepts
-
Resources
- Actor
- Approvals
- BulkProcess
- Calendar
- Membership
- Company
- Document
- Document library settings
- Folder
- Paged Folder
- Pins
- Integrations
- Form
- Friends
- Invitation
- Link
- Document Lock
- Folder Lock
- Localisation
- MemberAutocomplete
- Notifications
- Offline item
- PeopleBulkProcess
- Permissions
- Presence
- PublishedDocuments
- Recents
- Recommendations
- Recycle Bin
- Search
- Share
- Tasks (Todos), File Requests, Approvals
- Tasks on Documents
- Actions
- UserApprovals
- User
- VersionHistory
- Workspace
- Workspaces
- SamlPartners
- Logout
- Impersonation
- Administration
- WebHooks