social / pragma.order / OrderService /

OrderService #

class OrderService(pragmaNode: PragmaNode, instanceId: UUID, orderManager: OrderManager = OrderManager(), orderSectionsBuilder: OrderSectionsBuilder = OrderSectionsBuilder(), timeProxy: TimeProxy = TimeProxy()) : DistributedService, ConfigHandler<OrderServiceConfig>

OrderService is responsible for Pragma order syncing and management.

Constructors #

OrderService

internal fun OrderService(pragmaNode: PragmaNode, instanceId: UUID, orderManager: OrderManager = OrderManager(), orderSectionsBuilder: OrderSectionsBuilder = OrderSectionsBuilder(), timeProxy: TimeProxy = TimeProxy())

Functions #

NameSummary

getOrderHistoryRecordsOperatorV1

suspend fun getOrderHistoryRecordsOperatorV1(operatorSession: OperatorSession, request: OrderRpc.GetOrderHistoryRecordsOperatorV1Request): OrderRpc.GetOrderHistoryRecordsOperatorV1Response

Fetches and returns a list of OrderHistoryRecords associated with the given order ID.

getOrderRecordsOperatorV1

suspend fun getOrderRecordsOperatorV1(operatorSession: OperatorSession, request: OrderRpc.GetOrderRecordsOperatorV1Request): OrderRpc.GetOrderRecordsOperatorV1Response

Fetches and returns a list of OrderRecords associated with the given pragma social ID.

getOrderRecordsPartnerV1

suspend fun getOrderRecordsPartnerV1(partnerSession: PartnerSession, request: OrderRpc.GetOrderRecordsPartnerV1Request): OrderRpc.GetOrderRecordsPartnerV1Response

Fetches and returns a list of OrderRecords associated with the given pragma social ID.

getOrderRecordsServiceV1

suspend fun getOrderRecordsServiceV1(serviceSession: ServiceSession, request: OrderRpc.GetOrderRecordsServiceV1Request): OrderRpc.GetOrderRecordsServiceV1Response

Fetches and returns a list of OrderRecords associated with the given pragma social ID.

getPersonalDataSectionsServiceV1

suspend fun getPersonalDataSectionsServiceV1(serviceSession: ServiceSession, request: OrderRpc.GetPersonalDataSectionsServiceV1Request): OrderRpc.GetPersonalDataSectionsServiceV1Response

Provides a list of pragma.datarights.PersonalDataReportSection objects for use in the pragma.datarights.DataRightsService.

syncOrdersOperatorV1

suspend fun syncOrdersOperatorV1(operatorSession: OperatorSession, request: OrderRpc.SyncOrdersOperatorV1Request): OrderRpc.SyncOrdersOperatorV1Response

Syncs third party provider entitlements as Pragma orders for the given pragmaSocialId and list of providers. If there is no third party provider account linked to the given pragma social id, syncing for that provider will be skipped. Returns a list of orders that have been successfully synced since the given lastSyncedTimestampMillis or successfully synced during this rpc call if no lastSyncedTimestampMillis is provided.

syncOrdersPartnerV1

suspend fun syncOrdersPartnerV1(partnerSession: PartnerSession, request: OrderRpc.SyncOrdersPartnerV1Request): OrderRpc.SyncOrdersPartnerV1Response

Syncs third party provider entitlements as Pragma orders for the given pragmaSocialId and list of providers. If there is no third party provider account linked to the given pragma social id, syncing for that provider will be skipped. Returns a list of orders that have been successfully synced since the given lastSyncedTimestampMillis or successfully synced during this rpc call if no lastSyncedTimestampMillis is provided.

syncOrdersServiceV1

suspend fun syncOrdersServiceV1(serviceSession: ServiceSession, request: OrderRpc.SyncOrdersServiceV1Request): OrderRpc.SyncOrdersServiceV1Response

Syncs third party provider entitlements as Pragma orders for the given pragmaSocialId and list of providers. If there is no third party provider account linked to the given pragma social id, syncing for that provider will be skipped. Returns a list of orders that have been successfully synced since the given lastSyncedTimestampMillis or successfully synced during this rpc call if no lastSyncedTimestampMillis is provided.