Skip to content

Commit

Permalink
ALL-2604 New package name - @tatumio/tatum-v1 (#919)
Browse files Browse the repository at this point in the history
* ALL-2604 New package name - @tatumio/tatum-v1

* ALL-2604 New package name - @tatumio/tatum-v1. Notice

---------

Co-authored-by: Oleksandr Loiko <[email protected]>
  • Loading branch information
alexloiko and Oleksandr Loiko committed Sep 14, 2023
1 parent bca2457 commit 964828e
Show file tree
Hide file tree
Showing 12 changed files with 27 additions and 22 deletions.
17 changes: 11 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# [Tatum API client](http://tatum.io/) &middot; [![GitHub license](https://img.shields.io/npm/dm/@tatumio/tatum)](https://img.shields.io/npm/dm/@tatumio/tatum) [![GitHub license](https://img.shields.io/npm/v/@tatumio/tatum)](https://img.shields.io/npm/v/@tatumio/tatum) [![CI](https://github.com/tatumio/tatum-js/actions/workflows/main.yml/badge.svg)](https://github.com/tatumio/tatum-js/actions/workflows/main.yml)
# [Tatum API client](http://tatum.io/) &middot; [![GitHub license](https://img.shields.io/npm/dm/@tatumio/tatum-v1)](https://img.shields.io/npm/dm/@tatumio/tatum-v1) [![GitHub license](https://img.shields.io/npm/v/@tatumio/tatum-v1)](https://img.shields.io/npm/v/@tatumio/tatum-v1) [![CI](https://github.com/tatumio/tatum-js/actions/workflows/main.yml/badge.svg)](https://github.com/tatumio/tatum-js/actions/workflows/main.yml)
Tatum API client allows browsers and Node.js clients to interact with Tatum API. It includes the following core components.

> **Package name change**
>
> Important notice about package name change. Starting from version **1.37.36**, package name is changed from `@tatumio/tatum` to `@tatumio/tatum-v1`. Please update your package.json accordingly if you're using v1 sdk.

> **Warning**
>
> Important notice about using ETH and CELO: Please upgrade to version 1.37.22 or newer (all previous versions depend on https://ethgasstation.info which will stop working from 12.12.2022)
Expand All @@ -19,7 +24,7 @@ You can find API documentation at [Github Pages](https://tatumio.github.io/tatum
### Node.js
1. Install module:

`npm install @tatumio/tatum`
`npm install @tatumio/tatum-v1`

### Node.JS & Browser support
Library is written in TypeScript with ES2017 as the target JS version. Library should work in Node.JS current LTS.
Expand Down Expand Up @@ -82,7 +87,7 @@ If you want to work with TRON locally, you need to enter API Key for [Trongrid](

```js
// In Node.js
const Tatum = require('@tatumio/tatum');
const Tatum = require('@tatumio/tatum-v1');
const btcWallet = await Tatum.generateWallet(Tatum.Currency.BTC, true);

console.log(btcWallet);
Expand All @@ -97,10 +102,10 @@ console.log(btcWallet);

We support types within the repo itself. Please open an issue here if you find any wrong types.

You can use `@tatumio/tatum` as follows:
You can use `@tatumio/tatum-v1` as follows:

```typescript
import { generateWallet, Currency } from '@tatumio/tatum';
import { generateWallet, Currency } from '@tatumio/tatum-v1';
const btcWallet = await generateWallet(Currency.BTC, true);
```

Expand Down Expand Up @@ -128,7 +133,7 @@ Tatum js use core node js modules or browser APIs that are not available in Reac
```
npm i rn-nodeify -g
npm i react-native-randombytes --save
npm i @tatumio/tatum --save
npm i @tatumio/tatum-v1 --save
rn-nodeify --install http,https,path,crypto,fs,stream,os --hack
cd ios && pod install
```
Expand Down
4 changes: 2 additions & 2 deletions documentation/blockchain/marketplace/auction.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
sendAuctionBid,
sendAuctionApproveNftTransfer,
celoGetCurrentBlock
} from '@tatumio/tatum';
} from '@tatumio/tatum-v1';
```

## Deploy the auction smart contract
Expand Down Expand Up @@ -167,4 +167,4 @@ In the response you will get the transaction id, where you can find the contract
settle.chain = Currency.CELO;
console.log(await sendAuctionSettle(true, settle, 'https://alfajores-forno.celo-testnet.org'));

```
```
4 changes: 2 additions & 2 deletions documentation/blockchain/marketplace/marketplace.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
sendMarketplaceCreateListing,
sendCeloSmartContractReadMethodInvocationTransaction,
sendAuctionApproveNftTransfer
} from '@tatumio/tatum';
} from '@tatumio/tatum-v1';
```

## Deploy the smart contract for marketplace
Expand Down Expand Up @@ -110,4 +110,4 @@ In case of cashbacks in custom erc20, you will need to give allowance from buyer
r.methodABI = listing.abi.find(a => a.name === r.methodName)
r.params = []
console.log(await sendCeloSmartContractReadMethodInvocationTransaction(r, 'https://data-seed-prebsc-2-s1.binance.org:8545'))
```
```
4 changes: 2 additions & 2 deletions documentation/blockchain/nft/nft.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ or [Github Pages](https://tatumio.github.io/tatum-js/) to see how to use other N
## Import required libraries

```typescript
import { mintNFTWithUri } from '@tatumio/tatum';
import { mintNFTWithUri } from '@tatumio/tatum-v1';
```

## Get NFTs
Expand Down Expand Up @@ -99,4 +99,4 @@ const transactionHash = await updateCashbackForAuthorNFT(false, {
cashbackValue: '15',
fromPrivateKey: '0x315ea1dae65c75f088542161a0777525a8de1153904c745cb8131a9e0c632204'
});
```
```
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@tatumio/tatum",
"name": "@tatumio/tatum-v1",
"version": "1.37.36",
"description": "Tatum API client allows browsers and Node.js clients to interact with Tatum API.",
"main": "dist/src/index.js",
Expand Down
2 changes: 1 addition & 1 deletion src/blockchain/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Just browse source code or [Github Pages](https://tatumio.github.io/tatum-js/) t
## Import required libraries

```typescript
import { btcGetCurrentBlock } from '@tatumio/tatum';
import { btcGetCurrentBlock } from '@tatumio/tatum-v1';
```

## Get Current BTC block
Expand Down
4 changes: 2 additions & 2 deletions src/ledger/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ or [Github Pages](https://tatumio.github.io/tatum-js/) to see how to use other l
## Import required libraries

```typescript
import { getAccountById } from '@tatumio/tatum';
import { getAccountById } from '@tatumio/tatum-v1';
```

## Account endpoints
Expand Down Expand Up @@ -298,4 +298,4 @@ const trade = await getTradeById('60ab440d58019206c876b4f6');
### Get all active sell trades
```typescript
const sellTrades = await getActiveSellTrades('60ab440d58019206c876b4f6');
```
```
2 changes: 1 addition & 1 deletion src/nft/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ In following guide we will see how to work with NFT endpoints. Each endpoint bel
First, we must import the required libraries from Tatum JS.

```typescript
import { mintNFTWithUri } from '@tatumio/tatum';
import { mintNFTWithUri } from '@tatumio/tatum-v1';
```
## Deploy NFT
Next, we must [deploy an NFT smart contract](https://apidoc.tatum.io/.php#operation/NftDeployErc721) on our blockchain of choice.
Expand Down
2 changes: 1 addition & 1 deletion src/offchain/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ or [Github Pages](https://tatumio.github.io/tatum-js/) to see how to use other o

## Import required libraries
```typescript
import { sendBitcoinOffchainTransaction } from '@tatumio/tatum';
import { sendBitcoinOffchainTransaction } from '@tatumio/tatum-v1';
```

## Send bitcoin offchain transaction
Expand Down
4 changes: 2 additions & 2 deletions src/security/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ or [Github Pages](https://tatumio.github.io/tatum-js/) to see how to use other s

## Import required libraries
```typescript
import { getTransactionKMS } from '@tatumio/tatum';
import { getTransactionKMS } from '@tatumio/tatum-v1';
```

## Get a KMS transaction
Expand All @@ -21,4 +21,4 @@ await deleteTransactionKMS('60f990befd2f551040f512c0');
## Complete a pending KMS transaction
```typescript
await completePendingTransactionKMS('76da8509079338edd85cecb26ebd0fd644adb347d86e9e3c32bdead4ececb6e3');
```
```
2 changes: 1 addition & 1 deletion src/transaction/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ or [Github Pages](https://tatumio.github.io/tatum-js/) to see how to use other t
## Import required libraries

```typescript
import { sendBitcoinTransaction } from '@tatumio/tatum';
import { sendBitcoinTransaction } from '@tatumio/tatum-v1';
```

## Send bitcoin transaction - from address
Expand Down
2 changes: 1 addition & 1 deletion src/wallet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ or [Github Pages](https://tatumio.github.io/tatum-js/) to see how to use other w
## Import required libraries

```typescript
import { generateWallet } from '@tatumio/tatum';
import { generateWallet } from '@tatumio/tatum-v1';
```

## Generate a wallet
Expand Down

0 comments on commit 964828e

Please sign in to comment.