Skip to content

Commit da23d8c

Browse files
authored
feat: Rpc improvements (#242)
* feat: rebuild client and add examples for networks api * chore: improvements * chore: regenerate client with latest api spec
1 parent b53c501 commit da23d8c

File tree

297 files changed

+5268
-533
lines changed

Some content is hidden

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

297 files changed

+5268
-533
lines changed

docs/.openapi-generator/FILES

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
Apis/HealthApi.md
22
Apis/MetricsApi.md
3+
Apis/NetworksApi.md
34
Apis/NotificationsApi.md
45
Apis/PluginsApi.md
56
Apis/RelayersApi.md
@@ -8,10 +9,16 @@ Models/ApiResponse_BalanceResponse.md
89
Models/ApiResponse_BalanceResponse_data.md
910
Models/ApiResponse_DeletePendingTransactionsResponse.md
1011
Models/ApiResponse_DeletePendingTransactionsResponse_data.md
12+
Models/ApiResponse_NetworkResponse.md
13+
Models/ApiResponse_NetworkResponse_data.md
1114
Models/ApiResponse_NotificationResponse.md
1215
Models/ApiResponse_NotificationResponse_data.md
16+
Models/ApiResponse_PaginatedResult_PluginModel.md
17+
Models/ApiResponse_PaginatedResult_PluginModel_data.md
18+
Models/ApiResponse_PaginatedResult_PluginModel_data_items_inner.md
1319
Models/ApiResponse_PluginHandlerError.md
1420
Models/ApiResponse_PluginHandlerError_data.md
21+
Models/ApiResponse_PluginModel.md
1522
Models/ApiResponse_RelayerResponse.md
1623
Models/ApiResponse_RelayerResponse_data.md
1724
Models/ApiResponse_RelayerStatus.md
@@ -33,6 +40,7 @@ Models/ApiResponse_String.md
3340
Models/ApiResponse_TransactionResponse.md
3441
Models/ApiResponse_TransactionResponse_data.md
3542
Models/ApiResponse_Value.md
43+
Models/ApiResponse_Vec_NetworkResponse.md
3644
Models/ApiResponse_Vec_NotificationResponse.md
3745
Models/ApiResponse_Vec_RelayerResponse.md
3846
Models/ApiResponse_Vec_SignerResponse.md
@@ -49,6 +57,8 @@ Models/AuthSpec_oneOf_3.md
4957
Models/AwsKmsSignerRequestConfig.md
5058
Models/BalanceResponse.md
5159
Models/CdpSignerRequestConfig.md
60+
Models/ComponentStatus.md
61+
Models/Components.md
5262
Models/ContractSource.md
5363
Models/ContractSource_oneOf.md
5464
Models/ContractSource_oneOf_1.md
@@ -85,13 +95,15 @@ Models/JupiterSwapOptions.md
8595
Models/LocalSignerRequestConfig.md
8696
Models/LogEntry.md
8797
Models/LogLevel.md
98+
Models/MaskedRpcConfig.md
8899
Models/MemoSpec.md
89100
Models/MemoSpec_oneOf.md
90101
Models/MemoSpec_oneOf_1.md
91102
Models/MemoSpec_oneOf_2.md
92103
Models/MemoSpec_oneOf_3.md
93104
Models/MemoSpec_oneOf_4.md
94105
Models/NetworkPolicyResponse.md
106+
Models/NetworkResponse.md
95107
Models/NetworkRpcRequest.md
96108
Models/NetworkRpcResult.md
97109
Models/NetworkTransactionRequest.md
@@ -107,7 +119,13 @@ Models/OperationSpec_oneOf_3.md
107119
Models/PaginationMeta.md
108120
Models/PluginCallRequest.md
109121
Models/PluginHandlerError.md
122+
Models/PluginHealth.md
110123
Models/PluginMetadata.md
124+
Models/PluginModel.md
125+
Models/PoolStatus.md
126+
Models/QueueHealth.md
127+
Models/ReadinessResponse.md
128+
Models/RedisHealth.md
111129
Models/RelayerEvmPolicy.md
112130
Models/RelayerNetworkPolicy.md
113131
Models/RelayerNetworkPolicyResponse.md
@@ -122,6 +140,7 @@ Models/RelayerStatus.md
122140
Models/RelayerStellarPolicy.md
123141
Models/RelayerStellarSwapConfig.md
124142
Models/RpcConfig.md
143+
Models/RpcUrlEntry.md
125144
Models/SignAndSendTransactionRequestParams.md
126145
Models/SignAndSendTransactionResult.md
127146
Models/SignDataRequest.md
@@ -206,11 +225,14 @@ Models/StellarTokenKind_oneOf_classic.md
206225
Models/StellarTokenMetadata.md
207226
Models/StellarTransactionRequest.md
208227
Models/StellarTransactionResponse.md
228+
Models/SystemHealth.md
209229
Models/TransactionResponse.md
210230
Models/TransactionStatus.md
211231
Models/TransferTransactionRequestParams.md
212232
Models/TransferTransactionResult.md
213233
Models/TurnkeySignerRequestConfig.md
234+
Models/UpdateNetworkRequest.md
235+
Models/UpdatePluginRequest.md
214236
Models/UpdateRelayerRequest.md
215237
Models/VaultSignerRequestConfig.md
216238
Models/VaultTransitSignerRequestConfig.md

docs/Apis/HealthApi.md

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ All URIs are relative to *http://localhost*
44

55
| Method | HTTP request | Description |
66
|------------- | ------------- | -------------|
7-
| [**health**](HealthApi.md#health) | **GET** /v1/health | Health routes implementation |
7+
| [**health**](HealthApi.md#health) | **GET** /api/v1/health | Health routes implementation |
8+
| [**readiness**](HealthApi.md#readiness) | **GET** /api/v1/ready | Readiness endpoint that checks system resources, Redis, Queue, and plugins. |
89

910

1011
<a name="health"></a>
@@ -13,7 +14,7 @@ All URIs are relative to *http://localhost*
1314
1415
Health routes implementation
1516

16-
Note: OpenAPI documentation for these endpoints can be found in the &#x60;openapi.rs&#x60; file Handles the &#x60;/health&#x60; endpoint. Returns an &#x60;HttpResponse&#x60; with a status of &#x60;200 OK&#x60; and a body of &#x60;\&quot;OK\&quot;&#x60;.
17+
Note: OpenAPI documentation for these endpoints can be found in the &#x60;openapi.rs&#x60; file Handles the &#x60;/health&#x60; endpoint. Returns an &#x60;HttpResponse&#x60; with a status of &#x60;200 OK&#x60; and a body of &#x60;\&quot;OK\&quot;&#x60;. This endpoint is used for liveness probes in container orchestration platforms.
1718

1819
### Parameters
1920
This endpoint does not need any parameter.
@@ -31,3 +32,27 @@ No authorization required
3132
- **Content-Type**: Not defined
3233
- **Accept**: text/plain
3334

35+
<a name="readiness"></a>
36+
# **readiness**
37+
> ReadinessResponse readiness()
38+
39+
Readiness endpoint that checks system resources, Redis, Queue, and plugins.
40+
41+
Returns 200 OK if the service is ready to accept traffic, or 503 Service Unavailable if not. This endpoint is used for readiness probes in container orchestration platforms like AWS ECS or Kubernetes. ## Health Check Components - **System**: File descriptor usage, CLOSE_WAIT socket count - **Redis**: Primary and reader pool connectivity - **Queue**: Queue&#39;s Redis connections (separate from app&#39;s Redis) - **Plugins**: Plugin pool health, circuit breaker state, and connection metrics (if enabled) ## Status Levels - &#x60;healthy&#x60;: All components operational - &#x60;degraded&#x60;: Some components degraded but service can function (e.g., reader pool down) - &#x60;unhealthy&#x60;: Critical components failed, service unavailable ## Plugin Connection Metrics When plugins are enabled, the following connection metrics are exposed: - &#x60;shared_socket_available_slots&#x60;: Number of additional concurrent plugin executions that can start - &#x60;shared_socket_active_connections&#x60;: Current number of active plugin execution connections - &#x60;shared_socket_registered_executions&#x60;: Number of plugin executions currently registered (awaiting response) - &#x60;connection_pool_available_slots&#x60;: Available connections to the pool server - &#x60;connection_pool_active_connections&#x60;: Active connections to the pool server These metrics help diagnose connection pool exhaustion and plugin capacity issues. ## Caching Health check results are cached for 10 seconds to prevent excessive load from frequent health checks. Multiple requests within the TTL return the same cached response.
42+
43+
### Parameters
44+
This endpoint does not need any parameter.
45+
46+
### Return type
47+
48+
[**ReadinessResponse**](../Models/ReadinessResponse.md)
49+
50+
### Authorization
51+
52+
No authorization required
53+
54+
### HTTP request headers
55+
56+
- **Content-Type**: Not defined
57+
- **Accept**: application/json
58+

docs/Apis/NetworksApi.md

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
# NetworksApi
2+
3+
All URIs are relative to *http://localhost*
4+
5+
| Method | HTTP request | Description |
6+
|------------- | ------------- | -------------|
7+
| [**getNetwork**](NetworksApi.md#getNetwork) | **GET** /api/v1/networks/{network_id} | Retrieves details of a specific network by ID. |
8+
| [**listNetworks**](NetworksApi.md#listNetworks) | **GET** /api/v1/networks | Network routes implementation |
9+
| [**updateNetwork**](NetworksApi.md#updateNetwork) | **PATCH** /api/v1/networks/{network_id} | Updates a network&#39;s configuration. Currently supports updating RPC URLs only. Can be extended to support other fields. |
10+
11+
12+
<a name="getNetwork"></a>
13+
# **getNetwork**
14+
> ApiResponse_NetworkResponse getNetwork(network\_id)
15+
16+
Retrieves details of a specific network by ID.
17+
18+
### Parameters
19+
20+
|Name | Type | Description | Notes |
21+
|------------- | ------------- | ------------- | -------------|
22+
| **network\_id** | **String**| Network ID (e.g., evm:sepolia, solana:mainnet) | [default to null] |
23+
24+
### Return type
25+
26+
[**ApiResponse_NetworkResponse**](../Models/ApiResponse_NetworkResponse.md)
27+
28+
### Authorization
29+
30+
[bearer_auth](../README.md#bearer_auth)
31+
32+
### HTTP request headers
33+
34+
- **Content-Type**: Not defined
35+
- **Accept**: application/json
36+
37+
<a name="listNetworks"></a>
38+
# **listNetworks**
39+
> ApiResponse_Vec_NetworkResponse listNetworks(page, per\_page)
40+
41+
Network routes implementation
42+
43+
Note: OpenAPI documentation for these endpoints can be found in the &#x60;openapi.rs&#x60; file Lists all networks with pagination support.
44+
45+
### Parameters
46+
47+
|Name | Type | Description | Notes |
48+
|------------- | ------------- | ------------- | -------------|
49+
| **page** | **Integer**| Page number for pagination (starts at 1) | [optional] [default to null] |
50+
| **per\_page** | **Integer**| Number of items per page (default: 10) | [optional] [default to null] |
51+
52+
### Return type
53+
54+
[**ApiResponse_Vec_NetworkResponse**](../Models/ApiResponse_Vec_NetworkResponse.md)
55+
56+
### Authorization
57+
58+
[bearer_auth](../README.md#bearer_auth)
59+
60+
### HTTP request headers
61+
62+
- **Content-Type**: Not defined
63+
- **Accept**: application/json
64+
65+
<a name="updateNetwork"></a>
66+
# **updateNetwork**
67+
> ApiResponse_NetworkResponse updateNetwork(network\_id, UpdateNetworkRequest)
68+
69+
Updates a network&#39;s configuration. Currently supports updating RPC URLs only. Can be extended to support other fields.
70+
71+
### Parameters
72+
73+
|Name | Type | Description | Notes |
74+
|------------- | ------------- | ------------- | -------------|
75+
| **network\_id** | **String**| Network ID (e.g., evm:sepolia, solana:mainnet) | [default to null] |
76+
| **UpdateNetworkRequest** | [**UpdateNetworkRequest**](../Models/UpdateNetworkRequest.md)| | |
77+
78+
### Return type
79+
80+
[**ApiResponse_NetworkResponse**](../Models/ApiResponse_NetworkResponse.md)
81+
82+
### Authorization
83+
84+
[bearer_auth](../README.md#bearer_auth)
85+
86+
### HTTP request headers
87+
88+
- **Content-Type**: application/json
89+
- **Accept**: application/json
90+

docs/Apis/PluginsApi.md

Lines changed: 116 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,28 @@ All URIs are relative to *http://localhost*
44

55
| Method | HTTP request | Description |
66
|------------- | ------------- | -------------|
7-
| [**callPlugin**](PluginsApi.md#callPlugin) | **POST** /api/v1/plugins/{plugin_id}/call | Execute a plugin and receive the sanitized result |
7+
| [**callPlugin**](PluginsApi.md#callPlugin) | **POST** /api/v1/plugins/{plugin_id}/call | Execute a plugin with optional wildcard route routing |
8+
| [**callPluginGet**](PluginsApi.md#callPluginGet) | **GET** /api/v1/plugins/{plugin_id}/call | Execute a plugin via GET (must be enabled per plugin) |
9+
| [**getPlugin**](PluginsApi.md#getPlugin) | **GET** /api/v1/plugins/{plugin_id} | Get plugin by ID |
10+
| [**listPlugins**](PluginsApi.md#listPlugins) | **GET** /api/v1/plugins | List plugins. |
11+
| [**updatePlugin**](PluginsApi.md#updatePlugin) | **PATCH** /api/v1/plugins/{plugin_id} | Update plugin configuration |
812

913

1014
<a name="callPlugin"></a>
1115
# **callPlugin**
12-
> ApiResponse_Value callPlugin(plugin\_id, PluginCallRequest)
16+
> ApiResponse_Value callPlugin(plugin\_id, PluginCallRequest, route)
1317
14-
Execute a plugin and receive the sanitized result
18+
Execute a plugin with optional wildcard route routing
1519

16-
Logs and traces are only returned when the plugin is configured with &#x60;emit_logs&#x60; / &#x60;emit_traces&#x60;. Plugin-provided errors are normalized into a consistent payload (&#x60;code&#x60;, &#x60;details&#x60;) and a derived message so downstream clients receive a stable shape regardless of how the handler threw.
20+
Logs and traces are only returned when the plugin is configured with &#x60;emit_logs&#x60; / &#x60;emit_traces&#x60;. Plugin-provided errors are normalized into a consistent payload (&#x60;code&#x60;, &#x60;details&#x60;) and a derived message so downstream clients receive a stable shape regardless of how the handler threw. The endpoint supports wildcard route routing, allowing plugins to implement custom routing logic: - &#x60;/api/v1/plugins/{plugin_id}/call&#x60; - Default endpoint (route &#x3D; \&quot;\&quot;) - &#x60;/api/v1/plugins/{plugin_id}/call?route&#x3D;/verify&#x60; - Custom route via query parameter - &#x60;/api/v1/plugins/{plugin_id}/call/verify&#x60; - Custom route via URL path (route &#x3D; \&quot;/verify\&quot;) The route is passed to the plugin handler via the &#x60;context.route&#x60; field. You can specify a custom route either by appending it to the URL path or by using the &#x60;route&#x60; query parameter.
1721

1822
### Parameters
1923

2024
|Name | Type | Description | Notes |
2125
|------------- | ------------- | ------------- | -------------|
2226
| **plugin\_id** | **String**| The unique identifier of the plugin | [default to null] |
2327
| **PluginCallRequest** | [**PluginCallRequest**](../Models/PluginCallRequest.md)| | |
28+
| **route** | **String**| Optional route suffix for custom routing (e.g., &#39;/verify&#39;). Alternative to appending the route to the URL path. | [optional] [default to null] |
2429

2530
### Return type
2631

@@ -35,3 +40,110 @@ Execute a plugin and receive the sanitized result
3540
- **Content-Type**: application/json
3641
- **Accept**: application/json
3742

43+
<a name="callPluginGet"></a>
44+
# **callPluginGet**
45+
> ApiResponse_Value callPluginGet(plugin\_id, route)
46+
47+
Execute a plugin via GET (must be enabled per plugin)
48+
49+
This endpoint is disabled by default. To enable it for a given plugin, set &#x60;allow_get_invocation: true&#x60; in the plugin configuration. When invoked via GET: - &#x60;params&#x60; is an empty object (&#x60;{}&#x60;) - query parameters are passed to the plugin handler via &#x60;context.query&#x60; - wildcard route routing is supported the same way as POST (see &#x60;doc_call_plugin&#x60;) - Use the &#x60;route&#x60; query parameter or append the route to the URL path
50+
51+
### Parameters
52+
53+
|Name | Type | Description | Notes |
54+
|------------- | ------------- | ------------- | -------------|
55+
| **plugin\_id** | **String**| The unique identifier of the plugin | [default to null] |
56+
| **route** | **String**| Optional route suffix for custom routing (e.g., &#39;/verify&#39;). Alternative to appending the route to the URL path. | [optional] [default to null] |
57+
58+
### Return type
59+
60+
[**ApiResponse_Value**](../Models/ApiResponse_Value.md)
61+
62+
### Authorization
63+
64+
[bearer_auth](../README.md#bearer_auth)
65+
66+
### HTTP request headers
67+
68+
- **Content-Type**: Not defined
69+
- **Accept**: application/json
70+
71+
<a name="getPlugin"></a>
72+
# **getPlugin**
73+
> ApiResponse_PluginModel getPlugin(plugin\_id)
74+
75+
Get plugin by ID
76+
77+
### Parameters
78+
79+
|Name | Type | Description | Notes |
80+
|------------- | ------------- | ------------- | -------------|
81+
| **plugin\_id** | **String**| The unique identifier of the plugin | [default to null] |
82+
83+
### Return type
84+
85+
[**ApiResponse_PluginModel**](../Models/ApiResponse_PluginModel.md)
86+
87+
### Authorization
88+
89+
[bearer_auth](../README.md#bearer_auth)
90+
91+
### HTTP request headers
92+
93+
- **Content-Type**: Not defined
94+
- **Accept**: application/json
95+
96+
<a name="listPlugins"></a>
97+
# **listPlugins**
98+
> ApiResponse_PaginatedResult_PluginModel listPlugins(page, per\_page)
99+
100+
List plugins.
101+
102+
### Parameters
103+
104+
|Name | Type | Description | Notes |
105+
|------------- | ------------- | ------------- | -------------|
106+
| **page** | **Integer**| Page number for pagination (starts at 1) | [optional] [default to null] |
107+
| **per\_page** | **Integer**| Number of items per page (default: 10) | [optional] [default to null] |
108+
109+
### Return type
110+
111+
[**ApiResponse_PaginatedResult_PluginModel**](../Models/ApiResponse_PaginatedResult_PluginModel.md)
112+
113+
### Authorization
114+
115+
[bearer_auth](../README.md#bearer_auth)
116+
117+
### HTTP request headers
118+
119+
- **Content-Type**: Not defined
120+
- **Accept**: application/json
121+
122+
<a name="updatePlugin"></a>
123+
# **updatePlugin**
124+
> ApiResponse_PluginModel updatePlugin(plugin\_id, UpdatePluginRequest)
125+
126+
Update plugin configuration
127+
128+
Updates mutable plugin fields such as timeout, emit_logs, emit_traces, raw_response, allow_get_invocation, config, and forward_logs. The plugin id and path cannot be changed after creation. All fields are optional - only the provided fields will be updated. To clear the &#x60;config&#x60; field, pass &#x60;\&quot;config\&quot;: null&#x60;.
129+
130+
### Parameters
131+
132+
|Name | Type | Description | Notes |
133+
|------------- | ------------- | ------------- | -------------|
134+
| **plugin\_id** | **String**| The unique identifier of the plugin | [default to null] |
135+
| **UpdatePluginRequest** | [**UpdatePluginRequest**](../Models/UpdatePluginRequest.md)| Plugin configuration update. All fields are optional. | |
136+
137+
### Return type
138+
139+
[**ApiResponse_PluginModel**](../Models/ApiResponse_PluginModel.md)
140+
141+
### Authorization
142+
143+
[bearer_auth](../README.md#bearer_auth)
144+
145+
### HTTP request headers
146+
147+
- **Content-Type**: application/json
148+
- **Accept**: application/json
149+
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# ApiResponse_NetworkResponse
2+
## Properties
3+
4+
| Name | Type | Description | Notes |
5+
|------------ | ------------- | ------------- | -------------|
6+
| **data** | [**ApiResponse_NetworkResponse_data**](ApiResponse_NetworkResponse_data.md) | | [optional] [default to null] |
7+
| **error** | **String** | | [optional] [default to null] |
8+
| **metadata** | [**PluginMetadata**](PluginMetadata.md) | | [optional] [default to null] |
9+
| **pagination** | [**PaginationMeta**](PaginationMeta.md) | | [optional] [default to null] |
10+
| **success** | **Boolean** | | [default to null] |
11+
12+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
13+

0 commit comments

Comments
 (0)