لوكلاء AI: ملف markdown لهذه الصفحة — /docs-content-en/entities/currencies/localizations/get.md فهرس التوثيق — /llms.txt

مقالات التوثيق متاحة حاليًا باللغة الإنجليزية فقط.

Get currency localizations

GET /v1/currencies/:id/localizations

Reads the currency names and amount display settings per language. Call the method before changing localizations and after a failed write.

Scope: crm. A key in READONLY mode is accepted.

Parameters

Parameter Type Required Default Description
Parameterid (path) Typestring Requiredyes Default— DescriptionCurrency code from the currency list. Leading and trailing spaces are stripped, letters are uppercased

Examples

curl — personal key

Terminal
curl "https://vibecode.bitrix24.com/v1/currencies/QVC/localizations" \
  -H "X-Api-Key: YOUR_API_KEY"

curl — OAuth application

Terminal
curl "https://vibecode.bitrix24.com/v1/currencies/QVC/localizations" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/currencies/QVC/localizations', {
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
  },
})
const { success, data } = await res.json()

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/currencies/QVC/localizations', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})
const { success, data } = await res.json()

Response fields

Field Type Description
Fieldsuccess Typeboolean DescriptionAlways true on success
Fielddata Typeobject DescriptionMap of localizations keyed by language code. If there are no localizations, an empty object {}
Fielddata.{lang} Typeobject DescriptionSettings for the {lang} language, for example en or ru
Fielddata.{lang}.fullName Typestring DescriptionFull currency name
Fielddata.{lang}.formatString Typestring DescriptionAmount display template, # is the placeholder for the number
Fielddata.{lang}.decPoint Typestring DescriptionDecimal separator
Fielddata.{lang}.thousandsVariant Typestring DescriptionThousands separator variant
Fielddata.{lang}.thousandsSep Typestring | null DescriptionThousands separator character or HTML entity
Fielddata.{lang}.decimals Typenumber DescriptionNumber of digits after the decimal separator
Fielddata.{lang}.hideZero Typeboolean DescriptionHide trailing zeros in the fractional part

Response example

JSON
{
  "success": true,
  "data": {
    "en": {
      "fullName": "Example currency",
      "formatString": "# QVC",
      "decPoint": ".",
      "thousandsVariant": "S",
      "thousandsSep": " ",
      "decimals": 2,
      "hideZero": false
    },
    "ru": {
      "fullName": "Example currency",
      "formatString": "# QVC",
      "decPoint": ".",
      "thousandsVariant": "S",
      "thousandsSep": " ",
      "decimals": 2,
      "hideZero": false
    }
  }
}

Error response example

404 — a currency with the specified code is not found:

JSON
{
  "success": false,
  "error": {
    "code": "ENTITY_NOT_FOUND",
    "message": "Not found"
  }
}

Errors

HTTP Code Description
HTTP400 CodeINVALID_ID DescriptionThe currency code is empty after the spaces are stripped
HTTP404 CodeENTITY_NOT_FOUND DescriptionA currency with the specified code is not found
HTTP422 CodeBITRIX_ERROR DescriptionBitrix24 rejected reading the currency or its localizations
HTTP403 CodeBITRIX_ACCESS_DENIED DescriptionThe user has no rights for the operation in Bitrix24
HTTP403 CodeSCOPE_DENIED DescriptionThe API key does not have the crm scope
HTTP401 CodeMISSING_API_KEY DescriptionThe X-Api-Key header is missing
HTTP401 CodeTOKEN_MISSING DescriptionThe API key has no configured Bitrix24 tokens
HTTP502 CodeBITRIX_RESPONSE_INVALID DescriptionA response of an unexpected structure was received
HTTP502 CodeBITRIX_UNAVAILABLE DescriptionBitrix24 is unavailable

Full list of common API errors — Errors.

Known specifics

HTML entities in the format and separator strings are preserved as is, for example  .

See also