diff --git a/docs/sdk/python/human_protocol_sdk.escrow.escrow_utils.md b/docs/sdk/python/human_protocol_sdk.escrow.escrow_utils.md index 9d4645d552..7638365935 100644 --- a/docs/sdk/python/human_protocol_sdk.escrow.escrow_utils.md +++ b/docs/sdk/python/human_protocol_sdk.escrow.escrow_utils.md @@ -108,45 +108,48 @@ Get an array of escrow addresses based on the specified filter parameters. ) ``` -#### *static* get_status_events(chain_id, statuses=None, date_from=None, date_to=None, launcher=None, first=10, skip=0, order_direction=OrderDirection.DESC) +#### *static* get_payouts(filter) + +Fetch payouts from the subgraph based on the provided filter. + +* **Parameters:** + **filter** ([`PayoutFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.PayoutFilter)) – Object containing all the necessary parameters to filter payouts. +* **Return List[Payout]:** + List of payouts matching the query parameters. +* **Raises:** + [**EscrowClientError**](human_protocol_sdk.escrow.escrow_client.md#human_protocol_sdk.escrow.escrow_client.EscrowClientError) – If an unsupported chain ID or invalid addresses are provided. +* **Return type:** + `List`[[`Payout`](#human_protocol_sdk.escrow.escrow_utils.Payout)] + +#### *static* get_status_events(filter) Retrieve status events for specified networks and statuses within a date range. * **Parameters:** - * **chain_id** ([`ChainId`](human_protocol_sdk.constants.md#human_protocol_sdk.constants.ChainId)) – Network to request data. - * **(****Optional****[****List****[****Status****]****]****)** (*statuses*) – List of statuses to filter by. - * **(****Optional****[****datetime****]****)** (*date_to*) – Start date for the query range. - * **(****Optional****[****datetime****]****)** – End date for the query range. - * **(****Optional****[****str****]****)** (*launcher*) – Address of the launcher to filter by. - * **(****int****)** (*skip*) – Number of items per page. - * **(****int****)** – Page number to retrieve. - * **(****OrderDirection****)** (*order_direction*) – Order of results, “asc” or “desc”. + **filter** ([`StatusEventFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatusEventFilter)) – Object containing all the necessary parameters to filter status events. * **Return List[StatusEvent]:** List of status events matching the query parameters. * **Raises:** [**EscrowClientError**](human_protocol_sdk.escrow.escrow_client.md#human_protocol_sdk.escrow.escrow_client.EscrowClientError) – If an unsupported chain ID or invalid launcher address is provided. -* **Example:** - ```python - from datetime import datetime - from human_protocol_sdk.constants import ChainId, Status - from human_protocol_sdk.escrow import EscrowUtils - - print( - EscrowUtils.get_status_events( - chain_id=ChainId.POLYGON_AMOY, - statuses=[Status.Pending, Status.Paid], - date_from=datetime(2023, 1, 1), - date_to=datetime(2023, 12, 31), - launcher="0x1234567890abcdef1234567890abcdef12345678", - first=20, - skip=0, - order_direction=OrderDirection.DESC - ) - ) - ``` * **Return type:** `List`[[`StatusEvent`](#human_protocol_sdk.escrow.escrow_utils.StatusEvent)] +### *class* human_protocol_sdk.escrow.escrow_utils.Payout(id, escrow_address, recipient, amount, created_at) + +Bases: `object` + +Initializes a Payout instance. + +* **Parameters:** + * **id** (`str`) – The id of the payout. + * **chain_id** – The chain identifier where the payout occurred. + * **escrow_address** (`str`) – The address of the escrow that executed the payout. + * **recipient** (`str`) – The address of the recipient. + * **amount** (`int`) – The amount of the payout. + * **created_at** (`int`) – The time of creation of the payout. + +#### \_\_init_\_(id, escrow_address, recipient, amount, created_at) + ### *class* human_protocol_sdk.escrow.escrow_utils.StatusEvent(timestamp, status, chain_id, escrow_address) Bases: `object` diff --git a/docs/sdk/python/human_protocol_sdk.escrow.md b/docs/sdk/python/human_protocol_sdk.escrow.md index 8ee3c93e5b..deed876bfc 100644 --- a/docs/sdk/python/human_protocol_sdk.escrow.md +++ b/docs/sdk/python/human_protocol_sdk.escrow.md @@ -48,6 +48,9 @@ obtain information from both the contracts and subgraph. * [`EscrowUtils`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowUtils) * [`EscrowUtils.get_escrow()`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowUtils.get_escrow) * [`EscrowUtils.get_escrows()`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowUtils.get_escrows) + * [`EscrowUtils.get_payouts()`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowUtils.get_payouts) * [`EscrowUtils.get_status_events()`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowUtils.get_status_events) + * [`Payout`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.Payout) + * [`Payout.__init__()`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.Payout.__init__) * [`StatusEvent`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.StatusEvent) * [`StatusEvent.__init__()`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.StatusEvent.__init__) diff --git a/docs/sdk/python/human_protocol_sdk.filter.md b/docs/sdk/python/human_protocol_sdk.filter.md index 9572274f11..63f0e0e1d7 100644 --- a/docs/sdk/python/human_protocol_sdk.filter.md +++ b/docs/sdk/python/human_protocol_sdk.filter.md @@ -30,21 +30,25 @@ Bases: `Exception` Raises when some error happens when building filter object. -### *class* human_protocol_sdk.filter.PayoutFilter(escrow_address=None, recipient=None, date_from=None, date_to=None) +### *class* human_protocol_sdk.filter.PayoutFilter(chain_id, escrow_address=None, recipient=None, date_from=None, date_to=None, first=10, skip=0, order_direction=OrderDirection.DESC) Bases: `object` A class used to filter payout requests. -#### \_\_init_\_(escrow_address=None, recipient=None, date_from=None, date_to=None) +#### \_\_init_\_(chain_id, escrow_address=None, recipient=None, date_from=None, date_to=None, first=10, skip=0, order_direction=OrderDirection.DESC) -Initializes a PayoutFilter instance. +Initializes a filter for payouts. * **Parameters:** - * **escrow_address** (`Optional`[`str`]) – Escrow address - * **recipient** (`Optional`[`str`]) – Recipient address - * **date_from** (`Optional`[`datetime`]) – Created from date - * **date_to** (`Optional`[`datetime`]) – Created to date + * **chain_id** ([`ChainId`](human_protocol_sdk.constants.md#human_protocol_sdk.constants.ChainId)) – The chain ID where the payouts are recorded. + * **escrow_address** (`Optional`[`str`]) – Optional escrow address to filter payouts. + * **recipient** (`Optional`[`str`]) – Optional recipient address to filter payouts. + * **date_from** (`Optional`[`datetime`]) – Optional start date for filtering. + * **date_to** (`Optional`[`datetime`]) – Optional end date for filtering. + * **first** (`int`) – Optional number of payouts per page. Default is 10. + * **skip** (`int`) – Optional number of payouts to skip. Default is 0. + * **order_direction** ([`OrderDirection`](human_protocol_sdk.constants.md#human_protocol_sdk.constants.OrderDirection)) – Optional order direction. Default is DESC. ### *class* human_protocol_sdk.filter.StatisticsFilter(date_from=None, date_to=None, first=10, skip=0, order_direction=OrderDirection.ASC) @@ -74,6 +78,24 @@ A class used to filter statistical data. #### \_\_init_\_(date_from=None, date_to=None, first=10, skip=0, order_direction=OrderDirection.ASC) +### *class* human_protocol_sdk.filter.StatusEventFilter(chain_id, statuses=None, date_from=None, date_to=None, launcher=None, first=10, skip=0, order_direction=OrderDirection.DESC) + +Bases: `object` + +#### \_\_init_\_(chain_id, statuses=None, date_from=None, date_to=None, launcher=None, first=10, skip=0, order_direction=OrderDirection.DESC) + +Initializes a filter for status events. + +* **Parameters:** + * **chain_id** ([`ChainId`](human_protocol_sdk.constants.md#human_protocol_sdk.constants.ChainId)) – The chain ID where the events are recorded. + * **statuses** (`Optional`[`List`[[`Status`](human_protocol_sdk.constants.md#human_protocol_sdk.constants.Status)]]) – Optional list of statuses to filter by. + * **date_from** (`Optional`[`datetime`]) – Optional start date for filtering. + * **date_to** (`Optional`[`datetime`]) – Optional end date for filtering. + * **launcher** (`Optional`[`str`]) – Optional launcher address to filter by. + * **first** (`int`) – Optional number of events per page. Default is 10. + * **skip** (`int`) – Optional number of events to skip. Default is 0. + * **order_direction** ([`OrderDirection`](human_protocol_sdk.constants.md#human_protocol_sdk.constants.OrderDirection)) – Optional order direction. Default is DESC. + ### *class* human_protocol_sdk.filter.TransactionFilter(chain_id, from_address=None, to_address=None, start_date=None, end_date=None, start_block=None, end_block=None, first=10, skip=0, order_direction=OrderDirection.DESC) Bases: `object` diff --git a/docs/sdk/python/human_protocol_sdk.legacy_encryption.md b/docs/sdk/python/human_protocol_sdk.legacy_encryption.md index 920fcd5dcd..5677a8464c 100644 --- a/docs/sdk/python/human_protocol_sdk.legacy_encryption.md +++ b/docs/sdk/python/human_protocol_sdk.legacy_encryption.md @@ -17,7 +17,7 @@ Encryption class specialized in encrypting and decrypting a byte string. #### CIPHER -Cipher algorithm defintion. +Cipher algorithm definition. alias of `AES` diff --git a/docs/sdk/python/human_protocol_sdk.md b/docs/sdk/python/human_protocol_sdk.md index 23fa99ab62..684d555365 100644 --- a/docs/sdk/python/human_protocol_sdk.md +++ b/docs/sdk/python/human_protocol_sdk.md @@ -46,6 +46,7 @@ * [Module](human_protocol_sdk.escrow.escrow_utils.md#module) * [`EscrowData`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowData) * [`EscrowUtils`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.EscrowUtils) + * [`Payout`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.Payout) * [`StatusEvent`](human_protocol_sdk.escrow.escrow_utils.md#human_protocol_sdk.escrow.escrow_utils.StatusEvent) * [human_protocol_sdk.kvstore package](human_protocol_sdk.kvstore.md) * [Submodules](human_protocol_sdk.kvstore.md#submodules) @@ -164,6 +165,8 @@ * [`PayoutFilter.__init__()`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.PayoutFilter.__init__) * [`StatisticsFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatisticsFilter) * [`StatisticsFilter.__init__()`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatisticsFilter.__init__) + * [`StatusEventFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatusEventFilter) + * [`StatusEventFilter.__init__()`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatusEventFilter.__init__) * [`TransactionFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.TransactionFilter) * [`TransactionFilter.__init__()`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.TransactionFilter.__init__) * [human_protocol_sdk.legacy_encryption module](human_protocol_sdk.legacy_encryption.md) diff --git a/docs/sdk/python/index.md b/docs/sdk/python/index.md index 950c44c068..15c0aa94fb 100644 --- a/docs/sdk/python/index.md +++ b/docs/sdk/python/index.md @@ -55,6 +55,7 @@ pip install human-protocol-sdk[agreement] * [`FilterError`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.FilterError) * [`PayoutFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.PayoutFilter) * [`StatisticsFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatisticsFilter) + * [`StatusEventFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.StatusEventFilter) * [`TransactionFilter`](human_protocol_sdk.filter.md#human_protocol_sdk.filter.TransactionFilter) * [human_protocol_sdk.legacy_encryption module](human_protocol_sdk.legacy_encryption.md) * [`DecryptionError`](human_protocol_sdk.legacy_encryption.md#human_protocol_sdk.legacy_encryption.DecryptionError) diff --git a/docs/sdk/typescript/base/classes/BaseEthersClient.md b/docs/sdk/typescript/base/classes/BaseEthersClient.md index 4487e3c0cb..61bc738a62 100644 --- a/docs/sdk/typescript/base/classes/BaseEthersClient.md +++ b/docs/sdk/typescript/base/classes/BaseEthersClient.md @@ -6,7 +6,7 @@ # Class: `abstract` BaseEthersClient -Defined in: [base.ts:10](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L10) +Defined in: [base.ts:10](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L10) ## Introduction @@ -24,7 +24,7 @@ This class is used as a base class for other clients making on-chain calls. > **new BaseEthersClient**(`runner`, `networkData`): [`BaseEthersClient`](BaseEthersClient.md) -Defined in: [base.ts:20](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L20) +Defined in: [base.ts:20](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L20) **BaseClient constructor** @@ -52,7 +52,7 @@ The network information required to connect to the contracts > **networkData**: [`NetworkData`](../../types/type-aliases/NetworkData.md) -Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) +Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) *** @@ -60,4 +60,4 @@ Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06 > `protected` **runner**: `ContractRunner` -Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) +Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) diff --git a/docs/sdk/typescript/encryption/classes/Encryption.md b/docs/sdk/typescript/encryption/classes/Encryption.md index 8b4e009617..cdd63a999b 100644 --- a/docs/sdk/typescript/encryption/classes/Encryption.md +++ b/docs/sdk/typescript/encryption/classes/Encryption.md @@ -6,7 +6,7 @@ # Class: Encryption -Defined in: [encryption.ts:58](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L58) +Defined in: [encryption.ts:58](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L58) ## Introduction @@ -53,7 +53,7 @@ const encryption = await Encryption.build(privateKey, passphrase); > **new Encryption**(`privateKey`): [`Encryption`](Encryption.md) -Defined in: [encryption.ts:66](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L66) +Defined in: [encryption.ts:66](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L66) Constructor for the Encryption class. @@ -75,7 +75,7 @@ The private key. > **decrypt**(`message`, `publicKey`?): `Promise`\<`Uint8Array`\<`ArrayBufferLike`\>\> -Defined in: [encryption.ts:194](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L194) +Defined in: [encryption.ts:194](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L194) This function decrypts messages using the private key. In addition, the public key can be added for signature verification. @@ -129,7 +129,7 @@ const resultMessage = await encryption.decrypt('message'); > **sign**(`message`): `Promise`\<`string`\> -Defined in: [encryption.ts:251](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L251) +Defined in: [encryption.ts:251](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L251) This function signs a message using the private key used to initialize the client. @@ -165,7 +165,7 @@ const resultMessage = await encryption.sign('message'); > **signAndEncrypt**(`message`, `publicKeys`): `Promise`\<`string`\> -Defined in: [encryption.ts:142](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L142) +Defined in: [encryption.ts:142](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L142) This function signs and encrypts a message using the private key used to initialize the client and the specified public keys. @@ -232,7 +232,7 @@ const resultMessage = await encryption.signAndEncrypt('message', publicKeys); > `static` **build**(`privateKeyArmored`, `passphrase`?): `Promise`\<[`Encryption`](Encryption.md)\> -Defined in: [encryption.ts:77](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L77) +Defined in: [encryption.ts:77](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L77) Builds an Encryption instance by decrypting the private key from an encrypted private key and passphrase. diff --git a/docs/sdk/typescript/encryption/classes/EncryptionUtils.md b/docs/sdk/typescript/encryption/classes/EncryptionUtils.md index 9e02dcd753..3751992b3d 100644 --- a/docs/sdk/typescript/encryption/classes/EncryptionUtils.md +++ b/docs/sdk/typescript/encryption/classes/EncryptionUtils.md @@ -6,7 +6,7 @@ # Class: EncryptionUtils -Defined in: [encryption.ts:290](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L290) +Defined in: [encryption.ts:290](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L290) ## Introduction @@ -48,7 +48,7 @@ const keyPair = await EncryptionUtils.generateKeyPair('Human', 'human@hmt.ai'); > `static` **encrypt**(`message`, `publicKeys`): `Promise`\<`string`\> -Defined in: [encryption.ts:444](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L444) +Defined in: [encryption.ts:444](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L444) This function encrypts a message using the specified public keys. @@ -111,7 +111,7 @@ const result = await EncryptionUtils.encrypt('message', publicKeys); > `static` **generateKeyPair**(`name`, `email`, `passphrase`): `Promise`\<[`IKeyPair`](../../interfaces/interfaces/IKeyPair.md)\> -Defined in: [encryption.ts:382](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L382) +Defined in: [encryption.ts:382](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L382) This function generates a key pair for encryption and decryption. @@ -158,7 +158,7 @@ const result = await EncryptionUtils.generateKeyPair(name, email, passphrase); > `static` **getSignedData**(`message`): `Promise`\<`string`\> -Defined in: [encryption.ts:351](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L351) +Defined in: [encryption.ts:351](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L351) This function gets signed data from a signed message. @@ -190,7 +190,7 @@ const signedData = await EncryptionUtils.getSignedData('message'); > `static` **isEncrypted**(`message`): `boolean` -Defined in: [encryption.ts:494](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L494) +Defined in: [encryption.ts:494](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L494) Verifies if a message appears to be encrypted with OpenPGP. @@ -238,7 +238,7 @@ if (isEncrypted) { > `static` **verify**(`message`, `publicKey`): `Promise`\<`boolean`\> -Defined in: [encryption.ts:318](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L318) +Defined in: [encryption.ts:318](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/encryption.ts#L318) This function verifies the signature of a signed message using the public key. diff --git a/docs/sdk/typescript/enums/enumerations/ChainId.md b/docs/sdk/typescript/enums/enumerations/ChainId.md index fc57b00227..8beeb70fa3 100644 --- a/docs/sdk/typescript/enums/enumerations/ChainId.md +++ b/docs/sdk/typescript/enums/enumerations/ChainId.md @@ -6,7 +6,7 @@ # Enumeration: ChainId -Defined in: [enums.ts:1](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L1) +Defined in: [enums.ts:1](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L1) ## Enumeration Members @@ -14,7 +14,7 @@ Defined in: [enums.ts:1](https://github.com/humanprotocol/human-protocol/blob/06 > **ALL**: `-1` -Defined in: [enums.ts:2](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L2) +Defined in: [enums.ts:2](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L2) *** @@ -22,7 +22,7 @@ Defined in: [enums.ts:2](https://github.com/humanprotocol/human-protocol/blob/06 > **BSC\_MAINNET**: `56` -Defined in: [enums.ts:5](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L5) +Defined in: [enums.ts:5](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L5) *** @@ -30,7 +30,7 @@ Defined in: [enums.ts:5](https://github.com/humanprotocol/human-protocol/blob/06 > **BSC\_TESTNET**: `97` -Defined in: [enums.ts:6](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L6) +Defined in: [enums.ts:6](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L6) *** @@ -38,7 +38,7 @@ Defined in: [enums.ts:6](https://github.com/humanprotocol/human-protocol/blob/06 > **LOCALHOST**: `1338` -Defined in: [enums.ts:9](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L9) +Defined in: [enums.ts:9](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L9) *** @@ -46,7 +46,7 @@ Defined in: [enums.ts:9](https://github.com/humanprotocol/human-protocol/blob/06 > **MAINNET**: `1` -Defined in: [enums.ts:3](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L3) +Defined in: [enums.ts:3](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L3) *** @@ -54,7 +54,7 @@ Defined in: [enums.ts:3](https://github.com/humanprotocol/human-protocol/blob/06 > **POLYGON**: `137` -Defined in: [enums.ts:7](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L7) +Defined in: [enums.ts:7](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L7) *** @@ -62,7 +62,7 @@ Defined in: [enums.ts:7](https://github.com/humanprotocol/human-protocol/blob/06 > **POLYGON\_AMOY**: `80002` -Defined in: [enums.ts:8](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L8) +Defined in: [enums.ts:8](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L8) *** @@ -70,4 +70,4 @@ Defined in: [enums.ts:8](https://github.com/humanprotocol/human-protocol/blob/06 > **SEPOLIA**: `11155111` -Defined in: [enums.ts:4](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L4) +Defined in: [enums.ts:4](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L4) diff --git a/docs/sdk/typescript/enums/enumerations/OperatorCategory.md b/docs/sdk/typescript/enums/enumerations/OperatorCategory.md index db2feb91a4..2959d5fdde 100644 --- a/docs/sdk/typescript/enums/enumerations/OperatorCategory.md +++ b/docs/sdk/typescript/enums/enumerations/OperatorCategory.md @@ -6,7 +6,7 @@ # Enumeration: OperatorCategory -Defined in: [enums.ts:17](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L17) +Defined in: [enums.ts:17](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L17) ## Enumeration Members @@ -14,7 +14,7 @@ Defined in: [enums.ts:17](https://github.com/humanprotocol/human-protocol/blob/0 > **MACHINE\_LEARNING**: `"machine_learning"` -Defined in: [enums.ts:18](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L18) +Defined in: [enums.ts:18](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L18) *** @@ -22,4 +22,4 @@ Defined in: [enums.ts:18](https://github.com/humanprotocol/human-protocol/blob/0 > **MARKET\_MAKING**: `"market_making"` -Defined in: [enums.ts:19](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L19) +Defined in: [enums.ts:19](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L19) diff --git a/docs/sdk/typescript/enums/enumerations/OrderDirection.md b/docs/sdk/typescript/enums/enumerations/OrderDirection.md index a78e620292..36acf41cb4 100644 --- a/docs/sdk/typescript/enums/enumerations/OrderDirection.md +++ b/docs/sdk/typescript/enums/enumerations/OrderDirection.md @@ -6,7 +6,7 @@ # Enumeration: OrderDirection -Defined in: [enums.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L12) +Defined in: [enums.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L12) ## Enumeration Members @@ -14,7 +14,7 @@ Defined in: [enums.ts:12](https://github.com/humanprotocol/human-protocol/blob/0 > **ASC**: `"asc"` -Defined in: [enums.ts:13](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L13) +Defined in: [enums.ts:13](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L13) *** @@ -22,4 +22,4 @@ Defined in: [enums.ts:13](https://github.com/humanprotocol/human-protocol/blob/0 > **DESC**: `"desc"` -Defined in: [enums.ts:14](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L14) +Defined in: [enums.ts:14](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/enums.ts#L14) diff --git a/docs/sdk/typescript/escrow/classes/EscrowClient.md b/docs/sdk/typescript/escrow/classes/EscrowClient.md index 9a27e2ca4e..5284867466 100644 --- a/docs/sdk/typescript/escrow/classes/EscrowClient.md +++ b/docs/sdk/typescript/escrow/classes/EscrowClient.md @@ -6,7 +6,7 @@ # Class: EscrowClient -Defined in: [escrow.ts:134](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L134) +Defined in: [escrow.ts:141](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L141) ## Introduction @@ -86,7 +86,7 @@ const escrowClient = await EscrowClient.build(provider); > **new EscrowClient**(`runner`, `networkData`): [`EscrowClient`](EscrowClient.md) -Defined in: [escrow.ts:143](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L143) +Defined in: [escrow.ts:150](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L150) **EscrowClient constructor** @@ -118,7 +118,7 @@ The network information required to connect to the Escrow contract > **networkData**: [`NetworkData`](../../types/type-aliases/NetworkData.md) -Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) +Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) #### Inherited from @@ -130,7 +130,7 @@ Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06 > `protected` **runner**: `ContractRunner` -Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) +Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) #### Inherited from @@ -142,7 +142,7 @@ Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06 > **addTrustedHandlers**(`escrowAddress`, `trustedHandlers`, `txOptions`?): `Promise`\<`void`\> -Defined in: [escrow.ts:771](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L771) +Defined in: [escrow.ts:778](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L778) This function adds an array of addresses to the trusted handlers list. @@ -197,7 +197,7 @@ await escrowClient.addTrustedHandlers('0x62dD51230A30401C455c8398d06F85e4EaB6309 > **bulkPayOut**(`escrowAddress`, `recipients`, `amounts`, `finalResultsUrl`, `finalResultsHash`, `txId`, `forceComplete`, `txOptions`?): `Promise`\<`void`\> -Defined in: [escrow.ts:604](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L604) +Defined in: [escrow.ts:611](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L611) This function pays out the amounts specified to the workers and sets the URL of the final results file. @@ -287,7 +287,7 @@ await escrowClient.bulkPayOut('0x62dD51230A30401C455c8398d06F85e4EaB6309f', reci > **cancel**(`escrowAddress`, `txOptions`?): `Promise`\<[`EscrowCancel`](../../types/type-aliases/EscrowCancel.md)\> -Defined in: [escrow.ts:685](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L685) +Defined in: [escrow.ts:692](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L692) This function cancels the specified escrow and sends the balance to the canceler. @@ -335,7 +335,7 @@ await escrowClient.cancel('0x62dD51230A30401C455c8398d06F85e4EaB6309f'); > **complete**(`escrowAddress`, `txOptions`?): `Promise`\<`void`\> -Defined in: [escrow.ts:543](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L543) +Defined in: [escrow.ts:550](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L550) This function sets the status of an escrow to completed. @@ -383,7 +383,7 @@ await escrowClient.complete('0x62dD51230A30401C455c8398d06F85e4EaB6309f'); > **createBulkPayoutTransaction**(`escrowAddress`, `recipients`, `amounts`, `finalResultsUrl`, `finalResultsHash`, `txId`, `forceComplete`, `txOptions`?): `Promise`\<[`TransactionLikeWithNonce`](../../types/type-aliases/TransactionLikeWithNonce.md)\> -Defined in: [escrow.ts:940](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L940) +Defined in: [escrow.ts:947](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L947) Creates a prepared transaction for bulk payout without immediately sending it. @@ -477,7 +477,7 @@ console.log('Tx hash:', ethers.keccak256(signedTransaction)); > **createEscrow**(`tokenAddress`, `trustedHandlers`, `jobRequesterId`, `txOptions`?): `Promise`\<`string`\> -Defined in: [escrow.ts:223](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L223) +Defined in: [escrow.ts:230](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L230) This function creates an escrow contract that uses the token passed to pay oracle fees and reward workers. @@ -540,7 +540,7 @@ const escrowAddress = await escrowClient.createEscrow(tokenAddress, trustedHandl > **fund**(`escrowAddress`, `amount`, `txOptions`?): `Promise`\<`void`\> -Defined in: [escrow.ts:414](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L414) +Defined in: [escrow.ts:421](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L421) This function adds funds of the chosen token to the escrow. @@ -593,7 +593,7 @@ await escrowClient.fund('0x62dD51230A30401C455c8398d06F85e4EaB6309f', amount); > **getBalance**(`escrowAddress`): `Promise`\<`bigint`\> -Defined in: [escrow.ts:1085](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1085) +Defined in: [escrow.ts:1092](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1092) This function returns the balance for a specified escrow address. @@ -631,7 +631,7 @@ const balance = await escrowClient.getBalance('0x62dD51230A30401C455c8398d06F85e > **getExchangeOracleAddress**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1471](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1471) +Defined in: [escrow.ts:1478](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1478) This function returns the exchange oracle address for a given escrow. @@ -669,7 +669,7 @@ const oracleAddress = await escrowClient.getExchangeOracleAddress('0x62dD51230A3 > **getFactoryAddress**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1509](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1509) +Defined in: [escrow.ts:1516](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1516) This function returns the escrow factory address for a given escrow. @@ -707,7 +707,7 @@ const factoryAddress = await escrowClient.getFactoryAddress('0x62dD51230A30401C4 > **getIntermediateResultsUrl**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1243](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1243) +Defined in: [escrow.ts:1250](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1250) This function returns the intermediate results file URL. @@ -745,7 +745,7 @@ const intermediateResultsUrl = await escrowClient.getIntermediateResultsUrl('0x6 > **getJobLauncherAddress**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1395](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1395) +Defined in: [escrow.ts:1402](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1402) This function returns the job launcher address for a given escrow. @@ -783,7 +783,7 @@ const jobLauncherAddress = await escrowClient.getJobLauncherAddress('0x62dD51230 > **getManifestHash**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1129](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1129) +Defined in: [escrow.ts:1136](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1136) This function returns the manifest file hash. @@ -821,7 +821,7 @@ const manifestHash = await escrowClient.getManifestHash('0x62dD51230A30401C455c8 > **getManifestUrl**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1167](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1167) +Defined in: [escrow.ts:1174](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1174) This function returns the manifest file URL. @@ -859,7 +859,7 @@ const manifestUrl = await escrowClient.getManifestUrl('0x62dD51230A30401C455c839 > **getRecordingOracleAddress**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1357](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1357) +Defined in: [escrow.ts:1364](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1364) This function returns the recording oracle address for a given escrow. @@ -897,7 +897,7 @@ const oracleAddress = await escrowClient.getRecordingOracleAddress('0x62dD51230A > **getReputationOracleAddress**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1433](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1433) +Defined in: [escrow.ts:1440](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1440) This function returns the reputation oracle address for a given escrow. @@ -935,7 +935,7 @@ const oracleAddress = await escrowClient.getReputationOracleAddress('0x62dD51230 > **getResultsUrl**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1205](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1205) +Defined in: [escrow.ts:1212](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1212) This function returns the results file URL. @@ -973,7 +973,7 @@ const resultsUrl = await escrowClient.getResultsUrl('0x62dD51230A30401C455c8398d > **getStatus**(`escrowAddress`): `Promise`\<[`EscrowStatus`](../../types/enumerations/EscrowStatus.md)\> -Defined in: [escrow.ts:1319](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1319) +Defined in: [escrow.ts:1326](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1326) This function returns the current status of the escrow. @@ -1011,7 +1011,7 @@ const status = await escrowClient.getStatus('0x62dD51230A30401C455c8398d06F85e4E > **getTokenAddress**(`escrowAddress`): `Promise`\<`string`\> -Defined in: [escrow.ts:1281](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1281) +Defined in: [escrow.ts:1288](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1288) This function returns the token address used for funding the escrow. @@ -1049,7 +1049,7 @@ const tokenAddress = await escrowClient.getTokenAddress('0x62dD51230A30401C455c8 > **setup**(`escrowAddress`, `escrowConfig`, `txOptions`?): `Promise`\<`void`\> -Defined in: [escrow.ts:304](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L304) +Defined in: [escrow.ts:311](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L311) This function sets up the parameters of the escrow. @@ -1114,7 +1114,7 @@ await escrowClient.setup(escrowAddress, escrowConfig); > **storeResults**(`escrowAddress`, `url`, `hash`, `txOptions`?): `Promise`\<`void`\> -Defined in: [escrow.ts:479](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L479) +Defined in: [escrow.ts:486](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L486) This function stores the results URL and hash. @@ -1174,7 +1174,7 @@ await escrowClient.storeResults('0x62dD51230A30401C455c8398d06F85e4EaB6309f', 'h > **withdraw**(`escrowAddress`, `tokenAddress`, `txOptions`?): `Promise`\<[`EscrowWithdraw`](../../types/type-aliases/EscrowWithdraw.md)\> -Defined in: [escrow.ts:837](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L837) +Defined in: [escrow.ts:844](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L844) This function withdraws additional tokens in the escrow to the canceler. @@ -1231,7 +1231,7 @@ await escrowClient.withdraw( > `static` **build**(`runner`): `Promise`\<[`EscrowClient`](EscrowClient.md)\> -Defined in: [escrow.ts:161](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L161) +Defined in: [escrow.ts:168](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L168) Creates an instance of EscrowClient from a Runner. diff --git a/docs/sdk/typescript/escrow/classes/EscrowUtils.md b/docs/sdk/typescript/escrow/classes/EscrowUtils.md index 3c559646be..ffb98a5c33 100644 --- a/docs/sdk/typescript/escrow/classes/EscrowUtils.md +++ b/docs/sdk/typescript/escrow/classes/EscrowUtils.md @@ -6,7 +6,7 @@ # Class: EscrowUtils -Defined in: [escrow.ts:1558](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1558) +Defined in: [escrow.ts:1565](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1565) ## Introduction @@ -54,7 +54,7 @@ const escrowAddresses = new EscrowUtils.getEscrows({ > `static` **getEscrow**(`chainId`, `escrowAddress`): `Promise`\<[`EscrowData`](../../graphql/types/type-aliases/EscrowData.md)\> -Defined in: [escrow.ts:1773](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1773) +Defined in: [escrow.ts:1780](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1780) This function returns the escrow data for a given address. @@ -133,7 +133,7 @@ const escrowData = new EscrowUtils.getEscrow(ChainId.POLYGON_AMOY, "0x1234567890 > `static` **getEscrows**(`filter`): `Promise`\<[`EscrowData`](../../graphql/types/type-aliases/EscrowData.md)[]\> -Defined in: [escrow.ts:1655](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1655) +Defined in: [escrow.ts:1662](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1662) This function returns an array of escrows based on the specified filter parameters. @@ -241,11 +241,55 @@ const escrowDatas = await EscrowUtils.getEscrows(filters); *** +### getPayouts() + +> `static` **getPayouts**(`filter`): `Promise`\<[`Payout`](../../types/type-aliases/Payout.md)[]\> + +Defined in: [escrow.ts:1950](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1950) + +This function returns the payouts for a given set of networks. + +> This uses Subgraph + +**Input parameters** +Fetch payouts from the subgraph. + +#### Parameters + +##### filter + +[`IPayoutFilter`](../../interfaces/interfaces/IPayoutFilter.md) + +Filter parameters. + +#### Returns + +`Promise`\<[`Payout`](../../types/type-aliases/Payout.md)[]\> + +List of payouts matching the filters. + +**Code example** + +```ts +import { ChainId, EscrowUtils } from '@human-protocol/sdk'; + +const payouts = await EscrowUtils.getPayouts({ + chainId: ChainId.POLYGON, + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + from: new Date('2023-01-01'), + to: new Date('2023-12-31') +}); +console.log(payouts); +``` + +*** + ### getStatusEvents() -> `static` **getStatusEvents**(`chainId`, `statuses`?, `from`?, `to`?, `launcher`?, `first`?, `skip`?, `orderDirection`?): `Promise`\<[`StatusEvent`](../../graphql/types/type-aliases/StatusEvent.md)[]\> +> `static` **getStatusEvents**(`filter`): `Promise`\<[`StatusEvent`](../../graphql/types/type-aliases/StatusEvent.md)[]\> -Defined in: [escrow.ts:1860](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1860) +Defined in: [escrow.ts:1859](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts#L1859) This function returns the status events for a given set of networks within an optional date range. @@ -283,53 +327,11 @@ type Status = { #### Parameters -##### chainId - -[`ChainId`](../../enums/enumerations/ChainId.md) - -List of network IDs to query for status events. - -##### statuses? - -[`EscrowStatus`](../../types/enumerations/EscrowStatus.md)[] - -Optional array of statuses to query for. If not provided, queries for all statuses. - -##### from? - -`Date` - -Optional start date to filter events. - -##### to? - -`Date` - -Optional end date to filter events. - -##### launcher? - -`string` - -Optional launcher address to filter events. Must be a valid Ethereum address. - -##### first? - -`number` - -Optional number of transactions per page. Default is 10. - -##### skip? - -`number` - -Optional number of transactions to skip. Default is 0. - -##### orderDirection? +##### filter -[`OrderDirection`](../../enums/enumerations/OrderDirection.md) +[`IStatusEventFilter`](../../interfaces/interfaces/IStatusEventFilter.md) -Optional order of the results. Default is DESC. +Filter parameters. #### Returns @@ -345,12 +347,12 @@ import { ChainId, EscrowUtils, EscrowStatus } from '@human-protocol/sdk'; (async () => { const fromDate = new Date('2023-01-01'); const toDate = new Date('2023-12-31'); - const statusEvents = await EscrowUtils.getStatusEvents( - [ChainId.POLYGON, ChainId.MAINNET], - [EscrowStatus.Pending, EscrowStatus.Complete], - fromDate, - toDate - ); + const statusEvents = await EscrowUtils.getStatusEvents({ + chainId: ChainId.POLYGON, + statuses: [EscrowStatus.Pending, EscrowStatus.Complete], + from: fromDate, + to: toDate + }); console.log(statusEvents); })(); ``` diff --git a/docs/sdk/typescript/graphql/types/type-aliases/DailyEscrowData.md b/docs/sdk/typescript/graphql/types/type-aliases/DailyEscrowData.md index a710721fe7..1c238ad729 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/DailyEscrowData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/DailyEscrowData.md @@ -8,7 +8,7 @@ > **DailyEscrowData**: `object` -Defined in: [graphql/types.ts:83](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L83) +Defined in: [graphql/types.ts:83](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L83) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/DailyHMTData.md b/docs/sdk/typescript/graphql/types/type-aliases/DailyHMTData.md index 0007ba8dc0..ef5f4c3c6b 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/DailyHMTData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/DailyHMTData.md @@ -8,7 +8,7 @@ > **DailyHMTData**: `object` -Defined in: [graphql/types.ts:127](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L127) +Defined in: [graphql/types.ts:127](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L127) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/DailyPaymentData.md b/docs/sdk/typescript/graphql/types/type-aliases/DailyPaymentData.md index 25769b81cb..43bf891027 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/DailyPaymentData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/DailyPaymentData.md @@ -8,7 +8,7 @@ > **DailyPaymentData**: `object` -Defined in: [graphql/types.ts:106](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L106) +Defined in: [graphql/types.ts:106](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L106) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/DailyTaskData.md b/docs/sdk/typescript/graphql/types/type-aliases/DailyTaskData.md index c71d718fe8..36ebc6f6ff 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/DailyTaskData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/DailyTaskData.md @@ -8,7 +8,7 @@ > **DailyTaskData**: `object` -Defined in: [graphql/types.ts:148](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L148) +Defined in: [graphql/types.ts:148](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L148) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/DailyWorkerData.md b/docs/sdk/typescript/graphql/types/type-aliases/DailyWorkerData.md index e39d40f6e4..add04d9ddf 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/DailyWorkerData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/DailyWorkerData.md @@ -8,7 +8,7 @@ > **DailyWorkerData**: `object` -Defined in: [graphql/types.ts:97](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L97) +Defined in: [graphql/types.ts:97](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L97) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/EscrowData.md b/docs/sdk/typescript/graphql/types/type-aliases/EscrowData.md index 6af340f156..806397edc3 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/EscrowData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/EscrowData.md @@ -8,7 +8,7 @@ > **EscrowData**: `object` -Defined in: [graphql/types.ts:3](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L3) +Defined in: [graphql/types.ts:3](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L3) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatistics.md b/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatistics.md index b7d33856ff..232b139989 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatistics.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatistics.md @@ -8,7 +8,7 @@ > **EscrowStatistics**: `object` -Defined in: [graphql/types.ts:92](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L92) +Defined in: [graphql/types.ts:92](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L92) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatisticsData.md b/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatisticsData.md index c65ac8ca5a..2dcc38ed60 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatisticsData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/EscrowStatisticsData.md @@ -8,7 +8,7 @@ > **EscrowStatisticsData**: `object` -Defined in: [graphql/types.ts:42](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L42) +Defined in: [graphql/types.ts:42](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L42) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/EventDayData.md b/docs/sdk/typescript/graphql/types/type-aliases/EventDayData.md index 6a888a4c4f..e5a81288a4 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/EventDayData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/EventDayData.md @@ -8,7 +8,7 @@ > **EventDayData**: `object` -Defined in: [graphql/types.ts:55](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L55) +Defined in: [graphql/types.ts:55](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L55) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/HMTHolder.md b/docs/sdk/typescript/graphql/types/type-aliases/HMTHolder.md index 7dbf85afbb..31cc811022 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/HMTHolder.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/HMTHolder.md @@ -8,7 +8,7 @@ > **HMTHolder**: `object` -Defined in: [graphql/types.ts:122](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L122) +Defined in: [graphql/types.ts:122](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L122) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/HMTHolderData.md b/docs/sdk/typescript/graphql/types/type-aliases/HMTHolderData.md index fbc4efeef7..97a5ac5081 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/HMTHolderData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/HMTHolderData.md @@ -8,7 +8,7 @@ > **HMTHolderData**: `object` -Defined in: [graphql/types.ts:117](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L117) +Defined in: [graphql/types.ts:117](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L117) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/HMTStatistics.md b/docs/sdk/typescript/graphql/types/type-aliases/HMTStatistics.md index cbaf3a162d..0e8a6d6819 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/HMTStatistics.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/HMTStatistics.md @@ -8,7 +8,7 @@ > **HMTStatistics**: `object` -Defined in: [graphql/types.ts:135](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L135) +Defined in: [graphql/types.ts:135](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L135) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/HMTStatisticsData.md b/docs/sdk/typescript/graphql/types/type-aliases/HMTStatisticsData.md index c4b4a2b58c..b3c46dcee0 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/HMTStatisticsData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/HMTStatisticsData.md @@ -8,7 +8,7 @@ > **HMTStatisticsData**: `object` -Defined in: [graphql/types.ts:33](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L33) +Defined in: [graphql/types.ts:33](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L33) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/IMData.md b/docs/sdk/typescript/graphql/types/type-aliases/IMData.md index a815345c60..bf5b3fe488 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/IMData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/IMData.md @@ -8,4 +8,4 @@ > **IMData**: `Record`\<`string`, [`IMDataEntity`](IMDataEntity.md)\> -Defined in: [graphql/types.ts:146](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L146) +Defined in: [graphql/types.ts:146](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L146) diff --git a/docs/sdk/typescript/graphql/types/type-aliases/IMDataEntity.md b/docs/sdk/typescript/graphql/types/type-aliases/IMDataEntity.md index e522d32d83..542098ff6b 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/IMDataEntity.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/IMDataEntity.md @@ -8,7 +8,7 @@ > **IMDataEntity**: `object` -Defined in: [graphql/types.ts:141](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L141) +Defined in: [graphql/types.ts:141](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L141) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/KVStoreData.md b/docs/sdk/typescript/graphql/types/type-aliases/KVStoreData.md index 5f33fc202e..be19b6b9c6 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/KVStoreData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/KVStoreData.md @@ -8,7 +8,7 @@ > **KVStoreData**: `object` -Defined in: [graphql/types.ts:165](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L165) +Defined in: [graphql/types.ts:165](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L165) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/PaymentStatistics.md b/docs/sdk/typescript/graphql/types/type-aliases/PaymentStatistics.md index 2e3759c6f8..96254bc4fb 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/PaymentStatistics.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/PaymentStatistics.md @@ -8,7 +8,7 @@ > **PaymentStatistics**: `object` -Defined in: [graphql/types.ts:113](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L113) +Defined in: [graphql/types.ts:113](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L113) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/PayoutData.md b/docs/sdk/typescript/graphql/types/type-aliases/PayoutData.md index bb0362bb47..f0a44f16ba 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/PayoutData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/PayoutData.md @@ -8,7 +8,7 @@ > **PayoutData**: `object` -Defined in: [graphql/types.ts:25](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L25) +Defined in: [graphql/types.ts:25](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L25) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/RewardAddedEventData.md b/docs/sdk/typescript/graphql/types/type-aliases/RewardAddedEventData.md index e6a086e104..41154a1979 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/RewardAddedEventData.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/RewardAddedEventData.md @@ -8,7 +8,7 @@ > **RewardAddedEventData**: `object` -Defined in: [graphql/types.ts:76](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L76) +Defined in: [graphql/types.ts:76](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L76) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/StatusEvent.md b/docs/sdk/typescript/graphql/types/type-aliases/StatusEvent.md index 6eac1851f1..3933be12d2 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/StatusEvent.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/StatusEvent.md @@ -8,7 +8,7 @@ > **StatusEvent**: `object` -Defined in: [graphql/types.ts:158](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L158) +Defined in: [graphql/types.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L158) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/TaskStatistics.md b/docs/sdk/typescript/graphql/types/type-aliases/TaskStatistics.md index dcc05e52cf..25ea19ce28 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/TaskStatistics.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/TaskStatistics.md @@ -8,7 +8,7 @@ > **TaskStatistics**: `object` -Defined in: [graphql/types.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L154) +Defined in: [graphql/types.ts:154](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L154) ## Type declaration diff --git a/docs/sdk/typescript/graphql/types/type-aliases/WorkerStatistics.md b/docs/sdk/typescript/graphql/types/type-aliases/WorkerStatistics.md index 60aa3c5894..9fc02fa470 100644 --- a/docs/sdk/typescript/graphql/types/type-aliases/WorkerStatistics.md +++ b/docs/sdk/typescript/graphql/types/type-aliases/WorkerStatistics.md @@ -8,7 +8,7 @@ > **WorkerStatistics**: `object` -Defined in: [graphql/types.ts:102](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L102) +Defined in: [graphql/types.ts:102](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/graphql/types.ts#L102) ## Type declaration diff --git a/docs/sdk/typescript/interfaces/README.md b/docs/sdk/typescript/interfaces/README.md index 5f4b10c270..35090d4f89 100644 --- a/docs/sdk/typescript/interfaces/README.md +++ b/docs/sdk/typescript/interfaces/README.md @@ -23,6 +23,7 @@ - [IReputationNetworkSubgraph](interfaces/IReputationNetworkSubgraph.md) - [IReward](interfaces/IReward.md) - [IStatisticsFilter](interfaces/IStatisticsFilter.md) +- [IStatusEventFilter](interfaces/IStatusEventFilter.md) - [ITransaction](interfaces/ITransaction.md) - [ITransactionsFilter](interfaces/ITransactionsFilter.md) - [StakerInfo](interfaces/StakerInfo.md) diff --git a/docs/sdk/typescript/interfaces/interfaces/IEscrowConfig.md b/docs/sdk/typescript/interfaces/interfaces/IEscrowConfig.md index fa0a787f88..edf7ae0963 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IEscrowConfig.md +++ b/docs/sdk/typescript/interfaces/interfaces/IEscrowConfig.md @@ -6,7 +6,7 @@ # Interface: IEscrowConfig -Defined in: [interfaces.ts:79](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L79) +Defined in: [interfaces.ts:79](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L79) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:79](https://github.com/humanprotocol/human-protocol/b > **exchangeOracle**: `string` -Defined in: [interfaces.ts:82](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L82) +Defined in: [interfaces.ts:82](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L82) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:82](https://github.com/humanprotocol/human-protocol/b > **exchangeOracleFee**: `bigint` -Defined in: [interfaces.ts:85](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L85) +Defined in: [interfaces.ts:85](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L85) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:85](https://github.com/humanprotocol/human-protocol/b > **manifestHash**: `string` -Defined in: [interfaces.ts:87](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L87) +Defined in: [interfaces.ts:87](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L87) *** @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:87](https://github.com/humanprotocol/human-protocol/b > **manifestUrl**: `string` -Defined in: [interfaces.ts:86](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L86) +Defined in: [interfaces.ts:86](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L86) *** @@ -46,7 +46,7 @@ Defined in: [interfaces.ts:86](https://github.com/humanprotocol/human-protocol/b > **recordingOracle**: `string` -Defined in: [interfaces.ts:80](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L80) +Defined in: [interfaces.ts:80](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L80) *** @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:80](https://github.com/humanprotocol/human-protocol/b > **recordingOracleFee**: `bigint` -Defined in: [interfaces.ts:83](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L83) +Defined in: [interfaces.ts:83](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L83) *** @@ -62,7 +62,7 @@ Defined in: [interfaces.ts:83](https://github.com/humanprotocol/human-protocol/b > **reputationOracle**: `string` -Defined in: [interfaces.ts:81](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L81) +Defined in: [interfaces.ts:81](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L81) *** @@ -70,4 +70,4 @@ Defined in: [interfaces.ts:81](https://github.com/humanprotocol/human-protocol/b > **reputationOracleFee**: `bigint` -Defined in: [interfaces.ts:84](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L84) +Defined in: [interfaces.ts:84](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L84) diff --git a/docs/sdk/typescript/interfaces/interfaces/IEscrowsFilter.md b/docs/sdk/typescript/interfaces/interfaces/IEscrowsFilter.md index 2d9db02620..b21cbc2153 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IEscrowsFilter.md +++ b/docs/sdk/typescript/interfaces/interfaces/IEscrowsFilter.md @@ -6,7 +6,7 @@ # Interface: IEscrowsFilter -Defined in: [interfaces.ts:67](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L67) +Defined in: [interfaces.ts:67](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L67) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:67](https://github.com/humanprotocol/human-protocol/b > **chainId**: [`ChainId`](../../enums/enumerations/ChainId.md) -Defined in: [interfaces.ts:76](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L76) +Defined in: [interfaces.ts:76](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L76) *** @@ -26,7 +26,7 @@ Defined in: [interfaces.ts:76](https://github.com/humanprotocol/human-protocol/b > `optional` **exchangeOracle**: `string` -Defined in: [interfaces.ts:71](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L71) +Defined in: [interfaces.ts:71](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L71) *** @@ -34,7 +34,7 @@ Defined in: [interfaces.ts:71](https://github.com/humanprotocol/human-protocol/b > `optional` **first**: `number` -Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) +Defined in: [interfaces.ts:157](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L157) #### Inherited from @@ -46,7 +46,7 @@ Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/ > `optional` **from**: `Date` -Defined in: [interfaces.ts:74](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L74) +Defined in: [interfaces.ts:74](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L74) *** @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:74](https://github.com/humanprotocol/human-protocol/b > `optional` **jobRequesterId**: `string` -Defined in: [interfaces.ts:72](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L72) +Defined in: [interfaces.ts:72](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L72) *** @@ -62,7 +62,7 @@ Defined in: [interfaces.ts:72](https://github.com/humanprotocol/human-protocol/b > `optional` **launcher**: `string` -Defined in: [interfaces.ts:68](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L68) +Defined in: [interfaces.ts:68](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L68) *** @@ -70,7 +70,7 @@ Defined in: [interfaces.ts:68](https://github.com/humanprotocol/human-protocol/b > `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) -Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L155) +Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) #### Inherited from @@ -82,7 +82,7 @@ Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/ > `optional` **recordingOracle**: `string` -Defined in: [interfaces.ts:70](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L70) +Defined in: [interfaces.ts:70](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L70) *** @@ -90,7 +90,7 @@ Defined in: [interfaces.ts:70](https://github.com/humanprotocol/human-protocol/b > `optional` **reputationOracle**: `string` -Defined in: [interfaces.ts:69](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L69) +Defined in: [interfaces.ts:69](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L69) *** @@ -98,7 +98,7 @@ Defined in: [interfaces.ts:69](https://github.com/humanprotocol/human-protocol/b > `optional` **skip**: `number` -Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L154) +Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) #### Inherited from @@ -110,7 +110,7 @@ Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/ > `optional` **status**: [`EscrowStatus`](../../types/enumerations/EscrowStatus.md) -Defined in: [interfaces.ts:73](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L73) +Defined in: [interfaces.ts:73](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L73) *** @@ -118,4 +118,4 @@ Defined in: [interfaces.ts:73](https://github.com/humanprotocol/human-protocol/b > `optional` **to**: `Date` -Defined in: [interfaces.ts:75](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L75) +Defined in: [interfaces.ts:75](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L75) diff --git a/docs/sdk/typescript/interfaces/interfaces/IHMTHoldersParams.md b/docs/sdk/typescript/interfaces/interfaces/IHMTHoldersParams.md index efa88e282b..bec4ee9a2f 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IHMTHoldersParams.md +++ b/docs/sdk/typescript/interfaces/interfaces/IHMTHoldersParams.md @@ -6,7 +6,7 @@ # Interface: IHMTHoldersParams -Defined in: [interfaces.ts:102](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L102) +Defined in: [interfaces.ts:102](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L102) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:102](https://github.com/humanprotocol/human-protocol/ > `optional` **address**: `string` -Defined in: [interfaces.ts:103](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L103) +Defined in: [interfaces.ts:103](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L103) *** @@ -26,7 +26,7 @@ Defined in: [interfaces.ts:103](https://github.com/humanprotocol/human-protocol/ > `optional` **first**: `number` -Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) +Defined in: [interfaces.ts:157](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L157) #### Inherited from @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/ > `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) -Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L155) +Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) #### Inherited from @@ -50,7 +50,7 @@ Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/ > `optional` **skip**: `number` -Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L154) +Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) #### Inherited from diff --git a/docs/sdk/typescript/interfaces/interfaces/IKVStore.md b/docs/sdk/typescript/interfaces/interfaces/IKVStore.md index 24c492d012..52ac9d976c 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IKVStore.md +++ b/docs/sdk/typescript/interfaces/interfaces/IKVStore.md @@ -6,7 +6,7 @@ # Interface: IKVStore -Defined in: [interfaces.ts:113](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L113) +Defined in: [interfaces.ts:117](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L117) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:113](https://github.com/humanprotocol/human-protocol/ > **key**: `string` -Defined in: [interfaces.ts:114](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L114) +Defined in: [interfaces.ts:118](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L118) *** @@ -22,4 +22,4 @@ Defined in: [interfaces.ts:114](https://github.com/humanprotocol/human-protocol/ > **value**: `string` -Defined in: [interfaces.ts:115](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L115) +Defined in: [interfaces.ts:119](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L119) diff --git a/docs/sdk/typescript/interfaces/interfaces/IKeyPair.md b/docs/sdk/typescript/interfaces/interfaces/IKeyPair.md index 175caaaa7d..dfe71cd9c8 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IKeyPair.md +++ b/docs/sdk/typescript/interfaces/interfaces/IKeyPair.md @@ -6,7 +6,7 @@ # Interface: IKeyPair -Defined in: [interfaces.ts:90](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L90) +Defined in: [interfaces.ts:90](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L90) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:90](https://github.com/humanprotocol/human-protocol/b > **passphrase**: `string` -Defined in: [interfaces.ts:93](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L93) +Defined in: [interfaces.ts:93](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L93) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:93](https://github.com/humanprotocol/human-protocol/b > **privateKey**: `string` -Defined in: [interfaces.ts:91](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L91) +Defined in: [interfaces.ts:91](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L91) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:91](https://github.com/humanprotocol/human-protocol/b > **publicKey**: `string` -Defined in: [interfaces.ts:92](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L92) +Defined in: [interfaces.ts:92](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L92) *** @@ -38,4 +38,4 @@ Defined in: [interfaces.ts:92](https://github.com/humanprotocol/human-protocol/b > `optional` **revocationCertificate**: `string` -Defined in: [interfaces.ts:94](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L94) +Defined in: [interfaces.ts:94](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L94) diff --git a/docs/sdk/typescript/interfaces/interfaces/IOperator.md b/docs/sdk/typescript/interfaces/interfaces/IOperator.md index 19de7da259..58f5caf487 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IOperator.md +++ b/docs/sdk/typescript/interfaces/interfaces/IOperator.md @@ -6,7 +6,7 @@ # Interface: IOperator -Defined in: [interfaces.ts:9](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L9) +Defined in: [interfaces.ts:9](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L9) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:9](https://github.com/humanprotocol/human-protocol/bl > **address**: `string` -Defined in: [interfaces.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L12) +Defined in: [interfaces.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L12) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:12](https://github.com/humanprotocol/human-protocol/b > **amountJobsProcessed**: `bigint` -Defined in: [interfaces.ts:19](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L19) +Defined in: [interfaces.ts:19](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L19) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:19](https://github.com/humanprotocol/human-protocol/b > **amountLocked**: `bigint` -Defined in: [interfaces.ts:14](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L14) +Defined in: [interfaces.ts:14](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L14) *** @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:14](https://github.com/humanprotocol/human-protocol/b > **amountSlashed**: `bigint` -Defined in: [interfaces.ts:17](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L17) +Defined in: [interfaces.ts:17](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L17) *** @@ -46,7 +46,7 @@ Defined in: [interfaces.ts:17](https://github.com/humanprotocol/human-protocol/b > **amountStaked**: `bigint` -Defined in: [interfaces.ts:13](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L13) +Defined in: [interfaces.ts:13](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L13) *** @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:13](https://github.com/humanprotocol/human-protocol/b > **amountWithdrawn**: `bigint` -Defined in: [interfaces.ts:16](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L16) +Defined in: [interfaces.ts:16](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L16) *** @@ -62,7 +62,7 @@ Defined in: [interfaces.ts:16](https://github.com/humanprotocol/human-protocol/b > `optional` **category**: `string` -Defined in: [interfaces.ts:31](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L31) +Defined in: [interfaces.ts:31](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L31) *** @@ -70,7 +70,7 @@ Defined in: [interfaces.ts:31](https://github.com/humanprotocol/human-protocol/b > **chainId**: [`ChainId`](../../enums/enumerations/ChainId.md) -Defined in: [interfaces.ts:11](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L11) +Defined in: [interfaces.ts:11](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L11) *** @@ -78,7 +78,7 @@ Defined in: [interfaces.ts:11](https://github.com/humanprotocol/human-protocol/b > `optional` **fee**: `bigint` -Defined in: [interfaces.ts:21](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L21) +Defined in: [interfaces.ts:21](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L21) *** @@ -86,7 +86,7 @@ Defined in: [interfaces.ts:21](https://github.com/humanprotocol/human-protocol/b > **id**: `string` -Defined in: [interfaces.ts:10](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L10) +Defined in: [interfaces.ts:10](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L10) *** @@ -94,7 +94,7 @@ Defined in: [interfaces.ts:10](https://github.com/humanprotocol/human-protocol/b > `optional` **jobTypes**: `string`[] -Defined in: [interfaces.ts:26](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L26) +Defined in: [interfaces.ts:26](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L26) *** @@ -102,7 +102,7 @@ Defined in: [interfaces.ts:26](https://github.com/humanprotocol/human-protocol/b > **lockedUntilTimestamp**: `bigint` -Defined in: [interfaces.ts:15](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L15) +Defined in: [interfaces.ts:15](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L15) *** @@ -110,7 +110,7 @@ Defined in: [interfaces.ts:15](https://github.com/humanprotocol/human-protocol/b > `optional` **name**: `string` -Defined in: [interfaces.ts:30](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L30) +Defined in: [interfaces.ts:30](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L30) *** @@ -118,7 +118,7 @@ Defined in: [interfaces.ts:30](https://github.com/humanprotocol/human-protocol/b > `optional` **publicKey**: `string` -Defined in: [interfaces.ts:22](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L22) +Defined in: [interfaces.ts:22](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L22) *** @@ -126,7 +126,7 @@ Defined in: [interfaces.ts:22](https://github.com/humanprotocol/human-protocol/b > `optional` **registrationInstructions**: `string` -Defined in: [interfaces.ts:28](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L28) +Defined in: [interfaces.ts:28](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L28) *** @@ -134,7 +134,7 @@ Defined in: [interfaces.ts:28](https://github.com/humanprotocol/human-protocol/b > `optional` **registrationNeeded**: `boolean` -Defined in: [interfaces.ts:27](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L27) +Defined in: [interfaces.ts:27](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L27) *** @@ -142,7 +142,7 @@ Defined in: [interfaces.ts:27](https://github.com/humanprotocol/human-protocol/b > `optional` **reputationNetworks**: `string`[] -Defined in: [interfaces.ts:29](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L29) +Defined in: [interfaces.ts:29](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L29) *** @@ -150,7 +150,7 @@ Defined in: [interfaces.ts:29](https://github.com/humanprotocol/human-protocol/b > **reward**: `bigint` -Defined in: [interfaces.ts:18](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L18) +Defined in: [interfaces.ts:18](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L18) *** @@ -158,7 +158,7 @@ Defined in: [interfaces.ts:18](https://github.com/humanprotocol/human-protocol/b > `optional` **role**: `string` -Defined in: [interfaces.ts:20](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L20) +Defined in: [interfaces.ts:20](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L20) *** @@ -166,7 +166,7 @@ Defined in: [interfaces.ts:20](https://github.com/humanprotocol/human-protocol/b > `optional` **url**: `string` -Defined in: [interfaces.ts:25](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L25) +Defined in: [interfaces.ts:25](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L25) *** @@ -174,7 +174,7 @@ Defined in: [interfaces.ts:25](https://github.com/humanprotocol/human-protocol/b > `optional` **webhookUrl**: `string` -Defined in: [interfaces.ts:23](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L23) +Defined in: [interfaces.ts:23](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L23) *** @@ -182,4 +182,4 @@ Defined in: [interfaces.ts:23](https://github.com/humanprotocol/human-protocol/b > `optional` **website**: `string` -Defined in: [interfaces.ts:24](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L24) +Defined in: [interfaces.ts:24](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L24) diff --git a/docs/sdk/typescript/interfaces/interfaces/IOperatorSubgraph.md b/docs/sdk/typescript/interfaces/interfaces/IOperatorSubgraph.md index 67010ab6c1..734d574b83 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IOperatorSubgraph.md +++ b/docs/sdk/typescript/interfaces/interfaces/IOperatorSubgraph.md @@ -6,7 +6,7 @@ # Interface: IOperatorSubgraph -Defined in: [interfaces.ts:34](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L34) +Defined in: [interfaces.ts:34](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L34) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:34](https://github.com/humanprotocol/human-protocol/b > **address**: `string` -Defined in: [interfaces.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L12) +Defined in: [interfaces.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L12) #### Inherited from @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:12](https://github.com/humanprotocol/human-protocol/b > **amountJobsProcessed**: `bigint` -Defined in: [interfaces.ts:19](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L19) +Defined in: [interfaces.ts:19](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L19) #### Inherited from @@ -42,7 +42,7 @@ Defined in: [interfaces.ts:19](https://github.com/humanprotocol/human-protocol/b > **amountLocked**: `bigint` -Defined in: [interfaces.ts:14](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L14) +Defined in: [interfaces.ts:14](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L14) #### Inherited from @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:14](https://github.com/humanprotocol/human-protocol/b > **amountSlashed**: `bigint` -Defined in: [interfaces.ts:17](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L17) +Defined in: [interfaces.ts:17](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L17) #### Inherited from @@ -66,7 +66,7 @@ Defined in: [interfaces.ts:17](https://github.com/humanprotocol/human-protocol/b > **amountStaked**: `bigint` -Defined in: [interfaces.ts:13](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L13) +Defined in: [interfaces.ts:13](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L13) #### Inherited from @@ -78,7 +78,7 @@ Defined in: [interfaces.ts:13](https://github.com/humanprotocol/human-protocol/b > **amountWithdrawn**: `bigint` -Defined in: [interfaces.ts:16](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L16) +Defined in: [interfaces.ts:16](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L16) #### Inherited from @@ -90,7 +90,7 @@ Defined in: [interfaces.ts:16](https://github.com/humanprotocol/human-protocol/b > `optional` **category**: `string` -Defined in: [interfaces.ts:31](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L31) +Defined in: [interfaces.ts:31](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L31) #### Inherited from @@ -102,7 +102,7 @@ Defined in: [interfaces.ts:31](https://github.com/humanprotocol/human-protocol/b > `optional` **fee**: `bigint` -Defined in: [interfaces.ts:21](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L21) +Defined in: [interfaces.ts:21](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L21) #### Inherited from @@ -114,7 +114,7 @@ Defined in: [interfaces.ts:21](https://github.com/humanprotocol/human-protocol/b > **id**: `string` -Defined in: [interfaces.ts:10](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L10) +Defined in: [interfaces.ts:10](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L10) #### Inherited from @@ -126,7 +126,7 @@ Defined in: [interfaces.ts:10](https://github.com/humanprotocol/human-protocol/b > `optional` **jobTypes**: `string` -Defined in: [interfaces.ts:36](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L36) +Defined in: [interfaces.ts:36](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L36) *** @@ -134,7 +134,7 @@ Defined in: [interfaces.ts:36](https://github.com/humanprotocol/human-protocol/b > **lockedUntilTimestamp**: `bigint` -Defined in: [interfaces.ts:15](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L15) +Defined in: [interfaces.ts:15](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L15) #### Inherited from @@ -146,7 +146,7 @@ Defined in: [interfaces.ts:15](https://github.com/humanprotocol/human-protocol/b > `optional` **name**: `string` -Defined in: [interfaces.ts:30](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L30) +Defined in: [interfaces.ts:30](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L30) #### Inherited from @@ -158,7 +158,7 @@ Defined in: [interfaces.ts:30](https://github.com/humanprotocol/human-protocol/b > `optional` **publicKey**: `string` -Defined in: [interfaces.ts:22](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L22) +Defined in: [interfaces.ts:22](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L22) #### Inherited from @@ -170,7 +170,7 @@ Defined in: [interfaces.ts:22](https://github.com/humanprotocol/human-protocol/b > `optional` **registrationInstructions**: `string` -Defined in: [interfaces.ts:28](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L28) +Defined in: [interfaces.ts:28](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L28) #### Inherited from @@ -182,7 +182,7 @@ Defined in: [interfaces.ts:28](https://github.com/humanprotocol/human-protocol/b > `optional` **registrationNeeded**: `boolean` -Defined in: [interfaces.ts:27](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L27) +Defined in: [interfaces.ts:27](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L27) #### Inherited from @@ -194,7 +194,7 @@ Defined in: [interfaces.ts:27](https://github.com/humanprotocol/human-protocol/b > `optional` **reputationNetworks**: `object`[] -Defined in: [interfaces.ts:37](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L37) +Defined in: [interfaces.ts:37](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L37) #### address @@ -206,7 +206,7 @@ Defined in: [interfaces.ts:37](https://github.com/humanprotocol/human-protocol/b > **reward**: `bigint` -Defined in: [interfaces.ts:18](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L18) +Defined in: [interfaces.ts:18](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L18) #### Inherited from @@ -218,7 +218,7 @@ Defined in: [interfaces.ts:18](https://github.com/humanprotocol/human-protocol/b > `optional` **role**: `string` -Defined in: [interfaces.ts:20](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L20) +Defined in: [interfaces.ts:20](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L20) #### Inherited from @@ -230,7 +230,7 @@ Defined in: [interfaces.ts:20](https://github.com/humanprotocol/human-protocol/b > `optional` **url**: `string` -Defined in: [interfaces.ts:25](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L25) +Defined in: [interfaces.ts:25](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L25) #### Inherited from @@ -242,7 +242,7 @@ Defined in: [interfaces.ts:25](https://github.com/humanprotocol/human-protocol/b > `optional` **webhookUrl**: `string` -Defined in: [interfaces.ts:23](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L23) +Defined in: [interfaces.ts:23](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L23) #### Inherited from @@ -254,7 +254,7 @@ Defined in: [interfaces.ts:23](https://github.com/humanprotocol/human-protocol/b > `optional` **website**: `string` -Defined in: [interfaces.ts:24](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L24) +Defined in: [interfaces.ts:24](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L24) #### Inherited from diff --git a/docs/sdk/typescript/interfaces/interfaces/IOperatorsFilter.md b/docs/sdk/typescript/interfaces/interfaces/IOperatorsFilter.md index db1065a56d..56f77154eb 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IOperatorsFilter.md +++ b/docs/sdk/typescript/interfaces/interfaces/IOperatorsFilter.md @@ -6,7 +6,7 @@ # Interface: IOperatorsFilter -Defined in: [interfaces.ts:40](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L40) +Defined in: [interfaces.ts:40](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L40) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:40](https://github.com/humanprotocol/human-protocol/b > **chainId**: [`ChainId`](../../enums/enumerations/ChainId.md) -Defined in: [interfaces.ts:41](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L41) +Defined in: [interfaces.ts:41](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L41) *** @@ -26,7 +26,7 @@ Defined in: [interfaces.ts:41](https://github.com/humanprotocol/human-protocol/b > `optional` **first**: `number` -Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) +Defined in: [interfaces.ts:157](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L157) #### Inherited from @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/ > `optional` **minAmountStaked**: `number` -Defined in: [interfaces.ts:43](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L43) +Defined in: [interfaces.ts:43](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L43) *** @@ -46,7 +46,7 @@ Defined in: [interfaces.ts:43](https://github.com/humanprotocol/human-protocol/b > `optional` **orderBy**: `string` -Defined in: [interfaces.ts:44](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L44) +Defined in: [interfaces.ts:44](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L44) *** @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:44](https://github.com/humanprotocol/human-protocol/b > `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) -Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L155) +Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) #### Inherited from @@ -66,7 +66,7 @@ Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/ > `optional` **roles**: `string`[] -Defined in: [interfaces.ts:42](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L42) +Defined in: [interfaces.ts:42](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L42) *** @@ -74,7 +74,7 @@ Defined in: [interfaces.ts:42](https://github.com/humanprotocol/human-protocol/b > `optional` **skip**: `number` -Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L154) +Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) #### Inherited from diff --git a/docs/sdk/typescript/interfaces/interfaces/IPagination.md b/docs/sdk/typescript/interfaces/interfaces/IPagination.md index 61fc8370bd..5a43cccc13 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IPagination.md +++ b/docs/sdk/typescript/interfaces/interfaces/IPagination.md @@ -6,7 +6,7 @@ # Interface: IPagination -Defined in: [interfaces.ts:152](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L152) +Defined in: [interfaces.ts:156](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L156) ## Extended by @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:152](https://github.com/humanprotocol/human-protocol/ > `optional` **first**: `number` -Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) +Defined in: [interfaces.ts:157](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L157) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/ > `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) -Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L155) +Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) *** @@ -38,4 +38,4 @@ Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/ > `optional` **skip**: `number` -Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L154) +Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) diff --git a/docs/sdk/typescript/interfaces/interfaces/IPayoutFilter.md b/docs/sdk/typescript/interfaces/interfaces/IPayoutFilter.md index 12595076ad..8cfeb78020 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IPayoutFilter.md +++ b/docs/sdk/typescript/interfaces/interfaces/IPayoutFilter.md @@ -6,15 +6,31 @@ # Interface: IPayoutFilter -Defined in: [interfaces.ts:106](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L106) +Defined in: [interfaces.ts:106](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L106) ## Properties +### chainId + +> **chainId**: [`ChainId`](../../enums/enumerations/ChainId.md) + +Defined in: [interfaces.ts:107](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L107) + +*** + ### escrowAddress? > `optional` **escrowAddress**: `string` -Defined in: [interfaces.ts:107](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L107) +Defined in: [interfaces.ts:108](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L108) + +*** + +### first? + +> `optional` **first**: `number` + +Defined in: [interfaces.ts:112](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L112) *** @@ -22,7 +38,15 @@ Defined in: [interfaces.ts:107](https://github.com/humanprotocol/human-protocol/ > `optional` **from**: `Date` -Defined in: [interfaces.ts:109](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L109) +Defined in: [interfaces.ts:110](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L110) + +*** + +### orderDirection? + +> `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) + +Defined in: [interfaces.ts:114](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L114) *** @@ -30,7 +54,15 @@ Defined in: [interfaces.ts:109](https://github.com/humanprotocol/human-protocol/ > `optional` **recipient**: `string` -Defined in: [interfaces.ts:108](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L108) +Defined in: [interfaces.ts:109](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L109) + +*** + +### skip? + +> `optional` **skip**: `number` + +Defined in: [interfaces.ts:113](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L113) *** @@ -38,4 +70,4 @@ Defined in: [interfaces.ts:108](https://github.com/humanprotocol/human-protocol/ > `optional` **to**: `Date` -Defined in: [interfaces.ts:110](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L110) +Defined in: [interfaces.ts:111](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L111) diff --git a/docs/sdk/typescript/interfaces/interfaces/IReputationNetwork.md b/docs/sdk/typescript/interfaces/interfaces/IReputationNetwork.md index 09c53c2a0c..e1f98a77c5 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IReputationNetwork.md +++ b/docs/sdk/typescript/interfaces/interfaces/IReputationNetwork.md @@ -6,7 +6,7 @@ # Interface: IReputationNetwork -Defined in: [interfaces.ts:47](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L47) +Defined in: [interfaces.ts:47](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L47) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:47](https://github.com/humanprotocol/human-protocol/b > **address**: `string` -Defined in: [interfaces.ts:49](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L49) +Defined in: [interfaces.ts:49](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L49) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:49](https://github.com/humanprotocol/human-protocol/b > **id**: `string` -Defined in: [interfaces.ts:48](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L48) +Defined in: [interfaces.ts:48](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L48) *** @@ -30,4 +30,4 @@ Defined in: [interfaces.ts:48](https://github.com/humanprotocol/human-protocol/b > **operators**: [`IOperator`](IOperator.md)[] -Defined in: [interfaces.ts:50](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L50) +Defined in: [interfaces.ts:50](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L50) diff --git a/docs/sdk/typescript/interfaces/interfaces/IReputationNetworkSubgraph.md b/docs/sdk/typescript/interfaces/interfaces/IReputationNetworkSubgraph.md index 755b35d79e..42e5e21e69 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IReputationNetworkSubgraph.md +++ b/docs/sdk/typescript/interfaces/interfaces/IReputationNetworkSubgraph.md @@ -6,7 +6,7 @@ # Interface: IReputationNetworkSubgraph -Defined in: [interfaces.ts:53](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L53) +Defined in: [interfaces.ts:53](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L53) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:53](https://github.com/humanprotocol/human-protocol/b > **address**: `string` -Defined in: [interfaces.ts:49](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L49) +Defined in: [interfaces.ts:49](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L49) #### Inherited from @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:49](https://github.com/humanprotocol/human-protocol/b > **id**: `string` -Defined in: [interfaces.ts:48](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L48) +Defined in: [interfaces.ts:48](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L48) #### Inherited from @@ -42,4 +42,4 @@ Defined in: [interfaces.ts:48](https://github.com/humanprotocol/human-protocol/b > **operators**: [`IOperatorSubgraph`](IOperatorSubgraph.md)[] -Defined in: [interfaces.ts:55](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L55) +Defined in: [interfaces.ts:55](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L55) diff --git a/docs/sdk/typescript/interfaces/interfaces/IReward.md b/docs/sdk/typescript/interfaces/interfaces/IReward.md index a8cb309f5c..ed39ac5c9e 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IReward.md +++ b/docs/sdk/typescript/interfaces/interfaces/IReward.md @@ -6,7 +6,7 @@ # Interface: IReward -Defined in: [interfaces.ts:4](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L4) +Defined in: [interfaces.ts:4](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L4) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:4](https://github.com/humanprotocol/human-protocol/bl > **amount**: `bigint` -Defined in: [interfaces.ts:6](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L6) +Defined in: [interfaces.ts:6](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L6) *** @@ -22,4 +22,4 @@ Defined in: [interfaces.ts:6](https://github.com/humanprotocol/human-protocol/bl > **escrowAddress**: `string` -Defined in: [interfaces.ts:5](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L5) +Defined in: [interfaces.ts:5](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L5) diff --git a/docs/sdk/typescript/interfaces/interfaces/IStatisticsFilter.md b/docs/sdk/typescript/interfaces/interfaces/IStatisticsFilter.md index 189b653af1..d6f4eb1620 100644 --- a/docs/sdk/typescript/interfaces/interfaces/IStatisticsFilter.md +++ b/docs/sdk/typescript/interfaces/interfaces/IStatisticsFilter.md @@ -6,7 +6,7 @@ # Interface: IStatisticsFilter -Defined in: [interfaces.ts:97](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L97) +Defined in: [interfaces.ts:97](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L97) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:97](https://github.com/humanprotocol/human-protocol/b > `optional` **first**: `number` -Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) +Defined in: [interfaces.ts:157](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L157) #### Inherited from @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/ > `optional` **from**: `Date` -Defined in: [interfaces.ts:98](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L98) +Defined in: [interfaces.ts:98](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L98) *** @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:98](https://github.com/humanprotocol/human-protocol/b > `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) -Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L155) +Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) #### Inherited from @@ -50,7 +50,7 @@ Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/ > `optional` **skip**: `number` -Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L154) +Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) #### Inherited from @@ -62,4 +62,4 @@ Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/ > `optional` **to**: `Date` -Defined in: [interfaces.ts:99](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L99) +Defined in: [interfaces.ts:99](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L99) diff --git a/docs/sdk/typescript/interfaces/interfaces/IStatusEventFilter.md b/docs/sdk/typescript/interfaces/interfaces/IStatusEventFilter.md new file mode 100644 index 0000000000..0a71853420 --- /dev/null +++ b/docs/sdk/typescript/interfaces/interfaces/IStatusEventFilter.md @@ -0,0 +1,73 @@ +[**@human-protocol/sdk**](../../README.md) + +*** + +[@human-protocol/sdk](../../modules.md) / [interfaces](../README.md) / IStatusEventFilter + +# Interface: IStatusEventFilter + +Defined in: [interfaces.ts:169](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L169) + +## Properties + +### chainId + +> **chainId**: [`ChainId`](../../enums/enumerations/ChainId.md) + +Defined in: [interfaces.ts:170](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L170) + +*** + +### first? + +> `optional` **first**: `number` + +Defined in: [interfaces.ts:175](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L175) + +*** + +### from? + +> `optional` **from**: `Date` + +Defined in: [interfaces.ts:172](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L172) + +*** + +### launcher? + +> `optional` **launcher**: `string` + +Defined in: [interfaces.ts:174](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L174) + +*** + +### orderDirection? + +> `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) + +Defined in: [interfaces.ts:177](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L177) + +*** + +### skip? + +> `optional` **skip**: `number` + +Defined in: [interfaces.ts:176](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L176) + +*** + +### statuses? + +> `optional` **statuses**: [`EscrowStatus`](../../types/enumerations/EscrowStatus.md)[] + +Defined in: [interfaces.ts:171](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L171) + +*** + +### to? + +> `optional` **to**: `Date` + +Defined in: [interfaces.ts:173](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L173) diff --git a/docs/sdk/typescript/interfaces/interfaces/ITransaction.md b/docs/sdk/typescript/interfaces/interfaces/ITransaction.md index b955575a89..b3e76e7a24 100644 --- a/docs/sdk/typescript/interfaces/interfaces/ITransaction.md +++ b/docs/sdk/typescript/interfaces/interfaces/ITransaction.md @@ -6,7 +6,7 @@ # Interface: ITransaction -Defined in: [interfaces.ts:128](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L128) +Defined in: [interfaces.ts:132](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L132) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:128](https://github.com/humanprotocol/human-protocol/ > **block**: `bigint` -Defined in: [interfaces.ts:129](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L129) +Defined in: [interfaces.ts:133](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L133) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:129](https://github.com/humanprotocol/human-protocol/ > `optional` **escrow**: `string` -Defined in: [interfaces.ts:137](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L137) +Defined in: [interfaces.ts:141](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L141) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:137](https://github.com/humanprotocol/human-protocol/ > **from**: `string` -Defined in: [interfaces.ts:131](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L131) +Defined in: [interfaces.ts:135](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L135) *** @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:131](https://github.com/humanprotocol/human-protocol/ > **internalTransactions**: [`InternalTransaction`](InternalTransaction.md)[] -Defined in: [interfaces.ts:139](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L139) +Defined in: [interfaces.ts:143](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L143) *** @@ -46,7 +46,7 @@ Defined in: [interfaces.ts:139](https://github.com/humanprotocol/human-protocol/ > **method**: `string` -Defined in: [interfaces.ts:135](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L135) +Defined in: [interfaces.ts:139](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L139) *** @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:135](https://github.com/humanprotocol/human-protocol/ > `optional` **receiver**: `string` -Defined in: [interfaces.ts:136](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L136) +Defined in: [interfaces.ts:140](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L140) *** @@ -62,7 +62,7 @@ Defined in: [interfaces.ts:136](https://github.com/humanprotocol/human-protocol/ > **timestamp**: `bigint` -Defined in: [interfaces.ts:133](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L133) +Defined in: [interfaces.ts:137](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L137) *** @@ -70,7 +70,7 @@ Defined in: [interfaces.ts:133](https://github.com/humanprotocol/human-protocol/ > **to**: `string` -Defined in: [interfaces.ts:132](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L132) +Defined in: [interfaces.ts:136](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L136) *** @@ -78,7 +78,7 @@ Defined in: [interfaces.ts:132](https://github.com/humanprotocol/human-protocol/ > `optional` **token**: `string` -Defined in: [interfaces.ts:138](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L138) +Defined in: [interfaces.ts:142](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L142) *** @@ -86,7 +86,7 @@ Defined in: [interfaces.ts:138](https://github.com/humanprotocol/human-protocol/ > **txHash**: `string` -Defined in: [interfaces.ts:130](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L130) +Defined in: [interfaces.ts:134](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L134) *** @@ -94,4 +94,4 @@ Defined in: [interfaces.ts:130](https://github.com/humanprotocol/human-protocol/ > **value**: `string` -Defined in: [interfaces.ts:134](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L134) +Defined in: [interfaces.ts:138](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L138) diff --git a/docs/sdk/typescript/interfaces/interfaces/ITransactionsFilter.md b/docs/sdk/typescript/interfaces/interfaces/ITransactionsFilter.md index bf5baaaef9..7d979e65d2 100644 --- a/docs/sdk/typescript/interfaces/interfaces/ITransactionsFilter.md +++ b/docs/sdk/typescript/interfaces/interfaces/ITransactionsFilter.md @@ -6,7 +6,7 @@ # Interface: ITransactionsFilter -Defined in: [interfaces.ts:142](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L142) +Defined in: [interfaces.ts:146](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L146) ## Extends @@ -18,7 +18,7 @@ Defined in: [interfaces.ts:142](https://github.com/humanprotocol/human-protocol/ > **chainId**: [`ChainId`](../../enums/enumerations/ChainId.md) -Defined in: [interfaces.ts:143](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L143) +Defined in: [interfaces.ts:147](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L147) *** @@ -26,7 +26,7 @@ Defined in: [interfaces.ts:143](https://github.com/humanprotocol/human-protocol/ > `optional` **endBlock**: `number` -Defined in: [interfaces.ts:145](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L145) +Defined in: [interfaces.ts:149](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L149) *** @@ -34,7 +34,7 @@ Defined in: [interfaces.ts:145](https://github.com/humanprotocol/human-protocol/ > `optional` **endDate**: `Date` -Defined in: [interfaces.ts:147](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L147) +Defined in: [interfaces.ts:151](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L151) *** @@ -42,7 +42,7 @@ Defined in: [interfaces.ts:147](https://github.com/humanprotocol/human-protocol/ > `optional` **first**: `number` -Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) +Defined in: [interfaces.ts:157](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L157) #### Inherited from @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/ > `optional` **fromAddress**: `string` -Defined in: [interfaces.ts:148](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L148) +Defined in: [interfaces.ts:152](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L152) *** @@ -62,7 +62,7 @@ Defined in: [interfaces.ts:148](https://github.com/humanprotocol/human-protocol/ > `optional` **orderDirection**: [`OrderDirection`](../../enums/enumerations/OrderDirection.md) -Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L155) +Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) #### Inherited from @@ -74,7 +74,7 @@ Defined in: [interfaces.ts:155](https://github.com/humanprotocol/human-protocol/ > `optional` **skip**: `number` -Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L154) +Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) #### Inherited from @@ -86,7 +86,7 @@ Defined in: [interfaces.ts:154](https://github.com/humanprotocol/human-protocol/ > `optional` **startBlock**: `number` -Defined in: [interfaces.ts:144](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L144) +Defined in: [interfaces.ts:148](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L148) *** @@ -94,7 +94,7 @@ Defined in: [interfaces.ts:144](https://github.com/humanprotocol/human-protocol/ > `optional` **startDate**: `Date` -Defined in: [interfaces.ts:146](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L146) +Defined in: [interfaces.ts:150](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L150) *** @@ -102,4 +102,4 @@ Defined in: [interfaces.ts:146](https://github.com/humanprotocol/human-protocol/ > `optional` **toAddress**: `string` -Defined in: [interfaces.ts:149](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L149) +Defined in: [interfaces.ts:153](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L153) diff --git a/docs/sdk/typescript/interfaces/interfaces/InternalTransaction.md b/docs/sdk/typescript/interfaces/interfaces/InternalTransaction.md index 7a1993cdb0..b549a60af3 100644 --- a/docs/sdk/typescript/interfaces/interfaces/InternalTransaction.md +++ b/docs/sdk/typescript/interfaces/interfaces/InternalTransaction.md @@ -6,7 +6,7 @@ # Interface: InternalTransaction -Defined in: [interfaces.ts:118](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L118) +Defined in: [interfaces.ts:122](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L122) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:118](https://github.com/humanprotocol/human-protocol/ > `optional` **escrow**: `string` -Defined in: [interfaces.ts:124](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L124) +Defined in: [interfaces.ts:128](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L128) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:124](https://github.com/humanprotocol/human-protocol/ > **from**: `string` -Defined in: [interfaces.ts:119](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L119) +Defined in: [interfaces.ts:123](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L123) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:119](https://github.com/humanprotocol/human-protocol/ > **method**: `string` -Defined in: [interfaces.ts:122](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L122) +Defined in: [interfaces.ts:126](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L126) *** @@ -38,7 +38,7 @@ Defined in: [interfaces.ts:122](https://github.com/humanprotocol/human-protocol/ > `optional` **receiver**: `string` -Defined in: [interfaces.ts:123](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L123) +Defined in: [interfaces.ts:127](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L127) *** @@ -46,7 +46,7 @@ Defined in: [interfaces.ts:123](https://github.com/humanprotocol/human-protocol/ > **to**: `string` -Defined in: [interfaces.ts:120](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L120) +Defined in: [interfaces.ts:124](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L124) *** @@ -54,7 +54,7 @@ Defined in: [interfaces.ts:120](https://github.com/humanprotocol/human-protocol/ > `optional` **token**: `string` -Defined in: [interfaces.ts:125](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L125) +Defined in: [interfaces.ts:129](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L129) *** @@ -62,4 +62,4 @@ Defined in: [interfaces.ts:125](https://github.com/humanprotocol/human-protocol/ > **value**: `string` -Defined in: [interfaces.ts:121](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L121) +Defined in: [interfaces.ts:125](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L125) diff --git a/docs/sdk/typescript/interfaces/interfaces/StakerInfo.md b/docs/sdk/typescript/interfaces/interfaces/StakerInfo.md index 6a07d5191d..1449f7fce3 100644 --- a/docs/sdk/typescript/interfaces/interfaces/StakerInfo.md +++ b/docs/sdk/typescript/interfaces/interfaces/StakerInfo.md @@ -6,7 +6,7 @@ # Interface: StakerInfo -Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L158) +Defined in: [interfaces.ts:162](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L162) ## Properties @@ -14,7 +14,7 @@ Defined in: [interfaces.ts:158](https://github.com/humanprotocol/human-protocol/ > **lockedAmount**: `bigint` -Defined in: [interfaces.ts:160](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L160) +Defined in: [interfaces.ts:164](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L164) *** @@ -22,7 +22,7 @@ Defined in: [interfaces.ts:160](https://github.com/humanprotocol/human-protocol/ > **lockedUntil**: `bigint` -Defined in: [interfaces.ts:161](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L161) +Defined in: [interfaces.ts:165](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L165) *** @@ -30,7 +30,7 @@ Defined in: [interfaces.ts:161](https://github.com/humanprotocol/human-protocol/ > **stakedAmount**: `bigint` -Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L159) +Defined in: [interfaces.ts:163](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L163) *** @@ -38,4 +38,4 @@ Defined in: [interfaces.ts:159](https://github.com/humanprotocol/human-protocol/ > **withdrawableAmount**: `bigint` -Defined in: [interfaces.ts:162](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L162) +Defined in: [interfaces.ts:166](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts#L166) diff --git a/docs/sdk/typescript/kvstore/classes/KVStoreClient.md b/docs/sdk/typescript/kvstore/classes/KVStoreClient.md index d78e6862be..8e17f3d569 100644 --- a/docs/sdk/typescript/kvstore/classes/KVStoreClient.md +++ b/docs/sdk/typescript/kvstore/classes/KVStoreClient.md @@ -6,7 +6,7 @@ # Class: KVStoreClient -Defined in: [kvstore.ts:99](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L99) +Defined in: [kvstore.ts:99](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L99) ## Introduction @@ -86,7 +86,7 @@ const kvstoreClient = await KVStoreClient.build(provider); > **new KVStoreClient**(`runner`, `networkData`): [`KVStoreClient`](KVStoreClient.md) -Defined in: [kvstore.ts:108](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L108) +Defined in: [kvstore.ts:108](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L108) **KVStoreClient constructor** @@ -118,7 +118,7 @@ The network information required to connect to the KVStore contract > **networkData**: [`NetworkData`](../../types/type-aliases/NetworkData.md) -Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) +Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) #### Inherited from @@ -130,7 +130,7 @@ Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06 > `protected` **runner**: `ContractRunner` -Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) +Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) #### Inherited from @@ -142,7 +142,7 @@ Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06 > **set**(`key`, `value`, `txOptions`?): `Promise`\<`void`\> -Defined in: [kvstore.ts:171](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L171) +Defined in: [kvstore.ts:171](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L171) This function sets a key-value pair associated with the address that submits the transaction. @@ -196,7 +196,7 @@ await kvstoreClient.set('Role', 'RecordingOracle'); > **setBulk**(`keys`, `values`, `txOptions`?): `Promise`\<`void`\> -Defined in: [kvstore.ts:214](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L214) +Defined in: [kvstore.ts:214](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L214) This function sets key-value pairs in bulk associated with the address that submits the transaction. @@ -252,7 +252,7 @@ await kvstoreClient.setBulk(keys, values); > **setFileUrlAndHash**(`url`, `urlKey`, `txOptions`?): `Promise`\<`void`\> -Defined in: [kvstore.ts:257](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L257) +Defined in: [kvstore.ts:257](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L257) Sets a URL value for the address that submits the transaction, and its hash. @@ -305,7 +305,7 @@ await kvstoreClient.setFileUrlAndHash('linkedin.com/example', 'linkedin_url'); > `static` **build**(`runner`): `Promise`\<[`KVStoreClient`](KVStoreClient.md)\> -Defined in: [kvstore.ts:126](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L126) +Defined in: [kvstore.ts:126](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L126) Creates an instance of KVStoreClient from a runner. diff --git a/docs/sdk/typescript/kvstore/classes/KVStoreUtils.md b/docs/sdk/typescript/kvstore/classes/KVStoreUtils.md index 25c6968e0a..11f670ba09 100644 --- a/docs/sdk/typescript/kvstore/classes/KVStoreUtils.md +++ b/docs/sdk/typescript/kvstore/classes/KVStoreUtils.md @@ -6,7 +6,7 @@ # Class: KVStoreUtils -Defined in: [kvstore.ts:318](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L318) +Defined in: [kvstore.ts:318](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L318) ## Introduction @@ -55,7 +55,7 @@ const KVStoreAddresses = await KVStoreUtils.getKVStoreData( > `static` **get**(`chainId`, `address`, `key`): `Promise`\<`string`\> -Defined in: [kvstore.ts:389](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L389) +Defined in: [kvstore.ts:389](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L389) Gets the value of a key-value pair in the KVStore using the subgraph. @@ -116,7 +116,7 @@ console.log(value); > `static` **getFileUrlAndVerifyHash**(`chainId`, `address`, `urlKey`): `Promise`\<`string`\> -Defined in: [kvstore.ts:436](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L436) +Defined in: [kvstore.ts:436](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L436) Gets the URL value of the given entity, and verifies its hash. @@ -164,7 +164,7 @@ console.log(url); > `static` **getKVStoreData**(`chainId`, `address`): `Promise`\<[`IKVStore`](../../interfaces/interfaces/IKVStore.md)[]\> -Defined in: [kvstore.ts:337](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L337) +Defined in: [kvstore.ts:337](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L337) This function returns the KVStore data for a given address. @@ -211,7 +211,7 @@ console.log(kvStoreData); > `static` **getPublicKey**(`chainId`, `address`): `Promise`\<`string`\> -Defined in: [kvstore.ts:496](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L496) +Defined in: [kvstore.ts:496](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/kvstore.ts#L496) Gets the public key of the given entity, and verifies its hash. diff --git a/docs/sdk/typescript/operator/classes/OperatorUtils.md b/docs/sdk/typescript/operator/classes/OperatorUtils.md index 64e02a0563..4b7aedc4e0 100644 --- a/docs/sdk/typescript/operator/classes/OperatorUtils.md +++ b/docs/sdk/typescript/operator/classes/OperatorUtils.md @@ -6,7 +6,7 @@ # Class: OperatorUtils -Defined in: [operator.ts:27](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L27) +Defined in: [operator.ts:27](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L27) ## Constructors @@ -24,7 +24,7 @@ Defined in: [operator.ts:27](https://github.com/humanprotocol/human-protocol/blo > `static` **getOperator**(`chainId`, `address`): `Promise`\<[`IOperator`](../../interfaces/interfaces/IOperator.md)\> -Defined in: [operator.ts:43](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L43) +Defined in: [operator.ts:43](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L43) This function returns the operator data for the given address. @@ -62,7 +62,7 @@ const operator = await OperatorUtils.getOperator(ChainId.POLYGON_AMOY, '0x62dD51 > `static` **getOperators**(`filter`): `Promise`\<[`IOperator`](../../interfaces/interfaces/IOperator.md)[]\> -Defined in: [operator.ts:109](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L109) +Defined in: [operator.ts:109](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L109) This function returns all the operator details of the protocol. @@ -97,7 +97,7 @@ const operators = await OperatorUtils.getOperators(filter); > `static` **getReputationNetworkOperators**(`chainId`, `address`, `role`?): `Promise`\<[`IOperator`](../../interfaces/interfaces/IOperator.md)[]\> -Defined in: [operator.ts:190](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L190) +Defined in: [operator.ts:190](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L190) Retrieves the reputation network operators of the specified address. @@ -141,7 +141,7 @@ const operators = await OperatorUtils.getReputationNetworkOperators(ChainId.POLY > `static` **getRewards**(`chainId`, `slasherAddress`): `Promise`\<[`IReward`](../../interfaces/interfaces/IReward.md)[]\> -Defined in: [operator.ts:244](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L244) +Defined in: [operator.ts:244](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/operator.ts#L244) This function returns information about the rewards for a given slasher address. diff --git a/docs/sdk/typescript/staking/classes/StakingClient.md b/docs/sdk/typescript/staking/classes/StakingClient.md index 5065b6941f..459965895d 100644 --- a/docs/sdk/typescript/staking/classes/StakingClient.md +++ b/docs/sdk/typescript/staking/classes/StakingClient.md @@ -6,7 +6,7 @@ # Class: StakingClient -Defined in: [staking.ts:97](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L97) +Defined in: [staking.ts:97](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L97) ## Introduction @@ -86,7 +86,7 @@ const stakingClient = await StakingClient.build(provider); > **new StakingClient**(`runner`, `networkData`): [`StakingClient`](StakingClient.md) -Defined in: [staking.ts:108](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L108) +Defined in: [staking.ts:108](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L108) **StakingClient constructor** @@ -118,7 +118,7 @@ The network information required to connect to the Staking contract > **escrowFactoryContract**: `EscrowFactory` -Defined in: [staking.ts:100](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L100) +Defined in: [staking.ts:100](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L100) *** @@ -126,7 +126,7 @@ Defined in: [staking.ts:100](https://github.com/humanprotocol/human-protocol/blo > **networkData**: [`NetworkData`](../../types/type-aliases/NetworkData.md) -Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) +Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L12) #### Inherited from @@ -138,7 +138,7 @@ Defined in: [base.ts:12](https://github.com/humanprotocol/human-protocol/blob/06 > `protected` **runner**: `ContractRunner` -Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) +Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/base.ts#L11) #### Inherited from @@ -150,7 +150,7 @@ Defined in: [base.ts:11](https://github.com/humanprotocol/human-protocol/blob/06 > **stakingContract**: `Staking` -Defined in: [staking.ts:99](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L99) +Defined in: [staking.ts:99](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L99) *** @@ -158,7 +158,7 @@ Defined in: [staking.ts:99](https://github.com/humanprotocol/human-protocol/blob > **tokenContract**: `HMToken` -Defined in: [staking.ts:98](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L98) +Defined in: [staking.ts:98](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L98) ## Methods @@ -166,7 +166,7 @@ Defined in: [staking.ts:98](https://github.com/humanprotocol/human-protocol/blob > **approveStake**(`amount`, `txOptions`?): `Promise`\<`void`\> -Defined in: [staking.ts:193](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L193) +Defined in: [staking.ts:193](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L193) This function approves the staking contract to transfer a specified amount of tokens when the user stakes. It increases the allowance for the staking contract. @@ -213,7 +213,7 @@ await stakingClient.approveStake(amount); > **getStakerInfo**(`stakerAddress`): `Promise`\<[`StakerInfo`](../../interfaces/interfaces/StakerInfo.md)\> -Defined in: [staking.ts:435](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L435) +Defined in: [staking.ts:435](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L435) Retrieves comprehensive staking information for a staker. @@ -249,7 +249,7 @@ console.log(stakingInfo.tokensStaked); > **slash**(`slasher`, `staker`, `escrowAddress`, `amount`, `txOptions`?): `Promise`\<`void`\> -Defined in: [staking.ts:373](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L373) +Defined in: [staking.ts:373](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L373) This function reduces the allocated amount by a staker in an escrow and transfers those tokens to the reward pool. This allows the slasher to claim them later. @@ -314,7 +314,7 @@ await stakingClient.slash('0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266', '0xf39Fd > **stake**(`amount`, `txOptions`?): `Promise`\<`void`\> -Defined in: [staking.ts:247](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L247) +Defined in: [staking.ts:247](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L247) This function stakes a specified amount of tokens on a specific network. @@ -364,7 +364,7 @@ await stakingClient.stake(amount); > **unstake**(`amount`, `txOptions`?): `Promise`\<`void`\> -Defined in: [staking.ts:291](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L291) +Defined in: [staking.ts:291](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L291) This function unstakes tokens from staking contract. The unstaked tokens stay locked for a period of time. @@ -413,7 +413,7 @@ await stakingClient.unstake(amount); > **withdraw**(`txOptions`?): `Promise`\<`void`\> -Defined in: [staking.ts:336](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L336) +Defined in: [staking.ts:336](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L336) This function withdraws unstaked and non-locked tokens from staking contract to the user wallet. @@ -455,7 +455,7 @@ await stakingClient.withdraw(); > `static` **build**(`runner`): `Promise`\<[`StakingClient`](StakingClient.md)\> -Defined in: [staking.ts:136](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L136) +Defined in: [staking.ts:136](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/staking.ts#L136) Creates an instance of StakingClient from a Runner. diff --git a/docs/sdk/typescript/statistics/classes/StatisticsClient.md b/docs/sdk/typescript/statistics/classes/StatisticsClient.md index 6bd87f6e83..8c7ad98dda 100644 --- a/docs/sdk/typescript/statistics/classes/StatisticsClient.md +++ b/docs/sdk/typescript/statistics/classes/StatisticsClient.md @@ -6,7 +6,7 @@ # Class: StatisticsClient -Defined in: [statistics.ts:58](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L58) +Defined in: [statistics.ts:58](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L58) ## Introduction @@ -45,7 +45,7 @@ const statisticsClient = new StatisticsClient(NETWORKS[ChainId.POLYGON_AMOY]); > **new StatisticsClient**(`networkData`): [`StatisticsClient`](StatisticsClient.md) -Defined in: [statistics.ts:67](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L67) +Defined in: [statistics.ts:67](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L67) **StatisticsClient constructor** @@ -67,7 +67,7 @@ The network information required to connect to the Statistics contract > **networkData**: [`NetworkData`](../../types/type-aliases/NetworkData.md) -Defined in: [statistics.ts:59](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L59) +Defined in: [statistics.ts:59](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L59) *** @@ -75,7 +75,7 @@ Defined in: [statistics.ts:59](https://github.com/humanprotocol/human-protocol/b > **subgraphUrl**: `string` -Defined in: [statistics.ts:60](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L60) +Defined in: [statistics.ts:60](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L60) ## Methods @@ -83,7 +83,7 @@ Defined in: [statistics.ts:60](https://github.com/humanprotocol/human-protocol/b > **getEscrowStatistics**(`filter`): `Promise`\<[`EscrowStatistics`](../../graphql/types/type-aliases/EscrowStatistics.md)\> -Defined in: [statistics.ts:120](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L120) +Defined in: [statistics.ts:120](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L120) This function returns the statistical data of escrows. @@ -149,7 +149,7 @@ const escrowStatisticsApril = await statisticsClient.getEscrowStatistics({ > **getHMTDailyData**(`filter`): `Promise`\<[`DailyHMTData`](../../graphql/types/type-aliases/DailyHMTData.md)[]\> -Defined in: [statistics.ts:478](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L478) +Defined in: [statistics.ts:478](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L478) This function returns the statistical data of HMToken day by day. @@ -214,7 +214,7 @@ console.log('HMT statistics from 5/8 - 6/8:', hmtStatisticsRange); > **getHMTHolders**(`params`): `Promise`\<[`HMTHolder`](../../graphql/types/type-aliases/HMTHolder.md)[]\> -Defined in: [statistics.ts:407](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L407) +Defined in: [statistics.ts:407](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L407) This function returns the holders of the HMToken with optional filters and ordering. @@ -257,7 +257,7 @@ console.log('HMT holders:', hmtHolders.map((h) => ({ > **getHMTStatistics**(): `Promise`\<[`HMTStatistics`](../../graphql/types/type-aliases/HMTStatistics.md)\> -Defined in: [statistics.ts:364](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L364) +Defined in: [statistics.ts:364](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L364) This function returns the statistical data of HMToken. @@ -296,7 +296,7 @@ console.log('HMT statistics:', { > **getPaymentStatistics**(`filter`): `Promise`\<[`PaymentStatistics`](../../graphql/types/type-aliases/PaymentStatistics.md)\> -Defined in: [statistics.ts:300](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L300) +Defined in: [statistics.ts:300](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L300) This function returns the statistical data of payments. @@ -380,7 +380,7 @@ console.log( > **getWorkerStatistics**(`filter`): `Promise`\<[`WorkerStatistics`](../../graphql/types/type-aliases/WorkerStatistics.md)\> -Defined in: [statistics.ts:204](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L204) +Defined in: [statistics.ts:204](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/statistics.ts#L204) This function returns the statistical data of workers. diff --git a/docs/sdk/typescript/storage/classes/StorageClient.md b/docs/sdk/typescript/storage/classes/StorageClient.md index 6ce1cde592..4984cd664b 100644 --- a/docs/sdk/typescript/storage/classes/StorageClient.md +++ b/docs/sdk/typescript/storage/classes/StorageClient.md @@ -6,7 +6,7 @@ # Class: ~~StorageClient~~ -Defined in: [storage.ts:63](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L63) +Defined in: [storage.ts:63](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L63) ## Deprecated @@ -61,7 +61,7 @@ const storageClient = new StorageClient(params, credentials); > **new StorageClient**(`params`, `credentials`?): [`StorageClient`](StorageClient.md) -Defined in: [storage.ts:73](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L73) +Defined in: [storage.ts:73](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L73) **Storage client constructor** @@ -89,7 +89,7 @@ Optional. Cloud storage access data. If credentials are not provided - use anony > **bucketExists**(`bucket`): `Promise`\<`boolean`\> -Defined in: [storage.ts:262](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L262) +Defined in: [storage.ts:262](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L262) This function checks if a bucket exists. @@ -133,7 +133,7 @@ const exists = await storageClient.bucketExists('bucket-name'); > **downloadFiles**(`keys`, `bucket`): `Promise`\<`any`[]\> -Defined in: [storage.ts:112](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L112) +Defined in: [storage.ts:112](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L112) This function downloads files from a bucket. @@ -181,7 +181,7 @@ const files = await storageClient.downloadFiles(keys, 'bucket-name'); > **listObjects**(`bucket`): `Promise`\<`string`[]\> -Defined in: [storage.ts:292](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L292) +Defined in: [storage.ts:292](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L292) This function lists all file names contained in the bucket. @@ -225,7 +225,7 @@ const fileNames = await storageClient.listObjects('bucket-name'); > **uploadFiles**(`files`, `bucket`): `Promise`\<[`UploadFile`](../../types/type-aliases/UploadFile.md)[]\> -Defined in: [storage.ts:198](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L198) +Defined in: [storage.ts:198](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L198) This function uploads files to a bucket. @@ -278,7 +278,7 @@ const uploadedFiles = await storageClient.uploadFiles(files, 'bucket-name'); > `static` **downloadFileFromUrl**(`url`): `Promise`\<`any`\> -Defined in: [storage.ts:146](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L146) +Defined in: [storage.ts:146](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/storage.ts#L146) This function downloads files from a URL. diff --git a/docs/sdk/typescript/transaction/classes/TransactionUtils.md b/docs/sdk/typescript/transaction/classes/TransactionUtils.md index cb8ed148aa..eabf2632ac 100644 --- a/docs/sdk/typescript/transaction/classes/TransactionUtils.md +++ b/docs/sdk/typescript/transaction/classes/TransactionUtils.md @@ -6,7 +6,7 @@ # Class: TransactionUtils -Defined in: [transaction.ts:18](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/transaction.ts#L18) +Defined in: [transaction.ts:18](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/transaction.ts#L18) ## Constructors @@ -24,7 +24,7 @@ Defined in: [transaction.ts:18](https://github.com/humanprotocol/human-protocol/ > `static` **getTransaction**(`chainId`, `hash`): `Promise`\<[`ITransaction`](../../interfaces/interfaces/ITransaction.md)\> -Defined in: [transaction.ts:34](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/transaction.ts#L34) +Defined in: [transaction.ts:34](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/transaction.ts#L34) This function returns the transaction data for the given hash. @@ -62,7 +62,7 @@ const transaction = await TransactionUtils.getTransaction(ChainId.POLYGON, '0x62 > `static` **getTransactions**(`filter`): `Promise`\<[`ITransaction`](../../interfaces/interfaces/ITransaction.md)[]\> -Defined in: [transaction.ts:109](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/transaction.ts#L109) +Defined in: [transaction.ts:109](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/transaction.ts#L109) This function returns all transaction details based on the provided filter. diff --git a/docs/sdk/typescript/types/README.md b/docs/sdk/typescript/types/README.md index 87ec7b13af..19291e4dc2 100644 --- a/docs/sdk/typescript/types/README.md +++ b/docs/sdk/typescript/types/README.md @@ -15,6 +15,7 @@ - [EscrowCancel](type-aliases/EscrowCancel.md) - [EscrowWithdraw](type-aliases/EscrowWithdraw.md) - [NetworkData](type-aliases/NetworkData.md) +- [Payout](type-aliases/Payout.md) - [~~StorageCredentials~~](type-aliases/StorageCredentials.md) - [~~StorageParams~~](type-aliases/StorageParams.md) - [TransactionLikeWithNonce](type-aliases/TransactionLikeWithNonce.md) diff --git a/docs/sdk/typescript/types/enumerations/EscrowStatus.md b/docs/sdk/typescript/types/enumerations/EscrowStatus.md index 5db7ff8d60..c2f3976098 100644 --- a/docs/sdk/typescript/types/enumerations/EscrowStatus.md +++ b/docs/sdk/typescript/types/enumerations/EscrowStatus.md @@ -6,7 +6,7 @@ # Enumeration: EscrowStatus -Defined in: [types.ts:8](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L8) +Defined in: [types.ts:8](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L8) Enum for escrow statuses. @@ -16,7 +16,7 @@ Enum for escrow statuses. > **Cancelled**: `5` -Defined in: [types.ts:32](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L32) +Defined in: [types.ts:32](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L32) Escrow is cancelled. @@ -26,7 +26,7 @@ Escrow is cancelled. > **Complete**: `4` -Defined in: [types.ts:28](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L28) +Defined in: [types.ts:28](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L28) Escrow is finished. @@ -36,7 +36,7 @@ Escrow is finished. > **Launched**: `0` -Defined in: [types.ts:12](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L12) +Defined in: [types.ts:12](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L12) Escrow is launched. @@ -46,7 +46,7 @@ Escrow is launched. > **Paid**: `3` -Defined in: [types.ts:24](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L24) +Defined in: [types.ts:24](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L24) Escrow is fully paid. @@ -56,7 +56,7 @@ Escrow is fully paid. > **Partial**: `2` -Defined in: [types.ts:20](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L20) +Defined in: [types.ts:20](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L20) Escrow is partially paid out. @@ -66,6 +66,6 @@ Escrow is partially paid out. > **Pending**: `1` -Defined in: [types.ts:16](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L16) +Defined in: [types.ts:16](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L16) Escrow is funded, and waiting for the results to be submitted. diff --git a/docs/sdk/typescript/types/type-aliases/EscrowCancel.md b/docs/sdk/typescript/types/type-aliases/EscrowCancel.md index cf30dfbaa7..43b395a252 100644 --- a/docs/sdk/typescript/types/type-aliases/EscrowCancel.md +++ b/docs/sdk/typescript/types/type-aliases/EscrowCancel.md @@ -8,7 +8,7 @@ > **EscrowCancel**: `object` -Defined in: [types.ts:145](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L145) +Defined in: [types.ts:145](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L145) Represents the response data for an escrow cancellation. diff --git a/docs/sdk/typescript/types/type-aliases/EscrowWithdraw.md b/docs/sdk/typescript/types/type-aliases/EscrowWithdraw.md index 4cdfe43b66..ff7da73da5 100644 --- a/docs/sdk/typescript/types/type-aliases/EscrowWithdraw.md +++ b/docs/sdk/typescript/types/type-aliases/EscrowWithdraw.md @@ -8,7 +8,7 @@ > **EscrowWithdraw**: `object` -Defined in: [types.ts:159](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L159) +Defined in: [types.ts:159](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L159) Represents the response data for an escrow withdrawal. diff --git a/docs/sdk/typescript/types/type-aliases/NetworkData.md b/docs/sdk/typescript/types/type-aliases/NetworkData.md index f00440d4e3..1ed0e117b4 100644 --- a/docs/sdk/typescript/types/type-aliases/NetworkData.md +++ b/docs/sdk/typescript/types/type-aliases/NetworkData.md @@ -8,7 +8,7 @@ > **NetworkData**: `object` -Defined in: [types.ts:95](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L95) +Defined in: [types.ts:95](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L95) Network data diff --git a/docs/sdk/typescript/types/type-aliases/Payout.md b/docs/sdk/typescript/types/type-aliases/Payout.md new file mode 100644 index 0000000000..c7b88f127b --- /dev/null +++ b/docs/sdk/typescript/types/type-aliases/Payout.md @@ -0,0 +1,45 @@ +[**@human-protocol/sdk**](../../README.md) + +*** + +[@human-protocol/sdk](../../modules.md) / [types](../README.md) / Payout + +# Type Alias: Payout + +> **Payout**: `object` + +Defined in: [types.ts:177](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L177) + +Represents a payout from an escrow. + +## Type declaration + +### amount + +> **amount**: `bigint` + +The amount paid to the recipient. + +### createdAt + +> **createdAt**: `number` + +The timestamp when the payout was created (in UNIX format). + +### escrowAddress + +> **escrowAddress**: `string` + +The address of the escrow associated with the payout. + +### id + +> **id**: `string` + +Unique identifier of the payout. + +### recipient + +> **recipient**: `string` + +The address of the recipient who received the payout. diff --git a/docs/sdk/typescript/types/type-aliases/StorageCredentials.md b/docs/sdk/typescript/types/type-aliases/StorageCredentials.md index adea949f55..691b0b686e 100644 --- a/docs/sdk/typescript/types/type-aliases/StorageCredentials.md +++ b/docs/sdk/typescript/types/type-aliases/StorageCredentials.md @@ -8,7 +8,7 @@ > `readonly` **StorageCredentials**: `object` -Defined in: [types.ts:40](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L40) +Defined in: [types.ts:40](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L40) AWS/GCP cloud storage access data diff --git a/docs/sdk/typescript/types/type-aliases/StorageParams.md b/docs/sdk/typescript/types/type-aliases/StorageParams.md index c237594091..311839ac78 100644 --- a/docs/sdk/typescript/types/type-aliases/StorageParams.md +++ b/docs/sdk/typescript/types/type-aliases/StorageParams.md @@ -8,7 +8,7 @@ > **StorageParams**: `object` -Defined in: [types.ts:54](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L54) +Defined in: [types.ts:54](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L54) ## Type declaration diff --git a/docs/sdk/typescript/types/type-aliases/TransactionLikeWithNonce.md b/docs/sdk/typescript/types/type-aliases/TransactionLikeWithNonce.md index d329c39cb9..e5eb23e09d 100644 --- a/docs/sdk/typescript/types/type-aliases/TransactionLikeWithNonce.md +++ b/docs/sdk/typescript/types/type-aliases/TransactionLikeWithNonce.md @@ -8,7 +8,7 @@ > **TransactionLikeWithNonce**: `TransactionLike` & `object` -Defined in: [types.ts:174](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L174) +Defined in: [types.ts:200](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L200) ## Type declaration diff --git a/docs/sdk/typescript/types/type-aliases/UploadFile.md b/docs/sdk/typescript/types/type-aliases/UploadFile.md index 118d2c8051..0d3ce37b2b 100644 --- a/docs/sdk/typescript/types/type-aliases/UploadFile.md +++ b/docs/sdk/typescript/types/type-aliases/UploadFile.md @@ -8,7 +8,7 @@ > `readonly` **UploadFile**: `object` -Defined in: [types.ts:77](https://github.com/humanprotocol/human-protocol/blob/06afdec15d4185a13ccdd98fd231f6651db0e480/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L77) +Defined in: [types.ts:77](https://github.com/humanprotocol/human-protocol/blob/d770e8f228f083f5eba0523ebbdff361b3188c3d/packages/sdk/typescript/human-protocol-sdk/src/types.ts#L77) Upload file data diff --git a/packages/apps/job-launcher/server/src/modules/cron-job/cron-job.service.ts b/packages/apps/job-launcher/server/src/modules/cron-job/cron-job.service.ts index b0c6a756ed..2e972b05a2 100644 --- a/packages/apps/job-launcher/server/src/modules/cron-job/cron-job.service.ts +++ b/packages/apps/job-launcher/server/src/modules/cron-job/cron-job.service.ts @@ -457,15 +457,14 @@ export class CronJobService { let eventsBatch; do { - eventsBatch = await EscrowUtils.getStatusEvents( - network.chainId, + eventsBatch = await EscrowUtils.getStatusEvents({ + chainId: network.chainId, statuses, from, - undefined, - this.web3Service.getOperatorAddress(), - 100, + launcher: this.web3Service.getOperatorAddress(), + first: 100, skip, - ); + }); events.push(...eventsBatch); skip += 100; diff --git a/packages/sdk/python/human-protocol-sdk/example.py b/packages/sdk/python/human-protocol-sdk/example.py index 4cc935089c..0e92429f7e 100644 --- a/packages/sdk/python/human-protocol-sdk/example.py +++ b/packages/sdk/python/human-protocol-sdk/example.py @@ -1,8 +1,8 @@ import datetime -from human_protocol_sdk.constants import ChainId, Status +from human_protocol_sdk.constants import ChainId, OrderDirection, Status from human_protocol_sdk.escrow import EscrowUtils -from human_protocol_sdk.filter import EscrowFilter, StatisticsFilter +from human_protocol_sdk.filter import EscrowFilter, PayoutFilter, StatisticsFilter from human_protocol_sdk.statistics import ( StatisticsClient, HMTHoldersParam, @@ -84,6 +84,21 @@ def get_hmt_daily_data(statistics_client: StatisticsClient): ) +def get_payouts(): + filter = PayoutFilter( + chain_id=ChainId.POLYGON, + first=5, + skip=1, + order_direction=OrderDirection.ASC, + ) + + payouts = EscrowUtils.get_payouts(filter) + for payout in payouts: + print( + f"Payout ID: {payout.id}, Amount: {payout.amount}, Recipient: {payout.recipient}" + ) + + def get_escrows(): print( EscrowUtils.get_escrows( @@ -150,6 +165,7 @@ def agreement_example(): get_escrows() get_operators() + get_payouts() statistics_client = StatisticsClient(ChainId.POLYGON_AMOY) get_hmt_holders(statistics_client) diff --git a/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/escrow/escrow_utils.py b/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/escrow/escrow_utils.py index 515919dcac..aafc3132bc 100644 --- a/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/escrow/escrow_utils.py +++ b/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/escrow/escrow_utils.py @@ -32,7 +32,7 @@ from web3 import Web3 from human_protocol_sdk.constants import NETWORKS, ChainId, Status, OrderDirection -from human_protocol_sdk.filter import EscrowFilter +from human_protocol_sdk.filter import EscrowFilter, StatusEventFilter, PayoutFilter from human_protocol_sdk.utils import ( get_data_from_subgraph, ) @@ -129,6 +129,28 @@ def __init__( self.escrow_address = escrow_address +class Payout: + """ + Initializes a Payout instance. + + :param id: The id of the payout. + :param chain_id: The chain identifier where the payout occurred. + :param escrow_address: The address of the escrow that executed the payout. + :param recipient: The address of the recipient. + :param amount: The amount of the payout. + :param created_at: The time of creation of the payout. + """ + + def __init__( + self, id: str, escrow_address: str, recipient: str, amount: int, created_at: int + ): + self.id = id + self.escrow_address = escrow_address + self.recipient = recipient + self.amount = amount + self.created_at = created_at + + class EscrowUtils: """ A utility class that provides additional escrow-related functionalities. @@ -313,86 +335,38 @@ def get_escrow( ) @staticmethod - def get_status_events( - chain_id: ChainId, - statuses: Optional[List[Status]] = None, - date_from: Optional[datetime] = None, - date_to: Optional[datetime] = None, - launcher: Optional[str] = None, - first: int = 10, - skip: int = 0, - order_direction: OrderDirection = OrderDirection.DESC, - ) -> List[StatusEvent]: + def get_status_events(filter: StatusEventFilter) -> List[StatusEvent]: """ Retrieve status events for specified networks and statuses within a date range. - :param chain_id: Network to request data. - :param statuses (Optional[List[Status]]): List of statuses to filter by. - :param date_from (Optional[datetime]): Start date for the query range. - :param date_to (Optional[datetime]): End date for the query range. - :param launcher (Optional[str]): Address of the launcher to filter by. - :param first (int): Number of items per page. - :param skip (int): Page number to retrieve. - :param order_direction (OrderDirection): Order of results, "asc" or "desc". + :param filter: Object containing all the necessary parameters to filter status events. :return List[StatusEvent]: List of status events matching the query parameters. :raise EscrowClientError: If an unsupported chain ID or invalid launcher address is provided. - - :example: - .. code-block:: python - - from datetime import datetime - from human_protocol_sdk.constants import ChainId, Status - from human_protocol_sdk.escrow import EscrowUtils - - print( - EscrowUtils.get_status_events( - chain_id=ChainId.POLYGON_AMOY, - statuses=[Status.Pending, Status.Paid], - date_from=datetime(2023, 1, 1), - date_to=datetime(2023, 12, 31), - launcher="0x1234567890abcdef1234567890abcdef12345678", - first=20, - skip=0, - order_direction=OrderDirection.DESC - ) - ) """ - from human_protocol_sdk.gql.escrow import ( - get_status_query, - ) + from human_protocol_sdk.gql.escrow import get_status_query - if launcher and not Web3.is_address(launcher): + if filter.launcher and not Web3.is_address(filter.launcher): raise EscrowClientError("Invalid Address") - # If statuses are not provided, use all statuses except Launched - effective_statuses = statuses or [ - Status.Launched, - Status.Pending, - Status.Partial, - Status.Paid, - Status.Complete, - Status.Cancelled, - ] - - network = NETWORKS.get(chain_id) + network = NETWORKS.get(filter.chain_id) if not network: raise EscrowClientError("Unsupported Chain ID") - status_names = [status.name for status in effective_statuses] + status_names = [status.name for status in filter.statuses] data = get_data_from_subgraph( network, - get_status_query(date_from, date_to, launcher), + get_status_query(filter.date_from, filter.date_to, filter.launcher), { "status": status_names, - "from": int(date_from.timestamp()) if date_from else None, - "to": int(date_to.timestamp()) if date_to else None, - "launcher": launcher or None, - "first": first, - "skip": skip, - "orderDirection": order_direction.value, + "from": int(filter.date_from.timestamp()) if filter.date_from else None, + "to": int(filter.date_to.timestamp()) if filter.date_to else None, + "launcher": filter.launcher.lower() if filter.launcher else None, + "first": filter.first, + "skip": filter.skip, + "orderDirection": filter.order_direction.value, }, ) @@ -411,9 +385,71 @@ def get_status_events( timestamp=event["timestamp"], escrow_address=event["escrowAddress"], status=event["status"], - chain_id=chain_id, + chain_id=filter.chain_id, ) for event in status_events ] return events_with_chain_id + + @staticmethod + def get_payouts(filter: PayoutFilter) -> List[Payout]: + """ + Fetch payouts from the subgraph based on the provided filter. + + :param filter: Object containing all the necessary parameters to filter payouts. + + :return List[Payout]: List of payouts matching the query parameters. + + :raise EscrowClientError: If an unsupported chain ID or invalid addresses are provided. + """ + from human_protocol_sdk.gql.payout import get_payouts_query + + if filter.escrow_address and not Web3.is_address(filter.escrow_address): + raise EscrowClientError("Invalid escrow address") + + if filter.recipient and not Web3.is_address(filter.recipient): + raise EscrowClientError("Invalid recipient address") + + network = NETWORKS.get(filter.chain_id) + if not network: + raise EscrowClientError("Unsupported Chain ID") + + data = get_data_from_subgraph( + network, + get_payouts_query(filter), + { + "escrowAddress": ( + filter.escrow_address.lower() if filter.escrow_address else None + ), + "recipient": filter.recipient.lower() if filter.recipient else None, + "from": int(filter.date_from.timestamp()) if filter.date_from else None, + "to": int(filter.date_to.timestamp()) if filter.date_to else None, + "first": min(filter.first, 1000), + "skip": filter.skip, + "orderDirection": filter.order_direction.value, + }, + ) + + if ( + not data + or "data" not in data + or "payouts" not in data["data"] + or not data["data"]["payouts"] + ): + return [] + + payouts_raw = data["data"]["payouts"] + + payouts = [ + Payout( + id=payout["id"], + escrow_address=payout["escrowAddress"], + recipient=payout["recipient"], + amount=int(payout["amount"]), + created_at=int(payout["createdAt"]), + ) + for payout in payouts_raw + ] + + return payouts diff --git a/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/filter.py b/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/filter.py index 38b909a8c6..0b1cfd2adc 100644 --- a/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/filter.py +++ b/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/filter.py @@ -4,7 +4,7 @@ from typing import List, Optional -from human_protocol_sdk.constants import NETWORKS, ChainId, Status, OrderDirection +from human_protocol_sdk.constants import ChainId, Status, OrderDirection from web3 import Web3 @@ -100,18 +100,26 @@ class PayoutFilter: def __init__( self, + chain_id: ChainId, escrow_address: Optional[str] = None, recipient: Optional[str] = None, date_from: Optional[datetime] = None, date_to: Optional[datetime] = None, + first: int = 10, + skip: int = 0, + order_direction: OrderDirection = OrderDirection.DESC, ): """ - Initializes a PayoutFilter instance. - - :param escrow_address: Escrow address - :param recipient: Recipient address - :param date_from: Created from date - :param date_to: Created to date + Initializes a filter for payouts. + + :param chain_id: The chain ID where the payouts are recorded. + :param escrow_address: Optional escrow address to filter payouts. + :param recipient: Optional recipient address to filter payouts. + :param date_from: Optional start date for filtering. + :param date_to: Optional end date for filtering. + :param first: Optional number of payouts per page. Default is 10. + :param skip: Optional number of payouts to skip. Default is 0. + :param order_direction: Optional order direction. Default is DESC. """ if escrow_address and not Web3.is_address(escrow_address): @@ -125,10 +133,14 @@ def __init__( f"Invalid dates: {date_from} must be earlier than {date_to}" ) + self.chain_id = chain_id self.escrow_address = escrow_address self.recipient = recipient self.date_from = date_from self.date_to = date_to + self.first = first + self.skip = skip + self.order_direction = order_direction class TransactionFilter: @@ -251,3 +263,44 @@ def __init__( self.first = min(first, 1000) self.skip = skip self.order_direction = order_direction + + +class StatusEventFilter: + def __init__( + self, + chain_id: ChainId, + statuses: Optional[List[Status]] = None, + date_from: Optional[datetime] = None, + date_to: Optional[datetime] = None, + launcher: Optional[str] = None, + first: int = 10, + skip: int = 0, + order_direction: OrderDirection = OrderDirection.DESC, + ): + """ + Initializes a filter for status events. + + :param chain_id: The chain ID where the events are recorded. + :param statuses: Optional list of statuses to filter by. + :param date_from: Optional start date for filtering. + :param date_to: Optional end date for filtering. + :param launcher: Optional launcher address to filter by. + :param first: Optional number of events per page. Default is 10. + :param skip: Optional number of events to skip. Default is 0. + :param order_direction: Optional order direction. Default is DESC. + """ + self.chain_id = chain_id + self.statuses = statuses or [ + Status.Launched, + Status.Pending, + Status.Partial, + Status.Paid, + Status.Complete, + Status.Cancelled, + ] + self.date_from = date_from + self.date_to = date_to + self.launcher = launcher + self.first = first + self.skip = skip + self.order_direction = order_direction diff --git a/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/gql/payout.py b/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/gql/payout.py index 59db6df906..a7337d12bf 100644 --- a/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/gql/payout.py +++ b/packages/sdk/python/human-protocol-sdk/human_protocol_sdk/gql/payout.py @@ -11,13 +11,16 @@ """ -def get_payouts_query(filter: PayoutFilter): +def get_payouts_query(filter: PayoutFilter) -> str: return """ query GetPayouts( - $escrowAddress: String - $recipient: String - $from: Int - $to: Int + $escrowAddress: String, + $recipient: String, + $from: Int, + $to: Int, + $first: Int, + $skip: Int, + $orderDirection: String ) {{ payouts( where: {{ @@ -26,6 +29,10 @@ def get_payouts_query(filter: PayoutFilter): {from_clause} {to_clause} }} + orderBy: createdAt + orderDirection: $orderDirection + first: $first + skip: $skip ) {{ ...PayoutFields }} diff --git a/packages/sdk/python/human-protocol-sdk/test/human_protocol_sdk/escrow/test_escrow_utils.py b/packages/sdk/python/human-protocol-sdk/test/human_protocol_sdk/escrow/test_escrow_utils.py index 998ee706c8..a13681e2a0 100644 --- a/packages/sdk/python/human-protocol-sdk/test/human_protocol_sdk/escrow/test_escrow_utils.py +++ b/packages/sdk/python/human-protocol-sdk/test/human_protocol_sdk/escrow/test_escrow_utils.py @@ -2,7 +2,7 @@ from datetime import datetime from unittest.mock import patch -from human_protocol_sdk.constants import NETWORKS, ChainId, Status +from human_protocol_sdk.constants import NETWORKS, ChainId, Status, OrderDirection from human_protocol_sdk.gql.escrow import ( get_escrow_query, get_escrows_query, @@ -11,7 +11,12 @@ EscrowClientError, EscrowUtils, ) -from human_protocol_sdk.filter import EscrowFilter +from human_protocol_sdk.filter import ( + EscrowFilter, + FilterError, + StatusEventFilter, + PayoutFilter, +) class TestEscrowUtils(unittest.TestCase): @@ -181,15 +186,17 @@ def test_get_escrow_invalid_address_launcher(self): self.assertEqual("Invalid escrow address: invalid_address", str(cm.exception)) def test_get_status_events_unsupported_chain_id(self): + filter = StatusEventFilter(chain_id=9999) with self.assertRaises(EscrowClientError) as context: - EscrowUtils.get_status_events(9999) + EscrowUtils.get_status_events(filter) self.assertEqual(str(context.exception), "Unsupported Chain ID") def test_get_status_events_invalid_launcher(self): + filter = StatusEventFilter( + chain_id=ChainId.POLYGON_AMOY, launcher="invalid_address" + ) with self.assertRaises(EscrowClientError) as context: - EscrowUtils.get_status_events( - ChainId.POLYGON_AMOY, launcher="invalid_address" - ) + EscrowUtils.get_status_events(filter) self.assertEqual(str(context.exception), "Invalid Address") def test_get_status_events(self): @@ -208,9 +215,10 @@ def test_get_status_events(self): } } - result = EscrowUtils.get_status_events( - ChainId.POLYGON_AMOY, statuses=[Status.Pending] + filter = StatusEventFilter( + chain_id=ChainId.POLYGON_AMOY, statuses=[Status.Pending] ) + result = EscrowUtils.get_status_events(filter) self.assertEqual(len(result), 1) self.assertEqual(result[0].timestamp, 1620000000) @@ -237,12 +245,13 @@ def test_get_status_events_with_date_range(self): date_from = datetime(2021, 1, 1) date_to = datetime(2021, 12, 31) - result = EscrowUtils.get_status_events( - ChainId.POLYGON_AMOY, + filter = StatusEventFilter( + chain_id=ChainId.POLYGON_AMOY, statuses=[Status.Pending], date_from=date_from, date_to=date_to, ) + result = EscrowUtils.get_status_events(filter) self.assertEqual(len(result), 1) self.assertEqual(result[0].timestamp, 1620000000) @@ -256,9 +265,10 @@ def test_get_status_events_no_data(self): ) as mock_get_data_from_subgraph: mock_get_data_from_subgraph.return_value = {"data": {}} - result = EscrowUtils.get_status_events( - ChainId.POLYGON_AMOY, statuses=[Status.Pending] + filter = StatusEventFilter( + chain_id=ChainId.POLYGON_AMOY, statuses=[Status.Pending] ) + result = EscrowUtils.get_status_events(filter) self.assertEqual(len(result), 0) @@ -278,11 +288,12 @@ def test_get_status_events_with_launcher(self): } } - result = EscrowUtils.get_status_events( - ChainId.POLYGON_AMOY, + filter = StatusEventFilter( + chain_id=ChainId.POLYGON_AMOY, statuses=[Status.Pending], launcher="0x1234567890abcdef1234567890abcdef12345678", ) + result = EscrowUtils.get_status_events(filter) self.assertEqual(len(result), 1) self.assertEqual(result[0].timestamp, 1620000000) @@ -290,6 +301,139 @@ def test_get_status_events_with_launcher(self): self.assertEqual(result[0].status, "Pending") self.assertEqual(result[0].chain_id, ChainId.POLYGON_AMOY) + def test_get_payouts_unsupported_chain_id(self): + filter = PayoutFilter(chain_id=9999) + with self.assertRaises(EscrowClientError) as context: + EscrowUtils.get_payouts(filter) + self.assertEqual(str(context.exception), "Unsupported Chain ID") + + def test_get_payouts_invalid_escrow_address(self): + with self.assertRaises(FilterError) as context: + PayoutFilter( + chain_id=ChainId.POLYGON_AMOY, escrow_address="invalid_address" + ) + self.assertEqual(str(context.exception), "Invalid address: invalid_address") + + def test_get_payouts_invalid_recipient(self): + with self.assertRaises(FilterError) as context: + PayoutFilter(chain_id=ChainId.POLYGON_AMOY, recipient="invalid_address") + self.assertEqual(str(context.exception), "Invalid address: invalid_address") + + def test_get_payouts(self): + with patch( + "human_protocol_sdk.escrow.escrow_utils.get_data_from_subgraph" + ) as mock_get_data_from_subgraph: + mock_get_data_from_subgraph.return_value = { + "data": { + "payouts": [ + { + "id": "1", + "escrowAddress": "0x1234567890123456789012345678901234567890", + "recipient": "0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef", + "amount": "1000000000000000000", + "createdAt": "1672531200", + } + ] + } + } + + filter = PayoutFilter(chain_id=ChainId.POLYGON_AMOY) + result = EscrowUtils.get_payouts(filter) + + self.assertEqual(len(result), 1) + self.assertEqual(result[0].id, "1") + self.assertEqual( + result[0].escrow_address, "0x1234567890123456789012345678901234567890" + ) + self.assertEqual( + result[0].recipient, "0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef" + ) + self.assertEqual(result[0].amount, 1000000000000000000) + self.assertEqual(result[0].created_at, 1672531200) + + def test_get_payouts_with_filters(self): + with patch( + "human_protocol_sdk.escrow.escrow_utils.get_data_from_subgraph" + ) as mock_get_data_from_subgraph: + mock_get_data_from_subgraph.return_value = { + "data": { + "payouts": [ + { + "id": "1", + "escrowAddress": "0x1234567890123456789012345678901234567891", + "recipient": "0x1234567890123456789012345678901234567892", + "amount": "1000000000000000000", + "createdAt": "1672531200", + } + ] + } + } + + filter = PayoutFilter( + chain_id=ChainId.POLYGON_AMOY, + escrow_address="0x1234567890123456789012345678901234567891", + recipient="0x1234567890123456789012345678901234567892", + date_from=datetime(2023, 1, 1), + date_to=datetime(2023, 12, 31), + ) + result = EscrowUtils.get_payouts(filter) + + self.assertEqual(len(result), 1) + self.assertEqual(result[0].id, "1") + self.assertEqual( + result[0].escrow_address, "0x1234567890123456789012345678901234567891" + ) + self.assertEqual( + result[0].recipient, "0x1234567890123456789012345678901234567892" + ) + self.assertEqual(result[0].amount, 1000000000000000000) + self.assertEqual(result[0].created_at, 1672531200) + + def test_get_payouts_no_data(self): + with patch( + "human_protocol_sdk.escrow.escrow_utils.get_data_from_subgraph" + ) as mock_get_data_from_subgraph: + mock_get_data_from_subgraph.return_value = {"data": {"payouts": []}} + + filter = PayoutFilter(chain_id=ChainId.POLYGON_AMOY) + result = EscrowUtils.get_payouts(filter) + + self.assertEqual(len(result), 0) + + def test_get_payouts_with_pagination(self): + with patch( + "human_protocol_sdk.escrow.escrow_utils.get_data_from_subgraph" + ) as mock_get_data_from_subgraph: + mock_get_data_from_subgraph.return_value = { + "data": { + "payouts": [ + { + "id": "1", + "escrowAddress": "0x1234567890123456789012345678901234567890", + "recipient": "0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef", + "amount": "1000000000000000000", + "createdAt": "1672531200", + }, + { + "id": "2", + "escrowAddress": "0x1234567890123456789012345678901234567890", + "recipient": "0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef", + "amount": "2000000000000000000", + "createdAt": "1672617600", + }, + ] + } + } + + filter = PayoutFilter(chain_id=ChainId.POLYGON_AMOY, first=20, skip=10) + result = EscrowUtils.get_payouts(filter) + + self.assertEqual(len(result), 2) + self.assertEqual(result[0].id, "1") + self.assertEqual(result[1].id, "2") + self.assertEqual(result[0].amount, 1000000000000000000) + self.assertEqual(result[1].amount, 2000000000000000000) + if __name__ == "__main__": unittest.main(exit=True) diff --git a/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts b/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts index 97d51bdfef..46474bdf6b 100644 --- a/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts +++ b/packages/sdk/typescript/human-protocol-sdk/src/escrow.ts @@ -44,16 +44,23 @@ import { EscrowData, GET_ESCROWS_QUERY, GET_ESCROW_BY_ADDRESS_QUERY, + GET_PAYOUTS_QUERY, GET_STATUS_UPDATES_QUERY, StatusEvent, } from './graphql'; -import { IEscrowConfig, IEscrowsFilter } from './interfaces'; +import { + IEscrowConfig, + IEscrowsFilter, + IPayoutFilter, + IStatusEventFilter, +} from './interfaces'; import { EscrowCancel, EscrowStatus, EscrowWithdraw, NetworkData, TransactionLikeWithNonce, + Payout, } from './types'; import { getSubgraphUrl, @@ -1828,14 +1835,7 @@ export class EscrowUtils { * }; * ``` * - * @param {ChainId} chainId - List of network IDs to query for status events. - * @param {EscrowStatus[]} [statuses] - Optional array of statuses to query for. If not provided, queries for all statuses. - * @param {Date} [from] - Optional start date to filter events. - * @param {Date} [to] - Optional end date to filter events. - * @param {string} [launcher] - Optional launcher address to filter events. Must be a valid Ethereum address. - * @param {number} [first] - Optional number of transactions per page. Default is 10. - * @param {number} [skip] - Optional number of transactions to skip. Default is 0. - * @param {OrderDirection} [orderDirection] - Optional order of the results. Default is DESC. + * @param {IStatusEventFilter} filter Filter parameters. * @returns {Promise} - Array of status events with their corresponding statuses. * * **Code example** @@ -1846,34 +1846,38 @@ export class EscrowUtils { * (async () => { * const fromDate = new Date('2023-01-01'); * const toDate = new Date('2023-12-31'); - * const statusEvents = await EscrowUtils.getStatusEvents( - * [ChainId.POLYGON, ChainId.MAINNET], - * [EscrowStatus.Pending, EscrowStatus.Complete], - * fromDate, - * toDate - * ); + * const statusEvents = await EscrowUtils.getStatusEvents({ + * chainId: ChainId.POLYGON, + * statuses: [EscrowStatus.Pending, EscrowStatus.Complete], + * from: fromDate, + * to: toDate + * }); * console.log(statusEvents); * })(); * ``` */ - public static async getStatusEvents( - chainId: ChainId, - statuses?: EscrowStatus[], - from?: Date, - to?: Date, - launcher?: string, - first?: number, - skip?: number, - orderDirection?: OrderDirection + filter: IStatusEventFilter ): Promise { + const { + chainId, + statuses, + from, + to, + launcher, + first = 10, + skip = 0, + orderDirection = OrderDirection.DESC, + } = filter; + if (launcher && !ethers.isAddress(launcher)) { throw ErrorInvalidAddress; } - first = first !== undefined ? Math.min(first, 1000) : 10; - skip = skip || 0; - orderDirection = orderDirection || OrderDirection.DESC; + const networkData = NETWORKS[chainId]; + if (!networkData) { + throw ErrorUnsupportedChainID; + } // If statuses are not provided, use all statuses except Launched const effectiveStatuses = statuses ?? [ @@ -1885,11 +1889,6 @@ export class EscrowUtils { EscrowStatus.Cancelled, ]; - const networkData = NETWORKS[chainId]; - if (!networkData) { - throw ErrorUnsupportedChainID; - } - const statusNames = effectiveStatuses.map((status) => EscrowStatus[status]); const data = await gqlFetch<{ @@ -1902,9 +1901,9 @@ export class EscrowUtils { from: from ? getUnixTimestamp(from) : undefined, to: to ? getUnixTimestamp(to) : undefined, launcher: launcher || undefined, - orderDirection: orderDirection, - first: first, - skip: skip, + orderDirection, + first: Math.min(first, 1000), + skip, } ); @@ -1921,4 +1920,64 @@ export class EscrowUtils { return eventsWithChainId; } + + /** + * This function returns the payouts for a given set of networks. + * + * > This uses Subgraph + * + * **Input parameters** + * Fetch payouts from the subgraph. + * + * @param {IPayoutFilter} filter Filter parameters. + * @returns {Promise} List of payouts matching the filters. + * + * **Code example** + * + * ```ts + * import { ChainId, EscrowUtils } from '@human-protocol/sdk'; + * + * const payouts = await EscrowUtils.getPayouts({ + * chainId: ChainId.POLYGON, + * escrowAddress: '0x1234567890123456789012345678901234567890', + * recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + * from: new Date('2023-01-01'), + * to: new Date('2023-12-31') + * }); + * console.log(payouts); + * ``` + */ + public static async getPayouts(filter: IPayoutFilter): Promise { + const networkData = NETWORKS[filter.chainId]; + if (!networkData) { + throw ErrorUnsupportedChainID; + } + if (filter.escrowAddress && !ethers.isAddress(filter.escrowAddress)) { + throw ErrorInvalidAddress; + } + if (filter.recipient && !ethers.isAddress(filter.recipient)) { + throw ErrorInvalidAddress; + } + + const first = + filter.first !== undefined ? Math.min(filter.first, 1000) : 10; + const skip = filter.skip || 0; + const orderDirection = filter.orderDirection || OrderDirection.DESC; + + const { payouts } = await gqlFetch<{ payouts: Payout[] }>( + getSubgraphUrl(networkData), + GET_PAYOUTS_QUERY(filter), + { + escrowAddress: filter.escrowAddress?.toLowerCase(), + recipient: filter.recipient?.toLowerCase(), + from: filter.from ? getUnixTimestamp(filter.from) : undefined, + to: filter.to ? getUnixTimestamp(filter.to) : undefined, + first: Math.min(first, 1000), + skip, + orderDirection, + } + ); + + return payouts || []; + } } diff --git a/packages/sdk/typescript/human-protocol-sdk/src/graphql/queries/payout.ts b/packages/sdk/typescript/human-protocol-sdk/src/graphql/queries/payout.ts index bb134efbc1..b60df53460 100644 --- a/packages/sdk/typescript/human-protocol-sdk/src/graphql/queries/payout.ts +++ b/packages/sdk/typescript/human-protocol-sdk/src/graphql/queries/payout.ts @@ -1,5 +1,5 @@ import gql from 'graphql-tag'; -import { IPayoutFilter } from '../../interfaces'; +import { IPayoutFilter } from 'src/interfaces'; const PAYOUT_FRAGMENT = gql` fragment PayoutFields on Payout { @@ -22,9 +22,6 @@ export const GET_PAYOUTS_QUERY = (filter: IPayoutFilter) => { ${to ? `createdAt_lt: $to` : ''} } `; - const LIMIT_CLAUSE = ` - first: 1000 - `; return gql` query getPayouts( @@ -32,12 +29,16 @@ export const GET_PAYOUTS_QUERY = (filter: IPayoutFilter) => { $recipient: String $from: Int $to: Int + $first: Int + $skip: Int + $orderDirection: String ) { payouts( ${WHERE_CLAUSE} orderBy: createdAt, - orderDirection: desc, - ${LIMIT_CLAUSE} + orderDirection: $orderDirection, + first: $first, + skip: $skip ) { ...PayoutFields } diff --git a/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts b/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts index 33cd772662..92c2649d84 100644 --- a/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts +++ b/packages/sdk/typescript/human-protocol-sdk/src/interfaces.ts @@ -104,10 +104,14 @@ export interface IHMTHoldersParams extends IPagination { } export interface IPayoutFilter { + chainId: ChainId; escrowAddress?: string; recipient?: string; from?: Date; to?: Date; + first?: number; + skip?: number; + orderDirection?: OrderDirection; } export interface IKVStore { @@ -161,3 +165,14 @@ export interface StakerInfo { lockedUntil: bigint; withdrawableAmount: bigint; } + +export interface IStatusEventFilter { + chainId: ChainId; + statuses?: EscrowStatus[]; + from?: Date; + to?: Date; + launcher?: string; + first?: number; + skip?: number; + orderDirection?: OrderDirection; +} diff --git a/packages/sdk/typescript/human-protocol-sdk/src/types.ts b/packages/sdk/typescript/human-protocol-sdk/src/types.ts index f16c230091..17ac94cd92 100644 --- a/packages/sdk/typescript/human-protocol-sdk/src/types.ts +++ b/packages/sdk/typescript/human-protocol-sdk/src/types.ts @@ -171,4 +171,30 @@ export type EscrowWithdraw = { amountWithdrawn: bigint; }; +/** + * Represents a payout from an escrow. + */ +export type Payout = { + /** + * Unique identifier of the payout. + */ + id: string; + /** + * The address of the escrow associated with the payout. + */ + escrowAddress: string; + /** + * The address of the recipient who received the payout. + */ + recipient: string; + /** + * The amount paid to the recipient. + */ + amount: bigint; + /** + * The timestamp when the payout was created (in UNIX format). + */ + createdAt: number; +}; + export type TransactionLikeWithNonce = TransactionLike & { nonce: number }; diff --git a/packages/sdk/typescript/human-protocol-sdk/test/escrow.test.ts b/packages/sdk/typescript/human-protocol-sdk/test/escrow.test.ts index f2d3419e85..b9d69c0a01 100644 --- a/packages/sdk/typescript/human-protocol-sdk/test/escrow.test.ts +++ b/packages/sdk/typescript/human-protocol-sdk/test/escrow.test.ts @@ -35,7 +35,11 @@ import { InvalidEthereumAddressError, } from '../src/error'; import { EscrowClient, EscrowUtils } from '../src/escrow'; -import { GET_ESCROWS_QUERY, GET_ESCROW_BY_ADDRESS_QUERY } from '../src/graphql'; +import { + GET_ESCROWS_QUERY, + GET_ESCROW_BY_ADDRESS_QUERY, + GET_PAYOUTS_QUERY, +} from '../src/graphql'; import { EscrowStatus } from '../src/types'; import { DEFAULT_GAS_PAYER_PRIVKEY, @@ -2917,13 +2921,10 @@ describe('EscrowUtils', () => { test('should throw an error if launcher address is invalid', async () => { await expect( - EscrowUtils.getStatusEvents( - ChainId.POLYGON_AMOY, - undefined, - undefined, - undefined, - 'invalid_address' - ) + EscrowUtils.getStatusEvents({ + chainId: ChainId.POLYGON_AMOY, + launcher: 'invalid_address', + }) ).rejects.toThrow(ErrorInvalidAddress); }); @@ -2947,7 +2948,9 @@ describe('EscrowUtils', () => { .spyOn(gqlFetch, 'default') .mockResolvedValueOnce({ escrowStatusEvents: pendingEvents }); - const result = await EscrowUtils.getStatusEvents(ChainId.LOCALHOST); + const result = await EscrowUtils.getStatusEvents({ + chainId: ChainId.LOCALHOST, + }); expect(result).toEqual(pendingEvents); expect(gqlFetchSpy).toHaveBeenCalled(); }); @@ -2975,12 +2978,11 @@ describe('EscrowUtils', () => { .spyOn(gqlFetch, 'default') .mockResolvedValueOnce({ escrowStatusEvents: pendingEvents }); - const result = await EscrowUtils.getStatusEvents( - ChainId.POLYGON_AMOY, - undefined, - fromDate, - toDate - ); + const result = await EscrowUtils.getStatusEvents({ + chainId: ChainId.POLYGON_AMOY, + from: fromDate, + to: toDate, + }); expect(result).toEqual(pendingEvents); expect(gqlFetchSpy).toHaveBeenCalled(); @@ -3009,12 +3011,12 @@ describe('EscrowUtils', () => { .spyOn(gqlFetch, 'default') .mockResolvedValueOnce({ escrowStatusEvents: partialEvents }); - const result = await EscrowUtils.getStatusEvents( - ChainId.POLYGON_AMOY, - [EscrowStatus.Partial], - fromDate, - toDate - ); + const result = await EscrowUtils.getStatusEvents({ + chainId: ChainId.POLYGON_AMOY, + statuses: [EscrowStatus.Partial], + from: fromDate, + to: toDate, + }); expect(result).toEqual(partialEvents); expect(gqlFetchSpy).toHaveBeenCalled(); @@ -3043,15 +3045,235 @@ describe('EscrowUtils', () => { .spyOn(gqlFetch, 'default') .mockResolvedValueOnce({ escrowStatusEvents: pendingEvents }); - const result = await EscrowUtils.getStatusEvents( - ChainId.POLYGON_AMOY, - undefined, - fromDate, - toDate - ); + const result = await EscrowUtils.getStatusEvents({ + chainId: ChainId.POLYGON_AMOY, + from: fromDate, + to: toDate, + }); expect(result).toEqual(pendingEvents); expect(gqlFetchSpy).toHaveBeenCalled(); }); }); + + describe('getPayouts', () => { + afterEach(() => { + vi.clearAllMocks(); + }); + + test('should throw an error if chainId is invalid', async () => { + await expect( + EscrowUtils.getPayouts({ chainId: 123 } as any) + ).rejects.toThrow(ErrorUnsupportedChainID); + }); + + test('should throw an error if escrowAddress is an invalid address', async () => { + const filter = { + chainId: ChainId.POLYGON_AMOY, + escrowAddress: 'invalid_address', + }; + + await expect(EscrowUtils.getPayouts(filter)).rejects.toThrow( + ErrorInvalidAddress + ); + }); + + test('should throw an error if recipient is an invalid address', async () => { + const filter = { + chainId: ChainId.POLYGON_AMOY, + recipient: 'invalid_address', + }; + + await expect(EscrowUtils.getPayouts(filter)).rejects.toThrow( + ErrorInvalidAddress + ); + }); + + test('should successfully getPayouts', async () => { + const payouts = [ + { + id: '1', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '1000000000000000000', + createdAt: '1672531200', + }, + { + id: '2', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '2000000000000000000', + createdAt: '1672617600', + }, + ]; + + const gqlFetchSpy = vi + .spyOn(gqlFetch, 'default') + .mockResolvedValue({ payouts }); + + const filter = { + chainId: ChainId.POLYGON_AMOY, + }; + + const result = await EscrowUtils.getPayouts(filter); + expect(result).toEqual(payouts); + expect(gqlFetchSpy).toHaveBeenCalledWith( + 'https://api.studio.thegraph.com/query/74256/amoy/version/latest', + GET_PAYOUTS_QUERY(filter), + { + escrowAddress: undefined, + recipient: undefined, + from: undefined, + to: undefined, + first: 10, + skip: 0, + orderDirection: OrderDirection.DESC, + } + ); + }); + + test('should successfully getPayouts with filters', async () => { + const payouts = [ + { + id: '1', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '1000000000000000000', + createdAt: '1672531200', + }, + ]; + + const gqlFetchSpy = vi + .spyOn(gqlFetch, 'default') + .mockResolvedValue({ payouts }); + + const filter = { + chainId: ChainId.POLYGON_AMOY, + escrowAddress: ethers.ZeroAddress, + recipient: ethers.ZeroAddress, + from: new Date('2023-01-01'), + to: new Date('2023-01-02'), + }; + + const result = await EscrowUtils.getPayouts(filter); + expect(result).toEqual(payouts); + expect(gqlFetchSpy).toHaveBeenCalledWith( + 'https://api.studio.thegraph.com/query/74256/amoy/version/latest', + GET_PAYOUTS_QUERY(filter), + { + escrowAddress: filter.escrowAddress.toLowerCase(), + recipient: filter.recipient.toLowerCase(), + from: Math.floor(filter.from.getTime() / 1000), + to: Math.floor(filter.to.getTime() / 1000), + first: 10, + skip: 0, + orderDirection: OrderDirection.DESC, + } + ); + }); + + test('should successfully getPayouts with pagination', async () => { + const payouts = [ + { + id: '1', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '1000000000000000000', + createdAt: '1672531200', + }, + { + id: '2', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '2000000000000000000', + createdAt: '1672617600', + }, + ]; + + const gqlFetchSpy = vi + .spyOn(gqlFetch, 'default') + .mockResolvedValue({ payouts }); + + const filter = { + chainId: ChainId.POLYGON_AMOY, + first: 20, + skip: 10, + }; + + const result = await EscrowUtils.getPayouts(filter); + expect(result).toEqual(payouts); + expect(gqlFetchSpy).toHaveBeenCalledWith( + 'https://api.studio.thegraph.com/query/74256/amoy/version/latest', + GET_PAYOUTS_QUERY(filter), + { + escrowAddress: undefined, + recipient: undefined, + from: undefined, + to: undefined, + first: 20, + skip: 10, + orderDirection: OrderDirection.DESC, + } + ); + }); + + test('should successfully getPayouts with pagination over limits', async () => { + const payouts = [ + { + id: '1', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '1000000000000000000', + createdAt: '1672531200', + }, + { + id: '2', + escrowAddress: '0x1234567890123456789012345678901234567890', + recipient: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdef', + amount: '2000000000000000000', + createdAt: '1672617600', + }, + ]; + + const gqlFetchSpy = vi + .spyOn(gqlFetch, 'default') + .mockResolvedValue({ payouts }); + + const filter = { + chainId: ChainId.POLYGON_AMOY, + first: 20000, + skip: 10, + }; + + const result = await EscrowUtils.getPayouts(filter); + expect(result).toEqual(payouts); + expect(gqlFetchSpy).toHaveBeenCalledWith( + 'https://api.studio.thegraph.com/query/74256/amoy/version/latest', + GET_PAYOUTS_QUERY(filter), + { + escrowAddress: undefined, + recipient: undefined, + from: undefined, + to: undefined, + first: 1000, + skip: 10, + orderDirection: OrderDirection.DESC, + } + ); + }); + + test('should return an empty array if no payouts are found', async () => { + const gqlFetchSpy = vi + .spyOn(gqlFetch, 'default') + .mockResolvedValue({ payouts: [] }); + + const filter = { + chainId: ChainId.POLYGON_AMOY, + }; + + const result = await EscrowUtils.getPayouts(filter); + expect(result).toEqual([]); + expect(gqlFetchSpy).toHaveBeenCalled(); + }); + }); }); diff --git a/packages/sdk/typescript/human-protocol-sdk/test/transaction.test.ts b/packages/sdk/typescript/human-protocol-sdk/test/transaction.test.ts index 3f32f81200..3af3444d6b 100644 --- a/packages/sdk/typescript/human-protocol-sdk/test/transaction.test.ts +++ b/packages/sdk/typescript/human-protocol-sdk/test/transaction.test.ts @@ -6,7 +6,7 @@ import { NETWORKS } from '../src/constants'; import { ChainId, OrderDirection } from '../src/enums'; import { ErrorCannotUseDateAndBlockSimultaneously, - ErrorInvalidHahsProvided, + ErrorInvalidHashProvided, } from '../src/error'; import { GET_TRANSACTION_QUERY } from '../src/graphql/queries/transaction'; import { ITransaction, ITransactionsFilter } from '../src/interfaces'; @@ -64,7 +64,7 @@ describe('TransactionUtils', () => { test('should throw an error for an invalid transaction hash', async () => { await expect( TransactionUtils.getTransaction(ChainId.LOCALHOST, invalidHash) - ).rejects.toThrow(ErrorInvalidHahsProvided); + ).rejects.toThrow(ErrorInvalidHashProvided); }); test('should throw an error if the gql fetch fails', async () => {