Skip to content

Commit 192816a

Browse files
chore(developer): update API docs (#804)
1 parent 52b5236 commit 192816a

4 files changed

Lines changed: 432 additions & 24 deletions

File tree

src/assets/api/crowdin/file-based.yml

Lines changed: 105 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21403,21 +21403,31 @@ components:
2140321403
type: string
2140421404
enum:
2140521405
- replace
21406+
- remove
2140621407
- test
2140721408
path:
21408-
description: 'A JSON Pointer as defined by <a href="https://tools.ietf.org/html/rfc6901" target="_blank">RFC 6901</a>'
21409+
description: 'A JSON Pointer as defined by <a href="https://tools.ietf.org/html/rfc6901" target="_blank">RFC 6901</a>. The `/perUserOverrides/{userId}` and `/perUserOverrides/{userId}/*` paths accept any positive integer for `{userId}`. Creating a new override requires `{userId}` to be a project member; this requirement does not apply when editing or removing an existing one. The `remove` operation is supported for the `/perUserOverrides/{userId}` path (removes the entire per-user override) and for `/perUserOverrides/{userId}/*` field paths (removes that field; the resulting override is re-validated).'
2140921410
type: string
2141021411
format: json-pointer
2141121412
enum:
2141221413
- /preTranslationAiPromptId
2141321414
- /editorSuggestionAiPromptId
2141421415
- /qaCheckActionAiPromptId
2141521416
- /contextReviewAiPromptId
21417+
- /dailyCostLimit
21418+
- /monthlyCostLimit
21419+
- /userDailyCostLimit
21420+
- /userMonthlyCostLimit
21421+
- '/perUserOverrides/{userId}'
21422+
- '/perUserOverrides/{userId}/costLimitMode'
21423+
- '/perUserOverrides/{userId}/dailyCostLimit'
21424+
- '/perUserOverrides/{userId}/monthlyCostLimit'
2141621425
type: object
2141721426
discriminator:
2141821427
propertyName: op
2141921428
mapping:
2142021429
replace: '#/components/schemas/AiSettingsOperationReplace'
21430+
remove: '#/components/schemas/AiSettingsOperationRemove'
2142121431
test: '#/components/schemas/AiSettingsOperationTest'
2142221432
AiSettingsOperationReplace:
2142321433
description: 'A JSON Patch `Replace` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.3)'
@@ -21433,8 +21443,21 @@ components:
2143321443
oneOf:
2143421444
-
2143521445
type: integer
21446+
-
21447+
type: number
21448+
format: float
21449+
-
21450+
type: string
21451+
-
21452+
nullable: true
21453+
AiSettingsOperationRemove:
21454+
description: 'A JSON Patch `Remove` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.2). Supported for the `/perUserOverrides/{userId}` path (removes the entire per-user override) and `/perUserOverrides/{userId}/*` field paths (removes that field). The `costLimitMode` field cannot be removed as the override always requires it.'
21455+
type: object
21456+
allOf:
21457+
-
21458+
$ref: '#/components/schemas/AiSettingsOperation'
2143621459
AiSettingsOperationTest:
21437-
description: 'A JSON Patch `Replace` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.3)'
21460+
description: 'A JSON Patch `Test` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.6)'
2143821461
required:
2143921462
- value
2144021463
type: object
@@ -21447,6 +21470,13 @@ components:
2144721470
oneOf:
2144821471
-
2144921472
type: integer
21473+
-
21474+
type: number
21475+
format: float
21476+
-
21477+
type: string
21478+
-
21479+
nullable: true
2145021480
CrowdinAiSettingsResource:
2145121481
description: 'AI Settings Resource'
2145221482
type: object
@@ -21457,7 +21487,7 @@ components:
2145721487
properties:
2145821488
data:
2145921489
$ref: '#/components/schemas/CrowdinAiSettings'
21460-
CrowdinAiSettings:
21490+
AiSettings:
2146121491
title: 'AI Settings'
2146221492
properties:
2146321493
preTranslationAiPromptId:
@@ -21474,7 +21504,78 @@ components:
2147421504
type: integer
2147521505
example: 11
2147621506
nullable: true
21507+
dailyCostLimit:
21508+
description: 'Maximum total AI cost the organization can spend per day. `null` means no daily limit.'
21509+
type: number
21510+
format: float
21511+
example: 100
21512+
nullable: true
21513+
monthlyCostLimit:
21514+
description: 'Maximum total AI cost the organization can spend per month. `null` means no monthly limit.'
21515+
type: number
21516+
format: float
21517+
example: 2000
21518+
nullable: true
21519+
userDailyCostLimit:
21520+
description: 'Default maximum AI cost a single user can spend per day. Applies to every user unless overridden in `perUserOverrides`. `null` means no per-user daily limit.'
21521+
type: number
21522+
format: float
21523+
example: 10
21524+
nullable: true
21525+
userMonthlyCostLimit:
21526+
description: 'Default maximum AI cost a single user can spend per month. Applies to every user unless overridden in `perUserOverrides`. `null` means no per-user monthly limit.'
21527+
type: number
21528+
format: float
21529+
example: 200
21530+
nullable: true
21531+
perUserOverrides:
21532+
description: 'Per-user cost limit overrides that take precedence over `userDailyCostLimit` and `userMonthlyCostLimit`.'
21533+
type: array
21534+
items:
21535+
$ref: '#/components/schemas/AiUserCostLimit'
2147721536
type: object
21537+
AiUserCostLimit:
21538+
title: 'AI User Cost Limit'
21539+
properties:
21540+
userId:
21541+
description: 'ID of the user this cost limit override applies to'
21542+
type: integer
21543+
example: 123
21544+
costLimitMode:
21545+
description: "User AI cost limit mode\n\nValues available:\n- custom - Custom daily and monthly cost limits are applied\n- blocked - User is blocked from using AI\n- unlimited - User has no AI cost limit"
21546+
type: string
21547+
enum:
21548+
- custom
21549+
- blocked
21550+
- unlimited
21551+
example: custom
21552+
dailyCostLimit:
21553+
description: 'Maximum AI cost this user can spend per day. Applies when `costLimitMode` is `custom`. `null` for `blocked` and `unlimited` modes.'
21554+
type: number
21555+
format: float
21556+
example: 5
21557+
nullable: true
21558+
monthlyCostLimit:
21559+
description: 'Maximum AI cost this user can spend per month. Applies when `costLimitMode` is `custom`. `null` for `blocked` and `unlimited` modes.'
21560+
type: number
21561+
format: float
21562+
example: 100
21563+
nullable: true
21564+
createdAt:
21565+
type: string
21566+
format: date-time
21567+
example: '2026-05-23T11:26:54+00:00'
21568+
updatedAt:
21569+
type: string
21570+
format: date-time
21571+
example: '2026-05-23T11:26:54+00:00'
21572+
type: object
21573+
CrowdinAiSettings:
21574+
title: 'AI Settings'
21575+
type: object
21576+
allOf:
21577+
-
21578+
$ref: '#/components/schemas/AiSettings'
2147821579
AiTranslateFormBase:
2147921580
required:
2148021581
- strings
@@ -22322,12 +22423,12 @@ components:
2232222423
description: 'Lifecycle event URLs that changed (installed/uninstall/status)'
2232322424
type: object
2232422425
additionalProperties:
22325-
type: object
2232622426
properties:
2232722427
from:
2232822428
type: string
2232922429
to:
2233022430
type: string
22431+
type: object
2233122432
baseUrlChanged:
2233222433
description: 'baseUrl change (host that serves the app)'
2233322434
properties:

src/assets/api/crowdin/string-based.yml

Lines changed: 105 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19631,21 +19631,31 @@ components:
1963119631
type: string
1963219632
enum:
1963319633
- replace
19634+
- remove
1963419635
- test
1963519636
path:
19636-
description: 'A JSON Pointer as defined by <a href="https://tools.ietf.org/html/rfc6901" target="_blank">RFC 6901</a>'
19637+
description: 'A JSON Pointer as defined by <a href="https://tools.ietf.org/html/rfc6901" target="_blank">RFC 6901</a>. The `/perUserOverrides/{userId}` and `/perUserOverrides/{userId}/*` paths accept any positive integer for `{userId}`. Creating a new override requires `{userId}` to be a project member; this requirement does not apply when editing or removing an existing one. The `remove` operation is supported for the `/perUserOverrides/{userId}` path (removes the entire per-user override) and for `/perUserOverrides/{userId}/*` field paths (removes that field; the resulting override is re-validated).'
1963719638
type: string
1963819639
format: json-pointer
1963919640
enum:
1964019641
- /preTranslationAiPromptId
1964119642
- /editorSuggestionAiPromptId
1964219643
- /qaCheckActionAiPromptId
1964319644
- /contextReviewAiPromptId
19645+
- /dailyCostLimit
19646+
- /monthlyCostLimit
19647+
- /userDailyCostLimit
19648+
- /userMonthlyCostLimit
19649+
- '/perUserOverrides/{userId}'
19650+
- '/perUserOverrides/{userId}/costLimitMode'
19651+
- '/perUserOverrides/{userId}/dailyCostLimit'
19652+
- '/perUserOverrides/{userId}/monthlyCostLimit'
1964419653
type: object
1964519654
discriminator:
1964619655
propertyName: op
1964719656
mapping:
1964819657
replace: '#/components/schemas/AiSettingsOperationReplace'
19658+
remove: '#/components/schemas/AiSettingsOperationRemove'
1964919659
test: '#/components/schemas/AiSettingsOperationTest'
1965019660
AiSettingsOperationReplace:
1965119661
description: 'A JSON Patch `Replace` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.3)'
@@ -19661,8 +19671,21 @@ components:
1966119671
oneOf:
1966219672
-
1966319673
type: integer
19674+
-
19675+
type: number
19676+
format: float
19677+
-
19678+
type: string
19679+
-
19680+
nullable: true
19681+
AiSettingsOperationRemove:
19682+
description: 'A JSON Patch `Remove` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.2). Supported for the `/perUserOverrides/{userId}` path (removes the entire per-user override) and `/perUserOverrides/{userId}/*` field paths (removes that field). The `costLimitMode` field cannot be removed as the override always requires it.'
19683+
type: object
19684+
allOf:
19685+
-
19686+
$ref: '#/components/schemas/AiSettingsOperation'
1966419687
AiSettingsOperationTest:
19665-
description: 'A JSON Patch `Replace` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.3)'
19688+
description: 'A JSON Patch `Test` operation as defined by [RFC 6902](https://tools.ietf.org/html/rfc6902#section-4.6)'
1966619689
required:
1966719690
- value
1966819691
type: object
@@ -19675,6 +19698,13 @@ components:
1967519698
oneOf:
1967619699
-
1967719700
type: integer
19701+
-
19702+
type: number
19703+
format: float
19704+
-
19705+
type: string
19706+
-
19707+
nullable: true
1967819708
CrowdinAiSettingsResource:
1967919709
description: 'AI Settings Resource'
1968019710
type: object
@@ -19685,7 +19715,7 @@ components:
1968519715
properties:
1968619716
data:
1968719717
$ref: '#/components/schemas/CrowdinAiSettings'
19688-
CrowdinAiSettings:
19718+
AiSettings:
1968919719
title: 'AI Settings'
1969019720
properties:
1969119721
preTranslationAiPromptId:
@@ -19702,7 +19732,78 @@ components:
1970219732
type: integer
1970319733
example: 11
1970419734
nullable: true
19735+
dailyCostLimit:
19736+
description: 'Maximum total AI cost the organization can spend per day. `null` means no daily limit.'
19737+
type: number
19738+
format: float
19739+
example: 100
19740+
nullable: true
19741+
monthlyCostLimit:
19742+
description: 'Maximum total AI cost the organization can spend per month. `null` means no monthly limit.'
19743+
type: number
19744+
format: float
19745+
example: 2000
19746+
nullable: true
19747+
userDailyCostLimit:
19748+
description: 'Default maximum AI cost a single user can spend per day. Applies to every user unless overridden in `perUserOverrides`. `null` means no per-user daily limit.'
19749+
type: number
19750+
format: float
19751+
example: 10
19752+
nullable: true
19753+
userMonthlyCostLimit:
19754+
description: 'Default maximum AI cost a single user can spend per month. Applies to every user unless overridden in `perUserOverrides`. `null` means no per-user monthly limit.'
19755+
type: number
19756+
format: float
19757+
example: 200
19758+
nullable: true
19759+
perUserOverrides:
19760+
description: 'Per-user cost limit overrides that take precedence over `userDailyCostLimit` and `userMonthlyCostLimit`.'
19761+
type: array
19762+
items:
19763+
$ref: '#/components/schemas/AiUserCostLimit'
1970519764
type: object
19765+
AiUserCostLimit:
19766+
title: 'AI User Cost Limit'
19767+
properties:
19768+
userId:
19769+
description: 'ID of the user this cost limit override applies to'
19770+
type: integer
19771+
example: 123
19772+
costLimitMode:
19773+
description: "User AI cost limit mode\n\nValues available:\n- custom - Custom daily and monthly cost limits are applied\n- blocked - User is blocked from using AI\n- unlimited - User has no AI cost limit"
19774+
type: string
19775+
enum:
19776+
- custom
19777+
- blocked
19778+
- unlimited
19779+
example: custom
19780+
dailyCostLimit:
19781+
description: 'Maximum AI cost this user can spend per day. Applies when `costLimitMode` is `custom`. `null` for `blocked` and `unlimited` modes.'
19782+
type: number
19783+
format: float
19784+
example: 5
19785+
nullable: true
19786+
monthlyCostLimit:
19787+
description: 'Maximum AI cost this user can spend per month. Applies when `costLimitMode` is `custom`. `null` for `blocked` and `unlimited` modes.'
19788+
type: number
19789+
format: float
19790+
example: 100
19791+
nullable: true
19792+
createdAt:
19793+
type: string
19794+
format: date-time
19795+
example: '2026-05-23T11:26:54+00:00'
19796+
updatedAt:
19797+
type: string
19798+
format: date-time
19799+
example: '2026-05-23T11:26:54+00:00'
19800+
type: object
19801+
CrowdinAiSettings:
19802+
title: 'AI Settings'
19803+
type: object
19804+
allOf:
19805+
-
19806+
$ref: '#/components/schemas/AiSettings'
1970619807
AiTranslateFormBase:
1970719808
required:
1970819809
- strings
@@ -20227,12 +20328,12 @@ components:
2022720328
description: 'Lifecycle event URLs that changed (installed/uninstall/status)'
2022820329
type: object
2022920330
additionalProperties:
20230-
type: object
2023120331
properties:
2023220332
from:
2023320333
type: string
2023420334
to:
2023520335
type: string
20336+
type: object
2023620337
baseUrlChanged:
2023720338
description: 'baseUrl change (host that serves the app)'
2023820339
properties:

0 commit comments

Comments
 (0)