mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
231 lines
6.0 KiB
Go
231 lines
6.0 KiB
Go
/*
|
|
Hanzo Cloud API
|
|
|
|
The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
|
|
|
|
API version: v1
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package hanzoai
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// checks if the SocialOrgApp type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &SocialOrgApp{}
|
|
|
|
// SocialOrgApp struct for SocialOrgApp
|
|
type SocialOrgApp struct {
|
|
// ClientID is the public app id, in the clear. The screen masks it.
|
|
ClientId *string `json:"clientId,omitempty"`
|
|
// Provider is the network: x, facebook, instagram, linkedin, tiktok, youtube or threads.
|
|
Provider *string `json:"provider,omitempty"`
|
|
// SecretSet is whether a secret is sealed for this app. The secret itself is not in this response.
|
|
SecretSet *bool `json:"secretSet,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _SocialOrgApp SocialOrgApp
|
|
|
|
// NewSocialOrgApp instantiates a new SocialOrgApp object
|
|
// This constructor will assign default values to properties that have it defined,
|
|
// and makes sure properties required by API are set, but the set of arguments
|
|
// will change when the set of required properties is changed
|
|
func NewSocialOrgApp() *SocialOrgApp {
|
|
this := SocialOrgApp{}
|
|
return &this
|
|
}
|
|
|
|
// NewSocialOrgAppWithDefaults instantiates a new SocialOrgApp object
|
|
// This constructor will only assign default values to properties that have it defined,
|
|
// but it doesn't guarantee that properties required by API are set
|
|
func NewSocialOrgAppWithDefaults() *SocialOrgApp {
|
|
this := SocialOrgApp{}
|
|
return &this
|
|
}
|
|
|
|
// GetClientId returns the ClientId field value if set, zero value otherwise.
|
|
func (o *SocialOrgApp) GetClientId() string {
|
|
if o == nil || IsNil(o.ClientId) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.ClientId
|
|
}
|
|
|
|
// GetClientIdOk returns a tuple with the ClientId field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SocialOrgApp) GetClientIdOk() (*string, bool) {
|
|
if o == nil || IsNil(o.ClientId) {
|
|
return nil, false
|
|
}
|
|
return o.ClientId, true
|
|
}
|
|
|
|
// HasClientId returns a boolean if a field has been set.
|
|
func (o *SocialOrgApp) HasClientId() bool {
|
|
if o != nil && !IsNil(o.ClientId) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetClientId gets a reference to the given string and assigns it to the ClientId field.
|
|
func (o *SocialOrgApp) SetClientId(v string) {
|
|
o.ClientId = &v
|
|
}
|
|
|
|
// GetProvider returns the Provider field value if set, zero value otherwise.
|
|
func (o *SocialOrgApp) GetProvider() string {
|
|
if o == nil || IsNil(o.Provider) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Provider
|
|
}
|
|
|
|
// GetProviderOk returns a tuple with the Provider field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SocialOrgApp) GetProviderOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Provider) {
|
|
return nil, false
|
|
}
|
|
return o.Provider, true
|
|
}
|
|
|
|
// HasProvider returns a boolean if a field has been set.
|
|
func (o *SocialOrgApp) HasProvider() bool {
|
|
if o != nil && !IsNil(o.Provider) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetProvider gets a reference to the given string and assigns it to the Provider field.
|
|
func (o *SocialOrgApp) SetProvider(v string) {
|
|
o.Provider = &v
|
|
}
|
|
|
|
// GetSecretSet returns the SecretSet field value if set, zero value otherwise.
|
|
func (o *SocialOrgApp) GetSecretSet() bool {
|
|
if o == nil || IsNil(o.SecretSet) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.SecretSet
|
|
}
|
|
|
|
// GetSecretSetOk returns a tuple with the SecretSet field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SocialOrgApp) GetSecretSetOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.SecretSet) {
|
|
return nil, false
|
|
}
|
|
return o.SecretSet, true
|
|
}
|
|
|
|
// HasSecretSet returns a boolean if a field has been set.
|
|
func (o *SocialOrgApp) HasSecretSet() bool {
|
|
if o != nil && !IsNil(o.SecretSet) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetSecretSet gets a reference to the given bool and assigns it to the SecretSet field.
|
|
func (o *SocialOrgApp) SetSecretSet(v bool) {
|
|
o.SecretSet = &v
|
|
}
|
|
|
|
func (o SocialOrgApp) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o SocialOrgApp) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.ClientId) {
|
|
toSerialize["clientId"] = o.ClientId
|
|
}
|
|
if !IsNil(o.Provider) {
|
|
toSerialize["provider"] = o.Provider
|
|
}
|
|
if !IsNil(o.SecretSet) {
|
|
toSerialize["secretSet"] = o.SecretSet
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *SocialOrgApp) UnmarshalJSON(data []byte) (err error) {
|
|
varSocialOrgApp := _SocialOrgApp{}
|
|
|
|
err = json.Unmarshal(data, &varSocialOrgApp)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = SocialOrgApp(varSocialOrgApp)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "clientId")
|
|
delete(additionalProperties, "provider")
|
|
delete(additionalProperties, "secretSet")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableSocialOrgApp struct {
|
|
value *SocialOrgApp
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableSocialOrgApp) Get() *SocialOrgApp {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableSocialOrgApp) Set(val *SocialOrgApp) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableSocialOrgApp) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableSocialOrgApp) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableSocialOrgApp(val *SocialOrgApp) *NullableSocialOrgApp {
|
|
return &NullableSocialOrgApp{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableSocialOrgApp) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableSocialOrgApp) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|