Skip to content

Commit e77fcc7

Browse files
web-flowpenovicp
authored andcommitted
docs: generate documentation version
1 parent 207da4e commit e77fcc7

File tree

221 files changed

+47649
-1
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

221 files changed

+47649
-1
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
label: 'API'

www/versioned_docs/version-6.24.1/API/classes/Account.md

Lines changed: 2885 additions & 0 deletions
Large diffs are not rendered by default.

www/versioned_docs/version-6.24.1/API/classes/AccountInterface.md

Lines changed: 1302 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 245 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,245 @@
1+
---
2+
id: 'BatchClient'
3+
title: 'Class: BatchClient'
4+
sidebar_label: 'BatchClient'
5+
sidebar_position: 0
6+
custom_edit_url: null
7+
---
8+
9+
## Constructors
10+
11+
### constructor
12+
13+
**new BatchClient**(`options`): [`BatchClient`](BatchClient.md)
14+
15+
#### Parameters
16+
17+
| Name | Type |
18+
| :-------- | :------------------------------------------------------- |
19+
| `options` | [`BatchClientOptions`](../modules.md#batchclientoptions) |
20+
21+
#### Returns
22+
23+
[`BatchClient`](BatchClient.md)
24+
25+
#### Defined in
26+
27+
[src/utils/batch/index.ts:33](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L33)
28+
29+
## Properties
30+
31+
### nodeUrl
32+
33+
**nodeUrl**: `string`
34+
35+
#### Defined in
36+
37+
[src/utils/batch/index.ts:13](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L13)
38+
39+
---
40+
41+
### headers
42+
43+
**headers**: `object`
44+
45+
#### Defined in
46+
47+
[src/utils/batch/index.ts:15](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L15)
48+
49+
---
50+
51+
### interval
52+
53+
**interval**: `number`
54+
55+
#### Defined in
56+
57+
[src/utils/batch/index.ts:17](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L17)
58+
59+
---
60+
61+
### requestId
62+
63+
**requestId**: `number` = `0`
64+
65+
#### Defined in
66+
67+
[src/utils/batch/index.ts:19](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L19)
68+
69+
---
70+
71+
### pendingRequests
72+
73+
`Private` **pendingRequests**: `Record`<`string` \| `number`, [`RequestBody`](../namespaces/types.RPC.JRPC.md#requestbody)\> = `{}`
74+
75+
#### Defined in
76+
77+
[src/utils/batch/index.ts:21](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L21)
78+
79+
---
80+
81+
### batchPromises
82+
83+
`Private` **batchPromises**: `Record`<`string` \| `number`, `Promise`<[`ResponseBody`](../namespaces/types.RPC.JRPC.md#responsebody)[]\>\> = `{}`
84+
85+
#### Defined in
86+
87+
[src/utils/batch/index.ts:23](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L23)
88+
89+
---
90+
91+
### delayTimer
92+
93+
`Private` `Optional` **delayTimer**: `Timeout`
94+
95+
#### Defined in
96+
97+
[src/utils/batch/index.ts:25](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L25)
98+
99+
---
100+
101+
### delayPromise
102+
103+
`Private` `Optional` **delayPromise**: `Promise`<`void`\>
104+
105+
#### Defined in
106+
107+
[src/utils/batch/index.ts:27](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L27)
108+
109+
---
110+
111+
### delayPromiseResolve
112+
113+
`Private` `Optional` **delayPromiseResolve**: () => `void`
114+
115+
#### Type declaration
116+
117+
▸ (): `void`
118+
119+
##### Returns
120+
121+
`void`
122+
123+
#### Defined in
124+
125+
[src/utils/batch/index.ts:29](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L29)
126+
127+
---
128+
129+
### baseFetch
130+
131+
`Private` **baseFetch**: (`input`: `RequestInfo` \| `URL`, `init?`: `RequestInit`) => `Promise`<`Response`\>
132+
133+
#### Type declaration
134+
135+
▸ (`input`, `init?`): `Promise`<`Response`\>
136+
137+
##### Parameters
138+
139+
| Name | Type |
140+
| :------ | :--------------------- |
141+
| `input` | `RequestInfo` \| `URL` |
142+
| `init?` | `RequestInit` |
143+
144+
##### Returns
145+
146+
`Promise`<`Response`\>
147+
148+
#### Defined in
149+
150+
[src/utils/batch/index.ts:31](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L31)
151+
152+
## Methods
153+
154+
### wait
155+
156+
**wait**(): `Promise`<`void`\>
157+
158+
#### Returns
159+
160+
`Promise`<`void`\>
161+
162+
#### Defined in
163+
164+
[src/utils/batch/index.ts:40](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L40)
165+
166+
---
167+
168+
### addPendingRequest
169+
170+
**addPendingRequest**<`T`\>(`method`, `params?`, `id?`): `string` \| `number`
171+
172+
#### Type parameters
173+
174+
| Name | Type |
175+
| :--- | :-------------------------------------------------------------------------- |
176+
| `T` | extends keyof `ReadMethods` \| keyof `WriteMethods` \| keyof `TraceMethods` |
177+
178+
#### Parameters
179+
180+
| Name | Type |
181+
| :-------- | :------------------------------------------------------------------------------- |
182+
| `method` | `T` |
183+
| `params?` | [`Methods`](../namespaces/types.RPC.RPCSPEC07.API.md#methods)[`T`][``"params"``] |
184+
| `id?` | `string` \| `number` |
185+
186+
#### Returns
187+
188+
`string` \| `number`
189+
190+
#### Defined in
191+
192+
[src/utils/batch/index.ts:66](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L66)
193+
194+
---
195+
196+
### sendBatch
197+
198+
**sendBatch**(`requests`): `Promise`<`any`\>
199+
200+
#### Parameters
201+
202+
| Name | Type |
203+
| :--------- | :------------------------------------------------------------- |
204+
| `requests` | [`RequestBody`](../namespaces/types.RPC.JRPC.md#requestbody)[] |
205+
206+
#### Returns
207+
208+
`Promise`<`any`\>
209+
210+
#### Defined in
211+
212+
[src/utils/batch/index.ts:83](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L83)
213+
214+
---
215+
216+
### fetch
217+
218+
**fetch**<`T`, `TResponse`\>(`method`, `params?`, `id?`): `Promise`<`TResponse`\>
219+
220+
Automatically batches and fetches JSON-RPC calls in a single request.
221+
222+
#### Type parameters
223+
224+
| Name | Type |
225+
| :---------- | :-------------------------------------------------------------------------- |
226+
| `T` | extends keyof `ReadMethods` \| keyof `WriteMethods` \| keyof `TraceMethods` |
227+
| `TResponse` | extends `Object` |
228+
229+
#### Parameters
230+
231+
| Name | Type | Description |
232+
| :-------- | :------------------------------------------------------------------------------- | :------------------ |
233+
| `method` | `T` | Method to call |
234+
| `params?` | [`Methods`](../namespaces/types.RPC.RPCSPEC07.API.md#methods)[`T`][``"params"``] | Method parameters |
235+
| `id?` | `string` \| `number` | JSON-RPC Request ID |
236+
237+
#### Returns
238+
239+
`Promise`<`TResponse`\>
240+
241+
JSON-RPC Response
242+
243+
#### Defined in
244+
245+
[src/utils/batch/index.ts:100](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/batch/index.ts#L100)
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
---
2+
id: 'CairoCustomEnum'
3+
title: 'Class: CairoCustomEnum'
4+
sidebar_label: 'CairoCustomEnum'
5+
sidebar_position: 0
6+
custom_edit_url: null
7+
---
8+
9+
Class to handle Cairo custom Enum
10+
11+
**`Param`**
12+
13+
object containing the variants and its content. Example :
14+
{Success: 234, Warning: undefined, Error: undefined}.
15+
Only one variant with a value, object, array.
16+
17+
**`Example`**
18+
19+
```typescript
20+
const myCairoEnum = new CairoCustomEnum({
21+
Success: undefined,
22+
Warning: '0x7f32ea',
23+
Error: undefined,
24+
});
25+
```
26+
27+
## Constructors
28+
29+
### constructor
30+
31+
**new CairoCustomEnum**(`enumContent`): [`CairoCustomEnum`](CairoCustomEnum.md)
32+
33+
#### Parameters
34+
35+
| Name | Type | Description |
36+
| :------------ | :------------------------------------------- | :----------------------------------------------------------------------------------------------- |
37+
| `enumContent` | [`CairoEnumRaw`](../modules.md#cairoenumraw) | an object with the variants as keys and the content as value. Only one content shall be defined. |
38+
39+
#### Returns
40+
41+
[`CairoCustomEnum`](CairoCustomEnum.md)
42+
43+
#### Defined in
44+
45+
[src/utils/calldata/enum/CairoCustomEnum.ts:29](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/calldata/enum/CairoCustomEnum.ts#L29)
46+
47+
## Properties
48+
49+
### variant
50+
51+
`Readonly` **variant**: [`CairoEnumRaw`](../modules.md#cairoenumraw)
52+
53+
direct readonly access to variants of the Cairo Custom Enum.
54+
55+
**`Example`**
56+
57+
```typescript
58+
const successValue = myCairoEnum.variant.Success;
59+
60+
#### Defined in
61+
62+
[src/utils/calldata/enum/CairoCustomEnum.ts:24](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/calldata/enum/CairoCustomEnum.ts#L24)
63+
64+
## Methods
65+
66+
### unwrap
67+
68+
**unwrap**(): `any`
69+
70+
#### Returns
71+
72+
`any`
73+
74+
the content of the valid variant of a Cairo custom Enum.
75+
76+
#### Defined in
77+
78+
[src/utils/calldata/enum/CairoCustomEnum.ts:45](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/calldata/enum/CairoCustomEnum.ts#L45)
79+
80+
___
81+
82+
### activeVariant
83+
84+
▸ **activeVariant**(): `string`
85+
86+
#### Returns
87+
88+
`string`
89+
90+
the name of the valid variant of a Cairo custom Enum.
91+
92+
#### Defined in
93+
94+
[src/utils/calldata/enum/CairoCustomEnum.ts:54](https://github.com/starknet-io/starknet.js/blob/v6.24.1/src/utils/calldata/enum/CairoCustomEnum.ts#L54)
95+
```

0 commit comments

Comments
 (0)