@stacks/blockchain-api-client 7.2.0-beta.3 → 7.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/lib/generated/apis/FaucetsApi.js.map +1 -1
  2. package/lib/generated/apis/index.d.ts +0 -1
  3. package/lib/generated/apis/index.js +0 -1
  4. package/lib/generated/apis/index.js.map +1 -1
  5. package/lib/generated/models/AddressNonces.d.ts +0 -6
  6. package/lib/generated/models/AddressNonces.js +0 -3
  7. package/lib/generated/models/AddressNonces.js.map +1 -1
  8. package/lib/generated/models/ServerStatusResponse.d.ts +6 -0
  9. package/lib/generated/models/ServerStatusResponse.js +2 -0
  10. package/lib/generated/models/ServerStatusResponse.js.map +1 -1
  11. package/lib/generated/models/index.d.ts +0 -3
  12. package/lib/generated/models/index.js +0 -3
  13. package/lib/generated/models/index.js.map +1 -1
  14. package/lib/index.umd.js +18 -192
  15. package/lib/index.umd.js.map +1 -1
  16. package/package.json +1 -1
  17. package/src/generated/.openapi-generator/FILES +0 -4
  18. package/src/generated/apis/FaucetsApi.ts +0 -3
  19. package/src/generated/apis/index.ts +0 -1
  20. package/src/generated/models/AddressNonces.ts +0 -8
  21. package/src/generated/models/ServerStatusResponse.ts +8 -0
  22. package/src/generated/models/index.ts +0 -3
  23. package/lib/generated/apis/StackingApi.d.ts +0 -61
  24. package/lib/generated/apis/StackingApi.js +0 -63
  25. package/lib/generated/apis/StackingApi.js.map +0 -1
  26. package/lib/generated/models/InlineResponse403.d.ts +0 -33
  27. package/lib/generated/models/InlineResponse403.js +0 -45
  28. package/lib/generated/models/InlineResponse403.js.map +0 -1
  29. package/lib/generated/models/PoolDelegation.d.ts +0 -57
  30. package/lib/generated/models/PoolDelegation.js +0 -53
  31. package/lib/generated/models/PoolDelegation.js.map +0 -1
  32. package/lib/generated/models/PoolDelegationsResponse.d.ts +0 -46
  33. package/lib/generated/models/PoolDelegationsResponse.js +0 -49
  34. package/lib/generated/models/PoolDelegationsResponse.js.map +0 -1
  35. package/src/generated/apis/StackingApi.ts +0 -113
  36. package/src/generated/models/InlineResponse403.ts +0 -64
  37. package/src/generated/models/PoolDelegation.ts +0 -96
  38. package/src/generated/models/PoolDelegationsResponse.ts +0 -87
@@ -1,113 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * Stacks Blockchain API
5
- * Welcome to the API reference overview for the <a href=\"https://docs.hiro.so/get-started/stacks-blockchain-api\">Stacks Blockchain API</a>. <a href=\"https://hirosystems.github.io/stacks-blockchain-api/collection.json\" download=\"stacks-api-collection.json\">Download Postman collection</a>
6
- *
7
- * The version of the OpenAPI document: STACKS_API_VERSION
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
-
16
- import * as runtime from '../runtime';
17
- import {
18
- PoolDelegationsResponse,
19
- PoolDelegationsResponseFromJSON,
20
- PoolDelegationsResponseToJSON,
21
- } from '../models';
22
-
23
- export interface GetPoolDelegationsRequest {
24
- poolPrincipal: string;
25
- afterBlock?: number;
26
- unanchored?: boolean;
27
- limit?: number;
28
- offset?: number;
29
- }
30
-
31
- /**
32
- * StackingApi - interface
33
- *
34
- * @export
35
- * @interface StackingApiInterface
36
- */
37
- export interface StackingApiInterface {
38
- /**
39
- * Retrieves the list of stacking pool members for a given delegator principal.
40
- * @summary Stacking pool members
41
- * @param {string} poolPrincipal Address principal of the stacking pool delegator
42
- * @param {number} [afterBlock] If specified, only delegation events after the given block will be included
43
- * @param {boolean} [unanchored] whether or not to include Stackers from unconfirmed transactions
44
- * @param {number} [limit] number of items to return
45
- * @param {number} [offset] number of items to skip
46
- * @param {*} [options] Override http request option.
47
- * @throws {RequiredError}
48
- * @memberof StackingApiInterface
49
- */
50
- getPoolDelegationsRaw(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<PoolDelegationsResponse>>;
51
-
52
- /**
53
- * Retrieves the list of stacking pool members for a given delegator principal.
54
- * Stacking pool members
55
- */
56
- getPoolDelegations(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise<PoolDelegationsResponse>;
57
-
58
- }
59
-
60
- /**
61
- *
62
- */
63
- export class StackingApi extends runtime.BaseAPI implements StackingApiInterface {
64
-
65
- /**
66
- * Retrieves the list of stacking pool members for a given delegator principal.
67
- * Stacking pool members
68
- */
69
- async getPoolDelegationsRaw(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<PoolDelegationsResponse>> {
70
- if (requestParameters.poolPrincipal === null || requestParameters.poolPrincipal === undefined) {
71
- throw new runtime.RequiredError('poolPrincipal','Required parameter requestParameters.poolPrincipal was null or undefined when calling getPoolDelegations.');
72
- }
73
-
74
- const queryParameters: any = {};
75
-
76
- if (requestParameters.afterBlock !== undefined) {
77
- queryParameters['after_block'] = requestParameters.afterBlock;
78
- }
79
-
80
- if (requestParameters.unanchored !== undefined) {
81
- queryParameters['unanchored'] = requestParameters.unanchored;
82
- }
83
-
84
- if (requestParameters.limit !== undefined) {
85
- queryParameters['limit'] = requestParameters.limit;
86
- }
87
-
88
- if (requestParameters.offset !== undefined) {
89
- queryParameters['offset'] = requestParameters.offset;
90
- }
91
-
92
- const headerParameters: runtime.HTTPHeaders = {};
93
-
94
- const response = await this.request({
95
- path: `/extended/beta/stacking/{pool_principal}/delegations`.replace(`{${"pool_principal"}}`, encodeURIComponent(String(requestParameters.poolPrincipal))),
96
- method: 'GET',
97
- headers: headerParameters,
98
- query: queryParameters,
99
- }, initOverrides);
100
-
101
- return new runtime.JSONApiResponse(response, (jsonValue) => PoolDelegationsResponseFromJSON(jsonValue));
102
- }
103
-
104
- /**
105
- * Retrieves the list of stacking pool members for a given delegator principal.
106
- * Stacking pool members
107
- */
108
- async getPoolDelegations(requestParameters: GetPoolDelegationsRequest, initOverrides?: RequestInit): Promise<PoolDelegationsResponse> {
109
- const response = await this.getPoolDelegationsRaw(requestParameters, initOverrides);
110
- return await response.value();
111
- }
112
-
113
- }
@@ -1,64 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * Stacks Blockchain API
5
- * Welcome to the API reference overview for the <a href=\"https://docs.hiro.so/get-started/stacks-blockchain-api\">Stacks Blockchain API</a>. <a href=\"https://hirosystems.github.io/stacks-blockchain-api/collection.json\" download=\"stacks-api-collection.json\">Download Postman collection</a>
6
- *
7
- * The version of the OpenAPI document: STACKS_API_VERSION
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
- import { exists, mapValues } from '../runtime';
16
- /**
17
- *
18
- * @export
19
- * @interface InlineResponse403
20
- */
21
- export interface InlineResponse403 {
22
- /**
23
- *
24
- * @type {string}
25
- * @memberof InlineResponse403
26
- */
27
- error?: string;
28
- /**
29
- *
30
- * @type {boolean}
31
- * @memberof InlineResponse403
32
- */
33
- success?: boolean;
34
- }
35
-
36
- export function InlineResponse403FromJSON(json: any): InlineResponse403 {
37
- return InlineResponse403FromJSONTyped(json, false);
38
- }
39
-
40
- export function InlineResponse403FromJSONTyped(json: any, ignoreDiscriminator: boolean): InlineResponse403 {
41
- if ((json === undefined) || (json === null)) {
42
- return json;
43
- }
44
- return {
45
-
46
- 'error': !exists(json, 'error') ? undefined : json['error'],
47
- 'success': !exists(json, 'success') ? undefined : json['success'],
48
- };
49
- }
50
-
51
- export function InlineResponse403ToJSON(value?: InlineResponse403 | null): any {
52
- if (value === undefined) {
53
- return undefined;
54
- }
55
- if (value === null) {
56
- return null;
57
- }
58
- return {
59
-
60
- 'error': value.error,
61
- 'success': value.success,
62
- };
63
- }
64
-
@@ -1,96 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * Stacks Blockchain API
5
- * Welcome to the API reference overview for the <a href=\"https://docs.hiro.so/get-started/stacks-blockchain-api\">Stacks Blockchain API</a>. <a href=\"https://hirosystems.github.io/stacks-blockchain-api/collection.json\" download=\"stacks-api-collection.json\">Download Postman collection</a>
6
- *
7
- * The version of the OpenAPI document: STACKS_API_VERSION
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
- import { exists, mapValues } from '../runtime';
16
- /**
17
- *
18
- * @export
19
- * @interface PoolDelegation
20
- */
21
- export interface PoolDelegation {
22
- /**
23
- * The principal of the pool member that issued the delegation
24
- * @type {string}
25
- * @memberof PoolDelegation
26
- */
27
- stacker: string;
28
- /**
29
- * The pox-addr value specified by the stacker in the delegation operation
30
- * @type {string}
31
- * @memberof PoolDelegation
32
- */
33
- pox_addr?: string;
34
- /**
35
- * The amount of uSTX delegated by the stacker
36
- * @type {string}
37
- * @memberof PoolDelegation
38
- */
39
- amount_ustx: string;
40
- /**
41
- * The optional burnchain block unlock height that the stacker may have specified
42
- * @type {number}
43
- * @memberof PoolDelegation
44
- */
45
- burn_block_unlock_height?: number;
46
- /**
47
- * The block height at which the stacker delegation transaction was mined at
48
- * @type {number}
49
- * @memberof PoolDelegation
50
- */
51
- block_height: number;
52
- /**
53
- * The tx_id of the stacker delegation operation
54
- * @type {string}
55
- * @memberof PoolDelegation
56
- */
57
- tx_id: string;
58
- }
59
-
60
- export function PoolDelegationFromJSON(json: any): PoolDelegation {
61
- return PoolDelegationFromJSONTyped(json, false);
62
- }
63
-
64
- export function PoolDelegationFromJSONTyped(json: any, ignoreDiscriminator: boolean): PoolDelegation {
65
- if ((json === undefined) || (json === null)) {
66
- return json;
67
- }
68
- return {
69
-
70
- 'stacker': json['stacker'],
71
- 'pox_addr': !exists(json, 'pox_addr') ? undefined : json['pox_addr'],
72
- 'amount_ustx': json['amount_ustx'],
73
- 'burn_block_unlock_height': !exists(json, 'burn_block_unlock_height') ? undefined : json['burn_block_unlock_height'],
74
- 'block_height': json['block_height'],
75
- 'tx_id': json['tx_id'],
76
- };
77
- }
78
-
79
- export function PoolDelegationToJSON(value?: PoolDelegation | null): any {
80
- if (value === undefined) {
81
- return undefined;
82
- }
83
- if (value === null) {
84
- return null;
85
- }
86
- return {
87
-
88
- 'stacker': value.stacker,
89
- 'pox_addr': value.pox_addr,
90
- 'amount_ustx': value.amount_ustx,
91
- 'burn_block_unlock_height': value.burn_block_unlock_height,
92
- 'block_height': value.block_height,
93
- 'tx_id': value.tx_id,
94
- };
95
- }
96
-
@@ -1,87 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * Stacks Blockchain API
5
- * Welcome to the API reference overview for the <a href=\"https://docs.hiro.so/get-started/stacks-blockchain-api\">Stacks Blockchain API</a>. <a href=\"https://hirosystems.github.io/stacks-blockchain-api/collection.json\" download=\"stacks-api-collection.json\">Download Postman collection</a>
6
- *
7
- * The version of the OpenAPI document: STACKS_API_VERSION
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
- import { exists, mapValues } from '../runtime';
16
- import {
17
- PoolDelegation,
18
- PoolDelegationFromJSON,
19
- PoolDelegationFromJSONTyped,
20
- PoolDelegationToJSON,
21
- } from './';
22
-
23
- /**
24
- * GET request that returns stacking pool member details for a given pool (delegator) principal
25
- * @export
26
- * @interface PoolDelegationsResponse
27
- */
28
- export interface PoolDelegationsResponse {
29
- /**
30
- * The number of Stackers to return
31
- * @type {number}
32
- * @memberof PoolDelegationsResponse
33
- */
34
- limit: number;
35
- /**
36
- * The number to Stackers to skip (starting at `0`)
37
- * @type {number}
38
- * @memberof PoolDelegationsResponse
39
- */
40
- offset: number;
41
- /**
42
- * The total number of Stackers
43
- * @type {number}
44
- * @memberof PoolDelegationsResponse
45
- */
46
- total: number;
47
- /**
48
- *
49
- * @type {Array<PoolDelegation>}
50
- * @memberof PoolDelegationsResponse
51
- */
52
- results: Array<PoolDelegation>;
53
- }
54
-
55
- export function PoolDelegationsResponseFromJSON(json: any): PoolDelegationsResponse {
56
- return PoolDelegationsResponseFromJSONTyped(json, false);
57
- }
58
-
59
- export function PoolDelegationsResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): PoolDelegationsResponse {
60
- if ((json === undefined) || (json === null)) {
61
- return json;
62
- }
63
- return {
64
-
65
- 'limit': json['limit'],
66
- 'offset': json['offset'],
67
- 'total': json['total'],
68
- 'results': ((json['results'] as Array<any>).map(PoolDelegationFromJSON)),
69
- };
70
- }
71
-
72
- export function PoolDelegationsResponseToJSON(value?: PoolDelegationsResponse | null): any {
73
- if (value === undefined) {
74
- return undefined;
75
- }
76
- if (value === null) {
77
- return null;
78
- }
79
- return {
80
-
81
- 'limit': value.limit,
82
- 'offset': value.offset,
83
- 'total': value.total,
84
- 'results': ((value.results as Array<any>).map(PoolDelegationToJSON)),
85
- };
86
- }
87
-