- Overview
- Setup
- Tutorials
- How Tos
- Reference
- DAR Versions
- API Reference
- Commercials API
- Credential API
- Registry API
- Utility.Registry
- Utility.Registry.V0.Configuration.AppReward
- Utility.Registry.V0.Configuration.Instrument
- Utility.Registry.V0.Holding.Allocation
- Utility.Registry.V0.Holding.Burn
- Utility.Registry.V0.Holding.Lock
- Utility.Registry.V0.Holding.Mint
- Utility.Registry.V0.Holding.Transfer
- Utility.Registry.V0.Holding.Unlock
- Utility.Registry.V0.Rule.Transfer
- Utility.Registry.V0.Types
- Utility.Registry.V0.Util
- Utility.Registry.App
- Utility.Holding
- Utility.Registry
- Settlement Utility API
- Collateral Utility API
- Operator Backend API
Utility.Collateral.App.Service.User¶
Templates¶
template UserService
User service for the Collateral App.
Signatory: operator, user
Field
Type
Description
operator
The utility operator.
user
The user.
Choice Archive
Controller: operator, user
Returns: ()
(no fields)
Choice UserService_AcceptCollateralAgreementChangeRequest
Accept a collateral agreement change request.
Controller: user
Returns: CollateralAgreementChangeRequest_Accept_Result
Field
Type
Description
cid
The request cid.
payload
The request payload.
Choice UserService_AcceptCollateralAgreementRequest
Accept a collateral agreement request.
Controller: user
Returns: CollateralAgreementRequest_Accept_Result
Field
Type
Description
cid
The request cid.
payload
The request payload.
Choice UserService_CancelCollateralAgreementChangeRequest
Cancel a collateral agreement change request.
Controller: user
Returns: CollateralAgreementChangeRequest_Cancel_Result
Field
Type
Description
cid
The request cid.
payload
The request payload.
Choice UserService_CancelCollateralAgreementRequest
Cancel a collateral agreement request.
Controller: user
Returns: CollateralAgreementRequest_Cancel_Result
Field
Type
Description
cid
The request cid.
payload
The request payload.
Choice UserService_CancelInstructedCollateral
Cancel an instructed collateral.
Controller: user
Returns: InstructedCollateral_Cancel_Result
Field
Type
Description
cid
The Instructed collateral contract.
allocations
The allocations to settle.
extraArgs
For each allocation, the arguments to
Allocation_Cancel
choice.Choice UserService_ExecuteTransfer
Settle an instructed collateral transfer. This choice is compatible with external signing as long as
collateralStateCid
is stable (i.e. no other transfer for the same collateral agreement gets settled during the signing window for this choice).Controller: user
Returns: InstructedCollateral_ExecuteTransfer_Result
Field
Type
Description
cid
The Instructed Collateral contract.
allocations
The allocations to settle.
executeTransferArgs
For each allocation, the arguments to the
Allocation_ExecuteTransfer
choice.collateralStateCid
Collateral State contract to update.
Choice UserService_ProposeCollateralAgreementChange
Request a modification to an existing collateral agreement.
Controller: user
Returns: CollateralAgreement_ProposeChange_Result
Field
Type
Description
cid
The collateral agreement to change.
updatedTerms
Updated terms.
Choice UserService_RejectCollateralAgreementChangeRequest
Reject a collateral agreement change request.
Controller: user
Returns: CollateralAgreementChangeRequest_Reject_Result
Field
Type
Description
cid
The request cid.
payload
The request payload.
Choice UserService_RejectCollateralAgreementRequest
Reject a collateral agreement request.
Controller: user
Returns: CollateralAgreementRequest_Reject_Result
Field
Type
Description
cid
The request cid.
payload
The request payload.
Choice UserService_RequestCollateralAgreement
Request a collateral agreement.
Controller: user
Returns: UserService_RequestCollateralAgreement_Result
Field
Type
Description
counterparty
The counterparty to the request.
id
Agreement id.
requestorIsPartyA
Whether the requestor is
PartyA
in the CSA.terms
Terms of the collateral agreement.
Choice UserService_Terminate
Terminates the user service.
Controller: actor
Returns: UserService_Terminate_Result
Field
Type
Description
actor
Party initiating the termination of the
UserService
contract.Choice UserService_TerminateCollateralAgreement
Terminate a collateral agreement.
Controller: user
Returns: CollateralAgreement_Terminate_Result
Field
Type
Description
cid
The collateral agreement cid.
payload
The request payload.
Choice UserService_TransferCollateral
Initiate process to transfer collateral to a counterparty.
Controller: user
Returns: CollateralAgreement_TransferCollateral_Result
Field
Type
Description
cid
The Collateral Agreement contract.
positions
The positions that will be pledged.
reference
Textual reference, used for deduplication. Please, ensure this is unique.
createdAt
Time at which this request is created.
allocateBefore
Until when (exclusive) the senders are given time to allocate their assets.
settleBefore
Until when (exclusive) the executor is given time to execute the settlement. TODO consider if this should be provided via
OperatorConfiguration
.
template UserServiceRequest
A user service request.
Signatory: user
Field
Type
Description
operator
Service operator.
user
User.
Choice Archive
Controller: user
Returns: ()
(no fields)
Choice UserServiceRequest_Accept
Accept
UserService
request.Controller: operator
Returns: UserServiceRequest_Accept_Result
Field
Type
Description
operatorConfigurationCid
Operator configuration.
credentialCids
User credentials.
Choice UserServiceRequest_Cancel
Cancel
UserService
request.Controller: user
Returns: UserServiceRequest_Cancel_Result
(no fields)
Choice UserServiceRequest_Reject
Reject
UserService
request.Controller: operator
Returns: UserServiceRequest_Reject_Result
Field
Type
Description
reason
Rejection reason.
Data Types¶
data UserServiceRequest_Accept_Result
Result of
UserServiceRequest_Accept
.UserServiceRequest_Accept_Result
Field
Type
Description
userServiceCid
User Service contract id.
data UserServiceRequest_Cancel_Result
data UserServiceRequest_Reject_Result
Result of
UserServiceRequest_Reject
.UserServiceRequest_Reject_Result
Field
Type
Description
reason
Rejection reason.
data UserService_RequestCollateralAgreement_Result
Result of
UserServiceRequest_RequestCollateralAgreement
.UserService_RequestCollateralAgreement_Result
Field
Type
Description
collateralAgreementRequestCid
Collateral agreement request.
data UserService_Terminate_Result