From 64309917957c207de425ff375fde5b16b650210c Mon Sep 17 00:00:00 2001 From: fern-api <115122769+fern-api[bot]@users.noreply.github.com> Date: Tue, 27 Feb 2024 01:39:56 +0000 Subject: [PATCH] SDK regeneration --- acs/types.go | 117 -------------------------------- client_sessions.go | 1 + core/client_option.go | 2 +- types.go | 16 +++-- user_identities.go | 4 ++ useridentities/client/client.go | 3 +- 6 files changed, 20 insertions(+), 123 deletions(-) diff --git a/acs/types.go b/acs/types.go index 6530a35..73627a5 100644 --- a/acs/types.go +++ b/acs/types.go @@ -686,123 +686,6 @@ func (c *CredentialsGetResponseAcsCredentialWarningsItem) String() string { return fmt.Sprintf("%#v", c) } -type CredentialsListRequestOne struct { - AcsSystemId string `json:"acs_system_id"` - - _rawJSON json.RawMessage -} - -func (c *CredentialsListRequestOne) UnmarshalJSON(data []byte) error { - type unmarshaler CredentialsListRequestOne - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = CredentialsListRequestOne(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *CredentialsListRequestOne) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -type CredentialsListRequestTwo struct { - AcsUserId string `json:"acs_user_id"` - AcsSystemId string `json:"acs_system_id"` - - _rawJSON json.RawMessage -} - -func (c *CredentialsListRequestTwo) UnmarshalJSON(data []byte) error { - type unmarshaler CredentialsListRequestTwo - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = CredentialsListRequestTwo(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *CredentialsListRequestTwo) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -type CredentialsListRequestUserIdentityId struct { - UserIdentityId string `json:"user_identity_id"` - - _rawJSON json.RawMessage -} - -func (c *CredentialsListRequestUserIdentityId) UnmarshalJSON(data []byte) error { - type unmarshaler CredentialsListRequestUserIdentityId - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = CredentialsListRequestUserIdentityId(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *CredentialsListRequestUserIdentityId) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - -type CredentialsListRequestZero struct { - AcsUserId string `json:"acs_user_id"` - - _rawJSON json.RawMessage -} - -func (c *CredentialsListRequestZero) UnmarshalJSON(data []byte) error { - type unmarshaler CredentialsListRequestZero - var value unmarshaler - if err := json.Unmarshal(data, &value); err != nil { - return err - } - *c = CredentialsListRequestZero(value) - c._rawJSON = json.RawMessage(data) - return nil -} - -func (c *CredentialsListRequestZero) String() string { - if len(c._rawJSON) > 0 { - if value, err := core.StringifyJSON(c._rawJSON); err == nil { - return value - } - } - if value, err := core.StringifyJSON(c); err == nil { - return value - } - return fmt.Sprintf("%#v", c) -} - type CredentialsListResponseAcsCredentialsItem struct { AcsCredentialId string `json:"acs_credential_id"` AcsUserId *string `json:"acs_user_id,omitempty"` diff --git a/client_sessions.go b/client_sessions.go index 4b0f42b..6e01207 100644 --- a/client_sessions.go +++ b/client_sessions.go @@ -47,6 +47,7 @@ type ClientSessionsListRequest struct { UserIdentifierKey *string `json:"user_identifier_key,omitempty"` ConnectWebviewId *string `json:"connect_webview_id,omitempty"` WithoutUserIdentifierKey *bool `json:"without_user_identifier_key,omitempty"` + UserIdentityId *string `json:"user_identity_id,omitempty"` } type ClientSessionsRevokeRequest struct { diff --git a/core/client_option.go b/core/client_option.go index 161c8ac..2267009 100644 --- a/core/client_option.go +++ b/core/client_option.go @@ -50,6 +50,6 @@ func (c *ClientOptions) cloneHeader() http.Header { headers := c.HTTPHeader.Clone() headers.Set("X-Fern-Language", "Go") headers.Set("X-Fern-SDK-Name", "github.com/seamapi/go") - headers.Set("X-Fern-SDK-Version", "v0.2.10") + headers.Set("X-Fern-SDK-Version", "v0.2.11") return headers } diff --git a/types.go b/types.go index 21f001f..d56cf10 100644 --- a/types.go +++ b/types.go @@ -2890,6 +2890,8 @@ type DeviceProviderProviderCategoriesItem string const ( DeviceProviderProviderCategoriesItemStable DeviceProviderProviderCategoriesItem = "stable" DeviceProviderProviderCategoriesItemConsumerSmartlocks DeviceProviderProviderCategoriesItem = "consumer_smartlocks" + DeviceProviderProviderCategoriesItemThermostats DeviceProviderProviderCategoriesItem = "thermostats" + DeviceProviderProviderCategoriesItemNoiseSensors DeviceProviderProviderCategoriesItem = "noise_sensors" ) func NewDeviceProviderProviderCategoriesItemFromString(s string) (DeviceProviderProviderCategoriesItem, error) { @@ -2898,6 +2900,10 @@ func NewDeviceProviderProviderCategoriesItemFromString(s string) (DeviceProvider return DeviceProviderProviderCategoriesItemStable, nil case "consumer_smartlocks": return DeviceProviderProviderCategoriesItemConsumerSmartlocks, nil + case "thermostats": + return DeviceProviderProviderCategoriesItemThermostats, nil + case "noise_sensors": + return DeviceProviderProviderCategoriesItemNoiseSensors, nil } var t DeviceProviderProviderCategoriesItem return "", fmt.Errorf("%s is not a valid %T", s, t) @@ -4097,10 +4103,12 @@ type UnmanagedDevice struct { // Array of warnings associated with the device. Each warning object within the array contains two fields: "warning_code" and "message." "warning_code" is a string that uniquely identifies the type of warning, enabling quick recognition and categorization of the issue. "message" provides a more detailed description of the warning, offering insights into the issue and potentially how to rectify it. Warnings []*UnmanagedDeviceWarningsItem `json:"warnings,omitempty"` // Date and time at which the device object was created. - CreatedAt time.Time `json:"created_at"` - IsManaged bool `json:"is_managed"` - Properties *UnmanagedDeviceProperties `json:"properties,omitempty"` - DeviceProvider *UnmanagedDeviceDeviceProvider `json:"device_provider,omitempty"` + CreatedAt time.Time `json:"created_at"` + IsManaged bool `json:"is_managed"` + Properties *UnmanagedDeviceProperties `json:"properties,omitempty"` + CanRemotelyUnlock *bool `json:"can_remotely_unlock,omitempty"` + CanProgramOnlineAccessCodes *bool `json:"can_program_online_access_codes,omitempty"` + DeviceProvider *UnmanagedDeviceDeviceProvider `json:"device_provider,omitempty"` _rawJSON json.RawMessage } diff --git a/user_identities.go b/user_identities.go index f5d726c..9d466a6 100644 --- a/user_identities.go +++ b/user_identities.go @@ -29,6 +29,10 @@ type UserIdentitiesGrantAccessToDeviceRequest struct { DeviceId string `json:"device_id"` } +type UserIdentitiesListRequest struct { + CredentialManagerAcsSystemId *string `json:"credential_manager_acs_system_id,omitempty"` +} + type UserIdentitiesListAccessibleDevicesRequest struct { UserIdentityId string `json:"user_identity_id"` } diff --git a/useridentities/client/client.go b/useridentities/client/client.go index 1d24f2a..6e5629d 100644 --- a/useridentities/client/client.go +++ b/useridentities/client/client.go @@ -285,7 +285,7 @@ func (c *Client) GrantAccessToDevice(ctx context.Context, request *seamapigo.Use return response, nil } -func (c *Client) List(ctx context.Context) ([]*seamapigo.UserIdentitiesListResponseUserIdentitiesItem, error) { +func (c *Client) List(ctx context.Context, request *seamapigo.UserIdentitiesListRequest) ([]*seamapigo.UserIdentitiesListResponseUserIdentitiesItem, error) { baseURL := "https://connect.getseam.com" if c.baseURL != "" { baseURL = c.baseURL @@ -325,6 +325,7 @@ func (c *Client) List(ctx context.Context) ([]*seamapigo.UserIdentitiesListRespo URL: endpointURL, Method: http.MethodPost, Headers: c.header, + Request: request, Response: &response, ErrorDecoder: errorDecoder, },