Skip to content

Commit

Permalink
generate updated docs
Browse files Browse the repository at this point in the history
  • Loading branch information
sameh-farouk committed Aug 21, 2023
1 parent 40c75a6 commit a370cef
Show file tree
Hide file tree
Showing 2 changed files with 150 additions and 74 deletions.
150 changes: 97 additions & 53 deletions 3bot/vgrid/gridproxy/docs/gridproxy.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# module threefoldtech.vgrid.gridproxy
# module gridproxy



Expand Down Expand Up @@ -76,18 +76,20 @@ fn (mut c GridProxyClient) get_contracts(params ContractFilter) ![]Contract

get_contracts fetchs contracts information with pagination.

* `contract_id` (u64): Contract id. [optional].
* `contract_type` (string): [optional].
* `deployment_data` (string): Contract deployment data in case of 'node' contracts. [optional].
* `deployment_hash` (string): Contract deployment hash in case of 'node' contracts. [optional].
* `name` (string): Contract name in case of 'name' contracts. [optional].
* `node_id` (u64): Node id which contract is deployed on in case of ('rent' or 'node' contracts). [optional].
* `number_of_public_ips` (u64): Min number of public ips in the 'node' contract. [optional].
* `page` (u64): Page number. [optional].
* `size` (u64): Max result per page. [optional].
* `randomize` (bool): [optional].
* `ret_count` (bool): Set farms' count on headers based on filter. [optional].
* `contract_id` (u64): contract id. [optional].
* `twin_id` (u64): twin id. [optional].
* `node_id` (u64): node id which contract is deployed on in case of ('rent' or 'node' contracts). [optional].
* `name` (string): contract name in case of 'name' contracts. [optional].
* `type` (string): contract type 'node', 'name', or 'rent'. [optional].
* `state` (string): contract state 'Created', or 'Deleted'. [optional].
* `deployment_data` (string): contract deployment data in case of 'node' contracts. [optional].
* `deployment_hash` (string): contract deployment hash in case of 'node' contracts. [optional].
* `number_of_public_ips` (u64): Min number of public ips in the 'node' contract. [optional].
* `size` (u64): Max result per page. [optional].
* `state` (string): Contract state 'Created', or 'Deleted'. [optional].
* `twin_id` (u64): Twin id. [optional].
* `type` (string): Contract type 'node', 'name', or 'rent'. [optional].

* returns: `[]Contract` or `Error`.

Expand Down Expand Up @@ -161,20 +163,28 @@ fn (mut c GridProxyClient) get_farms(params FarmFilter) ![]Farm

get_farms fetchs farms information and public ips.

* `certification_type` (string): Certificate type DIY or Certified. [optional].
* `country` (string): Farm country. [optional].
* `dedicated` (bool): Farm is dedicated. [optional].
* `farm_id` (u64): Farm id. [optional].
* `free_ips` (u64): Min number of free ips in the farm. [optional].
* `name_contains` (string): Farm name contains. [optional].
* `name` (string): Farm name. [optional].
* `node_available_for` (u64): Twin ID of user for whom there is at least one node that is available to be deployed to in the farm. [optional].
* `node_certified` (bool): True for farms who have at least one certified node. [optional].
* `node_free_hru` (u64): Min free reservable hru for at least a single node that belongs to the farm, in bytes. [optional].
* `node_free_mru` (u64): Min free reservable mru for at least a single node that belongs to the farm, in bytes. [optional].
* `node_free_sru` (u64): Min free reservable sru for at least a single node that belongs to the farm, in bytes. [optional].
* `node_has_gpu` (bool): True for farms who have at least one node with a GPU * `node_rented_by` (u64): Twin ID of user who has at least one rented node in the farm * `node_status` (string): Node status for at least a single node that belongs to the farm
* `page` (u64): Page number. [optional].
* `size` (u64): Max result per page. [optional].
* `pricing_policy_id` (u64): Pricing policy id. [optional].
* `randomize` (bool): [optional].
* `ret_count` (bool): Set farms' count on headers based on filter. [optional].
* `free_ips` (u64): Min number of free ips in the farm. [optional].
* `size` (u64): Max result per page. [optional].
* `stellar_address` (string): Farm stellar_address. [optional].
* `total_ips` (u64): Min number of total ips in the farm. [optional].
* `pricing_policy_id` (u64): Pricing policy id. [optional].
* `version` (u64): farm version. [optional].
* `farm_id` (u64): farm id. [optional].
* `twin_id` (u64): twin id associated with the farm. [optional].
* `name` (string): farm name. [optional].
* `name_contains` (string): farm name contains. [optional].
* `certification_type` (string): certificate type DIY or Certified. [optional].
* `dedicated` (bool): farm is dedicated. [optional].
* `stellar_address` (string): farm stellar_address. [optional].
* `twin_id` (u64): Twin id associated with the farm. [optional].
* `version` (u64): Farm version. [optional].

returns: `[]Farm` or `Error`.

Expand Down Expand Up @@ -222,25 +232,41 @@ fn (mut c GridProxyClient) get_gateways(params NodeFilter) ![]Node

get_gateways fetchs gateways information and public configurations and domains with pagination.

* `page` (u64): Page number. [optional].
* `size` (u64): Max result per page. [optional].
* `ret_count` (bool): Set nodes' count on headers based on filter. [optional].
* `free_mru` (u64): Min free reservable mru in bytes. [optional].
* `free_hru` (u64): Min free reservable hru in bytes. [optional].
* `free_sru` (u64): Min free reservable sru in bytes. [optional].
* `free_ips` (u64): Min number of free ips in the farm of the node. [optional].
* `status` (string): Node status filter, set to 'up' to get online nodes only.. [optional].
* `available_for` (u64): Available for twin id. [optional].
* `certification_type` (string): Certificate type NotCertified, Silver or Gold. [optional].
* `city_contains` (string): Node partial city filter. [optional].
* `city` (string): Node city filter. [optional].
* `country_contains` (string): Node partial country filter. [optional].
* `country` (string): Node country filter. [optional].
* `dedicated` (bool): Set to true to get the dedicated nodes only. [optional].
* `domain` (string): Set to true to filter nodes with domain. [optional].
* `farm_ids` ([]u64): List of farm ids. [optional].
* `farm_name_contains` (string): Get nodes for specific farm. [optional].
* `farm_name` (string): Get nodes for specific farm. [optional].
* `free_hru` (u64): Min free reservable hru in bytes. [optional].
* `free_ips` (u64): Min number of free ips in the farm of the node. [optional].
* `free_mru` (u64): Min free reservable mru in bytes. [optional].
* `free_sru` (u64): Min free reservable sru in bytes. [optional].
* `gpu_available` (bool): Filter nodes that have available GPU. [optional].
* `gpu_device_id` (string): Filter nodes based on GPU device ID. [optional].
* `gpu_device_name` (string): Filter nodes based on GPU device partial name. [optional].
* `gpu_vendor_id` (string): Filter nodes based on GPU vendor ID. [optional].
* `gpu_vendor_name` (string): Filter nodes based on GPU vendor partial name. [optional].
* `has_gpu`: Filter nodes on whether they have GPU support or not. [optional].
* `ipv4` (string): Set to true to filter nodes with ipv4. [optional].
* `ipv6` (string): Set to true to filter nodes with ipv6. [optional].
* `domain` (string): Set to true to filter nodes with domain. [optional].
* `dedicated` (bool): Set to true to get the dedicated nodes only. [optional].
* `node_id` (u64): Node id. [optional].
* `page` (u64): Page number. [optional].
* `rentable` (bool): Set to true to filter the available nodes for renting. [optional].
* `rented_by` (u64): rented by twin id. [optional].
* `available_for` (u64): available for twin id. [optional].
* `farm_ids` ([]u64): List of farm ids. [optional].
* `rented_by` (u64): Rented by twin id. [optional].
* `ret_count` (bool): Set nodes' count on headers based on filter. [optional].
* `size` (u64): Max result per page. [optional].
* `status` (string): Node status filter, set to 'up' to get online nodes only. [optional].
* `total_cru` (u64): Min total cru in bytes. [optional].
* `total_hru` (u64): Min total hru in bytes. [optional].
* `total_mru` (u64): Min total mru in bytes. [optional].
* `total_sru` (u64): Min total sru in bytes. [optional].
* `twin_id` (u64): Twin id. [optional].

returns: `[]Node` or `Error`.

Expand Down Expand Up @@ -276,7 +302,7 @@ fn (mut c GridProxyClient) get_node_stats_by_id(node_id u64) !NodeStats
get_node_stats_by_id fetchs specific node statistics by node id.

* `node_id` (u64): node id.
statistics

returns: `Node_stats` or `Error`.

[[Return to contents]](#Contents)
Expand All @@ -288,25 +314,41 @@ fn (mut c GridProxyClient) get_nodes(params NodeFilter) ![]Node

get_nodes fetchs nodes information and public configurations with pagination.

* `page` (u64): Page number. [optional].
* `size` (u64): Max result per page. [optional].
* `ret_count` (bool): Set nodes' count on headers based on filter. [optional].
* `free_mru` (u64): Min free reservable mru in bytes. [optional].
* `free_hru` (u64): Min free reservable hru in bytes. [optional].
* `free_sru` (u64): Min free reservable sru in bytes. [optional].
* `free_ips` (u64): Min number of free ips in the farm of the node. [optional].
* `status` (string): Node status filter, set to 'up' to get online nodes only. [optional].
* `available_for` (u64): Available for twin id. [optional].
* `certification_type` (string): Certificate type NotCertified, Silver or Gold. [optional].
* `city_contains` (string): Node partial city filter. [optional].
* `city` (string): Node city filter. [optional].
* `country_contains` (string): Node partial country filter. [optional].
* `country` (string): Node country filter. [optional].
* `dedicated` (bool): Set to true to get the dedicated nodes only. [optional].
* `domain` (string): Set to true to filter nodes with domain. [optional].
* `farm_ids` ([]u64): List of farm ids. [optional].
* `farm_name_contains` (string): Get nodes for specific farm. [optional].
* `farm_name` (string): Get nodes for specific farm. [optional].
* `free_hru` (u64): Min free reservable hru in bytes. [optional].
* `free_ips` (u64): Min number of free ips in the farm of the node. [optional].
* `free_mru` (u64): Min free reservable mru in bytes. [optional].
* `free_sru` (u64): Min free reservable sru in bytes. [optional].
* `gpu_available` (bool): Filter nodes that have available GPU. [optional].
* `gpu_device_id` (string): Filter nodes based on GPU device ID. [optional].
* `gpu_device_name` (string): Filter nodes based on GPU device partial name. [optional].
* `gpu_vendor_id` (string): Filter nodes based on GPU vendor ID. [optional].
* `gpu_vendor_name` (string): Filter nodes based on GPU vendor partial name. [optional].
* `has_gpu`: Filter nodes on whether they have GPU support or not. [optional].
* `ipv4` (string): Set to true to filter nodes with ipv4. [optional].
* `ipv6` (string): Set to true to filter nodes with ipv6. [optional].
* `domain` (string): Set to true to filter nodes with domain. [optional].
* `dedicated` (bool): Set to true to get the dedicated nodes only. [optional].
* `node_id` (u64): Node id. [optional].
* `page` (u64): Page number. [optional].
* `rentable` (bool): Set to true to filter the available nodes for renting. [optional].
* `rented_by` (u64): rented by twin id. [optional].
* `available_for` (u64): available for twin id. [optional].
* `farm_ids` ([]u64): List of farm ids. [optional].
* `rented_by` (u64): Rented by twin id. [optional].
* `ret_count` (bool): Set nodes' count on headers based on filter. [optional].
* `size` (u64): Max result per page. [optional].
* `status` (string): Node status filter, set to 'up' to get online nodes only. [optional].
* `total_cru` (u64): Min total cru in bytes. [optional].
* `total_hru` (u64): Min total hru in bytes. [optional].
* `total_mru` (u64): Min total mru in bytes. [optional].
* `total_sru` (u64): Min total sru in bytes. [optional].
* `twin_id` (u64): Twin id. [optional].

returns: `[]Node` or `Error`.

Expand Down Expand Up @@ -383,11 +425,13 @@ fn (mut c GridProxyClient) get_twins(params TwinFilter) ![]Twin

get_twins fetchs twins information with pagaination.

* `account_id` (string): Account address. [optional].
* `page` (u64): Page number. [optional].
* `size` (u64): Max result per page. [optional].
* `public_key` (string): twin public key used for e2e encryption. [optional].
* `relay` (string): relay domain name. [optional].
* `ret_count` (bool): Set farms' count on headers based on filter. [optional].
* `twin_id` (u64): twin id. [optional].
* `account_id` (string): account address. [optional].
* `size` (u64): Max result per page. [optional].
* `twin_id` (u64): Twin id. [optional].

returns: `[]Twin` or `Error`.

Expand All @@ -413,4 +457,4 @@ returns: bool, `true` if API server is reachable and responding, `false` otherwi

[[Return to contents]](#Contents)

#### Powered by vdoc. Generated on: 20 Aug 2023 17:40:51
#### Powered by vdoc. Generated on: 21 Aug 2023 13:39:52
74 changes: 53 additions & 21 deletions 3bot/vgrid/gridproxy/docs/gridproxy.model.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# module threefoldtech.vgrid.gridproxy.model
# module gridproxy.model



Expand Down Expand Up @@ -273,6 +273,7 @@ pub mut:
page OptionU64 = EmptyOption{}
size OptionU64 = EmptyOption{}
ret_count OptionBool = EmptyOption{}
randomize OptionBool = EmptyOption{}
contract_id OptionU64 = EmptyOption{}
twin_id OptionU64 = EmptyOption{}
node_id OptionU64 = EmptyOption{}
Expand Down Expand Up @@ -343,6 +344,7 @@ pub mut:
page OptionU64 = EmptyOption{}
size OptionU64 = EmptyOption{}
ret_count OptionBool = EmptyOption{}
randomize OptionBool = EmptyOption{}
free_ips OptionU64 = EmptyOption{}
total_ips OptionU64 = EmptyOption{}
stellar_address string
Expand All @@ -353,6 +355,15 @@ pub mut:
name_contains string
certification_type string
dedicated OptionBool = EmptyOption{}
country string
node_free_mru OptionU64 = EmptyOption{}
node_free_hru OptionU64 = EmptyOption{}
node_free_sru OptionU64 = EmptyOption{}
node_status string
node_rented_by OptionU64 = EmptyOption{}
node_available_for OptionU64 = EmptyOption{}
node_has_gpu OptionBool = EmptyOption{}
node_certified OptionBool = EmptyOption{}
}
```

Expand Down Expand Up @@ -527,25 +538,43 @@ pub:
```v
struct NodeFilter {
pub mut:
page OptionU64 = EmptyOption{}
size OptionU64 = EmptyOption{}
ret_count OptionBool = EmptyOption{}
free_mru OptionU64 = EmptyOption{}
free_sru OptionU64 = EmptyOption{}
free_hru OptionU64 = EmptyOption{}
free_ips OptionU64 = EmptyOption{}
city string
country string
farm_name string
ipv4 string
ipv6 string
domain string
status string
dedicated OptionBool = EmptyOption{}
rentable OptionBool = EmptyOption{}
rented_by OptionU64 = EmptyOption{}
available_for OptionU64 = EmptyOption{}
farm_ids []u64
page OptionU64 = EmptyOption{}
size OptionU64 = EmptyOption{}
ret_count OptionBool = EmptyOption{}
randomize OptionBool = EmptyOption{}
free_mru OptionU64 = EmptyOption{}
free_sru OptionU64 = EmptyOption{}
free_hru OptionU64 = EmptyOption{}
free_ips OptionU64 = EmptyOption{}
total_mru OptionU64 = EmptyOption{}
total_sru OptionU64 = EmptyOption{}
total_hru OptionU64 = EmptyOption{}
total_cru OptionU64 = EmptyOption{}
city string
city_contains string
country string
country_contains string
farm_name string
farm_name_contains string
ipv4 OptionBool = EmptyOption{}
ipv6 OptionBool = EmptyOption{}
domain OptionBool = EmptyOption{}
status string
dedicated OptionBool = EmptyOption{}
rentable OptionBool = EmptyOption{}
rented_by OptionU64 = EmptyOption{}
rented OptionBool = EmptyOption{}
available_for OptionU64 = EmptyOption{}
farm_ids []u64
node_id OptionU64 = EmptyOption{}
twin_id OptionU64 = EmptyOption{}
certification_type string
has_gpu OptionBool = EmptyOption{}
gpu_device_id string
gpu_device_name string
gpu_vendor_id string
gpu_vendor_name string
gpu_available OptionBool = EmptyOption{}
}
```

Expand Down Expand Up @@ -727,8 +756,11 @@ pub mut:
page OptionU64 = EmptyOption{}
size OptionU64 = EmptyOption{}
ret_count OptionBool = EmptyOption{}
randomize OptionBool = EmptyOption{}
twin_id OptionU64 = EmptyOption{}
account_id string
relay string
public_key string
}
```

Expand Down Expand Up @@ -765,4 +797,4 @@ fn (mut i TwinIterator) next() ?[]Twin

[[Return to contents]](#Contents)

#### Powered by vdoc. Generated on: 20 Aug 2023 17:40:51
#### Powered by vdoc. Generated on: 21 Aug 2023 13:39:52

0 comments on commit a370cef

Please sign in to comment.