-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
cmd
committed
Feb 1, 2024
1 parent
b84efb2
commit 8952e5e
Showing
5 changed files
with
126 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
# Oracle Interfaces | ||
|
||
List of interfaces for the Oracle API. | ||
|
||
> Click on the links below to navigate: | ||
- [OracleTxData](#oracletxdata) | ||
- [OracleSpendData](#oraclespenddata) | ||
- [OracleTxOutput](#txoutput) | ||
|
||
## OracleTxData | ||
|
||
```ts | ||
interface OracleTxData { | ||
txid : string | ||
version : number, | ||
locktime : number | ||
vin : OracleTxIn[] | ||
vout : OracleTxOut[] | ||
size : number | ||
weight : number | ||
fee : number | ||
status : OracleTxStatus | ||
} | ||
|
||
interface OracleTxIn { | ||
txid : string | ||
vout : number | ||
prevout : OracleTxOut | null | ||
scriptsig : string | ||
scriptsig_asm : string | ||
witness : string[] | ||
sequence : number | ||
is_coinbase : boolean | ||
} | ||
|
||
interface OracleTxOut { | ||
scriptpubkey : string | ||
scriptpubkey_asm : string | ||
scriptpubkey_type : string | ||
scriptpubkey_address ?: string | ||
value : number | ||
} | ||
|
||
interface OracleTxStatus { | ||
confirmed : boolean | ||
block_hash : string | null | ||
block_height : number | null | ||
block_time : number | null | ||
} | ||
``` | ||
|
||
## OracleSpendData | ||
|
||
```ts | ||
interface OracleSpendData { | ||
txspend : TxOutput | ||
status : OracleTxStatus | ||
state : OracleSpendState | ||
} | ||
|
||
interface OracleTxSpendState { | ||
spent : boolean | ||
txid : string | null | ||
vin : number | null | ||
status : OracleTxStatus | ||
} | ||
``` | ||
|
||
## TxOutput | ||
|
||
```ts | ||
interface TxOutput { | ||
txid : string, | ||
vout : number, | ||
value : number, | ||
scriptkey : string | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Server Docs | ||
|
||
## Connecting to our Server | ||
|
||
BitEscrow currently provides an escrow server for the `signet`, `testnet`, and `mutiny` networks. Check out our list of client configurations below. | ||
|
||
### Mutiny Configuration | ||
|
||
To connect your EscrowClient to our `mutiny` server, use the following config: | ||
|
||
```ts | ||
const config = { | ||
hostname : 'https://bitescrow-mutiny.vercel.app', | ||
oracle : 'https://mutinynet.com', | ||
network : 'mutiny' | ||
} | ||
``` | ||
|
||
### Signet Configuration | ||
|
||
To connect your EscrowClient to our `signet` server, use the following config: | ||
|
||
```ts | ||
const config = { | ||
hostname : 'https://bitescrow-signet.vercel.app', | ||
oracle : 'https://mempool.space/signet', | ||
network : 'signet' | ||
} | ||
``` | ||
|
||
### Testnet Configuration | ||
|
||
To connect your EscrowClient to our `testnet` server, use the following config: | ||
|
||
```ts | ||
const config = { | ||
hostname : 'https://bitescrow-testnet.vercel.app', | ||
oracle : 'https://mempool.space/testnet', | ||
network : 'testnet' | ||
} | ||
``` |