@bearei/contracts 2.0.0-dev.3 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,14 @@ All notable changes to this project are documented in this file. The format is b
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to
5
5
  [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## 2.1.0 — 2026-10-27
8
+
9
+ ### Added
10
+
11
+ - `HTTP_EXCEPTION_CODE.CONFLICT` (`409000`) for writes that lose a race with a concurrent request
12
+ and collide with existing data. It is returned with HTTP status `409`; `SERVICE_FIELDS_ALREADY_EXISTS`
13
+ (`400003`) keeps its existing meaning for pre-validation rejections.
14
+
7
15
  ## 2.0.0-dev.3 — 2026-10-27
8
16
 
9
17
  Development snapshot published under the `next` dist-tag to verify the unified release pipeline
package/README.md CHANGED
@@ -70,6 +70,6 @@ existing value; renaming a code is also a breaking change for consumers that imp
70
70
 
71
71
  ```bash
72
72
  yarn install
73
- yarn verify # lint + typecheck + coverage + build
73
+ yarn verify # format + lint + typecheck + coverage + build
74
74
  yarn run pack # pack once and inspect the tarball
75
75
  ```
package/dist/index.d.mts CHANGED
@@ -9,6 +9,7 @@ declare const HTTP_EXCEPTION_CODE: {
9
9
  readonly APPLE_IAP_TRANSACTION_VERIFICATION_FAILED: 403005;
10
10
  readonly BAD_GATEWAY: 502000;
11
11
  readonly BAD_REQUEST: 400000;
12
+ readonly CONFLICT: 409000;
12
13
  readonly CONTAINS_INVALID_REQUEST_HEADERS: 400001;
13
14
  readonly EMAIL_CODE_INVALID: 401004;
14
15
  readonly EMAIL_SENDING_FAILED: 400005;
package/dist/index.d.ts CHANGED
@@ -9,6 +9,7 @@ declare const HTTP_EXCEPTION_CODE: {
9
9
  readonly APPLE_IAP_TRANSACTION_VERIFICATION_FAILED: 403005;
10
10
  readonly BAD_GATEWAY: 502000;
11
11
  readonly BAD_REQUEST: 400000;
12
+ readonly CONFLICT: 409000;
12
13
  readonly CONTAINS_INVALID_REQUEST_HEADERS: 400001;
13
14
  readonly EMAIL_CODE_INVALID: 401004;
14
15
  readonly EMAIL_SENDING_FAILED: 400005;
package/dist/index.js CHANGED
@@ -37,6 +37,7 @@ var HTTP_EXCEPTION_CODE = {
37
37
  APPLE_IAP_TRANSACTION_VERIFICATION_FAILED: 403005,
38
38
  BAD_GATEWAY: 502e3,
39
39
  BAD_REQUEST: 4e5,
40
+ CONFLICT: 409e3,
40
41
  CONTAINS_INVALID_REQUEST_HEADERS: 400001,
41
42
  EMAIL_CODE_INVALID: 401004,
42
43
  EMAIL_SENDING_FAILED: 400005,
package/dist/index.mjs CHANGED
@@ -6,6 +6,7 @@ var HTTP_EXCEPTION_CODE = {
6
6
  APPLE_IAP_TRANSACTION_VERIFICATION_FAILED: 403005,
7
7
  BAD_GATEWAY: 502e3,
8
8
  BAD_REQUEST: 4e5,
9
+ CONFLICT: 409e3,
9
10
  CONTAINS_INVALID_REQUEST_HEADERS: 400001,
10
11
  EMAIL_CODE_INVALID: 401004,
11
12
  EMAIL_SENDING_FAILED: 400005,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bearei/contracts",
3
- "version": "2.0.0-dev.3",
3
+ "version": "2.1.0",
4
4
  "description": "Framework-agnostic wire contracts shared by Bearei services, clients and apps",
5
5
  "keywords": [
6
6
  "bearei",
@@ -45,9 +45,9 @@
45
45
  "access": "public"
46
46
  },
47
47
  "devDependencies": {
48
- "@bearei/eslint-config": "^2.0.0",
49
- "@bearei/jest-preset": "^2.0.0",
50
- "@bearei/tsconfig": "^2.0.0",
48
+ "@bearei/eslint-config": "^2.1.0-dev.2",
49
+ "@bearei/jest-preset": "^2.1.0-dev.2",
50
+ "@bearei/tsconfig": "^2.1.0-dev.2",
51
51
  "@types/jest": "^29.5.13",
52
52
  "eslint": "^9.37.0",
53
53
  "jest": "^29.7.0",
@@ -76,13 +76,14 @@
76
76
  },
77
77
  "scripts": {
78
78
  "build": "tsup",
79
+ "format": "prettier --write .",
79
80
  "lint": "eslint \"src/**/*.ts\"",
80
81
  "pack": "yarn pack -o /tmp/bearei-contracts.tgz && bash .github/scripts/verify-tarball.sh /tmp/bearei-contracts.tgz",
81
82
  "prepack": "yarn build",
82
83
  "test": "jest",
83
84
  "test:coverage": "jest --coverage",
84
85
  "typecheck": "tsc --noEmit -p tsconfig.json",
85
- "verify": "yarn lint && yarn typecheck && yarn test:coverage && yarn build"
86
+ "verify": "yarn prettier --check . && yarn lint && yarn typecheck && yarn test:coverage && yarn build"
86
87
  },
87
- "packageManager": "yarn@4.18.0"
88
+ "packageManager": "yarn@4.18.0+sha512.fcb8716fe7cd0eece141ffc18b92193a9df9204c1ba83189c288835223fc0bbe64af473bab0d5e9927a7daeb5caf2bb07eb2787cc9338ca040ea125f2a1f2f7e"
88
89
  }