From 25fa5d516f762c31f12acca9d69cd8eaa224027b Mon Sep 17 00:00:00 2001 From: Scaleway Bot Date: Thu, 14 Sep 2023 10:25:58 +0200 Subject: [PATCH] feat(instance): add field private_nic_mac_address for ListServersRequest (#1833) --- api/instance/v1/instance_sdk.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/api/instance/v1/instance_sdk.go b/api/instance/v1/instance_sdk.go index 9e797e03e..c947200be 100644 --- a/api/instance/v1/instance_sdk.go +++ b/api/instance/v1/instance_sdk.go @@ -2019,6 +2019,8 @@ type ListServersRequest struct { Order ListServersRequestOrder `json:"-"` // PrivateNetworks: list Instances from the given Private Networks (use commas to separate them). PrivateNetworks []string `json:"-"` + // PrivateNicMacAddress: list Instances associated with the given private NIC MAC address. + PrivateNicMacAddress *string `json:"-"` } // ListServers: list all Instances. @@ -2054,6 +2056,7 @@ func (s *API) ListServers(req *ListServersRequest, opts ...scw.RequestOption) (* if len(req.PrivateNetworks) != 0 { parameter.AddToQuery(query, "private_networks", strings.Join(req.PrivateNetworks, ",")) } + parameter.AddToQuery(query, "private_nic_mac_address", req.PrivateNicMacAddress) if fmt.Sprint(req.Zone) == "" { return nil, errors.New("field Zone cannot be empty in request")