Skip to content

Commit

Permalink
Mark L2 direct bridging as an experimental feature
Browse files Browse the repository at this point in the history
The backend components of direct bridging (contracts and relayer bot) have not
been deployed yet. Despite the TypeScript SDK has been prepared to support it,
the feature is not operational and has been postponed for now. As we need to
release a new SDK version, we are marking SDK support for L2 direct bridging
as experimental until the backend is ready.
  • Loading branch information
lukasz-zimnoch committed Apr 12, 2024
1 parent f3ac802 commit 219a55c
Show file tree
Hide file tree
Showing 8 changed files with 77 additions and 896 deletions.
6 changes: 3 additions & 3 deletions typescript/api-reference/classes/BaseL2TBTCToken.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ EthersContractHandle\<L2TBTCTypechain\>.constructor

#### Defined in

[src/lib/base/l2-tbtc-token.ts:21](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/lib/base/l2-tbtc-token.ts#L21)
[src/lib/base/l2-tbtc-token.ts:23](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/lib/base/l2-tbtc-token.ts#L23)

## Properties

Expand Down Expand Up @@ -134,7 +134,7 @@ EthersContractHandle.\_totalRetryAttempts

#### Defined in

[src/lib/base/l2-tbtc-token.ts:50](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/lib/base/l2-tbtc-token.ts#L50)
[src/lib/base/l2-tbtc-token.ts:53](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/lib/base/l2-tbtc-token.ts#L53)

___

Expand Down Expand Up @@ -176,7 +176,7 @@ ___

#### Defined in

[src/lib/base/l2-tbtc-token.ts:42](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/lib/base/l2-tbtc-token.ts#L42)
[src/lib/base/l2-tbtc-token.ts:45](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/lib/base/l2-tbtc-token.ts#L45)

___

Expand Down
11 changes: 8 additions & 3 deletions typescript/api-reference/classes/DepositsService.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ Handle to tBTC contracts.

#### Defined in

[src/services/deposits/deposits-service.ts:177](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/deposits/deposits-service.ts#L177)
[src/services/deposits/deposits-service.ts:183](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/deposits/deposits-service.ts#L183)

___

Expand All @@ -159,6 +159,11 @@ system is deployed on. Such a deposit is initiated using a transaction
on the L2 chain. To make it happen, the given L2 cross-chain contracts
must be initialized along with a L2 signer first.

THIS IS EXPERIMENTAL CODE THAT CAN BE CHANGED OR REMOVED
IN FUTURE RELEASES. IT SHOULD BE USED ONLY FOR INTERNAL
PURPOSES AND EXTERNAL APPLICATIONS SHOULD NOT DEPEND ON IT.
CROSS-CHAIN SUPPORT IS NOT FULLY OPERATIONAL YET.

#### Parameters

| Name | Type | Description |
Expand Down Expand Up @@ -194,7 +199,7 @@ This is actually a call to initiateDepositWithProxy with a built-in

#### Defined in

[src/services/deposits/deposits-service.ts:157](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/deposits/deposits-service.ts#L157)
[src/services/deposits/deposits-service.ts:163](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/deposits/deposits-service.ts#L163)

___

Expand Down Expand Up @@ -299,4 +304,4 @@ Typically, there is no need to use this method when DepositsService

#### Defined in

[src/services/deposits/deposits-service.ts:255](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/deposits/deposits-service.ts#L255)
[src/services/deposits/deposits-service.ts:261](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/deposits/deposits-service.ts#L261)
31 changes: 21 additions & 10 deletions typescript/api-reference/classes/TBTC.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,11 @@ Gets cross-chain contracts for the given supported L2 chain.
The given L2 chain contracts must be first initialized using the
`initializeCrossChain` method.

THIS IS EXPERIMENTAL CODE THAT CAN BE CHANGED OR REMOVED
IN FUTURE RELEASES. IT SHOULD BE USED ONLY FOR INTERNAL
PURPOSES AND EXTERNAL APPLICATIONS SHOULD NOT DEPEND ON IT.
CROSS-CHAIN SUPPORT IS NOT FULLY OPERATIONAL YET.

#### Parameters

| Name | Type | Description |
Expand All @@ -161,7 +166,7 @@ Cross-chain contracts for the given L2 chain or

#### Defined in

[src/services/tbtc.ts:233](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L233)
[src/services/tbtc.ts:252](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L252)

___

Expand All @@ -172,6 +177,11 @@ ___
Initializes cross-chain contracts for the given L2 chain, using the
given signer. Updates the signer on subsequent calls.

THIS IS EXPERIMENTAL CODE THAT CAN BE CHANGED OR REMOVED
IN FUTURE RELEASES. IT SHOULD BE USED ONLY FOR INTERNAL
PURPOSES AND EXTERNAL APPLICATIONS SHOULD NOT DEPEND ON IT.
CROSS-CHAIN SUPPORT IS NOT FULLY OPERATIONAL YET.

#### Parameters

| Name | Type | Description |
Expand Down Expand Up @@ -200,7 +210,7 @@ In case this function needs to support non-EVM L2 chains that can't

#### Defined in

[src/services/tbtc.ts:185](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L185)
[src/services/tbtc.ts:198](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L198)

___

Expand Down Expand Up @@ -232,25 +242,26 @@ This function is especially useful for local development as it gives

#### Defined in

[src/services/tbtc.ts:163](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L163)
[src/services/tbtc.ts:170](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L170)

___

### initializeEthereum

**initializeEthereum**(`signer`, `ethereumChainId`, `bitcoinNetwork`): `Promise`\<[`TBTC`](TBTC.md)\>
**initializeEthereum**(`signer`, `ethereumChainId`, `bitcoinNetwork`, `crossChainSupport?`): `Promise`\<[`TBTC`](TBTC.md)\>

Initializes the tBTC v2 SDK entrypoint for the given Ethereum network and Bitcoin network.
The initialized instance uses default Electrum servers to interact
with Bitcoin network.

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `signer` | [`EthereumSigner`](../README.md#ethereumsigner) | Ethereum signer. |
| `ethereumChainId` | [`Ethereum`](../enums/Chains.Ethereum.md) | Ethereum chain ID. |
| `bitcoinNetwork` | [`BitcoinNetwork`](../enums/BitcoinNetwork-1.md) | Bitcoin network. |
| Name | Type | Default value | Description |
| :------ | :------ | :------ | :------ |
| `signer` | [`EthereumSigner`](../README.md#ethereumsigner) | `undefined` | Ethereum signer. |
| `ethereumChainId` | [`Ethereum`](../enums/Chains.Ethereum.md) | `undefined` | Ethereum chain ID. |
| `bitcoinNetwork` | [`BitcoinNetwork`](../enums/BitcoinNetwork-1.md) | `undefined` | Bitcoin network. |
| `crossChainSupport` | `boolean` | `false` | Whether to enable cross-chain support. False by default. |

#### Returns

Expand All @@ -265,7 +276,7 @@ Throws an error if the underlying signer's Ethereum network is

#### Defined in

[src/services/tbtc.ts:122](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L122)
[src/services/tbtc.ts:123](https://github.com/keep-network/tbtc-v2/blob/main/typescript/src/services/tbtc.ts#L123)

___

Expand Down
Loading

0 comments on commit 219a55c

Please sign in to comment.