From 4772d0d95398b4f8a48e1e2bae6b1fbbb387dec2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 12 Sep 2026 14:54:09 +0000 Subject: [PATCH 1/2] chore(deps-dev): bump @apidevtools/json-schema-ref-parser Bumps [@apidevtools/json-schema-ref-parser](https://github.com/APIDevTools/json-schema-ref-parser) from 15.4.0 to 16.0.1. - [Release notes](https://github.com/APIDevTools/json-schema-ref-parser/releases) - [Commits](https://github.com/APIDevTools/json-schema-ref-parser/compare/v15.4.0...v16.0.1) --- updated-dependencies: - dependency-name: "@apidevtools/json-schema-ref-parser" dependency-version: 16.0.1 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- package.json | 2 +- pnpm-lock.yaml | 21 +++++++++++---------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index 85d3cfb..bbe34a9 100644 --- a/package.json +++ b/package.json @@ -65,7 +65,7 @@ "yaml": "^2.9.0" }, "devDependencies": { - "@apidevtools/json-schema-ref-parser": "^15.4.0", + "@apidevtools/json-schema-ref-parser": "^16.0.1", "@biomejs/biome": "^2.5.2", "@changesets/cli": "^3.0.0", "@types/node": "^26.1.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 9bd3114..c8dbae5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -26,8 +26,8 @@ importers: version: 2.9.0 devDependencies: '@apidevtools/json-schema-ref-parser': - specifier: ^15.4.0 - version: 15.4.0(@types/json-schema@7.0.15) + specifier: ^16.0.1 + version: 16.0.1(@types/json-schema@7.0.15) '@biomejs/biome': specifier: ^2.5.2 version: 2.5.11 @@ -70,9 +70,9 @@ importers: packages: - '@apidevtools/json-schema-ref-parser@15.4.0': - resolution: {integrity: sha512-QbMJJlMZd27fZmi7Q+twCqwABlfaO4Qdc1YvbbwkqN2lILfELnfWfw9xFFl6CeF5jAeGQpokUVhvCkhz+rvEGg==} - engines: {node: '>=20'} + '@apidevtools/json-schema-ref-parser@16.0.1': + resolution: {integrity: sha512-JmQn9gXVZ83h3IgC+xXVmR4CXWbX1TTyQBj+q4d8BeJqDWSSD/Q3GbkrjhAbXCZxtjnlljOjyy0vio14vQjJtg==} + engines: {node: '>=22.19.0'} peerDependencies: '@types/json-schema': ^7.0.15 @@ -844,8 +844,8 @@ packages: resolution: {integrity: sha512-34wB/Y7MW7bzjKRjUKTa46I2Z7eV62Rkhva+KkopW7Qvv/OSWBqvkSY7vusOPrNuZcUG3tApvdVgNB8POj3SPw==} engines: {node: '>=10'} - js-yaml@4.3.0: - resolution: {integrity: sha512-1td788aAnnZ5qs7V2QIRl1owjtYpbKt749Y3xauqQgwIIGF/xXWz1wMTEBx5O3LK3lXLVuqXPdPxj2BoFHaW9Q==} + js-yaml@5.4.1: + resolution: {integrity: sha512-28R/k+NAjeuf7+CKlTxWZVExJGwVVLwY06DgEnOMz2gEpfNkDcD7QvyiVPT0xy0XXhU8vHsd4Ot42OOPdJG7dQ==} hasBin: true json-schema-to-zod@2.8.1: @@ -1246,10 +1246,11 @@ packages: snapshots: - '@apidevtools/json-schema-ref-parser@15.4.0(@types/json-schema@7.0.15)': + '@apidevtools/json-schema-ref-parser@16.0.1(@types/json-schema@7.0.15)': dependencies: '@types/json-schema': 7.0.15 - js-yaml: 4.3.0 + js-yaml: 5.4.1 + undici: 8.10.0 '@biomejs/biome@2.5.11': optionalDependencies: @@ -1839,7 +1840,7 @@ snapshots: joycon@3.1.1: {} - js-yaml@4.3.0: + js-yaml@5.4.1: dependencies: argparse: 2.0.1 From b3b1951bfe8937fd52f3c8f03a916e1113c9e07c Mon Sep 17 00:00:00 2001 From: Ilya Grigorik Date: Sat, 12 Sep 2026 07:58:57 -0700 Subject: [PATCH 2/2] chore: regenerate profile schemas Ref parser 16 resolves dereferenced entity versions to the shared entity description. Commit its deterministic output so the codegen drift gate matches the upgraded generator. --- src/core/generated/2026-04-08/business_profile.zod.ts | 6 +++--- src/core/generated/2026-04-08/platform_profile.zod.ts | 6 +++--- src/core/generated/2026-08-25/business_profile.zod.ts | 6 +++--- src/core/generated/2026-08-25/platform_profile.zod.ts | 6 +++--- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/core/generated/2026-04-08/business_profile.zod.ts b/src/core/generated/2026-04-08/business_profile.zod.ts index fc3d4ad..e1506ec 100644 --- a/src/core/generated/2026-04-08/business_profile.zod.ts +++ b/src/core/generated/2026-04-08/business_profile.zod.ts @@ -13,7 +13,7 @@ import { z } from "zod" -export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { +export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$")), z.array(z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$"))).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -45,7 +45,7 @@ export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), "signing_keys": z.array(z.object({ "kid": z.string().describe("Key ID. Referenced in signature headers to identify which key to use for verification."), "kty": z.string().describe("Key type (e.g., 'EC', 'RSA')."), "crv": z.string().describe("Curve name for EC keys (e.g., 'P-256').").optional(), "x": z.string().describe("X coordinate for EC public keys (base64url encoded).").optional(), "y": z.string().describe("Y coordinate for EC public keys (base64url encoded).").optional(), "n": z.string().describe("Modulus for RSA public keys (base64url encoded).").optional(), "e": z.string().describe("Exponent for RSA public keys (base64url encoded).").optional(), "use": z.enum(["sig","enc"]).describe("Key usage. Should be 'sig' for signing keys.").optional(), "alg": z.string().describe("Algorithm (e.g., 'ES256', 'RS256').").optional() }).catchall(z.any()).describe("Public key for signature verification in JWK format.")).describe("Public keys for signature verification (JWK format). Used to verify signed responses, webhooks, and other authenticated messages from this party.").optional() }).catchall(z.any()).describe("Base discovery profile with shared properties for all profile types."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), "signing_keys": z.array(z.object({ "kid": z.string().describe("Key ID. Referenced in signature headers to identify which key to use for verification."), "kty": z.string().describe("Key type (e.g., 'EC', 'RSA')."), "crv": z.string().describe("Curve name for EC keys (e.g., 'P-256').").optional(), "x": z.string().describe("X coordinate for EC public keys (base64url encoded).").optional(), "y": z.string().describe("Y coordinate for EC public keys (base64url encoded).").optional(), "n": z.string().describe("Modulus for RSA public keys (base64url encoded).").optional(), "e": z.string().describe("Exponent for RSA public keys (base64url encoded).").optional(), "use": z.enum(["sig","enc"]).describe("Key usage. Should be 'sig' for signing keys.").optional(), "alg": z.string().describe("Algorithm (e.g., 'ES256', 'RS256').").optional() }).catchall(z.any()).describe("Public key for signature verification in JWK format.")).describe("Public keys for signature verification (JWK format). Used to verify signed responses, webhooks, and other authenticated messages from this party.").optional() }).catchall(z.any()).describe("Base discovery profile with shared properties for all profile types."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$")), z.array(z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$"))).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -77,6 +77,6 @@ export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "supported_versions": z.record(z.string(), z.string().url()).describe("Previous protocol versions this business supports, mapped to profile URIs. Businesses that support older protocol versions SHOULD advertise each version and link to its profile. Each URI points to a complete, self-contained profile for that version. When omitted, only `version` is supported.").optional(), "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("UCP metadata for business/merchant-level configuration. Subset of platform schema with business-specific settings.").optional() }).catchall(z.any())).describe("Discovery profile for businesses/merchants. Subset of platform profile with business-specific configuration.") + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "supported_versions": z.record(z.string(), z.string().url()).describe("Previous protocol versions this business supports, mapped to profile URIs. Businesses that support older protocol versions SHOULD advertise each version and link to its profile. Each URI points to a complete, self-contained profile for that version. When omitted, only `version` is supported.").optional(), "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("UCP metadata for business/merchant-level configuration. Subset of platform schema with business-specific settings.").optional() }).catchall(z.any())).describe("Discovery profile for businesses/merchants. Subset of platform profile with business-specific configuration.") export type BusinessProfile = z.infer diff --git a/src/core/generated/2026-04-08/platform_profile.zod.ts b/src/core/generated/2026-04-08/platform_profile.zod.ts index 8b9a738..a897fe6 100644 --- a/src/core/generated/2026-04-08/platform_profile.zod.ts +++ b/src/core/generated/2026-04-08/platform_profile.zod.ts @@ -13,7 +13,7 @@ import { z } from "zod" -export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { +export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$")), z.array(z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$"))).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -45,7 +45,7 @@ export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), "signing_keys": z.array(z.object({ "kid": z.string().describe("Key ID. Referenced in signature headers to identify which key to use for verification."), "kty": z.string().describe("Key type (e.g., 'EC', 'RSA')."), "crv": z.string().describe("Curve name for EC keys (e.g., 'P-256').").optional(), "x": z.string().describe("X coordinate for EC public keys (base64url encoded).").optional(), "y": z.string().describe("Y coordinate for EC public keys (base64url encoded).").optional(), "n": z.string().describe("Modulus for RSA public keys (base64url encoded).").optional(), "e": z.string().describe("Exponent for RSA public keys (base64url encoded).").optional(), "use": z.enum(["sig","enc"]).describe("Key usage. Should be 'sig' for signing keys.").optional(), "alg": z.string().describe("Algorithm (e.g., 'ES256', 'RS256').").optional() }).catchall(z.any()).describe("Public key for signature verification in JWK format.")).describe("Public keys for signature verification (JWK format). Used to verify signed responses, webhooks, and other authenticated messages from this party.").optional() }).catchall(z.any()).describe("Base discovery profile with shared properties for all profile types."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), "signing_keys": z.array(z.object({ "kid": z.string().describe("Key ID. Referenced in signature headers to identify which key to use for verification."), "kty": z.string().describe("Key type (e.g., 'EC', 'RSA')."), "crv": z.string().describe("Curve name for EC keys (e.g., 'P-256').").optional(), "x": z.string().describe("X coordinate for EC public keys (base64url encoded).").optional(), "y": z.string().describe("Y coordinate for EC public keys (base64url encoded).").optional(), "n": z.string().describe("Modulus for RSA public keys (base64url encoded).").optional(), "e": z.string().describe("Exponent for RSA public keys (base64url encoded).").optional(), "use": z.enum(["sig","enc"]).describe("Key usage. Should be 'sig' for signing keys.").optional(), "alg": z.string().describe("Algorithm (e.g., 'ES256', 'RS256').").optional() }).catchall(z.any()).describe("Public key for signature verification in JWK format.")).describe("Public keys for signature verification (JWK format). Used to verify signed responses, webhooks, and other authenticated messages from this party.").optional() }).catchall(z.any()).describe("Base discovery profile with shared properties for all profile types."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$")), z.array(z.string().regex(new RegExp("^[a-z][a-z0-9]*(?:\\.[a-z][a-z0-9_]*)+$"))).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -77,6 +77,6 @@ export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("UCP version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("Full UCP metadata for platform-level configuration. Hosted at a URI advertised by the platform in request headers.").optional() }).catchall(z.any())).describe("Full discovery profile for platforms. Exposes complete service, capability, and payment handler registries.") + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("Constraints on this instrument type. Structure depends on instrument type and active capabilities.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("Full UCP metadata for platform-level configuration. Hosted at a URI advertised by the platform in request headers.").optional() }).catchall(z.any())).describe("Full discovery profile for platforms. Exposes complete service, capability, and payment handler registries.") export type PlatformProfile = z.infer diff --git a/src/core/generated/2026-08-25/business_profile.zod.ts b/src/core/generated/2026-08-25/business_profile.zod.ts index 6765c66..21832c0 100644 --- a/src/core/generated/2026-08-25/business_profile.zod.ts +++ b/src/core/generated/2026-08-25/business_profile.zod.ts @@ -13,7 +13,7 @@ import { z } from "zod" -export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { +export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'."), z.array(z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'.")).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -45,7 +45,7 @@ export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Protocol metadata, capabilities, services, and payment handlers advertised by this party."), "keys": z.array(z.object({ "kid": z.string().describe("Key identifier referenced by Signature-Input keyid. For keys used in dual-audience (Web Bot Auth) signatures, the kid MUST be the key's JWK SHA-256 Thumbprint (RFC 7638) so UCP-Agent and Signature-Agent lookups resolve the same key; otherwise the kid MAY be any stable string."), "kty": z.string().describe("JWK key type. Well-known values: EC for ECDSA (P-256, P-384); OKP for EdDSA (Ed25519). Open vocabulary; verifiers tolerate unrecognized types and select keys by kid."), "crv": z.string().describe("Curve name. Well-known values: P-256, P-384 (EC); Ed25519 (OKP). Open vocabulary.").optional(), "x": z.string().describe("Public key value, base64url-encoded. For EC, the x coordinate (RFC 7518 §6.2); for OKP, the public key (RFC 8037 §2).").optional(), "y": z.string().describe("EC public key y coordinate, base64url-encoded (RFC 7518 §6.2). Not used by OKP keys.").optional(), "alg": z.string().describe("JWA algorithm associated with this public key. Optional; verifiers derive the algorithm from crv when alg is omitted. When present for a well-known curve it MUST match: ES256 with P-256, ES384 with P-384, EdDSA with Ed25519.").optional(), "use": z.string().describe("JWK public key use. UCP examples use sig for signatures.").optional() }).catchall(z.any()).and(z.intersection(z.intersection(z.any(), z.any()), z.intersection(z.any(), z.intersection(z.any(), z.any())))).describe("Public JSON Web Key used for HTTP Message Signatures and signed webhook verification. UCP profiles publish public keys only; private key material MUST NOT appear in a profile. Well-known key types: EC (ECDSA P-256, P-384) and OKP (EdDSA Ed25519); OKP keys are RECOMMENDED for signers opting into Web Bot Auth (WBA) interop on HTTP transport. A single profile MAY publish keys of either or both types; consumers select keys by kid. The kty, crv, and alg vocabularies are OPEN: verifiers MUST tolerate key types, curves, and algorithms they do not recognize, selecting keys by kid at verification time. An unsupported key affects only the signature that references it (algorithm_unsupported) and MUST NOT cause whole-profile rejection. Additional public JWK members are permitted; consumers ignore unknown members.")).describe("Canonical UCP profile field for publishing signing keys, as a JWK Set per RFC 7517. When a profile publishes signing keys, they MUST appear here; this is where every UCP verifier reads them. Publishing keys[] makes the UCP profile a valid JWK Set that a signer can reuse as its Web Bot Auth key source: a WBA-shape verifier resolving via Signature-Agent type=jwks_uri pointed at this profile reads these keys, and the cimd and directory variants reach them through their own documents. See the Deployment Patterns for WBA Interop section in the overview for hosting patterns.").optional() }).catchall(z.any()).describe("Common wrapper for UCP profile documents."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Protocol metadata, capabilities, services, and payment handlers advertised by this party."), "keys": z.array(z.object({ "kid": z.string().describe("Key identifier referenced by Signature-Input keyid. For keys used in dual-audience (Web Bot Auth) signatures, the kid MUST be the key's JWK SHA-256 Thumbprint (RFC 7638) so UCP-Agent and Signature-Agent lookups resolve the same key; otherwise the kid MAY be any stable string."), "kty": z.string().describe("JWK key type. Well-known values: EC for ECDSA (P-256, P-384); OKP for EdDSA (Ed25519). Open vocabulary; verifiers tolerate unrecognized types and select keys by kid."), "crv": z.string().describe("Curve name. Well-known values: P-256, P-384 (EC); Ed25519 (OKP). Open vocabulary.").optional(), "x": z.string().describe("Public key value, base64url-encoded. For EC, the x coordinate (RFC 7518 §6.2); for OKP, the public key (RFC 8037 §2).").optional(), "y": z.string().describe("EC public key y coordinate, base64url-encoded (RFC 7518 §6.2). Not used by OKP keys.").optional(), "alg": z.string().describe("JWA algorithm associated with this public key. Optional; verifiers derive the algorithm from crv when alg is omitted. When present for a well-known curve it MUST match: ES256 with P-256, ES384 with P-384, EdDSA with Ed25519.").optional(), "use": z.string().describe("JWK public key use. UCP examples use sig for signatures.").optional() }).catchall(z.any()).and(z.intersection(z.intersection(z.any(), z.any()), z.intersection(z.any(), z.intersection(z.any(), z.any())))).describe("Public JSON Web Key used for HTTP Message Signatures and signed webhook verification. UCP profiles publish public keys only; private key material MUST NOT appear in a profile. Well-known key types: EC (ECDSA P-256, P-384) and OKP (EdDSA Ed25519); OKP keys are RECOMMENDED for signers opting into Web Bot Auth (WBA) interop on HTTP transport. A single profile MAY publish keys of either or both types; consumers select keys by kid. The kty, crv, and alg vocabularies are OPEN: verifiers MUST tolerate key types, curves, and algorithms they do not recognize, selecting keys by kid at verification time. An unsupported key affects only the signature that references it (algorithm_unsupported) and MUST NOT cause whole-profile rejection. Additional public JWK members are permitted; consumers ignore unknown members.")).describe("Canonical UCP profile field for publishing signing keys, as a JWK Set per RFC 7517. When a profile publishes signing keys, they MUST appear here; this is where every UCP verifier reads them. Publishing keys[] makes the UCP profile a valid JWK Set that a signer can reuse as its Web Bot Auth key source: a WBA-shape verifier resolving via Signature-Agent type=jwks_uri pointed at this profile reads these keys, and the cimd and directory variants reach them through their own documents. See the Deployment Patterns for WBA Interop section in the overview for hosting patterns.").optional() }).catchall(z.any()).describe("Common wrapper for UCP profile documents."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'."), z.array(z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'.")).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -77,6 +77,6 @@ export const businessProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "supported_versions": z.record(z.string(), z.string().url()).describe("Previous protocol versions this business supports, mapped to profile URIs. Businesses that support older protocol versions SHOULD advertise each version and link to its profile. Each URI points to a complete, self-contained profile for that version. When omitted, only `version` is supported.").optional(), "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("UCP metadata for business/merchant-level configuration. Subset of platform schema with business-specific settings.").optional() }).catchall(z.any())).describe("Profile document hosted by a business at /.well-known/ucp.") + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "supported_versions": z.record(z.string(), z.string().url()).describe("Previous protocol versions this business supports, mapped to profile URIs. Businesses that support older protocol versions SHOULD advertise each version and link to its profile. Each URI points to a complete, self-contained profile for that version. When omitted, only `version` is supported.").optional(), "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("UCP metadata for business/merchant-level configuration. Subset of platform schema with business-specific settings.").optional() }).catchall(z.any())).describe("Profile document hosted by a business at /.well-known/ucp.") export type BusinessProfile = z.infer diff --git a/src/core/generated/2026-08-25/platform_profile.zod.ts b/src/core/generated/2026-08-25/platform_profile.zod.ts index e6461a1..dd170c7 100644 --- a/src/core/generated/2026-08-25/platform_profile.zod.ts +++ b/src/core/generated/2026-08-25/platform_profile.zod.ts @@ -13,7 +13,7 @@ import { z } from "zod" -export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { +export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'."), z.array(z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'.")).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -45,7 +45,7 @@ export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Protocol metadata, capabilities, services, and payment handlers advertised by this party."), "keys": z.array(z.object({ "kid": z.string().describe("Key identifier referenced by Signature-Input keyid. For keys used in dual-audience (Web Bot Auth) signatures, the kid MUST be the key's JWK SHA-256 Thumbprint (RFC 7638) so UCP-Agent and Signature-Agent lookups resolve the same key; otherwise the kid MAY be any stable string."), "kty": z.string().describe("JWK key type. Well-known values: EC for ECDSA (P-256, P-384); OKP for EdDSA (Ed25519). Open vocabulary; verifiers tolerate unrecognized types and select keys by kid."), "crv": z.string().describe("Curve name. Well-known values: P-256, P-384 (EC); Ed25519 (OKP). Open vocabulary.").optional(), "x": z.string().describe("Public key value, base64url-encoded. For EC, the x coordinate (RFC 7518 §6.2); for OKP, the public key (RFC 8037 §2).").optional(), "y": z.string().describe("EC public key y coordinate, base64url-encoded (RFC 7518 §6.2). Not used by OKP keys.").optional(), "alg": z.string().describe("JWA algorithm associated with this public key. Optional; verifiers derive the algorithm from crv when alg is omitted. When present for a well-known curve it MUST match: ES256 with P-256, ES384 with P-384, EdDSA with Ed25519.").optional(), "use": z.string().describe("JWK public key use. UCP examples use sig for signatures.").optional() }).catchall(z.any()).and(z.intersection(z.intersection(z.any(), z.any()), z.intersection(z.any(), z.intersection(z.any(), z.any())))).describe("Public JSON Web Key used for HTTP Message Signatures and signed webhook verification. UCP profiles publish public keys only; private key material MUST NOT appear in a profile. Well-known key types: EC (ECDSA P-256, P-384) and OKP (EdDSA Ed25519); OKP keys are RECOMMENDED for signers opting into Web Bot Auth (WBA) interop on HTTP transport. A single profile MAY publish keys of either or both types; consumers select keys by kid. The kty, crv, and alg vocabularies are OPEN: verifiers MUST tolerate key types, curves, and algorithms they do not recognize, selecting keys by kid at verification time. An unsupported key affects only the signature that references it (algorithm_unsupported) and MUST NOT cause whole-profile rejection. Additional public JWK members are permitted; consumers ignore unknown members.")).describe("Canonical UCP profile field for publishing signing keys, as a JWK Set per RFC 7517. When a profile publishes signing keys, they MUST appear here; this is where every UCP verifier reads them. Publishing keys[] makes the UCP profile a valid JWK Set that a signer can reuse as its Web Bot Auth key source: a WBA-shape verifier resolving via Signature-Agent type=jwks_uri pointed at this profile reads these keys, and the cimd and directory variants reach them through their own documents. See the Deployment Patterns for WBA Interop section in the overview for hosting patterns.").optional() }).catchall(z.any()).describe("Common wrapper for UCP profile documents."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Protocol metadata, capabilities, services, and payment handlers advertised by this party."), "keys": z.array(z.object({ "kid": z.string().describe("Key identifier referenced by Signature-Input keyid. For keys used in dual-audience (Web Bot Auth) signatures, the kid MUST be the key's JWK SHA-256 Thumbprint (RFC 7638) so UCP-Agent and Signature-Agent lookups resolve the same key; otherwise the kid MAY be any stable string."), "kty": z.string().describe("JWK key type. Well-known values: EC for ECDSA (P-256, P-384); OKP for EdDSA (Ed25519). Open vocabulary; verifiers tolerate unrecognized types and select keys by kid."), "crv": z.string().describe("Curve name. Well-known values: P-256, P-384 (EC); Ed25519 (OKP). Open vocabulary.").optional(), "x": z.string().describe("Public key value, base64url-encoded. For EC, the x coordinate (RFC 7518 §6.2); for OKP, the public key (RFC 8037 §2).").optional(), "y": z.string().describe("EC public key y coordinate, base64url-encoded (RFC 7518 §6.2). Not used by OKP keys.").optional(), "alg": z.string().describe("JWA algorithm associated with this public key. Optional; verifiers derive the algorithm from crv when alg is omitted. When present for a well-known curve it MUST match: ES256 with P-256, ES384 with P-384, EdDSA with Ed25519.").optional(), "use": z.string().describe("JWK public key use. UCP examples use sig for signatures.").optional() }).catchall(z.any()).and(z.intersection(z.intersection(z.any(), z.any()), z.intersection(z.any(), z.intersection(z.any(), z.any())))).describe("Public JSON Web Key used for HTTP Message Signatures and signed webhook verification. UCP profiles publish public keys only; private key material MUST NOT appear in a profile. Well-known key types: EC (ECDSA P-256, P-384) and OKP (EdDSA Ed25519); OKP keys are RECOMMENDED for signers opting into Web Bot Auth (WBA) interop on HTTP transport. A single profile MAY publish keys of either or both types; consumers select keys by kid. The kty, crv, and alg vocabularies are OPEN: verifiers MUST tolerate key types, curves, and algorithms they do not recognize, selecting keys by kid at verification time. An unsupported key affects only the signature that references it (algorithm_unsupported) and MUST NOT cause whole-profile rejection. Additional public JWK members are permitted; consumers ignore unknown members.")).describe("Canonical UCP profile field for publishing signing keys, as a JWK Set per RFC 7517. When a profile publishes signing keys, they MUST appear here; this is where every UCP verifier reads them. Publishing keys[] makes the UCP profile a valid JWK Set that a signer can reuse as its Web Bot Auth key source: a WBA-shape verifier resolving via Signature-Agent type=jwks_uri pointed at this profile reads these keys, and the cimd and directory variants reach them through their own documents. See the Deployment Patterns for WBA Interop section in the overview for hosting patterns.").optional() }).catchall(z.any()).describe("Common wrapper for UCP profile documents."), z.object({ "ucp": z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "map_order": z.record(z.string(), z.array(z.string())).describe("Preferred key-traversal order for sibling registry fields inside the root `ucp` envelope (`services`, `capabilities`, and `payment_handlers`).").optional(), "status": z.enum(["success","error"]).describe("Application-level status of the UCP operation.").default("success"), "services": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "transport": z.enum(["rest","mcp","a2a","embedded"]).describe("Transport protocol for this service binding."), "endpoint": z.string().url().describe("Endpoint URL for this transport binding.").optional() }).catchall(z.any())))).describe("Service registry keyed by reverse-domain name.").optional(), "capabilities": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.object({ "extends": z.any().superRefine((x, ctx) => { const schemas = [z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'."), z.array(z.string().regex(new RegExp("^[a-z](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9_])?)+$")).describe("Reverse-domain identifier used for collision-safe namespacing of capabilities, services, handlers, eligibility claims, and extension-contributed keys. Must contain at least two dot-separated segments (e.g., 'dev.ucp.shopping.checkout', 'com.example.loyalty_gold'). Segments after the first are domain- or identifier-derived: they may contain interior hyphens, may start with a digit, and may contain underscores (e.g., 'com.example-shop.checkout', 'com.2example.cart', 'dev.ucp.common.identity_linking'), but must not start or end with a hyphen. The first segment (the reversed top-level domain) is letters and digits, and may contain interior hyphens to support internationalized (punycode) top-level domains such as 'xn--p1ai'.")).min(1)]; const { errors, failed } = schemas.reduce<{ errors: z.core.$ZodIssue[]; @@ -77,6 +77,6 @@ export const platformProfileSchema = z.intersection(z.object({ "ucp": z.object({ message: "Invalid input: Should pass single schema. Passed " + passed, }); } - }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Version identifier in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("Full UCP metadata for platform-level configuration. Hosted at a URI advertised by the platform in request headers.").optional() }).catchall(z.any())).describe("Profile document hosted by a platform and advertised to businesses via UCP-Agent.") + }).describe("Parent capability(s) this extends. Present for extensions, absent for root capabilities. Use array for multi-parent extensions.").optional() }).catchall(z.any())))).describe("Capability registry keyed by reverse-domain name.").optional(), "payment_handlers": z.record(z.string(), z.array(z.intersection(z.object({ "version": z.string().regex(new RegExp("^\\d{4}-\\d{2}-\\d{2}$")).describe("Entity version in YYYY-MM-DD format."), "spec": z.string().url().describe("URL to human-readable specification document.").optional(), "schema": z.string().url().describe("URL to JSON Schema defining this entity's structure and payloads.").optional(), "id": z.string().describe("Unique identifier for this entity instance. Used to disambiguate when multiple instances exist.").optional(), "config": z.record(z.string(), z.any()).describe("Entity-specific configuration. Structure defined by each entity's schema.").optional() }).catchall(z.any()).describe("Shared foundation for all UCP entities."), z.intersection(z.record(z.string(), z.any()), z.object({ "available_instruments": z.array(z.object({ "type": z.string().describe("The instrument type identifier (e.g., 'card', 'gift_card'). References an instrument schema's type constant."), "constraints": z.record(z.string(), z.any()).describe("A Constraint Expression describing the instrument this entry makes available. Keys in `properties` name members of the `constraint_target` declared by the instrument schema for this `type`. Requirements on submitted request data belong in `ucp.request_constraints` instead.").optional() }).catchall(z.any()).describe("An instrument type available from a payment handler with optional constraints.")).min(1).describe("Instrument types this handler supports, with optional constraints. When absent, every instrument should be considered available.").optional() }).catchall(z.any()))))).describe("Payment handler registry keyed by reverse-domain name.").optional() }).catchall(z.any()).describe("Base UCP metadata with shared properties for all schema types."), z.object({ "services": z.any(), "capabilities": z.any().optional(), "payment_handlers": z.any() }).catchall(z.any())).describe("Full UCP metadata for platform-level configuration. Hosted at a URI advertised by the platform in request headers.").optional() }).catchall(z.any())).describe("Profile document hosted by a platform and advertised to businesses via UCP-Agent.") export type PlatformProfile = z.infer