@unicrowio/sdk
Namespaces
Enumerations
Interfaces
- ApproveArbitratorParsedPayload
- ApproveSettlementParsedPayload
- ArbitrateParsedPayload
- CalculateAmountsInput
- ChallengeParsedPayload
- ClaimParsedPayload
- GenericParsedTxPayload
- GetResponseUserBalance
- IApproveArbitrationTransactionCallbacks
- IApproveOrProposeArbitrationModalProps
- IArbitrateModalProps
- IArbitrateTransactionCallbacks
- IArbitrateTransactionPayload
- IArbitrationTransactionPayload
- IArbitratorInfo
- IBalance
- IBalanceDetailed
- ICalculateStatusParams
- IChallengeModalProps
- IChallengeTransactionCallbacks
- IChallengeTransactionPayload
- IClaimModalProps
- IClaimMultipleModalProps
- IClaimTransactionCallbacks
- IClaimTransactionPayload
- IEnsAddresses
- IEscrowData
- IEscrowDataWithTokenInfo
- IEscrowStatus
- IGenericTransactionCallbacks
- IGetConnectedUser
- IGetEscrowData
- IGetPaymentListResponse
- IPage
- IPayTransactionCallbacks
- IPayTransactionPayload
- IPaymentModalProps
- IPaymentProps
- IPaymentPropsData
- IProposeArbitrationTransactionCallbacks
- IRefundModalProps
- IRefundTransactionCallbacks
- IRefundTransactionPayload
- IReleaseModalProps
- IReleaseTransactionCallbacks
- IReleasedTransactionBroadcastPayload
- ISettlement
- ISettlementApproveModalProps
- ISettlementApproveTransactionCallbacks
- ISettlementOfferModalProps
- ISettlementOfferTransactionCallbacks
- ISettlementTransactionPayload
- IToken
- IValidateProps
- IndexerInstance
- MultipleClaimParsedPayload
- OfferSettlementParsedPayload
- PayParsedPayload
- ProposalArbitratorParsedPayload
- ReleaseParsedPayload
- TPaymentListQueryParams
- UnicrowConfig
- UnicrowNetwork
- tShares
- tSplits
Type Aliases
CalculateFunction
Ƭ CalculateFunction: CalculateAmountsInput
Defined in
typing/index.ts:1372
IReleasedTransactionPayload
Ƭ IReleasedTransactionPayload: ReleaseParsedPayload
Defined in
typing/index.ts:674
tConnectedUser
Ƭ tConnectedUser: "buyer"
| "seller"
| "arbitrator"
| "marketplace"
| "other"
Defined in
typing/index.ts:880
tEscrowParty
Ƭ tEscrowParty: "buyer"
| "seller"
| null
Defined in
typing/index.ts:70
Variables
NETWORK
• Const
NETWORK: Object
Index signature
▪ [name: string
]: UnicrowNetwork
Defined in
config/setup.ts:3
Functions
config
▸ config(options?
): void
Sets the target network for all subsequent SDK calls. This is mandatory to call after importing the SDK. Networks and chain IDs currently available:
- 42161 - Arbitrum One
- 421614 - Arbitrum Sepolia
- 8453 - Base
- 8453 - Base Sepolia
Parameters
Name | Type | Default value | Description |
---|---|---|---|
options | Object | {} | Configuration options |
options.autoSwitchNetwork? | boolean | true | If the user is connected to a different network when a call is about to be performed, ask the user to change to that network (or add it if the user doesn't have it configured) |
options.chainId? | BigInt | undefined | Chain ID of one of Unicrow's supported networks (see above) |
Returns
void
Example
unicrowSDK.config({
chainId = BigInt(42161),
autoSwitchNetwork: true
})
Defined in
config/setup.ts:105
getContractAddress
▸ getContractAddress(role
): string
Parameters
Name | Type |
---|---|
role | Role |
Returns
string
Defined in
config/getContractAddress.ts:3