@rentnerproxy/app-contracts 0.0.0-stage → 1.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.
Files changed (45) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +39 -2
  3. package/contracts.schema.json +4007 -0
  4. package/dist/Types/contract.types.d.ts +15 -0
  5. package/dist/Types/contract.types.js +1 -0
  6. package/dist/catalog.d.ts +352 -0
  7. package/dist/catalog.js +54 -0
  8. package/dist/client.d.ts +31 -0
  9. package/dist/client.js +66 -0
  10. package/dist/http-operations.d.ts +333 -0
  11. package/dist/http-operations.generated.d.ts +299 -0
  12. package/dist/http-operations.generated.js +300 -0
  13. package/dist/http-operations.js +17 -0
  14. package/dist/http.d.ts +127 -0
  15. package/dist/http.js +142 -0
  16. package/dist/index.d.ts +5 -0
  17. package/dist/index.js +4 -0
  18. package/dist/manifest.d.ts +90 -0
  19. package/dist/manifest.js +106 -0
  20. package/dist/platform-api.d.ts +282 -0
  21. package/dist/platform-api.js +287 -0
  22. package/dist/primitives.d.ts +33 -0
  23. package/dist/primitives.js +87 -0
  24. package/dist/provider-api.d.ts +221 -0
  25. package/dist/provider-api.js +227 -0
  26. package/dist/public-schemas.d.ts +4 -0
  27. package/dist/public-schemas.js +6 -0
  28. package/dist/publication.d.ts +410 -0
  29. package/dist/publication.js +50 -0
  30. package/dist/runtime.d.ts +75 -0
  31. package/dist/runtime.js +88 -0
  32. package/dist/schemas.d.ts +926 -0
  33. package/dist/schemas.js +114 -0
  34. package/dist/ui-bridge.d.ts +81 -0
  35. package/dist/ui-bridge.js +92 -0
  36. package/dist/validation.d.ts +784 -0
  37. package/dist/validation.js +245 -0
  38. package/dist/wire.d.ts +31 -0
  39. package/dist/wire.js +54 -0
  40. package/fixtures.json +1094 -0
  41. package/http-fixtures.json +829 -0
  42. package/openapi.json +2557 -0
  43. package/package.json +60 -5
  44. package/protocol-fixtures.json +1804 -0
  45. package/upstream-probe-fixtures.json +852 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Kevin Sträßler
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,40 @@
1
- # Temporary Holding Version
1
+ # @rentnerproxy/app-contracts
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ The versioned RentnerProxy app contract for TypeScript: Zod schemas, validators and typed HTTP descriptors for app
4
+ manifests, releases, candidates, catalogs and the platform and app protocols.
5
+
6
+ ```bash
7
+ npm install @rentnerproxy/app-contracts
8
+ ```
9
+
10
+ ```ts
11
+ import { contractVersion, parseAppManifest } from '@rentnerproxy/app-contracts'
12
+ import schema from '@rentnerproxy/app-contracts/contracts.schema.json' with { type: 'json' }
13
+
14
+ const manifest = parseAppManifest(JSON.parse(source))
15
+ ```
16
+
17
+ The Zod schemas behind the validators are available from `@rentnerproxy/app-contracts/schemas`, for consumers that
18
+ build their own validation on top of the contract:
19
+
20
+ ```ts
21
+ import { appManifest, commit } from '@rentnerproxy/app-contracts/schemas'
22
+ ```
23
+
24
+ Besides the validators, the package ships the generated JSON documents and the shared fixtures, so an app can test
25
+ against exactly the cases the platform checks:
26
+
27
+ | Export | Content |
28
+ | -------------------------------- | ------------------------------------------------------------- |
29
+ | `./contracts.schema.json` | JSON Schema of every contract document |
30
+ | `./openapi.json` | OpenAPI description of the platform and app HTTP surface |
31
+ | `./fixtures.json` | Manifest, release and catalog fixtures |
32
+ | `./http-fixtures.json` | HTTP request and response fixtures |
33
+ | `./protocol-fixtures.json` | Protocol document fixtures |
34
+ | `./upstream-probe-fixtures.json` | Upstream probe outcomes and the monitoring result they map to |
35
+
36
+ The package version is the contract version. Additive changes bump the minor version; breaking changes need a new
37
+ major version. The package is built from the [RentnerProxy app SDK](https://github.com/RentnerProxy/app-sdk), which
38
+ also publishes the matching Rust crates.
39
+
40
+ Licensed under the MIT license.