Skip to content

Commit

Permalink
fix: moving asset transfer api to variable
Browse files Browse the repository at this point in the history
  • Loading branch information
nhussein11 committed Dec 16, 2024
1 parent fc1ca3d commit 31416ce
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Options for customizing the claim assets transaction. These options allow you to
??? child "Type `Format`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:122:122'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:122:122'
```

---
Expand Down Expand Up @@ -60,7 +60,7 @@ Options for customizing the claim assets transaction. These options allow you to
??? child "Type `AssetTransferType`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:480:480'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:480:480'
```
!!! note
Expand All @@ -82,7 +82,7 @@ Options for customizing the claim assets transaction. These options allow you to
??? child "Type `AssetTransferType`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:480:480'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:480:480'
```
!!! note
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ A promise containing the result of constructing the transaction.
??? child "Type `Format`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:122:122'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:122:122'
```

---
Expand Down Expand Up @@ -109,14 +109,14 @@ A promise containing the result of constructing the transaction.
??? child "Type `Methods`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:153:162'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:153:162'
```

??? child "Type `LocalTransferTypes`"


```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:138:148'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:138:148'
```

---
Expand All @@ -128,10 +128,10 @@ A promise containing the result of constructing the transaction.
??? child "Type `ConstructedFormat<T>`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:127:133'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:127:133'
```

The `ConstructedFormat` type is a conditional type that returns a specific type based on the value of the TxResult `format` field.
The `ConstructedFormat` type is a conditional type that returns a specific type based on the value of the `TxResult` `format` field.

- **Payload format** - if the format field is set to `'payload'`, the `ConstructedFormat` type will return a [`GenericExtrinsicPayload`](https://github.com/polkadot-js/api/blob/3b7b44f048ff515579dd233ea6964acec39c0589/packages/types/src/extrinsic/ExtrinsicPayload.ts#L48){target=\_blank}
- **Call format** - if the format field is set to `'call'`, the `ConstructedFormat` type will return a hexadecimal string (`0x${string}`). This is the encoded representation of the extrinsic call
Expand Down
14 changes: 7 additions & 7 deletions develop/toolkit/interoperability/asset-transfer-api/reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ Creates a local XCM transaction to retrieve trapped assets. This function can be


```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/AssetTransferApi.ts:344:349'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/AssetTransferApi.ts:344:349'
```

??? interface "Request parameters"
Expand Down Expand Up @@ -153,7 +153,7 @@ Creates a local XCM transaction to retrieve trapped assets. This function can be
Decodes the hex of an extrinsic into a string readable format.

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/AssetTransferApi.ts:466:466'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/AssetTransferApi.ts:466:466'
```

??? interface "Request parameters"
Expand All @@ -171,7 +171,7 @@ Decodes the hex of an extrinsic into a string readable format.
??? child "Type `Format`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:122:122'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:122:122'
```

??? interface "Response parameters"
Expand All @@ -197,7 +197,7 @@ Decodes the hex of an extrinsic into a string readable format.
Fetch estimated fee information for an extrinsic.

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/AssetTransferApi.ts:420:423'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/AssetTransferApi.ts:420:423'
```

??? interface "Request parameters"
Expand All @@ -209,10 +209,10 @@ Fetch estimated fee information for an extrinsic.
??? child "Type `ConstructedFormat<T>`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:127:133'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:127:133'
```

The `ConstructedFormat` type is a conditional type that returns a specific type based on the value of the TxResult `format` field.
The `ConstructedFormat` type is a conditional type that returns a specific type based on the value of the `TxResult` `format` field.

- Payload format - if the format field is set to `'payload'`, the `ConstructedFormat` type will return a [`GenericExtrinsicPayload`](https://github.com/polkadot-js/api/blob/3b7b44f048ff515579dd233ea6964acec39c0589/packages/types/src/extrinsic/ExtrinsicPayload.ts#L48){target=\_blank}
- Call format - if the format field is set to `'call'`, the `ConstructedFormat` type will return a hexadecimal string (`0x${string}`). This is the encoded representation of the extrinsic call
Expand All @@ -227,7 +227,7 @@ Fetch estimated fee information for an extrinsic.
??? child "Type `Format`"

```ts
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/v0.3.1/src/types.ts:122:122'
--8<-- 'https://raw.githubusercontent.com/paritytech/asset-transfer-api/refs/tags/{{ dependencies.asset_transfer_api.version }}/src/types.ts:122:122'
```

??? interface "Response parameters"
Expand Down

0 comments on commit 31416ce

Please sign in to comment.