From cc355ec5151f6bcf379881675e43d257b2361843 Mon Sep 17 00:00:00 2001 From: fern-api <115122769+fern-api[bot]@users.noreply.github.com> Date: Fri, 2 Feb 2024 21:13:57 +0000 Subject: [PATCH] SDK regeneration --- acs/credentials.go | 1 + acs/entrances.go | 5 +- acs/types.go | 406 ++++++++++++++++++++++++++++++++---------- client/options.go | 9 +- connect_webviews.go | 3 + core/client_option.go | 8 +- 6 files changed, 317 insertions(+), 115 deletions(-) diff --git a/acs/credentials.go b/acs/credentials.go index 5b4eaf5..d081954 100644 --- a/acs/credentials.go +++ b/acs/credentials.go @@ -120,6 +120,7 @@ type CredentialsCreateRequestVisionlineMetadata struct { AssaAbloyCredentialServiceMobileEndpointId *string `json:"assa_abloy_credential_service_mobile_endpoint_id,omitempty"` CardFormat *CredentialsCreateRequestVisionlineMetadataCardFormat `json:"card_format,omitempty"` IsOverrideKey *bool `json:"is_override_key,omitempty"` + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` _rawJSON json.RawMessage } diff --git a/acs/entrances.go b/acs/entrances.go index b3a1f4f..e6edb8d 100644 --- a/acs/entrances.go +++ b/acs/entrances.go @@ -23,9 +23,8 @@ type EntrancesListRequest struct { } type EntrancesListCredentialsWithAccessRequest struct { - AcsEntranceId *string `json:"acs_entrance_id,omitempty"` - AcsEntranceIds []string `json:"acs_entrance_ids,omitempty"` - IncludeIf []string `json:"include_if,omitempty"` + AcsEntranceId string `json:"acs_entrance_id"` + IncludeIf []string `json:"include_if,omitempty"` } type EntrancesGetResponse struct { diff --git a/acs/types.go b/acs/types.go index 6985ea0..65384ba 100644 --- a/acs/types.go +++ b/acs/types.go @@ -95,20 +95,21 @@ func (c *CredentialProvisioningAutomationsLaunchResponseAcsCredentialProvisionin } type CredentialsAssignResponseAcsCredential struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod CredentialsAssignResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` - ExternalType *CredentialsAssignResponseAcsCredentialExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod CredentialsAssignResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` + ExternalType *CredentialsAssignResponseAcsCredentialExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *CredentialsAssignResponseAcsCredentialVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -189,6 +190,35 @@ func (c CredentialsAssignResponseAcsCredentialExternalType) Ptr() *CredentialsAs return &c } +type CredentialsAssignResponseAcsCredentialVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CredentialsAssignResponseAcsCredentialVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler CredentialsAssignResponseAcsCredentialVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CredentialsAssignResponseAcsCredentialVisionlineMetadata(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CredentialsAssignResponseAcsCredentialVisionlineMetadata) 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 CredentialsCreateRequestVisionlineMetadataCardFormat string const ( @@ -212,20 +242,21 @@ func (c CredentialsCreateRequestVisionlineMetadataCardFormat) Ptr() *Credentials } type CredentialsCreateResponseAcsCredential struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod CredentialsCreateResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` - ExternalType *CredentialsCreateResponseAcsCredentialExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod CredentialsCreateResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` + ExternalType *CredentialsCreateResponseAcsCredentialExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *CredentialsCreateResponseAcsCredentialVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -306,21 +337,51 @@ func (c CredentialsCreateResponseAcsCredentialExternalType) Ptr() *CredentialsCr return &c } +type CredentialsCreateResponseAcsCredentialVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CredentialsCreateResponseAcsCredentialVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler CredentialsCreateResponseAcsCredentialVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CredentialsCreateResponseAcsCredentialVisionlineMetadata(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CredentialsCreateResponseAcsCredentialVisionlineMetadata) 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 CredentialsGetResponseAcsCredential struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod CredentialsGetResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` - ExternalType *CredentialsGetResponseAcsCredentialExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod CredentialsGetResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` + ExternalType *CredentialsGetResponseAcsCredentialExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *CredentialsGetResponseAcsCredentialVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -401,6 +462,35 @@ func (c CredentialsGetResponseAcsCredentialExternalType) Ptr() *CredentialsGetRe return &c } +type CredentialsGetResponseAcsCredentialVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CredentialsGetResponseAcsCredentialVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler CredentialsGetResponseAcsCredentialVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CredentialsGetResponseAcsCredentialVisionlineMetadata(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CredentialsGetResponseAcsCredentialVisionlineMetadata) 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 CredentialsListRequestOne struct { AcsSystemId string `json:"acs_system_id"` @@ -519,20 +609,21 @@ func (c *CredentialsListRequestZero) String() string { } type CredentialsListResponseAcsCredentialsItem struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod CredentialsListResponseAcsCredentialsItemAccessMethod `json:"access_method,omitempty"` - ExternalType *CredentialsListResponseAcsCredentialsItemExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod CredentialsListResponseAcsCredentialsItemAccessMethod `json:"access_method,omitempty"` + ExternalType *CredentialsListResponseAcsCredentialsItemExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *CredentialsListResponseAcsCredentialsItemVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -613,21 +704,51 @@ func (c CredentialsListResponseAcsCredentialsItemExternalType) Ptr() *Credential return &c } +type CredentialsListResponseAcsCredentialsItemVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CredentialsListResponseAcsCredentialsItemVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler CredentialsListResponseAcsCredentialsItemVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CredentialsListResponseAcsCredentialsItemVisionlineMetadata(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CredentialsListResponseAcsCredentialsItemVisionlineMetadata) 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 CredentialsUnassignResponseAcsCredential struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod CredentialsUnassignResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` - ExternalType *CredentialsUnassignResponseAcsCredentialExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod CredentialsUnassignResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` + ExternalType *CredentialsUnassignResponseAcsCredentialExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *CredentialsUnassignResponseAcsCredentialVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -708,21 +829,51 @@ func (c CredentialsUnassignResponseAcsCredentialExternalType) Ptr() *Credentials return &c } +type CredentialsUnassignResponseAcsCredentialVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CredentialsUnassignResponseAcsCredentialVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler CredentialsUnassignResponseAcsCredentialVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CredentialsUnassignResponseAcsCredentialVisionlineMetadata(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CredentialsUnassignResponseAcsCredentialVisionlineMetadata) 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 CredentialsUpdateResponseAcsCredential struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod CredentialsUpdateResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` - ExternalType *CredentialsUpdateResponseAcsCredentialExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod CredentialsUpdateResponseAcsCredentialAccessMethod `json:"access_method,omitempty"` + ExternalType *CredentialsUpdateResponseAcsCredentialExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *CredentialsUpdateResponseAcsCredentialVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -803,6 +954,35 @@ func (c CredentialsUpdateResponseAcsCredentialExternalType) Ptr() *CredentialsUp return &c } +type CredentialsUpdateResponseAcsCredentialVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (c *CredentialsUpdateResponseAcsCredentialVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler CredentialsUpdateResponseAcsCredentialVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *c = CredentialsUpdateResponseAcsCredentialVisionlineMetadata(value) + c._rawJSON = json.RawMessage(data) + return nil +} + +func (c *CredentialsUpdateResponseAcsCredentialVisionlineMetadata) 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 EntrancesGetResponseAcsEntrance struct { AcsEntranceId string `json:"acs_entrance_id"` DisplayName string `json:"display_name"` @@ -922,20 +1102,21 @@ func (e EntrancesGetResponseAcsEntranceVisionlineMetadataProfilesItemVisionlineD } type EntrancesListCredentialsWithAccessResponseAcsCredentialsItem struct { - AcsCredentialId string `json:"acs_credential_id"` - AcsUserId *string `json:"acs_user_id,omitempty"` - AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` - AcsSystemId string `json:"acs_system_id"` - DisplayName string `json:"display_name"` - Code *string `json:"code,omitempty"` - AccessMethod EntrancesListCredentialsWithAccessResponseAcsCredentialsItemAccessMethod `json:"access_method,omitempty"` - ExternalType *EntrancesListCredentialsWithAccessResponseAcsCredentialsItemExternalType `json:"external_type,omitempty"` - ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` - CreatedAt time.Time `json:"created_at"` - WorkspaceId string `json:"workspace_id"` - StartsAt *string `json:"starts_at,omitempty"` - EndsAt *string `json:"ends_at,omitempty"` - IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + AcsCredentialId string `json:"acs_credential_id"` + AcsUserId *string `json:"acs_user_id,omitempty"` + AcsCredentialPoolId *string `json:"acs_credential_pool_id,omitempty"` + AcsSystemId string `json:"acs_system_id"` + DisplayName string `json:"display_name"` + Code *string `json:"code,omitempty"` + AccessMethod EntrancesListCredentialsWithAccessResponseAcsCredentialsItemAccessMethod `json:"access_method,omitempty"` + ExternalType *EntrancesListCredentialsWithAccessResponseAcsCredentialsItemExternalType `json:"external_type,omitempty"` + ExternalTypeDisplayName *string `json:"external_type_display_name,omitempty"` + CreatedAt time.Time `json:"created_at"` + WorkspaceId string `json:"workspace_id"` + StartsAt *string `json:"starts_at,omitempty"` + EndsAt *string `json:"ends_at,omitempty"` + IsMultiPhoneSyncCredential *bool `json:"is_multi_phone_sync_credential,omitempty"` + VisionlineMetadata *EntrancesListCredentialsWithAccessResponseAcsCredentialsItemVisionlineMetadata `json:"visionline_metadata,omitempty"` _rawJSON json.RawMessage } @@ -1016,6 +1197,35 @@ func (e EntrancesListCredentialsWithAccessResponseAcsCredentialsItemExternalType return &e } +type EntrancesListCredentialsWithAccessResponseAcsCredentialsItemVisionlineMetadata struct { + JoinerAcsCredentialIds []string `json:"joiner_acs_credential_ids,omitempty"` + + _rawJSON json.RawMessage +} + +func (e *EntrancesListCredentialsWithAccessResponseAcsCredentialsItemVisionlineMetadata) UnmarshalJSON(data []byte) error { + type unmarshaler EntrancesListCredentialsWithAccessResponseAcsCredentialsItemVisionlineMetadata + var value unmarshaler + if err := json.Unmarshal(data, &value); err != nil { + return err + } + *e = EntrancesListCredentialsWithAccessResponseAcsCredentialsItemVisionlineMetadata(value) + e._rawJSON = json.RawMessage(data) + return nil +} + +func (e *EntrancesListCredentialsWithAccessResponseAcsCredentialsItemVisionlineMetadata) String() string { + if len(e._rawJSON) > 0 { + if value, err := core.StringifyJSON(e._rawJSON); err == nil { + return value + } + } + if value, err := core.StringifyJSON(e); err == nil { + return value + } + return fmt.Sprintf("%#v", e) +} + type EntrancesListResponseAcsEntrancesItem struct { AcsEntranceId string `json:"acs_entrance_id"` DisplayName string `json:"display_name"` diff --git a/client/options.go b/client/options.go index 49a702f..e468d90 100644 --- a/client/options.go +++ b/client/options.go @@ -31,20 +31,13 @@ func WithHTTPHeader(httpHeader http.Header) core.ClientOption { } } -// WithApiKey sets the 'Authorization: Bearer ' header on every request. +// WithApiKey sets the apiKey auth header on every request. func WithApiKey(apiKey string) core.ClientOption { return func(opts *core.ClientOptions) { opts.ApiKey = apiKey } } -// WithSeamWorkspace sets the seamWorkspace header on every request. -func WithSeamWorkspace(seamWorkspace string) core.ClientOption { - return func(opts *core.ClientOptions) { - opts.SeamWorkspace = seamWorkspace - } -} - // WithSeamClientSessionToken sets the seamClientSessionToken header on every request. func WithSeamClientSessionToken(seamClientSessionToken string) core.ClientOption { return func(opts *core.ClientOptions) { diff --git a/connect_webviews.go b/connect_webviews.go index e7b8d1f..8458e85 100644 --- a/connect_webviews.go +++ b/connect_webviews.go @@ -70,6 +70,7 @@ const ( AcceptedProviderVisionline AcceptedProvider = "visionline" AcceptedProviderAssaAbloyCredentialService AcceptedProvider = "assa_abloy_credential_service" AcceptedProviderSeamBridge AcceptedProvider = "seam_bridge" + AcceptedProviderTedee AcceptedProvider = "tedee" AcceptedProviderYaleAccess AcceptedProvider = "yale_access" AcceptedProviderHidCm AcceptedProvider = "hid_cm" AcceptedProviderGoogleNest AcceptedProvider = "google_nest" @@ -145,6 +146,8 @@ func NewAcceptedProviderFromString(s string) (AcceptedProvider, error) { return AcceptedProviderAssaAbloyCredentialService, nil case "seam_bridge": return AcceptedProviderSeamBridge, nil + case "tedee": + return AcceptedProviderTedee, nil case "yale_access": return AcceptedProviderYaleAccess, nil case "hid_cm": diff --git a/core/client_option.go b/core/client_option.go index e50913c..eba9edb 100644 --- a/core/client_option.go +++ b/core/client_option.go @@ -18,7 +18,6 @@ type ClientOptions struct { HTTPClient HTTPClient HTTPHeader http.Header ApiKey string - SeamWorkspace string SeamClientSessionToken string ClientSessionToken string } @@ -37,10 +36,7 @@ func NewClientOptions() *ClientOptions { // on every request. func (c *ClientOptions) ToHeader() http.Header { header := c.cloneHeader() - if c.ApiKey != "" { - header.Set("Authorization", "Bearer "+c.ApiKey) - } - header.Set("seam-workspace", fmt.Sprintf("%v", c.SeamWorkspace)) + header.Set("seam-workspace", fmt.Sprintf("%v", c.ApiKey)) header.Set("seam-client-session-token", fmt.Sprintf("%v", c.SeamClientSessionToken)) header.Set("client-session-token", fmt.Sprintf("%v", c.ClientSessionToken)) return header @@ -50,6 +46,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.5") + headers.Set("X-Fern-SDK-Version", "v0.2.6") return headers }