diff --git a/packages/data-store/src/__tests__/xstate.store.test.ts b/packages/data-store/src/__tests__/xstate.store.test.ts index fd669e8d8..65320f9fe 100644 --- a/packages/data-store/src/__tests__/xstate.store.test.ts +++ b/packages/data-store/src/__tests__/xstate.store.test.ts @@ -1,5 +1,12 @@ import { DataSource } from 'typeorm' -import { DataStoreXStateStoreEntities, GetActiveStateArgs, NonPersistedXStateStoreEvent, SaveStateArgs, State, XStateStore } from '../index' +import { + DataStoreXStateStoreEntities, + GetActiveStateArgs, + NonPersistedXStateStoreEvent, + SaveStateArgs, + State, + XStateStore, +} from '../index' import { DataStoreXStateStoreMigrations } from '../migrations' describe('Database entities tests', (): void => { diff --git a/packages/event-logger/src/agent/EventLogger.ts b/packages/event-logger/src/agent/EventLogger.ts index f8a3e7876..3b67f14d2 100644 --- a/packages/event-logger/src/agent/EventLogger.ts +++ b/packages/event-logger/src/agent/EventLogger.ts @@ -1,7 +1,6 @@ import { IAgentPlugin } from '@veramo/core' import { AbstractEventLoggerStore } from '@sphereon/ssi-sdk.data-store' import { AuditLoggingEvent, LoggingEventType, LogLevel } from '@sphereon/ssi-sdk.core' -import { IEventListener } from '@veramo/core/src/types/IAgent' import { v4 as uuidv4 } from 'uuid' import { schema } from '../index' import { EventLoggerOptions, GetAuditEventsArgs, IEventLogger, RequiredContext, LogAuditEventArgs, LoggingEvent } from '../types/IEventLogger' @@ -14,7 +13,7 @@ import { EventLoggerOptions, GetAuditEventsArgs, IEventLogger, RequiredContext, export const eventLoggerAuditMethods: Array = ['loggerGetAuditEvents', 'loggerLogAuditEvent'] export const eventLoggerMethods: Array = [...eventLoggerAuditMethods] -export class EventLogger implements IAgentPlugin, IEventListener { +export class EventLogger implements IAgentPlugin { readonly schema = schema.IEventLogger readonly eventTypes: Array = [] diff --git a/packages/oid4vci-holder/src/agent/OID4VCIHolder.ts b/packages/oid4vci-holder/src/agent/OID4VCIHolder.ts index 4869e3431..d6d2fe812 100644 --- a/packages/oid4vci-holder/src/agent/OID4VCIHolder.ts +++ b/packages/oid4vci-holder/src/agent/OID4VCIHolder.ts @@ -9,7 +9,6 @@ import { Party, } from '@sphereon/ssi-sdk.data-store' import { IAgentPlugin, VerifiableCredential } from '@veramo/core' -import { IEventListener } from '@veramo/core/src/types/IAgent' import { computeEntryHash } from '@veramo/utils' import { v4 as uuidv4 } from 'uuid' import { OID4VCIMachine } from '../machine/oid4vciMachine' @@ -50,7 +49,7 @@ import { * {@inheritDoc IOID4VCIHolder} */ -export class OID4VCIHolder implements IAgentPlugin, IEventListener { +export class OID4VCIHolder implements IAgentPlugin { readonly eventTypes: Array = [OID4VCIHolderEvent.CONTACT_IDENTITY_CREATED, OID4VCIHolderEvent.CREDENTIAL_STORED] readonly methods: IOID4VCIHolder = { diff --git a/packages/xstate-persistence/plugin.schema.json b/packages/xstate-persistence/plugin.schema.json index 75fe1a974..635ad593f 100644 --- a/packages/xstate-persistence/plugin.schema.json +++ b/packages/xstate-persistence/plugin.schema.json @@ -10,7 +10,9 @@ "description": "Machine type/id" } }, - "required": ["machineType"], + "required": [ + "machineType" + ], "additionalProperties": false }, "DeleteStateResult": { @@ -30,7 +32,9 @@ "type": "string" } }, - "required": ["machineType"] + "required": [ + "machineType" + ] }, "State": { "type": "object", @@ -73,7 +77,15 @@ "type": "string" } }, - "required": ["id", "stateName", "machineType", "xStateEventType", "state", "createdAt", "updatedAt"] + "required": [ + "id", + "stateName", + "machineType", + "xStateEventType", + "state", + "createdAt", + "updatedAt" + ] }, "NonPersistedMachineSnapshot": { "$ref": "#/components/schemas/SaveStateArgs" @@ -108,7 +120,12 @@ "type": "string" } }, - "required": ["stateName", "machineType", "xStateEventType", "state"] + "required": [ + "stateName", + "machineType", + "xStateEventType", + "state" + ] } }, "methods": { @@ -142,4 +159,4 @@ } } } -} +} \ No newline at end of file diff --git a/packages/xstate-persistence/src/agent/XStatePersistence.ts b/packages/xstate-persistence/src/agent/XStatePersistence.ts index 41b81f013..005bd24f2 100644 --- a/packages/xstate-persistence/src/agent/XStatePersistence.ts +++ b/packages/xstate-persistence/src/agent/XStatePersistence.ts @@ -1,6 +1,5 @@ import { IAbstractXStateStore, State } from '@sphereon/ssi-sdk.data-store' import { IAgentPlugin } from '@veramo/core' -import { IEventListener } from '@veramo/core/src/types/IAgent' import { DeleteExpiredStatesArgs, @@ -21,7 +20,7 @@ import { IXStatePersistence, LoadActiveStateArgs } from '../types' * * @beta This API may change without a BREAKING CHANGE notice. */ -export class XStatePersistence implements IAgentPlugin, IEventListener { +export class XStatePersistence implements IAgentPlugin { readonly schema = schema.IXStatePersistence readonly methods: IXStatePersistence readonly eventTypes: Array