diff --git a/client/client.go b/client/client.go index 4473fac..4d3f37b 100644 --- a/client/client.go +++ b/client/client.go @@ -2,6 +2,7 @@ package client import ( "github.com/infobloxopen/bloxone-go-client/anycast" + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" "github.com/infobloxopen/bloxone-go-client/dfp" "github.com/infobloxopen/bloxone-go-client/dnsconfig" "github.com/infobloxopen/bloxone-go-client/dnsdata" @@ -18,18 +19,19 @@ import ( // APIClient is an aggregation of different BloxOne API clients. type APIClient struct { - IPAddressManagementAPI *ipam.APIClient - IPAMFederationAPI *ipamfederation.APIClient - DNSConfigurationAPI *dnsconfig.APIClient - DNSDataAPI *dnsdata.APIClient - HostActivationAPI *infraprovision.APIClient - InfraManagementAPI *inframgmt.APIClient - KeysAPI *keys.APIClient - DNSForwardingProxyAPI *dfp.APIClient - FWAPI *fw.APIClient - AnycastAPI *anycast.APIClient - RedirectAPI *redirect.APIClient - UpgradePolicyClientAPI *upgradepolicy.APIClient + IPAddressManagementAPI *ipam.APIClient + IPAMFederationAPI *ipamfederation.APIClient + DiscoveryConfigurationAPIV2 *clouddiscovery.APIClient + DNSConfigurationAPI *dnsconfig.APIClient + DNSDataAPI *dnsdata.APIClient + HostActivationAPI *infraprovision.APIClient + InfraManagementAPI *inframgmt.APIClient + KeysAPI *keys.APIClient + DNSForwardingProxyAPI *dfp.APIClient + FWAPI *fw.APIClient + AnycastAPI *anycast.APIClient + RedirectAPI *redirect.APIClient + UpgradePolicyClientAPI *upgradepolicy.APIClient } // NewAPIClient creates a new BloxOne API Client. @@ -37,6 +39,7 @@ type APIClient struct { // The following clients are available: // - IPAddressManagementAPI // - IPAMFederationAPI +// - DiscoveryConfigurationAPIV2 // - DNSConfigurationAPI // - DNSDataAPI // - HostActivationAPI @@ -56,17 +59,18 @@ type APIClient struct { // - WithDebug() sets the debug mode. func NewAPIClient(options ...option.ClientOption) *APIClient { return &APIClient{ - IPAddressManagementAPI: ipam.NewAPIClient(options...), - IPAMFederationAPI: ipamfederation.NewAPIClient(options...), - DNSConfigurationAPI: dnsconfig.NewAPIClient(options...), - DNSDataAPI: dnsdata.NewAPIClient(options...), - HostActivationAPI: infraprovision.NewAPIClient(options...), - InfraManagementAPI: inframgmt.NewAPIClient(options...), - KeysAPI: keys.NewAPIClient(options...), - DNSForwardingProxyAPI: dfp.NewAPIClient(options...), - FWAPI: fw.NewAPIClient(options...), - AnycastAPI: anycast.NewAPIClient(options...), - RedirectAPI: redirect.NewAPIClient(options...), - UpgradePolicyClientAPI: upgradepolicy.NewAPIClient(options...), + IPAddressManagementAPI: ipam.NewAPIClient(options...), + IPAMFederationAPI: ipamfederation.NewAPIClient(options...), + DiscoveryConfigurationAPIV2: clouddiscovery.NewAPIClient(options...), + DNSConfigurationAPI: dnsconfig.NewAPIClient(options...), + DNSDataAPI: dnsdata.NewAPIClient(options...), + HostActivationAPI: infraprovision.NewAPIClient(options...), + InfraManagementAPI: inframgmt.NewAPIClient(options...), + KeysAPI: keys.NewAPIClient(options...), + DNSForwardingProxyAPI: dfp.NewAPIClient(options...), + FWAPI: fw.NewAPIClient(options...), + AnycastAPI: anycast.NewAPIClient(options...), + RedirectAPI: redirect.NewAPIClient(options...), + UpgradePolicyClientAPI: upgradepolicy.NewAPIClient(options...), } } diff --git a/clouddiscovery/.openapi-generator-ignore b/clouddiscovery/.openapi-generator-ignore new file mode 100644 index 0000000..7484ee5 --- /dev/null +++ b/clouddiscovery/.openapi-generator-ignore @@ -0,0 +1,23 @@ +# OpenAPI Generator Ignore +# Generated by openapi-generator https://github.com/openapitools/openapi-generator + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/clouddiscovery/.openapi-generator/FILES b/clouddiscovery/.openapi-generator/FILES new file mode 100644 index 0000000..f6117cd --- /dev/null +++ b/clouddiscovery/.openapi-generator/FILES @@ -0,0 +1,58 @@ +README.md +api/openapi.yaml +api_accounts.go +api_providers.go +api_sub_accounts.go +client.go +docs/Account.md +docs/AccountListResponse.md +docs/AccountsAPI.md +docs/AdditionalConfig.md +docs/ApiPageInfo.md +docs/Category.md +docs/CredentialConfig.md +docs/CredentialPreference.md +docs/DNSConfig.md +docs/Destination.md +docs/DestinationConfig.md +docs/DiscoveryConfig.md +docs/IPAMConfig.md +docs/Object.md +docs/ObjectType.md +docs/ProviderCreateResponse.md +docs/ProviderListResponse.md +docs/ProviderReadResponse.md +docs/ProviderUpdateResponse.md +docs/ProvidersAPI.md +docs/Resource.md +docs/SourceConfig.md +docs/SubAccountListRequestV2.md +docs/SubAccountListResponseV2.md +docs/SubAccountProvCredConfig.md +docs/SubAccountV2.md +docs/SubAccountsAPI.md +model_account.go +model_account_list_response.go +model_additional_config.go +model_api_page_info.go +model_category.go +model_credential_config.go +model_credential_preference.go +model_destination.go +model_destination_config.go +model_discovery_config.go +model_dns_config.go +model_ipam_config.go +model_object.go +model_object_type.go +model_provider_create_response.go +model_provider_list_response.go +model_provider_read_response.go +model_provider_update_response.go +model_resource.go +model_source_config.go +model_sub_account_list_request_v2.go +model_sub_account_list_response_v2.go +model_sub_account_prov_cred_config.go +model_sub_account_v2.go +utils.go diff --git a/clouddiscovery/.openapi-generator/VERSION b/clouddiscovery/.openapi-generator/VERSION new file mode 100644 index 0000000..18bb418 --- /dev/null +++ b/clouddiscovery/.openapi-generator/VERSION @@ -0,0 +1 @@ +7.5.0 diff --git a/clouddiscovery/README.md b/clouddiscovery/README.md new file mode 100644 index 0000000..85d87d3 --- /dev/null +++ b/clouddiscovery/README.md @@ -0,0 +1,143 @@ +# Go API client for Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets + +Base Paths: +1. provider: **_/api/cloud_discovery/v2/_** + + +## Overview +This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client. + +- API version: v2 +- Generator version: 7.5.0 +- Build package: com.infoblox.codegen.BloxoneGoClientCodegen + +## Installation + +Install the package using `go get`: +```bash +go get github.com/infobloxopen/bloxone-go-client/clouddiscovery +``` + +Import the package into your code: +```go +import "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +``` + +To use a proxy, set the environment variable `HTTP_PROXY`: + +```go +os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port") +``` + +To create a new API client, you can use the `NewAPIClient` function as shown below +```go +client := clouddiscovery.NewAPIClient() +``` + +## Configuration + +The `NewAPIClient` function accepts a variadic list of `option.ClientOption` functions that can be used to configure the client. +It requires the `option` package to be imported. You can import the package using: +```go +import "github.com/infobloxopen/bloxone-go-client/option" +``` + +### Client Name +The client name is used to identify the client in the logs. By default, the client name is set to `bloxone-go-client`. You can change this using the `option.WithClientName` option. For example: +```go +client := clouddiscovery.NewAPIClient(option.WithClientName("my-client")) +``` + +### Server URL + +The default URL for the Cloud Services Portal is `https://csp.infoblox.com`. If you need to change this, you can use `option.WithCSPUrl` to set the URL. For example: + +```go +client := clouddiscovery.NewAPIClient(option.WithCSPUrl("https://csp.eu.infoblox.com")) +``` + +You can also set the URL using the environment variable `BLOXONE_CSP_URL` + +### Authorization + +An API key is required to access Discovery Configuration API V2. You can obtain an API key by following the instructions in the guide for [Configuring User API Keys](https://docs.infoblox.com/space/BloxOneCloud/35430405/Configuring+User+API+Keys). + +To use an API key with Discovery Configuration API V2, you can use the `option.WithAPIKey` option. For example: + +```go +client := clouddiscovery.NewAPIClient(option.WithAPIKey("YOUR_API_KEY")) +``` + +You can also set the API key using the environment variable `BLOXONE_API_KEY` + +Note: The API key is a secret and should be handled securely. Hardcoding the API key in your code is not recommended. + +### Default Tags + +You can set default tags for all API requests using the `option.WithDefaultTags` option. For example: + +```go +client := clouddiscovery.NewAPIClient(option.WithDefaultTags(map[string]string{"tag1": "value1", "tag2": "value2"})) +``` +This will add the tags `tag1=value1` and `tag2=value2` to all API requests that support tags in the request body. + +## Documentation for API Endpoints + +All URIs are relative to *http://csp.infoblox.com/api/cloud_discovery/v2* + +Class | Method | HTTP request | Description +------------ | ------------- | ------------- | ------------- +*AccountsAPI* | [**List**](docs/AccountsAPI.md#list) | **Get** /accounts | List Accounts +*ProvidersAPI* | [**Create**](docs/ProvidersAPI.md#create) | **Post** /providers | Create Provider +*ProvidersAPI* | [**Delete**](docs/ProvidersAPI.md#delete) | **Delete** /providers/{id} | Delete Provider +*ProvidersAPI* | [**List**](docs/ProvidersAPI.md#list) | **Get** /providers | List Provider +*ProvidersAPI* | [**Read**](docs/ProvidersAPI.md#read) | **Get** /providers/{id} | Read Provider +*ProvidersAPI* | [**Update**](docs/ProvidersAPI.md#update) | **Put** /providers/{id} | Update Provider +*SubAccountsAPI* | [**List**](docs/SubAccountsAPI.md#list) | **Post** /sub_accounts | List Sub-accounts + + +## Documentation For Models + + - [Account](docs/Account.md) + - [AccountListResponse](docs/AccountListResponse.md) + - [AdditionalConfig](docs/AdditionalConfig.md) + - [ApiPageInfo](docs/ApiPageInfo.md) + - [Category](docs/Category.md) + - [CredentialConfig](docs/CredentialConfig.md) + - [CredentialPreference](docs/CredentialPreference.md) + - [DNSConfig](docs/DNSConfig.md) + - [Destination](docs/Destination.md) + - [DestinationConfig](docs/DestinationConfig.md) + - [DiscoveryConfig](docs/DiscoveryConfig.md) + - [IPAMConfig](docs/IPAMConfig.md) + - [Object](docs/Object.md) + - [ObjectType](docs/ObjectType.md) + - [ProviderCreateResponse](docs/ProviderCreateResponse.md) + - [ProviderListResponse](docs/ProviderListResponse.md) + - [ProviderReadResponse](docs/ProviderReadResponse.md) + - [ProviderUpdateResponse](docs/ProviderUpdateResponse.md) + - [Resource](docs/Resource.md) + - [SourceConfig](docs/SourceConfig.md) + - [SubAccountListRequestV2](docs/SubAccountListRequestV2.md) + - [SubAccountListResponseV2](docs/SubAccountListResponseV2.md) + - [SubAccountProvCredConfig](docs/SubAccountProvCredConfig.md) + - [SubAccountV2](docs/SubAccountV2.md) + + +## Documentation for Utility Methods + +Due to the fact that model structure members are all pointers, this package contains +a number of utility functions to easily obtain pointers to values of basic types. +Each of these functions takes a value of the given basic type and returns a pointer to it: + +* `PtrBool` +* `PtrInt` +* `PtrInt32` +* `PtrInt64` +* `PtrFloat` +* `PtrFloat32` +* `PtrFloat64` +* `PtrString` +* `PtrTime` diff --git a/clouddiscovery/api/openapi.yaml b/clouddiscovery/api/openapi.yaml new file mode 100644 index 0000000..a7bb103 --- /dev/null +++ b/clouddiscovery/api/openapi.yaml @@ -0,0 +1,2111 @@ +openapi: 3.0.1 +info: + description: "The Discovery configuration service is a BloxOne Service that provides\ + \ configuration for accessing and syncing the Cloud assets \n\nBase Paths: \n\ + 1. provider: **/api/cloud_discovery/v2/** \n" + title: Discovery Configuration API V2 + version: v2 +servers: +- url: http://csp.infoblox.com/api/cloud_discovery/v2 +- url: https://csp.infoblox.com/api/cloud_discovery/v2 +security: +- ApiKeyAuth: [] +paths: + /accounts: + get: + description: Use this method to list Accounts + operationId: AccountsList + parameters: + - description: "\n\nA collection of response resources can be transformed by\ + \ specifying a set of JSON tags to be returned. For a “flat” resource, the\ + \ tag name is straightforward. If field selection is allowed on non-flat\ + \ hierarchical resources, the service should implement a qualified naming\ + \ scheme such as dot-qualification to reference data down the hierarchy.\ + \ If a resource does not have the specified tag, the tag does not appear\ + \ in the output resource.\n\nSpecify this parameter as a comma-separated\ + \ list of JSON tag names.\n\n\t\t\t\t\t\t" + in: query + name: _fields + schema: + type: string + - description: "\n\nA collection of response resources can be filtered by a\ + \ logical expression string that includes JSON tag references to values\ + \ in each resource, literal values, and logical operators. If a resource\ + \ does not have the specified tag, its value is assumed to be null.\n\n\ + Literal values include numbers (integer and floating-point), and quoted\ + \ (both single- or double-quoted) literal strings, and 'null'. The following\ + \ operators are commonly used in filter expressions:\n\n| Op | Description\ + \ | \n| -- | ----------- | \n| == | \ + \ Equal | \n| != | Not Equal | \n\ + | > | Greater Than | \n| >= | Greater Than or Equal\ + \ To | \n| < | Less Than | \n| <= | Less Than\ + \ or Equal To | \n| and | Logical AND | \n| ~ |\ + \ Matches Regex | \n| !~ | Does Not Match Regex |\ + \ \n| or | Logical OR | \n| not | Logical NOT \ + \ | \n| () | Groupping Operators |\n\n\t\t\t\t\t\t" + in: query + name: _filter + schema: + type: string + - description: "\n\nThe integer index (zero-origin) of the offset into a collection\ + \ of resources. If omitted or null the value is assumed to be '0'.\n\n\t\ + \t\t\t\t\t\t" + in: query + name: _offset + schema: + type: integer + - description: "\n\nThe integer number of resources to be returned in the response.\ + \ The service may impose maximum value. If omitted the service may impose\ + \ a default value.\n\n\t\t\t\t\t\t\t" + in: query + name: _limit + schema: + type: integer + - description: "\n\nThe service-defined string used to identify a page of resources.\ + \ A null value indicates the first page.\n\n\t\t\t\t\t\t\t" + in: query + name: _page_token + schema: + type: string + - description: "\n\nA collection of response resources can be sorted by their\ + \ JSON tags. For a 'flat' resource, the tag name is straightforward. If\ + \ sorting is allowed on non-flat hierarchical resources, the service should\ + \ implement a qualified naming scheme such as dot-qualification to reference\ + \ data down the hierarchy. If a resource does not have the specified tag,\ + \ its value is assumed to be null.)\n\nSpecify this parameter as a comma-separated\ + \ list of JSON tag names. The sort direction can be specified by a suffix\ + \ separated by whitespace before the tag name. The suffix 'asc' sorts the\ + \ data in ascending order. The suffix 'desc' sorts the data in descending\ + \ order. If no suffix is specified the data is sorted in ascending order.\n\ + \n\t\t\t\t\t\t" + in: query + name: _order_by + schema: + type: string + - description: This parameter is used for filtering by tags. + in: query + name: _tfilter + schema: + type: string + - description: This parameter is used for sorting by tags. + in: query + name: _torder_by + schema: + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsAccountListResponse' + description: GET operation response + summary: List Accounts + tags: + - Accounts + /providers: + get: + description: Use this method to list Provider + operationId: ProvidersList + parameters: + - description: "\n\nA collection of response resources can be transformed by\ + \ specifying a set of JSON tags to be returned. For a “flat” resource, the\ + \ tag name is straightforward. If field selection is allowed on non-flat\ + \ hierarchical resources, the service should implement a qualified naming\ + \ scheme such as dot-qualification to reference data down the hierarchy.\ + \ If a resource does not have the specified tag, the tag does not appear\ + \ in the output resource.\n\nSpecify this parameter as a comma-separated\ + \ list of JSON tag names.\n\n\t\t\t\t\t\t" + in: query + name: _fields + schema: + type: string + - description: "\n\nA collection of response resources can be filtered by a\ + \ logical expression string that includes JSON tag references to values\ + \ in each resource, literal values, and logical operators. If a resource\ + \ does not have the specified tag, its value is assumed to be null.\n\n\ + Literal values include numbers (integer and floating-point), and quoted\ + \ (both single- or double-quoted) literal strings, and 'null'. The following\ + \ operators are commonly used in filter expressions:\n\n| Op | Description\ + \ | \n| -- | ----------- | \n| == | \ + \ Equal | \n| != | Not Equal | \n\ + | > | Greater Than | \n| >= | Greater Than or Equal\ + \ To | \n| < | Less Than | \n| <= | Less Than\ + \ or Equal To | \n| and | Logical AND | \n| ~ |\ + \ Matches Regex | \n| !~ | Does Not Match Regex |\ + \ \n| or | Logical OR | \n| not | Logical NOT \ + \ | \n| () | Groupping Operators |\n\n\t\t\t\t\t\t" + in: query + name: _filter + schema: + type: string + - description: "\n\nThe integer index (zero-origin) of the offset into a collection\ + \ of resources. If omitted or null the value is assumed to be '0'.\n\n\t\ + \t\t\t\t\t\t" + in: query + name: _offset + schema: + type: integer + - description: "\n\nThe integer number of resources to be returned in the response.\ + \ The service may impose maximum value. If omitted the service may impose\ + \ a default value.\n\n\t\t\t\t\t\t\t" + in: query + name: _limit + schema: + type: integer + - description: "\n\nThe service-defined string used to identify a page of resources.\ + \ A null value indicates the first page.\n\n\t\t\t\t\t\t\t" + in: query + name: _page_token + schema: + type: string + - description: "\n\nA collection of response resources can be sorted by their\ + \ JSON tags. For a 'flat' resource, the tag name is straightforward. If\ + \ sorting is allowed on non-flat hierarchical resources, the service should\ + \ implement a qualified naming scheme such as dot-qualification to reference\ + \ data down the hierarchy. If a resource does not have the specified tag,\ + \ its value is assumed to be null.)\n\nSpecify this parameter as a comma-separated\ + \ list of JSON tag names. The sort direction can be specified by a suffix\ + \ separated by whitespace before the tag name. The suffix 'asc' sorts the\ + \ data in ascending order. The suffix 'desc' sorts the data in descending\ + \ order. If no suffix is specified the data is sorted in ascending order.\n\ + \n\t\t\t\t\t\t" + in: query + name: _order_by + schema: + type: string + - description: This parameter is used for filtering by tags. + in: query + name: _tfilter + schema: + type: string + - description: This parameter is used for sorting by tags. + in: query + name: _torder_by + schema: + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsProviderListResponse' + description: GET operation response + summary: List Provider + tags: + - Providers + post: + description: Use this method to create Provider + operationId: ProvidersCreate + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsDiscoveryConfig' + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsProviderCreateResponse' + description: POST operation response + summary: Create Provider + tags: + - Providers + x-sdk-default-tags: true + x-codegen-request-body-name: body + /providers/{id}: + delete: + description: Use this method to delete Provider + operationId: ProvidersDelete + parameters: + - in: path + name: id + required: true + schema: + type: string + responses: + "204": + content: {} + description: No Content + summary: Delete Provider + tags: + - Providers + get: + description: Use this method to retrieve a single Provider by ID + operationId: ProvidersRead + parameters: + - in: path + name: id + required: true + schema: + type: string + - description: "\n\nA collection of response resources can be transformed by\ + \ specifying a set of JSON tags to be returned. For a “flat” resource, the\ + \ tag name is straightforward. If field selection is allowed on non-flat\ + \ hierarchical resources, the service should implement a qualified naming\ + \ scheme such as dot-qualification to reference data down the hierarchy.\ + \ If a resource does not have the specified tag, the tag does not appear\ + \ in the output resource.\n\nSpecify this parameter as a comma-separated\ + \ list of JSON tag names.\n\n\t\t\t\t\t\t" + in: query + name: _fields + schema: + type: string + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsProviderReadResponse' + description: GET operation response + summary: Read Provider + tags: + - Providers + put: + description: Use this method to update Provider + operationId: ProvidersUpdate + parameters: + - description: Auto-generated unique discovery config ID. Format BloxID. + in: path + name: id + required: true + schema: + type: string + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsDiscoveryConfig' + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsProviderUpdateResponse' + description: PUT operation response + summary: Update Provider + tags: + - Providers + x-sdk-default-tags: true + x-codegen-request-body-name: body + /sub_accounts: + post: + description: Use this method to list Sub-accounts + operationId: sub_accountsList + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsSubAccountListRequestV2' + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/ddidnsrickettsSubAccountListResponseV2' + description: POST operation response + summary: List Sub-accounts + tags: + - sub_accounts + x-codegen-request-body-name: body +components: + schemas: + apiPageInfo: + description: |- + PageInfo represents both server-driven and client-driven pagination response. + Server-driven pagination is a model in which the server returns some + amount of data along with an token indicating there is more data + and where subsequent queries can get the next page of data. + Client-driven pagination is a model in which rows are addressable by + offset and page size (limit). + example: + offset: 0 + size: 6 + page_token: page_token + properties: + offset: + description: |- + The service may optionally include the offset of the next page of resources. + A null value indicates no more pages. + format: int32 + type: integer + page_token: + description: |- + The service response should contain a string to indicate + the next page of resources. + A null value indicates no more pages. + type: string + size: + description: The service may optionally include the total number of resources + being paged. + format: int32 + type: integer + type: object + ddidnsrickettsAccount: + description: Source account information + example: + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + properties: + composite_status: + title: combined status of the account and the all the destinations statuses + type: string + composite_status_message: + description: Status message of the sync operation. + type: string + created_at: + description: Timestamp when the object has been created. + format: date-time + readOnly: true + type: string + deleted_at: + description: Timestamp when the object has been deleted. + format: date-time + readOnly: true + type: string + dhcp_server_id: + readOnly: true + title: DHCP Server ID. MSAD case + type: string + dns_server_id: + description: DNS Server ID. + readOnly: true + type: string + id: + description: Auto-generated unique source account ID. Format BloxID. + readOnly: true + type: string + last_successful_sync: + description: Last successful sync timestamp. + format: date-time + readOnly: true + type: string + last_sync: + description: Last sync timestamp. + format: date-time + readOnly: true + type: string + name: + description: Name of the source account. + type: string + parent_id: + description: Parent ID. + type: string + percent_complete: + description: Sync progress as a percentage. + format: int32 + readOnly: true + type: integer + provider_account_id: + title: "Provider Account ID value, such as aws account_id, azure subscription_id,\ + \ gcp project_id" + type: string + schedule_id: + description: Schedule ID. + readOnly: true + type: string + state: + readOnly: true + title: "State represents the current state of the account, ex.: authorized,\ + \ unauthorized, excluded, disabled" + type: string + status: + description: Status of the sync operation. + readOnly: true + type: string + status_message: + description: Status message of the sync operation. + readOnly: true + type: string + updated_at: + description: Timestamp when the object has been updated. + format: date-time + readOnly: true + type: string + required: + - name + title: Account + type: object + ddidnsrickettsAccountListResponse: + description: The Account object List response format. + example: + page: + offset: 0 + size: 6 + page_token: page_token + results: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + properties: + page: + $ref: '#/components/schemas/apiPageInfo' + results: + items: + $ref: '#/components/schemas/ddidnsrickettsAccount' + type: array + title: AccountListResponse + type: object + ddidnsrickettsAdditionalConfig: + example: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + properties: + excluded_accounts: + items: + type: string + title: excluded_accounts + type: array + forward_zone_enabled: + format: boolean + title: zone_forwarding refers to forwarding zone feature enabled or disabled. + values "true" or "false" + type: boolean + internal_ranges_enabled: + format: boolean + title: manage internal ranges for cloud provider GCP + type: boolean + object_type: + $ref: '#/components/schemas/ddidnsrickettsObjectType' + title: AdditionalConfig + type: object + ddidnsrickettsCategory: + description: Category ... + example: + excluded: true + id: id + properties: + excluded: + format: boolean + type: boolean + id: + readOnly: true + type: string + type: object + ddidnsrickettsCredentialConfig: + example: + access_identifier: access_identifier + region: region + enclave: enclave + properties: + access_identifier: + title: "access_identifier values: role_arn_1, tenant_id_123,project_id_123" + type: string + enclave: + title: enclave define whether its commercial or govt cloud + type: string + region: + title: region values for aws + type: string + title: CredentialConfig defines the credential configuration in source_configs + type: object + ddidnsrickettsCredentialPreference: + example: + credential_type: credential_type + access_identifier_type: access_identifier_type + properties: + access_identifier_type: + title: "access_identifier constants: role_id, tenant_id,project_id" + type: string + credential_type: + title: credential_type static or dynamic + type: string + title: CredentialPreference defines the credential preferences for the user + type: object + ddidnsrickettsDNSConfig: + example: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + properties: + consolidated_zone_data_enabled: + format: boolean + title: consolidated_zone_data_enabled consolidates public & private zones + into a single view + type: boolean + split_view_enabled: + description: "split_view_enabled consolidates private zones into a single\ + \ view, which is separate from the public zone view." + format: boolean + type: boolean + sync_type: + title: "sync_type values: \"read_only\", \"read_write\"" + type: string + view_id: + type: string + view_name: + type: string + type: object + ddidnsrickettsDestination: + description: Destination information + example: + destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + properties: + config: + $ref: '#/components/schemas/ddidnsrickettsDestinationConfig' + created_at: + description: Timestamp when the object has been created. + format: date-time + readOnly: true + type: string + deleted_at: + description: Timestamp when the object has been deleted. + format: date-time + readOnly: true + type: string + destination_type: + description: "Destination type: DNS / IPAM / ACCOUNT." + type: string + id: + description: Auto-generated unique destination ID. Format BloxID. + readOnly: true + type: string + updated_at: + description: Timestamp when the object has been updated. + format: date-time + readOnly: true + type: string + required: + - destination_type + title: Destination + type: object + ddidnsrickettsDestinationConfig: + example: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + properties: + dns: + $ref: '#/components/schemas/ddidnsrickettsDNSConfig' + ipam: + $ref: '#/components/schemas/ddidnsrickettsIPAMConfig' + title: DestinationConfig defines the destination configuration represented as + json object + type: object + ddidnsrickettsDiscoveryConfig: + description: Discovery configuration + example: + provider_type: provider_type + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + destinations: + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + description: description + account_preference: account_preference + desired_state: desired_state + sync_interval: sync_interval + deleted_at: 2000-01-23T04:56:07.000+00:00 + destination_types_enabled: + - destination_types_enabled + - destination_types_enabled + source_configs: + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + additional_config: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + tags: "{}" + updated_at: 2000-01-23T04:56:07.000+00:00 + credential_preference: + credential_type: credential_type + access_identifier_type: access_identifier_type + name: name + id: id + status: status + properties: + account_preference: + description: "Account preference. For ex.: single, multiple, auto-discover-multiple." + type: string + additional_config: + $ref: '#/components/schemas/ddidnsrickettsAdditionalConfig' + created_at: + description: Timestamp when the object has been created. + format: date-time + readOnly: true + type: string + credential_preference: + $ref: '#/components/schemas/ddidnsrickettsCredentialPreference' + deleted_at: + description: Timestamp when the object has been deleted. + format: date-time + readOnly: true + type: string + description: + description: Description of the discovery config. Optional. + type: string + desired_state: + description: Desired state. Default is "enabled". + type: string + destination_types_enabled: + description: "Destinations types enabled: Ex.: DNS, IPAM and ACCOUNT." + items: + type: string + type: array + destinations: + description: Destinations. + items: + $ref: '#/components/schemas/ddidnsrickettsDestination' + type: array + id: + description: Auto-generated unique discovery config ID. Format BloxID. + readOnly: true + type: string + last_sync: + description: Last sync timestamp. + format: date-time + type: string + name: + description: Name of the discovery config. + type: string + provider_type: + description: "Provider type. Ex.: Amazon Web Services, Google Cloud Platform,\ + \ Microsoft Azure." + type: string + source_configs: + description: Source configs. + items: + $ref: '#/components/schemas/ddidnsrickettsSourceConfig' + type: array + status: + description: |- + Status of the sync operation. + In single account case, Its the combined status of account & all the destinations statuses + In auto discover case, Its the status of the account discovery only. + type: string + status_message: + description: Aggregate status message of the sync operation. + type: string + sync_interval: + title: "Time between sync jobs in minutes. Default is \"Auto\". Other supported\ + \ values: 15, 30, 60, 120, 180, 240, 360, 480, 720, 1440" + type: string + tags: + additionalProperties: false + description: Tagging specifics. + type: object + updated_at: + description: Timestamp when the object has been updated. + format: date-time + readOnly: true + type: string + required: + - name + title: DiscoveryConfig + type: object + ddidnsrickettsIPAMConfig: + example: + ip_space: ip_space + dhcp_server: dhcp_server + properties: + dhcp_server: + type: string + ip_space: + type: string + type: object + ddidnsrickettsObject: + example: + resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + properties: + category: + $ref: '#/components/schemas/ddidnsrickettsCategory' + resource_set: + items: + $ref: '#/components/schemas/ddidnsrickettsResource' + type: array + title: Object + type: object + ddidnsrickettsObjectType: + example: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + properties: + discover_new: + format: boolean + type: boolean + objects: + items: + $ref: '#/components/schemas/ddidnsrickettsObject' + type: array + version: + format: float + type: number + type: object + ddidnsrickettsProviderCreateResponse: + description: The Provider object create response format. + example: + result: + provider_type: provider_type + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + destinations: + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + description: description + account_preference: account_preference + desired_state: desired_state + sync_interval: sync_interval + deleted_at: 2000-01-23T04:56:07.000+00:00 + destination_types_enabled: + - destination_types_enabled + - destination_types_enabled + source_configs: + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + additional_config: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + tags: "{}" + updated_at: 2000-01-23T04:56:07.000+00:00 + credential_preference: + credential_type: credential_type + access_identifier_type: access_identifier_type + name: name + id: id + status: status + properties: + result: + $ref: '#/components/schemas/ddidnsrickettsDiscoveryConfig' + title: ProviderCreateResponse + type: object + ddidnsrickettsProviderListResponse: + description: The Provider object List response format. + example: + page: + offset: 0 + size: 6 + page_token: page_token + results: + - provider_type: provider_type + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + destinations: + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + description: description + account_preference: account_preference + desired_state: desired_state + sync_interval: sync_interval + deleted_at: 2000-01-23T04:56:07.000+00:00 + destination_types_enabled: + - destination_types_enabled + - destination_types_enabled + source_configs: + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + additional_config: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + tags: "{}" + updated_at: 2000-01-23T04:56:07.000+00:00 + credential_preference: + credential_type: credential_type + access_identifier_type: access_identifier_type + name: name + id: id + status: status + - provider_type: provider_type + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + destinations: + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + description: description + account_preference: account_preference + desired_state: desired_state + sync_interval: sync_interval + deleted_at: 2000-01-23T04:56:07.000+00:00 + destination_types_enabled: + - destination_types_enabled + - destination_types_enabled + source_configs: + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + additional_config: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + tags: "{}" + updated_at: 2000-01-23T04:56:07.000+00:00 + credential_preference: + credential_type: credential_type + access_identifier_type: access_identifier_type + name: name + id: id + status: status + properties: + page: + $ref: '#/components/schemas/apiPageInfo' + results: + items: + $ref: '#/components/schemas/ddidnsrickettsDiscoveryConfig' + type: array + title: ProviderListResponse + type: object + ddidnsrickettsProviderReadResponse: + description: The Provider object read response format. + example: + result: + provider_type: provider_type + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + destinations: + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + description: description + account_preference: account_preference + desired_state: desired_state + sync_interval: sync_interval + deleted_at: 2000-01-23T04:56:07.000+00:00 + destination_types_enabled: + - destination_types_enabled + - destination_types_enabled + source_configs: + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + additional_config: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + tags: "{}" + updated_at: 2000-01-23T04:56:07.000+00:00 + credential_preference: + credential_type: credential_type + access_identifier_type: access_identifier_type + name: name + id: id + status: status + properties: + result: + $ref: '#/components/schemas/ddidnsrickettsDiscoveryConfig' + title: ProviderReadResponse + type: object + ddidnsrickettsProviderUpdateResponse: + description: The Provider object to update response format. + example: + result: + provider_type: provider_type + status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + destinations: + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + - destination_type: destination_type + updated_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + id: id + config: + ipam: + ip_space: ip_space + dhcp_server: dhcp_server + dns: + split_view_enabled: true + sync_type: sync_type + view_id: view_id + consolidated_zone_data_enabled: true + view_name: view_name + deleted_at: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + description: description + account_preference: account_preference + desired_state: desired_state + sync_interval: sync_interval + deleted_at: 2000-01-23T04:56:07.000+00:00 + destination_types_enabled: + - destination_types_enabled + - destination_types_enabled + source_configs: + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + - updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + additional_config: + object_type: + objects: + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + - resource_set: + - excluded: true + id: id + - excluded: true + id: id + category: + excluded: true + id: id + version: 0.8008282 + discover_new: true + excluded_accounts: + - excluded_accounts + - excluded_accounts + internal_ranges_enabled: true + forward_zone_enabled: true + tags: "{}" + updated_at: 2000-01-23T04:56:07.000+00:00 + credential_preference: + credential_type: credential_type + access_identifier_type: access_identifier_type + name: name + id: id + status: status + properties: + result: + $ref: '#/components/schemas/ddidnsrickettsDiscoveryConfig' + title: ProviderUpdateResponse + type: object + ddidnsrickettsResource: + example: + excluded: true + id: id + properties: + excluded: + format: boolean + type: boolean + id: + readOnly: true + type: string + title: Resource + type: object + ddidnsrickettsSourceConfig: + description: Source configuration + example: + updated_at: 2000-01-23T04:56:07.000+00:00 + account_schedule_id: account_schedule_id + credential_config: + access_identifier: access_identifier + region: region + enclave: enclave + cloud_credential_id: cloud_credential_id + created_at: 2000-01-23T04:56:07.000+00:00 + restricted_to_accounts: + - restricted_to_accounts + - restricted_to_accounts + accounts: + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + - status_message: status_message + last_sync: 2000-01-23T04:56:07.000+00:00 + created_at: 2000-01-23T04:56:07.000+00:00 + composite_status: composite_status + deleted_at: 2000-01-23T04:56:07.000+00:00 + percent_complete: 1 + last_successful_sync: 2000-01-23T04:56:07.000+00:00 + dhcp_server_id: dhcp_server_id + provider_account_id: provider_account_id + updated_at: 2000-01-23T04:56:07.000+00:00 + parent_id: parent_id + name: name + id: id + state: state + composite_status_message: composite_status_message + dns_server_id: dns_server_id + schedule_id: schedule_id + status: status + id: id + deleted_at: 2000-01-23T04:56:07.000+00:00 + properties: + account_schedule_id: + description: Account Schedule ID. + readOnly: true + type: string + accounts: + items: + $ref: '#/components/schemas/ddidnsrickettsAccount' + title: accounts + type: array + cloud_credential_id: + description: Cloud Credential ID. + type: string + created_at: + description: Timestamp when the object has been created. + format: date-time + readOnly: true + type: string + credential_config: + $ref: '#/components/schemas/ddidnsrickettsCredentialConfig' + deleted_at: + description: Timestamp when the object has been deleted. + format: date-time + readOnly: true + type: string + id: + description: Auto-generated unique source config ID. Format BloxID. + readOnly: true + type: string + restricted_to_accounts: + description: Provider account IDs such as accountID/ SubscriptionID to be + restricted for a given source_config. + items: + type: string + type: array + updated_at: + description: Timestamp when the object has been updated. + format: date-time + readOnly: true + type: string + title: SourceConfig + type: object + ddidnsrickettsSubAccountListRequestV2: + properties: + access_type: + title: access_type represents static/dynamic credential access type + type: string + credential_id: + type: string + fields: + description: atlas.api.field_selection + type: string + provider_credentials_config: + $ref: '#/components/schemas/ddidnsrickettsSubAccountProvCredConfig' + provider_type: + type: string + type: object + ddidnsrickettsSubAccountListResponseV2: + example: + page: + offset: 0 + size: 6 + page_token: page_token + results: + - name: name + id: id + - name: name + id: id + properties: + page: + $ref: '#/components/schemas/apiPageInfo' + results: + items: + $ref: '#/components/schemas/ddidnsrickettsSubAccountV2' + type: array + type: object + ddidnsrickettsSubAccountProvCredConfig: + properties: + project_id: + title: gcp project_id + type: string + role_arn: + title: aws role ARN + type: string + tenant_id: + title: azure tenant_id + type: string + type: object + ddidnsrickettsSubAccountV2: + example: + name: name + id: id + properties: + id: + readOnly: true + type: string + name: + type: string + title: Sub Account contains information regarding the accounts which can be + accessed with a given credentials + type: object + securitySchemes: + ApiKeyAuth: + in: header + name: Authorization + type: apiKey +x-original-swagger-version: "2.0" diff --git a/clouddiscovery/api_accounts.go b/clouddiscovery/api_accounts.go new file mode 100644 index 0000000..a26d504 --- /dev/null +++ b/clouddiscovery/api_accounts.go @@ -0,0 +1,213 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "bytes" + "context" + "io" + "net/http" + "net/url" + + "github.com/infobloxopen/bloxone-go-client/internal" +) + +type AccountsAPI interface { + /* + List List Accounts + + Use this method to list Accounts + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return AccountsAPIListRequest + */ + List(ctx context.Context) AccountsAPIListRequest + + // ListExecute executes the request + // @return AccountListResponse + ListExecute(r AccountsAPIListRequest) (*AccountListResponse, *http.Response, error) +} + +// AccountsAPIService AccountsAPI service +type AccountsAPIService internal.Service + +type AccountsAPIListRequest struct { + ctx context.Context + ApiService AccountsAPI + fields *string + filter *string + offset *int32 + limit *int32 + pageToken *string + orderBy *string + tfilter *string + torderBy *string +} + +// A collection of response resources can be transformed by specifying a set of JSON tags to be returned. For a “flat” resource, the tag name is straightforward. If field selection is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, the tag does not appear in the output resource. Specify this parameter as a comma-separated list of JSON tag names. +func (r AccountsAPIListRequest) Fields(fields string) AccountsAPIListRequest { + r.fields = &fields + return r +} + +// A collection of response resources can be filtered by a logical expression string that includes JSON tag references to values in each resource, literal values, and logical operators. If a resource does not have the specified tag, its value is assumed to be null. Literal values include numbers (integer and floating-point), and quoted (both single- or double-quoted) literal strings, and 'null'. The following operators are commonly used in filter expressions: | Op | Description | | -- | ----------- | | == | Equal | | != | Not Equal | | > | Greater Than | | >= | Greater Than or Equal To | | < | Less Than | | <= | Less Than or Equal To | | and | Logical AND | | ~ | Matches Regex | | !~ | Does Not Match Regex | | or | Logical OR | | not | Logical NOT | | () | Groupping Operators | +func (r AccountsAPIListRequest) Filter(filter string) AccountsAPIListRequest { + r.filter = &filter + return r +} + +// The integer index (zero-origin) of the offset into a collection of resources. If omitted or null the value is assumed to be '0'. +func (r AccountsAPIListRequest) Offset(offset int32) AccountsAPIListRequest { + r.offset = &offset + return r +} + +// The integer number of resources to be returned in the response. The service may impose maximum value. If omitted the service may impose a default value. +func (r AccountsAPIListRequest) Limit(limit int32) AccountsAPIListRequest { + r.limit = &limit + return r +} + +// The service-defined string used to identify a page of resources. A null value indicates the first page. +func (r AccountsAPIListRequest) PageToken(pageToken string) AccountsAPIListRequest { + r.pageToken = &pageToken + return r +} + +// A collection of response resources can be sorted by their JSON tags. For a 'flat' resource, the tag name is straightforward. If sorting is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, its value is assumed to be null.) Specify this parameter as a comma-separated list of JSON tag names. The sort direction can be specified by a suffix separated by whitespace before the tag name. The suffix 'asc' sorts the data in ascending order. The suffix 'desc' sorts the data in descending order. If no suffix is specified the data is sorted in ascending order. +func (r AccountsAPIListRequest) OrderBy(orderBy string) AccountsAPIListRequest { + r.orderBy = &orderBy + return r +} + +// This parameter is used for filtering by tags. +func (r AccountsAPIListRequest) Tfilter(tfilter string) AccountsAPIListRequest { + r.tfilter = &tfilter + return r +} + +// This parameter is used for sorting by tags. +func (r AccountsAPIListRequest) TorderBy(torderBy string) AccountsAPIListRequest { + r.torderBy = &torderBy + return r +} + +func (r AccountsAPIListRequest) Execute() (*AccountListResponse, *http.Response, error) { + return r.ApiService.ListExecute(r) +} + +/* +List List Accounts + +Use this method to list Accounts + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return AccountsAPIListRequest +*/ +func (a *AccountsAPIService) List(ctx context.Context) AccountsAPIListRequest { + return AccountsAPIListRequest{ + ApiService: a, + ctx: ctx, + } +} + +// Execute executes the request +// +// @return AccountListResponse +func (a *AccountsAPIService) ListExecute(r AccountsAPIListRequest) (*AccountListResponse, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodGet + localVarPostBody interface{} + formFiles []internal.FormFile + localVarReturnValue *AccountListResponse + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "AccountsAPIService.List") + if err != nil { + return localVarReturnValue, nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/accounts" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if r.fields != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_fields", r.fields, "") + } + if r.filter != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_filter", r.filter, "") + } + if r.offset != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_offset", r.offset, "") + } + if r.limit != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_limit", r.limit, "") + } + if r.pageToken != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_page_token", r.pageToken, "") + } + if r.orderBy != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_order_by", r.orderBy, "") + } + if r.tfilter != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_tfilter", r.tfilter, "") + } + if r.torderBy != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_torder_by", r.torderBy, "") + } + // to determine the Content-Type header + localVarHTTPContentTypes := []string{} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.Client.Decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := internal.NewGenericOpenAPIErrorWithBody(err.Error(), localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/clouddiscovery/api_providers.go b/clouddiscovery/api_providers.go new file mode 100644 index 0000000..cef46f0 --- /dev/null +++ b/clouddiscovery/api_providers.go @@ -0,0 +1,696 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "bytes" + "context" + "io" + "net/http" + "net/url" + "strings" + + "github.com/infobloxopen/bloxone-go-client/internal" +) + +type ProvidersAPI interface { + /* + Create Create Provider + + Use this method to create Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ProvidersAPICreateRequest + */ + Create(ctx context.Context) ProvidersAPICreateRequest + + // CreateExecute executes the request + // @return ProviderCreateResponse + CreateExecute(r ProvidersAPICreateRequest) (*ProviderCreateResponse, *http.Response, error) + /* + Delete Delete Provider + + Use this method to delete Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param id + @return ProvidersAPIDeleteRequest + */ + Delete(ctx context.Context, id string) ProvidersAPIDeleteRequest + + // DeleteExecute executes the request + DeleteExecute(r ProvidersAPIDeleteRequest) (*http.Response, error) + /* + List List Provider + + Use this method to list Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ProvidersAPIListRequest + */ + List(ctx context.Context) ProvidersAPIListRequest + + // ListExecute executes the request + // @return ProviderListResponse + ListExecute(r ProvidersAPIListRequest) (*ProviderListResponse, *http.Response, error) + /* + Read Read Provider + + Use this method to retrieve a single Provider by ID + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param id + @return ProvidersAPIReadRequest + */ + Read(ctx context.Context, id string) ProvidersAPIReadRequest + + // ReadExecute executes the request + // @return ProviderReadResponse + ReadExecute(r ProvidersAPIReadRequest) (*ProviderReadResponse, *http.Response, error) + /* + Update Update Provider + + Use this method to update Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param id Auto-generated unique discovery config ID. Format BloxID. + @return ProvidersAPIUpdateRequest + */ + Update(ctx context.Context, id string) ProvidersAPIUpdateRequest + + // UpdateExecute executes the request + // @return ProviderUpdateResponse + UpdateExecute(r ProvidersAPIUpdateRequest) (*ProviderUpdateResponse, *http.Response, error) +} + +// ProvidersAPIService ProvidersAPI service +type ProvidersAPIService internal.Service + +type ProvidersAPICreateRequest struct { + ctx context.Context + ApiService ProvidersAPI + body *DiscoveryConfig +} + +func (r ProvidersAPICreateRequest) Body(body DiscoveryConfig) ProvidersAPICreateRequest { + r.body = &body + return r +} + +func (r ProvidersAPICreateRequest) Execute() (*ProviderCreateResponse, *http.Response, error) { + return r.ApiService.CreateExecute(r) +} + +/* +Create Create Provider + +Use this method to create Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ProvidersAPICreateRequest +*/ +func (a *ProvidersAPIService) Create(ctx context.Context) ProvidersAPICreateRequest { + return ProvidersAPICreateRequest{ + ApiService: a, + ctx: ctx, + } +} + +// Execute executes the request +// +// @return ProviderCreateResponse +func (a *ProvidersAPIService) CreateExecute(r ProvidersAPICreateRequest) (*ProviderCreateResponse, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodPost + localVarPostBody interface{} + formFiles []internal.FormFile + localVarReturnValue *ProviderCreateResponse + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "ProvidersAPIService.Create") + if err != nil { + return localVarReturnValue, nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/providers" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + if r.body == nil { + return localVarReturnValue, nil, internal.ReportError("body is required and must be specified") + } + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + if len(a.Client.Cfg.DefaultTags) > 0 && r.body != nil { + if r.body.Tags == nil { + r.body.Tags = make(map[string]interface{}) + } + for k, v := range a.Client.Cfg.DefaultTags { + if _, ok := r.body.Tags[k]; !ok { + r.body.Tags[k] = v + } + } + } + // body params + localVarPostBody = r.body + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.Client.Decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := internal.NewGenericOpenAPIErrorWithBody(err.Error(), localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ProvidersAPIDeleteRequest struct { + ctx context.Context + ApiService ProvidersAPI + id string +} + +func (r ProvidersAPIDeleteRequest) Execute() (*http.Response, error) { + return r.ApiService.DeleteExecute(r) +} + +/* +Delete Delete Provider + +Use this method to delete Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param id + @return ProvidersAPIDeleteRequest +*/ +func (a *ProvidersAPIService) Delete(ctx context.Context, id string) ProvidersAPIDeleteRequest { + return ProvidersAPIDeleteRequest{ + ApiService: a, + ctx: ctx, + id: id, + } +} + +// Execute executes the request +func (a *ProvidersAPIService) DeleteExecute(r ProvidersAPIDeleteRequest) (*http.Response, error) { + var ( + localVarHTTPMethod = http.MethodDelete + localVarPostBody interface{} + formFiles []internal.FormFile + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "ProvidersAPIService.Delete") + if err != nil { + return nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/providers/{id}" + localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", url.PathEscape(internal.ParameterValueToString(r.id, "id")), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarHTTPResponse, newErr + } + + return localVarHTTPResponse, nil +} + +type ProvidersAPIListRequest struct { + ctx context.Context + ApiService ProvidersAPI + fields *string + filter *string + offset *int32 + limit *int32 + pageToken *string + orderBy *string + tfilter *string + torderBy *string +} + +// A collection of response resources can be transformed by specifying a set of JSON tags to be returned. For a “flat” resource, the tag name is straightforward. If field selection is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, the tag does not appear in the output resource. Specify this parameter as a comma-separated list of JSON tag names. +func (r ProvidersAPIListRequest) Fields(fields string) ProvidersAPIListRequest { + r.fields = &fields + return r +} + +// A collection of response resources can be filtered by a logical expression string that includes JSON tag references to values in each resource, literal values, and logical operators. If a resource does not have the specified tag, its value is assumed to be null. Literal values include numbers (integer and floating-point), and quoted (both single- or double-quoted) literal strings, and 'null'. The following operators are commonly used in filter expressions: | Op | Description | | -- | ----------- | | == | Equal | | != | Not Equal | | > | Greater Than | | >= | Greater Than or Equal To | | < | Less Than | | <= | Less Than or Equal To | | and | Logical AND | | ~ | Matches Regex | | !~ | Does Not Match Regex | | or | Logical OR | | not | Logical NOT | | () | Groupping Operators | +func (r ProvidersAPIListRequest) Filter(filter string) ProvidersAPIListRequest { + r.filter = &filter + return r +} + +// The integer index (zero-origin) of the offset into a collection of resources. If omitted or null the value is assumed to be '0'. +func (r ProvidersAPIListRequest) Offset(offset int32) ProvidersAPIListRequest { + r.offset = &offset + return r +} + +// The integer number of resources to be returned in the response. The service may impose maximum value. If omitted the service may impose a default value. +func (r ProvidersAPIListRequest) Limit(limit int32) ProvidersAPIListRequest { + r.limit = &limit + return r +} + +// The service-defined string used to identify a page of resources. A null value indicates the first page. +func (r ProvidersAPIListRequest) PageToken(pageToken string) ProvidersAPIListRequest { + r.pageToken = &pageToken + return r +} + +// A collection of response resources can be sorted by their JSON tags. For a 'flat' resource, the tag name is straightforward. If sorting is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, its value is assumed to be null.) Specify this parameter as a comma-separated list of JSON tag names. The sort direction can be specified by a suffix separated by whitespace before the tag name. The suffix 'asc' sorts the data in ascending order. The suffix 'desc' sorts the data in descending order. If no suffix is specified the data is sorted in ascending order. +func (r ProvidersAPIListRequest) OrderBy(orderBy string) ProvidersAPIListRequest { + r.orderBy = &orderBy + return r +} + +// This parameter is used for filtering by tags. +func (r ProvidersAPIListRequest) Tfilter(tfilter string) ProvidersAPIListRequest { + r.tfilter = &tfilter + return r +} + +// This parameter is used for sorting by tags. +func (r ProvidersAPIListRequest) TorderBy(torderBy string) ProvidersAPIListRequest { + r.torderBy = &torderBy + return r +} + +func (r ProvidersAPIListRequest) Execute() (*ProviderListResponse, *http.Response, error) { + return r.ApiService.ListExecute(r) +} + +/* +List List Provider + +Use this method to list Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ProvidersAPIListRequest +*/ +func (a *ProvidersAPIService) List(ctx context.Context) ProvidersAPIListRequest { + return ProvidersAPIListRequest{ + ApiService: a, + ctx: ctx, + } +} + +// Execute executes the request +// +// @return ProviderListResponse +func (a *ProvidersAPIService) ListExecute(r ProvidersAPIListRequest) (*ProviderListResponse, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodGet + localVarPostBody interface{} + formFiles []internal.FormFile + localVarReturnValue *ProviderListResponse + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "ProvidersAPIService.List") + if err != nil { + return localVarReturnValue, nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/providers" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if r.fields != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_fields", r.fields, "") + } + if r.filter != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_filter", r.filter, "") + } + if r.offset != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_offset", r.offset, "") + } + if r.limit != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_limit", r.limit, "") + } + if r.pageToken != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_page_token", r.pageToken, "") + } + if r.orderBy != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_order_by", r.orderBy, "") + } + if r.tfilter != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_tfilter", r.tfilter, "") + } + if r.torderBy != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_torder_by", r.torderBy, "") + } + // to determine the Content-Type header + localVarHTTPContentTypes := []string{} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.Client.Decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := internal.NewGenericOpenAPIErrorWithBody(err.Error(), localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ProvidersAPIReadRequest struct { + ctx context.Context + ApiService ProvidersAPI + id string + fields *string +} + +// A collection of response resources can be transformed by specifying a set of JSON tags to be returned. For a “flat” resource, the tag name is straightforward. If field selection is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, the tag does not appear in the output resource. Specify this parameter as a comma-separated list of JSON tag names. +func (r ProvidersAPIReadRequest) Fields(fields string) ProvidersAPIReadRequest { + r.fields = &fields + return r +} + +func (r ProvidersAPIReadRequest) Execute() (*ProviderReadResponse, *http.Response, error) { + return r.ApiService.ReadExecute(r) +} + +/* +Read Read Provider + +Use this method to retrieve a single Provider by ID + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param id + @return ProvidersAPIReadRequest +*/ +func (a *ProvidersAPIService) Read(ctx context.Context, id string) ProvidersAPIReadRequest { + return ProvidersAPIReadRequest{ + ApiService: a, + ctx: ctx, + id: id, + } +} + +// Execute executes the request +// +// @return ProviderReadResponse +func (a *ProvidersAPIService) ReadExecute(r ProvidersAPIReadRequest) (*ProviderReadResponse, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodGet + localVarPostBody interface{} + formFiles []internal.FormFile + localVarReturnValue *ProviderReadResponse + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "ProvidersAPIService.Read") + if err != nil { + return localVarReturnValue, nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/providers/{id}" + localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", url.PathEscape(internal.ParameterValueToString(r.id, "id")), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if r.fields != nil { + internal.ParameterAddToHeaderOrQuery(localVarQueryParams, "_fields", r.fields, "") + } + // to determine the Content-Type header + localVarHTTPContentTypes := []string{} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.Client.Decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := internal.NewGenericOpenAPIErrorWithBody(err.Error(), localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ProvidersAPIUpdateRequest struct { + ctx context.Context + ApiService ProvidersAPI + id string + body *DiscoveryConfig +} + +func (r ProvidersAPIUpdateRequest) Body(body DiscoveryConfig) ProvidersAPIUpdateRequest { + r.body = &body + return r +} + +func (r ProvidersAPIUpdateRequest) Execute() (*ProviderUpdateResponse, *http.Response, error) { + return r.ApiService.UpdateExecute(r) +} + +/* +Update Update Provider + +Use this method to update Provider + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param id Auto-generated unique discovery config ID. Format BloxID. + @return ProvidersAPIUpdateRequest +*/ +func (a *ProvidersAPIService) Update(ctx context.Context, id string) ProvidersAPIUpdateRequest { + return ProvidersAPIUpdateRequest{ + ApiService: a, + ctx: ctx, + id: id, + } +} + +// Execute executes the request +// +// @return ProviderUpdateResponse +func (a *ProvidersAPIService) UpdateExecute(r ProvidersAPIUpdateRequest) (*ProviderUpdateResponse, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodPut + localVarPostBody interface{} + formFiles []internal.FormFile + localVarReturnValue *ProviderUpdateResponse + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "ProvidersAPIService.Update") + if err != nil { + return localVarReturnValue, nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/providers/{id}" + localVarPath = strings.Replace(localVarPath, "{"+"id"+"}", url.PathEscape(internal.ParameterValueToString(r.id, "id")), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + if r.body == nil { + return localVarReturnValue, nil, internal.ReportError("body is required and must be specified") + } + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + if len(a.Client.Cfg.DefaultTags) > 0 && r.body != nil { + if r.body.Tags == nil { + r.body.Tags = make(map[string]interface{}) + } + for k, v := range a.Client.Cfg.DefaultTags { + if _, ok := r.body.Tags[k]; !ok { + r.body.Tags[k] = v + } + } + } + // body params + localVarPostBody = r.body + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.Client.Decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := internal.NewGenericOpenAPIErrorWithBody(err.Error(), localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/clouddiscovery/api_sub_accounts.go b/clouddiscovery/api_sub_accounts.go new file mode 100644 index 0000000..7af1c18 --- /dev/null +++ b/clouddiscovery/api_sub_accounts.go @@ -0,0 +1,144 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "bytes" + "context" + "io" + "net/http" + "net/url" + + "github.com/infobloxopen/bloxone-go-client/internal" +) + +type SubAccountsAPI interface { + /* + List List Sub-accounts + + Use this method to list Sub-accounts + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return SubAccountsAPIListRequest + */ + List(ctx context.Context) SubAccountsAPIListRequest + + // ListExecute executes the request + // @return SubAccountListResponseV2 + ListExecute(r SubAccountsAPIListRequest) (*SubAccountListResponseV2, *http.Response, error) +} + +// SubAccountsAPIService SubAccountsAPI service +type SubAccountsAPIService internal.Service + +type SubAccountsAPIListRequest struct { + ctx context.Context + ApiService SubAccountsAPI + body *SubAccountListRequestV2 +} + +func (r SubAccountsAPIListRequest) Body(body SubAccountListRequestV2) SubAccountsAPIListRequest { + r.body = &body + return r +} + +func (r SubAccountsAPIListRequest) Execute() (*SubAccountListResponseV2, *http.Response, error) { + return r.ApiService.ListExecute(r) +} + +/* +List List Sub-accounts + +Use this method to list Sub-accounts + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return SubAccountsAPIListRequest +*/ +func (a *SubAccountsAPIService) List(ctx context.Context) SubAccountsAPIListRequest { + return SubAccountsAPIListRequest{ + ApiService: a, + ctx: ctx, + } +} + +// Execute executes the request +// +// @return SubAccountListResponseV2 +func (a *SubAccountsAPIService) ListExecute(r SubAccountsAPIListRequest) (*SubAccountListResponseV2, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodPost + localVarPostBody interface{} + formFiles []internal.FormFile + localVarReturnValue *SubAccountListResponseV2 + ) + + localBasePath, err := a.Client.Cfg.ServerURLWithContext(r.ctx, "SubAccountsAPIService.List") + if err != nil { + return localVarReturnValue, nil, internal.NewGenericOpenAPIError(err.Error()) + } + + localVarPath := localBasePath + "/sub_accounts" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + if r.body == nil { + return localVarReturnValue, nil, internal.ReportError("body is required and must be specified") + } + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := internal.SelectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := internal.SelectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.body + req, err := a.Client.PrepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.Client.CallAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := internal.NewGenericOpenAPIErrorWithBody(localVarHTTPResponse.Status, localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.Client.Decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := internal.NewGenericOpenAPIErrorWithBody(err.Error(), localVarBody) + return localVarReturnValue, localVarHTTPResponse, newErr + } + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/clouddiscovery/client.go b/clouddiscovery/client.go new file mode 100644 index 0000000..13f13cb --- /dev/null +++ b/clouddiscovery/client.go @@ -0,0 +1,54 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "github.com/infobloxopen/bloxone-go-client/internal" + "github.com/infobloxopen/bloxone-go-client/option" +) + +const serviceBasePath = "/api/cloud_discovery/v2" + +// APIClient manages communication with the Discovery Configuration API V2 v2 +// In most cases there should be only one, shared, APIClient. +type APIClient struct { + *internal.APIClient + + // API Services + AccountsAPI AccountsAPI + ProvidersAPI ProvidersAPI + SubAccountsAPI SubAccountsAPI +} + +// NewAPIClient creates a new API client. +// The client can be configured with a variadic option. The following options are available: +// - WithClientName(string) sets the name of the client using the SDK. +// - WithCSPUrl(string) sets the URL for BloxOne Cloud Services Portal. +// - WithAPIKey(string) sets the APIKey for accessing the BloxOne API. +// - WithHTTPClient(*http.Client) sets the HTTPClient to use for the SDK. +// - WithDefaultTags(map[string]string) sets the tags the client can set by default for objects that has tags support. +// - WithDebug() sets the debug mode. +func NewAPIClient(options ...option.ClientOption) *APIClient { + cfg := internal.NewConfiguration() + for _, o := range options { + o(cfg) + } + + c := &APIClient{} + c.APIClient = internal.NewAPIClient(serviceBasePath, cfg) + + // API Services + c.AccountsAPI = (*AccountsAPIService)(&c.Common) + c.ProvidersAPI = (*ProvidersAPIService)(&c.Common) + c.SubAccountsAPI = (*SubAccountsAPIService)(&c.Common) + + return c +} diff --git a/clouddiscovery/docs/Account.md b/clouddiscovery/docs/Account.md new file mode 100644 index 0000000..56b4b2c --- /dev/null +++ b/clouddiscovery/docs/Account.md @@ -0,0 +1,493 @@ +# Account + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**CompositeStatus** | Pointer to **string** | | [optional] +**CompositeStatusMessage** | Pointer to **string** | Status message of the sync operation. | [optional] +**CreatedAt** | Pointer to **time.Time** | Timestamp when the object has been created. | [optional] [readonly] +**DeletedAt** | Pointer to **time.Time** | Timestamp when the object has been deleted. | [optional] [readonly] +**DhcpServerId** | Pointer to **string** | | [optional] [readonly] +**DnsServerId** | Pointer to **string** | DNS Server ID. | [optional] [readonly] +**Id** | Pointer to **string** | Auto-generated unique source account ID. Format BloxID. | [optional] [readonly] +**LastSuccessfulSync** | Pointer to **time.Time** | Last successful sync timestamp. | [optional] [readonly] +**LastSync** | Pointer to **time.Time** | Last sync timestamp. | [optional] [readonly] +**Name** | **string** | Name of the source account. | +**ParentId** | Pointer to **string** | Parent ID. | [optional] +**PercentComplete** | Pointer to **int32** | Sync progress as a percentage. | [optional] [readonly] +**ProviderAccountId** | Pointer to **string** | | [optional] +**ScheduleId** | Pointer to **string** | Schedule ID. | [optional] [readonly] +**State** | Pointer to **string** | | [optional] [readonly] +**Status** | Pointer to **string** | Status of the sync operation. | [optional] [readonly] +**StatusMessage** | Pointer to **string** | Status message of the sync operation. | [optional] [readonly] +**UpdatedAt** | Pointer to **time.Time** | Timestamp when the object has been updated. | [optional] [readonly] + +## Methods + +### NewAccount + +`func NewAccount(name string, ) *Account` + +NewAccount instantiates a new Account 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 + +### NewAccountWithDefaults + +`func NewAccountWithDefaults() *Account` + +NewAccountWithDefaults instantiates a new Account 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 + +### GetCompositeStatus + +`func (o *Account) GetCompositeStatus() string` + +GetCompositeStatus returns the CompositeStatus field if non-nil, zero value otherwise. + +### GetCompositeStatusOk + +`func (o *Account) GetCompositeStatusOk() (*string, bool)` + +GetCompositeStatusOk returns a tuple with the CompositeStatus field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCompositeStatus + +`func (o *Account) SetCompositeStatus(v string)` + +SetCompositeStatus sets CompositeStatus field to given value. + +### HasCompositeStatus + +`func (o *Account) HasCompositeStatus() bool` + +HasCompositeStatus returns a boolean if a field has been set. + +### GetCompositeStatusMessage + +`func (o *Account) GetCompositeStatusMessage() string` + +GetCompositeStatusMessage returns the CompositeStatusMessage field if non-nil, zero value otherwise. + +### GetCompositeStatusMessageOk + +`func (o *Account) GetCompositeStatusMessageOk() (*string, bool)` + +GetCompositeStatusMessageOk returns a tuple with the CompositeStatusMessage field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCompositeStatusMessage + +`func (o *Account) SetCompositeStatusMessage(v string)` + +SetCompositeStatusMessage sets CompositeStatusMessage field to given value. + +### HasCompositeStatusMessage + +`func (o *Account) HasCompositeStatusMessage() bool` + +HasCompositeStatusMessage returns a boolean if a field has been set. + +### GetCreatedAt + +`func (o *Account) GetCreatedAt() time.Time` + +GetCreatedAt returns the CreatedAt field if non-nil, zero value otherwise. + +### GetCreatedAtOk + +`func (o *Account) GetCreatedAtOk() (*time.Time, bool)` + +GetCreatedAtOk returns a tuple with the CreatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCreatedAt + +`func (o *Account) SetCreatedAt(v time.Time)` + +SetCreatedAt sets CreatedAt field to given value. + +### HasCreatedAt + +`func (o *Account) HasCreatedAt() bool` + +HasCreatedAt returns a boolean if a field has been set. + +### GetDeletedAt + +`func (o *Account) GetDeletedAt() time.Time` + +GetDeletedAt returns the DeletedAt field if non-nil, zero value otherwise. + +### GetDeletedAtOk + +`func (o *Account) GetDeletedAtOk() (*time.Time, bool)` + +GetDeletedAtOk returns a tuple with the DeletedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeletedAt + +`func (o *Account) SetDeletedAt(v time.Time)` + +SetDeletedAt sets DeletedAt field to given value. + +### HasDeletedAt + +`func (o *Account) HasDeletedAt() bool` + +HasDeletedAt returns a boolean if a field has been set. + +### GetDhcpServerId + +`func (o *Account) GetDhcpServerId() string` + +GetDhcpServerId returns the DhcpServerId field if non-nil, zero value otherwise. + +### GetDhcpServerIdOk + +`func (o *Account) GetDhcpServerIdOk() (*string, bool)` + +GetDhcpServerIdOk returns a tuple with the DhcpServerId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDhcpServerId + +`func (o *Account) SetDhcpServerId(v string)` + +SetDhcpServerId sets DhcpServerId field to given value. + +### HasDhcpServerId + +`func (o *Account) HasDhcpServerId() bool` + +HasDhcpServerId returns a boolean if a field has been set. + +### GetDnsServerId + +`func (o *Account) GetDnsServerId() string` + +GetDnsServerId returns the DnsServerId field if non-nil, zero value otherwise. + +### GetDnsServerIdOk + +`func (o *Account) GetDnsServerIdOk() (*string, bool)` + +GetDnsServerIdOk returns a tuple with the DnsServerId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDnsServerId + +`func (o *Account) SetDnsServerId(v string)` + +SetDnsServerId sets DnsServerId field to given value. + +### HasDnsServerId + +`func (o *Account) HasDnsServerId() bool` + +HasDnsServerId returns a boolean if a field has been set. + +### GetId + +`func (o *Account) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Account) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *Account) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *Account) HasId() bool` + +HasId returns a boolean if a field has been set. + +### GetLastSuccessfulSync + +`func (o *Account) GetLastSuccessfulSync() time.Time` + +GetLastSuccessfulSync returns the LastSuccessfulSync field if non-nil, zero value otherwise. + +### GetLastSuccessfulSyncOk + +`func (o *Account) GetLastSuccessfulSyncOk() (*time.Time, bool)` + +GetLastSuccessfulSyncOk returns a tuple with the LastSuccessfulSync field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetLastSuccessfulSync + +`func (o *Account) SetLastSuccessfulSync(v time.Time)` + +SetLastSuccessfulSync sets LastSuccessfulSync field to given value. + +### HasLastSuccessfulSync + +`func (o *Account) HasLastSuccessfulSync() bool` + +HasLastSuccessfulSync returns a boolean if a field has been set. + +### GetLastSync + +`func (o *Account) GetLastSync() time.Time` + +GetLastSync returns the LastSync field if non-nil, zero value otherwise. + +### GetLastSyncOk + +`func (o *Account) GetLastSyncOk() (*time.Time, bool)` + +GetLastSyncOk returns a tuple with the LastSync field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetLastSync + +`func (o *Account) SetLastSync(v time.Time)` + +SetLastSync sets LastSync field to given value. + +### HasLastSync + +`func (o *Account) HasLastSync() bool` + +HasLastSync returns a boolean if a field has been set. + +### GetName + +`func (o *Account) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *Account) GetNameOk() (*string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetName + +`func (o *Account) SetName(v string)` + +SetName sets Name field to given value. + + +### GetParentId + +`func (o *Account) GetParentId() string` + +GetParentId returns the ParentId field if non-nil, zero value otherwise. + +### GetParentIdOk + +`func (o *Account) GetParentIdOk() (*string, bool)` + +GetParentIdOk returns a tuple with the ParentId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetParentId + +`func (o *Account) SetParentId(v string)` + +SetParentId sets ParentId field to given value. + +### HasParentId + +`func (o *Account) HasParentId() bool` + +HasParentId returns a boolean if a field has been set. + +### GetPercentComplete + +`func (o *Account) GetPercentComplete() int32` + +GetPercentComplete returns the PercentComplete field if non-nil, zero value otherwise. + +### GetPercentCompleteOk + +`func (o *Account) GetPercentCompleteOk() (*int32, bool)` + +GetPercentCompleteOk returns a tuple with the PercentComplete field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPercentComplete + +`func (o *Account) SetPercentComplete(v int32)` + +SetPercentComplete sets PercentComplete field to given value. + +### HasPercentComplete + +`func (o *Account) HasPercentComplete() bool` + +HasPercentComplete returns a boolean if a field has been set. + +### GetProviderAccountId + +`func (o *Account) GetProviderAccountId() string` + +GetProviderAccountId returns the ProviderAccountId field if non-nil, zero value otherwise. + +### GetProviderAccountIdOk + +`func (o *Account) GetProviderAccountIdOk() (*string, bool)` + +GetProviderAccountIdOk returns a tuple with the ProviderAccountId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetProviderAccountId + +`func (o *Account) SetProviderAccountId(v string)` + +SetProviderAccountId sets ProviderAccountId field to given value. + +### HasProviderAccountId + +`func (o *Account) HasProviderAccountId() bool` + +HasProviderAccountId returns a boolean if a field has been set. + +### GetScheduleId + +`func (o *Account) GetScheduleId() string` + +GetScheduleId returns the ScheduleId field if non-nil, zero value otherwise. + +### GetScheduleIdOk + +`func (o *Account) GetScheduleIdOk() (*string, bool)` + +GetScheduleIdOk returns a tuple with the ScheduleId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetScheduleId + +`func (o *Account) SetScheduleId(v string)` + +SetScheduleId sets ScheduleId field to given value. + +### HasScheduleId + +`func (o *Account) HasScheduleId() bool` + +HasScheduleId returns a boolean if a field has been set. + +### GetState + +`func (o *Account) GetState() string` + +GetState returns the State field if non-nil, zero value otherwise. + +### GetStateOk + +`func (o *Account) GetStateOk() (*string, bool)` + +GetStateOk returns a tuple with the State field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetState + +`func (o *Account) SetState(v string)` + +SetState sets State field to given value. + +### HasState + +`func (o *Account) HasState() bool` + +HasState returns a boolean if a field has been set. + +### GetStatus + +`func (o *Account) GetStatus() string` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *Account) GetStatusOk() (*string, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatus + +`func (o *Account) SetStatus(v string)` + +SetStatus sets Status field to given value. + +### HasStatus + +`func (o *Account) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + +### GetStatusMessage + +`func (o *Account) GetStatusMessage() string` + +GetStatusMessage returns the StatusMessage field if non-nil, zero value otherwise. + +### GetStatusMessageOk + +`func (o *Account) GetStatusMessageOk() (*string, bool)` + +GetStatusMessageOk returns a tuple with the StatusMessage field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatusMessage + +`func (o *Account) SetStatusMessage(v string)` + +SetStatusMessage sets StatusMessage field to given value. + +### HasStatusMessage + +`func (o *Account) HasStatusMessage() bool` + +HasStatusMessage returns a boolean if a field has been set. + +### GetUpdatedAt + +`func (o *Account) GetUpdatedAt() time.Time` + +GetUpdatedAt returns the UpdatedAt field if non-nil, zero value otherwise. + +### GetUpdatedAtOk + +`func (o *Account) GetUpdatedAtOk() (*time.Time, bool)` + +GetUpdatedAtOk returns a tuple with the UpdatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetUpdatedAt + +`func (o *Account) SetUpdatedAt(v time.Time)` + +SetUpdatedAt sets UpdatedAt field to given value. + +### HasUpdatedAt + +`func (o *Account) HasUpdatedAt() bool` + +HasUpdatedAt returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/AccountListResponse.md b/clouddiscovery/docs/AccountListResponse.md new file mode 100644 index 0000000..8dd95ca --- /dev/null +++ b/clouddiscovery/docs/AccountListResponse.md @@ -0,0 +1,82 @@ +# AccountListResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Page** | Pointer to [**ApiPageInfo**](ApiPageInfo.md) | | [optional] +**Results** | Pointer to [**[]Account**](Account.md) | | [optional] + +## Methods + +### NewAccountListResponse + +`func NewAccountListResponse() *AccountListResponse` + +NewAccountListResponse instantiates a new AccountListResponse 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 + +### NewAccountListResponseWithDefaults + +`func NewAccountListResponseWithDefaults() *AccountListResponse` + +NewAccountListResponseWithDefaults instantiates a new AccountListResponse 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 + +### GetPage + +`func (o *AccountListResponse) GetPage() ApiPageInfo` + +GetPage returns the Page field if non-nil, zero value otherwise. + +### GetPageOk + +`func (o *AccountListResponse) GetPageOk() (*ApiPageInfo, bool)` + +GetPageOk returns a tuple with the Page field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPage + +`func (o *AccountListResponse) SetPage(v ApiPageInfo)` + +SetPage sets Page field to given value. + +### HasPage + +`func (o *AccountListResponse) HasPage() bool` + +HasPage returns a boolean if a field has been set. + +### GetResults + +`func (o *AccountListResponse) GetResults() []Account` + +GetResults returns the Results field if non-nil, zero value otherwise. + +### GetResultsOk + +`func (o *AccountListResponse) GetResultsOk() (*[]Account, bool)` + +GetResultsOk returns a tuple with the Results field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResults + +`func (o *AccountListResponse) SetResults(v []Account)` + +SetResults sets Results field to given value. + +### HasResults + +`func (o *AccountListResponse) HasResults() bool` + +HasResults returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/AccountsAPI.md b/clouddiscovery/docs/AccountsAPI.md new file mode 100644 index 0000000..666f70f --- /dev/null +++ b/clouddiscovery/docs/AccountsAPI.md @@ -0,0 +1,81 @@ +# AccountsAPI + +All URIs are relative to *http://csp.infoblox.com/api/cloud_discovery/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**List**](AccountsAPI.md#List) | **Get** /accounts | List Accounts + + + +## List + +> AccountListResponse List(ctx).Fields(fields).Filter(filter).Offset(offset).Limit(limit).PageToken(pageToken).OrderBy(orderBy).Tfilter(tfilter).TorderBy(torderBy).Execute() + +List Accounts + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + + apiClient := clouddiscovery.NewAPIClient() + resp, r, err := apiClient.AccountsAPI.List(context.Background()).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `AccountsAPI.List``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `List`: AccountListResponse + fmt.Fprintf(os.Stdout, "Response from `AccountsAPI.List`: %v\n", resp) +} +``` + +### Path Parameters + + + +### Other Parameters + +Other parameters are passed through a pointer to a `AccountsAPIListRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**fields** | **string** | A collection of response resources can be transformed by specifying a set of JSON tags to be returned. For a “flat” resource, the tag name is straightforward. If field selection is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, the tag does not appear in the output resource. Specify this parameter as a comma-separated list of JSON tag names. | +**filter** | **string** | A collection of response resources can be filtered by a logical expression string that includes JSON tag references to values in each resource, literal values, and logical operators. If a resource does not have the specified tag, its value is assumed to be null. Literal values include numbers (integer and floating-point), and quoted (both single- or double-quoted) literal strings, and 'null'. The following operators are commonly used in filter expressions: | Op | Description | | -- | ----------- | | == | Equal | | != | Not Equal | | > | Greater Than | | >= | Greater Than or Equal To | | < | Less Than | | <= | Less Than or Equal To | | and | Logical AND | | ~ | Matches Regex | | !~ | Does Not Match Regex | | or | Logical OR | | not | Logical NOT | | () | Groupping Operators | | +**offset** | **int32** | The integer index (zero-origin) of the offset into a collection of resources. If omitted or null the value is assumed to be '0'. | +**limit** | **int32** | The integer number of resources to be returned in the response. The service may impose maximum value. If omitted the service may impose a default value. | +**pageToken** | **string** | The service-defined string used to identify a page of resources. A null value indicates the first page. | +**orderBy** | **string** | A collection of response resources can be sorted by their JSON tags. For a 'flat' resource, the tag name is straightforward. If sorting is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, its value is assumed to be null.) Specify this parameter as a comma-separated list of JSON tag names. The sort direction can be specified by a suffix separated by whitespace before the tag name. The suffix 'asc' sorts the data in ascending order. The suffix 'desc' sorts the data in descending order. If no suffix is specified the data is sorted in ascending order. | +**tfilter** | **string** | This parameter is used for filtering by tags. | +**torderBy** | **string** | This parameter is used for sorting by tags. | + +### Return type + +[**AccountListResponse**](AccountListResponse.md) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + diff --git a/clouddiscovery/docs/AdditionalConfig.md b/clouddiscovery/docs/AdditionalConfig.md new file mode 100644 index 0000000..e5a6dd3 --- /dev/null +++ b/clouddiscovery/docs/AdditionalConfig.md @@ -0,0 +1,134 @@ +# AdditionalConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ExcludedAccounts** | Pointer to **[]string** | | [optional] +**ForwardZoneEnabled** | Pointer to **bool** | | [optional] +**InternalRangesEnabled** | Pointer to **bool** | | [optional] +**ObjectType** | Pointer to [**ObjectType**](ObjectType.md) | | [optional] + +## Methods + +### NewAdditionalConfig + +`func NewAdditionalConfig() *AdditionalConfig` + +NewAdditionalConfig instantiates a new AdditionalConfig 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 + +### NewAdditionalConfigWithDefaults + +`func NewAdditionalConfigWithDefaults() *AdditionalConfig` + +NewAdditionalConfigWithDefaults instantiates a new AdditionalConfig 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 + +### GetExcludedAccounts + +`func (o *AdditionalConfig) GetExcludedAccounts() []string` + +GetExcludedAccounts returns the ExcludedAccounts field if non-nil, zero value otherwise. + +### GetExcludedAccountsOk + +`func (o *AdditionalConfig) GetExcludedAccountsOk() (*[]string, bool)` + +GetExcludedAccountsOk returns a tuple with the ExcludedAccounts field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetExcludedAccounts + +`func (o *AdditionalConfig) SetExcludedAccounts(v []string)` + +SetExcludedAccounts sets ExcludedAccounts field to given value. + +### HasExcludedAccounts + +`func (o *AdditionalConfig) HasExcludedAccounts() bool` + +HasExcludedAccounts returns a boolean if a field has been set. + +### GetForwardZoneEnabled + +`func (o *AdditionalConfig) GetForwardZoneEnabled() bool` + +GetForwardZoneEnabled returns the ForwardZoneEnabled field if non-nil, zero value otherwise. + +### GetForwardZoneEnabledOk + +`func (o *AdditionalConfig) GetForwardZoneEnabledOk() (*bool, bool)` + +GetForwardZoneEnabledOk returns a tuple with the ForwardZoneEnabled field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetForwardZoneEnabled + +`func (o *AdditionalConfig) SetForwardZoneEnabled(v bool)` + +SetForwardZoneEnabled sets ForwardZoneEnabled field to given value. + +### HasForwardZoneEnabled + +`func (o *AdditionalConfig) HasForwardZoneEnabled() bool` + +HasForwardZoneEnabled returns a boolean if a field has been set. + +### GetInternalRangesEnabled + +`func (o *AdditionalConfig) GetInternalRangesEnabled() bool` + +GetInternalRangesEnabled returns the InternalRangesEnabled field if non-nil, zero value otherwise. + +### GetInternalRangesEnabledOk + +`func (o *AdditionalConfig) GetInternalRangesEnabledOk() (*bool, bool)` + +GetInternalRangesEnabledOk returns a tuple with the InternalRangesEnabled field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetInternalRangesEnabled + +`func (o *AdditionalConfig) SetInternalRangesEnabled(v bool)` + +SetInternalRangesEnabled sets InternalRangesEnabled field to given value. + +### HasInternalRangesEnabled + +`func (o *AdditionalConfig) HasInternalRangesEnabled() bool` + +HasInternalRangesEnabled returns a boolean if a field has been set. + +### GetObjectType + +`func (o *AdditionalConfig) GetObjectType() ObjectType` + +GetObjectType returns the ObjectType field if non-nil, zero value otherwise. + +### GetObjectTypeOk + +`func (o *AdditionalConfig) GetObjectTypeOk() (*ObjectType, bool)` + +GetObjectTypeOk returns a tuple with the ObjectType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetObjectType + +`func (o *AdditionalConfig) SetObjectType(v ObjectType)` + +SetObjectType sets ObjectType field to given value. + +### HasObjectType + +`func (o *AdditionalConfig) HasObjectType() bool` + +HasObjectType returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ApiPageInfo.md b/clouddiscovery/docs/ApiPageInfo.md new file mode 100644 index 0000000..8b3356e --- /dev/null +++ b/clouddiscovery/docs/ApiPageInfo.md @@ -0,0 +1,108 @@ +# ApiPageInfo + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Offset** | Pointer to **int32** | The service may optionally include the offset of the next page of resources. A null value indicates no more pages. | [optional] +**PageToken** | Pointer to **string** | The service response should contain a string to indicate the next page of resources. A null value indicates no more pages. | [optional] +**Size** | Pointer to **int32** | The service may optionally include the total number of resources being paged. | [optional] + +## Methods + +### NewApiPageInfo + +`func NewApiPageInfo() *ApiPageInfo` + +NewApiPageInfo instantiates a new ApiPageInfo 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 + +### NewApiPageInfoWithDefaults + +`func NewApiPageInfoWithDefaults() *ApiPageInfo` + +NewApiPageInfoWithDefaults instantiates a new ApiPageInfo 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 + +### GetOffset + +`func (o *ApiPageInfo) GetOffset() int32` + +GetOffset returns the Offset field if non-nil, zero value otherwise. + +### GetOffsetOk + +`func (o *ApiPageInfo) GetOffsetOk() (*int32, bool)` + +GetOffsetOk returns a tuple with the Offset field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetOffset + +`func (o *ApiPageInfo) SetOffset(v int32)` + +SetOffset sets Offset field to given value. + +### HasOffset + +`func (o *ApiPageInfo) HasOffset() bool` + +HasOffset returns a boolean if a field has been set. + +### GetPageToken + +`func (o *ApiPageInfo) GetPageToken() string` + +GetPageToken returns the PageToken field if non-nil, zero value otherwise. + +### GetPageTokenOk + +`func (o *ApiPageInfo) GetPageTokenOk() (*string, bool)` + +GetPageTokenOk returns a tuple with the PageToken field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPageToken + +`func (o *ApiPageInfo) SetPageToken(v string)` + +SetPageToken sets PageToken field to given value. + +### HasPageToken + +`func (o *ApiPageInfo) HasPageToken() bool` + +HasPageToken returns a boolean if a field has been set. + +### GetSize + +`func (o *ApiPageInfo) GetSize() int32` + +GetSize returns the Size field if non-nil, zero value otherwise. + +### GetSizeOk + +`func (o *ApiPageInfo) GetSizeOk() (*int32, bool)` + +GetSizeOk returns a tuple with the Size field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSize + +`func (o *ApiPageInfo) SetSize(v int32)` + +SetSize sets Size field to given value. + +### HasSize + +`func (o *ApiPageInfo) HasSize() bool` + +HasSize returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/Category.md b/clouddiscovery/docs/Category.md new file mode 100644 index 0000000..100fe62 --- /dev/null +++ b/clouddiscovery/docs/Category.md @@ -0,0 +1,82 @@ +# Category + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Excluded** | Pointer to **bool** | | [optional] +**Id** | Pointer to **string** | | [optional] [readonly] + +## Methods + +### NewCategory + +`func NewCategory() *Category` + +NewCategory instantiates a new Category 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 + +### NewCategoryWithDefaults + +`func NewCategoryWithDefaults() *Category` + +NewCategoryWithDefaults instantiates a new Category 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 + +### GetExcluded + +`func (o *Category) GetExcluded() bool` + +GetExcluded returns the Excluded field if non-nil, zero value otherwise. + +### GetExcludedOk + +`func (o *Category) GetExcludedOk() (*bool, bool)` + +GetExcludedOk returns a tuple with the Excluded field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetExcluded + +`func (o *Category) SetExcluded(v bool)` + +SetExcluded sets Excluded field to given value. + +### HasExcluded + +`func (o *Category) HasExcluded() bool` + +HasExcluded returns a boolean if a field has been set. + +### GetId + +`func (o *Category) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Category) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *Category) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *Category) HasId() bool` + +HasId returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/CredentialConfig.md b/clouddiscovery/docs/CredentialConfig.md new file mode 100644 index 0000000..0bc03e4 --- /dev/null +++ b/clouddiscovery/docs/CredentialConfig.md @@ -0,0 +1,108 @@ +# CredentialConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AccessIdentifier** | Pointer to **string** | | [optional] +**Enclave** | Pointer to **string** | | [optional] +**Region** | Pointer to **string** | | [optional] + +## Methods + +### NewCredentialConfig + +`func NewCredentialConfig() *CredentialConfig` + +NewCredentialConfig instantiates a new CredentialConfig 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 + +### NewCredentialConfigWithDefaults + +`func NewCredentialConfigWithDefaults() *CredentialConfig` + +NewCredentialConfigWithDefaults instantiates a new CredentialConfig 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 + +### GetAccessIdentifier + +`func (o *CredentialConfig) GetAccessIdentifier() string` + +GetAccessIdentifier returns the AccessIdentifier field if non-nil, zero value otherwise. + +### GetAccessIdentifierOk + +`func (o *CredentialConfig) GetAccessIdentifierOk() (*string, bool)` + +GetAccessIdentifierOk returns a tuple with the AccessIdentifier field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAccessIdentifier + +`func (o *CredentialConfig) SetAccessIdentifier(v string)` + +SetAccessIdentifier sets AccessIdentifier field to given value. + +### HasAccessIdentifier + +`func (o *CredentialConfig) HasAccessIdentifier() bool` + +HasAccessIdentifier returns a boolean if a field has been set. + +### GetEnclave + +`func (o *CredentialConfig) GetEnclave() string` + +GetEnclave returns the Enclave field if non-nil, zero value otherwise. + +### GetEnclaveOk + +`func (o *CredentialConfig) GetEnclaveOk() (*string, bool)` + +GetEnclaveOk returns a tuple with the Enclave field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetEnclave + +`func (o *CredentialConfig) SetEnclave(v string)` + +SetEnclave sets Enclave field to given value. + +### HasEnclave + +`func (o *CredentialConfig) HasEnclave() bool` + +HasEnclave returns a boolean if a field has been set. + +### GetRegion + +`func (o *CredentialConfig) GetRegion() string` + +GetRegion returns the Region field if non-nil, zero value otherwise. + +### GetRegionOk + +`func (o *CredentialConfig) GetRegionOk() (*string, bool)` + +GetRegionOk returns a tuple with the Region field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetRegion + +`func (o *CredentialConfig) SetRegion(v string)` + +SetRegion sets Region field to given value. + +### HasRegion + +`func (o *CredentialConfig) HasRegion() bool` + +HasRegion returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/CredentialPreference.md b/clouddiscovery/docs/CredentialPreference.md new file mode 100644 index 0000000..727f9f8 --- /dev/null +++ b/clouddiscovery/docs/CredentialPreference.md @@ -0,0 +1,82 @@ +# CredentialPreference + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AccessIdentifierType** | Pointer to **string** | | [optional] +**CredentialType** | Pointer to **string** | | [optional] + +## Methods + +### NewCredentialPreference + +`func NewCredentialPreference() *CredentialPreference` + +NewCredentialPreference instantiates a new CredentialPreference 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 + +### NewCredentialPreferenceWithDefaults + +`func NewCredentialPreferenceWithDefaults() *CredentialPreference` + +NewCredentialPreferenceWithDefaults instantiates a new CredentialPreference 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 + +### GetAccessIdentifierType + +`func (o *CredentialPreference) GetAccessIdentifierType() string` + +GetAccessIdentifierType returns the AccessIdentifierType field if non-nil, zero value otherwise. + +### GetAccessIdentifierTypeOk + +`func (o *CredentialPreference) GetAccessIdentifierTypeOk() (*string, bool)` + +GetAccessIdentifierTypeOk returns a tuple with the AccessIdentifierType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAccessIdentifierType + +`func (o *CredentialPreference) SetAccessIdentifierType(v string)` + +SetAccessIdentifierType sets AccessIdentifierType field to given value. + +### HasAccessIdentifierType + +`func (o *CredentialPreference) HasAccessIdentifierType() bool` + +HasAccessIdentifierType returns a boolean if a field has been set. + +### GetCredentialType + +`func (o *CredentialPreference) GetCredentialType() string` + +GetCredentialType returns the CredentialType field if non-nil, zero value otherwise. + +### GetCredentialTypeOk + +`func (o *CredentialPreference) GetCredentialTypeOk() (*string, bool)` + +GetCredentialTypeOk returns a tuple with the CredentialType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCredentialType + +`func (o *CredentialPreference) SetCredentialType(v string)` + +SetCredentialType sets CredentialType field to given value. + +### HasCredentialType + +`func (o *CredentialPreference) HasCredentialType() bool` + +HasCredentialType returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/DNSConfig.md b/clouddiscovery/docs/DNSConfig.md new file mode 100644 index 0000000..2a60c37 --- /dev/null +++ b/clouddiscovery/docs/DNSConfig.md @@ -0,0 +1,160 @@ +# DNSConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ConsolidatedZoneDataEnabled** | Pointer to **bool** | | [optional] +**SplitViewEnabled** | Pointer to **bool** | split_view_enabled consolidates private zones into a single view, which is separate from the public zone view. | [optional] +**SyncType** | Pointer to **string** | | [optional] +**ViewId** | Pointer to **string** | | [optional] +**ViewName** | Pointer to **string** | | [optional] + +## Methods + +### NewDNSConfig + +`func NewDNSConfig() *DNSConfig` + +NewDNSConfig instantiates a new DNSConfig 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 + +### NewDNSConfigWithDefaults + +`func NewDNSConfigWithDefaults() *DNSConfig` + +NewDNSConfigWithDefaults instantiates a new DNSConfig 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 + +### GetConsolidatedZoneDataEnabled + +`func (o *DNSConfig) GetConsolidatedZoneDataEnabled() bool` + +GetConsolidatedZoneDataEnabled returns the ConsolidatedZoneDataEnabled field if non-nil, zero value otherwise. + +### GetConsolidatedZoneDataEnabledOk + +`func (o *DNSConfig) GetConsolidatedZoneDataEnabledOk() (*bool, bool)` + +GetConsolidatedZoneDataEnabledOk returns a tuple with the ConsolidatedZoneDataEnabled field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetConsolidatedZoneDataEnabled + +`func (o *DNSConfig) SetConsolidatedZoneDataEnabled(v bool)` + +SetConsolidatedZoneDataEnabled sets ConsolidatedZoneDataEnabled field to given value. + +### HasConsolidatedZoneDataEnabled + +`func (o *DNSConfig) HasConsolidatedZoneDataEnabled() bool` + +HasConsolidatedZoneDataEnabled returns a boolean if a field has been set. + +### GetSplitViewEnabled + +`func (o *DNSConfig) GetSplitViewEnabled() bool` + +GetSplitViewEnabled returns the SplitViewEnabled field if non-nil, zero value otherwise. + +### GetSplitViewEnabledOk + +`func (o *DNSConfig) GetSplitViewEnabledOk() (*bool, bool)` + +GetSplitViewEnabledOk returns a tuple with the SplitViewEnabled field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSplitViewEnabled + +`func (o *DNSConfig) SetSplitViewEnabled(v bool)` + +SetSplitViewEnabled sets SplitViewEnabled field to given value. + +### HasSplitViewEnabled + +`func (o *DNSConfig) HasSplitViewEnabled() bool` + +HasSplitViewEnabled returns a boolean if a field has been set. + +### GetSyncType + +`func (o *DNSConfig) GetSyncType() string` + +GetSyncType returns the SyncType field if non-nil, zero value otherwise. + +### GetSyncTypeOk + +`func (o *DNSConfig) GetSyncTypeOk() (*string, bool)` + +GetSyncTypeOk returns a tuple with the SyncType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSyncType + +`func (o *DNSConfig) SetSyncType(v string)` + +SetSyncType sets SyncType field to given value. + +### HasSyncType + +`func (o *DNSConfig) HasSyncType() bool` + +HasSyncType returns a boolean if a field has been set. + +### GetViewId + +`func (o *DNSConfig) GetViewId() string` + +GetViewId returns the ViewId field if non-nil, zero value otherwise. + +### GetViewIdOk + +`func (o *DNSConfig) GetViewIdOk() (*string, bool)` + +GetViewIdOk returns a tuple with the ViewId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetViewId + +`func (o *DNSConfig) SetViewId(v string)` + +SetViewId sets ViewId field to given value. + +### HasViewId + +`func (o *DNSConfig) HasViewId() bool` + +HasViewId returns a boolean if a field has been set. + +### GetViewName + +`func (o *DNSConfig) GetViewName() string` + +GetViewName returns the ViewName field if non-nil, zero value otherwise. + +### GetViewNameOk + +`func (o *DNSConfig) GetViewNameOk() (*string, bool)` + +GetViewNameOk returns a tuple with the ViewName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetViewName + +`func (o *DNSConfig) SetViewName(v string)` + +SetViewName sets ViewName field to given value. + +### HasViewName + +`func (o *DNSConfig) HasViewName() bool` + +HasViewName returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/Destination.md b/clouddiscovery/docs/Destination.md new file mode 100644 index 0000000..4280548 --- /dev/null +++ b/clouddiscovery/docs/Destination.md @@ -0,0 +1,181 @@ +# Destination + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Config** | Pointer to [**DestinationConfig**](DestinationConfig.md) | Destination configuration. Ex.: '{ \"dns\": { \"view_name\": \"view 1\", \"view_id\": \"dns/view/v1\", \"consolidated_zone_data_enabled\": false, \"sync_type\": \"read_only/read_write\" \"split_view_enabled\": false }, \"ipam\": { \"ip_space\": \"\", }, \"account\": {}, }'. | [optional] +**CreatedAt** | Pointer to **time.Time** | Timestamp when the object has been created. | [optional] [readonly] +**DeletedAt** | Pointer to **time.Time** | Timestamp when the object has been deleted. | [optional] [readonly] +**DestinationType** | **string** | Destination type: DNS / IPAM / ACCOUNT. | +**Id** | Pointer to **string** | Auto-generated unique destination ID. Format BloxID. | [optional] [readonly] +**UpdatedAt** | Pointer to **time.Time** | Timestamp when the object has been updated. | [optional] [readonly] + +## Methods + +### NewDestination + +`func NewDestination(destinationType string, ) *Destination` + +NewDestination instantiates a new Destination 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 + +### NewDestinationWithDefaults + +`func NewDestinationWithDefaults() *Destination` + +NewDestinationWithDefaults instantiates a new Destination 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 + +### GetConfig + +`func (o *Destination) GetConfig() DestinationConfig` + +GetConfig returns the Config field if non-nil, zero value otherwise. + +### GetConfigOk + +`func (o *Destination) GetConfigOk() (*DestinationConfig, bool)` + +GetConfigOk returns a tuple with the Config field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetConfig + +`func (o *Destination) SetConfig(v DestinationConfig)` + +SetConfig sets Config field to given value. + +### HasConfig + +`func (o *Destination) HasConfig() bool` + +HasConfig returns a boolean if a field has been set. + +### GetCreatedAt + +`func (o *Destination) GetCreatedAt() time.Time` + +GetCreatedAt returns the CreatedAt field if non-nil, zero value otherwise. + +### GetCreatedAtOk + +`func (o *Destination) GetCreatedAtOk() (*time.Time, bool)` + +GetCreatedAtOk returns a tuple with the CreatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCreatedAt + +`func (o *Destination) SetCreatedAt(v time.Time)` + +SetCreatedAt sets CreatedAt field to given value. + +### HasCreatedAt + +`func (o *Destination) HasCreatedAt() bool` + +HasCreatedAt returns a boolean if a field has been set. + +### GetDeletedAt + +`func (o *Destination) GetDeletedAt() time.Time` + +GetDeletedAt returns the DeletedAt field if non-nil, zero value otherwise. + +### GetDeletedAtOk + +`func (o *Destination) GetDeletedAtOk() (*time.Time, bool)` + +GetDeletedAtOk returns a tuple with the DeletedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeletedAt + +`func (o *Destination) SetDeletedAt(v time.Time)` + +SetDeletedAt sets DeletedAt field to given value. + +### HasDeletedAt + +`func (o *Destination) HasDeletedAt() bool` + +HasDeletedAt returns a boolean if a field has been set. + +### GetDestinationType + +`func (o *Destination) GetDestinationType() string` + +GetDestinationType returns the DestinationType field if non-nil, zero value otherwise. + +### GetDestinationTypeOk + +`func (o *Destination) GetDestinationTypeOk() (*string, bool)` + +GetDestinationTypeOk returns a tuple with the DestinationType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDestinationType + +`func (o *Destination) SetDestinationType(v string)` + +SetDestinationType sets DestinationType field to given value. + + +### GetId + +`func (o *Destination) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Destination) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *Destination) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *Destination) HasId() bool` + +HasId returns a boolean if a field has been set. + +### GetUpdatedAt + +`func (o *Destination) GetUpdatedAt() time.Time` + +GetUpdatedAt returns the UpdatedAt field if non-nil, zero value otherwise. + +### GetUpdatedAtOk + +`func (o *Destination) GetUpdatedAtOk() (*time.Time, bool)` + +GetUpdatedAtOk returns a tuple with the UpdatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetUpdatedAt + +`func (o *Destination) SetUpdatedAt(v time.Time)` + +SetUpdatedAt sets UpdatedAt field to given value. + +### HasUpdatedAt + +`func (o *Destination) HasUpdatedAt() bool` + +HasUpdatedAt returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/DestinationConfig.md b/clouddiscovery/docs/DestinationConfig.md new file mode 100644 index 0000000..f180dd2 --- /dev/null +++ b/clouddiscovery/docs/DestinationConfig.md @@ -0,0 +1,82 @@ +# DestinationConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Dns** | Pointer to [**DNSConfig**](DNSConfig.md) | | [optional] +**Ipam** | Pointer to [**IPAMConfig**](IPAMConfig.md) | | [optional] + +## Methods + +### NewDestinationConfig + +`func NewDestinationConfig() *DestinationConfig` + +NewDestinationConfig instantiates a new DestinationConfig 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 + +### NewDestinationConfigWithDefaults + +`func NewDestinationConfigWithDefaults() *DestinationConfig` + +NewDestinationConfigWithDefaults instantiates a new DestinationConfig 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 + +### GetDns + +`func (o *DestinationConfig) GetDns() DNSConfig` + +GetDns returns the Dns field if non-nil, zero value otherwise. + +### GetDnsOk + +`func (o *DestinationConfig) GetDnsOk() (*DNSConfig, bool)` + +GetDnsOk returns a tuple with the Dns field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDns + +`func (o *DestinationConfig) SetDns(v DNSConfig)` + +SetDns sets Dns field to given value. + +### HasDns + +`func (o *DestinationConfig) HasDns() bool` + +HasDns returns a boolean if a field has been set. + +### GetIpam + +`func (o *DestinationConfig) GetIpam() IPAMConfig` + +GetIpam returns the Ipam field if non-nil, zero value otherwise. + +### GetIpamOk + +`func (o *DestinationConfig) GetIpamOk() (*IPAMConfig, bool)` + +GetIpamOk returns a tuple with the Ipam field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetIpam + +`func (o *DestinationConfig) SetIpam(v IPAMConfig)` + +SetIpam sets Ipam field to given value. + +### HasIpam + +`func (o *DestinationConfig) HasIpam() bool` + +HasIpam returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/DiscoveryConfig.md b/clouddiscovery/docs/DiscoveryConfig.md new file mode 100644 index 0000000..c2eea83 --- /dev/null +++ b/clouddiscovery/docs/DiscoveryConfig.md @@ -0,0 +1,519 @@ +# DiscoveryConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AccountPreference** | Pointer to **string** | Account preference. For ex.: single, multiple, auto-discover-multiple. | [optional] +**AdditionalConfig** | Pointer to [**AdditionalConfig**](AdditionalConfig.md) | Additional configuration. Ex.: '{ \"excluded_object_types\": [], \"exclusion_account_list\": [], \"zone_forwarding\": \"true\" or \"false\" }'. | [optional] +**CreatedAt** | Pointer to **time.Time** | Timestamp when the object has been created. | [optional] [readonly] +**CredentialPreference** | Pointer to [**CredentialPreference**](CredentialPreference.md) | Credential preference. Ex.: '{ \"type\": \"static\" or \"delegated\", \"access_identifier_type\": \"role_arn\" or \"tenant_id\" or \"project_id\" }'. | [optional] +**DeletedAt** | Pointer to **time.Time** | Timestamp when the object has been deleted. | [optional] [readonly] +**Description** | Pointer to **string** | Description of the discovery config. Optional. | [optional] +**DesiredState** | Pointer to **string** | Desired state. Default is \"enabled\". | [optional] +**DestinationTypesEnabled** | Pointer to **[]string** | Destinations types enabled: Ex.: DNS, IPAM and ACCOUNT. | [optional] +**Destinations** | Pointer to [**[]Destination**](Destination.md) | Destinations. | [optional] +**Id** | Pointer to **string** | Auto-generated unique discovery config ID. Format BloxID. | [optional] [readonly] +**LastSync** | Pointer to **time.Time** | Last sync timestamp. | [optional] +**Name** | **string** | Name of the discovery config. | +**ProviderType** | Pointer to **string** | Provider type. Ex.: Amazon Web Services, Google Cloud Platform, Microsoft Azure. | [optional] +**SourceConfigs** | Pointer to [**[]SourceConfig**](SourceConfig.md) | Source configs. | [optional] +**Status** | Pointer to **string** | Status of the sync operation. In single account case, Its the combined status of account & all the destinations statuses In auto discover case, Its the status of the account discovery only. | [optional] +**StatusMessage** | Pointer to **string** | Aggregate status message of the sync operation. | [optional] +**SyncInterval** | Pointer to **string** | | [optional] +**Tags** | Pointer to **map[string]interface{}** | Tagging specifics. | [optional] +**UpdatedAt** | Pointer to **time.Time** | Timestamp when the object has been updated. | [optional] [readonly] + +## Methods + +### NewDiscoveryConfig + +`func NewDiscoveryConfig(name string, ) *DiscoveryConfig` + +NewDiscoveryConfig instantiates a new DiscoveryConfig 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 + +### NewDiscoveryConfigWithDefaults + +`func NewDiscoveryConfigWithDefaults() *DiscoveryConfig` + +NewDiscoveryConfigWithDefaults instantiates a new DiscoveryConfig 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 + +### GetAccountPreference + +`func (o *DiscoveryConfig) GetAccountPreference() string` + +GetAccountPreference returns the AccountPreference field if non-nil, zero value otherwise. + +### GetAccountPreferenceOk + +`func (o *DiscoveryConfig) GetAccountPreferenceOk() (*string, bool)` + +GetAccountPreferenceOk returns a tuple with the AccountPreference field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAccountPreference + +`func (o *DiscoveryConfig) SetAccountPreference(v string)` + +SetAccountPreference sets AccountPreference field to given value. + +### HasAccountPreference + +`func (o *DiscoveryConfig) HasAccountPreference() bool` + +HasAccountPreference returns a boolean if a field has been set. + +### GetAdditionalConfig + +`func (o *DiscoveryConfig) GetAdditionalConfig() AdditionalConfig` + +GetAdditionalConfig returns the AdditionalConfig field if non-nil, zero value otherwise. + +### GetAdditionalConfigOk + +`func (o *DiscoveryConfig) GetAdditionalConfigOk() (*AdditionalConfig, bool)` + +GetAdditionalConfigOk returns a tuple with the AdditionalConfig field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAdditionalConfig + +`func (o *DiscoveryConfig) SetAdditionalConfig(v AdditionalConfig)` + +SetAdditionalConfig sets AdditionalConfig field to given value. + +### HasAdditionalConfig + +`func (o *DiscoveryConfig) HasAdditionalConfig() bool` + +HasAdditionalConfig returns a boolean if a field has been set. + +### GetCreatedAt + +`func (o *DiscoveryConfig) GetCreatedAt() time.Time` + +GetCreatedAt returns the CreatedAt field if non-nil, zero value otherwise. + +### GetCreatedAtOk + +`func (o *DiscoveryConfig) GetCreatedAtOk() (*time.Time, bool)` + +GetCreatedAtOk returns a tuple with the CreatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCreatedAt + +`func (o *DiscoveryConfig) SetCreatedAt(v time.Time)` + +SetCreatedAt sets CreatedAt field to given value. + +### HasCreatedAt + +`func (o *DiscoveryConfig) HasCreatedAt() bool` + +HasCreatedAt returns a boolean if a field has been set. + +### GetCredentialPreference + +`func (o *DiscoveryConfig) GetCredentialPreference() CredentialPreference` + +GetCredentialPreference returns the CredentialPreference field if non-nil, zero value otherwise. + +### GetCredentialPreferenceOk + +`func (o *DiscoveryConfig) GetCredentialPreferenceOk() (*CredentialPreference, bool)` + +GetCredentialPreferenceOk returns a tuple with the CredentialPreference field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCredentialPreference + +`func (o *DiscoveryConfig) SetCredentialPreference(v CredentialPreference)` + +SetCredentialPreference sets CredentialPreference field to given value. + +### HasCredentialPreference + +`func (o *DiscoveryConfig) HasCredentialPreference() bool` + +HasCredentialPreference returns a boolean if a field has been set. + +### GetDeletedAt + +`func (o *DiscoveryConfig) GetDeletedAt() time.Time` + +GetDeletedAt returns the DeletedAt field if non-nil, zero value otherwise. + +### GetDeletedAtOk + +`func (o *DiscoveryConfig) GetDeletedAtOk() (*time.Time, bool)` + +GetDeletedAtOk returns a tuple with the DeletedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeletedAt + +`func (o *DiscoveryConfig) SetDeletedAt(v time.Time)` + +SetDeletedAt sets DeletedAt field to given value. + +### HasDeletedAt + +`func (o *DiscoveryConfig) HasDeletedAt() bool` + +HasDeletedAt returns a boolean if a field has been set. + +### GetDescription + +`func (o *DiscoveryConfig) GetDescription() string` + +GetDescription returns the Description field if non-nil, zero value otherwise. + +### GetDescriptionOk + +`func (o *DiscoveryConfig) GetDescriptionOk() (*string, bool)` + +GetDescriptionOk returns a tuple with the Description field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDescription + +`func (o *DiscoveryConfig) SetDescription(v string)` + +SetDescription sets Description field to given value. + +### HasDescription + +`func (o *DiscoveryConfig) HasDescription() bool` + +HasDescription returns a boolean if a field has been set. + +### GetDesiredState + +`func (o *DiscoveryConfig) GetDesiredState() string` + +GetDesiredState returns the DesiredState field if non-nil, zero value otherwise. + +### GetDesiredStateOk + +`func (o *DiscoveryConfig) GetDesiredStateOk() (*string, bool)` + +GetDesiredStateOk returns a tuple with the DesiredState field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDesiredState + +`func (o *DiscoveryConfig) SetDesiredState(v string)` + +SetDesiredState sets DesiredState field to given value. + +### HasDesiredState + +`func (o *DiscoveryConfig) HasDesiredState() bool` + +HasDesiredState returns a boolean if a field has been set. + +### GetDestinationTypesEnabled + +`func (o *DiscoveryConfig) GetDestinationTypesEnabled() []string` + +GetDestinationTypesEnabled returns the DestinationTypesEnabled field if non-nil, zero value otherwise. + +### GetDestinationTypesEnabledOk + +`func (o *DiscoveryConfig) GetDestinationTypesEnabledOk() (*[]string, bool)` + +GetDestinationTypesEnabledOk returns a tuple with the DestinationTypesEnabled field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDestinationTypesEnabled + +`func (o *DiscoveryConfig) SetDestinationTypesEnabled(v []string)` + +SetDestinationTypesEnabled sets DestinationTypesEnabled field to given value. + +### HasDestinationTypesEnabled + +`func (o *DiscoveryConfig) HasDestinationTypesEnabled() bool` + +HasDestinationTypesEnabled returns a boolean if a field has been set. + +### GetDestinations + +`func (o *DiscoveryConfig) GetDestinations() []Destination` + +GetDestinations returns the Destinations field if non-nil, zero value otherwise. + +### GetDestinationsOk + +`func (o *DiscoveryConfig) GetDestinationsOk() (*[]Destination, bool)` + +GetDestinationsOk returns a tuple with the Destinations field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDestinations + +`func (o *DiscoveryConfig) SetDestinations(v []Destination)` + +SetDestinations sets Destinations field to given value. + +### HasDestinations + +`func (o *DiscoveryConfig) HasDestinations() bool` + +HasDestinations returns a boolean if a field has been set. + +### GetId + +`func (o *DiscoveryConfig) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *DiscoveryConfig) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *DiscoveryConfig) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *DiscoveryConfig) HasId() bool` + +HasId returns a boolean if a field has been set. + +### GetLastSync + +`func (o *DiscoveryConfig) GetLastSync() time.Time` + +GetLastSync returns the LastSync field if non-nil, zero value otherwise. + +### GetLastSyncOk + +`func (o *DiscoveryConfig) GetLastSyncOk() (*time.Time, bool)` + +GetLastSyncOk returns a tuple with the LastSync field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetLastSync + +`func (o *DiscoveryConfig) SetLastSync(v time.Time)` + +SetLastSync sets LastSync field to given value. + +### HasLastSync + +`func (o *DiscoveryConfig) HasLastSync() bool` + +HasLastSync returns a boolean if a field has been set. + +### GetName + +`func (o *DiscoveryConfig) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *DiscoveryConfig) GetNameOk() (*string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetName + +`func (o *DiscoveryConfig) SetName(v string)` + +SetName sets Name field to given value. + + +### GetProviderType + +`func (o *DiscoveryConfig) GetProviderType() string` + +GetProviderType returns the ProviderType field if non-nil, zero value otherwise. + +### GetProviderTypeOk + +`func (o *DiscoveryConfig) GetProviderTypeOk() (*string, bool)` + +GetProviderTypeOk returns a tuple with the ProviderType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetProviderType + +`func (o *DiscoveryConfig) SetProviderType(v string)` + +SetProviderType sets ProviderType field to given value. + +### HasProviderType + +`func (o *DiscoveryConfig) HasProviderType() bool` + +HasProviderType returns a boolean if a field has been set. + +### GetSourceConfigs + +`func (o *DiscoveryConfig) GetSourceConfigs() []SourceConfig` + +GetSourceConfigs returns the SourceConfigs field if non-nil, zero value otherwise. + +### GetSourceConfigsOk + +`func (o *DiscoveryConfig) GetSourceConfigsOk() (*[]SourceConfig, bool)` + +GetSourceConfigsOk returns a tuple with the SourceConfigs field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSourceConfigs + +`func (o *DiscoveryConfig) SetSourceConfigs(v []SourceConfig)` + +SetSourceConfigs sets SourceConfigs field to given value. + +### HasSourceConfigs + +`func (o *DiscoveryConfig) HasSourceConfigs() bool` + +HasSourceConfigs returns a boolean if a field has been set. + +### GetStatus + +`func (o *DiscoveryConfig) GetStatus() string` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *DiscoveryConfig) GetStatusOk() (*string, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatus + +`func (o *DiscoveryConfig) SetStatus(v string)` + +SetStatus sets Status field to given value. + +### HasStatus + +`func (o *DiscoveryConfig) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + +### GetStatusMessage + +`func (o *DiscoveryConfig) GetStatusMessage() string` + +GetStatusMessage returns the StatusMessage field if non-nil, zero value otherwise. + +### GetStatusMessageOk + +`func (o *DiscoveryConfig) GetStatusMessageOk() (*string, bool)` + +GetStatusMessageOk returns a tuple with the StatusMessage field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatusMessage + +`func (o *DiscoveryConfig) SetStatusMessage(v string)` + +SetStatusMessage sets StatusMessage field to given value. + +### HasStatusMessage + +`func (o *DiscoveryConfig) HasStatusMessage() bool` + +HasStatusMessage returns a boolean if a field has been set. + +### GetSyncInterval + +`func (o *DiscoveryConfig) GetSyncInterval() string` + +GetSyncInterval returns the SyncInterval field if non-nil, zero value otherwise. + +### GetSyncIntervalOk + +`func (o *DiscoveryConfig) GetSyncIntervalOk() (*string, bool)` + +GetSyncIntervalOk returns a tuple with the SyncInterval field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetSyncInterval + +`func (o *DiscoveryConfig) SetSyncInterval(v string)` + +SetSyncInterval sets SyncInterval field to given value. + +### HasSyncInterval + +`func (o *DiscoveryConfig) HasSyncInterval() bool` + +HasSyncInterval returns a boolean if a field has been set. + +### GetTags + +`func (o *DiscoveryConfig) GetTags() map[string]interface{}` + +GetTags returns the Tags field if non-nil, zero value otherwise. + +### GetTagsOk + +`func (o *DiscoveryConfig) GetTagsOk() (*map[string]interface{}, bool)` + +GetTagsOk returns a tuple with the Tags field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTags + +`func (o *DiscoveryConfig) SetTags(v map[string]interface{})` + +SetTags sets Tags field to given value. + +### HasTags + +`func (o *DiscoveryConfig) HasTags() bool` + +HasTags returns a boolean if a field has been set. + +### GetUpdatedAt + +`func (o *DiscoveryConfig) GetUpdatedAt() time.Time` + +GetUpdatedAt returns the UpdatedAt field if non-nil, zero value otherwise. + +### GetUpdatedAtOk + +`func (o *DiscoveryConfig) GetUpdatedAtOk() (*time.Time, bool)` + +GetUpdatedAtOk returns a tuple with the UpdatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetUpdatedAt + +`func (o *DiscoveryConfig) SetUpdatedAt(v time.Time)` + +SetUpdatedAt sets UpdatedAt field to given value. + +### HasUpdatedAt + +`func (o *DiscoveryConfig) HasUpdatedAt() bool` + +HasUpdatedAt returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/IPAMConfig.md b/clouddiscovery/docs/IPAMConfig.md new file mode 100644 index 0000000..bd46e26 --- /dev/null +++ b/clouddiscovery/docs/IPAMConfig.md @@ -0,0 +1,82 @@ +# IPAMConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**DhcpServer** | Pointer to **string** | | [optional] +**IpSpace** | Pointer to **string** | | [optional] + +## Methods + +### NewIPAMConfig + +`func NewIPAMConfig() *IPAMConfig` + +NewIPAMConfig instantiates a new IPAMConfig 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 + +### NewIPAMConfigWithDefaults + +`func NewIPAMConfigWithDefaults() *IPAMConfig` + +NewIPAMConfigWithDefaults instantiates a new IPAMConfig 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 + +### GetDhcpServer + +`func (o *IPAMConfig) GetDhcpServer() string` + +GetDhcpServer returns the DhcpServer field if non-nil, zero value otherwise. + +### GetDhcpServerOk + +`func (o *IPAMConfig) GetDhcpServerOk() (*string, bool)` + +GetDhcpServerOk returns a tuple with the DhcpServer field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDhcpServer + +`func (o *IPAMConfig) SetDhcpServer(v string)` + +SetDhcpServer sets DhcpServer field to given value. + +### HasDhcpServer + +`func (o *IPAMConfig) HasDhcpServer() bool` + +HasDhcpServer returns a boolean if a field has been set. + +### GetIpSpace + +`func (o *IPAMConfig) GetIpSpace() string` + +GetIpSpace returns the IpSpace field if non-nil, zero value otherwise. + +### GetIpSpaceOk + +`func (o *IPAMConfig) GetIpSpaceOk() (*string, bool)` + +GetIpSpaceOk returns a tuple with the IpSpace field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetIpSpace + +`func (o *IPAMConfig) SetIpSpace(v string)` + +SetIpSpace sets IpSpace field to given value. + +### HasIpSpace + +`func (o *IPAMConfig) HasIpSpace() bool` + +HasIpSpace returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/Object.md b/clouddiscovery/docs/Object.md new file mode 100644 index 0000000..544101e --- /dev/null +++ b/clouddiscovery/docs/Object.md @@ -0,0 +1,82 @@ +# Object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Category** | Pointer to [**Category**](Category.md) | | [optional] +**ResourceSet** | Pointer to [**[]Resource**](Resource.md) | | [optional] + +## Methods + +### NewObject + +`func NewObject() *Object` + +NewObject instantiates a new Object 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 + +### NewObjectWithDefaults + +`func NewObjectWithDefaults() *Object` + +NewObjectWithDefaults instantiates a new Object 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 + +### GetCategory + +`func (o *Object) GetCategory() Category` + +GetCategory returns the Category field if non-nil, zero value otherwise. + +### GetCategoryOk + +`func (o *Object) GetCategoryOk() (*Category, bool)` + +GetCategoryOk returns a tuple with the Category field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCategory + +`func (o *Object) SetCategory(v Category)` + +SetCategory sets Category field to given value. + +### HasCategory + +`func (o *Object) HasCategory() bool` + +HasCategory returns a boolean if a field has been set. + +### GetResourceSet + +`func (o *Object) GetResourceSet() []Resource` + +GetResourceSet returns the ResourceSet field if non-nil, zero value otherwise. + +### GetResourceSetOk + +`func (o *Object) GetResourceSetOk() (*[]Resource, bool)` + +GetResourceSetOk returns a tuple with the ResourceSet field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResourceSet + +`func (o *Object) SetResourceSet(v []Resource)` + +SetResourceSet sets ResourceSet field to given value. + +### HasResourceSet + +`func (o *Object) HasResourceSet() bool` + +HasResourceSet returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ObjectType.md b/clouddiscovery/docs/ObjectType.md new file mode 100644 index 0000000..d7d64e4 --- /dev/null +++ b/clouddiscovery/docs/ObjectType.md @@ -0,0 +1,108 @@ +# ObjectType + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**DiscoverNew** | Pointer to **bool** | | [optional] +**Objects** | Pointer to [**[]Object**](Object.md) | | [optional] +**Version** | Pointer to **float32** | | [optional] + +## Methods + +### NewObjectType + +`func NewObjectType() *ObjectType` + +NewObjectType instantiates a new ObjectType 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 + +### NewObjectTypeWithDefaults + +`func NewObjectTypeWithDefaults() *ObjectType` + +NewObjectTypeWithDefaults instantiates a new ObjectType 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 + +### GetDiscoverNew + +`func (o *ObjectType) GetDiscoverNew() bool` + +GetDiscoverNew returns the DiscoverNew field if non-nil, zero value otherwise. + +### GetDiscoverNewOk + +`func (o *ObjectType) GetDiscoverNewOk() (*bool, bool)` + +GetDiscoverNewOk returns a tuple with the DiscoverNew field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDiscoverNew + +`func (o *ObjectType) SetDiscoverNew(v bool)` + +SetDiscoverNew sets DiscoverNew field to given value. + +### HasDiscoverNew + +`func (o *ObjectType) HasDiscoverNew() bool` + +HasDiscoverNew returns a boolean if a field has been set. + +### GetObjects + +`func (o *ObjectType) GetObjects() []Object` + +GetObjects returns the Objects field if non-nil, zero value otherwise. + +### GetObjectsOk + +`func (o *ObjectType) GetObjectsOk() (*[]Object, bool)` + +GetObjectsOk returns a tuple with the Objects field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetObjects + +`func (o *ObjectType) SetObjects(v []Object)` + +SetObjects sets Objects field to given value. + +### HasObjects + +`func (o *ObjectType) HasObjects() bool` + +HasObjects returns a boolean if a field has been set. + +### GetVersion + +`func (o *ObjectType) GetVersion() float32` + +GetVersion returns the Version field if non-nil, zero value otherwise. + +### GetVersionOk + +`func (o *ObjectType) GetVersionOk() (*float32, bool)` + +GetVersionOk returns a tuple with the Version field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetVersion + +`func (o *ObjectType) SetVersion(v float32)` + +SetVersion sets Version field to given value. + +### HasVersion + +`func (o *ObjectType) HasVersion() bool` + +HasVersion returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ProviderCreateResponse.md b/clouddiscovery/docs/ProviderCreateResponse.md new file mode 100644 index 0000000..1d79bbc --- /dev/null +++ b/clouddiscovery/docs/ProviderCreateResponse.md @@ -0,0 +1,56 @@ +# ProviderCreateResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Result** | Pointer to [**DiscoveryConfig**](DiscoveryConfig.md) | | [optional] + +## Methods + +### NewProviderCreateResponse + +`func NewProviderCreateResponse() *ProviderCreateResponse` + +NewProviderCreateResponse instantiates a new ProviderCreateResponse 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 + +### NewProviderCreateResponseWithDefaults + +`func NewProviderCreateResponseWithDefaults() *ProviderCreateResponse` + +NewProviderCreateResponseWithDefaults instantiates a new ProviderCreateResponse 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 + +### GetResult + +`func (o *ProviderCreateResponse) GetResult() DiscoveryConfig` + +GetResult returns the Result field if non-nil, zero value otherwise. + +### GetResultOk + +`func (o *ProviderCreateResponse) GetResultOk() (*DiscoveryConfig, bool)` + +GetResultOk returns a tuple with the Result field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResult + +`func (o *ProviderCreateResponse) SetResult(v DiscoveryConfig)` + +SetResult sets Result field to given value. + +### HasResult + +`func (o *ProviderCreateResponse) HasResult() bool` + +HasResult returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ProviderListResponse.md b/clouddiscovery/docs/ProviderListResponse.md new file mode 100644 index 0000000..112632b --- /dev/null +++ b/clouddiscovery/docs/ProviderListResponse.md @@ -0,0 +1,82 @@ +# ProviderListResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Page** | Pointer to [**ApiPageInfo**](ApiPageInfo.md) | | [optional] +**Results** | Pointer to [**[]DiscoveryConfig**](DiscoveryConfig.md) | | [optional] + +## Methods + +### NewProviderListResponse + +`func NewProviderListResponse() *ProviderListResponse` + +NewProviderListResponse instantiates a new ProviderListResponse 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 + +### NewProviderListResponseWithDefaults + +`func NewProviderListResponseWithDefaults() *ProviderListResponse` + +NewProviderListResponseWithDefaults instantiates a new ProviderListResponse 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 + +### GetPage + +`func (o *ProviderListResponse) GetPage() ApiPageInfo` + +GetPage returns the Page field if non-nil, zero value otherwise. + +### GetPageOk + +`func (o *ProviderListResponse) GetPageOk() (*ApiPageInfo, bool)` + +GetPageOk returns a tuple with the Page field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPage + +`func (o *ProviderListResponse) SetPage(v ApiPageInfo)` + +SetPage sets Page field to given value. + +### HasPage + +`func (o *ProviderListResponse) HasPage() bool` + +HasPage returns a boolean if a field has been set. + +### GetResults + +`func (o *ProviderListResponse) GetResults() []DiscoveryConfig` + +GetResults returns the Results field if non-nil, zero value otherwise. + +### GetResultsOk + +`func (o *ProviderListResponse) GetResultsOk() (*[]DiscoveryConfig, bool)` + +GetResultsOk returns a tuple with the Results field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResults + +`func (o *ProviderListResponse) SetResults(v []DiscoveryConfig)` + +SetResults sets Results field to given value. + +### HasResults + +`func (o *ProviderListResponse) HasResults() bool` + +HasResults returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ProviderReadResponse.md b/clouddiscovery/docs/ProviderReadResponse.md new file mode 100644 index 0000000..47736aa --- /dev/null +++ b/clouddiscovery/docs/ProviderReadResponse.md @@ -0,0 +1,56 @@ +# ProviderReadResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Result** | Pointer to [**DiscoveryConfig**](DiscoveryConfig.md) | | [optional] + +## Methods + +### NewProviderReadResponse + +`func NewProviderReadResponse() *ProviderReadResponse` + +NewProviderReadResponse instantiates a new ProviderReadResponse 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 + +### NewProviderReadResponseWithDefaults + +`func NewProviderReadResponseWithDefaults() *ProviderReadResponse` + +NewProviderReadResponseWithDefaults instantiates a new ProviderReadResponse 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 + +### GetResult + +`func (o *ProviderReadResponse) GetResult() DiscoveryConfig` + +GetResult returns the Result field if non-nil, zero value otherwise. + +### GetResultOk + +`func (o *ProviderReadResponse) GetResultOk() (*DiscoveryConfig, bool)` + +GetResultOk returns a tuple with the Result field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResult + +`func (o *ProviderReadResponse) SetResult(v DiscoveryConfig)` + +SetResult sets Result field to given value. + +### HasResult + +`func (o *ProviderReadResponse) HasResult() bool` + +HasResult returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ProviderUpdateResponse.md b/clouddiscovery/docs/ProviderUpdateResponse.md new file mode 100644 index 0000000..42486b7 --- /dev/null +++ b/clouddiscovery/docs/ProviderUpdateResponse.md @@ -0,0 +1,56 @@ +# ProviderUpdateResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Result** | Pointer to [**DiscoveryConfig**](DiscoveryConfig.md) | | [optional] + +## Methods + +### NewProviderUpdateResponse + +`func NewProviderUpdateResponse() *ProviderUpdateResponse` + +NewProviderUpdateResponse instantiates a new ProviderUpdateResponse 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 + +### NewProviderUpdateResponseWithDefaults + +`func NewProviderUpdateResponseWithDefaults() *ProviderUpdateResponse` + +NewProviderUpdateResponseWithDefaults instantiates a new ProviderUpdateResponse 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 + +### GetResult + +`func (o *ProviderUpdateResponse) GetResult() DiscoveryConfig` + +GetResult returns the Result field if non-nil, zero value otherwise. + +### GetResultOk + +`func (o *ProviderUpdateResponse) GetResultOk() (*DiscoveryConfig, bool)` + +GetResultOk returns a tuple with the Result field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResult + +`func (o *ProviderUpdateResponse) SetResult(v DiscoveryConfig)` + +SetResult sets Result field to given value. + +### HasResult + +`func (o *ProviderUpdateResponse) HasResult() bool` + +HasResult returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/ProvidersAPI.md b/clouddiscovery/docs/ProvidersAPI.md new file mode 100644 index 0000000..6e13e1a --- /dev/null +++ b/clouddiscovery/docs/ProvidersAPI.md @@ -0,0 +1,359 @@ +# ProvidersAPI + +All URIs are relative to *http://csp.infoblox.com/api/cloud_discovery/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**Create**](ProvidersAPI.md#Create) | **Post** /providers | Create Provider +[**Delete**](ProvidersAPI.md#Delete) | **Delete** /providers/{id} | Delete Provider +[**List**](ProvidersAPI.md#List) | **Get** /providers | List Provider +[**Read**](ProvidersAPI.md#Read) | **Get** /providers/{id} | Read Provider +[**Update**](ProvidersAPI.md#Update) | **Put** /providers/{id} | Update Provider + + + +## Create + +> ProviderCreateResponse Create(ctx).Body(body).Execute() + +Create Provider + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + body := *clouddiscovery.NewDiscoveryConfig("Name_example") // DiscoveryConfig | + + apiClient := clouddiscovery.NewAPIClient() + resp, r, err := apiClient.ProvidersAPI.Create(context.Background()).Body(body).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `ProvidersAPI.Create``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `Create`: ProviderCreateResponse + fmt.Fprintf(os.Stdout, "Response from `ProvidersAPI.Create`: %v\n", resp) +} +``` + +### Path Parameters + + + +### Other Parameters + +Other parameters are passed through a pointer to a `ProvidersAPICreateRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**body** | [**DiscoveryConfig**](DiscoveryConfig.md) | | + +### Return type + +[**ProviderCreateResponse**](ProviderCreateResponse.md) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## Delete + +> Delete(ctx, id).Execute() + +Delete Provider + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + id := "a5183192-1e00-475f-b334-38e1f0bb1bc7" // string | + + apiClient := clouddiscovery.NewAPIClient() + r, err := apiClient.ProvidersAPI.Delete(context.Background(), id).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `ProvidersAPI.Delete``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } +} +``` + +### Path Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. +**id** | **string** | | + +### Other Parameters + +Other parameters are passed through a pointer to a `ProvidersAPIDeleteRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + +### Return type + + (empty response body) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: Not defined + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## List + +> ProviderListResponse List(ctx).Fields(fields).Filter(filter).Offset(offset).Limit(limit).PageToken(pageToken).OrderBy(orderBy).Tfilter(tfilter).TorderBy(torderBy).Execute() + +List Provider + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + + apiClient := clouddiscovery.NewAPIClient() + resp, r, err := apiClient.ProvidersAPI.List(context.Background()).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `ProvidersAPI.List``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `List`: ProviderListResponse + fmt.Fprintf(os.Stdout, "Response from `ProvidersAPI.List`: %v\n", resp) +} +``` + +### Path Parameters + + + +### Other Parameters + +Other parameters are passed through a pointer to a `ProvidersAPIListRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**fields** | **string** | A collection of response resources can be transformed by specifying a set of JSON tags to be returned. For a “flat” resource, the tag name is straightforward. If field selection is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, the tag does not appear in the output resource. Specify this parameter as a comma-separated list of JSON tag names. | +**filter** | **string** | A collection of response resources can be filtered by a logical expression string that includes JSON tag references to values in each resource, literal values, and logical operators. If a resource does not have the specified tag, its value is assumed to be null. Literal values include numbers (integer and floating-point), and quoted (both single- or double-quoted) literal strings, and 'null'. The following operators are commonly used in filter expressions: | Op | Description | | -- | ----------- | | == | Equal | | != | Not Equal | | > | Greater Than | | >= | Greater Than or Equal To | | < | Less Than | | <= | Less Than or Equal To | | and | Logical AND | | ~ | Matches Regex | | !~ | Does Not Match Regex | | or | Logical OR | | not | Logical NOT | | () | Groupping Operators | | +**offset** | **int32** | The integer index (zero-origin) of the offset into a collection of resources. If omitted or null the value is assumed to be '0'. | +**limit** | **int32** | The integer number of resources to be returned in the response. The service may impose maximum value. If omitted the service may impose a default value. | +**pageToken** | **string** | The service-defined string used to identify a page of resources. A null value indicates the first page. | +**orderBy** | **string** | A collection of response resources can be sorted by their JSON tags. For a 'flat' resource, the tag name is straightforward. If sorting is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, its value is assumed to be null.) Specify this parameter as a comma-separated list of JSON tag names. The sort direction can be specified by a suffix separated by whitespace before the tag name. The suffix 'asc' sorts the data in ascending order. The suffix 'desc' sorts the data in descending order. If no suffix is specified the data is sorted in ascending order. | +**tfilter** | **string** | This parameter is used for filtering by tags. | +**torderBy** | **string** | This parameter is used for sorting by tags. | + +### Return type + +[**ProviderListResponse**](ProviderListResponse.md) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## Read + +> ProviderReadResponse Read(ctx, id).Fields(fields).Execute() + +Read Provider + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + id := "a5183192-1e00-475f-b334-38e1f0bb1bc7" // string | + + apiClient := clouddiscovery.NewAPIClient() + resp, r, err := apiClient.ProvidersAPI.Read(context.Background(), id).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `ProvidersAPI.Read``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `Read`: ProviderReadResponse + fmt.Fprintf(os.Stdout, "Response from `ProvidersAPI.Read`: %v\n", resp) +} +``` + +### Path Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. +**id** | **string** | | + +### Other Parameters + +Other parameters are passed through a pointer to a `ProvidersAPIReadRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**fields** | **string** | A collection of response resources can be transformed by specifying a set of JSON tags to be returned. For a “flat” resource, the tag name is straightforward. If field selection is allowed on non-flat hierarchical resources, the service should implement a qualified naming scheme such as dot-qualification to reference data down the hierarchy. If a resource does not have the specified tag, the tag does not appear in the output resource. Specify this parameter as a comma-separated list of JSON tag names. | + +### Return type + +[**ProviderReadResponse**](ProviderReadResponse.md) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## Update + +> ProviderUpdateResponse Update(ctx, id).Body(body).Execute() + +Update Provider + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + id := "a5183192-1e00-475f-b334-38e1f0bb1bc7" // string | Auto-generated unique discovery config ID. Format BloxID. + body := *clouddiscovery.NewDiscoveryConfig("Name_example") // DiscoveryConfig | + + apiClient := clouddiscovery.NewAPIClient() + resp, r, err := apiClient.ProvidersAPI.Update(context.Background(), id).Body(body).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `ProvidersAPI.Update``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `Update`: ProviderUpdateResponse + fmt.Fprintf(os.Stdout, "Response from `ProvidersAPI.Update`: %v\n", resp) +} +``` + +### Path Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. +**id** | **string** | Auto-generated unique discovery config ID. Format BloxID. | + +### Other Parameters + +Other parameters are passed through a pointer to a `ProvidersAPIUpdateRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**body** | [**DiscoveryConfig**](DiscoveryConfig.md) | | + +### Return type + +[**ProviderUpdateResponse**](ProviderUpdateResponse.md) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + diff --git a/clouddiscovery/docs/Resource.md b/clouddiscovery/docs/Resource.md new file mode 100644 index 0000000..5365892 --- /dev/null +++ b/clouddiscovery/docs/Resource.md @@ -0,0 +1,82 @@ +# Resource + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Excluded** | Pointer to **bool** | | [optional] +**Id** | Pointer to **string** | | [optional] [readonly] + +## Methods + +### NewResource + +`func NewResource() *Resource` + +NewResource instantiates a new Resource 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 + +### NewResourceWithDefaults + +`func NewResourceWithDefaults() *Resource` + +NewResourceWithDefaults instantiates a new Resource 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 + +### GetExcluded + +`func (o *Resource) GetExcluded() bool` + +GetExcluded returns the Excluded field if non-nil, zero value otherwise. + +### GetExcludedOk + +`func (o *Resource) GetExcludedOk() (*bool, bool)` + +GetExcludedOk returns a tuple with the Excluded field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetExcluded + +`func (o *Resource) SetExcluded(v bool)` + +SetExcluded sets Excluded field to given value. + +### HasExcluded + +`func (o *Resource) HasExcluded() bool` + +HasExcluded returns a boolean if a field has been set. + +### GetId + +`func (o *Resource) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Resource) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *Resource) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *Resource) HasId() bool` + +HasId returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/SourceConfig.md b/clouddiscovery/docs/SourceConfig.md new file mode 100644 index 0000000..c43ecec --- /dev/null +++ b/clouddiscovery/docs/SourceConfig.md @@ -0,0 +1,264 @@ +# SourceConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AccountScheduleId** | Pointer to **string** | Account Schedule ID. | [optional] [readonly] +**Accounts** | Pointer to [**[]Account**](Account.md) | | [optional] +**CloudCredentialId** | Pointer to **string** | Cloud Credential ID. | [optional] +**CreatedAt** | Pointer to **time.Time** | Timestamp when the object has been created. | [optional] [readonly] +**CredentialConfig** | Pointer to [**CredentialConfig**](CredentialConfig.md) | Credential configuration. Ex.: '{ \"access_identifier\": \"arn:aws:iam::1234:role/access_for_discovery\", \"region\": \"us-east-1\", \"enclave\": \"commercial/gov\" }'. | [optional] +**DeletedAt** | Pointer to **time.Time** | Timestamp when the object has been deleted. | [optional] [readonly] +**Id** | Pointer to **string** | Auto-generated unique source config ID. Format BloxID. | [optional] [readonly] +**RestrictedToAccounts** | Pointer to **[]string** | Provider account IDs such as accountID/ SubscriptionID to be restricted for a given source_config. | [optional] +**UpdatedAt** | Pointer to **time.Time** | Timestamp when the object has been updated. | [optional] [readonly] + +## Methods + +### NewSourceConfig + +`func NewSourceConfig() *SourceConfig` + +NewSourceConfig instantiates a new SourceConfig 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 + +### NewSourceConfigWithDefaults + +`func NewSourceConfigWithDefaults() *SourceConfig` + +NewSourceConfigWithDefaults instantiates a new SourceConfig 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 + +### GetAccountScheduleId + +`func (o *SourceConfig) GetAccountScheduleId() string` + +GetAccountScheduleId returns the AccountScheduleId field if non-nil, zero value otherwise. + +### GetAccountScheduleIdOk + +`func (o *SourceConfig) GetAccountScheduleIdOk() (*string, bool)` + +GetAccountScheduleIdOk returns a tuple with the AccountScheduleId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAccountScheduleId + +`func (o *SourceConfig) SetAccountScheduleId(v string)` + +SetAccountScheduleId sets AccountScheduleId field to given value. + +### HasAccountScheduleId + +`func (o *SourceConfig) HasAccountScheduleId() bool` + +HasAccountScheduleId returns a boolean if a field has been set. + +### GetAccounts + +`func (o *SourceConfig) GetAccounts() []Account` + +GetAccounts returns the Accounts field if non-nil, zero value otherwise. + +### GetAccountsOk + +`func (o *SourceConfig) GetAccountsOk() (*[]Account, bool)` + +GetAccountsOk returns a tuple with the Accounts field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAccounts + +`func (o *SourceConfig) SetAccounts(v []Account)` + +SetAccounts sets Accounts field to given value. + +### HasAccounts + +`func (o *SourceConfig) HasAccounts() bool` + +HasAccounts returns a boolean if a field has been set. + +### GetCloudCredentialId + +`func (o *SourceConfig) GetCloudCredentialId() string` + +GetCloudCredentialId returns the CloudCredentialId field if non-nil, zero value otherwise. + +### GetCloudCredentialIdOk + +`func (o *SourceConfig) GetCloudCredentialIdOk() (*string, bool)` + +GetCloudCredentialIdOk returns a tuple with the CloudCredentialId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCloudCredentialId + +`func (o *SourceConfig) SetCloudCredentialId(v string)` + +SetCloudCredentialId sets CloudCredentialId field to given value. + +### HasCloudCredentialId + +`func (o *SourceConfig) HasCloudCredentialId() bool` + +HasCloudCredentialId returns a boolean if a field has been set. + +### GetCreatedAt + +`func (o *SourceConfig) GetCreatedAt() time.Time` + +GetCreatedAt returns the CreatedAt field if non-nil, zero value otherwise. + +### GetCreatedAtOk + +`func (o *SourceConfig) GetCreatedAtOk() (*time.Time, bool)` + +GetCreatedAtOk returns a tuple with the CreatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCreatedAt + +`func (o *SourceConfig) SetCreatedAt(v time.Time)` + +SetCreatedAt sets CreatedAt field to given value. + +### HasCreatedAt + +`func (o *SourceConfig) HasCreatedAt() bool` + +HasCreatedAt returns a boolean if a field has been set. + +### GetCredentialConfig + +`func (o *SourceConfig) GetCredentialConfig() CredentialConfig` + +GetCredentialConfig returns the CredentialConfig field if non-nil, zero value otherwise. + +### GetCredentialConfigOk + +`func (o *SourceConfig) GetCredentialConfigOk() (*CredentialConfig, bool)` + +GetCredentialConfigOk returns a tuple with the CredentialConfig field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCredentialConfig + +`func (o *SourceConfig) SetCredentialConfig(v CredentialConfig)` + +SetCredentialConfig sets CredentialConfig field to given value. + +### HasCredentialConfig + +`func (o *SourceConfig) HasCredentialConfig() bool` + +HasCredentialConfig returns a boolean if a field has been set. + +### GetDeletedAt + +`func (o *SourceConfig) GetDeletedAt() time.Time` + +GetDeletedAt returns the DeletedAt field if non-nil, zero value otherwise. + +### GetDeletedAtOk + +`func (o *SourceConfig) GetDeletedAtOk() (*time.Time, bool)` + +GetDeletedAtOk returns a tuple with the DeletedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeletedAt + +`func (o *SourceConfig) SetDeletedAt(v time.Time)` + +SetDeletedAt sets DeletedAt field to given value. + +### HasDeletedAt + +`func (o *SourceConfig) HasDeletedAt() bool` + +HasDeletedAt returns a boolean if a field has been set. + +### GetId + +`func (o *SourceConfig) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *SourceConfig) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *SourceConfig) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *SourceConfig) HasId() bool` + +HasId returns a boolean if a field has been set. + +### GetRestrictedToAccounts + +`func (o *SourceConfig) GetRestrictedToAccounts() []string` + +GetRestrictedToAccounts returns the RestrictedToAccounts field if non-nil, zero value otherwise. + +### GetRestrictedToAccountsOk + +`func (o *SourceConfig) GetRestrictedToAccountsOk() (*[]string, bool)` + +GetRestrictedToAccountsOk returns a tuple with the RestrictedToAccounts field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetRestrictedToAccounts + +`func (o *SourceConfig) SetRestrictedToAccounts(v []string)` + +SetRestrictedToAccounts sets RestrictedToAccounts field to given value. + +### HasRestrictedToAccounts + +`func (o *SourceConfig) HasRestrictedToAccounts() bool` + +HasRestrictedToAccounts returns a boolean if a field has been set. + +### GetUpdatedAt + +`func (o *SourceConfig) GetUpdatedAt() time.Time` + +GetUpdatedAt returns the UpdatedAt field if non-nil, zero value otherwise. + +### GetUpdatedAtOk + +`func (o *SourceConfig) GetUpdatedAtOk() (*time.Time, bool)` + +GetUpdatedAtOk returns a tuple with the UpdatedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetUpdatedAt + +`func (o *SourceConfig) SetUpdatedAt(v time.Time)` + +SetUpdatedAt sets UpdatedAt field to given value. + +### HasUpdatedAt + +`func (o *SourceConfig) HasUpdatedAt() bool` + +HasUpdatedAt returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/SubAccountListRequestV2.md b/clouddiscovery/docs/SubAccountListRequestV2.md new file mode 100644 index 0000000..a50d8c0 --- /dev/null +++ b/clouddiscovery/docs/SubAccountListRequestV2.md @@ -0,0 +1,160 @@ +# SubAccountListRequestV2 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AccessType** | Pointer to **string** | | [optional] +**CredentialId** | Pointer to **string** | | [optional] +**Fields** | Pointer to **string** | atlas.api.field_selection | [optional] +**ProviderCredentialsConfig** | Pointer to [**SubAccountProvCredConfig**](SubAccountProvCredConfig.md) | | [optional] +**ProviderType** | Pointer to **string** | | [optional] + +## Methods + +### NewSubAccountListRequestV2 + +`func NewSubAccountListRequestV2() *SubAccountListRequestV2` + +NewSubAccountListRequestV2 instantiates a new SubAccountListRequestV2 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 + +### NewSubAccountListRequestV2WithDefaults + +`func NewSubAccountListRequestV2WithDefaults() *SubAccountListRequestV2` + +NewSubAccountListRequestV2WithDefaults instantiates a new SubAccountListRequestV2 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 + +### GetAccessType + +`func (o *SubAccountListRequestV2) GetAccessType() string` + +GetAccessType returns the AccessType field if non-nil, zero value otherwise. + +### GetAccessTypeOk + +`func (o *SubAccountListRequestV2) GetAccessTypeOk() (*string, bool)` + +GetAccessTypeOk returns a tuple with the AccessType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAccessType + +`func (o *SubAccountListRequestV2) SetAccessType(v string)` + +SetAccessType sets AccessType field to given value. + +### HasAccessType + +`func (o *SubAccountListRequestV2) HasAccessType() bool` + +HasAccessType returns a boolean if a field has been set. + +### GetCredentialId + +`func (o *SubAccountListRequestV2) GetCredentialId() string` + +GetCredentialId returns the CredentialId field if non-nil, zero value otherwise. + +### GetCredentialIdOk + +`func (o *SubAccountListRequestV2) GetCredentialIdOk() (*string, bool)` + +GetCredentialIdOk returns a tuple with the CredentialId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCredentialId + +`func (o *SubAccountListRequestV2) SetCredentialId(v string)` + +SetCredentialId sets CredentialId field to given value. + +### HasCredentialId + +`func (o *SubAccountListRequestV2) HasCredentialId() bool` + +HasCredentialId returns a boolean if a field has been set. + +### GetFields + +`func (o *SubAccountListRequestV2) GetFields() string` + +GetFields returns the Fields field if non-nil, zero value otherwise. + +### GetFieldsOk + +`func (o *SubAccountListRequestV2) GetFieldsOk() (*string, bool)` + +GetFieldsOk returns a tuple with the Fields field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetFields + +`func (o *SubAccountListRequestV2) SetFields(v string)` + +SetFields sets Fields field to given value. + +### HasFields + +`func (o *SubAccountListRequestV2) HasFields() bool` + +HasFields returns a boolean if a field has been set. + +### GetProviderCredentialsConfig + +`func (o *SubAccountListRequestV2) GetProviderCredentialsConfig() SubAccountProvCredConfig` + +GetProviderCredentialsConfig returns the ProviderCredentialsConfig field if non-nil, zero value otherwise. + +### GetProviderCredentialsConfigOk + +`func (o *SubAccountListRequestV2) GetProviderCredentialsConfigOk() (*SubAccountProvCredConfig, bool)` + +GetProviderCredentialsConfigOk returns a tuple with the ProviderCredentialsConfig field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetProviderCredentialsConfig + +`func (o *SubAccountListRequestV2) SetProviderCredentialsConfig(v SubAccountProvCredConfig)` + +SetProviderCredentialsConfig sets ProviderCredentialsConfig field to given value. + +### HasProviderCredentialsConfig + +`func (o *SubAccountListRequestV2) HasProviderCredentialsConfig() bool` + +HasProviderCredentialsConfig returns a boolean if a field has been set. + +### GetProviderType + +`func (o *SubAccountListRequestV2) GetProviderType() string` + +GetProviderType returns the ProviderType field if non-nil, zero value otherwise. + +### GetProviderTypeOk + +`func (o *SubAccountListRequestV2) GetProviderTypeOk() (*string, bool)` + +GetProviderTypeOk returns a tuple with the ProviderType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetProviderType + +`func (o *SubAccountListRequestV2) SetProviderType(v string)` + +SetProviderType sets ProviderType field to given value. + +### HasProviderType + +`func (o *SubAccountListRequestV2) HasProviderType() bool` + +HasProviderType returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/SubAccountListResponseV2.md b/clouddiscovery/docs/SubAccountListResponseV2.md new file mode 100644 index 0000000..0fb62af --- /dev/null +++ b/clouddiscovery/docs/SubAccountListResponseV2.md @@ -0,0 +1,82 @@ +# SubAccountListResponseV2 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Page** | Pointer to [**ApiPageInfo**](ApiPageInfo.md) | | [optional] +**Results** | Pointer to [**[]SubAccountV2**](SubAccountV2.md) | | [optional] + +## Methods + +### NewSubAccountListResponseV2 + +`func NewSubAccountListResponseV2() *SubAccountListResponseV2` + +NewSubAccountListResponseV2 instantiates a new SubAccountListResponseV2 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 + +### NewSubAccountListResponseV2WithDefaults + +`func NewSubAccountListResponseV2WithDefaults() *SubAccountListResponseV2` + +NewSubAccountListResponseV2WithDefaults instantiates a new SubAccountListResponseV2 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 + +### GetPage + +`func (o *SubAccountListResponseV2) GetPage() ApiPageInfo` + +GetPage returns the Page field if non-nil, zero value otherwise. + +### GetPageOk + +`func (o *SubAccountListResponseV2) GetPageOk() (*ApiPageInfo, bool)` + +GetPageOk returns a tuple with the Page field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPage + +`func (o *SubAccountListResponseV2) SetPage(v ApiPageInfo)` + +SetPage sets Page field to given value. + +### HasPage + +`func (o *SubAccountListResponseV2) HasPage() bool` + +HasPage returns a boolean if a field has been set. + +### GetResults + +`func (o *SubAccountListResponseV2) GetResults() []SubAccountV2` + +GetResults returns the Results field if non-nil, zero value otherwise. + +### GetResultsOk + +`func (o *SubAccountListResponseV2) GetResultsOk() (*[]SubAccountV2, bool)` + +GetResultsOk returns a tuple with the Results field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetResults + +`func (o *SubAccountListResponseV2) SetResults(v []SubAccountV2)` + +SetResults sets Results field to given value. + +### HasResults + +`func (o *SubAccountListResponseV2) HasResults() bool` + +HasResults returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/SubAccountProvCredConfig.md b/clouddiscovery/docs/SubAccountProvCredConfig.md new file mode 100644 index 0000000..aa7264e --- /dev/null +++ b/clouddiscovery/docs/SubAccountProvCredConfig.md @@ -0,0 +1,108 @@ +# SubAccountProvCredConfig + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ProjectId** | Pointer to **string** | | [optional] +**RoleArn** | Pointer to **string** | | [optional] +**TenantId** | Pointer to **string** | | [optional] + +## Methods + +### NewSubAccountProvCredConfig + +`func NewSubAccountProvCredConfig() *SubAccountProvCredConfig` + +NewSubAccountProvCredConfig instantiates a new SubAccountProvCredConfig 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 + +### NewSubAccountProvCredConfigWithDefaults + +`func NewSubAccountProvCredConfigWithDefaults() *SubAccountProvCredConfig` + +NewSubAccountProvCredConfigWithDefaults instantiates a new SubAccountProvCredConfig 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 + +### GetProjectId + +`func (o *SubAccountProvCredConfig) GetProjectId() string` + +GetProjectId returns the ProjectId field if non-nil, zero value otherwise. + +### GetProjectIdOk + +`func (o *SubAccountProvCredConfig) GetProjectIdOk() (*string, bool)` + +GetProjectIdOk returns a tuple with the ProjectId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetProjectId + +`func (o *SubAccountProvCredConfig) SetProjectId(v string)` + +SetProjectId sets ProjectId field to given value. + +### HasProjectId + +`func (o *SubAccountProvCredConfig) HasProjectId() bool` + +HasProjectId returns a boolean if a field has been set. + +### GetRoleArn + +`func (o *SubAccountProvCredConfig) GetRoleArn() string` + +GetRoleArn returns the RoleArn field if non-nil, zero value otherwise. + +### GetRoleArnOk + +`func (o *SubAccountProvCredConfig) GetRoleArnOk() (*string, bool)` + +GetRoleArnOk returns a tuple with the RoleArn field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetRoleArn + +`func (o *SubAccountProvCredConfig) SetRoleArn(v string)` + +SetRoleArn sets RoleArn field to given value. + +### HasRoleArn + +`func (o *SubAccountProvCredConfig) HasRoleArn() bool` + +HasRoleArn returns a boolean if a field has been set. + +### GetTenantId + +`func (o *SubAccountProvCredConfig) GetTenantId() string` + +GetTenantId returns the TenantId field if non-nil, zero value otherwise. + +### GetTenantIdOk + +`func (o *SubAccountProvCredConfig) GetTenantIdOk() (*string, bool)` + +GetTenantIdOk returns a tuple with the TenantId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTenantId + +`func (o *SubAccountProvCredConfig) SetTenantId(v string)` + +SetTenantId sets TenantId field to given value. + +### HasTenantId + +`func (o *SubAccountProvCredConfig) HasTenantId() bool` + +HasTenantId returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/SubAccountV2.md b/clouddiscovery/docs/SubAccountV2.md new file mode 100644 index 0000000..fa8c13b --- /dev/null +++ b/clouddiscovery/docs/SubAccountV2.md @@ -0,0 +1,82 @@ +# SubAccountV2 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Id** | Pointer to **string** | | [optional] [readonly] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### NewSubAccountV2 + +`func NewSubAccountV2() *SubAccountV2` + +NewSubAccountV2 instantiates a new SubAccountV2 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 + +### NewSubAccountV2WithDefaults + +`func NewSubAccountV2WithDefaults() *SubAccountV2` + +NewSubAccountV2WithDefaults instantiates a new SubAccountV2 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 + +### GetId + +`func (o *SubAccountV2) GetId() string` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *SubAccountV2) GetIdOk() (*string, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetId + +`func (o *SubAccountV2) SetId(v string)` + +SetId sets Id field to given value. + +### HasId + +`func (o *SubAccountV2) HasId() bool` + +HasId returns a boolean if a field has been set. + +### GetName + +`func (o *SubAccountV2) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *SubAccountV2) GetNameOk() (*string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetName + +`func (o *SubAccountV2) SetName(v string)` + +SetName sets Name field to given value. + +### HasName + +`func (o *SubAccountV2) HasName() bool` + +HasName returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/clouddiscovery/docs/SubAccountsAPI.md b/clouddiscovery/docs/SubAccountsAPI.md new file mode 100644 index 0000000..2643345 --- /dev/null +++ b/clouddiscovery/docs/SubAccountsAPI.md @@ -0,0 +1,75 @@ +# SubAccountsAPI + +All URIs are relative to *http://csp.infoblox.com/api/cloud_discovery/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**List**](SubAccountsAPI.md#List) | **Post** /sub_accounts | List Sub-accounts + + + +## List + +> SubAccountListResponseV2 List(ctx).Body(body).Execute() + +List Sub-accounts + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func main() { + body := *clouddiscovery.NewSubAccountListRequestV2() // SubAccountListRequestV2 | + + apiClient := clouddiscovery.NewAPIClient() + resp, r, err := apiClient.SubAccountsAPI.List(context.Background()).Body(body).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `SubAccountsAPI.List``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `List`: SubAccountListResponseV2 + fmt.Fprintf(os.Stdout, "Response from `SubAccountsAPI.List`: %v\n", resp) +} +``` + +### Path Parameters + + + +### Other Parameters + +Other parameters are passed through a pointer to a `SubAccountsAPIListRequest` struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**body** | [**SubAccountListRequestV2**](SubAccountListRequestV2.md) | | + +### Return type + +[**SubAccountListResponseV2**](SubAccountListResponseV2.md) + +### Authorization + +[ApiKeyAuth](../README.md#ApiKeyAuth) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + diff --git a/clouddiscovery/model_account.go b/clouddiscovery/model_account.go new file mode 100644 index 0000000..020e2a8 --- /dev/null +++ b/clouddiscovery/model_account.go @@ -0,0 +1,810 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" + "fmt" + "time" +) + +// checks if the Account type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Account{} + +// Account Source account information +type Account struct { + CompositeStatus *string `json:"composite_status,omitempty"` + // Status message of the sync operation. + CompositeStatusMessage *string `json:"composite_status_message,omitempty"` + // Timestamp when the object has been created. + CreatedAt *time.Time `json:"created_at,omitempty"` + // Timestamp when the object has been deleted. + DeletedAt *time.Time `json:"deleted_at,omitempty"` + DhcpServerId *string `json:"dhcp_server_id,omitempty"` + // DNS Server ID. + DnsServerId *string `json:"dns_server_id,omitempty"` + // Auto-generated unique source account ID. Format BloxID. + Id *string `json:"id,omitempty"` + // Last successful sync timestamp. + LastSuccessfulSync *time.Time `json:"last_successful_sync,omitempty"` + // Last sync timestamp. + LastSync *time.Time `json:"last_sync,omitempty"` + // Name of the source account. + Name string `json:"name"` + // Parent ID. + ParentId *string `json:"parent_id,omitempty"` + // Sync progress as a percentage. + PercentComplete *int32 `json:"percent_complete,omitempty"` + ProviderAccountId *string `json:"provider_account_id,omitempty"` + // Schedule ID. + ScheduleId *string `json:"schedule_id,omitempty"` + State *string `json:"state,omitempty"` + // Status of the sync operation. + Status *string `json:"status,omitempty"` + // Status message of the sync operation. + StatusMessage *string `json:"status_message,omitempty"` + // Timestamp when the object has been updated. + UpdatedAt *time.Time `json:"updated_at,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _Account Account + +// NewAccount instantiates a new Account 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 NewAccount(name string) *Account { + this := Account{} + this.Name = name + return &this +} + +// NewAccountWithDefaults instantiates a new Account 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 NewAccountWithDefaults() *Account { + this := Account{} + return &this +} + +// GetCompositeStatus returns the CompositeStatus field value if set, zero value otherwise. +func (o *Account) GetCompositeStatus() string { + if o == nil || IsNil(o.CompositeStatus) { + var ret string + return ret + } + return *o.CompositeStatus +} + +// GetCompositeStatusOk returns a tuple with the CompositeStatus field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCompositeStatusOk() (*string, bool) { + if o == nil || IsNil(o.CompositeStatus) { + return nil, false + } + return o.CompositeStatus, true +} + +// HasCompositeStatus returns a boolean if a field has been set. +func (o *Account) HasCompositeStatus() bool { + if o != nil && !IsNil(o.CompositeStatus) { + return true + } + + return false +} + +// SetCompositeStatus gets a reference to the given string and assigns it to the CompositeStatus field. +func (o *Account) SetCompositeStatus(v string) { + o.CompositeStatus = &v +} + +// GetCompositeStatusMessage returns the CompositeStatusMessage field value if set, zero value otherwise. +func (o *Account) GetCompositeStatusMessage() string { + if o == nil || IsNil(o.CompositeStatusMessage) { + var ret string + return ret + } + return *o.CompositeStatusMessage +} + +// GetCompositeStatusMessageOk returns a tuple with the CompositeStatusMessage field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCompositeStatusMessageOk() (*string, bool) { + if o == nil || IsNil(o.CompositeStatusMessage) { + return nil, false + } + return o.CompositeStatusMessage, true +} + +// HasCompositeStatusMessage returns a boolean if a field has been set. +func (o *Account) HasCompositeStatusMessage() bool { + if o != nil && !IsNil(o.CompositeStatusMessage) { + return true + } + + return false +} + +// SetCompositeStatusMessage gets a reference to the given string and assigns it to the CompositeStatusMessage field. +func (o *Account) SetCompositeStatusMessage(v string) { + o.CompositeStatusMessage = &v +} + +// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise. +func (o *Account) GetCreatedAt() time.Time { + if o == nil || IsNil(o.CreatedAt) { + var ret time.Time + return ret + } + return *o.CreatedAt +} + +// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCreatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.CreatedAt) { + return nil, false + } + return o.CreatedAt, true +} + +// HasCreatedAt returns a boolean if a field has been set. +func (o *Account) HasCreatedAt() bool { + if o != nil && !IsNil(o.CreatedAt) { + return true + } + + return false +} + +// SetCreatedAt gets a reference to the given time.Time and assigns it to the CreatedAt field. +func (o *Account) SetCreatedAt(v time.Time) { + o.CreatedAt = &v +} + +// GetDeletedAt returns the DeletedAt field value if set, zero value otherwise. +func (o *Account) GetDeletedAt() time.Time { + if o == nil || IsNil(o.DeletedAt) { + var ret time.Time + return ret + } + return *o.DeletedAt +} + +// GetDeletedAtOk returns a tuple with the DeletedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetDeletedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.DeletedAt) { + return nil, false + } + return o.DeletedAt, true +} + +// HasDeletedAt returns a boolean if a field has been set. +func (o *Account) HasDeletedAt() bool { + if o != nil && !IsNil(o.DeletedAt) { + return true + } + + return false +} + +// SetDeletedAt gets a reference to the given time.Time and assigns it to the DeletedAt field. +func (o *Account) SetDeletedAt(v time.Time) { + o.DeletedAt = &v +} + +// GetDhcpServerId returns the DhcpServerId field value if set, zero value otherwise. +func (o *Account) GetDhcpServerId() string { + if o == nil || IsNil(o.DhcpServerId) { + var ret string + return ret + } + return *o.DhcpServerId +} + +// GetDhcpServerIdOk returns a tuple with the DhcpServerId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetDhcpServerIdOk() (*string, bool) { + if o == nil || IsNil(o.DhcpServerId) { + return nil, false + } + return o.DhcpServerId, true +} + +// HasDhcpServerId returns a boolean if a field has been set. +func (o *Account) HasDhcpServerId() bool { + if o != nil && !IsNil(o.DhcpServerId) { + return true + } + + return false +} + +// SetDhcpServerId gets a reference to the given string and assigns it to the DhcpServerId field. +func (o *Account) SetDhcpServerId(v string) { + o.DhcpServerId = &v +} + +// GetDnsServerId returns the DnsServerId field value if set, zero value otherwise. +func (o *Account) GetDnsServerId() string { + if o == nil || IsNil(o.DnsServerId) { + var ret string + return ret + } + return *o.DnsServerId +} + +// GetDnsServerIdOk returns a tuple with the DnsServerId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetDnsServerIdOk() (*string, bool) { + if o == nil || IsNil(o.DnsServerId) { + return nil, false + } + return o.DnsServerId, true +} + +// HasDnsServerId returns a boolean if a field has been set. +func (o *Account) HasDnsServerId() bool { + if o != nil && !IsNil(o.DnsServerId) { + return true + } + + return false +} + +// SetDnsServerId gets a reference to the given string and assigns it to the DnsServerId field. +func (o *Account) SetDnsServerId(v string) { + o.DnsServerId = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *Account) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Account) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *Account) SetId(v string) { + o.Id = &v +} + +// GetLastSuccessfulSync returns the LastSuccessfulSync field value if set, zero value otherwise. +func (o *Account) GetLastSuccessfulSync() time.Time { + if o == nil || IsNil(o.LastSuccessfulSync) { + var ret time.Time + return ret + } + return *o.LastSuccessfulSync +} + +// GetLastSuccessfulSyncOk returns a tuple with the LastSuccessfulSync field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetLastSuccessfulSyncOk() (*time.Time, bool) { + if o == nil || IsNil(o.LastSuccessfulSync) { + return nil, false + } + return o.LastSuccessfulSync, true +} + +// HasLastSuccessfulSync returns a boolean if a field has been set. +func (o *Account) HasLastSuccessfulSync() bool { + if o != nil && !IsNil(o.LastSuccessfulSync) { + return true + } + + return false +} + +// SetLastSuccessfulSync gets a reference to the given time.Time and assigns it to the LastSuccessfulSync field. +func (o *Account) SetLastSuccessfulSync(v time.Time) { + o.LastSuccessfulSync = &v +} + +// GetLastSync returns the LastSync field value if set, zero value otherwise. +func (o *Account) GetLastSync() time.Time { + if o == nil || IsNil(o.LastSync) { + var ret time.Time + return ret + } + return *o.LastSync +} + +// GetLastSyncOk returns a tuple with the LastSync field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetLastSyncOk() (*time.Time, bool) { + if o == nil || IsNil(o.LastSync) { + return nil, false + } + return o.LastSync, true +} + +// HasLastSync returns a boolean if a field has been set. +func (o *Account) HasLastSync() bool { + if o != nil && !IsNil(o.LastSync) { + return true + } + + return false +} + +// SetLastSync gets a reference to the given time.Time and assigns it to the LastSync field. +func (o *Account) SetLastSync(v time.Time) { + o.LastSync = &v +} + +// GetName returns the Name field value +func (o *Account) GetName() string { + if o == nil { + var ret string + return ret + } + + return o.Name +} + +// GetNameOk returns a tuple with the Name field value +// and a boolean to check if the value has been set. +func (o *Account) GetNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Name, true +} + +// SetName sets field value +func (o *Account) SetName(v string) { + o.Name = v +} + +// GetParentId returns the ParentId field value if set, zero value otherwise. +func (o *Account) GetParentId() string { + if o == nil || IsNil(o.ParentId) { + var ret string + return ret + } + return *o.ParentId +} + +// GetParentIdOk returns a tuple with the ParentId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetParentIdOk() (*string, bool) { + if o == nil || IsNil(o.ParentId) { + return nil, false + } + return o.ParentId, true +} + +// HasParentId returns a boolean if a field has been set. +func (o *Account) HasParentId() bool { + if o != nil && !IsNil(o.ParentId) { + return true + } + + return false +} + +// SetParentId gets a reference to the given string and assigns it to the ParentId field. +func (o *Account) SetParentId(v string) { + o.ParentId = &v +} + +// GetPercentComplete returns the PercentComplete field value if set, zero value otherwise. +func (o *Account) GetPercentComplete() int32 { + if o == nil || IsNil(o.PercentComplete) { + var ret int32 + return ret + } + return *o.PercentComplete +} + +// GetPercentCompleteOk returns a tuple with the PercentComplete field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetPercentCompleteOk() (*int32, bool) { + if o == nil || IsNil(o.PercentComplete) { + return nil, false + } + return o.PercentComplete, true +} + +// HasPercentComplete returns a boolean if a field has been set. +func (o *Account) HasPercentComplete() bool { + if o != nil && !IsNil(o.PercentComplete) { + return true + } + + return false +} + +// SetPercentComplete gets a reference to the given int32 and assigns it to the PercentComplete field. +func (o *Account) SetPercentComplete(v int32) { + o.PercentComplete = &v +} + +// GetProviderAccountId returns the ProviderAccountId field value if set, zero value otherwise. +func (o *Account) GetProviderAccountId() string { + if o == nil || IsNil(o.ProviderAccountId) { + var ret string + return ret + } + return *o.ProviderAccountId +} + +// GetProviderAccountIdOk returns a tuple with the ProviderAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetProviderAccountIdOk() (*string, bool) { + if o == nil || IsNil(o.ProviderAccountId) { + return nil, false + } + return o.ProviderAccountId, true +} + +// HasProviderAccountId returns a boolean if a field has been set. +func (o *Account) HasProviderAccountId() bool { + if o != nil && !IsNil(o.ProviderAccountId) { + return true + } + + return false +} + +// SetProviderAccountId gets a reference to the given string and assigns it to the ProviderAccountId field. +func (o *Account) SetProviderAccountId(v string) { + o.ProviderAccountId = &v +} + +// GetScheduleId returns the ScheduleId field value if set, zero value otherwise. +func (o *Account) GetScheduleId() string { + if o == nil || IsNil(o.ScheduleId) { + var ret string + return ret + } + return *o.ScheduleId +} + +// GetScheduleIdOk returns a tuple with the ScheduleId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetScheduleIdOk() (*string, bool) { + if o == nil || IsNil(o.ScheduleId) { + return nil, false + } + return o.ScheduleId, true +} + +// HasScheduleId returns a boolean if a field has been set. +func (o *Account) HasScheduleId() bool { + if o != nil && !IsNil(o.ScheduleId) { + return true + } + + return false +} + +// SetScheduleId gets a reference to the given string and assigns it to the ScheduleId field. +func (o *Account) SetScheduleId(v string) { + o.ScheduleId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Account) GetState() string { + if o == nil || IsNil(o.State) { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetStateOk() (*string, bool) { + if o == nil || IsNil(o.State) { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Account) HasState() bool { + if o != nil && !IsNil(o.State) { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Account) SetState(v string) { + o.State = &v +} + +// GetStatus returns the Status field value if set, zero value otherwise. +func (o *Account) GetStatus() string { + if o == nil || IsNil(o.Status) { + var ret string + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetStatusOk() (*string, bool) { + if o == nil || IsNil(o.Status) { + return nil, false + } + return o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *Account) HasStatus() bool { + if o != nil && !IsNil(o.Status) { + return true + } + + return false +} + +// SetStatus gets a reference to the given string and assigns it to the Status field. +func (o *Account) SetStatus(v string) { + o.Status = &v +} + +// GetStatusMessage returns the StatusMessage field value if set, zero value otherwise. +func (o *Account) GetStatusMessage() string { + if o == nil || IsNil(o.StatusMessage) { + var ret string + return ret + } + return *o.StatusMessage +} + +// GetStatusMessageOk returns a tuple with the StatusMessage field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetStatusMessageOk() (*string, bool) { + if o == nil || IsNil(o.StatusMessage) { + return nil, false + } + return o.StatusMessage, true +} + +// HasStatusMessage returns a boolean if a field has been set. +func (o *Account) HasStatusMessage() bool { + if o != nil && !IsNil(o.StatusMessage) { + return true + } + + return false +} + +// SetStatusMessage gets a reference to the given string and assigns it to the StatusMessage field. +func (o *Account) SetStatusMessage(v string) { + o.StatusMessage = &v +} + +// GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise. +func (o *Account) GetUpdatedAt() time.Time { + if o == nil || IsNil(o.UpdatedAt) { + var ret time.Time + return ret + } + return *o.UpdatedAt +} + +// GetUpdatedAtOk returns a tuple with the UpdatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetUpdatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.UpdatedAt) { + return nil, false + } + return o.UpdatedAt, true +} + +// HasUpdatedAt returns a boolean if a field has been set. +func (o *Account) HasUpdatedAt() bool { + if o != nil && !IsNil(o.UpdatedAt) { + return true + } + + return false +} + +// SetUpdatedAt gets a reference to the given time.Time and assigns it to the UpdatedAt field. +func (o *Account) SetUpdatedAt(v time.Time) { + o.UpdatedAt = &v +} + +func (o Account) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Account) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.CompositeStatus) { + toSerialize["composite_status"] = o.CompositeStatus + } + if !IsNil(o.CompositeStatusMessage) { + toSerialize["composite_status_message"] = o.CompositeStatusMessage + } + if !IsNil(o.CreatedAt) { + toSerialize["created_at"] = o.CreatedAt + } + if !IsNil(o.DeletedAt) { + toSerialize["deleted_at"] = o.DeletedAt + } + if !IsNil(o.DhcpServerId) { + toSerialize["dhcp_server_id"] = o.DhcpServerId + } + if !IsNil(o.DnsServerId) { + toSerialize["dns_server_id"] = o.DnsServerId + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.LastSuccessfulSync) { + toSerialize["last_successful_sync"] = o.LastSuccessfulSync + } + if !IsNil(o.LastSync) { + toSerialize["last_sync"] = o.LastSync + } + toSerialize["name"] = o.Name + if !IsNil(o.ParentId) { + toSerialize["parent_id"] = o.ParentId + } + if !IsNil(o.PercentComplete) { + toSerialize["percent_complete"] = o.PercentComplete + } + if !IsNil(o.ProviderAccountId) { + toSerialize["provider_account_id"] = o.ProviderAccountId + } + if !IsNil(o.ScheduleId) { + toSerialize["schedule_id"] = o.ScheduleId + } + if !IsNil(o.State) { + toSerialize["state"] = o.State + } + if !IsNil(o.Status) { + toSerialize["status"] = o.Status + } + if !IsNil(o.StatusMessage) { + toSerialize["status_message"] = o.StatusMessage + } + if !IsNil(o.UpdatedAt) { + toSerialize["updated_at"] = o.UpdatedAt + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *Account) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "name", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err + } + + for _, requiredProperty := range requiredProperties { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varAccount := _Account{} + + err = json.Unmarshal(data, &varAccount) + + if err != nil { + return err + } + + *o = Account(varAccount) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "composite_status") + delete(additionalProperties, "composite_status_message") + delete(additionalProperties, "created_at") + delete(additionalProperties, "deleted_at") + delete(additionalProperties, "dhcp_server_id") + delete(additionalProperties, "dns_server_id") + delete(additionalProperties, "id") + delete(additionalProperties, "last_successful_sync") + delete(additionalProperties, "last_sync") + delete(additionalProperties, "name") + delete(additionalProperties, "parent_id") + delete(additionalProperties, "percent_complete") + delete(additionalProperties, "provider_account_id") + delete(additionalProperties, "schedule_id") + delete(additionalProperties, "state") + delete(additionalProperties, "status") + delete(additionalProperties, "status_message") + delete(additionalProperties, "updated_at") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableAccount struct { + value *Account + isSet bool +} + +func (v NullableAccount) Get() *Account { + return v.value +} + +func (v *NullableAccount) Set(val *Account) { + v.value = val + v.isSet = true +} + +func (v NullableAccount) IsSet() bool { + return v.isSet +} + +func (v *NullableAccount) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccount(val *Account) *NullableAccount { + return &NullableAccount{value: val, isSet: true} +} + +func (v NullableAccount) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccount) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_account_list_response.go b/clouddiscovery/model_account_list_response.go new file mode 100644 index 0000000..3d79ab4 --- /dev/null +++ b/clouddiscovery/model_account_list_response.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the AccountListResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &AccountListResponse{} + +// AccountListResponse The Account object List response format. +type AccountListResponse struct { + Page *ApiPageInfo `json:"page,omitempty"` + Results []Account `json:"results,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _AccountListResponse AccountListResponse + +// NewAccountListResponse instantiates a new AccountListResponse 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 NewAccountListResponse() *AccountListResponse { + this := AccountListResponse{} + return &this +} + +// NewAccountListResponseWithDefaults instantiates a new AccountListResponse 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 NewAccountListResponseWithDefaults() *AccountListResponse { + this := AccountListResponse{} + return &this +} + +// GetPage returns the Page field value if set, zero value otherwise. +func (o *AccountListResponse) GetPage() ApiPageInfo { + if o == nil || IsNil(o.Page) { + var ret ApiPageInfo + return ret + } + return *o.Page +} + +// GetPageOk returns a tuple with the Page field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccountListResponse) GetPageOk() (*ApiPageInfo, bool) { + if o == nil || IsNil(o.Page) { + return nil, false + } + return o.Page, true +} + +// HasPage returns a boolean if a field has been set. +func (o *AccountListResponse) HasPage() bool { + if o != nil && !IsNil(o.Page) { + return true + } + + return false +} + +// SetPage gets a reference to the given ApiPageInfo and assigns it to the Page field. +func (o *AccountListResponse) SetPage(v ApiPageInfo) { + o.Page = &v +} + +// GetResults returns the Results field value if set, zero value otherwise. +func (o *AccountListResponse) GetResults() []Account { + if o == nil || IsNil(o.Results) { + var ret []Account + return ret + } + return o.Results +} + +// GetResultsOk returns a tuple with the Results field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccountListResponse) GetResultsOk() ([]Account, bool) { + if o == nil || IsNil(o.Results) { + return nil, false + } + return o.Results, true +} + +// HasResults returns a boolean if a field has been set. +func (o *AccountListResponse) HasResults() bool { + if o != nil && !IsNil(o.Results) { + return true + } + + return false +} + +// SetResults gets a reference to the given []Account and assigns it to the Results field. +func (o *AccountListResponse) SetResults(v []Account) { + o.Results = v +} + +func (o AccountListResponse) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o AccountListResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Page) { + toSerialize["page"] = o.Page + } + if !IsNil(o.Results) { + toSerialize["results"] = o.Results + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *AccountListResponse) UnmarshalJSON(data []byte) (err error) { + varAccountListResponse := _AccountListResponse{} + + err = json.Unmarshal(data, &varAccountListResponse) + + if err != nil { + return err + } + + *o = AccountListResponse(varAccountListResponse) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "page") + delete(additionalProperties, "results") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableAccountListResponse struct { + value *AccountListResponse + isSet bool +} + +func (v NullableAccountListResponse) Get() *AccountListResponse { + return v.value +} + +func (v *NullableAccountListResponse) Set(val *AccountListResponse) { + v.value = val + v.isSet = true +} + +func (v NullableAccountListResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableAccountListResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccountListResponse(val *AccountListResponse) *NullableAccountListResponse { + return &NullableAccountListResponse{value: val, isSet: true} +} + +func (v NullableAccountListResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccountListResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_additional_config.go b/clouddiscovery/model_additional_config.go new file mode 100644 index 0000000..b66e7f8 --- /dev/null +++ b/clouddiscovery/model_additional_config.go @@ -0,0 +1,264 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the AdditionalConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &AdditionalConfig{} + +// AdditionalConfig struct for AdditionalConfig +type AdditionalConfig struct { + ExcludedAccounts []string `json:"excluded_accounts,omitempty"` + ForwardZoneEnabled *bool `json:"forward_zone_enabled,omitempty"` + InternalRangesEnabled *bool `json:"internal_ranges_enabled,omitempty"` + ObjectType *ObjectType `json:"object_type,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _AdditionalConfig AdditionalConfig + +// NewAdditionalConfig instantiates a new AdditionalConfig 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 NewAdditionalConfig() *AdditionalConfig { + this := AdditionalConfig{} + return &this +} + +// NewAdditionalConfigWithDefaults instantiates a new AdditionalConfig 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 NewAdditionalConfigWithDefaults() *AdditionalConfig { + this := AdditionalConfig{} + return &this +} + +// GetExcludedAccounts returns the ExcludedAccounts field value if set, zero value otherwise. +func (o *AdditionalConfig) GetExcludedAccounts() []string { + if o == nil || IsNil(o.ExcludedAccounts) { + var ret []string + return ret + } + return o.ExcludedAccounts +} + +// GetExcludedAccountsOk returns a tuple with the ExcludedAccounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalConfig) GetExcludedAccountsOk() ([]string, bool) { + if o == nil || IsNil(o.ExcludedAccounts) { + return nil, false + } + return o.ExcludedAccounts, true +} + +// HasExcludedAccounts returns a boolean if a field has been set. +func (o *AdditionalConfig) HasExcludedAccounts() bool { + if o != nil && !IsNil(o.ExcludedAccounts) { + return true + } + + return false +} + +// SetExcludedAccounts gets a reference to the given []string and assigns it to the ExcludedAccounts field. +func (o *AdditionalConfig) SetExcludedAccounts(v []string) { + o.ExcludedAccounts = v +} + +// GetForwardZoneEnabled returns the ForwardZoneEnabled field value if set, zero value otherwise. +func (o *AdditionalConfig) GetForwardZoneEnabled() bool { + if o == nil || IsNil(o.ForwardZoneEnabled) { + var ret bool + return ret + } + return *o.ForwardZoneEnabled +} + +// GetForwardZoneEnabledOk returns a tuple with the ForwardZoneEnabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalConfig) GetForwardZoneEnabledOk() (*bool, bool) { + if o == nil || IsNil(o.ForwardZoneEnabled) { + return nil, false + } + return o.ForwardZoneEnabled, true +} + +// HasForwardZoneEnabled returns a boolean if a field has been set. +func (o *AdditionalConfig) HasForwardZoneEnabled() bool { + if o != nil && !IsNil(o.ForwardZoneEnabled) { + return true + } + + return false +} + +// SetForwardZoneEnabled gets a reference to the given bool and assigns it to the ForwardZoneEnabled field. +func (o *AdditionalConfig) SetForwardZoneEnabled(v bool) { + o.ForwardZoneEnabled = &v +} + +// GetInternalRangesEnabled returns the InternalRangesEnabled field value if set, zero value otherwise. +func (o *AdditionalConfig) GetInternalRangesEnabled() bool { + if o == nil || IsNil(o.InternalRangesEnabled) { + var ret bool + return ret + } + return *o.InternalRangesEnabled +} + +// GetInternalRangesEnabledOk returns a tuple with the InternalRangesEnabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalConfig) GetInternalRangesEnabledOk() (*bool, bool) { + if o == nil || IsNil(o.InternalRangesEnabled) { + return nil, false + } + return o.InternalRangesEnabled, true +} + +// HasInternalRangesEnabled returns a boolean if a field has been set. +func (o *AdditionalConfig) HasInternalRangesEnabled() bool { + if o != nil && !IsNil(o.InternalRangesEnabled) { + return true + } + + return false +} + +// SetInternalRangesEnabled gets a reference to the given bool and assigns it to the InternalRangesEnabled field. +func (o *AdditionalConfig) SetInternalRangesEnabled(v bool) { + o.InternalRangesEnabled = &v +} + +// GetObjectType returns the ObjectType field value if set, zero value otherwise. +func (o *AdditionalConfig) GetObjectType() ObjectType { + if o == nil || IsNil(o.ObjectType) { + var ret ObjectType + return ret + } + return *o.ObjectType +} + +// GetObjectTypeOk returns a tuple with the ObjectType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalConfig) GetObjectTypeOk() (*ObjectType, bool) { + if o == nil || IsNil(o.ObjectType) { + return nil, false + } + return o.ObjectType, true +} + +// HasObjectType returns a boolean if a field has been set. +func (o *AdditionalConfig) HasObjectType() bool { + if o != nil && !IsNil(o.ObjectType) { + return true + } + + return false +} + +// SetObjectType gets a reference to the given ObjectType and assigns it to the ObjectType field. +func (o *AdditionalConfig) SetObjectType(v ObjectType) { + o.ObjectType = &v +} + +func (o AdditionalConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o AdditionalConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ExcludedAccounts) { + toSerialize["excluded_accounts"] = o.ExcludedAccounts + } + if !IsNil(o.ForwardZoneEnabled) { + toSerialize["forward_zone_enabled"] = o.ForwardZoneEnabled + } + if !IsNil(o.InternalRangesEnabled) { + toSerialize["internal_ranges_enabled"] = o.InternalRangesEnabled + } + if !IsNil(o.ObjectType) { + toSerialize["object_type"] = o.ObjectType + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *AdditionalConfig) UnmarshalJSON(data []byte) (err error) { + varAdditionalConfig := _AdditionalConfig{} + + err = json.Unmarshal(data, &varAdditionalConfig) + + if err != nil { + return err + } + + *o = AdditionalConfig(varAdditionalConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "excluded_accounts") + delete(additionalProperties, "forward_zone_enabled") + delete(additionalProperties, "internal_ranges_enabled") + delete(additionalProperties, "object_type") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableAdditionalConfig struct { + value *AdditionalConfig + isSet bool +} + +func (v NullableAdditionalConfig) Get() *AdditionalConfig { + return v.value +} + +func (v *NullableAdditionalConfig) Set(val *AdditionalConfig) { + v.value = val + v.isSet = true +} + +func (v NullableAdditionalConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableAdditionalConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAdditionalConfig(val *AdditionalConfig) *NullableAdditionalConfig { + return &NullableAdditionalConfig{value: val, isSet: true} +} + +func (v NullableAdditionalConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAdditionalConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_api_page_info.go b/clouddiscovery/model_api_page_info.go new file mode 100644 index 0000000..53681a7 --- /dev/null +++ b/clouddiscovery/model_api_page_info.go @@ -0,0 +1,230 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the ApiPageInfo type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ApiPageInfo{} + +// ApiPageInfo PageInfo represents both server-driven and client-driven pagination response. Server-driven pagination is a model in which the server returns some amount of data along with an token indicating there is more data and where subsequent queries can get the next page of data. Client-driven pagination is a model in which rows are addressable by offset and page size (limit). +type ApiPageInfo struct { + // The service may optionally include the offset of the next page of resources. A null value indicates no more pages. + Offset *int32 `json:"offset,omitempty"` + // The service response should contain a string to indicate the next page of resources. A null value indicates no more pages. + PageToken *string `json:"page_token,omitempty"` + // The service may optionally include the total number of resources being paged. + Size *int32 `json:"size,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ApiPageInfo ApiPageInfo + +// NewApiPageInfo instantiates a new ApiPageInfo 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 NewApiPageInfo() *ApiPageInfo { + this := ApiPageInfo{} + return &this +} + +// NewApiPageInfoWithDefaults instantiates a new ApiPageInfo 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 NewApiPageInfoWithDefaults() *ApiPageInfo { + this := ApiPageInfo{} + return &this +} + +// GetOffset returns the Offset field value if set, zero value otherwise. +func (o *ApiPageInfo) GetOffset() int32 { + if o == nil || IsNil(o.Offset) { + var ret int32 + return ret + } + return *o.Offset +} + +// GetOffsetOk returns a tuple with the Offset field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ApiPageInfo) GetOffsetOk() (*int32, bool) { + if o == nil || IsNil(o.Offset) { + return nil, false + } + return o.Offset, true +} + +// HasOffset returns a boolean if a field has been set. +func (o *ApiPageInfo) HasOffset() bool { + if o != nil && !IsNil(o.Offset) { + return true + } + + return false +} + +// SetOffset gets a reference to the given int32 and assigns it to the Offset field. +func (o *ApiPageInfo) SetOffset(v int32) { + o.Offset = &v +} + +// GetPageToken returns the PageToken field value if set, zero value otherwise. +func (o *ApiPageInfo) GetPageToken() string { + if o == nil || IsNil(o.PageToken) { + var ret string + return ret + } + return *o.PageToken +} + +// GetPageTokenOk returns a tuple with the PageToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ApiPageInfo) GetPageTokenOk() (*string, bool) { + if o == nil || IsNil(o.PageToken) { + return nil, false + } + return o.PageToken, true +} + +// HasPageToken returns a boolean if a field has been set. +func (o *ApiPageInfo) HasPageToken() bool { + if o != nil && !IsNil(o.PageToken) { + return true + } + + return false +} + +// SetPageToken gets a reference to the given string and assigns it to the PageToken field. +func (o *ApiPageInfo) SetPageToken(v string) { + o.PageToken = &v +} + +// GetSize returns the Size field value if set, zero value otherwise. +func (o *ApiPageInfo) GetSize() int32 { + if o == nil || IsNil(o.Size) { + var ret int32 + return ret + } + return *o.Size +} + +// GetSizeOk returns a tuple with the Size field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ApiPageInfo) GetSizeOk() (*int32, bool) { + if o == nil || IsNil(o.Size) { + return nil, false + } + return o.Size, true +} + +// HasSize returns a boolean if a field has been set. +func (o *ApiPageInfo) HasSize() bool { + if o != nil && !IsNil(o.Size) { + return true + } + + return false +} + +// SetSize gets a reference to the given int32 and assigns it to the Size field. +func (o *ApiPageInfo) SetSize(v int32) { + o.Size = &v +} + +func (o ApiPageInfo) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ApiPageInfo) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Offset) { + toSerialize["offset"] = o.Offset + } + if !IsNil(o.PageToken) { + toSerialize["page_token"] = o.PageToken + } + if !IsNil(o.Size) { + toSerialize["size"] = o.Size + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ApiPageInfo) UnmarshalJSON(data []byte) (err error) { + varApiPageInfo := _ApiPageInfo{} + + err = json.Unmarshal(data, &varApiPageInfo) + + if err != nil { + return err + } + + *o = ApiPageInfo(varApiPageInfo) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "offset") + delete(additionalProperties, "page_token") + delete(additionalProperties, "size") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableApiPageInfo struct { + value *ApiPageInfo + isSet bool +} + +func (v NullableApiPageInfo) Get() *ApiPageInfo { + return v.value +} + +func (v *NullableApiPageInfo) Set(val *ApiPageInfo) { + v.value = val + v.isSet = true +} + +func (v NullableApiPageInfo) IsSet() bool { + return v.isSet +} + +func (v *NullableApiPageInfo) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableApiPageInfo(val *ApiPageInfo) *NullableApiPageInfo { + return &NullableApiPageInfo{value: val, isSet: true} +} + +func (v NullableApiPageInfo) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableApiPageInfo) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_category.go b/clouddiscovery/model_category.go new file mode 100644 index 0000000..46f04ff --- /dev/null +++ b/clouddiscovery/model_category.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the Category type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Category{} + +// Category Category ... +type Category struct { + Excluded *bool `json:"excluded,omitempty"` + Id *string `json:"id,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _Category Category + +// NewCategory instantiates a new Category 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 NewCategory() *Category { + this := Category{} + return &this +} + +// NewCategoryWithDefaults instantiates a new Category 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 NewCategoryWithDefaults() *Category { + this := Category{} + return &this +} + +// GetExcluded returns the Excluded field value if set, zero value otherwise. +func (o *Category) GetExcluded() bool { + if o == nil || IsNil(o.Excluded) { + var ret bool + return ret + } + return *o.Excluded +} + +// GetExcludedOk returns a tuple with the Excluded field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Category) GetExcludedOk() (*bool, bool) { + if o == nil || IsNil(o.Excluded) { + return nil, false + } + return o.Excluded, true +} + +// HasExcluded returns a boolean if a field has been set. +func (o *Category) HasExcluded() bool { + if o != nil && !IsNil(o.Excluded) { + return true + } + + return false +} + +// SetExcluded gets a reference to the given bool and assigns it to the Excluded field. +func (o *Category) SetExcluded(v bool) { + o.Excluded = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *Category) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Category) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Category) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *Category) SetId(v string) { + o.Id = &v +} + +func (o Category) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Category) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Excluded) { + toSerialize["excluded"] = o.Excluded + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *Category) UnmarshalJSON(data []byte) (err error) { + varCategory := _Category{} + + err = json.Unmarshal(data, &varCategory) + + if err != nil { + return err + } + + *o = Category(varCategory) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "excluded") + delete(additionalProperties, "id") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableCategory struct { + value *Category + isSet bool +} + +func (v NullableCategory) Get() *Category { + return v.value +} + +func (v *NullableCategory) Set(val *Category) { + v.value = val + v.isSet = true +} + +func (v NullableCategory) IsSet() bool { + return v.isSet +} + +func (v *NullableCategory) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCategory(val *Category) *NullableCategory { + return &NullableCategory{value: val, isSet: true} +} + +func (v NullableCategory) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCategory) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_credential_config.go b/clouddiscovery/model_credential_config.go new file mode 100644 index 0000000..63b21b3 --- /dev/null +++ b/clouddiscovery/model_credential_config.go @@ -0,0 +1,227 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the CredentialConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CredentialConfig{} + +// CredentialConfig struct for CredentialConfig +type CredentialConfig struct { + AccessIdentifier *string `json:"access_identifier,omitempty"` + Enclave *string `json:"enclave,omitempty"` + Region *string `json:"region,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _CredentialConfig CredentialConfig + +// NewCredentialConfig instantiates a new CredentialConfig 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 NewCredentialConfig() *CredentialConfig { + this := CredentialConfig{} + return &this +} + +// NewCredentialConfigWithDefaults instantiates a new CredentialConfig 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 NewCredentialConfigWithDefaults() *CredentialConfig { + this := CredentialConfig{} + return &this +} + +// GetAccessIdentifier returns the AccessIdentifier field value if set, zero value otherwise. +func (o *CredentialConfig) GetAccessIdentifier() string { + if o == nil || IsNil(o.AccessIdentifier) { + var ret string + return ret + } + return *o.AccessIdentifier +} + +// GetAccessIdentifierOk returns a tuple with the AccessIdentifier field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialConfig) GetAccessIdentifierOk() (*string, bool) { + if o == nil || IsNil(o.AccessIdentifier) { + return nil, false + } + return o.AccessIdentifier, true +} + +// HasAccessIdentifier returns a boolean if a field has been set. +func (o *CredentialConfig) HasAccessIdentifier() bool { + if o != nil && !IsNil(o.AccessIdentifier) { + return true + } + + return false +} + +// SetAccessIdentifier gets a reference to the given string and assigns it to the AccessIdentifier field. +func (o *CredentialConfig) SetAccessIdentifier(v string) { + o.AccessIdentifier = &v +} + +// GetEnclave returns the Enclave field value if set, zero value otherwise. +func (o *CredentialConfig) GetEnclave() string { + if o == nil || IsNil(o.Enclave) { + var ret string + return ret + } + return *o.Enclave +} + +// GetEnclaveOk returns a tuple with the Enclave field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialConfig) GetEnclaveOk() (*string, bool) { + if o == nil || IsNil(o.Enclave) { + return nil, false + } + return o.Enclave, true +} + +// HasEnclave returns a boolean if a field has been set. +func (o *CredentialConfig) HasEnclave() bool { + if o != nil && !IsNil(o.Enclave) { + return true + } + + return false +} + +// SetEnclave gets a reference to the given string and assigns it to the Enclave field. +func (o *CredentialConfig) SetEnclave(v string) { + o.Enclave = &v +} + +// GetRegion returns the Region field value if set, zero value otherwise. +func (o *CredentialConfig) GetRegion() string { + if o == nil || IsNil(o.Region) { + var ret string + return ret + } + return *o.Region +} + +// GetRegionOk returns a tuple with the Region field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialConfig) GetRegionOk() (*string, bool) { + if o == nil || IsNil(o.Region) { + return nil, false + } + return o.Region, true +} + +// HasRegion returns a boolean if a field has been set. +func (o *CredentialConfig) HasRegion() bool { + if o != nil && !IsNil(o.Region) { + return true + } + + return false +} + +// SetRegion gets a reference to the given string and assigns it to the Region field. +func (o *CredentialConfig) SetRegion(v string) { + o.Region = &v +} + +func (o CredentialConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CredentialConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AccessIdentifier) { + toSerialize["access_identifier"] = o.AccessIdentifier + } + if !IsNil(o.Enclave) { + toSerialize["enclave"] = o.Enclave + } + if !IsNil(o.Region) { + toSerialize["region"] = o.Region + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *CredentialConfig) UnmarshalJSON(data []byte) (err error) { + varCredentialConfig := _CredentialConfig{} + + err = json.Unmarshal(data, &varCredentialConfig) + + if err != nil { + return err + } + + *o = CredentialConfig(varCredentialConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "access_identifier") + delete(additionalProperties, "enclave") + delete(additionalProperties, "region") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableCredentialConfig struct { + value *CredentialConfig + isSet bool +} + +func (v NullableCredentialConfig) Get() *CredentialConfig { + return v.value +} + +func (v *NullableCredentialConfig) Set(val *CredentialConfig) { + v.value = val + v.isSet = true +} + +func (v NullableCredentialConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableCredentialConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCredentialConfig(val *CredentialConfig) *NullableCredentialConfig { + return &NullableCredentialConfig{value: val, isSet: true} +} + +func (v NullableCredentialConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCredentialConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_credential_preference.go b/clouddiscovery/model_credential_preference.go new file mode 100644 index 0000000..41dfdf8 --- /dev/null +++ b/clouddiscovery/model_credential_preference.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the CredentialPreference type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CredentialPreference{} + +// CredentialPreference struct for CredentialPreference +type CredentialPreference struct { + AccessIdentifierType *string `json:"access_identifier_type,omitempty"` + CredentialType *string `json:"credential_type,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _CredentialPreference CredentialPreference + +// NewCredentialPreference instantiates a new CredentialPreference 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 NewCredentialPreference() *CredentialPreference { + this := CredentialPreference{} + return &this +} + +// NewCredentialPreferenceWithDefaults instantiates a new CredentialPreference 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 NewCredentialPreferenceWithDefaults() *CredentialPreference { + this := CredentialPreference{} + return &this +} + +// GetAccessIdentifierType returns the AccessIdentifierType field value if set, zero value otherwise. +func (o *CredentialPreference) GetAccessIdentifierType() string { + if o == nil || IsNil(o.AccessIdentifierType) { + var ret string + return ret + } + return *o.AccessIdentifierType +} + +// GetAccessIdentifierTypeOk returns a tuple with the AccessIdentifierType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialPreference) GetAccessIdentifierTypeOk() (*string, bool) { + if o == nil || IsNil(o.AccessIdentifierType) { + return nil, false + } + return o.AccessIdentifierType, true +} + +// HasAccessIdentifierType returns a boolean if a field has been set. +func (o *CredentialPreference) HasAccessIdentifierType() bool { + if o != nil && !IsNil(o.AccessIdentifierType) { + return true + } + + return false +} + +// SetAccessIdentifierType gets a reference to the given string and assigns it to the AccessIdentifierType field. +func (o *CredentialPreference) SetAccessIdentifierType(v string) { + o.AccessIdentifierType = &v +} + +// GetCredentialType returns the CredentialType field value if set, zero value otherwise. +func (o *CredentialPreference) GetCredentialType() string { + if o == nil || IsNil(o.CredentialType) { + var ret string + return ret + } + return *o.CredentialType +} + +// GetCredentialTypeOk returns a tuple with the CredentialType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialPreference) GetCredentialTypeOk() (*string, bool) { + if o == nil || IsNil(o.CredentialType) { + return nil, false + } + return o.CredentialType, true +} + +// HasCredentialType returns a boolean if a field has been set. +func (o *CredentialPreference) HasCredentialType() bool { + if o != nil && !IsNil(o.CredentialType) { + return true + } + + return false +} + +// SetCredentialType gets a reference to the given string and assigns it to the CredentialType field. +func (o *CredentialPreference) SetCredentialType(v string) { + o.CredentialType = &v +} + +func (o CredentialPreference) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CredentialPreference) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AccessIdentifierType) { + toSerialize["access_identifier_type"] = o.AccessIdentifierType + } + if !IsNil(o.CredentialType) { + toSerialize["credential_type"] = o.CredentialType + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *CredentialPreference) UnmarshalJSON(data []byte) (err error) { + varCredentialPreference := _CredentialPreference{} + + err = json.Unmarshal(data, &varCredentialPreference) + + if err != nil { + return err + } + + *o = CredentialPreference(varCredentialPreference) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "access_identifier_type") + delete(additionalProperties, "credential_type") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableCredentialPreference struct { + value *CredentialPreference + isSet bool +} + +func (v NullableCredentialPreference) Get() *CredentialPreference { + return v.value +} + +func (v *NullableCredentialPreference) Set(val *CredentialPreference) { + v.value = val + v.isSet = true +} + +func (v NullableCredentialPreference) IsSet() bool { + return v.isSet +} + +func (v *NullableCredentialPreference) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCredentialPreference(val *CredentialPreference) *NullableCredentialPreference { + return &NullableCredentialPreference{value: val, isSet: true} +} + +func (v NullableCredentialPreference) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCredentialPreference) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_destination.go b/clouddiscovery/model_destination.go new file mode 100644 index 0000000..421c86d --- /dev/null +++ b/clouddiscovery/model_destination.go @@ -0,0 +1,358 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" + "fmt" + "time" +) + +// checks if the Destination type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Destination{} + +// Destination Destination information +type Destination struct { + // Destination configuration. Ex.: '{ \"dns\": { \"view_name\": \"view 1\", \"view_id\": \"dns/view/v1\", \"consolidated_zone_data_enabled\": false, \"sync_type\": \"read_only/read_write\" \"split_view_enabled\": false }, \"ipam\": { \"ip_space\": \"\", }, \"account\": {}, }'. + Config *DestinationConfig `json:"config,omitempty"` + // Timestamp when the object has been created. + CreatedAt *time.Time `json:"created_at,omitempty"` + // Timestamp when the object has been deleted. + DeletedAt *time.Time `json:"deleted_at,omitempty"` + // Destination type: DNS / IPAM / ACCOUNT. + DestinationType string `json:"destination_type"` + // Auto-generated unique destination ID. Format BloxID. + Id *string `json:"id,omitempty"` + // Timestamp when the object has been updated. + UpdatedAt *time.Time `json:"updated_at,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _Destination Destination + +// NewDestination instantiates a new Destination 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 NewDestination(destinationType string) *Destination { + this := Destination{} + this.DestinationType = destinationType + return &this +} + +// NewDestinationWithDefaults instantiates a new Destination 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 NewDestinationWithDefaults() *Destination { + this := Destination{} + return &this +} + +// GetConfig returns the Config field value if set, zero value otherwise. +func (o *Destination) GetConfig() DestinationConfig { + if o == nil || IsNil(o.Config) { + var ret DestinationConfig + return ret + } + return *o.Config +} + +// GetConfigOk returns a tuple with the Config field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Destination) GetConfigOk() (*DestinationConfig, bool) { + if o == nil || IsNil(o.Config) { + return nil, false + } + return o.Config, true +} + +// HasConfig returns a boolean if a field has been set. +func (o *Destination) HasConfig() bool { + if o != nil && !IsNil(o.Config) { + return true + } + + return false +} + +// SetConfig gets a reference to the given DestinationConfig and assigns it to the Config field. +func (o *Destination) SetConfig(v DestinationConfig) { + o.Config = &v +} + +// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise. +func (o *Destination) GetCreatedAt() time.Time { + if o == nil || IsNil(o.CreatedAt) { + var ret time.Time + return ret + } + return *o.CreatedAt +} + +// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Destination) GetCreatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.CreatedAt) { + return nil, false + } + return o.CreatedAt, true +} + +// HasCreatedAt returns a boolean if a field has been set. +func (o *Destination) HasCreatedAt() bool { + if o != nil && !IsNil(o.CreatedAt) { + return true + } + + return false +} + +// SetCreatedAt gets a reference to the given time.Time and assigns it to the CreatedAt field. +func (o *Destination) SetCreatedAt(v time.Time) { + o.CreatedAt = &v +} + +// GetDeletedAt returns the DeletedAt field value if set, zero value otherwise. +func (o *Destination) GetDeletedAt() time.Time { + if o == nil || IsNil(o.DeletedAt) { + var ret time.Time + return ret + } + return *o.DeletedAt +} + +// GetDeletedAtOk returns a tuple with the DeletedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Destination) GetDeletedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.DeletedAt) { + return nil, false + } + return o.DeletedAt, true +} + +// HasDeletedAt returns a boolean if a field has been set. +func (o *Destination) HasDeletedAt() bool { + if o != nil && !IsNil(o.DeletedAt) { + return true + } + + return false +} + +// SetDeletedAt gets a reference to the given time.Time and assigns it to the DeletedAt field. +func (o *Destination) SetDeletedAt(v time.Time) { + o.DeletedAt = &v +} + +// GetDestinationType returns the DestinationType field value +func (o *Destination) GetDestinationType() string { + if o == nil { + var ret string + return ret + } + + return o.DestinationType +} + +// GetDestinationTypeOk returns a tuple with the DestinationType field value +// and a boolean to check if the value has been set. +func (o *Destination) GetDestinationTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DestinationType, true +} + +// SetDestinationType sets field value +func (o *Destination) SetDestinationType(v string) { + o.DestinationType = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *Destination) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Destination) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Destination) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *Destination) SetId(v string) { + o.Id = &v +} + +// GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise. +func (o *Destination) GetUpdatedAt() time.Time { + if o == nil || IsNil(o.UpdatedAt) { + var ret time.Time + return ret + } + return *o.UpdatedAt +} + +// GetUpdatedAtOk returns a tuple with the UpdatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Destination) GetUpdatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.UpdatedAt) { + return nil, false + } + return o.UpdatedAt, true +} + +// HasUpdatedAt returns a boolean if a field has been set. +func (o *Destination) HasUpdatedAt() bool { + if o != nil && !IsNil(o.UpdatedAt) { + return true + } + + return false +} + +// SetUpdatedAt gets a reference to the given time.Time and assigns it to the UpdatedAt field. +func (o *Destination) SetUpdatedAt(v time.Time) { + o.UpdatedAt = &v +} + +func (o Destination) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Destination) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Config) { + toSerialize["config"] = o.Config + } + if !IsNil(o.CreatedAt) { + toSerialize["created_at"] = o.CreatedAt + } + if !IsNil(o.DeletedAt) { + toSerialize["deleted_at"] = o.DeletedAt + } + toSerialize["destination_type"] = o.DestinationType + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.UpdatedAt) { + toSerialize["updated_at"] = o.UpdatedAt + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *Destination) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "destination_type", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err + } + + for _, requiredProperty := range requiredProperties { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDestination := _Destination{} + + err = json.Unmarshal(data, &varDestination) + + if err != nil { + return err + } + + *o = Destination(varDestination) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "config") + delete(additionalProperties, "created_at") + delete(additionalProperties, "deleted_at") + delete(additionalProperties, "destination_type") + delete(additionalProperties, "id") + delete(additionalProperties, "updated_at") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableDestination struct { + value *Destination + isSet bool +} + +func (v NullableDestination) Get() *Destination { + return v.value +} + +func (v *NullableDestination) Set(val *Destination) { + v.value = val + v.isSet = true +} + +func (v NullableDestination) IsSet() bool { + return v.isSet +} + +func (v *NullableDestination) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDestination(val *Destination) *NullableDestination { + return &NullableDestination{value: val, isSet: true} +} + +func (v NullableDestination) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDestination) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_destination_config.go b/clouddiscovery/model_destination_config.go new file mode 100644 index 0000000..a5122c3 --- /dev/null +++ b/clouddiscovery/model_destination_config.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the DestinationConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DestinationConfig{} + +// DestinationConfig struct for DestinationConfig +type DestinationConfig struct { + Dns *DNSConfig `json:"dns,omitempty"` + Ipam *IPAMConfig `json:"ipam,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _DestinationConfig DestinationConfig + +// NewDestinationConfig instantiates a new DestinationConfig 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 NewDestinationConfig() *DestinationConfig { + this := DestinationConfig{} + return &this +} + +// NewDestinationConfigWithDefaults instantiates a new DestinationConfig 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 NewDestinationConfigWithDefaults() *DestinationConfig { + this := DestinationConfig{} + return &this +} + +// GetDns returns the Dns field value if set, zero value otherwise. +func (o *DestinationConfig) GetDns() DNSConfig { + if o == nil || IsNil(o.Dns) { + var ret DNSConfig + return ret + } + return *o.Dns +} + +// GetDnsOk returns a tuple with the Dns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DestinationConfig) GetDnsOk() (*DNSConfig, bool) { + if o == nil || IsNil(o.Dns) { + return nil, false + } + return o.Dns, true +} + +// HasDns returns a boolean if a field has been set. +func (o *DestinationConfig) HasDns() bool { + if o != nil && !IsNil(o.Dns) { + return true + } + + return false +} + +// SetDns gets a reference to the given DNSConfig and assigns it to the Dns field. +func (o *DestinationConfig) SetDns(v DNSConfig) { + o.Dns = &v +} + +// GetIpam returns the Ipam field value if set, zero value otherwise. +func (o *DestinationConfig) GetIpam() IPAMConfig { + if o == nil || IsNil(o.Ipam) { + var ret IPAMConfig + return ret + } + return *o.Ipam +} + +// GetIpamOk returns a tuple with the Ipam field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DestinationConfig) GetIpamOk() (*IPAMConfig, bool) { + if o == nil || IsNil(o.Ipam) { + return nil, false + } + return o.Ipam, true +} + +// HasIpam returns a boolean if a field has been set. +func (o *DestinationConfig) HasIpam() bool { + if o != nil && !IsNil(o.Ipam) { + return true + } + + return false +} + +// SetIpam gets a reference to the given IPAMConfig and assigns it to the Ipam field. +func (o *DestinationConfig) SetIpam(v IPAMConfig) { + o.Ipam = &v +} + +func (o DestinationConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DestinationConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Dns) { + toSerialize["dns"] = o.Dns + } + if !IsNil(o.Ipam) { + toSerialize["ipam"] = o.Ipam + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *DestinationConfig) UnmarshalJSON(data []byte) (err error) { + varDestinationConfig := _DestinationConfig{} + + err = json.Unmarshal(data, &varDestinationConfig) + + if err != nil { + return err + } + + *o = DestinationConfig(varDestinationConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "dns") + delete(additionalProperties, "ipam") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableDestinationConfig struct { + value *DestinationConfig + isSet bool +} + +func (v NullableDestinationConfig) Get() *DestinationConfig { + return v.value +} + +func (v *NullableDestinationConfig) Set(val *DestinationConfig) { + v.value = val + v.isSet = true +} + +func (v NullableDestinationConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableDestinationConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDestinationConfig(val *DestinationConfig) *NullableDestinationConfig { + return &NullableDestinationConfig{value: val, isSet: true} +} + +func (v NullableDestinationConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDestinationConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_discovery_config.go b/clouddiscovery/model_discovery_config.go new file mode 100644 index 0000000..d9a6f0f --- /dev/null +++ b/clouddiscovery/model_discovery_config.go @@ -0,0 +1,851 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" + "fmt" + "time" +) + +// checks if the DiscoveryConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DiscoveryConfig{} + +// DiscoveryConfig Discovery configuration +type DiscoveryConfig struct { + // Account preference. For ex.: single, multiple, auto-discover-multiple. + AccountPreference *string `json:"account_preference,omitempty"` + // Additional configuration. Ex.: '{ \"excluded_object_types\": [], \"exclusion_account_list\": [], \"zone_forwarding\": \"true\" or \"false\" }'. + AdditionalConfig *AdditionalConfig `json:"additional_config,omitempty"` + // Timestamp when the object has been created. + CreatedAt *time.Time `json:"created_at,omitempty"` + // Credential preference. Ex.: '{ \"type\": \"static\" or \"delegated\", \"access_identifier_type\": \"role_arn\" or \"tenant_id\" or \"project_id\" }'. + CredentialPreference *CredentialPreference `json:"credential_preference,omitempty"` + // Timestamp when the object has been deleted. + DeletedAt *time.Time `json:"deleted_at,omitempty"` + // Description of the discovery config. Optional. + Description *string `json:"description,omitempty"` + // Desired state. Default is \"enabled\". + DesiredState *string `json:"desired_state,omitempty"` + // Destinations types enabled: Ex.: DNS, IPAM and ACCOUNT. + DestinationTypesEnabled []string `json:"destination_types_enabled,omitempty"` + // Destinations. + Destinations []Destination `json:"destinations,omitempty"` + // Auto-generated unique discovery config ID. Format BloxID. + Id *string `json:"id,omitempty"` + // Last sync timestamp. + LastSync *time.Time `json:"last_sync,omitempty"` + // Name of the discovery config. + Name string `json:"name"` + // Provider type. Ex.: Amazon Web Services, Google Cloud Platform, Microsoft Azure. + ProviderType *string `json:"provider_type,omitempty"` + // Source configs. + SourceConfigs []SourceConfig `json:"source_configs,omitempty"` + // Status of the sync operation. In single account case, Its the combined status of account & all the destinations statuses In auto discover case, Its the status of the account discovery only. + Status *string `json:"status,omitempty"` + // Aggregate status message of the sync operation. + StatusMessage *string `json:"status_message,omitempty"` + SyncInterval *string `json:"sync_interval,omitempty"` + // Tagging specifics. + Tags map[string]interface{} `json:"tags,omitempty"` + // Timestamp when the object has been updated. + UpdatedAt *time.Time `json:"updated_at,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _DiscoveryConfig DiscoveryConfig + +// NewDiscoveryConfig instantiates a new DiscoveryConfig 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 NewDiscoveryConfig(name string) *DiscoveryConfig { + this := DiscoveryConfig{} + this.Name = name + return &this +} + +// NewDiscoveryConfigWithDefaults instantiates a new DiscoveryConfig 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 NewDiscoveryConfigWithDefaults() *DiscoveryConfig { + this := DiscoveryConfig{} + return &this +} + +// GetAccountPreference returns the AccountPreference field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetAccountPreference() string { + if o == nil || IsNil(o.AccountPreference) { + var ret string + return ret + } + return *o.AccountPreference +} + +// GetAccountPreferenceOk returns a tuple with the AccountPreference field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetAccountPreferenceOk() (*string, bool) { + if o == nil || IsNil(o.AccountPreference) { + return nil, false + } + return o.AccountPreference, true +} + +// HasAccountPreference returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasAccountPreference() bool { + if o != nil && !IsNil(o.AccountPreference) { + return true + } + + return false +} + +// SetAccountPreference gets a reference to the given string and assigns it to the AccountPreference field. +func (o *DiscoveryConfig) SetAccountPreference(v string) { + o.AccountPreference = &v +} + +// GetAdditionalConfig returns the AdditionalConfig field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetAdditionalConfig() AdditionalConfig { + if o == nil || IsNil(o.AdditionalConfig) { + var ret AdditionalConfig + return ret + } + return *o.AdditionalConfig +} + +// GetAdditionalConfigOk returns a tuple with the AdditionalConfig field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetAdditionalConfigOk() (*AdditionalConfig, bool) { + if o == nil || IsNil(o.AdditionalConfig) { + return nil, false + } + return o.AdditionalConfig, true +} + +// HasAdditionalConfig returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasAdditionalConfig() bool { + if o != nil && !IsNil(o.AdditionalConfig) { + return true + } + + return false +} + +// SetAdditionalConfig gets a reference to the given AdditionalConfig and assigns it to the AdditionalConfig field. +func (o *DiscoveryConfig) SetAdditionalConfig(v AdditionalConfig) { + o.AdditionalConfig = &v +} + +// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetCreatedAt() time.Time { + if o == nil || IsNil(o.CreatedAt) { + var ret time.Time + return ret + } + return *o.CreatedAt +} + +// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetCreatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.CreatedAt) { + return nil, false + } + return o.CreatedAt, true +} + +// HasCreatedAt returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasCreatedAt() bool { + if o != nil && !IsNil(o.CreatedAt) { + return true + } + + return false +} + +// SetCreatedAt gets a reference to the given time.Time and assigns it to the CreatedAt field. +func (o *DiscoveryConfig) SetCreatedAt(v time.Time) { + o.CreatedAt = &v +} + +// GetCredentialPreference returns the CredentialPreference field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetCredentialPreference() CredentialPreference { + if o == nil || IsNil(o.CredentialPreference) { + var ret CredentialPreference + return ret + } + return *o.CredentialPreference +} + +// GetCredentialPreferenceOk returns a tuple with the CredentialPreference field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetCredentialPreferenceOk() (*CredentialPreference, bool) { + if o == nil || IsNil(o.CredentialPreference) { + return nil, false + } + return o.CredentialPreference, true +} + +// HasCredentialPreference returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasCredentialPreference() bool { + if o != nil && !IsNil(o.CredentialPreference) { + return true + } + + return false +} + +// SetCredentialPreference gets a reference to the given CredentialPreference and assigns it to the CredentialPreference field. +func (o *DiscoveryConfig) SetCredentialPreference(v CredentialPreference) { + o.CredentialPreference = &v +} + +// GetDeletedAt returns the DeletedAt field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetDeletedAt() time.Time { + if o == nil || IsNil(o.DeletedAt) { + var ret time.Time + return ret + } + return *o.DeletedAt +} + +// GetDeletedAtOk returns a tuple with the DeletedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetDeletedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.DeletedAt) { + return nil, false + } + return o.DeletedAt, true +} + +// HasDeletedAt returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasDeletedAt() bool { + if o != nil && !IsNil(o.DeletedAt) { + return true + } + + return false +} + +// SetDeletedAt gets a reference to the given time.Time and assigns it to the DeletedAt field. +func (o *DiscoveryConfig) SetDeletedAt(v time.Time) { + o.DeletedAt = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetDescription() string { + if o == nil || IsNil(o.Description) { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetDescriptionOk() (*string, bool) { + if o == nil || IsNil(o.Description) { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasDescription() bool { + if o != nil && !IsNil(o.Description) { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *DiscoveryConfig) SetDescription(v string) { + o.Description = &v +} + +// GetDesiredState returns the DesiredState field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetDesiredState() string { + if o == nil || IsNil(o.DesiredState) { + var ret string + return ret + } + return *o.DesiredState +} + +// GetDesiredStateOk returns a tuple with the DesiredState field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetDesiredStateOk() (*string, bool) { + if o == nil || IsNil(o.DesiredState) { + return nil, false + } + return o.DesiredState, true +} + +// HasDesiredState returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasDesiredState() bool { + if o != nil && !IsNil(o.DesiredState) { + return true + } + + return false +} + +// SetDesiredState gets a reference to the given string and assigns it to the DesiredState field. +func (o *DiscoveryConfig) SetDesiredState(v string) { + o.DesiredState = &v +} + +// GetDestinationTypesEnabled returns the DestinationTypesEnabled field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetDestinationTypesEnabled() []string { + if o == nil || IsNil(o.DestinationTypesEnabled) { + var ret []string + return ret + } + return o.DestinationTypesEnabled +} + +// GetDestinationTypesEnabledOk returns a tuple with the DestinationTypesEnabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetDestinationTypesEnabledOk() ([]string, bool) { + if o == nil || IsNil(o.DestinationTypesEnabled) { + return nil, false + } + return o.DestinationTypesEnabled, true +} + +// HasDestinationTypesEnabled returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasDestinationTypesEnabled() bool { + if o != nil && !IsNil(o.DestinationTypesEnabled) { + return true + } + + return false +} + +// SetDestinationTypesEnabled gets a reference to the given []string and assigns it to the DestinationTypesEnabled field. +func (o *DiscoveryConfig) SetDestinationTypesEnabled(v []string) { + o.DestinationTypesEnabled = v +} + +// GetDestinations returns the Destinations field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetDestinations() []Destination { + if o == nil || IsNil(o.Destinations) { + var ret []Destination + return ret + } + return o.Destinations +} + +// GetDestinationsOk returns a tuple with the Destinations field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetDestinationsOk() ([]Destination, bool) { + if o == nil || IsNil(o.Destinations) { + return nil, false + } + return o.Destinations, true +} + +// HasDestinations returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasDestinations() bool { + if o != nil && !IsNil(o.Destinations) { + return true + } + + return false +} + +// SetDestinations gets a reference to the given []Destination and assigns it to the Destinations field. +func (o *DiscoveryConfig) SetDestinations(v []Destination) { + o.Destinations = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *DiscoveryConfig) SetId(v string) { + o.Id = &v +} + +// GetLastSync returns the LastSync field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetLastSync() time.Time { + if o == nil || IsNil(o.LastSync) { + var ret time.Time + return ret + } + return *o.LastSync +} + +// GetLastSyncOk returns a tuple with the LastSync field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetLastSyncOk() (*time.Time, bool) { + if o == nil || IsNil(o.LastSync) { + return nil, false + } + return o.LastSync, true +} + +// HasLastSync returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasLastSync() bool { + if o != nil && !IsNil(o.LastSync) { + return true + } + + return false +} + +// SetLastSync gets a reference to the given time.Time and assigns it to the LastSync field. +func (o *DiscoveryConfig) SetLastSync(v time.Time) { + o.LastSync = &v +} + +// GetName returns the Name field value +func (o *DiscoveryConfig) GetName() string { + if o == nil { + var ret string + return ret + } + + return o.Name +} + +// GetNameOk returns a tuple with the Name field value +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Name, true +} + +// SetName sets field value +func (o *DiscoveryConfig) SetName(v string) { + o.Name = v +} + +// GetProviderType returns the ProviderType field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetProviderType() string { + if o == nil || IsNil(o.ProviderType) { + var ret string + return ret + } + return *o.ProviderType +} + +// GetProviderTypeOk returns a tuple with the ProviderType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetProviderTypeOk() (*string, bool) { + if o == nil || IsNil(o.ProviderType) { + return nil, false + } + return o.ProviderType, true +} + +// HasProviderType returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasProviderType() bool { + if o != nil && !IsNil(o.ProviderType) { + return true + } + + return false +} + +// SetProviderType gets a reference to the given string and assigns it to the ProviderType field. +func (o *DiscoveryConfig) SetProviderType(v string) { + o.ProviderType = &v +} + +// GetSourceConfigs returns the SourceConfigs field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetSourceConfigs() []SourceConfig { + if o == nil || IsNil(o.SourceConfigs) { + var ret []SourceConfig + return ret + } + return o.SourceConfigs +} + +// GetSourceConfigsOk returns a tuple with the SourceConfigs field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetSourceConfigsOk() ([]SourceConfig, bool) { + if o == nil || IsNil(o.SourceConfigs) { + return nil, false + } + return o.SourceConfigs, true +} + +// HasSourceConfigs returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasSourceConfigs() bool { + if o != nil && !IsNil(o.SourceConfigs) { + return true + } + + return false +} + +// SetSourceConfigs gets a reference to the given []SourceConfig and assigns it to the SourceConfigs field. +func (o *DiscoveryConfig) SetSourceConfigs(v []SourceConfig) { + o.SourceConfigs = v +} + +// GetStatus returns the Status field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetStatus() string { + if o == nil || IsNil(o.Status) { + var ret string + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetStatusOk() (*string, bool) { + if o == nil || IsNil(o.Status) { + return nil, false + } + return o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasStatus() bool { + if o != nil && !IsNil(o.Status) { + return true + } + + return false +} + +// SetStatus gets a reference to the given string and assigns it to the Status field. +func (o *DiscoveryConfig) SetStatus(v string) { + o.Status = &v +} + +// GetStatusMessage returns the StatusMessage field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetStatusMessage() string { + if o == nil || IsNil(o.StatusMessage) { + var ret string + return ret + } + return *o.StatusMessage +} + +// GetStatusMessageOk returns a tuple with the StatusMessage field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetStatusMessageOk() (*string, bool) { + if o == nil || IsNil(o.StatusMessage) { + return nil, false + } + return o.StatusMessage, true +} + +// HasStatusMessage returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasStatusMessage() bool { + if o != nil && !IsNil(o.StatusMessage) { + return true + } + + return false +} + +// SetStatusMessage gets a reference to the given string and assigns it to the StatusMessage field. +func (o *DiscoveryConfig) SetStatusMessage(v string) { + o.StatusMessage = &v +} + +// GetSyncInterval returns the SyncInterval field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetSyncInterval() string { + if o == nil || IsNil(o.SyncInterval) { + var ret string + return ret + } + return *o.SyncInterval +} + +// GetSyncIntervalOk returns a tuple with the SyncInterval field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetSyncIntervalOk() (*string, bool) { + if o == nil || IsNil(o.SyncInterval) { + return nil, false + } + return o.SyncInterval, true +} + +// HasSyncInterval returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasSyncInterval() bool { + if o != nil && !IsNil(o.SyncInterval) { + return true + } + + return false +} + +// SetSyncInterval gets a reference to the given string and assigns it to the SyncInterval field. +func (o *DiscoveryConfig) SetSyncInterval(v string) { + o.SyncInterval = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetTags() map[string]interface{} { + if o == nil || IsNil(o.Tags) { + var ret map[string]interface{} + return ret + } + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetTagsOk() (map[string]interface{}, bool) { + if o == nil || IsNil(o.Tags) { + return map[string]interface{}{}, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasTags() bool { + if o != nil && !IsNil(o.Tags) { + return true + } + + return false +} + +// SetTags gets a reference to the given map[string]interface{} and assigns it to the Tags field. +func (o *DiscoveryConfig) SetTags(v map[string]interface{}) { + o.Tags = v +} + +// GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise. +func (o *DiscoveryConfig) GetUpdatedAt() time.Time { + if o == nil || IsNil(o.UpdatedAt) { + var ret time.Time + return ret + } + return *o.UpdatedAt +} + +// GetUpdatedAtOk returns a tuple with the UpdatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DiscoveryConfig) GetUpdatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.UpdatedAt) { + return nil, false + } + return o.UpdatedAt, true +} + +// HasUpdatedAt returns a boolean if a field has been set. +func (o *DiscoveryConfig) HasUpdatedAt() bool { + if o != nil && !IsNil(o.UpdatedAt) { + return true + } + + return false +} + +// SetUpdatedAt gets a reference to the given time.Time and assigns it to the UpdatedAt field. +func (o *DiscoveryConfig) SetUpdatedAt(v time.Time) { + o.UpdatedAt = &v +} + +func (o DiscoveryConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DiscoveryConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AccountPreference) { + toSerialize["account_preference"] = o.AccountPreference + } + if !IsNil(o.AdditionalConfig) { + toSerialize["additional_config"] = o.AdditionalConfig + } + if !IsNil(o.CreatedAt) { + toSerialize["created_at"] = o.CreatedAt + } + if !IsNil(o.CredentialPreference) { + toSerialize["credential_preference"] = o.CredentialPreference + } + if !IsNil(o.DeletedAt) { + toSerialize["deleted_at"] = o.DeletedAt + } + if !IsNil(o.Description) { + toSerialize["description"] = o.Description + } + if !IsNil(o.DesiredState) { + toSerialize["desired_state"] = o.DesiredState + } + if !IsNil(o.DestinationTypesEnabled) { + toSerialize["destination_types_enabled"] = o.DestinationTypesEnabled + } + if !IsNil(o.Destinations) { + toSerialize["destinations"] = o.Destinations + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.LastSync) { + toSerialize["last_sync"] = o.LastSync + } + toSerialize["name"] = o.Name + if !IsNil(o.ProviderType) { + toSerialize["provider_type"] = o.ProviderType + } + if !IsNil(o.SourceConfigs) { + toSerialize["source_configs"] = o.SourceConfigs + } + if !IsNil(o.Status) { + toSerialize["status"] = o.Status + } + if !IsNil(o.StatusMessage) { + toSerialize["status_message"] = o.StatusMessage + } + if !IsNil(o.SyncInterval) { + toSerialize["sync_interval"] = o.SyncInterval + } + if !IsNil(o.Tags) { + toSerialize["tags"] = o.Tags + } + if !IsNil(o.UpdatedAt) { + toSerialize["updated_at"] = o.UpdatedAt + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *DiscoveryConfig) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "name", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err + } + + for _, requiredProperty := range requiredProperties { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDiscoveryConfig := _DiscoveryConfig{} + + err = json.Unmarshal(data, &varDiscoveryConfig) + + if err != nil { + return err + } + + *o = DiscoveryConfig(varDiscoveryConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "account_preference") + delete(additionalProperties, "additional_config") + delete(additionalProperties, "created_at") + delete(additionalProperties, "credential_preference") + delete(additionalProperties, "deleted_at") + delete(additionalProperties, "description") + delete(additionalProperties, "desired_state") + delete(additionalProperties, "destination_types_enabled") + delete(additionalProperties, "destinations") + delete(additionalProperties, "id") + delete(additionalProperties, "last_sync") + delete(additionalProperties, "name") + delete(additionalProperties, "provider_type") + delete(additionalProperties, "source_configs") + delete(additionalProperties, "status") + delete(additionalProperties, "status_message") + delete(additionalProperties, "sync_interval") + delete(additionalProperties, "tags") + delete(additionalProperties, "updated_at") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableDiscoveryConfig struct { + value *DiscoveryConfig + isSet bool +} + +func (v NullableDiscoveryConfig) Get() *DiscoveryConfig { + return v.value +} + +func (v *NullableDiscoveryConfig) Set(val *DiscoveryConfig) { + v.value = val + v.isSet = true +} + +func (v NullableDiscoveryConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableDiscoveryConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDiscoveryConfig(val *DiscoveryConfig) *NullableDiscoveryConfig { + return &NullableDiscoveryConfig{value: val, isSet: true} +} + +func (v NullableDiscoveryConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDiscoveryConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_dns_config.go b/clouddiscovery/model_dns_config.go new file mode 100644 index 0000000..a22dd7b --- /dev/null +++ b/clouddiscovery/model_dns_config.go @@ -0,0 +1,302 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the DNSConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DNSConfig{} + +// DNSConfig struct for DNSConfig +type DNSConfig struct { + ConsolidatedZoneDataEnabled *bool `json:"consolidated_zone_data_enabled,omitempty"` + // split_view_enabled consolidates private zones into a single view, which is separate from the public zone view. + SplitViewEnabled *bool `json:"split_view_enabled,omitempty"` + SyncType *string `json:"sync_type,omitempty"` + ViewId *string `json:"view_id,omitempty"` + ViewName *string `json:"view_name,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _DNSConfig DNSConfig + +// NewDNSConfig instantiates a new DNSConfig 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 NewDNSConfig() *DNSConfig { + this := DNSConfig{} + return &this +} + +// NewDNSConfigWithDefaults instantiates a new DNSConfig 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 NewDNSConfigWithDefaults() *DNSConfig { + this := DNSConfig{} + return &this +} + +// GetConsolidatedZoneDataEnabled returns the ConsolidatedZoneDataEnabled field value if set, zero value otherwise. +func (o *DNSConfig) GetConsolidatedZoneDataEnabled() bool { + if o == nil || IsNil(o.ConsolidatedZoneDataEnabled) { + var ret bool + return ret + } + return *o.ConsolidatedZoneDataEnabled +} + +// GetConsolidatedZoneDataEnabledOk returns a tuple with the ConsolidatedZoneDataEnabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DNSConfig) GetConsolidatedZoneDataEnabledOk() (*bool, bool) { + if o == nil || IsNil(o.ConsolidatedZoneDataEnabled) { + return nil, false + } + return o.ConsolidatedZoneDataEnabled, true +} + +// HasConsolidatedZoneDataEnabled returns a boolean if a field has been set. +func (o *DNSConfig) HasConsolidatedZoneDataEnabled() bool { + if o != nil && !IsNil(o.ConsolidatedZoneDataEnabled) { + return true + } + + return false +} + +// SetConsolidatedZoneDataEnabled gets a reference to the given bool and assigns it to the ConsolidatedZoneDataEnabled field. +func (o *DNSConfig) SetConsolidatedZoneDataEnabled(v bool) { + o.ConsolidatedZoneDataEnabled = &v +} + +// GetSplitViewEnabled returns the SplitViewEnabled field value if set, zero value otherwise. +func (o *DNSConfig) GetSplitViewEnabled() bool { + if o == nil || IsNil(o.SplitViewEnabled) { + var ret bool + return ret + } + return *o.SplitViewEnabled +} + +// GetSplitViewEnabledOk returns a tuple with the SplitViewEnabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DNSConfig) GetSplitViewEnabledOk() (*bool, bool) { + if o == nil || IsNil(o.SplitViewEnabled) { + return nil, false + } + return o.SplitViewEnabled, true +} + +// HasSplitViewEnabled returns a boolean if a field has been set. +func (o *DNSConfig) HasSplitViewEnabled() bool { + if o != nil && !IsNil(o.SplitViewEnabled) { + return true + } + + return false +} + +// SetSplitViewEnabled gets a reference to the given bool and assigns it to the SplitViewEnabled field. +func (o *DNSConfig) SetSplitViewEnabled(v bool) { + o.SplitViewEnabled = &v +} + +// GetSyncType returns the SyncType field value if set, zero value otherwise. +func (o *DNSConfig) GetSyncType() string { + if o == nil || IsNil(o.SyncType) { + var ret string + return ret + } + return *o.SyncType +} + +// GetSyncTypeOk returns a tuple with the SyncType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DNSConfig) GetSyncTypeOk() (*string, bool) { + if o == nil || IsNil(o.SyncType) { + return nil, false + } + return o.SyncType, true +} + +// HasSyncType returns a boolean if a field has been set. +func (o *DNSConfig) HasSyncType() bool { + if o != nil && !IsNil(o.SyncType) { + return true + } + + return false +} + +// SetSyncType gets a reference to the given string and assigns it to the SyncType field. +func (o *DNSConfig) SetSyncType(v string) { + o.SyncType = &v +} + +// GetViewId returns the ViewId field value if set, zero value otherwise. +func (o *DNSConfig) GetViewId() string { + if o == nil || IsNil(o.ViewId) { + var ret string + return ret + } + return *o.ViewId +} + +// GetViewIdOk returns a tuple with the ViewId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DNSConfig) GetViewIdOk() (*string, bool) { + if o == nil || IsNil(o.ViewId) { + return nil, false + } + return o.ViewId, true +} + +// HasViewId returns a boolean if a field has been set. +func (o *DNSConfig) HasViewId() bool { + if o != nil && !IsNil(o.ViewId) { + return true + } + + return false +} + +// SetViewId gets a reference to the given string and assigns it to the ViewId field. +func (o *DNSConfig) SetViewId(v string) { + o.ViewId = &v +} + +// GetViewName returns the ViewName field value if set, zero value otherwise. +func (o *DNSConfig) GetViewName() string { + if o == nil || IsNil(o.ViewName) { + var ret string + return ret + } + return *o.ViewName +} + +// GetViewNameOk returns a tuple with the ViewName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DNSConfig) GetViewNameOk() (*string, bool) { + if o == nil || IsNil(o.ViewName) { + return nil, false + } + return o.ViewName, true +} + +// HasViewName returns a boolean if a field has been set. +func (o *DNSConfig) HasViewName() bool { + if o != nil && !IsNil(o.ViewName) { + return true + } + + return false +} + +// SetViewName gets a reference to the given string and assigns it to the ViewName field. +func (o *DNSConfig) SetViewName(v string) { + o.ViewName = &v +} + +func (o DNSConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DNSConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ConsolidatedZoneDataEnabled) { + toSerialize["consolidated_zone_data_enabled"] = o.ConsolidatedZoneDataEnabled + } + if !IsNil(o.SplitViewEnabled) { + toSerialize["split_view_enabled"] = o.SplitViewEnabled + } + if !IsNil(o.SyncType) { + toSerialize["sync_type"] = o.SyncType + } + if !IsNil(o.ViewId) { + toSerialize["view_id"] = o.ViewId + } + if !IsNil(o.ViewName) { + toSerialize["view_name"] = o.ViewName + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *DNSConfig) UnmarshalJSON(data []byte) (err error) { + varDNSConfig := _DNSConfig{} + + err = json.Unmarshal(data, &varDNSConfig) + + if err != nil { + return err + } + + *o = DNSConfig(varDNSConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "consolidated_zone_data_enabled") + delete(additionalProperties, "split_view_enabled") + delete(additionalProperties, "sync_type") + delete(additionalProperties, "view_id") + delete(additionalProperties, "view_name") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableDNSConfig struct { + value *DNSConfig + isSet bool +} + +func (v NullableDNSConfig) Get() *DNSConfig { + return v.value +} + +func (v *NullableDNSConfig) Set(val *DNSConfig) { + v.value = val + v.isSet = true +} + +func (v NullableDNSConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableDNSConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDNSConfig(val *DNSConfig) *NullableDNSConfig { + return &NullableDNSConfig{value: val, isSet: true} +} + +func (v NullableDNSConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDNSConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_ipam_config.go b/clouddiscovery/model_ipam_config.go new file mode 100644 index 0000000..b7bb0a5 --- /dev/null +++ b/clouddiscovery/model_ipam_config.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the IPAMConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &IPAMConfig{} + +// IPAMConfig struct for IPAMConfig +type IPAMConfig struct { + DhcpServer *string `json:"dhcp_server,omitempty"` + IpSpace *string `json:"ip_space,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _IPAMConfig IPAMConfig + +// NewIPAMConfig instantiates a new IPAMConfig 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 NewIPAMConfig() *IPAMConfig { + this := IPAMConfig{} + return &this +} + +// NewIPAMConfigWithDefaults instantiates a new IPAMConfig 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 NewIPAMConfigWithDefaults() *IPAMConfig { + this := IPAMConfig{} + return &this +} + +// GetDhcpServer returns the DhcpServer field value if set, zero value otherwise. +func (o *IPAMConfig) GetDhcpServer() string { + if o == nil || IsNil(o.DhcpServer) { + var ret string + return ret + } + return *o.DhcpServer +} + +// GetDhcpServerOk returns a tuple with the DhcpServer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *IPAMConfig) GetDhcpServerOk() (*string, bool) { + if o == nil || IsNil(o.DhcpServer) { + return nil, false + } + return o.DhcpServer, true +} + +// HasDhcpServer returns a boolean if a field has been set. +func (o *IPAMConfig) HasDhcpServer() bool { + if o != nil && !IsNil(o.DhcpServer) { + return true + } + + return false +} + +// SetDhcpServer gets a reference to the given string and assigns it to the DhcpServer field. +func (o *IPAMConfig) SetDhcpServer(v string) { + o.DhcpServer = &v +} + +// GetIpSpace returns the IpSpace field value if set, zero value otherwise. +func (o *IPAMConfig) GetIpSpace() string { + if o == nil || IsNil(o.IpSpace) { + var ret string + return ret + } + return *o.IpSpace +} + +// GetIpSpaceOk returns a tuple with the IpSpace field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *IPAMConfig) GetIpSpaceOk() (*string, bool) { + if o == nil || IsNil(o.IpSpace) { + return nil, false + } + return o.IpSpace, true +} + +// HasIpSpace returns a boolean if a field has been set. +func (o *IPAMConfig) HasIpSpace() bool { + if o != nil && !IsNil(o.IpSpace) { + return true + } + + return false +} + +// SetIpSpace gets a reference to the given string and assigns it to the IpSpace field. +func (o *IPAMConfig) SetIpSpace(v string) { + o.IpSpace = &v +} + +func (o IPAMConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o IPAMConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.DhcpServer) { + toSerialize["dhcp_server"] = o.DhcpServer + } + if !IsNil(o.IpSpace) { + toSerialize["ip_space"] = o.IpSpace + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *IPAMConfig) UnmarshalJSON(data []byte) (err error) { + varIPAMConfig := _IPAMConfig{} + + err = json.Unmarshal(data, &varIPAMConfig) + + if err != nil { + return err + } + + *o = IPAMConfig(varIPAMConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "dhcp_server") + delete(additionalProperties, "ip_space") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableIPAMConfig struct { + value *IPAMConfig + isSet bool +} + +func (v NullableIPAMConfig) Get() *IPAMConfig { + return v.value +} + +func (v *NullableIPAMConfig) Set(val *IPAMConfig) { + v.value = val + v.isSet = true +} + +func (v NullableIPAMConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableIPAMConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableIPAMConfig(val *IPAMConfig) *NullableIPAMConfig { + return &NullableIPAMConfig{value: val, isSet: true} +} + +func (v NullableIPAMConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableIPAMConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_object.go b/clouddiscovery/model_object.go new file mode 100644 index 0000000..f790667 --- /dev/null +++ b/clouddiscovery/model_object.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the Object type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Object{} + +// Object struct for Object +type Object struct { + Category *Category `json:"category,omitempty"` + ResourceSet []Resource `json:"resource_set,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _Object Object + +// NewObject instantiates a new Object 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 NewObject() *Object { + this := Object{} + return &this +} + +// NewObjectWithDefaults instantiates a new Object 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 NewObjectWithDefaults() *Object { + this := Object{} + return &this +} + +// GetCategory returns the Category field value if set, zero value otherwise. +func (o *Object) GetCategory() Category { + if o == nil || IsNil(o.Category) { + var ret Category + return ret + } + return *o.Category +} + +// GetCategoryOk returns a tuple with the Category field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Object) GetCategoryOk() (*Category, bool) { + if o == nil || IsNil(o.Category) { + return nil, false + } + return o.Category, true +} + +// HasCategory returns a boolean if a field has been set. +func (o *Object) HasCategory() bool { + if o != nil && !IsNil(o.Category) { + return true + } + + return false +} + +// SetCategory gets a reference to the given Category and assigns it to the Category field. +func (o *Object) SetCategory(v Category) { + o.Category = &v +} + +// GetResourceSet returns the ResourceSet field value if set, zero value otherwise. +func (o *Object) GetResourceSet() []Resource { + if o == nil || IsNil(o.ResourceSet) { + var ret []Resource + return ret + } + return o.ResourceSet +} + +// GetResourceSetOk returns a tuple with the ResourceSet field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Object) GetResourceSetOk() ([]Resource, bool) { + if o == nil || IsNil(o.ResourceSet) { + return nil, false + } + return o.ResourceSet, true +} + +// HasResourceSet returns a boolean if a field has been set. +func (o *Object) HasResourceSet() bool { + if o != nil && !IsNil(o.ResourceSet) { + return true + } + + return false +} + +// SetResourceSet gets a reference to the given []Resource and assigns it to the ResourceSet field. +func (o *Object) SetResourceSet(v []Resource) { + o.ResourceSet = v +} + +func (o Object) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Object) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Category) { + toSerialize["category"] = o.Category + } + if !IsNil(o.ResourceSet) { + toSerialize["resource_set"] = o.ResourceSet + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *Object) UnmarshalJSON(data []byte) (err error) { + varObject := _Object{} + + err = json.Unmarshal(data, &varObject) + + if err != nil { + return err + } + + *o = Object(varObject) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "category") + delete(additionalProperties, "resource_set") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableObject struct { + value *Object + isSet bool +} + +func (v NullableObject) Get() *Object { + return v.value +} + +func (v *NullableObject) Set(val *Object) { + v.value = val + v.isSet = true +} + +func (v NullableObject) IsSet() bool { + return v.isSet +} + +func (v *NullableObject) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableObject(val *Object) *NullableObject { + return &NullableObject{value: val, isSet: true} +} + +func (v NullableObject) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableObject) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_object_type.go b/clouddiscovery/model_object_type.go new file mode 100644 index 0000000..f01a777 --- /dev/null +++ b/clouddiscovery/model_object_type.go @@ -0,0 +1,227 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the ObjectType type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ObjectType{} + +// ObjectType struct for ObjectType +type ObjectType struct { + DiscoverNew *bool `json:"discover_new,omitempty"` + Objects []Object `json:"objects,omitempty"` + Version *float32 `json:"version,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ObjectType ObjectType + +// NewObjectType instantiates a new ObjectType 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 NewObjectType() *ObjectType { + this := ObjectType{} + return &this +} + +// NewObjectTypeWithDefaults instantiates a new ObjectType 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 NewObjectTypeWithDefaults() *ObjectType { + this := ObjectType{} + return &this +} + +// GetDiscoverNew returns the DiscoverNew field value if set, zero value otherwise. +func (o *ObjectType) GetDiscoverNew() bool { + if o == nil || IsNil(o.DiscoverNew) { + var ret bool + return ret + } + return *o.DiscoverNew +} + +// GetDiscoverNewOk returns a tuple with the DiscoverNew field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ObjectType) GetDiscoverNewOk() (*bool, bool) { + if o == nil || IsNil(o.DiscoverNew) { + return nil, false + } + return o.DiscoverNew, true +} + +// HasDiscoverNew returns a boolean if a field has been set. +func (o *ObjectType) HasDiscoverNew() bool { + if o != nil && !IsNil(o.DiscoverNew) { + return true + } + + return false +} + +// SetDiscoverNew gets a reference to the given bool and assigns it to the DiscoverNew field. +func (o *ObjectType) SetDiscoverNew(v bool) { + o.DiscoverNew = &v +} + +// GetObjects returns the Objects field value if set, zero value otherwise. +func (o *ObjectType) GetObjects() []Object { + if o == nil || IsNil(o.Objects) { + var ret []Object + return ret + } + return o.Objects +} + +// GetObjectsOk returns a tuple with the Objects field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ObjectType) GetObjectsOk() ([]Object, bool) { + if o == nil || IsNil(o.Objects) { + return nil, false + } + return o.Objects, true +} + +// HasObjects returns a boolean if a field has been set. +func (o *ObjectType) HasObjects() bool { + if o != nil && !IsNil(o.Objects) { + return true + } + + return false +} + +// SetObjects gets a reference to the given []Object and assigns it to the Objects field. +func (o *ObjectType) SetObjects(v []Object) { + o.Objects = v +} + +// GetVersion returns the Version field value if set, zero value otherwise. +func (o *ObjectType) GetVersion() float32 { + if o == nil || IsNil(o.Version) { + var ret float32 + return ret + } + return *o.Version +} + +// GetVersionOk returns a tuple with the Version field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ObjectType) GetVersionOk() (*float32, bool) { + if o == nil || IsNil(o.Version) { + return nil, false + } + return o.Version, true +} + +// HasVersion returns a boolean if a field has been set. +func (o *ObjectType) HasVersion() bool { + if o != nil && !IsNil(o.Version) { + return true + } + + return false +} + +// SetVersion gets a reference to the given float32 and assigns it to the Version field. +func (o *ObjectType) SetVersion(v float32) { + o.Version = &v +} + +func (o ObjectType) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ObjectType) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.DiscoverNew) { + toSerialize["discover_new"] = o.DiscoverNew + } + if !IsNil(o.Objects) { + toSerialize["objects"] = o.Objects + } + if !IsNil(o.Version) { + toSerialize["version"] = o.Version + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ObjectType) UnmarshalJSON(data []byte) (err error) { + varObjectType := _ObjectType{} + + err = json.Unmarshal(data, &varObjectType) + + if err != nil { + return err + } + + *o = ObjectType(varObjectType) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "discover_new") + delete(additionalProperties, "objects") + delete(additionalProperties, "version") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableObjectType struct { + value *ObjectType + isSet bool +} + +func (v NullableObjectType) Get() *ObjectType { + return v.value +} + +func (v *NullableObjectType) Set(val *ObjectType) { + v.value = val + v.isSet = true +} + +func (v NullableObjectType) IsSet() bool { + return v.isSet +} + +func (v *NullableObjectType) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableObjectType(val *ObjectType) *NullableObjectType { + return &NullableObjectType{value: val, isSet: true} +} + +func (v NullableObjectType) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableObjectType) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_provider_create_response.go b/clouddiscovery/model_provider_create_response.go new file mode 100644 index 0000000..98f26ec --- /dev/null +++ b/clouddiscovery/model_provider_create_response.go @@ -0,0 +1,153 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the ProviderCreateResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ProviderCreateResponse{} + +// ProviderCreateResponse The Provider object create response format. +type ProviderCreateResponse struct { + Result *DiscoveryConfig `json:"result,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ProviderCreateResponse ProviderCreateResponse + +// NewProviderCreateResponse instantiates a new ProviderCreateResponse 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 NewProviderCreateResponse() *ProviderCreateResponse { + this := ProviderCreateResponse{} + return &this +} + +// NewProviderCreateResponseWithDefaults instantiates a new ProviderCreateResponse 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 NewProviderCreateResponseWithDefaults() *ProviderCreateResponse { + this := ProviderCreateResponse{} + return &this +} + +// GetResult returns the Result field value if set, zero value otherwise. +func (o *ProviderCreateResponse) GetResult() DiscoveryConfig { + if o == nil || IsNil(o.Result) { + var ret DiscoveryConfig + return ret + } + return *o.Result +} + +// GetResultOk returns a tuple with the Result field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProviderCreateResponse) GetResultOk() (*DiscoveryConfig, bool) { + if o == nil || IsNil(o.Result) { + return nil, false + } + return o.Result, true +} + +// HasResult returns a boolean if a field has been set. +func (o *ProviderCreateResponse) HasResult() bool { + if o != nil && !IsNil(o.Result) { + return true + } + + return false +} + +// SetResult gets a reference to the given DiscoveryConfig and assigns it to the Result field. +func (o *ProviderCreateResponse) SetResult(v DiscoveryConfig) { + o.Result = &v +} + +func (o ProviderCreateResponse) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ProviderCreateResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Result) { + toSerialize["result"] = o.Result + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ProviderCreateResponse) UnmarshalJSON(data []byte) (err error) { + varProviderCreateResponse := _ProviderCreateResponse{} + + err = json.Unmarshal(data, &varProviderCreateResponse) + + if err != nil { + return err + } + + *o = ProviderCreateResponse(varProviderCreateResponse) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "result") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableProviderCreateResponse struct { + value *ProviderCreateResponse + isSet bool +} + +func (v NullableProviderCreateResponse) Get() *ProviderCreateResponse { + return v.value +} + +func (v *NullableProviderCreateResponse) Set(val *ProviderCreateResponse) { + v.value = val + v.isSet = true +} + +func (v NullableProviderCreateResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableProviderCreateResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableProviderCreateResponse(val *ProviderCreateResponse) *NullableProviderCreateResponse { + return &NullableProviderCreateResponse{value: val, isSet: true} +} + +func (v NullableProviderCreateResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableProviderCreateResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_provider_list_response.go b/clouddiscovery/model_provider_list_response.go new file mode 100644 index 0000000..e12a41b --- /dev/null +++ b/clouddiscovery/model_provider_list_response.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the ProviderListResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ProviderListResponse{} + +// ProviderListResponse The Provider object List response format. +type ProviderListResponse struct { + Page *ApiPageInfo `json:"page,omitempty"` + Results []DiscoveryConfig `json:"results,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ProviderListResponse ProviderListResponse + +// NewProviderListResponse instantiates a new ProviderListResponse 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 NewProviderListResponse() *ProviderListResponse { + this := ProviderListResponse{} + return &this +} + +// NewProviderListResponseWithDefaults instantiates a new ProviderListResponse 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 NewProviderListResponseWithDefaults() *ProviderListResponse { + this := ProviderListResponse{} + return &this +} + +// GetPage returns the Page field value if set, zero value otherwise. +func (o *ProviderListResponse) GetPage() ApiPageInfo { + if o == nil || IsNil(o.Page) { + var ret ApiPageInfo + return ret + } + return *o.Page +} + +// GetPageOk returns a tuple with the Page field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProviderListResponse) GetPageOk() (*ApiPageInfo, bool) { + if o == nil || IsNil(o.Page) { + return nil, false + } + return o.Page, true +} + +// HasPage returns a boolean if a field has been set. +func (o *ProviderListResponse) HasPage() bool { + if o != nil && !IsNil(o.Page) { + return true + } + + return false +} + +// SetPage gets a reference to the given ApiPageInfo and assigns it to the Page field. +func (o *ProviderListResponse) SetPage(v ApiPageInfo) { + o.Page = &v +} + +// GetResults returns the Results field value if set, zero value otherwise. +func (o *ProviderListResponse) GetResults() []DiscoveryConfig { + if o == nil || IsNil(o.Results) { + var ret []DiscoveryConfig + return ret + } + return o.Results +} + +// GetResultsOk returns a tuple with the Results field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProviderListResponse) GetResultsOk() ([]DiscoveryConfig, bool) { + if o == nil || IsNil(o.Results) { + return nil, false + } + return o.Results, true +} + +// HasResults returns a boolean if a field has been set. +func (o *ProviderListResponse) HasResults() bool { + if o != nil && !IsNil(o.Results) { + return true + } + + return false +} + +// SetResults gets a reference to the given []DiscoveryConfig and assigns it to the Results field. +func (o *ProviderListResponse) SetResults(v []DiscoveryConfig) { + o.Results = v +} + +func (o ProviderListResponse) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ProviderListResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Page) { + toSerialize["page"] = o.Page + } + if !IsNil(o.Results) { + toSerialize["results"] = o.Results + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ProviderListResponse) UnmarshalJSON(data []byte) (err error) { + varProviderListResponse := _ProviderListResponse{} + + err = json.Unmarshal(data, &varProviderListResponse) + + if err != nil { + return err + } + + *o = ProviderListResponse(varProviderListResponse) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "page") + delete(additionalProperties, "results") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableProviderListResponse struct { + value *ProviderListResponse + isSet bool +} + +func (v NullableProviderListResponse) Get() *ProviderListResponse { + return v.value +} + +func (v *NullableProviderListResponse) Set(val *ProviderListResponse) { + v.value = val + v.isSet = true +} + +func (v NullableProviderListResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableProviderListResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableProviderListResponse(val *ProviderListResponse) *NullableProviderListResponse { + return &NullableProviderListResponse{value: val, isSet: true} +} + +func (v NullableProviderListResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableProviderListResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_provider_read_response.go b/clouddiscovery/model_provider_read_response.go new file mode 100644 index 0000000..ac524c7 --- /dev/null +++ b/clouddiscovery/model_provider_read_response.go @@ -0,0 +1,153 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the ProviderReadResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ProviderReadResponse{} + +// ProviderReadResponse The Provider object read response format. +type ProviderReadResponse struct { + Result *DiscoveryConfig `json:"result,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ProviderReadResponse ProviderReadResponse + +// NewProviderReadResponse instantiates a new ProviderReadResponse 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 NewProviderReadResponse() *ProviderReadResponse { + this := ProviderReadResponse{} + return &this +} + +// NewProviderReadResponseWithDefaults instantiates a new ProviderReadResponse 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 NewProviderReadResponseWithDefaults() *ProviderReadResponse { + this := ProviderReadResponse{} + return &this +} + +// GetResult returns the Result field value if set, zero value otherwise. +func (o *ProviderReadResponse) GetResult() DiscoveryConfig { + if o == nil || IsNil(o.Result) { + var ret DiscoveryConfig + return ret + } + return *o.Result +} + +// GetResultOk returns a tuple with the Result field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProviderReadResponse) GetResultOk() (*DiscoveryConfig, bool) { + if o == nil || IsNil(o.Result) { + return nil, false + } + return o.Result, true +} + +// HasResult returns a boolean if a field has been set. +func (o *ProviderReadResponse) HasResult() bool { + if o != nil && !IsNil(o.Result) { + return true + } + + return false +} + +// SetResult gets a reference to the given DiscoveryConfig and assigns it to the Result field. +func (o *ProviderReadResponse) SetResult(v DiscoveryConfig) { + o.Result = &v +} + +func (o ProviderReadResponse) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ProviderReadResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Result) { + toSerialize["result"] = o.Result + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ProviderReadResponse) UnmarshalJSON(data []byte) (err error) { + varProviderReadResponse := _ProviderReadResponse{} + + err = json.Unmarshal(data, &varProviderReadResponse) + + if err != nil { + return err + } + + *o = ProviderReadResponse(varProviderReadResponse) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "result") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableProviderReadResponse struct { + value *ProviderReadResponse + isSet bool +} + +func (v NullableProviderReadResponse) Get() *ProviderReadResponse { + return v.value +} + +func (v *NullableProviderReadResponse) Set(val *ProviderReadResponse) { + v.value = val + v.isSet = true +} + +func (v NullableProviderReadResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableProviderReadResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableProviderReadResponse(val *ProviderReadResponse) *NullableProviderReadResponse { + return &NullableProviderReadResponse{value: val, isSet: true} +} + +func (v NullableProviderReadResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableProviderReadResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_provider_update_response.go b/clouddiscovery/model_provider_update_response.go new file mode 100644 index 0000000..783f83c --- /dev/null +++ b/clouddiscovery/model_provider_update_response.go @@ -0,0 +1,153 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the ProviderUpdateResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ProviderUpdateResponse{} + +// ProviderUpdateResponse The Provider object to update response format. +type ProviderUpdateResponse struct { + Result *DiscoveryConfig `json:"result,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ProviderUpdateResponse ProviderUpdateResponse + +// NewProviderUpdateResponse instantiates a new ProviderUpdateResponse 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 NewProviderUpdateResponse() *ProviderUpdateResponse { + this := ProviderUpdateResponse{} + return &this +} + +// NewProviderUpdateResponseWithDefaults instantiates a new ProviderUpdateResponse 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 NewProviderUpdateResponseWithDefaults() *ProviderUpdateResponse { + this := ProviderUpdateResponse{} + return &this +} + +// GetResult returns the Result field value if set, zero value otherwise. +func (o *ProviderUpdateResponse) GetResult() DiscoveryConfig { + if o == nil || IsNil(o.Result) { + var ret DiscoveryConfig + return ret + } + return *o.Result +} + +// GetResultOk returns a tuple with the Result field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProviderUpdateResponse) GetResultOk() (*DiscoveryConfig, bool) { + if o == nil || IsNil(o.Result) { + return nil, false + } + return o.Result, true +} + +// HasResult returns a boolean if a field has been set. +func (o *ProviderUpdateResponse) HasResult() bool { + if o != nil && !IsNil(o.Result) { + return true + } + + return false +} + +// SetResult gets a reference to the given DiscoveryConfig and assigns it to the Result field. +func (o *ProviderUpdateResponse) SetResult(v DiscoveryConfig) { + o.Result = &v +} + +func (o ProviderUpdateResponse) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ProviderUpdateResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Result) { + toSerialize["result"] = o.Result + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ProviderUpdateResponse) UnmarshalJSON(data []byte) (err error) { + varProviderUpdateResponse := _ProviderUpdateResponse{} + + err = json.Unmarshal(data, &varProviderUpdateResponse) + + if err != nil { + return err + } + + *o = ProviderUpdateResponse(varProviderUpdateResponse) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "result") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableProviderUpdateResponse struct { + value *ProviderUpdateResponse + isSet bool +} + +func (v NullableProviderUpdateResponse) Get() *ProviderUpdateResponse { + return v.value +} + +func (v *NullableProviderUpdateResponse) Set(val *ProviderUpdateResponse) { + v.value = val + v.isSet = true +} + +func (v NullableProviderUpdateResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableProviderUpdateResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableProviderUpdateResponse(val *ProviderUpdateResponse) *NullableProviderUpdateResponse { + return &NullableProviderUpdateResponse{value: val, isSet: true} +} + +func (v NullableProviderUpdateResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableProviderUpdateResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_resource.go b/clouddiscovery/model_resource.go new file mode 100644 index 0000000..2c2d997 --- /dev/null +++ b/clouddiscovery/model_resource.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the Resource type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Resource{} + +// Resource struct for Resource +type Resource struct { + Excluded *bool `json:"excluded,omitempty"` + Id *string `json:"id,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _Resource Resource + +// NewResource instantiates a new Resource 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 NewResource() *Resource { + this := Resource{} + return &this +} + +// NewResourceWithDefaults instantiates a new Resource 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 NewResourceWithDefaults() *Resource { + this := Resource{} + return &this +} + +// GetExcluded returns the Excluded field value if set, zero value otherwise. +func (o *Resource) GetExcluded() bool { + if o == nil || IsNil(o.Excluded) { + var ret bool + return ret + } + return *o.Excluded +} + +// GetExcludedOk returns a tuple with the Excluded field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Resource) GetExcludedOk() (*bool, bool) { + if o == nil || IsNil(o.Excluded) { + return nil, false + } + return o.Excluded, true +} + +// HasExcluded returns a boolean if a field has been set. +func (o *Resource) HasExcluded() bool { + if o != nil && !IsNil(o.Excluded) { + return true + } + + return false +} + +// SetExcluded gets a reference to the given bool and assigns it to the Excluded field. +func (o *Resource) SetExcluded(v bool) { + o.Excluded = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *Resource) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Resource) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Resource) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *Resource) SetId(v string) { + o.Id = &v +} + +func (o Resource) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Resource) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Excluded) { + toSerialize["excluded"] = o.Excluded + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *Resource) UnmarshalJSON(data []byte) (err error) { + varResource := _Resource{} + + err = json.Unmarshal(data, &varResource) + + if err != nil { + return err + } + + *o = Resource(varResource) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "excluded") + delete(additionalProperties, "id") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableResource struct { + value *Resource + isSet bool +} + +func (v NullableResource) Get() *Resource { + return v.value +} + +func (v *NullableResource) Set(val *Resource) { + v.value = val + v.isSet = true +} + +func (v NullableResource) IsSet() bool { + return v.isSet +} + +func (v *NullableResource) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableResource(val *Resource) *NullableResource { + return &NullableResource{value: val, isSet: true} +} + +func (v NullableResource) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableResource) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_source_config.go b/clouddiscovery/model_source_config.go new file mode 100644 index 0000000..2ef1c24 --- /dev/null +++ b/clouddiscovery/model_source_config.go @@ -0,0 +1,458 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" + "time" +) + +// checks if the SourceConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SourceConfig{} + +// SourceConfig Source configuration +type SourceConfig struct { + // Account Schedule ID. + AccountScheduleId *string `json:"account_schedule_id,omitempty"` + Accounts []Account `json:"accounts,omitempty"` + // Cloud Credential ID. + CloudCredentialId *string `json:"cloud_credential_id,omitempty"` + // Timestamp when the object has been created. + CreatedAt *time.Time `json:"created_at,omitempty"` + // Credential configuration. Ex.: '{ \"access_identifier\": \"arn:aws:iam::1234:role/access_for_discovery\", \"region\": \"us-east-1\", \"enclave\": \"commercial/gov\" }'. + CredentialConfig *CredentialConfig `json:"credential_config,omitempty"` + // Timestamp when the object has been deleted. + DeletedAt *time.Time `json:"deleted_at,omitempty"` + // Auto-generated unique source config ID. Format BloxID. + Id *string `json:"id,omitempty"` + // Provider account IDs such as accountID/ SubscriptionID to be restricted for a given source_config. + RestrictedToAccounts []string `json:"restricted_to_accounts,omitempty"` + // Timestamp when the object has been updated. + UpdatedAt *time.Time `json:"updated_at,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _SourceConfig SourceConfig + +// NewSourceConfig instantiates a new SourceConfig 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 NewSourceConfig() *SourceConfig { + this := SourceConfig{} + return &this +} + +// NewSourceConfigWithDefaults instantiates a new SourceConfig 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 NewSourceConfigWithDefaults() *SourceConfig { + this := SourceConfig{} + return &this +} + +// GetAccountScheduleId returns the AccountScheduleId field value if set, zero value otherwise. +func (o *SourceConfig) GetAccountScheduleId() string { + if o == nil || IsNil(o.AccountScheduleId) { + var ret string + return ret + } + return *o.AccountScheduleId +} + +// GetAccountScheduleIdOk returns a tuple with the AccountScheduleId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetAccountScheduleIdOk() (*string, bool) { + if o == nil || IsNil(o.AccountScheduleId) { + return nil, false + } + return o.AccountScheduleId, true +} + +// HasAccountScheduleId returns a boolean if a field has been set. +func (o *SourceConfig) HasAccountScheduleId() bool { + if o != nil && !IsNil(o.AccountScheduleId) { + return true + } + + return false +} + +// SetAccountScheduleId gets a reference to the given string and assigns it to the AccountScheduleId field. +func (o *SourceConfig) SetAccountScheduleId(v string) { + o.AccountScheduleId = &v +} + +// GetAccounts returns the Accounts field value if set, zero value otherwise. +func (o *SourceConfig) GetAccounts() []Account { + if o == nil || IsNil(o.Accounts) { + var ret []Account + return ret + } + return o.Accounts +} + +// GetAccountsOk returns a tuple with the Accounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetAccountsOk() ([]Account, bool) { + if o == nil || IsNil(o.Accounts) { + return nil, false + } + return o.Accounts, true +} + +// HasAccounts returns a boolean if a field has been set. +func (o *SourceConfig) HasAccounts() bool { + if o != nil && !IsNil(o.Accounts) { + return true + } + + return false +} + +// SetAccounts gets a reference to the given []Account and assigns it to the Accounts field. +func (o *SourceConfig) SetAccounts(v []Account) { + o.Accounts = v +} + +// GetCloudCredentialId returns the CloudCredentialId field value if set, zero value otherwise. +func (o *SourceConfig) GetCloudCredentialId() string { + if o == nil || IsNil(o.CloudCredentialId) { + var ret string + return ret + } + return *o.CloudCredentialId +} + +// GetCloudCredentialIdOk returns a tuple with the CloudCredentialId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetCloudCredentialIdOk() (*string, bool) { + if o == nil || IsNil(o.CloudCredentialId) { + return nil, false + } + return o.CloudCredentialId, true +} + +// HasCloudCredentialId returns a boolean if a field has been set. +func (o *SourceConfig) HasCloudCredentialId() bool { + if o != nil && !IsNil(o.CloudCredentialId) { + return true + } + + return false +} + +// SetCloudCredentialId gets a reference to the given string and assigns it to the CloudCredentialId field. +func (o *SourceConfig) SetCloudCredentialId(v string) { + o.CloudCredentialId = &v +} + +// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise. +func (o *SourceConfig) GetCreatedAt() time.Time { + if o == nil || IsNil(o.CreatedAt) { + var ret time.Time + return ret + } + return *o.CreatedAt +} + +// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetCreatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.CreatedAt) { + return nil, false + } + return o.CreatedAt, true +} + +// HasCreatedAt returns a boolean if a field has been set. +func (o *SourceConfig) HasCreatedAt() bool { + if o != nil && !IsNil(o.CreatedAt) { + return true + } + + return false +} + +// SetCreatedAt gets a reference to the given time.Time and assigns it to the CreatedAt field. +func (o *SourceConfig) SetCreatedAt(v time.Time) { + o.CreatedAt = &v +} + +// GetCredentialConfig returns the CredentialConfig field value if set, zero value otherwise. +func (o *SourceConfig) GetCredentialConfig() CredentialConfig { + if o == nil || IsNil(o.CredentialConfig) { + var ret CredentialConfig + return ret + } + return *o.CredentialConfig +} + +// GetCredentialConfigOk returns a tuple with the CredentialConfig field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetCredentialConfigOk() (*CredentialConfig, bool) { + if o == nil || IsNil(o.CredentialConfig) { + return nil, false + } + return o.CredentialConfig, true +} + +// HasCredentialConfig returns a boolean if a field has been set. +func (o *SourceConfig) HasCredentialConfig() bool { + if o != nil && !IsNil(o.CredentialConfig) { + return true + } + + return false +} + +// SetCredentialConfig gets a reference to the given CredentialConfig and assigns it to the CredentialConfig field. +func (o *SourceConfig) SetCredentialConfig(v CredentialConfig) { + o.CredentialConfig = &v +} + +// GetDeletedAt returns the DeletedAt field value if set, zero value otherwise. +func (o *SourceConfig) GetDeletedAt() time.Time { + if o == nil || IsNil(o.DeletedAt) { + var ret time.Time + return ret + } + return *o.DeletedAt +} + +// GetDeletedAtOk returns a tuple with the DeletedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetDeletedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.DeletedAt) { + return nil, false + } + return o.DeletedAt, true +} + +// HasDeletedAt returns a boolean if a field has been set. +func (o *SourceConfig) HasDeletedAt() bool { + if o != nil && !IsNil(o.DeletedAt) { + return true + } + + return false +} + +// SetDeletedAt gets a reference to the given time.Time and assigns it to the DeletedAt field. +func (o *SourceConfig) SetDeletedAt(v time.Time) { + o.DeletedAt = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *SourceConfig) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *SourceConfig) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *SourceConfig) SetId(v string) { + o.Id = &v +} + +// GetRestrictedToAccounts returns the RestrictedToAccounts field value if set, zero value otherwise. +func (o *SourceConfig) GetRestrictedToAccounts() []string { + if o == nil || IsNil(o.RestrictedToAccounts) { + var ret []string + return ret + } + return o.RestrictedToAccounts +} + +// GetRestrictedToAccountsOk returns a tuple with the RestrictedToAccounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetRestrictedToAccountsOk() ([]string, bool) { + if o == nil || IsNil(o.RestrictedToAccounts) { + return nil, false + } + return o.RestrictedToAccounts, true +} + +// HasRestrictedToAccounts returns a boolean if a field has been set. +func (o *SourceConfig) HasRestrictedToAccounts() bool { + if o != nil && !IsNil(o.RestrictedToAccounts) { + return true + } + + return false +} + +// SetRestrictedToAccounts gets a reference to the given []string and assigns it to the RestrictedToAccounts field. +func (o *SourceConfig) SetRestrictedToAccounts(v []string) { + o.RestrictedToAccounts = v +} + +// GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise. +func (o *SourceConfig) GetUpdatedAt() time.Time { + if o == nil || IsNil(o.UpdatedAt) { + var ret time.Time + return ret + } + return *o.UpdatedAt +} + +// GetUpdatedAtOk returns a tuple with the UpdatedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceConfig) GetUpdatedAtOk() (*time.Time, bool) { + if o == nil || IsNil(o.UpdatedAt) { + return nil, false + } + return o.UpdatedAt, true +} + +// HasUpdatedAt returns a boolean if a field has been set. +func (o *SourceConfig) HasUpdatedAt() bool { + if o != nil && !IsNil(o.UpdatedAt) { + return true + } + + return false +} + +// SetUpdatedAt gets a reference to the given time.Time and assigns it to the UpdatedAt field. +func (o *SourceConfig) SetUpdatedAt(v time.Time) { + o.UpdatedAt = &v +} + +func (o SourceConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SourceConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AccountScheduleId) { + toSerialize["account_schedule_id"] = o.AccountScheduleId + } + if !IsNil(o.Accounts) { + toSerialize["accounts"] = o.Accounts + } + if !IsNil(o.CloudCredentialId) { + toSerialize["cloud_credential_id"] = o.CloudCredentialId + } + if !IsNil(o.CreatedAt) { + toSerialize["created_at"] = o.CreatedAt + } + if !IsNil(o.CredentialConfig) { + toSerialize["credential_config"] = o.CredentialConfig + } + if !IsNil(o.DeletedAt) { + toSerialize["deleted_at"] = o.DeletedAt + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.RestrictedToAccounts) { + toSerialize["restricted_to_accounts"] = o.RestrictedToAccounts + } + if !IsNil(o.UpdatedAt) { + toSerialize["updated_at"] = o.UpdatedAt + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *SourceConfig) UnmarshalJSON(data []byte) (err error) { + varSourceConfig := _SourceConfig{} + + err = json.Unmarshal(data, &varSourceConfig) + + if err != nil { + return err + } + + *o = SourceConfig(varSourceConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "account_schedule_id") + delete(additionalProperties, "accounts") + delete(additionalProperties, "cloud_credential_id") + delete(additionalProperties, "created_at") + delete(additionalProperties, "credential_config") + delete(additionalProperties, "deleted_at") + delete(additionalProperties, "id") + delete(additionalProperties, "restricted_to_accounts") + delete(additionalProperties, "updated_at") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableSourceConfig struct { + value *SourceConfig + isSet bool +} + +func (v NullableSourceConfig) Get() *SourceConfig { + return v.value +} + +func (v *NullableSourceConfig) Set(val *SourceConfig) { + v.value = val + v.isSet = true +} + +func (v NullableSourceConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableSourceConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSourceConfig(val *SourceConfig) *NullableSourceConfig { + return &NullableSourceConfig{value: val, isSet: true} +} + +func (v NullableSourceConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSourceConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_sub_account_list_request_v2.go b/clouddiscovery/model_sub_account_list_request_v2.go new file mode 100644 index 0000000..69b489c --- /dev/null +++ b/clouddiscovery/model_sub_account_list_request_v2.go @@ -0,0 +1,302 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the SubAccountListRequestV2 type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SubAccountListRequestV2{} + +// SubAccountListRequestV2 struct for SubAccountListRequestV2 +type SubAccountListRequestV2 struct { + AccessType *string `json:"access_type,omitempty"` + CredentialId *string `json:"credential_id,omitempty"` + // atlas.api.field_selection + Fields *string `json:"fields,omitempty"` + ProviderCredentialsConfig *SubAccountProvCredConfig `json:"provider_credentials_config,omitempty"` + ProviderType *string `json:"provider_type,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _SubAccountListRequestV2 SubAccountListRequestV2 + +// NewSubAccountListRequestV2 instantiates a new SubAccountListRequestV2 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 NewSubAccountListRequestV2() *SubAccountListRequestV2 { + this := SubAccountListRequestV2{} + return &this +} + +// NewSubAccountListRequestV2WithDefaults instantiates a new SubAccountListRequestV2 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 NewSubAccountListRequestV2WithDefaults() *SubAccountListRequestV2 { + this := SubAccountListRequestV2{} + return &this +} + +// GetAccessType returns the AccessType field value if set, zero value otherwise. +func (o *SubAccountListRequestV2) GetAccessType() string { + if o == nil || IsNil(o.AccessType) { + var ret string + return ret + } + return *o.AccessType +} + +// GetAccessTypeOk returns a tuple with the AccessType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListRequestV2) GetAccessTypeOk() (*string, bool) { + if o == nil || IsNil(o.AccessType) { + return nil, false + } + return o.AccessType, true +} + +// HasAccessType returns a boolean if a field has been set. +func (o *SubAccountListRequestV2) HasAccessType() bool { + if o != nil && !IsNil(o.AccessType) { + return true + } + + return false +} + +// SetAccessType gets a reference to the given string and assigns it to the AccessType field. +func (o *SubAccountListRequestV2) SetAccessType(v string) { + o.AccessType = &v +} + +// GetCredentialId returns the CredentialId field value if set, zero value otherwise. +func (o *SubAccountListRequestV2) GetCredentialId() string { + if o == nil || IsNil(o.CredentialId) { + var ret string + return ret + } + return *o.CredentialId +} + +// GetCredentialIdOk returns a tuple with the CredentialId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListRequestV2) GetCredentialIdOk() (*string, bool) { + if o == nil || IsNil(o.CredentialId) { + return nil, false + } + return o.CredentialId, true +} + +// HasCredentialId returns a boolean if a field has been set. +func (o *SubAccountListRequestV2) HasCredentialId() bool { + if o != nil && !IsNil(o.CredentialId) { + return true + } + + return false +} + +// SetCredentialId gets a reference to the given string and assigns it to the CredentialId field. +func (o *SubAccountListRequestV2) SetCredentialId(v string) { + o.CredentialId = &v +} + +// GetFields returns the Fields field value if set, zero value otherwise. +func (o *SubAccountListRequestV2) GetFields() string { + if o == nil || IsNil(o.Fields) { + var ret string + return ret + } + return *o.Fields +} + +// GetFieldsOk returns a tuple with the Fields field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListRequestV2) GetFieldsOk() (*string, bool) { + if o == nil || IsNil(o.Fields) { + return nil, false + } + return o.Fields, true +} + +// HasFields returns a boolean if a field has been set. +func (o *SubAccountListRequestV2) HasFields() bool { + if o != nil && !IsNil(o.Fields) { + return true + } + + return false +} + +// SetFields gets a reference to the given string and assigns it to the Fields field. +func (o *SubAccountListRequestV2) SetFields(v string) { + o.Fields = &v +} + +// GetProviderCredentialsConfig returns the ProviderCredentialsConfig field value if set, zero value otherwise. +func (o *SubAccountListRequestV2) GetProviderCredentialsConfig() SubAccountProvCredConfig { + if o == nil || IsNil(o.ProviderCredentialsConfig) { + var ret SubAccountProvCredConfig + return ret + } + return *o.ProviderCredentialsConfig +} + +// GetProviderCredentialsConfigOk returns a tuple with the ProviderCredentialsConfig field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListRequestV2) GetProviderCredentialsConfigOk() (*SubAccountProvCredConfig, bool) { + if o == nil || IsNil(o.ProviderCredentialsConfig) { + return nil, false + } + return o.ProviderCredentialsConfig, true +} + +// HasProviderCredentialsConfig returns a boolean if a field has been set. +func (o *SubAccountListRequestV2) HasProviderCredentialsConfig() bool { + if o != nil && !IsNil(o.ProviderCredentialsConfig) { + return true + } + + return false +} + +// SetProviderCredentialsConfig gets a reference to the given SubAccountProvCredConfig and assigns it to the ProviderCredentialsConfig field. +func (o *SubAccountListRequestV2) SetProviderCredentialsConfig(v SubAccountProvCredConfig) { + o.ProviderCredentialsConfig = &v +} + +// GetProviderType returns the ProviderType field value if set, zero value otherwise. +func (o *SubAccountListRequestV2) GetProviderType() string { + if o == nil || IsNil(o.ProviderType) { + var ret string + return ret + } + return *o.ProviderType +} + +// GetProviderTypeOk returns a tuple with the ProviderType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListRequestV2) GetProviderTypeOk() (*string, bool) { + if o == nil || IsNil(o.ProviderType) { + return nil, false + } + return o.ProviderType, true +} + +// HasProviderType returns a boolean if a field has been set. +func (o *SubAccountListRequestV2) HasProviderType() bool { + if o != nil && !IsNil(o.ProviderType) { + return true + } + + return false +} + +// SetProviderType gets a reference to the given string and assigns it to the ProviderType field. +func (o *SubAccountListRequestV2) SetProviderType(v string) { + o.ProviderType = &v +} + +func (o SubAccountListRequestV2) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SubAccountListRequestV2) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AccessType) { + toSerialize["access_type"] = o.AccessType + } + if !IsNil(o.CredentialId) { + toSerialize["credential_id"] = o.CredentialId + } + if !IsNil(o.Fields) { + toSerialize["fields"] = o.Fields + } + if !IsNil(o.ProviderCredentialsConfig) { + toSerialize["provider_credentials_config"] = o.ProviderCredentialsConfig + } + if !IsNil(o.ProviderType) { + toSerialize["provider_type"] = o.ProviderType + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *SubAccountListRequestV2) UnmarshalJSON(data []byte) (err error) { + varSubAccountListRequestV2 := _SubAccountListRequestV2{} + + err = json.Unmarshal(data, &varSubAccountListRequestV2) + + if err != nil { + return err + } + + *o = SubAccountListRequestV2(varSubAccountListRequestV2) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "access_type") + delete(additionalProperties, "credential_id") + delete(additionalProperties, "fields") + delete(additionalProperties, "provider_credentials_config") + delete(additionalProperties, "provider_type") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableSubAccountListRequestV2 struct { + value *SubAccountListRequestV2 + isSet bool +} + +func (v NullableSubAccountListRequestV2) Get() *SubAccountListRequestV2 { + return v.value +} + +func (v *NullableSubAccountListRequestV2) Set(val *SubAccountListRequestV2) { + v.value = val + v.isSet = true +} + +func (v NullableSubAccountListRequestV2) IsSet() bool { + return v.isSet +} + +func (v *NullableSubAccountListRequestV2) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubAccountListRequestV2(val *SubAccountListRequestV2) *NullableSubAccountListRequestV2 { + return &NullableSubAccountListRequestV2{value: val, isSet: true} +} + +func (v NullableSubAccountListRequestV2) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubAccountListRequestV2) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_sub_account_list_response_v2.go b/clouddiscovery/model_sub_account_list_response_v2.go new file mode 100644 index 0000000..0602c7b --- /dev/null +++ b/clouddiscovery/model_sub_account_list_response_v2.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the SubAccountListResponseV2 type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SubAccountListResponseV2{} + +// SubAccountListResponseV2 struct for SubAccountListResponseV2 +type SubAccountListResponseV2 struct { + Page *ApiPageInfo `json:"page,omitempty"` + Results []SubAccountV2 `json:"results,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _SubAccountListResponseV2 SubAccountListResponseV2 + +// NewSubAccountListResponseV2 instantiates a new SubAccountListResponseV2 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 NewSubAccountListResponseV2() *SubAccountListResponseV2 { + this := SubAccountListResponseV2{} + return &this +} + +// NewSubAccountListResponseV2WithDefaults instantiates a new SubAccountListResponseV2 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 NewSubAccountListResponseV2WithDefaults() *SubAccountListResponseV2 { + this := SubAccountListResponseV2{} + return &this +} + +// GetPage returns the Page field value if set, zero value otherwise. +func (o *SubAccountListResponseV2) GetPage() ApiPageInfo { + if o == nil || IsNil(o.Page) { + var ret ApiPageInfo + return ret + } + return *o.Page +} + +// GetPageOk returns a tuple with the Page field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListResponseV2) GetPageOk() (*ApiPageInfo, bool) { + if o == nil || IsNil(o.Page) { + return nil, false + } + return o.Page, true +} + +// HasPage returns a boolean if a field has been set. +func (o *SubAccountListResponseV2) HasPage() bool { + if o != nil && !IsNil(o.Page) { + return true + } + + return false +} + +// SetPage gets a reference to the given ApiPageInfo and assigns it to the Page field. +func (o *SubAccountListResponseV2) SetPage(v ApiPageInfo) { + o.Page = &v +} + +// GetResults returns the Results field value if set, zero value otherwise. +func (o *SubAccountListResponseV2) GetResults() []SubAccountV2 { + if o == nil || IsNil(o.Results) { + var ret []SubAccountV2 + return ret + } + return o.Results +} + +// GetResultsOk returns a tuple with the Results field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountListResponseV2) GetResultsOk() ([]SubAccountV2, bool) { + if o == nil || IsNil(o.Results) { + return nil, false + } + return o.Results, true +} + +// HasResults returns a boolean if a field has been set. +func (o *SubAccountListResponseV2) HasResults() bool { + if o != nil && !IsNil(o.Results) { + return true + } + + return false +} + +// SetResults gets a reference to the given []SubAccountV2 and assigns it to the Results field. +func (o *SubAccountListResponseV2) SetResults(v []SubAccountV2) { + o.Results = v +} + +func (o SubAccountListResponseV2) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SubAccountListResponseV2) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Page) { + toSerialize["page"] = o.Page + } + if !IsNil(o.Results) { + toSerialize["results"] = o.Results + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *SubAccountListResponseV2) UnmarshalJSON(data []byte) (err error) { + varSubAccountListResponseV2 := _SubAccountListResponseV2{} + + err = json.Unmarshal(data, &varSubAccountListResponseV2) + + if err != nil { + return err + } + + *o = SubAccountListResponseV2(varSubAccountListResponseV2) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "page") + delete(additionalProperties, "results") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableSubAccountListResponseV2 struct { + value *SubAccountListResponseV2 + isSet bool +} + +func (v NullableSubAccountListResponseV2) Get() *SubAccountListResponseV2 { + return v.value +} + +func (v *NullableSubAccountListResponseV2) Set(val *SubAccountListResponseV2) { + v.value = val + v.isSet = true +} + +func (v NullableSubAccountListResponseV2) IsSet() bool { + return v.isSet +} + +func (v *NullableSubAccountListResponseV2) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubAccountListResponseV2(val *SubAccountListResponseV2) *NullableSubAccountListResponseV2 { + return &NullableSubAccountListResponseV2{value: val, isSet: true} +} + +func (v NullableSubAccountListResponseV2) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubAccountListResponseV2) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_sub_account_prov_cred_config.go b/clouddiscovery/model_sub_account_prov_cred_config.go new file mode 100644 index 0000000..cc3037e --- /dev/null +++ b/clouddiscovery/model_sub_account_prov_cred_config.go @@ -0,0 +1,227 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the SubAccountProvCredConfig type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SubAccountProvCredConfig{} + +// SubAccountProvCredConfig struct for SubAccountProvCredConfig +type SubAccountProvCredConfig struct { + ProjectId *string `json:"project_id,omitempty"` + RoleArn *string `json:"role_arn,omitempty"` + TenantId *string `json:"tenant_id,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _SubAccountProvCredConfig SubAccountProvCredConfig + +// NewSubAccountProvCredConfig instantiates a new SubAccountProvCredConfig 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 NewSubAccountProvCredConfig() *SubAccountProvCredConfig { + this := SubAccountProvCredConfig{} + return &this +} + +// NewSubAccountProvCredConfigWithDefaults instantiates a new SubAccountProvCredConfig 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 NewSubAccountProvCredConfigWithDefaults() *SubAccountProvCredConfig { + this := SubAccountProvCredConfig{} + return &this +} + +// GetProjectId returns the ProjectId field value if set, zero value otherwise. +func (o *SubAccountProvCredConfig) GetProjectId() string { + if o == nil || IsNil(o.ProjectId) { + var ret string + return ret + } + return *o.ProjectId +} + +// GetProjectIdOk returns a tuple with the ProjectId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountProvCredConfig) GetProjectIdOk() (*string, bool) { + if o == nil || IsNil(o.ProjectId) { + return nil, false + } + return o.ProjectId, true +} + +// HasProjectId returns a boolean if a field has been set. +func (o *SubAccountProvCredConfig) HasProjectId() bool { + if o != nil && !IsNil(o.ProjectId) { + return true + } + + return false +} + +// SetProjectId gets a reference to the given string and assigns it to the ProjectId field. +func (o *SubAccountProvCredConfig) SetProjectId(v string) { + o.ProjectId = &v +} + +// GetRoleArn returns the RoleArn field value if set, zero value otherwise. +func (o *SubAccountProvCredConfig) GetRoleArn() string { + if o == nil || IsNil(o.RoleArn) { + var ret string + return ret + } + return *o.RoleArn +} + +// GetRoleArnOk returns a tuple with the RoleArn field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountProvCredConfig) GetRoleArnOk() (*string, bool) { + if o == nil || IsNil(o.RoleArn) { + return nil, false + } + return o.RoleArn, true +} + +// HasRoleArn returns a boolean if a field has been set. +func (o *SubAccountProvCredConfig) HasRoleArn() bool { + if o != nil && !IsNil(o.RoleArn) { + return true + } + + return false +} + +// SetRoleArn gets a reference to the given string and assigns it to the RoleArn field. +func (o *SubAccountProvCredConfig) SetRoleArn(v string) { + o.RoleArn = &v +} + +// GetTenantId returns the TenantId field value if set, zero value otherwise. +func (o *SubAccountProvCredConfig) GetTenantId() string { + if o == nil || IsNil(o.TenantId) { + var ret string + return ret + } + return *o.TenantId +} + +// GetTenantIdOk returns a tuple with the TenantId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountProvCredConfig) GetTenantIdOk() (*string, bool) { + if o == nil || IsNil(o.TenantId) { + return nil, false + } + return o.TenantId, true +} + +// HasTenantId returns a boolean if a field has been set. +func (o *SubAccountProvCredConfig) HasTenantId() bool { + if o != nil && !IsNil(o.TenantId) { + return true + } + + return false +} + +// SetTenantId gets a reference to the given string and assigns it to the TenantId field. +func (o *SubAccountProvCredConfig) SetTenantId(v string) { + o.TenantId = &v +} + +func (o SubAccountProvCredConfig) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SubAccountProvCredConfig) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ProjectId) { + toSerialize["project_id"] = o.ProjectId + } + if !IsNil(o.RoleArn) { + toSerialize["role_arn"] = o.RoleArn + } + if !IsNil(o.TenantId) { + toSerialize["tenant_id"] = o.TenantId + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *SubAccountProvCredConfig) UnmarshalJSON(data []byte) (err error) { + varSubAccountProvCredConfig := _SubAccountProvCredConfig{} + + err = json.Unmarshal(data, &varSubAccountProvCredConfig) + + if err != nil { + return err + } + + *o = SubAccountProvCredConfig(varSubAccountProvCredConfig) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "project_id") + delete(additionalProperties, "role_arn") + delete(additionalProperties, "tenant_id") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableSubAccountProvCredConfig struct { + value *SubAccountProvCredConfig + isSet bool +} + +func (v NullableSubAccountProvCredConfig) Get() *SubAccountProvCredConfig { + return v.value +} + +func (v *NullableSubAccountProvCredConfig) Set(val *SubAccountProvCredConfig) { + v.value = val + v.isSet = true +} + +func (v NullableSubAccountProvCredConfig) IsSet() bool { + return v.isSet +} + +func (v *NullableSubAccountProvCredConfig) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubAccountProvCredConfig(val *SubAccountProvCredConfig) *NullableSubAccountProvCredConfig { + return &NullableSubAccountProvCredConfig{value: val, isSet: true} +} + +func (v NullableSubAccountProvCredConfig) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubAccountProvCredConfig) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/model_sub_account_v2.go b/clouddiscovery/model_sub_account_v2.go new file mode 100644 index 0000000..a282b14 --- /dev/null +++ b/clouddiscovery/model_sub_account_v2.go @@ -0,0 +1,190 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" +) + +// checks if the SubAccountV2 type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SubAccountV2{} + +// SubAccountV2 struct for SubAccountV2 +type SubAccountV2 struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _SubAccountV2 SubAccountV2 + +// NewSubAccountV2 instantiates a new SubAccountV2 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 NewSubAccountV2() *SubAccountV2 { + this := SubAccountV2{} + return &this +} + +// NewSubAccountV2WithDefaults instantiates a new SubAccountV2 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 NewSubAccountV2WithDefaults() *SubAccountV2 { + this := SubAccountV2{} + return &this +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *SubAccountV2) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountV2) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *SubAccountV2) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *SubAccountV2) SetId(v string) { + o.Id = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *SubAccountV2) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SubAccountV2) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *SubAccountV2) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *SubAccountV2) SetName(v string) { + o.Name = &v +} + +func (o SubAccountV2) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SubAccountV2) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *SubAccountV2) UnmarshalJSON(data []byte) (err error) { + varSubAccountV2 := _SubAccountV2{} + + err = json.Unmarshal(data, &varSubAccountV2) + + if err != nil { + return err + } + + *o = SubAccountV2(varSubAccountV2) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "id") + delete(additionalProperties, "name") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableSubAccountV2 struct { + value *SubAccountV2 + isSet bool +} + +func (v NullableSubAccountV2) Get() *SubAccountV2 { + return v.value +} + +func (v *NullableSubAccountV2) Set(val *SubAccountV2) { + v.value = val + v.isSet = true +} + +func (v NullableSubAccountV2) IsSet() bool { + return v.isSet +} + +func (v *NullableSubAccountV2) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubAccountV2(val *SubAccountV2) *NullableSubAccountV2 { + return &NullableSubAccountV2{value: val, isSet: true} +} + +func (v NullableSubAccountV2) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubAccountV2) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/clouddiscovery/test/api_accounts_test.go b/clouddiscovery/test/api_accounts_test.go new file mode 100644 index 0000000..32e39a4 --- /dev/null +++ b/clouddiscovery/test/api_accounts_test.go @@ -0,0 +1,37 @@ +/* +Discovery Configuration API V2 + +Testing AccountsAPIService + +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); + +package clouddiscovery + +import ( + "context" + "github.com/infobloxopen/bloxone-go-client/client" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" +) + +func TestAccountsAPIService(t *testing.T) { + + apiClient := client.NewAPIClient() + + t.Run("Test AccountsAPIService List", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.AccountsAPI.List(context.Background()).Execute() + + require.Nil(t, err) + require.NotNil(t, resp) + assert.Equal(t, 200, httpRes.StatusCode) + + }) + +} diff --git a/clouddiscovery/test/api_providers_test.go b/clouddiscovery/test/api_providers_test.go new file mode 100644 index 0000000..ae06683 --- /dev/null +++ b/clouddiscovery/test/api_providers_test.go @@ -0,0 +1,286 @@ +/* +Discovery Configuration API V2 + +Testing ProvidersAPIService + +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); + +package clouddiscovery + +import ( + "context" + "fmt" + "github.com/infobloxopen/bloxone-go-client/client" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func TestProvidersAPIService(t *testing.T) { + + apiClient := client.NewAPIClient() + + var awsId, azureId, gcpId *string + + t.Run("Test ProvidersAPIService Create AWS Provider", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + awsresp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Create(context.Background()). + Body(clouddiscovery.DiscoveryConfig{ + AccountPreference: clouddiscovery.PtrString("single"), + CredentialPreference: &clouddiscovery.CredentialPreference{ + AccessIdentifierType: clouddiscovery.PtrString("role_arn"), + CredentialType: clouddiscovery.PtrString("dynamic"), + }, + Description: clouddiscovery.PtrString("AWS Discovery"), + Name: "TestSyncAWS1", + ProviderType: clouddiscovery.PtrString("Amazon Web Services"), + SourceConfigs: []clouddiscovery.SourceConfig{ + { + CredentialConfig: &clouddiscovery.CredentialConfig{ + AccessIdentifier: clouddiscovery.PtrString("arn:aws:iam::111111111111:role/infoblox_discovery"), + }, + AdditionalProperties: nil, + }, + }, + SyncInterval: clouddiscovery.PtrString("Auto"), + Tags: nil, + }). + Execute() + + require.Nil(t, err) + require.NotNil(t, awsresp) + assert.Equal(t, 201, httpRes.StatusCode) + awsId = awsresp.GetResult().Id + + }) + + t.Run("Test ProvidersAPIService Create Azure Provider", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + azureresp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Create(context.Background()). + Body(clouddiscovery.DiscoveryConfig{ + AccountPreference: clouddiscovery.PtrString("single"), + CredentialPreference: &clouddiscovery.CredentialPreference{ + AccessIdentifierType: clouddiscovery.PtrString("tenant_id"), + CredentialType: clouddiscovery.PtrString("dynamic"), + AdditionalProperties: nil, + }, + Description: clouddiscovery.PtrString("Azure Discovery"), + Name: "TestSyncAzure", + ProviderType: clouddiscovery.PtrString("Microsoft Azure"), + SourceConfigs: []clouddiscovery.SourceConfig{ + { + CredentialConfig: &clouddiscovery.CredentialConfig{ + AccessIdentifier: clouddiscovery.PtrString("1111112111"), + }, + RestrictedToAccounts: []string{"3333333333"}, + AdditionalProperties: nil, + }, + }, + SyncInterval: clouddiscovery.PtrString("Auto"), + Tags: nil, + }). + Execute() + + if err != nil { + t.Errorf("Error while reading AWS provider: %v", err) + } + require.Nil(t, err) + require.NotNil(t, azureresp) + assert.Equal(t, 201, httpRes.StatusCode) + azureId = azureresp.GetResult().Id + //azureSfc = azureresp.GetResult().SourceConfigs[0].Id + + }) + + t.Run("Test ProvidersAPIService Create GCP Provider", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + gcpresp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Create(context.Background()). + Body(clouddiscovery.DiscoveryConfig{ + AccountPreference: clouddiscovery.PtrString("single"), + CredentialPreference: &clouddiscovery.CredentialPreference{ + AccessIdentifierType: clouddiscovery.PtrString("project_id"), + CredentialType: clouddiscovery.PtrString("dynamic"), + AdditionalProperties: nil, + }, + Description: clouddiscovery.PtrString("GCP Discovery"), + Name: "TestSyncGCP", + ProviderType: clouddiscovery.PtrString("Google Cloud Platform"), + SourceConfigs: []clouddiscovery.SourceConfig{ + { + CredentialConfig: &clouddiscovery.CredentialConfig{ + AccessIdentifier: clouddiscovery.PtrString("33333333333"), + }, + }, + }, + SyncInterval: clouddiscovery.PtrString("Auto"), + Tags: nil, + }). + Execute() + + if err != nil { + t.Errorf("Error while reading AWS provider: %v", err) + } + require.Nil(t, err) + require.NotNil(t, gcpresp) + assert.Equal(t, 201, httpRes.StatusCode) + gcpId = gcpresp.GetResult().Id + + }) + + t.Run("Test ProvidersAPIService List", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.List(context.Background()).Execute() + + if err != nil { + t.Errorf("Error while reading AWS provider: %v", err) + } + fmt.Println(resp) + require.NoError(t, err) + assert.Equal(t, 200, httpRes.StatusCode) + + }) + + t.Run("Test ProvidersAPIService Read", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Read(context.Background(), *gcpId).Execute() + + // print resp + fmt.Println(resp) + require.NoError(t, err) + assert.Equal(t, 200, httpRes.StatusCode) + }) + + t.Run("Test ProvidersAPIService Update", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Update(context.Background(), *awsId). + Body(clouddiscovery.DiscoveryConfig{ + AccountPreference: clouddiscovery.PtrString("single"), + CredentialPreference: &clouddiscovery.CredentialPreference{ + AccessIdentifierType: clouddiscovery.PtrString("role_arn"), + CredentialType: clouddiscovery.PtrString("dynamic"), + AdditionalProperties: nil, + }, + Description: clouddiscovery.PtrString("AWS Discovery"), + Name: "TestSyncAWS", + ProviderType: clouddiscovery.PtrString("Amazon Web Services"), + SourceConfigs: []clouddiscovery.SourceConfig{ + { + //Id: az, + CredentialConfig: &clouddiscovery.CredentialConfig{ + AccessIdentifier: clouddiscovery.PtrString("arn:aws:iam::111111111111:role/infoblox_discovery"), + }, + AdditionalProperties: nil, + }, + }, + SyncInterval: clouddiscovery.PtrString("Auto"), + Tags: nil, + }). + Execute() + + if err != nil { + t.Errorf("Error while updating AWS provider: %v", err) + } + require.Nil(t, err) + require.NotNil(t, resp) + assert.Equal(t, 200, httpRes.StatusCode) + + }) + + t.Run("Test ProvidersAPIService Azure Update", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Update(context.Background(), *azureId). + Body(clouddiscovery.DiscoveryConfig{ + AccountPreference: clouddiscovery.PtrString("single"), + Description: clouddiscovery.PtrString("Azure Discovery meow"), + Name: "TestSyncAzure", + ProviderType: clouddiscovery.PtrString("Microsoft Azure"), + SyncInterval: clouddiscovery.PtrString("Auto"), + Tags: nil, + }). + Execute() + + if err != nil { + t.Errorf("Error while updating AWS provider: %v", err) + } + require.Nil(t, err) + require.NotNil(t, resp) + assert.Equal(t, 200, httpRes.StatusCode) + + }) + + t.Run("Test ProvidersAPIService Update GCP Provider", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + gcpresp, httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Update(context.Background(), *gcpId). + Body(clouddiscovery.DiscoveryConfig{ + AccountPreference: clouddiscovery.PtrString("single"), + Description: clouddiscovery.PtrString("GCP Discovery update"), + Name: "TestSyncGCP", + ProviderType: clouddiscovery.PtrString("Google Cloud Platform"), + }). + Execute() + + if err != nil { + t.Errorf("Error while reading AWS provider: %v", err) + } + require.Nil(t, err) + require.NotNil(t, gcpresp) + assert.Equal(t, 200, httpRes.StatusCode) + //gcpId = gcpresp.GetResult().Id + + }) + + t.Run("Test ProvidersAPIService AWS Delete", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Delete(context.Background(), *awsId).Execute() + + require.Nil(t, err) + assert.Equal(t, 204, httpRes.StatusCode) + + }) + + t.Run("Test ProvidersAPIService Azure Delete", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Delete(context.Background(), *azureId).Execute() + + require.Nil(t, err) + assert.Equal(t, 204, httpRes.StatusCode) + + }) + + t.Run("Test ProvidersAPIService GCP Delete", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + httpRes, err := apiClient.DiscoveryConfigurationAPIV2.ProvidersAPI.Delete(context.Background(), *gcpId).Execute() + + require.Nil(t, err) + assert.Equal(t, 204, httpRes.StatusCode) + + }) + +} diff --git a/clouddiscovery/test/api_sub_accounts_test.go b/clouddiscovery/test/api_sub_accounts_test.go new file mode 100644 index 0000000..0effe9a --- /dev/null +++ b/clouddiscovery/test/api_sub_accounts_test.go @@ -0,0 +1,38 @@ +/* +Discovery Configuration API V2 + +Testing SubAccountsAPIService + +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); + +package clouddiscovery + +import ( + "context" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/infobloxopen/bloxone-go-client/clouddiscovery" +) + +func TestSubAccountsAPIService(t *testing.T) { + + apiClient := clouddiscovery.NewAPIClient() + + t.Run("Test SubAccountsAPIService List", func(t *testing.T) { + + t.Skip("skip test") // remove to run test + + resp, httpRes, err := apiClient.SubAccountsAPI.List(context.Background()).Execute() + + require.Nil(t, err) + require.NotNil(t, resp) + assert.Equal(t, 200, httpRes.StatusCode) + + }) + +} diff --git a/clouddiscovery/utils.go b/clouddiscovery/utils.go new file mode 100644 index 0000000..9939f29 --- /dev/null +++ b/clouddiscovery/utils.go @@ -0,0 +1,347 @@ +/* +Discovery Configuration API V2 + +The Discovery configuration service is a BloxOne Service that provides configuration for accessing and syncing the Cloud assets Base Paths: 1. provider: **_/api/cloud_discovery/v2/_** + +API version: v2 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package clouddiscovery + +import ( + "encoding/json" + "reflect" + "time" +) + +// PtrBool is a helper routine that returns a pointer to given boolean value. +func PtrBool(v bool) *bool { return &v } + +// PtrInt is a helper routine that returns a pointer to given integer value. +func PtrInt(v int) *int { return &v } + +// PtrInt32 is a helper routine that returns a pointer to given integer value. +func PtrInt32(v int32) *int32 { return &v } + +// PtrInt64 is a helper routine that returns a pointer to given integer value. +func PtrInt64(v int64) *int64 { return &v } + +// PtrFloat32 is a helper routine that returns a pointer to given float value. +func PtrFloat32(v float32) *float32 { return &v } + +// PtrFloat64 is a helper routine that returns a pointer to given float value. +func PtrFloat64(v float64) *float64 { return &v } + +// PtrString is a helper routine that returns a pointer to given string value. +func PtrString(v string) *string { return &v } + +// PtrTime is helper routine that returns a pointer to given Time value. +func PtrTime(v time.Time) *time.Time { return &v } + +type NullableBool struct { + value *bool + isSet bool +} + +func (v NullableBool) Get() *bool { + return v.value +} + +func (v *NullableBool) Set(val *bool) { + v.value = val + v.isSet = true +} + +func (v NullableBool) IsSet() bool { + return v.isSet +} + +func (v *NullableBool) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBool(val *bool) *NullableBool { + return &NullableBool{value: val, isSet: true} +} + +func (v NullableBool) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBool) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableInt struct { + value *int + isSet bool +} + +func (v NullableInt) Get() *int { + return v.value +} + +func (v *NullableInt) Set(val *int) { + v.value = val + v.isSet = true +} + +func (v NullableInt) IsSet() bool { + return v.isSet +} + +func (v *NullableInt) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt(val *int) *NullableInt { + return &NullableInt{value: val, isSet: true} +} + +func (v NullableInt) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableInt32 struct { + value *int32 + isSet bool +} + +func (v NullableInt32) Get() *int32 { + return v.value +} + +func (v *NullableInt32) Set(val *int32) { + v.value = val + v.isSet = true +} + +func (v NullableInt32) IsSet() bool { + return v.isSet +} + +func (v *NullableInt32) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt32(val *int32) *NullableInt32 { + return &NullableInt32{value: val, isSet: true} +} + +func (v NullableInt32) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt32) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableInt64 struct { + value *int64 + isSet bool +} + +func (v NullableInt64) Get() *int64 { + return v.value +} + +func (v *NullableInt64) Set(val *int64) { + v.value = val + v.isSet = true +} + +func (v NullableInt64) IsSet() bool { + return v.isSet +} + +func (v *NullableInt64) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt64(val *int64) *NullableInt64 { + return &NullableInt64{value: val, isSet: true} +} + +func (v NullableInt64) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt64) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableFloat32 struct { + value *float32 + isSet bool +} + +func (v NullableFloat32) Get() *float32 { + return v.value +} + +func (v *NullableFloat32) Set(val *float32) { + v.value = val + v.isSet = true +} + +func (v NullableFloat32) IsSet() bool { + return v.isSet +} + +func (v *NullableFloat32) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFloat32(val *float32) *NullableFloat32 { + return &NullableFloat32{value: val, isSet: true} +} + +func (v NullableFloat32) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFloat32) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableFloat64 struct { + value *float64 + isSet bool +} + +func (v NullableFloat64) Get() *float64 { + return v.value +} + +func (v *NullableFloat64) Set(val *float64) { + v.value = val + v.isSet = true +} + +func (v NullableFloat64) IsSet() bool { + return v.isSet +} + +func (v *NullableFloat64) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFloat64(val *float64) *NullableFloat64 { + return &NullableFloat64{value: val, isSet: true} +} + +func (v NullableFloat64) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFloat64) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableString struct { + value *string + isSet bool +} + +func (v NullableString) Get() *string { + return v.value +} + +func (v *NullableString) Set(val *string) { + v.value = val + v.isSet = true +} + +func (v NullableString) IsSet() bool { + return v.isSet +} + +func (v *NullableString) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableString(val *string) *NullableString { + return &NullableString{value: val, isSet: true} +} + +func (v NullableString) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableString) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableTime struct { + value *time.Time + isSet bool +} + +func (v NullableTime) Get() *time.Time { + return v.value +} + +func (v *NullableTime) Set(val *time.Time) { + v.value = val + v.isSet = true +} + +func (v NullableTime) IsSet() bool { + return v.isSet +} + +func (v *NullableTime) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTime(val *time.Time) *NullableTime { + return &NullableTime{value: val, isSet: true} +} + +func (v NullableTime) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTime) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +// IsNil checks if an input is nil +func IsNil(i interface{}) bool { + if i == nil { + return true + } + switch reflect.TypeOf(i).Kind() { + case reflect.Chan, reflect.Func, reflect.Map, reflect.Ptr, reflect.UnsafePointer, reflect.Interface, reflect.Slice: + return reflect.ValueOf(i).IsNil() + case reflect.Array: + return reflect.ValueOf(i).IsZero() + } + return false +} + +type MappedNullable interface { + ToMap() (map[string]interface{}, error) +}