diff --git a/sdk/typescript/lib/generated/.openapi-generator/FILES b/sdk/typescript/lib/generated/.openapi-generator/FILES index 611b188c5..d0c9b44e0 100644 --- a/sdk/typescript/lib/generated/.openapi-generator/FILES +++ b/sdk/typescript/lib/generated/.openapi-generator/FILES @@ -61,19 +61,30 @@ models/ComponentEntityRoleAssignments.ts models/ComponentMethodRoyalty.ts models/ComponentRoyaltyConfig.ts models/CursorLimitMixin.ts +models/DetailedEventEmitter.ts +models/DetailedEventEmitterBase.ts +models/DetailedEventIdentifier.ts +models/DetailedEventPayload.ts +models/DetailedEventPayloadTypeDefinition.ts +models/DetailedEventPayloadTypeDefinitionBase.ts +models/DetailedEventsItem.ts models/EntityMetadataCollection.ts models/EntityMetadataCollectionAllOf.ts models/EntityMetadataItem.ts models/EntityMetadataItemValue.ts models/EntityMetadataItemValueAllOf.ts +models/EntityMethodEventEmitter.ts +models/EntityMethodEventEmitterAllOf.ts models/EntityNotFoundError.ts models/EntityNotFoundErrorAllOf.ts models/EntitySchemaCollection.ts models/EntitySchemaCollectionAllOf.ts models/EntitySchemaCollectionItem.ts models/ErrorResponse.ts +models/EventEmitterType.ts models/EventsItem.ts models/FromLedgerStateMixin.ts +models/FunctionEmitter.ts models/FungibleResourcesCollection.ts models/FungibleResourcesCollectionAllOf.ts models/FungibleResourcesCollectionItem.ts @@ -171,6 +182,7 @@ models/MetadataUrlArrayValueAllOf.ts models/MetadataUrlValue.ts models/MetadataUrlValueAllOf.ts models/MetadataValueType.ts +models/MethodEmitter.ts models/NativeResourceAccessControllerRecoveryBadgeValue.ts models/NativeResourceAccessControllerRecoveryBadgeValueAllOf.ts models/NativeResourceAccountOwnerBadgeValue.ts @@ -235,6 +247,8 @@ models/PackageBlueprintCollectionItem.ts models/PackageCodeCollection.ts models/PackageCodeCollectionAllOf.ts models/PackageCodeCollectionItem.ts +models/PackageFunctionEventEmitter.ts +models/PackageFunctionEventEmitterAllOf.ts models/PackageVmType.ts models/PreviewFlags.ts models/PreviewTransaction.ts @@ -319,6 +333,9 @@ models/ResultSetCursorMixin.ts models/RoleAssignmentResolution.ts models/RoleKey.ts models/RoyaltyAmount.ts +models/SborTypeKind.ts +models/SchemaLocalEventPayloadTypeDefinition.ts +models/SchemaLocalEventPayloadTypeDefinitionAllOf.ts models/ScryptoSborValue.ts models/StateAccountAuthorizedDepositorsPageRequest.ts models/StateAccountAuthorizedDepositorsPageResponse.ts @@ -477,5 +494,7 @@ models/ValidatorsUptimeRequest.ts models/ValidatorsUptimeRequestAllOf.ts models/ValidatorsUptimeResponse.ts models/ValidatorsUptimeResponseAllOf.ts +models/WellKnownEventPayloadTypeDefinition.ts +models/WellKnownEventPayloadTypeDefinitionAllOf.ts models/index.ts runtime.ts diff --git a/sdk/typescript/lib/generated/models/DetailedEventEmitter.ts b/sdk/typescript/lib/generated/models/DetailedEventEmitter.ts new file mode 100644 index 000000000..c59c2ac7f --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventEmitter.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { + EntityMethodEventEmitter, + instanceOfEntityMethodEventEmitter, + EntityMethodEventEmitterFromJSON, + EntityMethodEventEmitterFromJSONTyped, + EntityMethodEventEmitterToJSON, +} from './EntityMethodEventEmitter'; +import { + PackageFunctionEventEmitter, + instanceOfPackageFunctionEventEmitter, + PackageFunctionEventEmitterFromJSON, + PackageFunctionEventEmitterFromJSONTyped, + PackageFunctionEventEmitterToJSON, +} from './PackageFunctionEventEmitter'; + +/** + * @type DetailedEventEmitter + * + * @export + */ +export type DetailedEventEmitter = { type: 'EntityMethod' } & EntityMethodEventEmitter | { type: 'PackageFunction' } & PackageFunctionEventEmitter; + +export function DetailedEventEmitterFromJSON(json: any): DetailedEventEmitter { + return DetailedEventEmitterFromJSONTyped(json, false); +} + +export function DetailedEventEmitterFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventEmitter { + if ((json === undefined) || (json === null)) { + return json; + } + switch (json['type']) { + case 'EntityMethod': + return {...EntityMethodEventEmitterFromJSONTyped(json, true), type: 'EntityMethod'}; + case 'PackageFunction': + return {...PackageFunctionEventEmitterFromJSONTyped(json, true), type: 'PackageFunction'}; + default: + throw new Error(`No variant of DetailedEventEmitter exists with 'type=${json['type']}'`); + } +} + +export function DetailedEventEmitterToJSON(value?: DetailedEventEmitter | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + switch (value['type']) { + case 'EntityMethod': + return EntityMethodEventEmitterToJSON(value); + case 'PackageFunction': + return PackageFunctionEventEmitterToJSON(value); + default: + throw new Error(`No variant of DetailedEventEmitter exists with 'type=${value['type']}'`); + } + +} + diff --git a/sdk/typescript/lib/generated/models/DetailedEventEmitterBase.ts b/sdk/typescript/lib/generated/models/DetailedEventEmitterBase.ts new file mode 100644 index 000000000..47e282c62 --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventEmitterBase.ts @@ -0,0 +1,73 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import type { EventEmitterType } from './EventEmitterType'; +import { + EventEmitterTypeFromJSON, + EventEmitterTypeFromJSONTyped, + EventEmitterTypeToJSON, +} from './EventEmitterType'; + +/** + * Detailed information about the event emitter. + * @export + * @interface DetailedEventEmitterBase + */ +export interface DetailedEventEmitterBase { + /** + * + * @type {EventEmitterType} + * @memberof DetailedEventEmitterBase + */ + type: EventEmitterType; +} + +/** + * Check if a given object implements the DetailedEventEmitterBase interface. + */ +export function instanceOfDetailedEventEmitterBase(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "type" in value; + + return isInstance; +} + +export function DetailedEventEmitterBaseFromJSON(json: any): DetailedEventEmitterBase { + return DetailedEventEmitterBaseFromJSONTyped(json, false); +} + +export function DetailedEventEmitterBaseFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventEmitterBase { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'type': EventEmitterTypeFromJSON(json['type']), + }; +} + +export function DetailedEventEmitterBaseToJSON(value?: DetailedEventEmitterBase | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'type': EventEmitterTypeToJSON(value.type), + }; +} + diff --git a/sdk/typescript/lib/generated/models/DetailedEventIdentifier.ts b/sdk/typescript/lib/generated/models/DetailedEventIdentifier.ts new file mode 100644 index 000000000..63faf80f8 --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventIdentifier.ts @@ -0,0 +1,87 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Identifier of an event. + * @export + * @interface DetailedEventIdentifier + */ +export interface DetailedEventIdentifier { + /** + * The address of the published package that defines the event. + +Bech32m-encoded human readable version of the address. + + * @type {string} + * @memberof DetailedEventIdentifier + */ + _package: string; + /** + * The blueprint that defines the event. + * @type {string} + * @memberof DetailedEventIdentifier + */ + blueprint: string; + /** + * Event name. + * @type {string} + * @memberof DetailedEventIdentifier + */ + event: string; +} + +/** + * Check if a given object implements the DetailedEventIdentifier interface. + */ +export function instanceOfDetailedEventIdentifier(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "_package" in value; + isInstance = isInstance && "blueprint" in value; + isInstance = isInstance && "event" in value; + + return isInstance; +} + +export function DetailedEventIdentifierFromJSON(json: any): DetailedEventIdentifier { + return DetailedEventIdentifierFromJSONTyped(json, false); +} + +export function DetailedEventIdentifierFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventIdentifier { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + '_package': json['package'], + 'blueprint': json['blueprint'], + 'event': json['event'], + }; +} + +export function DetailedEventIdentifierToJSON(value?: DetailedEventIdentifier | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'package': value._package, + 'blueprint': value.blueprint, + 'event': value.event, + }; +} + diff --git a/sdk/typescript/lib/generated/models/DetailedEventPayload.ts b/sdk/typescript/lib/generated/models/DetailedEventPayload.ts new file mode 100644 index 000000000..4a0f14907 --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventPayload.ts @@ -0,0 +1,66 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Event payload decoded into Programmatic JSON using its schema. + * @export + * @interface DetailedEventPayload + */ +export interface DetailedEventPayload { + /** + * + * @type {object} + * @memberof DetailedEventPayload + */ + programmatic_json: object; +} + +/** + * Check if a given object implements the DetailedEventPayload interface. + */ +export function instanceOfDetailedEventPayload(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "programmatic_json" in value; + + return isInstance; +} + +export function DetailedEventPayloadFromJSON(json: any): DetailedEventPayload { + return DetailedEventPayloadFromJSONTyped(json, false); +} + +export function DetailedEventPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventPayload { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'programmatic_json': json['programmatic_json'], + }; +} + +export function DetailedEventPayloadToJSON(value?: DetailedEventPayload | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'programmatic_json': value.programmatic_json, + }; +} + diff --git a/sdk/typescript/lib/generated/models/DetailedEventPayloadTypeDefinition.ts b/sdk/typescript/lib/generated/models/DetailedEventPayloadTypeDefinition.ts new file mode 100644 index 000000000..2625cb4b5 --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventPayloadTypeDefinition.ts @@ -0,0 +1,72 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { + SchemaLocalEventPayloadTypeDefinition, + instanceOfSchemaLocalEventPayloadTypeDefinition, + SchemaLocalEventPayloadTypeDefinitionFromJSON, + SchemaLocalEventPayloadTypeDefinitionFromJSONTyped, + SchemaLocalEventPayloadTypeDefinitionToJSON, +} from './SchemaLocalEventPayloadTypeDefinition'; +import { + WellKnownEventPayloadTypeDefinition, + instanceOfWellKnownEventPayloadTypeDefinition, + WellKnownEventPayloadTypeDefinitionFromJSON, + WellKnownEventPayloadTypeDefinitionFromJSONTyped, + WellKnownEventPayloadTypeDefinitionToJSON, +} from './WellKnownEventPayloadTypeDefinition'; + +/** + * @type DetailedEventPayloadTypeDefinition + * + * @export + */ +export type DetailedEventPayloadTypeDefinition = { kind: 'SchemaLocal' } & SchemaLocalEventPayloadTypeDefinition | { kind: 'WellKnown' } & WellKnownEventPayloadTypeDefinition; + +export function DetailedEventPayloadTypeDefinitionFromJSON(json: any): DetailedEventPayloadTypeDefinition { + return DetailedEventPayloadTypeDefinitionFromJSONTyped(json, false); +} + +export function DetailedEventPayloadTypeDefinitionFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventPayloadTypeDefinition { + if ((json === undefined) || (json === null)) { + return json; + } + switch (json['kind']) { + case 'SchemaLocal': + return {...SchemaLocalEventPayloadTypeDefinitionFromJSONTyped(json, true), kind: 'SchemaLocal'}; + case 'WellKnown': + return {...WellKnownEventPayloadTypeDefinitionFromJSONTyped(json, true), kind: 'WellKnown'}; + default: + throw new Error(`No variant of DetailedEventPayloadTypeDefinition exists with 'kind=${json['kind']}'`); + } +} + +export function DetailedEventPayloadTypeDefinitionToJSON(value?: DetailedEventPayloadTypeDefinition | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + switch (value['kind']) { + case 'SchemaLocal': + return SchemaLocalEventPayloadTypeDefinitionToJSON(value); + case 'WellKnown': + return WellKnownEventPayloadTypeDefinitionToJSON(value); + default: + throw new Error(`No variant of DetailedEventPayloadTypeDefinition exists with 'kind=${value['kind']}'`); + } + +} + diff --git a/sdk/typescript/lib/generated/models/DetailedEventPayloadTypeDefinitionBase.ts b/sdk/typescript/lib/generated/models/DetailedEventPayloadTypeDefinitionBase.ts new file mode 100644 index 000000000..48602873a --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventPayloadTypeDefinitionBase.ts @@ -0,0 +1,73 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import type { SborTypeKind } from './SborTypeKind'; +import { + SborTypeKindFromJSON, + SborTypeKindFromJSONTyped, + SborTypeKindToJSON, +} from './SborTypeKind'; + +/** + * Detailed information about the event's payload type. + * @export + * @interface DetailedEventPayloadTypeDefinitionBase + */ +export interface DetailedEventPayloadTypeDefinitionBase { + /** + * + * @type {SborTypeKind} + * @memberof DetailedEventPayloadTypeDefinitionBase + */ + kind: SborTypeKind; +} + +/** + * Check if a given object implements the DetailedEventPayloadTypeDefinitionBase interface. + */ +export function instanceOfDetailedEventPayloadTypeDefinitionBase(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "kind" in value; + + return isInstance; +} + +export function DetailedEventPayloadTypeDefinitionBaseFromJSON(json: any): DetailedEventPayloadTypeDefinitionBase { + return DetailedEventPayloadTypeDefinitionBaseFromJSONTyped(json, false); +} + +export function DetailedEventPayloadTypeDefinitionBaseFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventPayloadTypeDefinitionBase { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'kind': SborTypeKindFromJSON(json['kind']), + }; +} + +export function DetailedEventPayloadTypeDefinitionBaseToJSON(value?: DetailedEventPayloadTypeDefinitionBase | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'kind': SborTypeKindToJSON(value.kind), + }; +} + diff --git a/sdk/typescript/lib/generated/models/DetailedEventsItem.ts b/sdk/typescript/lib/generated/models/DetailedEventsItem.ts new file mode 100644 index 000000000..f53a7c2e2 --- /dev/null +++ b/sdk/typescript/lib/generated/models/DetailedEventsItem.ts @@ -0,0 +1,118 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import type { DetailedEventEmitter } from './DetailedEventEmitter'; +import { + DetailedEventEmitterFromJSON, + DetailedEventEmitterFromJSONTyped, + DetailedEventEmitterToJSON, +} from './DetailedEventEmitter'; +import type { DetailedEventIdentifier } from './DetailedEventIdentifier'; +import { + DetailedEventIdentifierFromJSON, + DetailedEventIdentifierFromJSONTyped, + DetailedEventIdentifierToJSON, +} from './DetailedEventIdentifier'; +import type { DetailedEventPayload } from './DetailedEventPayload'; +import { + DetailedEventPayloadFromJSON, + DetailedEventPayloadFromJSONTyped, + DetailedEventPayloadToJSON, +} from './DetailedEventPayload'; +import type { DetailedEventPayloadTypeDefinition } from './DetailedEventPayloadTypeDefinition'; +import { + DetailedEventPayloadTypeDefinitionFromJSON, + DetailedEventPayloadTypeDefinitionFromJSONTyped, + DetailedEventPayloadTypeDefinitionToJSON, +} from './DetailedEventPayloadTypeDefinition'; + +/** + * + * @export + * @interface DetailedEventsItem + */ +export interface DetailedEventsItem { + /** + * + * @type {DetailedEventIdentifier} + * @memberof DetailedEventsItem + */ + identifier: DetailedEventIdentifier; + /** + * + * @type {DetailedEventPayloadTypeDefinition} + * @memberof DetailedEventsItem + */ + payload_type_definition: DetailedEventPayloadTypeDefinition; + /** + * + * @type {DetailedEventEmitter} + * @memberof DetailedEventsItem + */ + emitter: DetailedEventEmitter; + /** + * + * @type {DetailedEventPayload} + * @memberof DetailedEventsItem + */ + payload: DetailedEventPayload; +} + +/** + * Check if a given object implements the DetailedEventsItem interface. + */ +export function instanceOfDetailedEventsItem(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "identifier" in value; + isInstance = isInstance && "payload_type_definition" in value; + isInstance = isInstance && "emitter" in value; + isInstance = isInstance && "payload" in value; + + return isInstance; +} + +export function DetailedEventsItemFromJSON(json: any): DetailedEventsItem { + return DetailedEventsItemFromJSONTyped(json, false); +} + +export function DetailedEventsItemFromJSONTyped(json: any, ignoreDiscriminator: boolean): DetailedEventsItem { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'identifier': DetailedEventIdentifierFromJSON(json['identifier']), + 'payload_type_definition': DetailedEventPayloadTypeDefinitionFromJSON(json['payload_type_definition']), + 'emitter': DetailedEventEmitterFromJSON(json['emitter']), + 'payload': DetailedEventPayloadFromJSON(json['payload']), + }; +} + +export function DetailedEventsItemToJSON(value?: DetailedEventsItem | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'identifier': DetailedEventIdentifierToJSON(value.identifier), + 'payload_type_definition': DetailedEventPayloadTypeDefinitionToJSON(value.payload_type_definition), + 'emitter': DetailedEventEmitterToJSON(value.emitter), + 'payload': DetailedEventPayloadToJSON(value.payload), + }; +} + diff --git a/sdk/typescript/lib/generated/models/EntityMethodEventEmitter.ts b/sdk/typescript/lib/generated/models/EntityMethodEventEmitter.ts new file mode 100644 index 000000000..93e99a6ee --- /dev/null +++ b/sdk/typescript/lib/generated/models/EntityMethodEventEmitter.ts @@ -0,0 +1,115 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import type { MethodEmitter } from './MethodEmitter'; +import { + MethodEmitterFromJSON, + MethodEmitterFromJSONTyped, + MethodEmitterToJSON, +} from './MethodEmitter'; + +/** + * Details of the entity method's event emitter. + * @export + * @interface EntityMethodEventEmitter + */ +export interface EntityMethodEventEmitter { + /** + * + * @type {MethodEmitter} + * @memberof EntityMethodEventEmitter + */ + method_emitter: MethodEmitter; + /** + * The address of the outer object of the emitter. For example, for events emitted by vaults, this will be the resource address; for events emitted by validators, it will be the consensus manager address. + +Bech32m-encoded human readable version of the address. + + * @type {string} + * @memberof EntityMethodEventEmitter + */ + outer_emitter?: string; + /** + * The address of the global ancestor of the entity emitting the event (self if the entity emitting the event is global). + +Bech32m-encoded human readable version of the address. + + * @type {string} + * @memberof EntityMethodEventEmitter + */ + global_emitter: string; + /** + * + * @type {string} + * @memberof EntityMethodEventEmitter + */ + type: EntityMethodEventEmitterTypeEnum; +} + + +/** + * @export + */ +export const EntityMethodEventEmitterTypeEnum = { + EntityMethod: 'EntityMethod' +} as const; +export type EntityMethodEventEmitterTypeEnum = typeof EntityMethodEventEmitterTypeEnum[keyof typeof EntityMethodEventEmitterTypeEnum]; + + +/** + * Check if a given object implements the EntityMethodEventEmitter interface. + */ +export function instanceOfEntityMethodEventEmitter(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "method_emitter" in value; + isInstance = isInstance && "global_emitter" in value; + isInstance = isInstance && "type" in value; + + return isInstance; +} + +export function EntityMethodEventEmitterFromJSON(json: any): EntityMethodEventEmitter { + return EntityMethodEventEmitterFromJSONTyped(json, false); +} + +export function EntityMethodEventEmitterFromJSONTyped(json: any, ignoreDiscriminator: boolean): EntityMethodEventEmitter { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'method_emitter': MethodEmitterFromJSON(json['method_emitter']), + 'outer_emitter': !exists(json, 'outer_emitter') ? undefined : json['outer_emitter'], + 'global_emitter': json['global_emitter'], + 'type': json['type'], + }; +} + +export function EntityMethodEventEmitterToJSON(value?: EntityMethodEventEmitter | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'method_emitter': MethodEmitterToJSON(value.method_emitter), + 'outer_emitter': value.outer_emitter, + 'global_emitter': value.global_emitter, + 'type': value.type, + }; +} + diff --git a/sdk/typescript/lib/generated/models/EntityMethodEventEmitterAllOf.ts b/sdk/typescript/lib/generated/models/EntityMethodEventEmitterAllOf.ts new file mode 100644 index 000000000..9ff2ae4d3 --- /dev/null +++ b/sdk/typescript/lib/generated/models/EntityMethodEventEmitterAllOf.ts @@ -0,0 +1,75 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface EntityMethodEventEmitterAllOf + */ +export interface EntityMethodEventEmitterAllOf { + /** + * + * @type {string} + * @memberof EntityMethodEventEmitterAllOf + */ + type?: EntityMethodEventEmitterAllOfTypeEnum; +} + + +/** + * @export + */ +export const EntityMethodEventEmitterAllOfTypeEnum = { + EntityMethod: 'EntityMethod' +} as const; +export type EntityMethodEventEmitterAllOfTypeEnum = typeof EntityMethodEventEmitterAllOfTypeEnum[keyof typeof EntityMethodEventEmitterAllOfTypeEnum]; + + +/** + * Check if a given object implements the EntityMethodEventEmitterAllOf interface. + */ +export function instanceOfEntityMethodEventEmitterAllOf(value: object): boolean { + let isInstance = true; + + return isInstance; +} + +export function EntityMethodEventEmitterAllOfFromJSON(json: any): EntityMethodEventEmitterAllOf { + return EntityMethodEventEmitterAllOfFromJSONTyped(json, false); +} + +export function EntityMethodEventEmitterAllOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): EntityMethodEventEmitterAllOf { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'type': !exists(json, 'type') ? undefined : json['type'], + }; +} + +export function EntityMethodEventEmitterAllOfToJSON(value?: EntityMethodEventEmitterAllOf | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'type': value.type, + }; +} + diff --git a/sdk/typescript/lib/generated/models/EventEmitterType.ts b/sdk/typescript/lib/generated/models/EventEmitterType.ts new file mode 100644 index 000000000..6ff818520 --- /dev/null +++ b/sdk/typescript/lib/generated/models/EventEmitterType.ts @@ -0,0 +1,38 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +/** + * + * @export + */ +export const EventEmitterType = { + EntityMethod: 'EntityMethod', + PackageFunction: 'PackageFunction' +} as const; +export type EventEmitterType = typeof EventEmitterType[keyof typeof EventEmitterType]; + + +export function EventEmitterTypeFromJSON(json: any): EventEmitterType { + return EventEmitterTypeFromJSONTyped(json, false); +} + +export function EventEmitterTypeFromJSONTyped(json: any, ignoreDiscriminator: boolean): EventEmitterType { + return json as EventEmitterType; +} + +export function EventEmitterTypeToJSON(value?: EventEmitterType | null): any { + return value as any; +} + diff --git a/sdk/typescript/lib/generated/models/FunctionEmitter.ts b/sdk/typescript/lib/generated/models/FunctionEmitter.ts new file mode 100644 index 000000000..6116b4445 --- /dev/null +++ b/sdk/typescript/lib/generated/models/FunctionEmitter.ts @@ -0,0 +1,66 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Details of the blueprint function that emitted the event. + * @export + * @interface FunctionEmitter + */ +export interface FunctionEmitter { + /** + * + * @type {string} + * @memberof FunctionEmitter + */ + blueprint: string; +} + +/** + * Check if a given object implements the FunctionEmitter interface. + */ +export function instanceOfFunctionEmitter(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "blueprint" in value; + + return isInstance; +} + +export function FunctionEmitterFromJSON(json: any): FunctionEmitter { + return FunctionEmitterFromJSONTyped(json, false); +} + +export function FunctionEmitterFromJSONTyped(json: any, ignoreDiscriminator: boolean): FunctionEmitter { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'blueprint': json['blueprint'], + }; +} + +export function FunctionEmitterToJSON(value?: FunctionEmitter | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'blueprint': value.blueprint, + }; +} + diff --git a/sdk/typescript/lib/generated/models/MethodEmitter.ts b/sdk/typescript/lib/generated/models/MethodEmitter.ts new file mode 100644 index 000000000..5bc80f4c3 --- /dev/null +++ b/sdk/typescript/lib/generated/models/MethodEmitter.ts @@ -0,0 +1,75 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Details of the component module method that emitted the event. + * @export + * @interface MethodEmitter + */ +export interface MethodEmitter { + /** + * Bech32m-encoded human readable version of the address. + * @type {string} + * @memberof MethodEmitter + */ + entity: string; + /** + * + * @type {string} + * @memberof MethodEmitter + */ + module: string; +} + +/** + * Check if a given object implements the MethodEmitter interface. + */ +export function instanceOfMethodEmitter(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "entity" in value; + isInstance = isInstance && "module" in value; + + return isInstance; +} + +export function MethodEmitterFromJSON(json: any): MethodEmitter { + return MethodEmitterFromJSONTyped(json, false); +} + +export function MethodEmitterFromJSONTyped(json: any, ignoreDiscriminator: boolean): MethodEmitter { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'entity': json['entity'], + 'module': json['module'], + }; +} + +export function MethodEmitterToJSON(value?: MethodEmitter | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'entity': value.entity, + 'module': value.module, + }; +} + diff --git a/sdk/typescript/lib/generated/models/PackageFunctionEventEmitter.ts b/sdk/typescript/lib/generated/models/PackageFunctionEventEmitter.ts new file mode 100644 index 000000000..b2c2255ba --- /dev/null +++ b/sdk/typescript/lib/generated/models/PackageFunctionEventEmitter.ts @@ -0,0 +1,92 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import type { FunctionEmitter } from './FunctionEmitter'; +import { + FunctionEmitterFromJSON, + FunctionEmitterFromJSONTyped, + FunctionEmitterToJSON, +} from './FunctionEmitter'; + +/** + * Details of the package function's event emitter. + * @export + * @interface PackageFunctionEventEmitter + */ +export interface PackageFunctionEventEmitter { + /** + * + * @type {FunctionEmitter} + * @memberof PackageFunctionEventEmitter + */ + function_emitter: FunctionEmitter; + /** + * + * @type {string} + * @memberof PackageFunctionEventEmitter + */ + type: PackageFunctionEventEmitterTypeEnum; +} + + +/** + * @export + */ +export const PackageFunctionEventEmitterTypeEnum = { + PackageFunction: 'PackageFunction' +} as const; +export type PackageFunctionEventEmitterTypeEnum = typeof PackageFunctionEventEmitterTypeEnum[keyof typeof PackageFunctionEventEmitterTypeEnum]; + + +/** + * Check if a given object implements the PackageFunctionEventEmitter interface. + */ +export function instanceOfPackageFunctionEventEmitter(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "function_emitter" in value; + isInstance = isInstance && "type" in value; + + return isInstance; +} + +export function PackageFunctionEventEmitterFromJSON(json: any): PackageFunctionEventEmitter { + return PackageFunctionEventEmitterFromJSONTyped(json, false); +} + +export function PackageFunctionEventEmitterFromJSONTyped(json: any, ignoreDiscriminator: boolean): PackageFunctionEventEmitter { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'function_emitter': FunctionEmitterFromJSON(json['function_emitter']), + 'type': json['type'], + }; +} + +export function PackageFunctionEventEmitterToJSON(value?: PackageFunctionEventEmitter | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'function_emitter': FunctionEmitterToJSON(value.function_emitter), + 'type': value.type, + }; +} + diff --git a/sdk/typescript/lib/generated/models/PackageFunctionEventEmitterAllOf.ts b/sdk/typescript/lib/generated/models/PackageFunctionEventEmitterAllOf.ts new file mode 100644 index 000000000..6e7a91f0b --- /dev/null +++ b/sdk/typescript/lib/generated/models/PackageFunctionEventEmitterAllOf.ts @@ -0,0 +1,75 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface PackageFunctionEventEmitterAllOf + */ +export interface PackageFunctionEventEmitterAllOf { + /** + * + * @type {string} + * @memberof PackageFunctionEventEmitterAllOf + */ + type?: PackageFunctionEventEmitterAllOfTypeEnum; +} + + +/** + * @export + */ +export const PackageFunctionEventEmitterAllOfTypeEnum = { + PackageFunction: 'PackageFunction' +} as const; +export type PackageFunctionEventEmitterAllOfTypeEnum = typeof PackageFunctionEventEmitterAllOfTypeEnum[keyof typeof PackageFunctionEventEmitterAllOfTypeEnum]; + + +/** + * Check if a given object implements the PackageFunctionEventEmitterAllOf interface. + */ +export function instanceOfPackageFunctionEventEmitterAllOf(value: object): boolean { + let isInstance = true; + + return isInstance; +} + +export function PackageFunctionEventEmitterAllOfFromJSON(json: any): PackageFunctionEventEmitterAllOf { + return PackageFunctionEventEmitterAllOfFromJSONTyped(json, false); +} + +export function PackageFunctionEventEmitterAllOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): PackageFunctionEventEmitterAllOf { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'type': !exists(json, 'type') ? undefined : json['type'], + }; +} + +export function PackageFunctionEventEmitterAllOfToJSON(value?: PackageFunctionEventEmitterAllOf | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'type': value.type, + }; +} + diff --git a/sdk/typescript/lib/generated/models/SborTypeKind.ts b/sdk/typescript/lib/generated/models/SborTypeKind.ts new file mode 100644 index 000000000..4097d81e4 --- /dev/null +++ b/sdk/typescript/lib/generated/models/SborTypeKind.ts @@ -0,0 +1,38 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +/** + * + * @export + */ +export const SborTypeKind = { + SchemaLocal: 'SchemaLocal', + WellKnown: 'WellKnown' +} as const; +export type SborTypeKind = typeof SborTypeKind[keyof typeof SborTypeKind]; + + +export function SborTypeKindFromJSON(json: any): SborTypeKind { + return SborTypeKindFromJSONTyped(json, false); +} + +export function SborTypeKindFromJSONTyped(json: any, ignoreDiscriminator: boolean): SborTypeKind { + return json as SborTypeKind; +} + +export function SborTypeKindToJSON(value?: SborTypeKind | null): any { + return value as any; +} + diff --git a/sdk/typescript/lib/generated/models/SchemaLocalEventPayloadTypeDefinition.ts b/sdk/typescript/lib/generated/models/SchemaLocalEventPayloadTypeDefinition.ts new file mode 100644 index 000000000..64c17d4f1 --- /dev/null +++ b/sdk/typescript/lib/generated/models/SchemaLocalEventPayloadTypeDefinition.ts @@ -0,0 +1,103 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Reference to a local schema type that defines the schema of an event. + * @export + * @interface SchemaLocalEventPayloadTypeDefinition + */ +export interface SchemaLocalEventPayloadTypeDefinition { + /** + * + * @type {string} + * @memberof SchemaLocalEventPayloadTypeDefinition + */ + kind: SchemaLocalEventPayloadTypeDefinitionKindEnum; + /** + * + * @type {number} + * @memberof SchemaLocalEventPayloadTypeDefinition + */ + local_type_id: number; + /** + * Bech32m-encoded human readable version of the address. + * @type {string} + * @memberof SchemaLocalEventPayloadTypeDefinition + */ + entity: string; + /** + * Hex-encoded binary blob. + * @type {string} + * @memberof SchemaLocalEventPayloadTypeDefinition + */ + schema_hash_hex: string; +} + + +/** + * @export + */ +export const SchemaLocalEventPayloadTypeDefinitionKindEnum = { + SchemaLocal: 'SchemaLocal' +} as const; +export type SchemaLocalEventPayloadTypeDefinitionKindEnum = typeof SchemaLocalEventPayloadTypeDefinitionKindEnum[keyof typeof SchemaLocalEventPayloadTypeDefinitionKindEnum]; + + +/** + * Check if a given object implements the SchemaLocalEventPayloadTypeDefinition interface. + */ +export function instanceOfSchemaLocalEventPayloadTypeDefinition(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "kind" in value; + isInstance = isInstance && "local_type_id" in value; + isInstance = isInstance && "entity" in value; + isInstance = isInstance && "schema_hash_hex" in value; + + return isInstance; +} + +export function SchemaLocalEventPayloadTypeDefinitionFromJSON(json: any): SchemaLocalEventPayloadTypeDefinition { + return SchemaLocalEventPayloadTypeDefinitionFromJSONTyped(json, false); +} + +export function SchemaLocalEventPayloadTypeDefinitionFromJSONTyped(json: any, ignoreDiscriminator: boolean): SchemaLocalEventPayloadTypeDefinition { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'kind': json['kind'], + 'local_type_id': json['local_type_id'], + 'entity': json['entity'], + 'schema_hash_hex': json['schema_hash_hex'], + }; +} + +export function SchemaLocalEventPayloadTypeDefinitionToJSON(value?: SchemaLocalEventPayloadTypeDefinition | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'kind': value.kind, + 'local_type_id': value.local_type_id, + 'entity': value.entity, + 'schema_hash_hex': value.schema_hash_hex, + }; +} + diff --git a/sdk/typescript/lib/generated/models/SchemaLocalEventPayloadTypeDefinitionAllOf.ts b/sdk/typescript/lib/generated/models/SchemaLocalEventPayloadTypeDefinitionAllOf.ts new file mode 100644 index 000000000..72c4a0248 --- /dev/null +++ b/sdk/typescript/lib/generated/models/SchemaLocalEventPayloadTypeDefinitionAllOf.ts @@ -0,0 +1,102 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface SchemaLocalEventPayloadTypeDefinitionAllOf + */ +export interface SchemaLocalEventPayloadTypeDefinitionAllOf { + /** + * + * @type {number} + * @memberof SchemaLocalEventPayloadTypeDefinitionAllOf + */ + local_type_id: number; + /** + * Bech32m-encoded human readable version of the address. + * @type {string} + * @memberof SchemaLocalEventPayloadTypeDefinitionAllOf + */ + entity: string; + /** + * Hex-encoded binary blob. + * @type {string} + * @memberof SchemaLocalEventPayloadTypeDefinitionAllOf + */ + schema_hash_hex: string; + /** + * + * @type {string} + * @memberof SchemaLocalEventPayloadTypeDefinitionAllOf + */ + kind?: SchemaLocalEventPayloadTypeDefinitionAllOfKindEnum; +} + + +/** + * @export + */ +export const SchemaLocalEventPayloadTypeDefinitionAllOfKindEnum = { + SchemaLocal: 'SchemaLocal' +} as const; +export type SchemaLocalEventPayloadTypeDefinitionAllOfKindEnum = typeof SchemaLocalEventPayloadTypeDefinitionAllOfKindEnum[keyof typeof SchemaLocalEventPayloadTypeDefinitionAllOfKindEnum]; + + +/** + * Check if a given object implements the SchemaLocalEventPayloadTypeDefinitionAllOf interface. + */ +export function instanceOfSchemaLocalEventPayloadTypeDefinitionAllOf(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "local_type_id" in value; + isInstance = isInstance && "entity" in value; + isInstance = isInstance && "schema_hash_hex" in value; + + return isInstance; +} + +export function SchemaLocalEventPayloadTypeDefinitionAllOfFromJSON(json: any): SchemaLocalEventPayloadTypeDefinitionAllOf { + return SchemaLocalEventPayloadTypeDefinitionAllOfFromJSONTyped(json, false); +} + +export function SchemaLocalEventPayloadTypeDefinitionAllOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): SchemaLocalEventPayloadTypeDefinitionAllOf { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'local_type_id': json['local_type_id'], + 'entity': json['entity'], + 'schema_hash_hex': json['schema_hash_hex'], + 'kind': !exists(json, 'kind') ? undefined : json['kind'], + }; +} + +export function SchemaLocalEventPayloadTypeDefinitionAllOfToJSON(value?: SchemaLocalEventPayloadTypeDefinitionAllOf | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'local_type_id': value.local_type_id, + 'entity': value.entity, + 'schema_hash_hex': value.schema_hash_hex, + 'kind': value.kind, + }; +} + diff --git a/sdk/typescript/lib/generated/models/TransactionDetailsOptIns.ts b/sdk/typescript/lib/generated/models/TransactionDetailsOptIns.ts index 10875bd8f..55ada0826 100644 --- a/sdk/typescript/lib/generated/models/TransactionDetailsOptIns.ts +++ b/sdk/typescript/lib/generated/models/TransactionDetailsOptIns.ts @@ -56,11 +56,21 @@ export interface TransactionDetailsOptIns { */ receipt_costing_parameters?: boolean; /** - * if set to `true`, events inside receipt object is returned. + * if set to `true`, events inside receipt object is returned. Please use the `detailed_events` instead, as it provides an enriched model with context and additional data. * @type {boolean} * @memberof TransactionDetailsOptIns + * @deprecated */ receipt_events?: boolean; + /** + * if set to `true`, detailed events object is returned. + +For more information please visit [Detailed Eevents docs](#section/Detailed-Events-Explained). + + * @type {boolean} + * @memberof TransactionDetailsOptIns + */ + detailed_events?: boolean; /** * (true by default) if set to `true`, transaction receipt output is returned. * @type {boolean} @@ -116,6 +126,7 @@ export function TransactionDetailsOptInsFromJSONTyped(json: any, ignoreDiscrimin 'receipt_fee_destination': !exists(json, 'receipt_fee_destination') ? undefined : json['receipt_fee_destination'], 'receipt_costing_parameters': !exists(json, 'receipt_costing_parameters') ? undefined : json['receipt_costing_parameters'], 'receipt_events': !exists(json, 'receipt_events') ? undefined : json['receipt_events'], + 'detailed_events': !exists(json, 'detailed_events') ? undefined : json['detailed_events'], 'receipt_output': !exists(json, 'receipt_output') ? undefined : json['receipt_output'], 'affected_global_entities': !exists(json, 'affected_global_entities') ? undefined : json['affected_global_entities'], 'manifest_instructions': !exists(json, 'manifest_instructions') ? undefined : json['manifest_instructions'], @@ -139,6 +150,7 @@ export function TransactionDetailsOptInsToJSON(value?: TransactionDetailsOptIns 'receipt_fee_destination': value.receipt_fee_destination, 'receipt_costing_parameters': value.receipt_costing_parameters, 'receipt_events': value.receipt_events, + 'detailed_events': value.detailed_events, 'receipt_output': value.receipt_output, 'affected_global_entities': value.affected_global_entities, 'manifest_instructions': value.manifest_instructions, diff --git a/sdk/typescript/lib/generated/models/TransactionReceipt.ts b/sdk/typescript/lib/generated/models/TransactionReceipt.ts index a691607e6..9c79adabf 100644 --- a/sdk/typescript/lib/generated/models/TransactionReceipt.ts +++ b/sdk/typescript/lib/generated/models/TransactionReceipt.ts @@ -13,6 +13,12 @@ */ import { exists, mapValues } from '../runtime'; +import type { DetailedEventsItem } from './DetailedEventsItem'; +import { + DetailedEventsItemFromJSON, + DetailedEventsItemFromJSONTyped, + DetailedEventsItemToJSON, +} from './DetailedEventsItem'; import type { EventsItem } from './EventsItem'; import { EventsItemFromJSON, @@ -89,11 +95,21 @@ This type is defined in the Core API as `SborData`. See the Core API documentati */ output?: object; /** - * Events emitted by a transaction. + * Events emitted by a transaction. Please use the `detailed_events` instead, as it provides an enriched model with context and additional data. * @type {Array} * @memberof TransactionReceipt + * @deprecated */ events?: Array; + /** + * Events emitted by a transaction, enriched with additional context and data. + +For more information please visit [Detailed Eevents docs](#section/Detailed-Events-Explained). + + * @type {Array} + * @memberof TransactionReceipt + */ + detailed_events?: Array; /** * Error message (only present if status is `Failed` or `Rejected`) * @type {string} @@ -130,6 +146,7 @@ export function TransactionReceiptFromJSONTyped(json: any, ignoreDiscriminator: 'next_epoch': !exists(json, 'next_epoch') ? undefined : json['next_epoch'], 'output': !exists(json, 'output') ? undefined : json['output'], 'events': !exists(json, 'events') ? undefined : ((json['events'] as Array).map(EventsItemFromJSON)), + 'detailed_events': !exists(json, 'detailed_events') ? undefined : ((json['detailed_events'] as Array).map(DetailedEventsItemFromJSON)), 'error_message': !exists(json, 'error_message') ? undefined : json['error_message'], }; } @@ -152,6 +169,7 @@ export function TransactionReceiptToJSON(value?: TransactionReceipt | null): any 'next_epoch': value.next_epoch, 'output': value.output, 'events': value.events === undefined ? undefined : ((value.events as Array).map(EventsItemToJSON)), + 'detailed_events': value.detailed_events === undefined ? undefined : ((value.detailed_events as Array).map(DetailedEventsItemToJSON)), 'error_message': value.error_message, }; } diff --git a/sdk/typescript/lib/generated/models/WellKnownEventPayloadTypeDefinition.ts b/sdk/typescript/lib/generated/models/WellKnownEventPayloadTypeDefinition.ts new file mode 100644 index 000000000..63b7a88e5 --- /dev/null +++ b/sdk/typescript/lib/generated/models/WellKnownEventPayloadTypeDefinition.ts @@ -0,0 +1,85 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * Reference to a well-known type that defines the schema of an event. + * @export + * @interface WellKnownEventPayloadTypeDefinition + */ +export interface WellKnownEventPayloadTypeDefinition { + /** + * + * @type {string} + * @memberof WellKnownEventPayloadTypeDefinition + */ + kind: WellKnownEventPayloadTypeDefinitionKindEnum; + /** + * + * @type {number} + * @memberof WellKnownEventPayloadTypeDefinition + */ + well_known_type_id: number; +} + + +/** + * @export + */ +export const WellKnownEventPayloadTypeDefinitionKindEnum = { + WellKnown: 'WellKnown' +} as const; +export type WellKnownEventPayloadTypeDefinitionKindEnum = typeof WellKnownEventPayloadTypeDefinitionKindEnum[keyof typeof WellKnownEventPayloadTypeDefinitionKindEnum]; + + +/** + * Check if a given object implements the WellKnownEventPayloadTypeDefinition interface. + */ +export function instanceOfWellKnownEventPayloadTypeDefinition(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "kind" in value; + isInstance = isInstance && "well_known_type_id" in value; + + return isInstance; +} + +export function WellKnownEventPayloadTypeDefinitionFromJSON(json: any): WellKnownEventPayloadTypeDefinition { + return WellKnownEventPayloadTypeDefinitionFromJSONTyped(json, false); +} + +export function WellKnownEventPayloadTypeDefinitionFromJSONTyped(json: any, ignoreDiscriminator: boolean): WellKnownEventPayloadTypeDefinition { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'kind': json['kind'], + 'well_known_type_id': json['well_known_type_id'], + }; +} + +export function WellKnownEventPayloadTypeDefinitionToJSON(value?: WellKnownEventPayloadTypeDefinition | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'kind': value.kind, + 'well_known_type_id': value.well_known_type_id, + }; +} + diff --git a/sdk/typescript/lib/generated/models/WellKnownEventPayloadTypeDefinitionAllOf.ts b/sdk/typescript/lib/generated/models/WellKnownEventPayloadTypeDefinitionAllOf.ts new file mode 100644 index 000000000..f4c6f7baf --- /dev/null +++ b/sdk/typescript/lib/generated/models/WellKnownEventPayloadTypeDefinitionAllOf.ts @@ -0,0 +1,84 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Radix Gateway API - Babylon + * This API is exposed by the Babylon Radix Gateway to enable clients to efficiently query current and historic state on the RadixDLT ledger, and intelligently handle transaction submission. It is designed for use by wallets and explorers, and for light queries from front-end dApps. For exchange/asset integrations, back-end dApp integrations, or simple use cases, you should consider using the Core API on a Node. A Gateway is only needed for reading historic snapshots of ledger states or a more robust set-up. The Gateway API is implemented by the [Network Gateway](https://github.com/radixdlt/babylon-gateway), which is configured to read from [full node(s)](https://github.com/radixdlt/babylon-node) to extract and index data from the network. This document is an API reference documentation, visit [User Guide](https://docs.radixdlt.com/) to learn more about how to run a Gateway of your own. ## Migration guide Please see [the latest release notes](https://github.com/radixdlt/babylon-gateway/releases). ## Integration and forward compatibility guarantees All responses may have additional fields added at any release, so clients are advised to use JSON parsers which ignore unknown fields on JSON objects. When the Radix protocol is updated, new functionality may be added, and so discriminated unions returned by the API may need to be updated to have new variants added, corresponding to the updated data. Clients may need to update in advance to be able to handle these new variants when a protocol update comes out. On the very rare occasions we need to make breaking changes to the API, these will be warned in advance with deprecation notices on previous versions. These deprecation notices will include a safe migration path. Deprecation notes or breaking changes will be flagged clearly in release notes for new versions of the Gateway. The Gateway DB schema is not subject to any compatibility guarantees, and may be changed at any release. DB changes will be flagged in the release notes so clients doing custom DB integrations can prepare. + * + * The version of the OpenAPI document: v1.10.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface WellKnownEventPayloadTypeDefinitionAllOf + */ +export interface WellKnownEventPayloadTypeDefinitionAllOf { + /** + * + * @type {number} + * @memberof WellKnownEventPayloadTypeDefinitionAllOf + */ + well_known_type_id: number; + /** + * + * @type {string} + * @memberof WellKnownEventPayloadTypeDefinitionAllOf + */ + kind?: WellKnownEventPayloadTypeDefinitionAllOfKindEnum; +} + + +/** + * @export + */ +export const WellKnownEventPayloadTypeDefinitionAllOfKindEnum = { + WellKnown: 'WellKnown' +} as const; +export type WellKnownEventPayloadTypeDefinitionAllOfKindEnum = typeof WellKnownEventPayloadTypeDefinitionAllOfKindEnum[keyof typeof WellKnownEventPayloadTypeDefinitionAllOfKindEnum]; + + +/** + * Check if a given object implements the WellKnownEventPayloadTypeDefinitionAllOf interface. + */ +export function instanceOfWellKnownEventPayloadTypeDefinitionAllOf(value: object): boolean { + let isInstance = true; + isInstance = isInstance && "well_known_type_id" in value; + + return isInstance; +} + +export function WellKnownEventPayloadTypeDefinitionAllOfFromJSON(json: any): WellKnownEventPayloadTypeDefinitionAllOf { + return WellKnownEventPayloadTypeDefinitionAllOfFromJSONTyped(json, false); +} + +export function WellKnownEventPayloadTypeDefinitionAllOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): WellKnownEventPayloadTypeDefinitionAllOf { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'well_known_type_id': json['well_known_type_id'], + 'kind': !exists(json, 'kind') ? undefined : json['kind'], + }; +} + +export function WellKnownEventPayloadTypeDefinitionAllOfToJSON(value?: WellKnownEventPayloadTypeDefinitionAllOf | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'well_known_type_id': value.well_known_type_id, + 'kind': value.kind, + }; +} + diff --git a/sdk/typescript/lib/generated/models/index.ts b/sdk/typescript/lib/generated/models/index.ts index d1a0d8254..adbe7e238 100644 --- a/sdk/typescript/lib/generated/models/index.ts +++ b/sdk/typescript/lib/generated/models/index.ts @@ -54,19 +54,30 @@ export * from './ComponentEntityRoleAssignments'; export * from './ComponentMethodRoyalty'; export * from './ComponentRoyaltyConfig'; export * from './CursorLimitMixin'; +export * from './DetailedEventEmitter'; +export * from './DetailedEventEmitterBase'; +export * from './DetailedEventIdentifier'; +export * from './DetailedEventPayload'; +export * from './DetailedEventPayloadTypeDefinition'; +export * from './DetailedEventPayloadTypeDefinitionBase'; +export * from './DetailedEventsItem'; export * from './EntityMetadataCollection'; export * from './EntityMetadataCollectionAllOf'; export * from './EntityMetadataItem'; export * from './EntityMetadataItemValue'; export * from './EntityMetadataItemValueAllOf'; +export * from './EntityMethodEventEmitter'; +export * from './EntityMethodEventEmitterAllOf'; export * from './EntityNotFoundError'; export * from './EntityNotFoundErrorAllOf'; export * from './EntitySchemaCollection'; export * from './EntitySchemaCollectionAllOf'; export * from './EntitySchemaCollectionItem'; export * from './ErrorResponse'; +export * from './EventEmitterType'; export * from './EventsItem'; export * from './FromLedgerStateMixin'; +export * from './FunctionEmitter'; export * from './FungibleResourcesCollection'; export * from './FungibleResourcesCollectionAllOf'; export * from './FungibleResourcesCollectionItem'; @@ -164,6 +175,7 @@ export * from './MetadataUrlArrayValueAllOf'; export * from './MetadataUrlValue'; export * from './MetadataUrlValueAllOf'; export * from './MetadataValueType'; +export * from './MethodEmitter'; export * from './NativeResourceAccessControllerRecoveryBadgeValue'; export * from './NativeResourceAccessControllerRecoveryBadgeValueAllOf'; export * from './NativeResourceAccountOwnerBadgeValue'; @@ -228,6 +240,8 @@ export * from './PackageBlueprintCollectionItem'; export * from './PackageCodeCollection'; export * from './PackageCodeCollectionAllOf'; export * from './PackageCodeCollectionItem'; +export * from './PackageFunctionEventEmitter'; +export * from './PackageFunctionEventEmitterAllOf'; export * from './PackageVmType'; export * from './PreviewFlags'; export * from './PreviewTransaction'; @@ -312,6 +326,9 @@ export * from './ResultSetCursorMixin'; export * from './RoleAssignmentResolution'; export * from './RoleKey'; export * from './RoyaltyAmount'; +export * from './SborTypeKind'; +export * from './SchemaLocalEventPayloadTypeDefinition'; +export * from './SchemaLocalEventPayloadTypeDefinitionAllOf'; export * from './ScryptoSborValue'; export * from './StateAccountAuthorizedDepositorsPageRequest'; export * from './StateAccountAuthorizedDepositorsPageResponse'; @@ -470,3 +487,5 @@ export * from './ValidatorsUptimeRequest'; export * from './ValidatorsUptimeRequestAllOf'; export * from './ValidatorsUptimeResponse'; export * from './ValidatorsUptimeResponseAllOf'; +export * from './WellKnownEventPayloadTypeDefinition'; +export * from './WellKnownEventPayloadTypeDefinitionAllOf';