spartera_api_sdk 0.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/CHANGELOG.md +9 -0
- data/Gemfile +9 -0
- data/LICENSE +21 -0
- data/README.md +372 -0
- data/Rakefile +10 -0
- data/docs/APIKeysApi.md +537 -0
- data/docs/Alerts.md +30 -0
- data/docs/AlertsApi.md +525 -0
- data/docs/AlertsInput.md +24 -0
- data/docs/AlertsUpdate.md +24 -0
- data/docs/ApiKeys.md +40 -0
- data/docs/ApiKeysInput.md +34 -0
- data/docs/ApiKeysUpdate.md +34 -0
- data/docs/AssetPriceHistory.md +30 -0
- data/docs/AssetPriceHistoryApi.md +597 -0
- data/docs/AssetPriceHistoryInput.md +24 -0
- data/docs/AssetPriceHistoryUpdate.md +24 -0
- data/docs/AssetUsecases.md +28 -0
- data/docs/AssetUsecasesApi.md +157 -0
- data/docs/Assets.md +142 -0
- data/docs/AssetsApi.md +1197 -0
- data/docs/AssetsInput.md +128 -0
- data/docs/AssetsUpdate.md +128 -0
- data/docs/CloudProviders.md +28 -0
- data/docs/CloudProvidersApi.md +157 -0
- data/docs/CloudProvidersInput.md +22 -0
- data/docs/CloudProvidersUpdate.md +22 -0
- data/docs/Companies.md +46 -0
- data/docs/CompaniesApi.md +805 -0
- data/docs/CompaniesInput.md +40 -0
- data/docs/CompaniesUpdate.md +40 -0
- data/docs/Connections.md +38 -0
- data/docs/ConnectionsApi.md +607 -0
- data/docs/ConnectionsInput.md +32 -0
- data/docs/ConnectionsUpdate.md +32 -0
- data/docs/CreateAlerts200Response.md +20 -0
- data/docs/CreateAlerts200ResponseData.md +18 -0
- data/docs/CreateApiKeys200Response.md +20 -0
- data/docs/CreateApiKeys200ResponseData.md +18 -0
- data/docs/CreateAssetPriceHistory200Response.md +20 -0
- data/docs/CreateAssetPriceHistory200ResponseData.md +18 -0
- data/docs/CreateAssetsAnalyze200Response.md +20 -0
- data/docs/CreateAssetsAnalyze200ResponseData.md +18 -0
- data/docs/CreateConnections200Response.md +20 -0
- data/docs/CreateConnections200ResponseData.md +18 -0
- data/docs/CreateEndpoints200Response.md +20 -0
- data/docs/CreateEndpoints200ResponseData.md +18 -0
- data/docs/CreateFavorites200Response.md +20 -0
- data/docs/CreateFavorites200ResponseData.md +18 -0
- data/docs/CreatePostgenIntegrations200Response.md +20 -0
- data/docs/CreatePostgenIntegrations200ResponseData.md +18 -0
- data/docs/CreatePosts200Response.md +20 -0
- data/docs/CreatePosts200ResponseData.md +18 -0
- data/docs/CreateUsers200Response.md +20 -0
- data/docs/CreateUsers200ResponseData.md +18 -0
- data/docs/DeleteAlerts200Response.md +20 -0
- data/docs/DeleteAlerts200ResponseData.md +18 -0
- data/docs/DeleteApiKeys200Response.md +20 -0
- data/docs/DeleteApiKeys200ResponseData.md +18 -0
- data/docs/DeleteAssetPriceHistory200Response.md +20 -0
- data/docs/DeleteAssetPriceHistory200ResponseData.md +18 -0
- data/docs/DeleteAssets200Response.md +20 -0
- data/docs/DeleteAssets200ResponseData.md +18 -0
- data/docs/DeleteConnections200Response.md +20 -0
- data/docs/DeleteConnections200ResponseData.md +18 -0
- data/docs/DeleteEndpoints200Response.md +20 -0
- data/docs/DeleteEndpoints200ResponseData.md +18 -0
- data/docs/DeleteFavorites200Response.md +20 -0
- data/docs/DeleteFavorites200ResponseData.md +18 -0
- data/docs/DeletePostgenIntegrations200Response.md +20 -0
- data/docs/DeletePostgenIntegrations200ResponseData.md +18 -0
- data/docs/DeletePosts200Response.md +20 -0
- data/docs/DeletePosts200ResponseData.md +18 -0
- data/docs/DeleteUsers200Response.md +20 -0
- data/docs/DeleteUsers200ResponseData.md +18 -0
- data/docs/Endpoints.md +96 -0
- data/docs/EndpointsApi.md +1189 -0
- data/docs/EndpointsInput.md +94 -0
- data/docs/EndpointsUpdate.md +94 -0
- data/docs/Error.md +24 -0
- data/docs/Favorites.md +34 -0
- data/docs/FavoritesApi.md +597 -0
- data/docs/FavoritesInput.md +28 -0
- data/docs/FavoritesUpdate.md +28 -0
- data/docs/GetAlertsById200Response.md +20 -0
- data/docs/GetApiKeysById200Response.md +20 -0
- data/docs/GetAssetPriceHistoryById200Response.md +20 -0
- data/docs/GetAssetUsecasesById200Response.md +20 -0
- data/docs/GetAssetsByIdAnalyze200Response.md +20 -0
- data/docs/GetCloudProvidersById200Response.md +20 -0
- data/docs/GetCompaniesById200Response.md +20 -0
- data/docs/GetConnectionsById200Response.md +20 -0
- data/docs/GetEndpointsByIdConnectionsDescribe200Response.md +20 -0
- data/docs/GetFavoritesById200Response.md +20 -0
- data/docs/GetIndustriesById200Response.md +20 -0
- data/docs/GetJobFunctionsById200Response.md +20 -0
- data/docs/GetPostgenIntegrationsById200Response.md +20 -0
- data/docs/GetPostsById200Response.md +20 -0
- data/docs/GetStorageEnginesById200Response.md +20 -0
- data/docs/GetUsersById200Response.md +20 -0
- data/docs/Industries.md +32 -0
- data/docs/IndustriesApi.md +237 -0
- data/docs/InlineObject.md +22 -0
- data/docs/InlineObject1.md +20 -0
- data/docs/InlineObject2.md +20 -0
- data/docs/InlineObject3.md +20 -0
- data/docs/InlineObject4.md +20 -0
- data/docs/InlineObject5.md +20 -0
- data/docs/InlineObject6.md +22 -0
- data/docs/InlineObject7.md +20 -0
- data/docs/JobFunctions.md +24 -0
- data/docs/JobFunctionsApi.md +157 -0
- data/docs/JobFunctionsInput.md +18 -0
- data/docs/JobFunctionsUpdate.md +18 -0
- data/docs/ListApiKeys200Response.md +20 -0
- data/docs/ListAssetUsecases200Response.md +20 -0
- data/docs/ListAssets200Response.md +20 -0
- data/docs/ListCloudProviders200Response.md +20 -0
- data/docs/ListCompaniesAnalyticsAssets200Response.md +20 -0
- data/docs/ListConnections200Response.md +20 -0
- data/docs/ListEndpoints200Response.md +20 -0
- data/docs/ListIndustries200Response.md +20 -0
- data/docs/ListJobFunctions200Response.md +20 -0
- data/docs/ListPostgenIntegrations200Response.md +20 -0
- data/docs/ListPosts200Response.md +20 -0
- data/docs/ListStorageEngines200Response.md +20 -0
- data/docs/ListUsers200Response.md +20 -0
- data/docs/PostPublications.md +40 -0
- data/docs/PostPublicationsInput.md +34 -0
- data/docs/PostPublicationsUpdate.md +34 -0
- data/docs/PostgenIntegrations.md +36 -0
- data/docs/PostgenIntegrationsApi.md +463 -0
- data/docs/PostgenIntegrationsInput.md +30 -0
- data/docs/PostgenIntegrationsUpdate.md +30 -0
- data/docs/Posts.md +68 -0
- data/docs/PostsApi.md +843 -0
- data/docs/PostsInput.md +62 -0
- data/docs/PostsUpdate.md +62 -0
- data/docs/StorageEngines.md +32 -0
- data/docs/StorageEnginesApi.md +161 -0
- data/docs/UpdateAlerts200Response.md +20 -0
- data/docs/UpdateAlerts200ResponseData.md +18 -0
- data/docs/UpdateApiKeys200Response.md +20 -0
- data/docs/UpdateApiKeys200ResponseData.md +18 -0
- data/docs/UpdateAssetPriceHistory200Response.md +20 -0
- data/docs/UpdateAssetPriceHistory200ResponseData.md +18 -0
- data/docs/UpdateAssets200Response.md +20 -0
- data/docs/UpdateAssets200ResponseData.md +18 -0
- data/docs/UpdateCompanies200Response.md +20 -0
- data/docs/UpdateCompanies200ResponseData.md +18 -0
- data/docs/UpdateConnections200Response.md +20 -0
- data/docs/UpdateConnections200ResponseData.md +18 -0
- data/docs/UpdateEndpoints200Response.md +20 -0
- data/docs/UpdateEndpoints200ResponseData.md +18 -0
- data/docs/UpdateFavorites200Response.md +20 -0
- data/docs/UpdateFavorites200ResponseData.md +18 -0
- data/docs/UpdatePostgenIntegrations200Response.md +20 -0
- data/docs/UpdatePostgenIntegrations200ResponseData.md +18 -0
- data/docs/UpdatePosts200Response.md +20 -0
- data/docs/UpdatePosts200ResponseData.md +18 -0
- data/docs/UpdateUsers200Response.md +20 -0
- data/docs/UpdateUsers200ResponseData.md +18 -0
- data/docs/Users.md +36 -0
- data/docs/UsersApi.md +639 -0
- data/docs/UsersInput.md +30 -0
- data/docs/UsersUpdate.md +30 -0
- data/git_push.sh +57 -0
- data/lib/spartera_api_sdk/api/alerts_api.rb +790 -0
- data/lib/spartera_api_sdk/api/api_keys_api.rb +746 -0
- data/lib/spartera_api_sdk/api/asset_price_history_api.rb +867 -0
- data/lib/spartera_api_sdk/api/asset_usecases_api.rb +190 -0
- data/lib/spartera_api_sdk/api/assets_api.rb +1554 -0
- data/lib/spartera_api_sdk/api/cloud_providers_api.rb +190 -0
- data/lib/spartera_api_sdk/api/companies_api.rb +1085 -0
- data/lib/spartera_api_sdk/api/connections_api.rb +828 -0
- data/lib/spartera_api_sdk/api/endpoints_api.rb +1613 -0
- data/lib/spartera_api_sdk/api/favorites_api.rb +870 -0
- data/lib/spartera_api_sdk/api/industries_api.rb +284 -0
- data/lib/spartera_api_sdk/api/job_functions_api.rb +190 -0
- data/lib/spartera_api_sdk/api/postgen_integrations_api.rb +634 -0
- data/lib/spartera_api_sdk/api/posts_api.rb +1190 -0
- data/lib/spartera_api_sdk/api/storage_engines_api.rb +228 -0
- data/lib/spartera_api_sdk/api/users_api.rb +891 -0
- data/lib/spartera_api_sdk/api_client.rb +397 -0
- data/lib/spartera_api_sdk/api_error.rb +58 -0
- data/lib/spartera_api_sdk/api_model_base.rb +88 -0
- data/lib/spartera_api_sdk/configuration.rb +312 -0
- data/lib/spartera_api_sdk/models/alerts.rb +260 -0
- data/lib/spartera_api_sdk/models/alerts_input.rb +213 -0
- data/lib/spartera_api_sdk/models/alerts_update.rb +179 -0
- data/lib/spartera_api_sdk/models/api_keys.rb +344 -0
- data/lib/spartera_api_sdk/models/api_keys_input.rb +263 -0
- data/lib/spartera_api_sdk/models/api_keys_update.rb +229 -0
- data/lib/spartera_api_sdk/models/asset_price_history.rb +209 -0
- data/lib/spartera_api_sdk/models/asset_price_history_input.rb +179 -0
- data/lib/spartera_api_sdk/models/asset_price_history_update.rb +179 -0
- data/lib/spartera_api_sdk/models/asset_usecases.rb +216 -0
- data/lib/spartera_api_sdk/models/assets.rb +1068 -0
- data/lib/spartera_api_sdk/models/assets_input.rb +918 -0
- data/lib/spartera_api_sdk/models/assets_update.rb +877 -0
- data/lib/spartera_api_sdk/models/cloud_providers.rb +216 -0
- data/lib/spartera_api_sdk/models/cloud_providers_input.rb +186 -0
- data/lib/spartera_api_sdk/models/cloud_providers_update.rb +169 -0
- data/lib/spartera_api_sdk/models/companies.rb +374 -0
- data/lib/spartera_api_sdk/models/companies_input.rb +327 -0
- data/lib/spartera_api_sdk/models/companies_update.rb +293 -0
- data/lib/spartera_api_sdk/models/connections.rb +317 -0
- data/lib/spartera_api_sdk/models/connections_input.rb +287 -0
- data/lib/spartera_api_sdk/models/connections_update.rb +253 -0
- data/lib/spartera_api_sdk/models/create_alerts200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_alerts200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_api_keys200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_api_keys200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_asset_price_history200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_asset_price_history200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_assets_analyze200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_assets_analyze200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_connections200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_connections200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_endpoints200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_endpoints200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_favorites200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_favorites200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_postgen_integrations200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_postgen_integrations200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_posts200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_posts200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/create_users200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/create_users200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_alerts200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_alerts200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_api_keys200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_api_keys200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_asset_price_history200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_asset_price_history200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_assets200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_assets200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_connections200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_connections200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_endpoints200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_endpoints200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_favorites200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_favorites200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_postgen_integrations200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_postgen_integrations200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_posts200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_posts200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/delete_users200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/delete_users200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/endpoints.rb +788 -0
- data/lib/spartera_api_sdk/models/endpoints_input.rb +686 -0
- data/lib/spartera_api_sdk/models/endpoints_update.rb +635 -0
- data/lib/spartera_api_sdk/models/error.rb +212 -0
- data/lib/spartera_api_sdk/models/favorites.rb +280 -0
- data/lib/spartera_api_sdk/models/favorites_input.rb +233 -0
- data/lib/spartera_api_sdk/models/favorites_update.rb +199 -0
- data/lib/spartera_api_sdk/models/get_alerts_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_api_keys_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_asset_price_history_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_asset_usecases_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_assets_by_id_analyze200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_cloud_providers_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_companies_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_connections_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_endpoints_by_id_connections_describe200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_favorites_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_industries_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_job_functions_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_postgen_integrations_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_posts_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_storage_engines_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/get_users_by_id200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/industries.rb +253 -0
- data/lib/spartera_api_sdk/models/inline_object.rb +167 -0
- data/lib/spartera_api_sdk/models/inline_object1.rb +156 -0
- data/lib/spartera_api_sdk/models/inline_object2.rb +156 -0
- data/lib/spartera_api_sdk/models/inline_object3.rb +156 -0
- data/lib/spartera_api_sdk/models/inline_object4.rb +156 -0
- data/lib/spartera_api_sdk/models/inline_object5.rb +156 -0
- data/lib/spartera_api_sdk/models/inline_object6.rb +166 -0
- data/lib/spartera_api_sdk/models/inline_object7.rb +156 -0
- data/lib/spartera_api_sdk/models/job_functions.rb +213 -0
- data/lib/spartera_api_sdk/models/job_functions_input.rb +166 -0
- data/lib/spartera_api_sdk/models/job_functions_update.rb +149 -0
- data/lib/spartera_api_sdk/models/list_api_keys200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_asset_usecases200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_assets200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_cloud_providers200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_companies_analytics_assets200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_connections200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_endpoints200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_industries200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_job_functions200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_postgen_integrations200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_posts200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_storage_engines200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/list_users200_response.rb +193 -0
- data/lib/spartera_api_sdk/models/post_publications.rb +327 -0
- data/lib/spartera_api_sdk/models/post_publications_input.rb +280 -0
- data/lib/spartera_api_sdk/models/post_publications_update.rb +229 -0
- data/lib/spartera_api_sdk/models/postgen_integrations.rb +341 -0
- data/lib/spartera_api_sdk/models/postgen_integrations_input.rb +294 -0
- data/lib/spartera_api_sdk/models/postgen_integrations_update.rb +209 -0
- data/lib/spartera_api_sdk/models/posts.rb +586 -0
- data/lib/spartera_api_sdk/models/posts_input.rb +437 -0
- data/lib/spartera_api_sdk/models/posts_update.rb +369 -0
- data/lib/spartera_api_sdk/models/storage_engines.rb +294 -0
- data/lib/spartera_api_sdk/models/update_alerts200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_alerts200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_api_keys200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_api_keys200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_asset_price_history200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_asset_price_history200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_assets200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_assets200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_companies200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_companies200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_connections200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_connections200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_endpoints200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_endpoints200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_favorites200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_favorites200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_postgen_integrations200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_postgen_integrations200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_posts200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_posts200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/update_users200_response.rb +191 -0
- data/lib/spartera_api_sdk/models/update_users200_response_data.rb +165 -0
- data/lib/spartera_api_sdk/models/users.rb +331 -0
- data/lib/spartera_api_sdk/models/users_input.rb +260 -0
- data/lib/spartera_api_sdk/models/users_update.rb +243 -0
- data/lib/spartera_api_sdk/version.rb +15 -0
- data/lib/spartera_api_sdk.rb +201 -0
- data/spartera_api_sdk.gemspec +39 -0
- data/spec/api/alerts_api_spec.rb +126 -0
- data/spec/api/api_keys_api_spec.rb +130 -0
- data/spec/api/asset_price_history_api_spec.rb +138 -0
- data/spec/api/asset_usecases_api_spec.rb +61 -0
- data/spec/api/assets_api_spec.rb +243 -0
- data/spec/api/cloud_providers_api_spec.rb +61 -0
- data/spec/api/companies_api_spec.rb +186 -0
- data/spec/api/connections_api_spec.rb +141 -0
- data/spec/api/endpoints_api_spec.rb +240 -0
- data/spec/api/favorites_api_spec.rb +138 -0
- data/spec/api/industries_api_spec.rb +76 -0
- data/spec/api/job_functions_api_spec.rb +61 -0
- data/spec/api/postgen_integrations_api_spec.rb +117 -0
- data/spec/api/posts_api_spec.rb +186 -0
- data/spec/api/storage_engines_api_spec.rb +63 -0
- data/spec/api/users_api_spec.rb +154 -0
- data/spec/models/alerts_input_spec.rb +54 -0
- data/spec/models/alerts_spec.rb +72 -0
- data/spec/models/alerts_update_spec.rb +54 -0
- data/spec/models/api_keys_input_spec.rb +84 -0
- data/spec/models/api_keys_spec.rb +102 -0
- data/spec/models/api_keys_update_spec.rb +84 -0
- data/spec/models/asset_price_history_input_spec.rb +54 -0
- data/spec/models/asset_price_history_spec.rb +72 -0
- data/spec/models/asset_price_history_update_spec.rb +54 -0
- data/spec/models/asset_usecases_spec.rb +66 -0
- data/spec/models/assets_input_spec.rb +418 -0
- data/spec/models/assets_spec.rb +464 -0
- data/spec/models/assets_update_spec.rb +418 -0
- data/spec/models/cloud_providers_input_spec.rb +48 -0
- data/spec/models/cloud_providers_spec.rb +66 -0
- data/spec/models/cloud_providers_update_spec.rb +48 -0
- data/spec/models/companies_input_spec.rb +106 -0
- data/spec/models/companies_spec.rb +124 -0
- data/spec/models/companies_update_spec.rb +106 -0
- data/spec/models/connections_input_spec.rb +82 -0
- data/spec/models/connections_spec.rb +100 -0
- data/spec/models/connections_update_spec.rb +82 -0
- data/spec/models/create_alerts200_response_data_spec.rb +36 -0
- data/spec/models/create_alerts200_response_spec.rb +42 -0
- data/spec/models/create_api_keys200_response_data_spec.rb +36 -0
- data/spec/models/create_api_keys200_response_spec.rb +42 -0
- data/spec/models/create_asset_price_history200_response_data_spec.rb +36 -0
- data/spec/models/create_asset_price_history200_response_spec.rb +42 -0
- data/spec/models/create_assets_analyze200_response_data_spec.rb +36 -0
- data/spec/models/create_assets_analyze200_response_spec.rb +42 -0
- data/spec/models/create_connections200_response_data_spec.rb +36 -0
- data/spec/models/create_connections200_response_spec.rb +42 -0
- data/spec/models/create_endpoints200_response_data_spec.rb +36 -0
- data/spec/models/create_endpoints200_response_spec.rb +42 -0
- data/spec/models/create_favorites200_response_data_spec.rb +36 -0
- data/spec/models/create_favorites200_response_spec.rb +42 -0
- data/spec/models/create_postgen_integrations200_response_data_spec.rb +36 -0
- data/spec/models/create_postgen_integrations200_response_spec.rb +42 -0
- data/spec/models/create_posts200_response_data_spec.rb +36 -0
- data/spec/models/create_posts200_response_spec.rb +42 -0
- data/spec/models/create_users200_response_data_spec.rb +36 -0
- data/spec/models/create_users200_response_spec.rb +42 -0
- data/spec/models/delete_alerts200_response_data_spec.rb +36 -0
- data/spec/models/delete_alerts200_response_spec.rb +42 -0
- data/spec/models/delete_api_keys200_response_data_spec.rb +36 -0
- data/spec/models/delete_api_keys200_response_spec.rb +42 -0
- data/spec/models/delete_asset_price_history200_response_data_spec.rb +36 -0
- data/spec/models/delete_asset_price_history200_response_spec.rb +42 -0
- data/spec/models/delete_assets200_response_data_spec.rb +36 -0
- data/spec/models/delete_assets200_response_spec.rb +42 -0
- data/spec/models/delete_connections200_response_data_spec.rb +36 -0
- data/spec/models/delete_connections200_response_spec.rb +42 -0
- data/spec/models/delete_endpoints200_response_data_spec.rb +36 -0
- data/spec/models/delete_endpoints200_response_spec.rb +42 -0
- data/spec/models/delete_favorites200_response_data_spec.rb +36 -0
- data/spec/models/delete_favorites200_response_spec.rb +42 -0
- data/spec/models/delete_postgen_integrations200_response_data_spec.rb +36 -0
- data/spec/models/delete_postgen_integrations200_response_spec.rb +42 -0
- data/spec/models/delete_posts200_response_data_spec.rb +36 -0
- data/spec/models/delete_posts200_response_spec.rb +42 -0
- data/spec/models/delete_users200_response_data_spec.rb +36 -0
- data/spec/models/delete_users200_response_spec.rb +42 -0
- data/spec/models/endpoints_input_spec.rb +292 -0
- data/spec/models/endpoints_spec.rb +298 -0
- data/spec/models/endpoints_update_spec.rb +292 -0
- data/spec/models/error_spec.rb +54 -0
- data/spec/models/favorites_input_spec.rb +66 -0
- data/spec/models/favorites_spec.rb +84 -0
- data/spec/models/favorites_update_spec.rb +66 -0
- data/spec/models/get_alerts_by_id200_response_spec.rb +42 -0
- data/spec/models/get_api_keys_by_id200_response_spec.rb +42 -0
- data/spec/models/get_asset_price_history_by_id200_response_spec.rb +42 -0
- data/spec/models/get_asset_usecases_by_id200_response_spec.rb +42 -0
- data/spec/models/get_assets_by_id_analyze200_response_spec.rb +42 -0
- data/spec/models/get_cloud_providers_by_id200_response_spec.rb +42 -0
- data/spec/models/get_companies_by_id200_response_spec.rb +42 -0
- data/spec/models/get_connections_by_id200_response_spec.rb +42 -0
- data/spec/models/get_endpoints_by_id_connections_describe200_response_spec.rb +42 -0
- data/spec/models/get_favorites_by_id200_response_spec.rb +42 -0
- data/spec/models/get_industries_by_id200_response_spec.rb +42 -0
- data/spec/models/get_job_functions_by_id200_response_spec.rb +42 -0
- data/spec/models/get_postgen_integrations_by_id200_response_spec.rb +42 -0
- data/spec/models/get_posts_by_id200_response_spec.rb +42 -0
- data/spec/models/get_storage_engines_by_id200_response_spec.rb +42 -0
- data/spec/models/get_users_by_id200_response_spec.rb +42 -0
- data/spec/models/industries_spec.rb +78 -0
- data/spec/models/inline_object1_spec.rb +42 -0
- data/spec/models/inline_object2_spec.rb +42 -0
- data/spec/models/inline_object3_spec.rb +42 -0
- data/spec/models/inline_object4_spec.rb +42 -0
- data/spec/models/inline_object5_spec.rb +42 -0
- data/spec/models/inline_object6_spec.rb +48 -0
- data/spec/models/inline_object7_spec.rb +42 -0
- data/spec/models/inline_object_spec.rb +48 -0
- data/spec/models/job_functions_input_spec.rb +36 -0
- data/spec/models/job_functions_spec.rb +54 -0
- data/spec/models/job_functions_update_spec.rb +36 -0
- data/spec/models/list_api_keys200_response_spec.rb +42 -0
- data/spec/models/list_asset_usecases200_response_spec.rb +42 -0
- data/spec/models/list_assets200_response_spec.rb +42 -0
- data/spec/models/list_cloud_providers200_response_spec.rb +42 -0
- data/spec/models/list_companies_analytics_assets200_response_spec.rb +42 -0
- data/spec/models/list_connections200_response_spec.rb +42 -0
- data/spec/models/list_endpoints200_response_spec.rb +42 -0
- data/spec/models/list_industries200_response_spec.rb +42 -0
- data/spec/models/list_job_functions200_response_spec.rb +42 -0
- data/spec/models/list_postgen_integrations200_response_spec.rb +42 -0
- data/spec/models/list_posts200_response_spec.rb +42 -0
- data/spec/models/list_storage_engines200_response_spec.rb +42 -0
- data/spec/models/list_users200_response_spec.rb +42 -0
- data/spec/models/post_publications_input_spec.rb +84 -0
- data/spec/models/post_publications_spec.rb +102 -0
- data/spec/models/post_publications_update_spec.rb +84 -0
- data/spec/models/postgen_integrations_input_spec.rb +72 -0
- data/spec/models/postgen_integrations_spec.rb +90 -0
- data/spec/models/postgen_integrations_update_spec.rb +72 -0
- data/spec/models/posts_input_spec.rb +168 -0
- data/spec/models/posts_spec.rb +186 -0
- data/spec/models/posts_update_spec.rb +168 -0
- data/spec/models/storage_engines_spec.rb +82 -0
- data/spec/models/update_alerts200_response_data_spec.rb +36 -0
- data/spec/models/update_alerts200_response_spec.rb +42 -0
- data/spec/models/update_api_keys200_response_data_spec.rb +36 -0
- data/spec/models/update_api_keys200_response_spec.rb +42 -0
- data/spec/models/update_asset_price_history200_response_data_spec.rb +36 -0
- data/spec/models/update_asset_price_history200_response_spec.rb +42 -0
- data/spec/models/update_assets200_response_data_spec.rb +36 -0
- data/spec/models/update_assets200_response_spec.rb +42 -0
- data/spec/models/update_companies200_response_data_spec.rb +36 -0
- data/spec/models/update_companies200_response_spec.rb +42 -0
- data/spec/models/update_connections200_response_data_spec.rb +36 -0
- data/spec/models/update_connections200_response_spec.rb +42 -0
- data/spec/models/update_endpoints200_response_data_spec.rb +36 -0
- data/spec/models/update_endpoints200_response_spec.rb +42 -0
- data/spec/models/update_favorites200_response_data_spec.rb +36 -0
- data/spec/models/update_favorites200_response_spec.rb +42 -0
- data/spec/models/update_postgen_integrations200_response_data_spec.rb +36 -0
- data/spec/models/update_postgen_integrations200_response_spec.rb +42 -0
- data/spec/models/update_posts200_response_data_spec.rb +36 -0
- data/spec/models/update_posts200_response_spec.rb +42 -0
- data/spec/models/update_users200_response_data_spec.rb +36 -0
- data/spec/models/update_users200_response_spec.rb +42 -0
- data/spec/models/users_input_spec.rb +76 -0
- data/spec/models/users_spec.rb +94 -0
- data/spec/models/users_update_spec.rb +76 -0
- data/spec/spec_helper.rb +111 -0
- metadata +742 -0
|
@@ -0,0 +1,828 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Spartera API Documentation
|
|
3
|
+
|
|
4
|
+
#Auto-generated API documentation for REST services of the Spartera platform
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.25.0
|
|
7
|
+
Contact: support@spartera.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.21.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module SparteraApiSdk
|
|
16
|
+
class ConnectionsApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Create a new connection by ID
|
|
23
|
+
# @param company_id [String] Unique identifier for the Company
|
|
24
|
+
# @param connections_input [ConnectionsInput]
|
|
25
|
+
# @param [Hash] opts the optional parameters
|
|
26
|
+
# @option opts [Integer] :page Page number for pagination (default to 1)
|
|
27
|
+
# @option opts [Integer] :limit Number of items per page (default to 20)
|
|
28
|
+
# @option opts [String] :sort_by Field to sort by
|
|
29
|
+
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
30
|
+
# @option opts [String] :search Search term to filter results
|
|
31
|
+
# @return [CreateConnections200Response]
|
|
32
|
+
def create_connections(company_id, connections_input, opts = {})
|
|
33
|
+
data, _status_code, _headers = create_connections_with_http_info(company_id, connections_input, opts)
|
|
34
|
+
data
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Create a new connection by ID
|
|
38
|
+
# @param company_id [String] Unique identifier for the Company
|
|
39
|
+
# @param connections_input [ConnectionsInput]
|
|
40
|
+
# @param [Hash] opts the optional parameters
|
|
41
|
+
# @option opts [Integer] :page Page number for pagination (default to 1)
|
|
42
|
+
# @option opts [Integer] :limit Number of items per page (default to 20)
|
|
43
|
+
# @option opts [String] :sort_by Field to sort by
|
|
44
|
+
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
45
|
+
# @option opts [String] :search Search term to filter results
|
|
46
|
+
# @return [Array<(CreateConnections200Response, Integer, Hash)>] CreateConnections200Response data, response status code and response headers
|
|
47
|
+
def create_connections_with_http_info(company_id, connections_input, opts = {})
|
|
48
|
+
if @api_client.config.debugging
|
|
49
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.create_connections ...'
|
|
50
|
+
end
|
|
51
|
+
# verify the required parameter 'company_id' is set
|
|
52
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
53
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.create_connections"
|
|
54
|
+
end
|
|
55
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
56
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.create_connections, the character length must be smaller than or equal to 255.'
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
60
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.create_connections, the character length must be greater than or equal to 1.'
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
64
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
65
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.create_connections, must conform to the pattern #{pattern}."
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
# verify the required parameter 'connections_input' is set
|
|
69
|
+
if @api_client.config.client_side_validation && connections_input.nil?
|
|
70
|
+
fail ArgumentError, "Missing the required parameter 'connections_input' when calling ConnectionsApi.create_connections"
|
|
71
|
+
end
|
|
72
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
73
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling ConnectionsApi.create_connections, must be greater than or equal to 1.'
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
77
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ConnectionsApi.create_connections, must be smaller than or equal to 100.'
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
81
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ConnectionsApi.create_connections, must be greater than or equal to 1.'
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
allowable_values = ["asc", "desc"]
|
|
85
|
+
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
86
|
+
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
87
|
+
end
|
|
88
|
+
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
89
|
+
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling ConnectionsApi.create_connections, the character length must be smaller than or equal to 255.'
|
|
90
|
+
end
|
|
91
|
+
|
|
92
|
+
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
93
|
+
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling ConnectionsApi.create_connections, the character length must be greater than or equal to 1.'
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
# resource path
|
|
97
|
+
local_var_path = '/companies/{company_id}/connections'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
98
|
+
|
|
99
|
+
# query parameters
|
|
100
|
+
query_params = opts[:query_params] || {}
|
|
101
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
102
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
103
|
+
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
104
|
+
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
105
|
+
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
106
|
+
|
|
107
|
+
# header parameters
|
|
108
|
+
header_params = opts[:header_params] || {}
|
|
109
|
+
# HTTP header 'Accept' (if needed)
|
|
110
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
111
|
+
# HTTP header 'Content-Type'
|
|
112
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
113
|
+
if !content_type.nil?
|
|
114
|
+
header_params['Content-Type'] = content_type
|
|
115
|
+
end
|
|
116
|
+
|
|
117
|
+
# form parameters
|
|
118
|
+
form_params = opts[:form_params] || {}
|
|
119
|
+
|
|
120
|
+
# http body (model)
|
|
121
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(connections_input)
|
|
122
|
+
|
|
123
|
+
# return_type
|
|
124
|
+
return_type = opts[:debug_return_type] || 'CreateConnections200Response'
|
|
125
|
+
|
|
126
|
+
# auth_names
|
|
127
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
128
|
+
|
|
129
|
+
new_options = opts.merge(
|
|
130
|
+
:operation => :"ConnectionsApi.create_connections",
|
|
131
|
+
:header_params => header_params,
|
|
132
|
+
:query_params => query_params,
|
|
133
|
+
:form_params => form_params,
|
|
134
|
+
:body => post_body,
|
|
135
|
+
:auth_names => auth_names,
|
|
136
|
+
:return_type => return_type
|
|
137
|
+
)
|
|
138
|
+
|
|
139
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
140
|
+
if @api_client.config.debugging
|
|
141
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#create_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
142
|
+
end
|
|
143
|
+
return data, status_code, headers
|
|
144
|
+
end
|
|
145
|
+
|
|
146
|
+
# Delete single connection by ID
|
|
147
|
+
# @param company_id [String] Unique identifier for the Company
|
|
148
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
149
|
+
# @param [Hash] opts the optional parameters
|
|
150
|
+
# @return [DeleteConnections200Response]
|
|
151
|
+
def delete_connections(company_id, connection_id, opts = {})
|
|
152
|
+
data, _status_code, _headers = delete_connections_with_http_info(company_id, connection_id, opts)
|
|
153
|
+
data
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
# Delete single connection by ID
|
|
157
|
+
# @param company_id [String] Unique identifier for the Company
|
|
158
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
159
|
+
# @param [Hash] opts the optional parameters
|
|
160
|
+
# @return [Array<(DeleteConnections200Response, Integer, Hash)>] DeleteConnections200Response data, response status code and response headers
|
|
161
|
+
def delete_connections_with_http_info(company_id, connection_id, opts = {})
|
|
162
|
+
if @api_client.config.debugging
|
|
163
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.delete_connections ...'
|
|
164
|
+
end
|
|
165
|
+
# verify the required parameter 'company_id' is set
|
|
166
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
167
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.delete_connections"
|
|
168
|
+
end
|
|
169
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
170
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.delete_connections, the character length must be smaller than or equal to 255.'
|
|
171
|
+
end
|
|
172
|
+
|
|
173
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
174
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.delete_connections, the character length must be greater than or equal to 1.'
|
|
175
|
+
end
|
|
176
|
+
|
|
177
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
178
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
179
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.delete_connections, must conform to the pattern #{pattern}."
|
|
180
|
+
end
|
|
181
|
+
|
|
182
|
+
# verify the required parameter 'connection_id' is set
|
|
183
|
+
if @api_client.config.client_side_validation && connection_id.nil?
|
|
184
|
+
fail ArgumentError, "Missing the required parameter 'connection_id' when calling ConnectionsApi.delete_connections"
|
|
185
|
+
end
|
|
186
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length > 255
|
|
187
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.delete_connections, the character length must be smaller than or equal to 255.'
|
|
188
|
+
end
|
|
189
|
+
|
|
190
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length < 1
|
|
191
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.delete_connections, the character length must be greater than or equal to 1.'
|
|
192
|
+
end
|
|
193
|
+
|
|
194
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
195
|
+
if @api_client.config.client_side_validation && connection_id !~ pattern
|
|
196
|
+
fail ArgumentError, "invalid value for 'connection_id' when calling ConnectionsApi.delete_connections, must conform to the pattern #{pattern}."
|
|
197
|
+
end
|
|
198
|
+
|
|
199
|
+
# resource path
|
|
200
|
+
local_var_path = '/companies/{company_id}/connections/{connection_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s)).sub('{' + 'connection_id' + '}', CGI.escape(connection_id.to_s))
|
|
201
|
+
|
|
202
|
+
# query parameters
|
|
203
|
+
query_params = opts[:query_params] || {}
|
|
204
|
+
|
|
205
|
+
# header parameters
|
|
206
|
+
header_params = opts[:header_params] || {}
|
|
207
|
+
# HTTP header 'Accept' (if needed)
|
|
208
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
209
|
+
|
|
210
|
+
# form parameters
|
|
211
|
+
form_params = opts[:form_params] || {}
|
|
212
|
+
|
|
213
|
+
# http body (model)
|
|
214
|
+
post_body = opts[:debug_body]
|
|
215
|
+
|
|
216
|
+
# return_type
|
|
217
|
+
return_type = opts[:debug_return_type] || 'DeleteConnections200Response'
|
|
218
|
+
|
|
219
|
+
# auth_names
|
|
220
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
221
|
+
|
|
222
|
+
new_options = opts.merge(
|
|
223
|
+
:operation => :"ConnectionsApi.delete_connections",
|
|
224
|
+
:header_params => header_params,
|
|
225
|
+
:query_params => query_params,
|
|
226
|
+
:form_params => form_params,
|
|
227
|
+
:body => post_body,
|
|
228
|
+
:auth_names => auth_names,
|
|
229
|
+
:return_type => return_type
|
|
230
|
+
)
|
|
231
|
+
|
|
232
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
233
|
+
if @api_client.config.debugging
|
|
234
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#delete_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
235
|
+
end
|
|
236
|
+
return data, status_code, headers
|
|
237
|
+
end
|
|
238
|
+
|
|
239
|
+
# Get single connection by ID
|
|
240
|
+
# @param company_id [String] Unique identifier for the Company
|
|
241
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
242
|
+
# @param [Hash] opts the optional parameters
|
|
243
|
+
# @return [GetConnectionsById200Response]
|
|
244
|
+
def get_connections_by_id(company_id, connection_id, opts = {})
|
|
245
|
+
data, _status_code, _headers = get_connections_by_id_with_http_info(company_id, connection_id, opts)
|
|
246
|
+
data
|
|
247
|
+
end
|
|
248
|
+
|
|
249
|
+
# Get single connection by ID
|
|
250
|
+
# @param company_id [String] Unique identifier for the Company
|
|
251
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
252
|
+
# @param [Hash] opts the optional parameters
|
|
253
|
+
# @return [Array<(GetConnectionsById200Response, Integer, Hash)>] GetConnectionsById200Response data, response status code and response headers
|
|
254
|
+
def get_connections_by_id_with_http_info(company_id, connection_id, opts = {})
|
|
255
|
+
if @api_client.config.debugging
|
|
256
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.get_connections_by_id ...'
|
|
257
|
+
end
|
|
258
|
+
# verify the required parameter 'company_id' is set
|
|
259
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
260
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.get_connections_by_id"
|
|
261
|
+
end
|
|
262
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
263
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id, the character length must be smaller than or equal to 255.'
|
|
264
|
+
end
|
|
265
|
+
|
|
266
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
267
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id, the character length must be greater than or equal to 1.'
|
|
268
|
+
end
|
|
269
|
+
|
|
270
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
271
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
272
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.get_connections_by_id, must conform to the pattern #{pattern}."
|
|
273
|
+
end
|
|
274
|
+
|
|
275
|
+
# verify the required parameter 'connection_id' is set
|
|
276
|
+
if @api_client.config.client_side_validation && connection_id.nil?
|
|
277
|
+
fail ArgumentError, "Missing the required parameter 'connection_id' when calling ConnectionsApi.get_connections_by_id"
|
|
278
|
+
end
|
|
279
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length > 255
|
|
280
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id, the character length must be smaller than or equal to 255.'
|
|
281
|
+
end
|
|
282
|
+
|
|
283
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length < 1
|
|
284
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id, the character length must be greater than or equal to 1.'
|
|
285
|
+
end
|
|
286
|
+
|
|
287
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
288
|
+
if @api_client.config.client_side_validation && connection_id !~ pattern
|
|
289
|
+
fail ArgumentError, "invalid value for 'connection_id' when calling ConnectionsApi.get_connections_by_id, must conform to the pattern #{pattern}."
|
|
290
|
+
end
|
|
291
|
+
|
|
292
|
+
# resource path
|
|
293
|
+
local_var_path = '/companies/{company_id}/connections/{connection_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s)).sub('{' + 'connection_id' + '}', CGI.escape(connection_id.to_s))
|
|
294
|
+
|
|
295
|
+
# query parameters
|
|
296
|
+
query_params = opts[:query_params] || {}
|
|
297
|
+
|
|
298
|
+
# header parameters
|
|
299
|
+
header_params = opts[:header_params] || {}
|
|
300
|
+
# HTTP header 'Accept' (if needed)
|
|
301
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
302
|
+
|
|
303
|
+
# form parameters
|
|
304
|
+
form_params = opts[:form_params] || {}
|
|
305
|
+
|
|
306
|
+
# http body (model)
|
|
307
|
+
post_body = opts[:debug_body]
|
|
308
|
+
|
|
309
|
+
# return_type
|
|
310
|
+
return_type = opts[:debug_return_type] || 'GetConnectionsById200Response'
|
|
311
|
+
|
|
312
|
+
# auth_names
|
|
313
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
314
|
+
|
|
315
|
+
new_options = opts.merge(
|
|
316
|
+
:operation => :"ConnectionsApi.get_connections_by_id",
|
|
317
|
+
:header_params => header_params,
|
|
318
|
+
:query_params => query_params,
|
|
319
|
+
:form_params => form_params,
|
|
320
|
+
:body => post_body,
|
|
321
|
+
:auth_names => auth_names,
|
|
322
|
+
:return_type => return_type
|
|
323
|
+
)
|
|
324
|
+
|
|
325
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
326
|
+
if @api_client.config.debugging
|
|
327
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#get_connections_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
328
|
+
end
|
|
329
|
+
return data, status_code, headers
|
|
330
|
+
end
|
|
331
|
+
|
|
332
|
+
# Test the specified connection
|
|
333
|
+
# @param company_id [String] Unique identifier for the Company
|
|
334
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
335
|
+
# @param [Hash] opts the optional parameters
|
|
336
|
+
# @return [GetConnectionsById200Response]
|
|
337
|
+
def get_connections_by_id2(company_id, connection_id, opts = {})
|
|
338
|
+
data, _status_code, _headers = get_connections_by_id2_with_http_info(company_id, connection_id, opts)
|
|
339
|
+
data
|
|
340
|
+
end
|
|
341
|
+
|
|
342
|
+
# Test the specified connection
|
|
343
|
+
# @param company_id [String] Unique identifier for the Company
|
|
344
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
345
|
+
# @param [Hash] opts the optional parameters
|
|
346
|
+
# @return [Array<(GetConnectionsById200Response, Integer, Hash)>] GetConnectionsById200Response data, response status code and response headers
|
|
347
|
+
def get_connections_by_id2_with_http_info(company_id, connection_id, opts = {})
|
|
348
|
+
if @api_client.config.debugging
|
|
349
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.get_connections_by_id2 ...'
|
|
350
|
+
end
|
|
351
|
+
# verify the required parameter 'company_id' is set
|
|
352
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
353
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.get_connections_by_id2"
|
|
354
|
+
end
|
|
355
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
356
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id2, the character length must be smaller than or equal to 255.'
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
360
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id2, the character length must be greater than or equal to 1.'
|
|
361
|
+
end
|
|
362
|
+
|
|
363
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
364
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
365
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.get_connections_by_id2, must conform to the pattern #{pattern}."
|
|
366
|
+
end
|
|
367
|
+
|
|
368
|
+
# verify the required parameter 'connection_id' is set
|
|
369
|
+
if @api_client.config.client_side_validation && connection_id.nil?
|
|
370
|
+
fail ArgumentError, "Missing the required parameter 'connection_id' when calling ConnectionsApi.get_connections_by_id2"
|
|
371
|
+
end
|
|
372
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length > 255
|
|
373
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id2, the character length must be smaller than or equal to 255.'
|
|
374
|
+
end
|
|
375
|
+
|
|
376
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length < 1
|
|
377
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id2, the character length must be greater than or equal to 1.'
|
|
378
|
+
end
|
|
379
|
+
|
|
380
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
381
|
+
if @api_client.config.client_side_validation && connection_id !~ pattern
|
|
382
|
+
fail ArgumentError, "invalid value for 'connection_id' when calling ConnectionsApi.get_connections_by_id2, must conform to the pattern #{pattern}."
|
|
383
|
+
end
|
|
384
|
+
|
|
385
|
+
# resource path
|
|
386
|
+
local_var_path = '/companies/{company_id}/connections/{connection_id}/test'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s)).sub('{' + 'connection_id' + '}', CGI.escape(connection_id.to_s))
|
|
387
|
+
|
|
388
|
+
# query parameters
|
|
389
|
+
query_params = opts[:query_params] || {}
|
|
390
|
+
|
|
391
|
+
# header parameters
|
|
392
|
+
header_params = opts[:header_params] || {}
|
|
393
|
+
# HTTP header 'Accept' (if needed)
|
|
394
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
395
|
+
|
|
396
|
+
# form parameters
|
|
397
|
+
form_params = opts[:form_params] || {}
|
|
398
|
+
|
|
399
|
+
# http body (model)
|
|
400
|
+
post_body = opts[:debug_body]
|
|
401
|
+
|
|
402
|
+
# return_type
|
|
403
|
+
return_type = opts[:debug_return_type] || 'GetConnectionsById200Response'
|
|
404
|
+
|
|
405
|
+
# auth_names
|
|
406
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
407
|
+
|
|
408
|
+
new_options = opts.merge(
|
|
409
|
+
:operation => :"ConnectionsApi.get_connections_by_id2",
|
|
410
|
+
:header_params => header_params,
|
|
411
|
+
:query_params => query_params,
|
|
412
|
+
:form_params => form_params,
|
|
413
|
+
:body => post_body,
|
|
414
|
+
:auth_names => auth_names,
|
|
415
|
+
:return_type => return_type
|
|
416
|
+
)
|
|
417
|
+
|
|
418
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
419
|
+
if @api_client.config.debugging
|
|
420
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#get_connections_by_id2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
421
|
+
end
|
|
422
|
+
return data, status_code, headers
|
|
423
|
+
end
|
|
424
|
+
|
|
425
|
+
# Retrieve the information schema for the specified connection
|
|
426
|
+
# @param company_id [String] Unique identifier for the Company
|
|
427
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
428
|
+
# @param [Hash] opts the optional parameters
|
|
429
|
+
# @return [GetConnectionsById200Response]
|
|
430
|
+
def get_connections_by_id_infoschema(company_id, connection_id, opts = {})
|
|
431
|
+
data, _status_code, _headers = get_connections_by_id_infoschema_with_http_info(company_id, connection_id, opts)
|
|
432
|
+
data
|
|
433
|
+
end
|
|
434
|
+
|
|
435
|
+
# Retrieve the information schema for the specified connection
|
|
436
|
+
# @param company_id [String] Unique identifier for the Company
|
|
437
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
438
|
+
# @param [Hash] opts the optional parameters
|
|
439
|
+
# @return [Array<(GetConnectionsById200Response, Integer, Hash)>] GetConnectionsById200Response data, response status code and response headers
|
|
440
|
+
def get_connections_by_id_infoschema_with_http_info(company_id, connection_id, opts = {})
|
|
441
|
+
if @api_client.config.debugging
|
|
442
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.get_connections_by_id_infoschema ...'
|
|
443
|
+
end
|
|
444
|
+
# verify the required parameter 'company_id' is set
|
|
445
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
446
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.get_connections_by_id_infoschema"
|
|
447
|
+
end
|
|
448
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
449
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id_infoschema, the character length must be smaller than or equal to 255.'
|
|
450
|
+
end
|
|
451
|
+
|
|
452
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
453
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id_infoschema, the character length must be greater than or equal to 1.'
|
|
454
|
+
end
|
|
455
|
+
|
|
456
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
457
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
458
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.get_connections_by_id_infoschema, must conform to the pattern #{pattern}."
|
|
459
|
+
end
|
|
460
|
+
|
|
461
|
+
# verify the required parameter 'connection_id' is set
|
|
462
|
+
if @api_client.config.client_side_validation && connection_id.nil?
|
|
463
|
+
fail ArgumentError, "Missing the required parameter 'connection_id' when calling ConnectionsApi.get_connections_by_id_infoschema"
|
|
464
|
+
end
|
|
465
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length > 255
|
|
466
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id_infoschema, the character length must be smaller than or equal to 255.'
|
|
467
|
+
end
|
|
468
|
+
|
|
469
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length < 1
|
|
470
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id_infoschema, the character length must be greater than or equal to 1.'
|
|
471
|
+
end
|
|
472
|
+
|
|
473
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
474
|
+
if @api_client.config.client_side_validation && connection_id !~ pattern
|
|
475
|
+
fail ArgumentError, "invalid value for 'connection_id' when calling ConnectionsApi.get_connections_by_id_infoschema, must conform to the pattern #{pattern}."
|
|
476
|
+
end
|
|
477
|
+
|
|
478
|
+
# resource path
|
|
479
|
+
local_var_path = '/companies/{company_id}/connections/{connection_id}/infoschema'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s)).sub('{' + 'connection_id' + '}', CGI.escape(connection_id.to_s))
|
|
480
|
+
|
|
481
|
+
# query parameters
|
|
482
|
+
query_params = opts[:query_params] || {}
|
|
483
|
+
|
|
484
|
+
# header parameters
|
|
485
|
+
header_params = opts[:header_params] || {}
|
|
486
|
+
# HTTP header 'Accept' (if needed)
|
|
487
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
488
|
+
|
|
489
|
+
# form parameters
|
|
490
|
+
form_params = opts[:form_params] || {}
|
|
491
|
+
|
|
492
|
+
# http body (model)
|
|
493
|
+
post_body = opts[:debug_body]
|
|
494
|
+
|
|
495
|
+
# return_type
|
|
496
|
+
return_type = opts[:debug_return_type] || 'GetConnectionsById200Response'
|
|
497
|
+
|
|
498
|
+
# auth_names
|
|
499
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
500
|
+
|
|
501
|
+
new_options = opts.merge(
|
|
502
|
+
:operation => :"ConnectionsApi.get_connections_by_id_infoschema",
|
|
503
|
+
:header_params => header_params,
|
|
504
|
+
:query_params => query_params,
|
|
505
|
+
:form_params => form_params,
|
|
506
|
+
:body => post_body,
|
|
507
|
+
:auth_names => auth_names,
|
|
508
|
+
:return_type => return_type
|
|
509
|
+
)
|
|
510
|
+
|
|
511
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
512
|
+
if @api_client.config.debugging
|
|
513
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#get_connections_by_id_infoschema\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
514
|
+
end
|
|
515
|
+
return data, status_code, headers
|
|
516
|
+
end
|
|
517
|
+
|
|
518
|
+
# Get a randomized sample of rows from a table on this connection. Used by the visualization editor to give sellers data to author against. Query Parameters: schema_name (required): Schema/dataset name table_name (required): Table name limit (optional): Max rows to return (default 1000, max 10000) Returns columnar data — {column_name: [values]} — ready for Plotly's dataSources prop. The actual chart at render time will pull fresh data via the asset's saved SQL; this is only for authoring preview.
|
|
519
|
+
# @param company_id [String] Unique identifier for the Company
|
|
520
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
521
|
+
# @param [Hash] opts the optional parameters
|
|
522
|
+
# @return [GetConnectionsById200Response]
|
|
523
|
+
def get_connections_by_id_sample_data(company_id, connection_id, opts = {})
|
|
524
|
+
data, _status_code, _headers = get_connections_by_id_sample_data_with_http_info(company_id, connection_id, opts)
|
|
525
|
+
data
|
|
526
|
+
end
|
|
527
|
+
|
|
528
|
+
# Get a randomized sample of rows from a table on this connection. Used by the visualization editor to give sellers data to author against. Query Parameters: schema_name (required): Schema/dataset name table_name (required): Table name limit (optional): Max rows to return (default 1000, max 10000) Returns columnar data — {column_name: [values]} — ready for Plotly's dataSources prop. The actual chart at render time will pull fresh data via the asset's saved SQL; this is only for authoring preview.
|
|
529
|
+
# @param company_id [String] Unique identifier for the Company
|
|
530
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
531
|
+
# @param [Hash] opts the optional parameters
|
|
532
|
+
# @return [Array<(GetConnectionsById200Response, Integer, Hash)>] GetConnectionsById200Response data, response status code and response headers
|
|
533
|
+
def get_connections_by_id_sample_data_with_http_info(company_id, connection_id, opts = {})
|
|
534
|
+
if @api_client.config.debugging
|
|
535
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.get_connections_by_id_sample_data ...'
|
|
536
|
+
end
|
|
537
|
+
# verify the required parameter 'company_id' is set
|
|
538
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
539
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.get_connections_by_id_sample_data"
|
|
540
|
+
end
|
|
541
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
542
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id_sample_data, the character length must be smaller than or equal to 255.'
|
|
543
|
+
end
|
|
544
|
+
|
|
545
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
546
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.get_connections_by_id_sample_data, the character length must be greater than or equal to 1.'
|
|
547
|
+
end
|
|
548
|
+
|
|
549
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
550
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
551
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.get_connections_by_id_sample_data, must conform to the pattern #{pattern}."
|
|
552
|
+
end
|
|
553
|
+
|
|
554
|
+
# verify the required parameter 'connection_id' is set
|
|
555
|
+
if @api_client.config.client_side_validation && connection_id.nil?
|
|
556
|
+
fail ArgumentError, "Missing the required parameter 'connection_id' when calling ConnectionsApi.get_connections_by_id_sample_data"
|
|
557
|
+
end
|
|
558
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length > 255
|
|
559
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id_sample_data, the character length must be smaller than or equal to 255.'
|
|
560
|
+
end
|
|
561
|
+
|
|
562
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length < 1
|
|
563
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.get_connections_by_id_sample_data, the character length must be greater than or equal to 1.'
|
|
564
|
+
end
|
|
565
|
+
|
|
566
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
567
|
+
if @api_client.config.client_side_validation && connection_id !~ pattern
|
|
568
|
+
fail ArgumentError, "invalid value for 'connection_id' when calling ConnectionsApi.get_connections_by_id_sample_data, must conform to the pattern #{pattern}."
|
|
569
|
+
end
|
|
570
|
+
|
|
571
|
+
# resource path
|
|
572
|
+
local_var_path = '/companies/{company_id}/connections/{connection_id}/sample-data'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s)).sub('{' + 'connection_id' + '}', CGI.escape(connection_id.to_s))
|
|
573
|
+
|
|
574
|
+
# query parameters
|
|
575
|
+
query_params = opts[:query_params] || {}
|
|
576
|
+
|
|
577
|
+
# header parameters
|
|
578
|
+
header_params = opts[:header_params] || {}
|
|
579
|
+
# HTTP header 'Accept' (if needed)
|
|
580
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
581
|
+
|
|
582
|
+
# form parameters
|
|
583
|
+
form_params = opts[:form_params] || {}
|
|
584
|
+
|
|
585
|
+
# http body (model)
|
|
586
|
+
post_body = opts[:debug_body]
|
|
587
|
+
|
|
588
|
+
# return_type
|
|
589
|
+
return_type = opts[:debug_return_type] || 'GetConnectionsById200Response'
|
|
590
|
+
|
|
591
|
+
# auth_names
|
|
592
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
593
|
+
|
|
594
|
+
new_options = opts.merge(
|
|
595
|
+
:operation => :"ConnectionsApi.get_connections_by_id_sample_data",
|
|
596
|
+
:header_params => header_params,
|
|
597
|
+
:query_params => query_params,
|
|
598
|
+
:form_params => form_params,
|
|
599
|
+
:body => post_body,
|
|
600
|
+
:auth_names => auth_names,
|
|
601
|
+
:return_type => return_type
|
|
602
|
+
)
|
|
603
|
+
|
|
604
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
605
|
+
if @api_client.config.debugging
|
|
606
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#get_connections_by_id_sample_data\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
607
|
+
end
|
|
608
|
+
return data, status_code, headers
|
|
609
|
+
end
|
|
610
|
+
|
|
611
|
+
# Get all connections for a specific company
|
|
612
|
+
# @param company_id [String] Unique identifier for the Company
|
|
613
|
+
# @param [Hash] opts the optional parameters
|
|
614
|
+
# @option opts [Integer] :page Page number for pagination (default to 1)
|
|
615
|
+
# @option opts [Integer] :limit Number of items per page (default to 20)
|
|
616
|
+
# @option opts [String] :sort_by Field to sort by
|
|
617
|
+
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
618
|
+
# @option opts [String] :search Search term to filter results
|
|
619
|
+
# @return [ListConnections200Response]
|
|
620
|
+
def list_connections(company_id, opts = {})
|
|
621
|
+
data, _status_code, _headers = list_connections_with_http_info(company_id, opts)
|
|
622
|
+
data
|
|
623
|
+
end
|
|
624
|
+
|
|
625
|
+
# Get all connections for a specific company
|
|
626
|
+
# @param company_id [String] Unique identifier for the Company
|
|
627
|
+
# @param [Hash] opts the optional parameters
|
|
628
|
+
# @option opts [Integer] :page Page number for pagination (default to 1)
|
|
629
|
+
# @option opts [Integer] :limit Number of items per page (default to 20)
|
|
630
|
+
# @option opts [String] :sort_by Field to sort by
|
|
631
|
+
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
632
|
+
# @option opts [String] :search Search term to filter results
|
|
633
|
+
# @return [Array<(ListConnections200Response, Integer, Hash)>] ListConnections200Response data, response status code and response headers
|
|
634
|
+
def list_connections_with_http_info(company_id, opts = {})
|
|
635
|
+
if @api_client.config.debugging
|
|
636
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.list_connections ...'
|
|
637
|
+
end
|
|
638
|
+
# verify the required parameter 'company_id' is set
|
|
639
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
640
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.list_connections"
|
|
641
|
+
end
|
|
642
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
643
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.list_connections, the character length must be smaller than or equal to 255.'
|
|
644
|
+
end
|
|
645
|
+
|
|
646
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
647
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.list_connections, the character length must be greater than or equal to 1.'
|
|
648
|
+
end
|
|
649
|
+
|
|
650
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
651
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
652
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.list_connections, must conform to the pattern #{pattern}."
|
|
653
|
+
end
|
|
654
|
+
|
|
655
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
656
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling ConnectionsApi.list_connections, must be greater than or equal to 1.'
|
|
657
|
+
end
|
|
658
|
+
|
|
659
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
660
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ConnectionsApi.list_connections, must be smaller than or equal to 100.'
|
|
661
|
+
end
|
|
662
|
+
|
|
663
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
664
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ConnectionsApi.list_connections, must be greater than or equal to 1.'
|
|
665
|
+
end
|
|
666
|
+
|
|
667
|
+
allowable_values = ["asc", "desc"]
|
|
668
|
+
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
669
|
+
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
670
|
+
end
|
|
671
|
+
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
672
|
+
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling ConnectionsApi.list_connections, the character length must be smaller than or equal to 255.'
|
|
673
|
+
end
|
|
674
|
+
|
|
675
|
+
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
676
|
+
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling ConnectionsApi.list_connections, the character length must be greater than or equal to 1.'
|
|
677
|
+
end
|
|
678
|
+
|
|
679
|
+
# resource path
|
|
680
|
+
local_var_path = '/companies/{company_id}/connections'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
681
|
+
|
|
682
|
+
# query parameters
|
|
683
|
+
query_params = opts[:query_params] || {}
|
|
684
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
685
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
686
|
+
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
687
|
+
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
688
|
+
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
689
|
+
|
|
690
|
+
# header parameters
|
|
691
|
+
header_params = opts[:header_params] || {}
|
|
692
|
+
# HTTP header 'Accept' (if needed)
|
|
693
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
694
|
+
|
|
695
|
+
# form parameters
|
|
696
|
+
form_params = opts[:form_params] || {}
|
|
697
|
+
|
|
698
|
+
# http body (model)
|
|
699
|
+
post_body = opts[:debug_body]
|
|
700
|
+
|
|
701
|
+
# return_type
|
|
702
|
+
return_type = opts[:debug_return_type] || 'ListConnections200Response'
|
|
703
|
+
|
|
704
|
+
# auth_names
|
|
705
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
706
|
+
|
|
707
|
+
new_options = opts.merge(
|
|
708
|
+
:operation => :"ConnectionsApi.list_connections",
|
|
709
|
+
:header_params => header_params,
|
|
710
|
+
:query_params => query_params,
|
|
711
|
+
:form_params => form_params,
|
|
712
|
+
:body => post_body,
|
|
713
|
+
:auth_names => auth_names,
|
|
714
|
+
:return_type => return_type
|
|
715
|
+
)
|
|
716
|
+
|
|
717
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
718
|
+
if @api_client.config.debugging
|
|
719
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#list_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
720
|
+
end
|
|
721
|
+
return data, status_code, headers
|
|
722
|
+
end
|
|
723
|
+
|
|
724
|
+
# Update an existing connection by ID
|
|
725
|
+
# @param company_id [String] Unique identifier for the Company
|
|
726
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
727
|
+
# @param connections_update [ConnectionsUpdate]
|
|
728
|
+
# @param [Hash] opts the optional parameters
|
|
729
|
+
# @return [UpdateConnections200Response]
|
|
730
|
+
def update_connections(company_id, connection_id, connections_update, opts = {})
|
|
731
|
+
data, _status_code, _headers = update_connections_with_http_info(company_id, connection_id, connections_update, opts)
|
|
732
|
+
data
|
|
733
|
+
end
|
|
734
|
+
|
|
735
|
+
# Update an existing connection by ID
|
|
736
|
+
# @param company_id [String] Unique identifier for the Company
|
|
737
|
+
# @param connection_id [String] Unique identifier for the Connection
|
|
738
|
+
# @param connections_update [ConnectionsUpdate]
|
|
739
|
+
# @param [Hash] opts the optional parameters
|
|
740
|
+
# @return [Array<(UpdateConnections200Response, Integer, Hash)>] UpdateConnections200Response data, response status code and response headers
|
|
741
|
+
def update_connections_with_http_info(company_id, connection_id, connections_update, opts = {})
|
|
742
|
+
if @api_client.config.debugging
|
|
743
|
+
@api_client.config.logger.debug 'Calling API: ConnectionsApi.update_connections ...'
|
|
744
|
+
end
|
|
745
|
+
# verify the required parameter 'company_id' is set
|
|
746
|
+
if @api_client.config.client_side_validation && company_id.nil?
|
|
747
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling ConnectionsApi.update_connections"
|
|
748
|
+
end
|
|
749
|
+
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
750
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.update_connections, the character length must be smaller than or equal to 255.'
|
|
751
|
+
end
|
|
752
|
+
|
|
753
|
+
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
754
|
+
fail ArgumentError, 'invalid value for "company_id" when calling ConnectionsApi.update_connections, the character length must be greater than or equal to 1.'
|
|
755
|
+
end
|
|
756
|
+
|
|
757
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
758
|
+
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
759
|
+
fail ArgumentError, "invalid value for 'company_id' when calling ConnectionsApi.update_connections, must conform to the pattern #{pattern}."
|
|
760
|
+
end
|
|
761
|
+
|
|
762
|
+
# verify the required parameter 'connection_id' is set
|
|
763
|
+
if @api_client.config.client_side_validation && connection_id.nil?
|
|
764
|
+
fail ArgumentError, "Missing the required parameter 'connection_id' when calling ConnectionsApi.update_connections"
|
|
765
|
+
end
|
|
766
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length > 255
|
|
767
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.update_connections, the character length must be smaller than or equal to 255.'
|
|
768
|
+
end
|
|
769
|
+
|
|
770
|
+
if @api_client.config.client_side_validation && connection_id.to_s.length < 1
|
|
771
|
+
fail ArgumentError, 'invalid value for "connection_id" when calling ConnectionsApi.update_connections, the character length must be greater than or equal to 1.'
|
|
772
|
+
end
|
|
773
|
+
|
|
774
|
+
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
775
|
+
if @api_client.config.client_side_validation && connection_id !~ pattern
|
|
776
|
+
fail ArgumentError, "invalid value for 'connection_id' when calling ConnectionsApi.update_connections, must conform to the pattern #{pattern}."
|
|
777
|
+
end
|
|
778
|
+
|
|
779
|
+
# verify the required parameter 'connections_update' is set
|
|
780
|
+
if @api_client.config.client_side_validation && connections_update.nil?
|
|
781
|
+
fail ArgumentError, "Missing the required parameter 'connections_update' when calling ConnectionsApi.update_connections"
|
|
782
|
+
end
|
|
783
|
+
# resource path
|
|
784
|
+
local_var_path = '/companies/{company_id}/connections/{connection_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s)).sub('{' + 'connection_id' + '}', CGI.escape(connection_id.to_s))
|
|
785
|
+
|
|
786
|
+
# query parameters
|
|
787
|
+
query_params = opts[:query_params] || {}
|
|
788
|
+
|
|
789
|
+
# header parameters
|
|
790
|
+
header_params = opts[:header_params] || {}
|
|
791
|
+
# HTTP header 'Accept' (if needed)
|
|
792
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
793
|
+
# HTTP header 'Content-Type'
|
|
794
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
795
|
+
if !content_type.nil?
|
|
796
|
+
header_params['Content-Type'] = content_type
|
|
797
|
+
end
|
|
798
|
+
|
|
799
|
+
# form parameters
|
|
800
|
+
form_params = opts[:form_params] || {}
|
|
801
|
+
|
|
802
|
+
# http body (model)
|
|
803
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(connections_update)
|
|
804
|
+
|
|
805
|
+
# return_type
|
|
806
|
+
return_type = opts[:debug_return_type] || 'UpdateConnections200Response'
|
|
807
|
+
|
|
808
|
+
# auth_names
|
|
809
|
+
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
810
|
+
|
|
811
|
+
new_options = opts.merge(
|
|
812
|
+
:operation => :"ConnectionsApi.update_connections",
|
|
813
|
+
:header_params => header_params,
|
|
814
|
+
:query_params => query_params,
|
|
815
|
+
:form_params => form_params,
|
|
816
|
+
:body => post_body,
|
|
817
|
+
:auth_names => auth_names,
|
|
818
|
+
:return_type => return_type
|
|
819
|
+
)
|
|
820
|
+
|
|
821
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
822
|
+
if @api_client.config.debugging
|
|
823
|
+
@api_client.config.logger.debug "API called: ConnectionsApi#update_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
824
|
+
end
|
|
825
|
+
return data, status_code, headers
|
|
826
|
+
end
|
|
827
|
+
end
|
|
828
|
+
end
|