From 81ac35adcf92420148823e57314f884e422483b2 Mon Sep 17 00:00:00 2001 From: Tarik Gul <47201679+TarikGul@users.noreply.github.com> Date: Wed, 7 Feb 2024 13:28:35 -0500 Subject: [PATCH] chore(release): 0.1.7 (#367) --- CHANGELOG.md | 28 ++++++++++++++ docs/assets/search.js | 2 +- .../AssetTransferApi.AssetTransferApi.html | 12 +++--- .../errors_BaseError.BaseErrorsEnum.html | 38 ++++++++++--------- docs/enums/types.Direction.html | 22 +++++------ ...nstructApiPromise.constructApiPromise.html | 4 +- docs/index.html | 5 ++- .../constructApiPromise.ApiInfo.html | 10 ++--- docs/interfaces/types.TransferArgsOpts.html | 22 +++++------ docs/interfaces/types.TxResult.html | 18 ++++----- docs/modules/AssetTransferApi.html | 4 +- docs/modules/constructApiPromise.html | 4 +- docs/modules/errors_BaseError.html | 4 +- docs/modules/types.html | 4 +- docs/types/types.AssetTransferApiOpts.html | 6 +-- docs/types/types.ConstructedFormat.html | 4 +- docs/types/types.Format.html | 4 +- docs/types/types.LocalTransferTypes.html | 4 +- docs/types/types.Methods.html | 4 +- docs/types/types.RegistryTypes.html | 4 +- docs/types/types.XcmDirection.html | 4 +- package.json | 2 +- 22 files changed, 120 insertions(+), 89 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9382d2c2..f19167e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,33 @@ # Changelog +## [0.1.7](https://github.com/paritytech/asset-transfer-api/compare/v0.1.6..v0.1.7)(2024-02-07) + +### Feat + +- feat: ensure the injectedRegsitry opt does deep comparisons ([#359](https://github.com/paritytech/asset-transfer-api/pull/359)) ([724a89d](https://github.com/paritytech/asset-transfer-api/commit/724a89d7e2728a2a42604dc4e5e2d9b535926213)) +- feat: add local transfers for orml, and parachains ([#352](https://github.com/paritytech/asset-transfer-api/pull/352)) ([57cc037](https://github.com/paritytech/asset-transfer-api/commit/57cc037190e8ca14beb1e56485e2782a34523596)) + +### Fix + +- fix(internal): add deepEqual functionality for comparing two objects ([#365](https://github.com/paritytech/asset-transfer-api/pull/365)) ([e305138](https://github.com/paritytech/asset-transfer-api/commit/e305138f79ecf7cbd118869db2429c3f2726d0a1)) +- fix(internal-refactor): adjust naming to be more conventional ([#358](https://github.com/paritytech/asset-transfer-api/pull/358)) ([6b42fdb](https://github.com/paritytech/asset-transfer-api/commit/6b42fdba43b02fb924fb824b3898d74d27ea2caa)) +- fix: renaming statemine in zombienet toml files ([#356](https://github.com/paritytech/asset-transfer-api/pull/356)) ([f653810](https://github.com/paritytech/asset-transfer-api/commit/f653810154321d349adbce7ea0b3a69efa1c9334)) + +### Chore + +- chore(yarn): update berry to 4.1.0 ([#362](https://github.com/paritytech/asset-transfer-api/pull/362)) ([46a4d07](https://github.com/paritytech/asset-transfer-api/commit/46a4d07100a89b59725946f8dae19c660de13584)) +- chore(registry): update registry dep ([#360](https://github.com/paritytech/asset-transfer-api/pull/360)) ([d71af0f](https://github.com/paritytech/asset-transfer-api/commit/d71af0fbbeacbc53221afd8ed646b51cf8c16b77)) + +### Docs + +- docs: add `RELEASE.md` ([#355](https://github.com/paritytech/asset-transfer-api/pull/355)) ([550e76f](https://github.com/paritytech/asset-transfer-api/commit/550e76f44f99458e899acb888cec38ffb3cdd000)) + +### Test + +- test: set registries to NPM for AssetTransferApi ([#363](https://github.com/paritytech/asset-transfer-api/pull/363)) ([94d6c31](https://github.com/paritytech/asset-transfer-api/commit/94d6c31e74a4d32a072c455d2f8dcbeddb605122)) +- test: e2e tests ([#343](https://github.com/paritytech/asset-transfer-api/pull/343)) ([7d5de87](https://github.com/paritytech/asset-transfer-api/commit/7d5de8726328728edca8be63eb79ce25b8439d1e)) + + ## [0.1.6](https://github.com/paritytech/asset-transfer-api/compare/v0.1.5..v0.1.6)(2024-01-22) ## Features diff --git a/docs/assets/search.js b/docs/assets/search.js index 88a50072..3184288b 100644 --- a/docs/assets/search.js +++ b/docs/assets/search.js @@ -1 +1 @@ -window.searchData = "data:application/octet-stream;base64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TIOIcV8zh8qoTjmYS7ivH7kU6SYZA7rshC6RKQA38+G2XyLSzRtoBz6uqjuEobtDCPgCuIWvLO2nmeU7hkYRZJaP5nKcREGCHAm8PivlbkmCzAx8/afWJkINmnHga8aHbUf2mLf3HRwkqPBxVRuI3eWnorz8BKIOWpL01aW9lgzcAhXhI7l4yqqPAoAimJ+511e7FgKQF4Evn/fN+y4N33eBuQaQtfQFq7yqF5cXOUGQwEQvfEyZgiCXdQzuhHyjpquJA8zc+Z3PJIndbPHNvlDHUWKE7x9eX/8G2s7WrRVCAAA="; \ No newline at end of file +window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAE7WbbW/bOBKA/4vy1XBDUqSTfOtdW6BAd7dos3sHFEGhtelWV1nySXKbbND/viQlWTPS0JYs7afU9bxxnhm+SPRzkGc/iuDu03PwLU43wR1fBGm008Fd8LIodHmfR2mx1fnLfRwsgkOemC922eaQ6OJFV2D5tdwlRmqdROYbYzQIfi4au4zfnLdca/YtD3C1CPZRrtOSst+Gwa/DNo51rqNSN4Lub7Qu4yy9MKCrUwaHhdoz7Is9TuMyjpL4L/1Bf4mLMn+6NGjS0szRbnW5/vpG67fpNrs0zo6NmSPc6HW20a8fyzxOi3h9aZB9MzPE2RZslho+h3VpBN7n2S4udK8rCZmTjcmlahtzHyNCcVrqfButPWZr8dPNSMUMpoVrHh7dR2AqGOH6qtIb7L5R9oVR7PX6V/vPS2IByvMFFG31f9e7P3RewMlpVFhdE1OCU+GgitweUjf50eENq9PBhdQ2Sfm0N7rdtnD/e7IR2rngVZxrvA7o9LBrbBy/PR1uFQYg2rbZu2wdJQNsXzWCJzy0KrSvj09FqXf32fsoj4a47MjP4PmDTqKnMa4bhRl8V3/HOD9qTPBuczc840h6stfB2cbik/0Oz3RHfoJnF/wY112F6b6HQsbiY/3y69sVk+0UZ2by/hzl1GvvUGDcNNV19SbLd1FJOqm+mmb+382krjcnPPWkpjl10+pxl46WC+i1LzbN7S+6/JptaF/1d9McdPeQv+1L2h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fIvTHAWYz5UfoLO3r92NAG6RQnknh43rXPLCCFsBIlHckRdLchAE5APRDn6Z9WR9VL+uBJki99KU+qX7WAuYNMFbmazqndZwrq4upoNzBRMd9ITc38kCzg3iFL8u75uI2cAf0uK9Gd/VLmzRLD+6ljSuRor8Cg+lK+YafZmaucgaSfc+CAqNf+dYrs/jH8I0CUAcdp3yjaS6qguSBqVL4VpeqssmNB1BXvhlqH+VRme3d7yZAwYDWYr7pqVLNq1+4AF2QbeZDXukW9Q9FgDKYVbk/5qfiR1zaxaW3toKeDH2ogT6RdBBB6JtV3H2jwt03Ar0J9wK+2HO9Ld21KqAHV0RfwpoliAQNQla+OmkM9DbTIGPCV9pQGfWpAJUtfPORK5F+kXGgy8/oEpUC4ua+uO3PMunJG2gzH6v6QmXkLlQCXiDu0Jdu+zvV6kVGqwgw+TA3agbz/ngdAZAGJaa8g3a5Ipoa1Bnzxl0r99sauGa+BaDRJnCBCZ35psDj0SX/UnTPLgJMK6Fv6I2BxN0mK6vbZIAcmNakr7ftPW/gFqiEvkIpH/P6VxZAEazxwuur208M1Bbz9cShfTGn4Ys5sOCAbK98Zqq7j0l1MxYkCWwWQh8p01Tk1pDD05Rv1HRHClBgwvldBJIE/bAIzNlSJ3FqhD89/Pz5N9nOL1RmQwAA"; \ No newline at end of file diff --git a/docs/classes/AssetTransferApi.AssetTransferApi.html b/docs/classes/AssetTransferApi.AssetTransferApi.html index f284bff2..9cf41c5d 100644 --- a/docs/classes/AssetTransferApi.AssetTransferApi.html +++ b/docs/classes/AssetTransferApi.AssetTransferApi.html @@ -1,8 +1,8 @@ -AssetTransferApi | @substrate/asset-transfer-api - v0.1.6

Holds open an api connection to a specified chain within the ApiPromise in order to help +AssetTransferApi | @substrate/asset-transfer-api - v0.1.7

Holds open an api connection to a specified chain within the ApiPromise in order to help construct transactions for assets and estimating fees.

import { AssetTransferApi, constructApiPromise } from '@substrate/asset-transfer-api'

const main = () => {
const { api, specName, safeXcmVersion } = await constructApiPromise('wss://some_ws_url');
const assetsApi = new AssetTransferApi(api, specName, safeXcmVersion);
}
-

Methods

Methods

  • assetIds: string[]

    Array of assetId's to be transferred

  • amounts: string[]

    Array of the amounts of each token to transfer

  • opts: TransferArgsOpts<T> = {}

    Options

    -
  • Returns Promise<TxResult<T>>

    • Decodes the hex of an extrinsic into a string readable format.

      +

    Returns Promise<TxResult<T>>

    • Decodes the hex of an extrinsic into a string readable format.

      const decodedExt = assetsApi.decodeExtrinsic(tx, 'call');
      console.log(JSON.parse(decodedExt));

      Type Parameters

      Parameters

      • encodedTransaction: string

        the hex of an extrinsic tx

      • format: T

        The format the tx is in

        -

      Returns string

    • Fetch estimated fee information for an extrinsic

      +

    Returns string

    • Fetch estimated fee information for an extrinsic

      const feeInfo = assetApi.fetchFeeInfo(tx, 'call');
      console.log(feeInfo.toJSON());

      Type Parameters

      Parameters

      • tx: ConstructedFormat<T>

        a payload, call or submittable

      • format: T

        The format the tx is in

        -

      Returns Promise<null | RuntimeDispatchInfo | RuntimeDispatchInfoV1>

    • Initialize the registry. This will only activate the registry for the CDN. +

    Returns Promise<null | RuntimeDispatchInfo | RuntimeDispatchInfoV1>

    \ No newline at end of file +

    Returns Promise<void>

    \ No newline at end of file diff --git a/docs/enums/errors_BaseError.BaseErrorsEnum.html b/docs/enums/errors_BaseError.BaseErrorsEnum.html index c4064927..f1e47896 100644 --- a/docs/enums/errors_BaseError.BaseErrorsEnum.html +++ b/docs/enums/errors_BaseError.BaseErrorsEnum.html @@ -1,5 +1,5 @@ -BaseErrorsEnum | @substrate/asset-transfer-api - v0.1.6

    Errors that may be returned by the API.

    -

    Enumeration Members

    AssetNotFound +BaseErrorsEnum | @substrate/asset-transfer-api - v0.1.7

    Errors that may be returned by the API.

    +

    Enumeration Members

    AssetNotFound: "AssetNotFound"

    Not able to find the asset.

    -
    DisabledOption: "DisabledOption"

    The following option is disabled given the inputs.

    -
    InternalError: "InternalError"

    An issue has happened internally.

    -
    InvalidAddress: "InvalidAddress"

    The inputted address is invalid.

    -
    InvalidAsset: "InvalidAsset"

    The inputted asset is incorrect or invalid, and does not exist given the surrounding specs. +

    DisabledOption: "DisabledOption"

    The following option is disabled given the inputs.

    +
    InternalError: "InternalError"

    An issue has happened internally.

    +
    InvalidAddress: "InvalidAddress"

    The inputted address is invalid.

    +
    InvalidAsset: "InvalidAsset"

    The inputted asset is incorrect or invalid, and does not exist given the surrounding specs. This exlcudes MultiLocation assets which are handled using InvalidMultiLocationAsset.

    -
    InvalidDirection: "InvalidDirection"

    The direction in which these assets are going to be sent is incorrect.

    -
    InvalidInput: "InvalidInput"

    An input or lack of input to any public facing function by the user is incorrect, and or invalid. +

    InvalidDirection: "InvalidDirection"

    The direction in which these assets are going to be sent is incorrect.

    +
    InvalidInput: "InvalidInput"

    An input or lack of input to any public facing function by the user is incorrect, and or invalid. This may include using options incorrectly.

    -
    InvalidMultiLocationAsset: "InvalidMultiLocationAsset"

    The inputted multilocation is incorrect.

    -
    InvalidPallet: "InvalidPallet"

    The following pallet does not support the method to be used.

    -
    InvalidXcmVersion: "InvalidXcmVersion"

    The xcm version is invalid.

    -
    MultipleNonUniqueAssetsFound: "MultipleNonUniqueAssetsFound"

    Multiple assets have been found for a single token symbol.

    -
    NoFeeAssetLpFound: "NoFeeAssetLpFound"

    The provided paysWithFeeOrigin asset has no liquidity pool.

    -
    NotImplemented: "NotImplemented"

    Not Implemented yet.

    -
    PalletNotFound: "PalletNotFound"

    The following pallet is not found.

    -
    RegistryNotFound: "RegistryNotFound"

    Not able to find the pertinent registry to gather certain information. This can refer to xcAssets.

    -
    UnsupportedEnvironment: "UnsupportedEnvironment"

    The provided JS environment is not supported, and the api will not run.

    -
    \ No newline at end of file +
    InvalidMultiLocationAsset: "InvalidMultiLocationAsset"

    The inputted multilocation is incorrect.

    +
    InvalidPallet: "InvalidPallet"

    The following pallet does not support the method to be used.

    +
    InvalidXcmVersion: "InvalidXcmVersion"

    The xcm version is invalid.

    +
    MultipleNonUniqueAssetsFound: "MultipleNonUniqueAssetsFound"

    Multiple assets have been found for a single token symbol.

    +
    NoFeeAssetLpFound: "NoFeeAssetLpFound"

    The provided paysWithFeeOrigin asset has no liquidity pool.

    +
    NotImplemented: "NotImplemented"

    Not Implemented yet.

    +
    PalletNotFound: "PalletNotFound"

    The following pallet is not found.

    +
    RegistryNotFound: "RegistryNotFound"

    Not able to find the pertinent registry to gather certain information. This can refer to xcAssets.

    +
    SpecNameNotProvided: "SpecNameNotProvided"

    The specName was not provided when injecting a new chain in the registry.

    +
    UnsupportedEnvironment: "UnsupportedEnvironment"

    The provided JS environment is not supported, and the api will not run.

    +
    \ No newline at end of file diff --git a/docs/enums/types.Direction.html b/docs/enums/types.Direction.html index c03b115f..1890dc6e 100644 --- a/docs/enums/types.Direction.html +++ b/docs/enums/types.Direction.html @@ -1,5 +1,5 @@ -Direction | @substrate/asset-transfer-api - v0.1.6

    Represents all possible tx directions

    -

    Enumeration Members

    Local +Direction | @substrate/asset-transfer-api - v0.1.7

    Represents all possible tx directions

    +

    Enumeration Members

    Local: "Local"

    Local tx

    -
    ParaToPara: "ParaToPara"

    Parachain to Parachain.

    -
    ParaToRelay: "ParaToRelay"

    Parachain to Relay chain.

    -
    ParaToSystem: "ParaToSystem"

    Parachain to System parachain.

    -
    RelayToPara: "RelayToPara"

    Relay chain to Parachain.

    -
    RelayToSystem: "RelayToSystem"

    Relay to System Parachain.

    -
    SystemToPara: "SystemToPara"

    System parachain to Parachain.

    -
    SystemToRelay: "SystemToRelay"

    System parachain to Relay chain.

    -
    SystemToSystem: "SystemToSystem"

    System parachain to System parachain chain.

    -
    \ No newline at end of file +
    ParaToPara: "ParaToPara"

    Parachain to Parachain.

    +
    ParaToRelay: "ParaToRelay"

    Parachain to Relay chain.

    +
    ParaToSystem: "ParaToSystem"

    Parachain to System parachain.

    +
    RelayToPara: "RelayToPara"

    Relay chain to Parachain.

    +
    RelayToSystem: "RelayToSystem"

    Relay to System Parachain.

    +
    SystemToPara: "SystemToPara"

    System parachain to Parachain.

    +
    SystemToRelay: "SystemToRelay"

    System parachain to Relay chain.

    +
    SystemToSystem: "SystemToSystem"

    System parachain to System parachain chain.

    +
    \ No newline at end of file diff --git a/docs/functions/constructApiPromise.constructApiPromise.html b/docs/functions/constructApiPromise.constructApiPromise.html index f1cc6dd5..956210c2 100644 --- a/docs/functions/constructApiPromise.constructApiPromise.html +++ b/docs/functions/constructApiPromise.constructApiPromise.html @@ -1,6 +1,6 @@ -constructApiPromise | @substrate/asset-transfer-api - v0.1.6

    Returns Promise<ApiInfo>

    \ No newline at end of file diff --git a/docs/index.html b/docs/index.html index d77f1f17..c6df3e89 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1,4 +1,4 @@ -@substrate/asset-transfer-api - v0.1.6

    @substrate/asset-transfer-api - v0.1.6



    +@substrate/asset-transfer-api - v0.1.7

    @substrate/asset-transfer-api - v0.1.7



    @substrate/asset-transfer-api

    Asset API used for common good parachains

    @@ -127,4 +127,5 @@

    Asset API used for common good parachains

    Copy each binary that is necessary into the root <root>/bin folder.

    Running Zombienet

    From the root directory run ./<zombienet_binary_name> -p native spawn ./zombienet/<network_file>.toml | tee zombienet.log

    Create an asset

    From the root directory run yarn start:zombienet-post-script. You can run this right after running your zombienet network.

    -
    \ No newline at end of file +

    E2E Testing

    You can access the E2E tests and its documentation here.

    +
    \ No newline at end of file diff --git a/docs/interfaces/constructApiPromise.ApiInfo.html b/docs/interfaces/constructApiPromise.ApiInfo.html index 11022e1b..eaf7527b 100644 --- a/docs/interfaces/constructApiPromise.ApiInfo.html +++ b/docs/interfaces/constructApiPromise.ApiInfo.html @@ -1,8 +1,8 @@ -ApiInfo | @substrate/asset-transfer-api - v0.1.6

    Return value for constructApiPromise

    -
    interface ApiInfo {
        api: ApiPromise;
        safeXcmVersion: number;
        specName: string;
    }

    Properties

    api +ApiInfo | @substrate/asset-transfer-api - v0.1.7

    Return value for constructApiPromise

    +
    interface ApiInfo {
        api: ApiPromise;
        safeXcmVersion: number;
        specName: string;
    }

    Properties

    api: ApiPromise

    Polkadot-js ApiPromise

    -
    safeXcmVersion: number

    SafeXcmVersion for the chain which the api is connected too.

    -
    specName: string

    SpecName of the chain which the api is connected to.

    -
    \ No newline at end of file +
    safeXcmVersion: number

    SafeXcmVersion for the chain which the api is connected too.

    +
    specName: string

    SpecName of the chain which the api is connected to.

    +
    \ No newline at end of file diff --git a/docs/interfaces/types.TransferArgsOpts.html b/docs/interfaces/types.TransferArgsOpts.html index d46c0d4f..d4a49a45 100644 --- a/docs/interfaces/types.TransferArgsOpts.html +++ b/docs/interfaces/types.TransferArgsOpts.html @@ -1,5 +1,5 @@ -TransferArgsOpts | @substrate/asset-transfer-api - v0.1.6

    The TransferArgsOpts are the options passed into createTransferTransaction.

    -
    interface TransferArgsOpts {
        format?: T;
        isLimited?: boolean;
        keepAlive?: boolean;
        paysWithFeeDest?: string;
        paysWithFeeOrigin?: string;
        sendersAddr?: string;
        transferLiquidToken?: boolean;
        weightLimit?: {
            proofSize?: string;
            refTime?: string;
        };
        xcmVersion?: number;
    }

    Type Parameters

    Properties

    format? +TransferArgsOpts | @substrate/asset-transfer-api - v0.1.7

    The TransferArgsOpts are the options passed into createTransferTransaction.

    +
    interface TransferArgsOpts {
        format?: T;
        isLimited?: boolean;
        keepAlive?: boolean;
        paysWithFeeDest?: string;
        paysWithFeeOrigin?: string;
        sendersAddr?: string;
        transferLiquidToken?: boolean;
        weightLimit?: {
            proofSize?: string;
            refTime?: string;
        };
        xcmVersion?: number;
    }

    Type Parameters

    Properties

    format? isLimited? keepAlive? paysWithFeeDest? @@ -12,24 +12,24 @@ It can either be a payload, call, or submittable.

    Note: A submittable will return a SubmittableExtrinsic polkadot-js type, whereas a payload or call will return a hex.

    -
    isLimited?: boolean

    Boolean to declare if this will be with limited XCM transfers. +

    isLimited?: boolean

    Boolean to declare if this will be with limited XCM transfers. Deafult is unlimited.

    -
    keepAlive?: boolean

    For creating local asset transfers, this will allow for a transferKeepAlive as oppose +

    keepAlive?: boolean

    For creating local asset transfers, this will allow for a transferKeepAlive as oppose to a transfer.

    -
    paysWithFeeDest?: string

    AssetId to pay fee's on the destination parachain.

    -
    paysWithFeeOrigin?: string

    AssetId to pay fee's on the current common good parachain. +

    paysWithFeeDest?: string

    AssetId to pay fee's on the destination parachain.

    +
    paysWithFeeOrigin?: string

    AssetId to pay fee's on the current common good parachain. Polkadot AssetHub: default DOT Kusama AssetHub: default KSM

    -
    sendersAddr?: string

    The SS58 Address the tx will be sent from. This is specifically used for the format payload. +

    sendersAddr?: string

    The SS58 Address the tx will be sent from. This is specifically used for the format payload. It is necessary because the payload will need information such as the nonce.

    -
    transferLiquidToken?: boolean

    Boolean to declare if this will transfer liquidity tokens. +

    transferLiquidToken?: boolean

    Boolean to declare if this will transfer liquidity tokens. Default is false.

    -
    weightLimit?: {
        proofSize?: string;
        refTime?: string;
    }

    When isLimited is true, the option for applying a weightLimit is possible. +

    weightLimit?: {
        proofSize?: string;
        refTime?: string;
    }

    When isLimited is true, the option for applying a weightLimit is possible. If not inputted it will default to Unlimited.

    Type declaration

    • Optional proofSize?: string

      Provided when creating limited txs, represents the amount of storage in bytes that can be used by the tx

    • Optional refTime?: string

      Provided when creating limited txs, represents the allowed amount of computation time the tx can use

      -
    xcmVersion?: number

    Set the xcmVersion for message construction. If this is not present a supported version +

    xcmVersion?: number

    Set the xcmVersion for message construction. If this is not present a supported version will be queried, and if there is no supported version a safe version will be queried.

    -
    \ No newline at end of file +
    \ No newline at end of file diff --git a/docs/interfaces/types.TxResult.html b/docs/interfaces/types.TxResult.html index 0b3642b2..30ba1a4e 100644 --- a/docs/interfaces/types.TxResult.html +++ b/docs/interfaces/types.TxResult.html @@ -1,6 +1,6 @@ -TxResult | @substrate/asset-transfer-api - v0.1.6

    The TxResult is the result of constructing a transaction. +TxResult | @substrate/asset-transfer-api - v0.1.7

    The TxResult is the result of constructing a transaction. T extends Format in the context of the options passed in for the Format the user expects.

    -
    interface TxResult {
        dest: string;
        direction: Direction | "local";
        format: Format | "local";
        method: Methods;
        origin: string;
        tx: ConstructedFormat<T>;
        xcmVersion: null | number;
    }

    Type Parameters

    • T

    Properties

    interface TxResult {
        dest: string;
        direction: Direction | "local";
        format: Format | "local";
        method: Methods;
        origin: string;
        tx: ConstructedFormat<T>;
        xcmVersion: null | number;
    }

    Type Parameters

    • T

    Properties

    Properties

    dest: string

    Description

    The destination specName of the transaction

    -
    direction: Direction | "local"

    Description

    The direction of the cross chain transfer.

    -
    format: Format | "local"

    Description

    The format type the tx is ouputted in.

    -
    method: Methods

    Description

    The method used in the transaction.

    -
    origin: string

    Description

    The origin specName of the transaction

    -

    Description

    The constructed transaction.

    -
    xcmVersion: null | number

    Description

    The xcm version that was used to construct the tx.

    -
    \ No newline at end of file +
    direction: Direction | "local"

    Description

    The direction of the cross chain transfer.

    +
    format: Format | "local"

    Description

    The format type the tx is ouputted in.

    +
    method: Methods

    Description

    The method used in the transaction.

    +
    origin: string

    Description

    The origin specName of the transaction

    +

    Description

    The constructed transaction.

    +
    xcmVersion: null | number

    Description

    The xcm version that was used to construct the tx.

    +
    \ No newline at end of file diff --git a/docs/modules/AssetTransferApi.html b/docs/modules/AssetTransferApi.html index e61408f9..c0493e08 100644 --- a/docs/modules/AssetTransferApi.html +++ b/docs/modules/AssetTransferApi.html @@ -1,2 +1,2 @@ -AssetTransferApi | @substrate/asset-transfer-api - v0.1.6
    \ No newline at end of file +AssetTransferApi | @substrate/asset-transfer-api - v0.1.7
    \ No newline at end of file diff --git a/docs/modules/constructApiPromise.html b/docs/modules/constructApiPromise.html index f4525fa9..a1ab30a5 100644 --- a/docs/modules/constructApiPromise.html +++ b/docs/modules/constructApiPromise.html @@ -1,3 +1,3 @@ -constructApiPromise | @substrate/asset-transfer-api - v0.1.6

    Index

    Interfaces

    ApiInfo +constructApiPromise | @substrate/asset-transfer-api - v0.1.7
    \ No newline at end of file +
    \ No newline at end of file diff --git a/docs/modules/errors_BaseError.html b/docs/modules/errors_BaseError.html index c29d8be9..507860ae 100644 --- a/docs/modules/errors_BaseError.html +++ b/docs/modules/errors_BaseError.html @@ -1,2 +1,2 @@ -errors/BaseError | @substrate/asset-transfer-api - v0.1.6
    \ No newline at end of file +errors/BaseError | @substrate/asset-transfer-api - v0.1.7
    \ No newline at end of file diff --git a/docs/modules/types.html b/docs/modules/types.html index da642990..99df3e02 100644 --- a/docs/modules/types.html +++ b/docs/modules/types.html @@ -1,4 +1,4 @@ -types | @substrate/asset-transfer-api - v0.1.6

    Index

    Enumerations

    Direction +types | @substrate/asset-transfer-api - v0.1.7
    \ No newline at end of file +
    \ No newline at end of file diff --git a/docs/types/types.AssetTransferApiOpts.html b/docs/types/types.AssetTransferApiOpts.html index 807aa33b..0f8928ad 100644 --- a/docs/types/types.AssetTransferApiOpts.html +++ b/docs/types/types.AssetTransferApiOpts.html @@ -1,5 +1,5 @@ -AssetTransferApiOpts | @substrate/asset-transfer-api - v0.1.6
    AssetTransferApiOpts: {
        injectedRegistry?: RequireAtLeastOne<ChainInfoRegistry>;
        registryType?: RegistryTypes;
    }

    Options that are appplied at initialization of the AssetTransferApi.

    -

    Type declaration

    • Optional injectedRegistry?: RequireAtLeastOne<ChainInfoRegistry>

      Option to inject chain information into the registry.

      +AssetTransferApiOpts | @substrate/asset-transfer-api - v0.1.7
      AssetTransferApiOpts<T>: {
          injectedRegistry?: RequireAtLeastOne<ChainInfoRegistry<T>>;
          registryType?: RegistryTypes;
      }

      Options that are appplied at initialization of the AssetTransferApi.

      +

      Type Parameters

      • T extends ChainInfoKeys | InjectedChainInfoKeys

      Type declaration

      • Optional injectedRegistry?: RequireAtLeastOne<ChainInfoRegistry<T>>

        Option to inject chain information into the registry.

      • Optional registryType?: RegistryTypes

        Whether or not to apply the registry from the npm package asset-transfer-api-registry, or the hosted CDN which updates frequently.

        -
      \ No newline at end of file +
    \ No newline at end of file diff --git a/docs/types/types.ConstructedFormat.html b/docs/types/types.ConstructedFormat.html index 229a08eb..a13c6b18 100644 --- a/docs/types/types.ConstructedFormat.html +++ b/docs/types/types.ConstructedFormat.html @@ -1,2 +1,2 @@ -ConstructedFormat | @substrate/asset-transfer-api - v0.1.6
    ConstructedFormat<T>: T extends "payload"
        ? `0x${string}`
        : T extends "call"
            ? `0x${string}`
            : T extends "submittable"
                ? SubmittableExtrinsic<"promise", ISubmittableResult>
                : never

    The Format types possible for a constructed transaction.

    -

    Type Parameters

    • T

    \ No newline at end of file +ConstructedFormat | @substrate/asset-transfer-api - v0.1.7
    ConstructedFormat<T>: T extends "payload"
        ? `0x${string}`
        : T extends "call"
            ? `0x${string}`
            : T extends "submittable"
                ? SubmittableExtrinsic<"promise", ISubmittableResult>
                : never

    The Format types possible for a constructed transaction.

    +

    Type Parameters

    • T

    \ No newline at end of file diff --git a/docs/types/types.Format.html b/docs/types/types.Format.html index daac4a23..feff95f1 100644 --- a/docs/types/types.Format.html +++ b/docs/types/types.Format.html @@ -1,7 +1,7 @@ -Format | @substrate/asset-transfer-api - v0.1.6
    Format: "payload" | "call" | "submittable"

    AssetTransferApi supports three formats to be returned:

    +Format | @substrate/asset-transfer-api - v0.1.7
    Format: "payload" | "call" | "submittable"

    AssetTransferApi supports three formats to be returned:

    • payload: This returns a Polkadot-js ExtrinsicPayload as a hex.
    • call: This returns a Polkadot-js Call as a hex.
    • submittable: This returns a Polkadot-js SubmittableExtrinsic.
    -
    \ No newline at end of file +
    \ No newline at end of file diff --git a/docs/types/types.LocalTransferTypes.html b/docs/types/types.LocalTransferTypes.html index 971965f4..8113dd5e 100644 --- a/docs/types/types.LocalTransferTypes.html +++ b/docs/types/types.LocalTransferTypes.html @@ -1,2 +1,2 @@ -LocalTransferTypes | @substrate/asset-transfer-api - v0.1.6
    LocalTransferTypes: "assets::transfer" | "assets::transferKeepAlive" | "foreignAssets::transfer" | "foreignAssets::transferKeepAlive" | "balances::transfer" | "balances::transferKeepAlive" | "poolAssets::transfer" | "poolAssets::transferKeepAlive" | "tokens::transfer" | "tokens::transferKeepAlive"

    The types of local transactions the api can construct.

    -
    \ No newline at end of file +LocalTransferTypes | @substrate/asset-transfer-api - v0.1.7
    LocalTransferTypes: "assets::transfer" | "assets::transferKeepAlive" | "foreignAssets::transfer" | "foreignAssets::transferKeepAlive" | "balances::transfer" | "balances::transferKeepAlive" | "poolAssets::transfer" | "poolAssets::transferKeepAlive" | "tokens::transfer" | "tokens::transferKeepAlive"

    The types of local transactions the api can construct.

    +
    \ No newline at end of file diff --git a/docs/types/types.Methods.html b/docs/types/types.Methods.html index 3128099d..645d84a8 100644 --- a/docs/types/types.Methods.html +++ b/docs/types/types.Methods.html @@ -1,2 +1,2 @@ -Methods | @substrate/asset-transfer-api - v0.1.6
    Methods: LocalTransferTypes | "reserveTransferAssets" | "limitedReserveTransferAssets" | "teleportAssets" | "limitedTeleportAssets" | "transferMultiasset" | "transferMultiassets" | "transferMultiassetWithFee"

    The Methods are the collections of methods the API will use to construct a transaction.

    -
    \ No newline at end of file +Methods | @substrate/asset-transfer-api - v0.1.7
    Methods: LocalTransferTypes | "reserveTransferAssets" | "limitedReserveTransferAssets" | "teleportAssets" | "limitedTeleportAssets" | "transferMultiasset" | "transferMultiassets" | "transferMultiassetWithFee"

    The Methods are the collections of methods the API will use to construct a transaction.

    +
    \ No newline at end of file diff --git a/docs/types/types.RegistryTypes.html b/docs/types/types.RegistryTypes.html index 139172b5..8742f471 100644 --- a/docs/types/types.RegistryTypes.html +++ b/docs/types/types.RegistryTypes.html @@ -1,4 +1,4 @@ -RegistryTypes | @substrate/asset-transfer-api - v0.1.6
    RegistryTypes: "CDN" | "NPM"

    Types that the registry can be initialized as.

    +RegistryTypes | @substrate/asset-transfer-api - v0.1.7
    RegistryTypes: "CDN" | "NPM"

    Types that the registry can be initialized as.

    CDN - The registry will be initialized with the up to date version given the CDN NPM - The registry will be initialized with the NPM version which is updated less frequently.

    -
    \ No newline at end of file +
    \ No newline at end of file diff --git a/docs/types/types.XcmDirection.html b/docs/types/types.XcmDirection.html index 9c8ffe9f..ec4bc175 100644 --- a/docs/types/types.XcmDirection.html +++ b/docs/types/types.XcmDirection.html @@ -1,2 +1,2 @@ -XcmDirection | @substrate/asset-transfer-api - v0.1.6
    XcmDirection: Exclude<Direction, "Local">

    The direction of the cross chain transfer. This only concerns XCM transactions.

    -
    \ No newline at end of file +XcmDirection | @substrate/asset-transfer-api - v0.1.7
    XcmDirection: Exclude<Direction, "Local">

    The direction of the cross chain transfer. This only concerns XCM transactions.

    +
    \ No newline at end of file diff --git a/package.json b/package.json index 603ce380..408088c4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@substrate/asset-transfer-api", - "version": "0.1.6", + "version": "0.1.7", "description": "", "main": "lib/index.js", "scripts": {