spartera_api_sdk 0.3.7 → 1.0.58
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 +4 -4
- data/Gemfile +5 -3
- data/Gemfile.lock +69 -0
- data/README.md +324 -336
- data/config.json +10 -0
- data/docs/APIKeysApi.md +102 -286
- data/docs/Alert.md +36 -0
- data/docs/AlertsApi.md +163 -177
- data/docs/Apikey.md +36 -0
- data/docs/Asset.md +110 -0
- data/docs/AssetPriceHistoryApi.md +178 -202
- data/docs/Assetpricehistory.md +38 -0
- data/docs/AssetsApi.md +352 -418
- data/docs/CloudProvidersApi.md +233 -49
- data/docs/Cloudprovider.md +30 -0
- data/docs/CompaniesApi.md +171 -357
- data/docs/Company.md +44 -0
- data/docs/Connection.md +54 -0
- data/docs/ConnectionsApi.md +139 -249
- data/docs/Favorite.md +36 -0
- data/docs/FavoritesApi.md +183 -199
- data/docs/User.md +34 -0
- data/docs/UsersApi.md +97 -379
- data/example.rb +51 -0
- data/git_push.sh +2 -2
- data/lib/spartera_api_sdk/api/alerts_api.rb +176 -423
- data/lib/spartera_api_sdk/api/api_keys_api.rb +95 -496
- data/lib/spartera_api_sdk/api/asset_price_history_api.rb +177 -468
- data/lib/spartera_api_sdk/api/assets_api.rb +358 -806
- data/lib/spartera_api_sdk/api/cloud_providers_api.rb +199 -74
- data/lib/spartera_api_sdk/api/companies_api.rb +146 -660
- data/lib/spartera_api_sdk/api/connections_api.rb +139 -466
- data/lib/spartera_api_sdk/api/favorites_api.rb +204 -464
- data/lib/spartera_api_sdk/api/users_api.rb +95 -619
- data/lib/spartera_api_sdk/api_client.rb +4 -8
- data/lib/spartera_api_sdk/api_error.rb +2 -2
- data/lib/spartera_api_sdk/configuration.rb +12 -4
- data/lib/spartera_api_sdk/models/{alerts.rb → alert.rb} +139 -46
- data/lib/spartera_api_sdk/models/{api_keys.rb → apikey.rb} +124 -98
- data/lib/spartera_api_sdk/models/asset.rb +686 -0
- data/lib/spartera_api_sdk/models/{asset_price_history.rb → assetpricehistory.rb} +180 -44
- data/lib/spartera_api_sdk/models/{cloud_providers.rb → cloudprovider.rb} +111 -35
- data/lib/spartera_api_sdk/models/{companies.rb → company.rb} +105 -90
- data/lib/spartera_api_sdk/models/{connections.rb → connection.rb} +186 -69
- data/lib/spartera_api_sdk/models/error.rb +76 -3
- data/lib/spartera_api_sdk/models/{favorites.rb → favorite.rb} +111 -38
- data/lib/spartera_api_sdk/models/inline_object.rb +76 -3
- data/lib/spartera_api_sdk/models/inline_object1.rb +76 -3
- data/lib/spartera_api_sdk/models/inline_object2.rb +76 -3
- data/lib/spartera_api_sdk/models/inline_object3.rb +76 -3
- data/lib/spartera_api_sdk/models/{users.rb → user.rb} +108 -112
- data/lib/spartera_api_sdk/version.rb +3 -3
- data/lib/spartera_api_sdk.rb +11 -150
- data/spartera_api_sdk.gemspec +8 -19
- data/spec/api/alerts_api_spec.rb +51 -51
- data/spec/api/api_keys_api_spec.rb +30 -67
- data/spec/api/asset_price_history_api_spec.rb +53 -57
- data/spec/api/assets_api_spec.rb +99 -114
- data/spec/api/cloud_providers_api_spec.rb +42 -15
- data/spec/api/companies_api_spec.rb +47 -99
- data/spec/api/connections_api_spec.rb +41 -63
- data/spec/api/favorites_api_spec.rb +56 -56
- data/spec/api/users_api_spec.rb +29 -88
- data/spec/models/{postgen_integrations_spec.rb → alert_spec.rb} +17 -17
- data/spec/models/{api_keys_update_spec.rb → apikey_spec.rb} +20 -14
- data/spec/models/{endpoints_spec.rb → asset_spec.rb} +83 -69
- data/spec/models/{api_keys_spec.rb → assetpricehistory_spec.rb} +19 -25
- data/spec/models/{cloud_providers_spec.rb → cloudprovider_spec.rb} +20 -14
- data/spec/models/{companies_spec.rb → company_spec.rb} +16 -26
- data/spec/models/{posts_input_spec.rb → connection_spec.rb} +27 -51
- data/spec/models/error_spec.rb +3 -3
- data/spec/models/{favorites_spec.rb → favorite_spec.rb} +23 -17
- data/spec/models/inline_object1_spec.rb +3 -3
- data/spec/models/inline_object2_spec.rb +3 -3
- data/spec/models/inline_object3_spec.rb +3 -3
- data/spec/models/inline_object_spec.rb +3 -3
- data/spec/models/{api_keys_input_spec.rb → user_spec.rb} +15 -15
- data/spec/spec_helper.rb +2 -2
- data/test.sh +42 -0
- metadata +77 -615
- data/CHANGELOG.md +0 -13
- data/docs/Alerts.md +0 -30
- data/docs/AlertsInput.md +0 -24
- data/docs/AlertsUpdate.md +0 -24
- data/docs/ApiKeys.md +0 -40
- data/docs/ApiKeysInput.md +0 -34
- data/docs/ApiKeysUpdate.md +0 -34
- data/docs/AssetPriceHistory.md +0 -30
- data/docs/AssetPriceHistoryInput.md +0 -24
- data/docs/AssetPriceHistoryUpdate.md +0 -24
- data/docs/AssetUsecases.md +0 -28
- data/docs/AssetUsecasesApi.md +0 -157
- data/docs/Assets.md +0 -142
- data/docs/AssetsInput.md +0 -128
- data/docs/AssetsUpdate.md +0 -128
- data/docs/CloudProviders.md +0 -28
- data/docs/CloudProvidersInput.md +0 -22
- data/docs/CloudProvidersUpdate.md +0 -22
- data/docs/Companies.md +0 -46
- data/docs/CompaniesInput.md +0 -40
- data/docs/CompaniesUpdate.md +0 -40
- data/docs/Connections.md +0 -38
- data/docs/ConnectionsInput.md +0 -32
- data/docs/ConnectionsUpdate.md +0 -32
- data/docs/CreateAlerts200Response.md +0 -20
- data/docs/CreateAlerts200ResponseData.md +0 -18
- data/docs/CreateApiKeys200Response.md +0 -20
- data/docs/CreateApiKeys200ResponseData.md +0 -18
- data/docs/CreateAssetPriceHistory200Response.md +0 -20
- data/docs/CreateAssetPriceHistory200ResponseData.md +0 -18
- data/docs/CreateAssetsAnalyze200Response.md +0 -20
- data/docs/CreateAssetsAnalyze200ResponseData.md +0 -18
- data/docs/CreateConnections200Response.md +0 -20
- data/docs/CreateConnections200ResponseData.md +0 -18
- data/docs/CreateEndpoints200Response.md +0 -20
- data/docs/CreateEndpoints200ResponseData.md +0 -18
- data/docs/CreateFavorites200Response.md +0 -20
- data/docs/CreateFavorites200ResponseData.md +0 -18
- data/docs/CreatePostgenIntegrations200Response.md +0 -20
- data/docs/CreatePostgenIntegrations200ResponseData.md +0 -18
- data/docs/CreatePosts200Response.md +0 -20
- data/docs/CreatePosts200ResponseData.md +0 -18
- data/docs/CreateUsers200Response.md +0 -20
- data/docs/CreateUsers200ResponseData.md +0 -18
- data/docs/DeleteAlerts200Response.md +0 -20
- data/docs/DeleteAlerts200ResponseData.md +0 -18
- data/docs/DeleteApiKeys200Response.md +0 -20
- data/docs/DeleteApiKeys200ResponseData.md +0 -18
- data/docs/DeleteAssetPriceHistory200Response.md +0 -20
- data/docs/DeleteAssetPriceHistory200ResponseData.md +0 -18
- data/docs/DeleteAssets200Response.md +0 -20
- data/docs/DeleteAssets200ResponseData.md +0 -18
- data/docs/DeleteConnections200Response.md +0 -20
- data/docs/DeleteConnections200ResponseData.md +0 -18
- data/docs/DeleteEndpoints200Response.md +0 -20
- data/docs/DeleteEndpoints200ResponseData.md +0 -18
- data/docs/DeleteFavorites200Response.md +0 -20
- data/docs/DeleteFavorites200ResponseData.md +0 -18
- data/docs/DeletePostgenIntegrations200Response.md +0 -20
- data/docs/DeletePostgenIntegrations200ResponseData.md +0 -18
- data/docs/DeletePosts200Response.md +0 -20
- data/docs/DeletePosts200ResponseData.md +0 -18
- data/docs/DeleteUsers200Response.md +0 -20
- data/docs/DeleteUsers200ResponseData.md +0 -18
- data/docs/Endpoints.md +0 -96
- data/docs/EndpointsApi.md +0 -1189
- data/docs/EndpointsInput.md +0 -94
- data/docs/EndpointsUpdate.md +0 -94
- data/docs/Favorites.md +0 -34
- data/docs/FavoritesInput.md +0 -28
- data/docs/FavoritesUpdate.md +0 -28
- data/docs/GetAlertsById200Response.md +0 -20
- data/docs/GetApiKeysById200Response.md +0 -20
- data/docs/GetAssetPriceHistoryById200Response.md +0 -20
- data/docs/GetAssetUsecasesById200Response.md +0 -20
- data/docs/GetAssetsByIdAnalyze200Response.md +0 -20
- data/docs/GetCloudProvidersById200Response.md +0 -20
- data/docs/GetCompaniesById200Response.md +0 -20
- data/docs/GetConnectionsById200Response.md +0 -20
- data/docs/GetEndpointsByIdConnectionsDescribe200Response.md +0 -20
- data/docs/GetFavoritesById200Response.md +0 -20
- data/docs/GetIndustriesById200Response.md +0 -20
- data/docs/GetJobFunctionsById200Response.md +0 -20
- data/docs/GetPostgenIntegrationsById200Response.md +0 -20
- data/docs/GetPostsById200Response.md +0 -20
- data/docs/GetStorageEnginesById200Response.md +0 -20
- data/docs/GetUsersById200Response.md +0 -20
- data/docs/Industries.md +0 -32
- data/docs/IndustriesApi.md +0 -237
- data/docs/InlineObject4.md +0 -20
- data/docs/InlineObject5.md +0 -20
- data/docs/InlineObject6.md +0 -22
- data/docs/InlineObject7.md +0 -20
- data/docs/JobFunctions.md +0 -24
- data/docs/JobFunctionsApi.md +0 -157
- data/docs/JobFunctionsInput.md +0 -18
- data/docs/JobFunctionsUpdate.md +0 -18
- data/docs/ListApiKeys200Response.md +0 -20
- data/docs/ListAssetUsecases200Response.md +0 -20
- data/docs/ListAssets200Response.md +0 -20
- data/docs/ListCloudProviders200Response.md +0 -20
- data/docs/ListCompaniesAnalyticsAssets200Response.md +0 -20
- data/docs/ListConnections200Response.md +0 -20
- data/docs/ListEndpoints200Response.md +0 -20
- data/docs/ListIndustries200Response.md +0 -20
- data/docs/ListJobFunctions200Response.md +0 -20
- data/docs/ListPostgenIntegrations200Response.md +0 -20
- data/docs/ListPosts200Response.md +0 -20
- data/docs/ListStorageEngines200Response.md +0 -20
- data/docs/ListUsers200Response.md +0 -20
- data/docs/PostPublications.md +0 -40
- data/docs/PostPublicationsInput.md +0 -34
- data/docs/PostPublicationsUpdate.md +0 -34
- data/docs/PostgenIntegrations.md +0 -36
- data/docs/PostgenIntegrationsApi.md +0 -463
- data/docs/PostgenIntegrationsInput.md +0 -30
- data/docs/PostgenIntegrationsUpdate.md +0 -30
- data/docs/Posts.md +0 -68
- data/docs/PostsApi.md +0 -843
- data/docs/PostsInput.md +0 -62
- data/docs/PostsUpdate.md +0 -62
- data/docs/StorageEngines.md +0 -32
- data/docs/StorageEnginesApi.md +0 -161
- data/docs/UpdateAlerts200Response.md +0 -20
- data/docs/UpdateAlerts200ResponseData.md +0 -18
- data/docs/UpdateApiKeys200Response.md +0 -20
- data/docs/UpdateApiKeys200ResponseData.md +0 -18
- data/docs/UpdateAssetPriceHistory200Response.md +0 -20
- data/docs/UpdateAssetPriceHistory200ResponseData.md +0 -18
- data/docs/UpdateAssets200Response.md +0 -20
- data/docs/UpdateAssets200ResponseData.md +0 -18
- data/docs/UpdateCompanies200Response.md +0 -20
- data/docs/UpdateCompanies200ResponseData.md +0 -18
- data/docs/UpdateConnections200Response.md +0 -20
- data/docs/UpdateConnections200ResponseData.md +0 -18
- data/docs/UpdateEndpoints200Response.md +0 -20
- data/docs/UpdateEndpoints200ResponseData.md +0 -18
- data/docs/UpdateFavorites200Response.md +0 -20
- data/docs/UpdateFavorites200ResponseData.md +0 -18
- data/docs/UpdatePostgenIntegrations200Response.md +0 -20
- data/docs/UpdatePostgenIntegrations200ResponseData.md +0 -18
- data/docs/UpdatePosts200Response.md +0 -20
- data/docs/UpdatePosts200ResponseData.md +0 -18
- data/docs/UpdateUsers200Response.md +0 -20
- data/docs/UpdateUsers200ResponseData.md +0 -18
- data/docs/Users.md +0 -36
- data/docs/UsersInput.md +0 -30
- data/docs/UsersUpdate.md +0 -30
- data/lib/spartera_api_sdk/api/asset_usecases_api.rb +0 -190
- data/lib/spartera_api_sdk/api/endpoints_api.rb +0 -1613
- data/lib/spartera_api_sdk/api/industries_api.rb +0 -284
- data/lib/spartera_api_sdk/api/job_functions_api.rb +0 -190
- data/lib/spartera_api_sdk/api/postgen_integrations_api.rb +0 -634
- data/lib/spartera_api_sdk/api/posts_api.rb +0 -1190
- data/lib/spartera_api_sdk/api/storage_engines_api.rb +0 -228
- data/lib/spartera_api_sdk/api_model_base.rb +0 -88
- data/lib/spartera_api_sdk/models/alerts_input.rb +0 -213
- data/lib/spartera_api_sdk/models/alerts_update.rb +0 -179
- data/lib/spartera_api_sdk/models/api_keys_input.rb +0 -263
- data/lib/spartera_api_sdk/models/api_keys_update.rb +0 -229
- data/lib/spartera_api_sdk/models/asset_price_history_input.rb +0 -179
- data/lib/spartera_api_sdk/models/asset_price_history_update.rb +0 -179
- data/lib/spartera_api_sdk/models/asset_usecases.rb +0 -216
- data/lib/spartera_api_sdk/models/assets.rb +0 -1068
- data/lib/spartera_api_sdk/models/assets_input.rb +0 -918
- data/lib/spartera_api_sdk/models/assets_update.rb +0 -877
- data/lib/spartera_api_sdk/models/cloud_providers_input.rb +0 -186
- data/lib/spartera_api_sdk/models/cloud_providers_update.rb +0 -169
- data/lib/spartera_api_sdk/models/companies_input.rb +0 -327
- data/lib/spartera_api_sdk/models/companies_update.rb +0 -293
- data/lib/spartera_api_sdk/models/connections_input.rb +0 -287
- data/lib/spartera_api_sdk/models/connections_update.rb +0 -253
- data/lib/spartera_api_sdk/models/create_alerts200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_alerts200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_api_keys200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_api_keys200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_asset_price_history200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_asset_price_history200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_assets_analyze200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_assets_analyze200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_connections200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_connections200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_endpoints200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_endpoints200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_favorites200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_favorites200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_postgen_integrations200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_postgen_integrations200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_posts200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_posts200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/create_users200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/create_users200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_alerts200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_alerts200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_api_keys200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_api_keys200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_asset_price_history200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_asset_price_history200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_assets200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_assets200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_connections200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_connections200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_endpoints200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_endpoints200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_favorites200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_favorites200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_postgen_integrations200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_postgen_integrations200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_posts200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_posts200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/delete_users200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/delete_users200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/endpoints.rb +0 -788
- data/lib/spartera_api_sdk/models/endpoints_input.rb +0 -686
- data/lib/spartera_api_sdk/models/endpoints_update.rb +0 -635
- data/lib/spartera_api_sdk/models/favorites_input.rb +0 -233
- data/lib/spartera_api_sdk/models/favorites_update.rb +0 -199
- data/lib/spartera_api_sdk/models/get_alerts_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_api_keys_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_asset_price_history_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_asset_usecases_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_assets_by_id_analyze200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_cloud_providers_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_companies_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_connections_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_endpoints_by_id_connections_describe200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_favorites_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_industries_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_job_functions_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_postgen_integrations_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_posts_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_storage_engines_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/get_users_by_id200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/industries.rb +0 -253
- data/lib/spartera_api_sdk/models/inline_object4.rb +0 -156
- data/lib/spartera_api_sdk/models/inline_object5.rb +0 -156
- data/lib/spartera_api_sdk/models/inline_object6.rb +0 -166
- data/lib/spartera_api_sdk/models/inline_object7.rb +0 -156
- data/lib/spartera_api_sdk/models/job_functions.rb +0 -213
- data/lib/spartera_api_sdk/models/job_functions_input.rb +0 -166
- data/lib/spartera_api_sdk/models/job_functions_update.rb +0 -149
- data/lib/spartera_api_sdk/models/list_api_keys200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_asset_usecases200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_assets200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_cloud_providers200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_companies_analytics_assets200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_connections200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_endpoints200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_industries200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_job_functions200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_postgen_integrations200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_posts200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_storage_engines200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/list_users200_response.rb +0 -193
- data/lib/spartera_api_sdk/models/post_publications.rb +0 -327
- data/lib/spartera_api_sdk/models/post_publications_input.rb +0 -280
- data/lib/spartera_api_sdk/models/post_publications_update.rb +0 -229
- data/lib/spartera_api_sdk/models/postgen_integrations.rb +0 -341
- data/lib/spartera_api_sdk/models/postgen_integrations_input.rb +0 -294
- data/lib/spartera_api_sdk/models/postgen_integrations_update.rb +0 -209
- data/lib/spartera_api_sdk/models/posts.rb +0 -586
- data/lib/spartera_api_sdk/models/posts_input.rb +0 -437
- data/lib/spartera_api_sdk/models/posts_update.rb +0 -369
- data/lib/spartera_api_sdk/models/storage_engines.rb +0 -294
- data/lib/spartera_api_sdk/models/update_alerts200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_alerts200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_api_keys200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_api_keys200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_asset_price_history200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_asset_price_history200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_assets200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_assets200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_companies200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_companies200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_connections200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_connections200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_endpoints200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_endpoints200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_favorites200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_favorites200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_postgen_integrations200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_postgen_integrations200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_posts200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_posts200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/update_users200_response.rb +0 -191
- data/lib/spartera_api_sdk/models/update_users200_response_data.rb +0 -165
- data/lib/spartera_api_sdk/models/users_input.rb +0 -260
- data/lib/spartera_api_sdk/models/users_update.rb +0 -243
- data/spec/api/asset_usecases_api_spec.rb +0 -61
- data/spec/api/endpoints_api_spec.rb +0 -240
- data/spec/api/industries_api_spec.rb +0 -76
- data/spec/api/job_functions_api_spec.rb +0 -61
- data/spec/api/postgen_integrations_api_spec.rb +0 -117
- data/spec/api/posts_api_spec.rb +0 -186
- data/spec/api/storage_engines_api_spec.rb +0 -63
- data/spec/models/alerts_input_spec.rb +0 -54
- data/spec/models/alerts_spec.rb +0 -72
- data/spec/models/alerts_update_spec.rb +0 -54
- data/spec/models/asset_price_history_input_spec.rb +0 -54
- data/spec/models/asset_price_history_spec.rb +0 -72
- data/spec/models/asset_price_history_update_spec.rb +0 -54
- data/spec/models/asset_usecases_spec.rb +0 -66
- data/spec/models/assets_input_spec.rb +0 -418
- data/spec/models/assets_spec.rb +0 -464
- data/spec/models/assets_update_spec.rb +0 -418
- data/spec/models/cloud_providers_input_spec.rb +0 -48
- data/spec/models/cloud_providers_update_spec.rb +0 -48
- data/spec/models/companies_input_spec.rb +0 -106
- data/spec/models/companies_update_spec.rb +0 -106
- data/spec/models/connections_input_spec.rb +0 -82
- data/spec/models/connections_spec.rb +0 -100
- data/spec/models/connections_update_spec.rb +0 -82
- data/spec/models/create_alerts200_response_data_spec.rb +0 -36
- data/spec/models/create_alerts200_response_spec.rb +0 -42
- data/spec/models/create_api_keys200_response_data_spec.rb +0 -36
- data/spec/models/create_api_keys200_response_spec.rb +0 -42
- data/spec/models/create_asset_price_history200_response_data_spec.rb +0 -36
- data/spec/models/create_asset_price_history200_response_spec.rb +0 -42
- data/spec/models/create_assets_analyze200_response_data_spec.rb +0 -36
- data/spec/models/create_assets_analyze200_response_spec.rb +0 -42
- data/spec/models/create_connections200_response_data_spec.rb +0 -36
- data/spec/models/create_connections200_response_spec.rb +0 -42
- data/spec/models/create_endpoints200_response_data_spec.rb +0 -36
- data/spec/models/create_endpoints200_response_spec.rb +0 -42
- data/spec/models/create_favorites200_response_data_spec.rb +0 -36
- data/spec/models/create_favorites200_response_spec.rb +0 -42
- data/spec/models/create_postgen_integrations200_response_data_spec.rb +0 -36
- data/spec/models/create_postgen_integrations200_response_spec.rb +0 -42
- data/spec/models/create_posts200_response_data_spec.rb +0 -36
- data/spec/models/create_posts200_response_spec.rb +0 -42
- data/spec/models/create_users200_response_data_spec.rb +0 -36
- data/spec/models/create_users200_response_spec.rb +0 -42
- data/spec/models/delete_alerts200_response_data_spec.rb +0 -36
- data/spec/models/delete_alerts200_response_spec.rb +0 -42
- data/spec/models/delete_api_keys200_response_data_spec.rb +0 -36
- data/spec/models/delete_api_keys200_response_spec.rb +0 -42
- data/spec/models/delete_asset_price_history200_response_data_spec.rb +0 -36
- data/spec/models/delete_asset_price_history200_response_spec.rb +0 -42
- data/spec/models/delete_assets200_response_data_spec.rb +0 -36
- data/spec/models/delete_assets200_response_spec.rb +0 -42
- data/spec/models/delete_connections200_response_data_spec.rb +0 -36
- data/spec/models/delete_connections200_response_spec.rb +0 -42
- data/spec/models/delete_endpoints200_response_data_spec.rb +0 -36
- data/spec/models/delete_endpoints200_response_spec.rb +0 -42
- data/spec/models/delete_favorites200_response_data_spec.rb +0 -36
- data/spec/models/delete_favorites200_response_spec.rb +0 -42
- data/spec/models/delete_postgen_integrations200_response_data_spec.rb +0 -36
- data/spec/models/delete_postgen_integrations200_response_spec.rb +0 -42
- data/spec/models/delete_posts200_response_data_spec.rb +0 -36
- data/spec/models/delete_posts200_response_spec.rb +0 -42
- data/spec/models/delete_users200_response_data_spec.rb +0 -36
- data/spec/models/delete_users200_response_spec.rb +0 -42
- data/spec/models/endpoints_input_spec.rb +0 -292
- data/spec/models/endpoints_update_spec.rb +0 -292
- data/spec/models/favorites_input_spec.rb +0 -66
- data/spec/models/favorites_update_spec.rb +0 -66
- data/spec/models/get_alerts_by_id200_response_spec.rb +0 -42
- data/spec/models/get_api_keys_by_id200_response_spec.rb +0 -42
- data/spec/models/get_asset_price_history_by_id200_response_spec.rb +0 -42
- data/spec/models/get_asset_usecases_by_id200_response_spec.rb +0 -42
- data/spec/models/get_assets_by_id_analyze200_response_spec.rb +0 -42
- data/spec/models/get_cloud_providers_by_id200_response_spec.rb +0 -42
- data/spec/models/get_companies_by_id200_response_spec.rb +0 -42
- data/spec/models/get_connections_by_id200_response_spec.rb +0 -42
- data/spec/models/get_endpoints_by_id_connections_describe200_response_spec.rb +0 -42
- data/spec/models/get_favorites_by_id200_response_spec.rb +0 -42
- data/spec/models/get_industries_by_id200_response_spec.rb +0 -42
- data/spec/models/get_job_functions_by_id200_response_spec.rb +0 -42
- data/spec/models/get_postgen_integrations_by_id200_response_spec.rb +0 -42
- data/spec/models/get_posts_by_id200_response_spec.rb +0 -42
- data/spec/models/get_storage_engines_by_id200_response_spec.rb +0 -42
- data/spec/models/get_users_by_id200_response_spec.rb +0 -42
- data/spec/models/industries_spec.rb +0 -78
- data/spec/models/inline_object4_spec.rb +0 -42
- data/spec/models/inline_object5_spec.rb +0 -42
- data/spec/models/inline_object6_spec.rb +0 -48
- data/spec/models/inline_object7_spec.rb +0 -42
- data/spec/models/job_functions_input_spec.rb +0 -36
- data/spec/models/job_functions_spec.rb +0 -54
- data/spec/models/job_functions_update_spec.rb +0 -36
- data/spec/models/list_api_keys200_response_spec.rb +0 -42
- data/spec/models/list_asset_usecases200_response_spec.rb +0 -42
- data/spec/models/list_assets200_response_spec.rb +0 -42
- data/spec/models/list_cloud_providers200_response_spec.rb +0 -42
- data/spec/models/list_companies_analytics_assets200_response_spec.rb +0 -42
- data/spec/models/list_connections200_response_spec.rb +0 -42
- data/spec/models/list_endpoints200_response_spec.rb +0 -42
- data/spec/models/list_industries200_response_spec.rb +0 -42
- data/spec/models/list_job_functions200_response_spec.rb +0 -42
- data/spec/models/list_postgen_integrations200_response_spec.rb +0 -42
- data/spec/models/list_posts200_response_spec.rb +0 -42
- data/spec/models/list_storage_engines200_response_spec.rb +0 -42
- data/spec/models/list_users200_response_spec.rb +0 -42
- data/spec/models/post_publications_input_spec.rb +0 -84
- data/spec/models/post_publications_spec.rb +0 -102
- data/spec/models/post_publications_update_spec.rb +0 -84
- data/spec/models/postgen_integrations_input_spec.rb +0 -72
- data/spec/models/postgen_integrations_update_spec.rb +0 -72
- data/spec/models/posts_spec.rb +0 -186
- data/spec/models/posts_update_spec.rb +0 -168
- data/spec/models/storage_engines_spec.rb +0 -82
- data/spec/models/update_alerts200_response_data_spec.rb +0 -36
- data/spec/models/update_alerts200_response_spec.rb +0 -42
- data/spec/models/update_api_keys200_response_data_spec.rb +0 -36
- data/spec/models/update_api_keys200_response_spec.rb +0 -42
- data/spec/models/update_asset_price_history200_response_data_spec.rb +0 -36
- data/spec/models/update_asset_price_history200_response_spec.rb +0 -42
- data/spec/models/update_assets200_response_data_spec.rb +0 -36
- data/spec/models/update_assets200_response_spec.rb +0 -42
- data/spec/models/update_companies200_response_data_spec.rb +0 -36
- data/spec/models/update_companies200_response_spec.rb +0 -42
- data/spec/models/update_connections200_response_data_spec.rb +0 -36
- data/spec/models/update_connections200_response_spec.rb +0 -42
- data/spec/models/update_endpoints200_response_data_spec.rb +0 -36
- data/spec/models/update_endpoints200_response_spec.rb +0 -42
- data/spec/models/update_favorites200_response_data_spec.rb +0 -36
- data/spec/models/update_favorites200_response_spec.rb +0 -42
- data/spec/models/update_postgen_integrations200_response_data_spec.rb +0 -36
- data/spec/models/update_postgen_integrations200_response_spec.rb +0 -42
- data/spec/models/update_posts200_response_data_spec.rb +0 -36
- data/spec/models/update_posts200_response_spec.rb +0 -42
- data/spec/models/update_users200_response_data_spec.rb +0 -36
- data/spec/models/update_users200_response_spec.rb +0 -42
- data/spec/models/users_input_spec.rb +0 -76
- data/spec/models/users_spec.rb +0 -94
- data/spec/models/users_update_spec.rb +0 -76
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
|
|
4
4
|
#Auto-generated API documentation for REST services of the Spartera platform
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document:
|
|
6
|
+
The version of the OpenAPI document: 0.0.0
|
|
7
7
|
Contact: support@spartera.com
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
|
-
Generator version: 7.
|
|
9
|
+
Generator version: 7.13.0
|
|
10
10
|
|
|
11
11
|
=end
|
|
12
12
|
|
|
@@ -19,42 +19,29 @@ module SparteraApiSdk
|
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
|
-
# Get
|
|
23
|
-
# @param company_id [String]
|
|
22
|
+
# Get asset performance analytics Query params: start_date, end_date, limit, sort_by, include
|
|
23
|
+
# @param company_id [String]
|
|
24
24
|
# @param [Hash] opts the optional parameters
|
|
25
|
-
# @return [
|
|
26
|
-
def
|
|
27
|
-
data, _status_code, _headers =
|
|
25
|
+
# @return [Object]
|
|
26
|
+
def companies_company_id_analytics_assets_get(company_id, opts = {})
|
|
27
|
+
data, _status_code, _headers = companies_company_id_analytics_assets_get_with_http_info(company_id, opts)
|
|
28
28
|
data
|
|
29
29
|
end
|
|
30
30
|
|
|
31
|
-
# Get
|
|
32
|
-
# @param company_id [String]
|
|
31
|
+
# Get asset performance analytics Query params: start_date, end_date, limit, sort_by, include
|
|
32
|
+
# @param company_id [String]
|
|
33
33
|
# @param [Hash] opts the optional parameters
|
|
34
|
-
# @return [Array<(
|
|
35
|
-
def
|
|
34
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
35
|
+
def companies_company_id_analytics_assets_get_with_http_info(company_id, opts = {})
|
|
36
36
|
if @api_client.config.debugging
|
|
37
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
37
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_analytics_assets_get ...'
|
|
38
38
|
end
|
|
39
39
|
# verify the required parameter 'company_id' is set
|
|
40
40
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
41
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
42
|
-
end
|
|
43
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
44
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.get_companies_by_id, the character length must be smaller than or equal to 255.'
|
|
45
|
-
end
|
|
46
|
-
|
|
47
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
48
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.get_companies_by_id, the character length must be greater than or equal to 1.'
|
|
49
|
-
end
|
|
50
|
-
|
|
51
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
52
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
53
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.get_companies_by_id, must conform to the pattern #{pattern}."
|
|
41
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_analytics_assets_get"
|
|
54
42
|
end
|
|
55
|
-
|
|
56
43
|
# resource path
|
|
57
|
-
local_var_path = '/companies/{company_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
44
|
+
local_var_path = '/companies/{company_id}/analytics/assets'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
58
45
|
|
|
59
46
|
# query parameters
|
|
60
47
|
query_params = opts[:query_params] || {}
|
|
@@ -71,13 +58,13 @@ module SparteraApiSdk
|
|
|
71
58
|
post_body = opts[:debug_body]
|
|
72
59
|
|
|
73
60
|
# return_type
|
|
74
|
-
return_type = opts[:debug_return_type] || '
|
|
61
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
75
62
|
|
|
76
63
|
# auth_names
|
|
77
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
64
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
78
65
|
|
|
79
66
|
new_options = opts.merge(
|
|
80
|
-
:operation => :"CompaniesApi.
|
|
67
|
+
:operation => :"CompaniesApi.companies_company_id_analytics_assets_get",
|
|
81
68
|
:header_params => header_params,
|
|
82
69
|
:query_params => query_params,
|
|
83
70
|
:form_params => form_params,
|
|
@@ -88,89 +75,37 @@ module SparteraApiSdk
|
|
|
88
75
|
|
|
89
76
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
90
77
|
if @api_client.config.debugging
|
|
91
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
78
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_analytics_assets_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
92
79
|
end
|
|
93
80
|
return data, status_code, headers
|
|
94
81
|
end
|
|
95
82
|
|
|
96
|
-
# Get
|
|
97
|
-
# @param company_id [String]
|
|
83
|
+
# Get customer analytics including growth and segmentation Query params: start_date, end_date, group_by, segment_by
|
|
84
|
+
# @param company_id [String]
|
|
98
85
|
# @param [Hash] opts the optional parameters
|
|
99
|
-
# @
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
103
|
-
# @option opts [String] :search Search term to filter results
|
|
104
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
105
|
-
def list_companies(company_id, opts = {})
|
|
106
|
-
data, _status_code, _headers = list_companies_with_http_info(company_id, opts)
|
|
86
|
+
# @return [Object]
|
|
87
|
+
def companies_company_id_analytics_customers_get(company_id, opts = {})
|
|
88
|
+
data, _status_code, _headers = companies_company_id_analytics_customers_get_with_http_info(company_id, opts)
|
|
107
89
|
data
|
|
108
90
|
end
|
|
109
91
|
|
|
110
|
-
# Get
|
|
111
|
-
# @param company_id [String]
|
|
92
|
+
# Get customer analytics including growth and segmentation Query params: start_date, end_date, group_by, segment_by
|
|
93
|
+
# @param company_id [String]
|
|
112
94
|
# @param [Hash] opts the optional parameters
|
|
113
|
-
# @
|
|
114
|
-
|
|
115
|
-
# @option opts [String] :sort_by Field to sort by
|
|
116
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
117
|
-
# @option opts [String] :search Search term to filter results
|
|
118
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
119
|
-
def list_companies_with_http_info(company_id, opts = {})
|
|
95
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
96
|
+
def companies_company_id_analytics_customers_get_with_http_info(company_id, opts = {})
|
|
120
97
|
if @api_client.config.debugging
|
|
121
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
98
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_analytics_customers_get ...'
|
|
122
99
|
end
|
|
123
100
|
# verify the required parameter 'company_id' is set
|
|
124
101
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
125
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
126
|
-
end
|
|
127
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
128
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies, the character length must be smaller than or equal to 255.'
|
|
129
|
-
end
|
|
130
|
-
|
|
131
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
132
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies, the character length must be greater than or equal to 1.'
|
|
102
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_analytics_customers_get"
|
|
133
103
|
end
|
|
134
|
-
|
|
135
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
136
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
137
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies, must conform to the pattern #{pattern}."
|
|
138
|
-
end
|
|
139
|
-
|
|
140
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
141
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies, must be greater than or equal to 1.'
|
|
142
|
-
end
|
|
143
|
-
|
|
144
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
145
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies, must be smaller than or equal to 100.'
|
|
146
|
-
end
|
|
147
|
-
|
|
148
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
149
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies, must be greater than or equal to 1.'
|
|
150
|
-
end
|
|
151
|
-
|
|
152
|
-
allowable_values = ["asc", "desc"]
|
|
153
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
154
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
155
|
-
end
|
|
156
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
157
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies, the character length must be smaller than or equal to 255.'
|
|
158
|
-
end
|
|
159
|
-
|
|
160
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
161
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies, the character length must be greater than or equal to 1.'
|
|
162
|
-
end
|
|
163
|
-
|
|
164
104
|
# resource path
|
|
165
|
-
local_var_path = '/companies/{company_id}/
|
|
105
|
+
local_var_path = '/companies/{company_id}/analytics/customers'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
166
106
|
|
|
167
107
|
# query parameters
|
|
168
108
|
query_params = opts[:query_params] || {}
|
|
169
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
170
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
171
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
172
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
173
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
174
109
|
|
|
175
110
|
# header parameters
|
|
176
111
|
header_params = opts[:header_params] || {}
|
|
@@ -184,13 +119,13 @@ module SparteraApiSdk
|
|
|
184
119
|
post_body = opts[:debug_body]
|
|
185
120
|
|
|
186
121
|
# return_type
|
|
187
|
-
return_type = opts[:debug_return_type] || '
|
|
122
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
188
123
|
|
|
189
124
|
# auth_names
|
|
190
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
125
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
191
126
|
|
|
192
127
|
new_options = opts.merge(
|
|
193
|
-
:operation => :"CompaniesApi.
|
|
128
|
+
:operation => :"CompaniesApi.companies_company_id_analytics_customers_get",
|
|
194
129
|
:header_params => header_params,
|
|
195
130
|
:query_params => query_params,
|
|
196
131
|
:form_params => form_params,
|
|
@@ -201,89 +136,37 @@ module SparteraApiSdk
|
|
|
201
136
|
|
|
202
137
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
203
138
|
if @api_client.config.debugging
|
|
204
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
139
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_analytics_customers_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
205
140
|
end
|
|
206
141
|
return data, status_code, headers
|
|
207
142
|
end
|
|
208
143
|
|
|
209
|
-
# Get
|
|
210
|
-
# @param company_id [String]
|
|
144
|
+
# Get comprehensive dashboard analytics for seller dashboard Includes all metrics needed for dashboard charts in one call Query params: start_date, end_date, period (day/week/month/quarter)
|
|
145
|
+
# @param company_id [String]
|
|
211
146
|
# @param [Hash] opts the optional parameters
|
|
212
|
-
# @
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
216
|
-
# @option opts [String] :search Search term to filter results
|
|
217
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
218
|
-
def list_companies_analytics_assets(company_id, opts = {})
|
|
219
|
-
data, _status_code, _headers = list_companies_analytics_assets_with_http_info(company_id, opts)
|
|
147
|
+
# @return [Object]
|
|
148
|
+
def companies_company_id_analytics_dashboard_get(company_id, opts = {})
|
|
149
|
+
data, _status_code, _headers = companies_company_id_analytics_dashboard_get_with_http_info(company_id, opts)
|
|
220
150
|
data
|
|
221
151
|
end
|
|
222
152
|
|
|
223
|
-
# Get
|
|
224
|
-
# @param company_id [String]
|
|
153
|
+
# Get comprehensive dashboard analytics for seller dashboard Includes all metrics needed for dashboard charts in one call Query params: start_date, end_date, period (day/week/month/quarter)
|
|
154
|
+
# @param company_id [String]
|
|
225
155
|
# @param [Hash] opts the optional parameters
|
|
226
|
-
# @
|
|
227
|
-
|
|
228
|
-
# @option opts [String] :sort_by Field to sort by
|
|
229
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
230
|
-
# @option opts [String] :search Search term to filter results
|
|
231
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
232
|
-
def list_companies_analytics_assets_with_http_info(company_id, opts = {})
|
|
156
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
157
|
+
def companies_company_id_analytics_dashboard_get_with_http_info(company_id, opts = {})
|
|
233
158
|
if @api_client.config.debugging
|
|
234
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
159
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_analytics_dashboard_get ...'
|
|
235
160
|
end
|
|
236
161
|
# verify the required parameter 'company_id' is set
|
|
237
162
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
238
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
239
|
-
end
|
|
240
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
241
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_assets, the character length must be smaller than or equal to 255.'
|
|
242
|
-
end
|
|
243
|
-
|
|
244
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
245
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_assets, the character length must be greater than or equal to 1.'
|
|
246
|
-
end
|
|
247
|
-
|
|
248
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
249
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
250
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_analytics_assets, must conform to the pattern #{pattern}."
|
|
251
|
-
end
|
|
252
|
-
|
|
253
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
254
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_analytics_assets, must be greater than or equal to 1.'
|
|
255
|
-
end
|
|
256
|
-
|
|
257
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
258
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_assets, must be smaller than or equal to 100.'
|
|
259
|
-
end
|
|
260
|
-
|
|
261
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
262
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_assets, must be greater than or equal to 1.'
|
|
263
|
-
end
|
|
264
|
-
|
|
265
|
-
allowable_values = ["asc", "desc"]
|
|
266
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
267
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
268
|
-
end
|
|
269
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
270
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_assets, the character length must be smaller than or equal to 255.'
|
|
271
|
-
end
|
|
272
|
-
|
|
273
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
274
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_assets, the character length must be greater than or equal to 1.'
|
|
163
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_analytics_dashboard_get"
|
|
275
164
|
end
|
|
276
|
-
|
|
277
165
|
# resource path
|
|
278
|
-
local_var_path = '/companies/{company_id}/analytics/
|
|
166
|
+
local_var_path = '/companies/{company_id}/analytics/dashboard'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
279
167
|
|
|
280
168
|
# query parameters
|
|
281
169
|
query_params = opts[:query_params] || {}
|
|
282
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
283
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
284
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
285
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
286
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
287
170
|
|
|
288
171
|
# header parameters
|
|
289
172
|
header_params = opts[:header_params] || {}
|
|
@@ -297,13 +180,13 @@ module SparteraApiSdk
|
|
|
297
180
|
post_body = opts[:debug_body]
|
|
298
181
|
|
|
299
182
|
# return_type
|
|
300
|
-
return_type = opts[:debug_return_type] || '
|
|
183
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
301
184
|
|
|
302
185
|
# auth_names
|
|
303
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
186
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
304
187
|
|
|
305
188
|
new_options = opts.merge(
|
|
306
|
-
:operation => :"CompaniesApi.
|
|
189
|
+
:operation => :"CompaniesApi.companies_company_id_analytics_dashboard_get",
|
|
307
190
|
:header_params => header_params,
|
|
308
191
|
:query_params => query_params,
|
|
309
192
|
:form_params => form_params,
|
|
@@ -314,89 +197,37 @@ module SparteraApiSdk
|
|
|
314
197
|
|
|
315
198
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
316
199
|
if @api_client.config.debugging
|
|
317
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
200
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_analytics_dashboard_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
318
201
|
end
|
|
319
202
|
return data, status_code, headers
|
|
320
203
|
end
|
|
321
204
|
|
|
322
|
-
# Get
|
|
323
|
-
# @param company_id [String]
|
|
205
|
+
# Get sales over time analytics Query params: start_date, end_date, group_by (day/week/month/quarter), metrics
|
|
206
|
+
# @param company_id [String]
|
|
324
207
|
# @param [Hash] opts the optional parameters
|
|
325
|
-
# @
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
329
|
-
# @option opts [String] :search Search term to filter results
|
|
330
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
331
|
-
def list_companies_analytics_customers(company_id, opts = {})
|
|
332
|
-
data, _status_code, _headers = list_companies_analytics_customers_with_http_info(company_id, opts)
|
|
208
|
+
# @return [Object]
|
|
209
|
+
def companies_company_id_analytics_sales_get(company_id, opts = {})
|
|
210
|
+
data, _status_code, _headers = companies_company_id_analytics_sales_get_with_http_info(company_id, opts)
|
|
333
211
|
data
|
|
334
212
|
end
|
|
335
213
|
|
|
336
|
-
# Get
|
|
337
|
-
# @param company_id [String]
|
|
214
|
+
# Get sales over time analytics Query params: start_date, end_date, group_by (day/week/month/quarter), metrics
|
|
215
|
+
# @param company_id [String]
|
|
338
216
|
# @param [Hash] opts the optional parameters
|
|
339
|
-
# @
|
|
340
|
-
|
|
341
|
-
# @option opts [String] :sort_by Field to sort by
|
|
342
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
343
|
-
# @option opts [String] :search Search term to filter results
|
|
344
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
345
|
-
def list_companies_analytics_customers_with_http_info(company_id, opts = {})
|
|
217
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
218
|
+
def companies_company_id_analytics_sales_get_with_http_info(company_id, opts = {})
|
|
346
219
|
if @api_client.config.debugging
|
|
347
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
220
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_analytics_sales_get ...'
|
|
348
221
|
end
|
|
349
222
|
# verify the required parameter 'company_id' is set
|
|
350
223
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
351
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
352
|
-
end
|
|
353
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
354
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_customers, the character length must be smaller than or equal to 255.'
|
|
355
|
-
end
|
|
356
|
-
|
|
357
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
358
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_customers, the character length must be greater than or equal to 1.'
|
|
359
|
-
end
|
|
360
|
-
|
|
361
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
362
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
363
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_analytics_customers, must conform to the pattern #{pattern}."
|
|
364
|
-
end
|
|
365
|
-
|
|
366
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
367
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_analytics_customers, must be greater than or equal to 1.'
|
|
224
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_analytics_sales_get"
|
|
368
225
|
end
|
|
369
|
-
|
|
370
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
371
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_customers, must be smaller than or equal to 100.'
|
|
372
|
-
end
|
|
373
|
-
|
|
374
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
375
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_customers, must be greater than or equal to 1.'
|
|
376
|
-
end
|
|
377
|
-
|
|
378
|
-
allowable_values = ["asc", "desc"]
|
|
379
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
380
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
381
|
-
end
|
|
382
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
383
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_customers, the character length must be smaller than or equal to 255.'
|
|
384
|
-
end
|
|
385
|
-
|
|
386
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
387
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_customers, the character length must be greater than or equal to 1.'
|
|
388
|
-
end
|
|
389
|
-
|
|
390
226
|
# resource path
|
|
391
|
-
local_var_path = '/companies/{company_id}/analytics/
|
|
227
|
+
local_var_path = '/companies/{company_id}/analytics/sales'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
392
228
|
|
|
393
229
|
# query parameters
|
|
394
230
|
query_params = opts[:query_params] || {}
|
|
395
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
396
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
397
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
398
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
399
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
400
231
|
|
|
401
232
|
# header parameters
|
|
402
233
|
header_params = opts[:header_params] || {}
|
|
@@ -410,13 +241,13 @@ module SparteraApiSdk
|
|
|
410
241
|
post_body = opts[:debug_body]
|
|
411
242
|
|
|
412
243
|
# return_type
|
|
413
|
-
return_type = opts[:debug_return_type] || '
|
|
244
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
414
245
|
|
|
415
246
|
# auth_names
|
|
416
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
247
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
417
248
|
|
|
418
249
|
new_options = opts.merge(
|
|
419
|
-
:operation => :"CompaniesApi.
|
|
250
|
+
:operation => :"CompaniesApi.companies_company_id_analytics_sales_get",
|
|
420
251
|
:header_params => header_params,
|
|
421
252
|
:query_params => query_params,
|
|
422
253
|
:form_params => form_params,
|
|
@@ -427,89 +258,37 @@ module SparteraApiSdk
|
|
|
427
258
|
|
|
428
259
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
429
260
|
if @api_client.config.debugging
|
|
430
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
261
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_analytics_sales_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
431
262
|
end
|
|
432
263
|
return data, status_code, headers
|
|
433
264
|
end
|
|
434
265
|
|
|
435
|
-
# Get
|
|
436
|
-
# @param company_id [String]
|
|
266
|
+
# Get details of the requestor's own company
|
|
267
|
+
# @param company_id [String]
|
|
437
268
|
# @param [Hash] opts the optional parameters
|
|
438
|
-
# @
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
442
|
-
# @option opts [String] :search Search term to filter results
|
|
443
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
444
|
-
def list_companies_analytics_dashboard(company_id, opts = {})
|
|
445
|
-
data, _status_code, _headers = list_companies_analytics_dashboard_with_http_info(company_id, opts)
|
|
269
|
+
# @return [Object]
|
|
270
|
+
def companies_company_id_get(company_id, opts = {})
|
|
271
|
+
data, _status_code, _headers = companies_company_id_get_with_http_info(company_id, opts)
|
|
446
272
|
data
|
|
447
273
|
end
|
|
448
274
|
|
|
449
|
-
# Get
|
|
450
|
-
# @param company_id [String]
|
|
275
|
+
# Get details of the requestor's own company
|
|
276
|
+
# @param company_id [String]
|
|
451
277
|
# @param [Hash] opts the optional parameters
|
|
452
|
-
# @
|
|
453
|
-
|
|
454
|
-
# @option opts [String] :sort_by Field to sort by
|
|
455
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
456
|
-
# @option opts [String] :search Search term to filter results
|
|
457
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
458
|
-
def list_companies_analytics_dashboard_with_http_info(company_id, opts = {})
|
|
278
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
279
|
+
def companies_company_id_get_with_http_info(company_id, opts = {})
|
|
459
280
|
if @api_client.config.debugging
|
|
460
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
281
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_get ...'
|
|
461
282
|
end
|
|
462
283
|
# verify the required parameter 'company_id' is set
|
|
463
284
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
464
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
465
|
-
end
|
|
466
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
467
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_dashboard, the character length must be smaller than or equal to 255.'
|
|
285
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_get"
|
|
468
286
|
end
|
|
469
|
-
|
|
470
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
471
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_dashboard, the character length must be greater than or equal to 1.'
|
|
472
|
-
end
|
|
473
|
-
|
|
474
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
475
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
476
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_analytics_dashboard, must conform to the pattern #{pattern}."
|
|
477
|
-
end
|
|
478
|
-
|
|
479
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
480
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_analytics_dashboard, must be greater than or equal to 1.'
|
|
481
|
-
end
|
|
482
|
-
|
|
483
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
484
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_dashboard, must be smaller than or equal to 100.'
|
|
485
|
-
end
|
|
486
|
-
|
|
487
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
488
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_dashboard, must be greater than or equal to 1.'
|
|
489
|
-
end
|
|
490
|
-
|
|
491
|
-
allowable_values = ["asc", "desc"]
|
|
492
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
493
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
494
|
-
end
|
|
495
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
496
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_dashboard, the character length must be smaller than or equal to 255.'
|
|
497
|
-
end
|
|
498
|
-
|
|
499
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
500
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_dashboard, the character length must be greater than or equal to 1.'
|
|
501
|
-
end
|
|
502
|
-
|
|
503
287
|
# resource path
|
|
504
|
-
local_var_path = '/companies/{company_id}
|
|
288
|
+
local_var_path = '/companies/{company_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
505
289
|
|
|
506
290
|
# query parameters
|
|
507
291
|
query_params = opts[:query_params] || {}
|
|
508
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
509
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
510
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
511
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
512
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
513
292
|
|
|
514
293
|
# header parameters
|
|
515
294
|
header_params = opts[:header_params] || {}
|
|
@@ -523,13 +302,13 @@ module SparteraApiSdk
|
|
|
523
302
|
post_body = opts[:debug_body]
|
|
524
303
|
|
|
525
304
|
# return_type
|
|
526
|
-
return_type = opts[:debug_return_type] || '
|
|
305
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
527
306
|
|
|
528
307
|
# auth_names
|
|
529
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
308
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
530
309
|
|
|
531
310
|
new_options = opts.merge(
|
|
532
|
-
:operation => :"CompaniesApi.
|
|
311
|
+
:operation => :"CompaniesApi.companies_company_id_get",
|
|
533
312
|
:header_params => header_params,
|
|
534
313
|
:query_params => query_params,
|
|
535
314
|
:form_params => form_params,
|
|
@@ -540,89 +319,37 @@ module SparteraApiSdk
|
|
|
540
319
|
|
|
541
320
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
542
321
|
if @api_client.config.debugging
|
|
543
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
322
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
544
323
|
end
|
|
545
324
|
return data, status_code, headers
|
|
546
325
|
end
|
|
547
326
|
|
|
548
|
-
# Get
|
|
549
|
-
# @param company_id [String]
|
|
327
|
+
# Get all objects (connections, assets) of a single company
|
|
328
|
+
# @param company_id [String]
|
|
550
329
|
# @param [Hash] opts the optional parameters
|
|
551
|
-
# @
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
555
|
-
# @option opts [String] :search Search term to filter results
|
|
556
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
557
|
-
def list_companies_analytics_metrics(company_id, opts = {})
|
|
558
|
-
data, _status_code, _headers = list_companies_analytics_metrics_with_http_info(company_id, opts)
|
|
330
|
+
# @return [Object]
|
|
331
|
+
def companies_company_id_objects_get(company_id, opts = {})
|
|
332
|
+
data, _status_code, _headers = companies_company_id_objects_get_with_http_info(company_id, opts)
|
|
559
333
|
data
|
|
560
334
|
end
|
|
561
335
|
|
|
562
|
-
# Get
|
|
563
|
-
# @param company_id [String]
|
|
336
|
+
# Get all objects (connections, assets) of a single company
|
|
337
|
+
# @param company_id [String]
|
|
564
338
|
# @param [Hash] opts the optional parameters
|
|
565
|
-
# @
|
|
566
|
-
|
|
567
|
-
# @option opts [String] :sort_by Field to sort by
|
|
568
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
569
|
-
# @option opts [String] :search Search term to filter results
|
|
570
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
571
|
-
def list_companies_analytics_metrics_with_http_info(company_id, opts = {})
|
|
339
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
340
|
+
def companies_company_id_objects_get_with_http_info(company_id, opts = {})
|
|
572
341
|
if @api_client.config.debugging
|
|
573
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
342
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_objects_get ...'
|
|
574
343
|
end
|
|
575
344
|
# verify the required parameter 'company_id' is set
|
|
576
345
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
577
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
578
|
-
end
|
|
579
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
580
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_metrics, the character length must be smaller than or equal to 255.'
|
|
581
|
-
end
|
|
582
|
-
|
|
583
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
584
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_metrics, the character length must be greater than or equal to 1.'
|
|
585
|
-
end
|
|
586
|
-
|
|
587
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
588
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
589
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_analytics_metrics, must conform to the pattern #{pattern}."
|
|
590
|
-
end
|
|
591
|
-
|
|
592
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
593
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_analytics_metrics, must be greater than or equal to 1.'
|
|
594
|
-
end
|
|
595
|
-
|
|
596
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
597
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_metrics, must be smaller than or equal to 100.'
|
|
598
|
-
end
|
|
599
|
-
|
|
600
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
601
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_metrics, must be greater than or equal to 1.'
|
|
602
|
-
end
|
|
603
|
-
|
|
604
|
-
allowable_values = ["asc", "desc"]
|
|
605
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
606
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
607
|
-
end
|
|
608
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
609
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_metrics, the character length must be smaller than or equal to 255.'
|
|
610
|
-
end
|
|
611
|
-
|
|
612
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
613
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_metrics, the character length must be greater than or equal to 1.'
|
|
346
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_objects_get"
|
|
614
347
|
end
|
|
615
|
-
|
|
616
348
|
# resource path
|
|
617
|
-
local_var_path = '/companies/{company_id}/
|
|
349
|
+
local_var_path = '/companies/{company_id}/objects'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
618
350
|
|
|
619
351
|
# query parameters
|
|
620
352
|
query_params = opts[:query_params] || {}
|
|
621
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
622
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
623
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
624
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
625
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
626
353
|
|
|
627
354
|
# header parameters
|
|
628
355
|
header_params = opts[:header_params] || {}
|
|
@@ -636,13 +363,13 @@ module SparteraApiSdk
|
|
|
636
363
|
post_body = opts[:debug_body]
|
|
637
364
|
|
|
638
365
|
# return_type
|
|
639
|
-
return_type = opts[:debug_return_type] || '
|
|
366
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
640
367
|
|
|
641
368
|
# auth_names
|
|
642
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
369
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
643
370
|
|
|
644
371
|
new_options = opts.merge(
|
|
645
|
-
:operation => :"CompaniesApi.
|
|
372
|
+
:operation => :"CompaniesApi.companies_company_id_objects_get",
|
|
646
373
|
:header_params => header_params,
|
|
647
374
|
:query_params => query_params,
|
|
648
375
|
:form_params => form_params,
|
|
@@ -653,89 +380,37 @@ module SparteraApiSdk
|
|
|
653
380
|
|
|
654
381
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
655
382
|
if @api_client.config.debugging
|
|
656
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
383
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_objects_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
657
384
|
end
|
|
658
385
|
return data, status_code, headers
|
|
659
386
|
end
|
|
660
387
|
|
|
661
|
-
#
|
|
662
|
-
# @param company_id [String]
|
|
388
|
+
# Update an existing company by ID
|
|
389
|
+
# @param company_id [String]
|
|
663
390
|
# @param [Hash] opts the optional parameters
|
|
664
|
-
# @
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
668
|
-
# @option opts [String] :search Search term to filter results
|
|
669
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
670
|
-
def list_companies_analytics_sales(company_id, opts = {})
|
|
671
|
-
data, _status_code, _headers = list_companies_analytics_sales_with_http_info(company_id, opts)
|
|
391
|
+
# @return [Object]
|
|
392
|
+
def companies_company_id_patch(company_id, opts = {})
|
|
393
|
+
data, _status_code, _headers = companies_company_id_patch_with_http_info(company_id, opts)
|
|
672
394
|
data
|
|
673
395
|
end
|
|
674
396
|
|
|
675
|
-
#
|
|
676
|
-
# @param company_id [String]
|
|
397
|
+
# Update an existing company by ID
|
|
398
|
+
# @param company_id [String]
|
|
677
399
|
# @param [Hash] opts the optional parameters
|
|
678
|
-
# @
|
|
679
|
-
|
|
680
|
-
# @option opts [String] :sort_by Field to sort by
|
|
681
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
682
|
-
# @option opts [String] :search Search term to filter results
|
|
683
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
684
|
-
def list_companies_analytics_sales_with_http_info(company_id, opts = {})
|
|
400
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
401
|
+
def companies_company_id_patch_with_http_info(company_id, opts = {})
|
|
685
402
|
if @api_client.config.debugging
|
|
686
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
403
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_patch ...'
|
|
687
404
|
end
|
|
688
405
|
# verify the required parameter 'company_id' is set
|
|
689
406
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
690
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
691
|
-
end
|
|
692
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
693
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_sales, the character length must be smaller than or equal to 255.'
|
|
694
|
-
end
|
|
695
|
-
|
|
696
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
697
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_analytics_sales, the character length must be greater than or equal to 1.'
|
|
698
|
-
end
|
|
699
|
-
|
|
700
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
701
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
702
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_analytics_sales, must conform to the pattern #{pattern}."
|
|
703
|
-
end
|
|
704
|
-
|
|
705
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
706
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_analytics_sales, must be greater than or equal to 1.'
|
|
707
|
-
end
|
|
708
|
-
|
|
709
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
710
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_sales, must be smaller than or equal to 100.'
|
|
407
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_patch"
|
|
711
408
|
end
|
|
712
|
-
|
|
713
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
714
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_analytics_sales, must be greater than or equal to 1.'
|
|
715
|
-
end
|
|
716
|
-
|
|
717
|
-
allowable_values = ["asc", "desc"]
|
|
718
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
719
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
720
|
-
end
|
|
721
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
722
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_sales, the character length must be smaller than or equal to 255.'
|
|
723
|
-
end
|
|
724
|
-
|
|
725
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
726
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_analytics_sales, the character length must be greater than or equal to 1.'
|
|
727
|
-
end
|
|
728
|
-
|
|
729
409
|
# resource path
|
|
730
|
-
local_var_path = '/companies/{company_id}
|
|
410
|
+
local_var_path = '/companies/{company_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
731
411
|
|
|
732
412
|
# query parameters
|
|
733
413
|
query_params = opts[:query_params] || {}
|
|
734
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
735
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
736
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
737
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
738
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
739
414
|
|
|
740
415
|
# header parameters
|
|
741
416
|
header_params = opts[:header_params] || {}
|
|
@@ -749,13 +424,13 @@ module SparteraApiSdk
|
|
|
749
424
|
post_body = opts[:debug_body]
|
|
750
425
|
|
|
751
426
|
# return_type
|
|
752
|
-
return_type = opts[:debug_return_type] || '
|
|
427
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
753
428
|
|
|
754
429
|
# auth_names
|
|
755
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
430
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
756
431
|
|
|
757
432
|
new_options = opts.merge(
|
|
758
|
-
:operation => :"CompaniesApi.
|
|
433
|
+
:operation => :"CompaniesApi.companies_company_id_patch",
|
|
759
434
|
:header_params => header_params,
|
|
760
435
|
:query_params => query_params,
|
|
761
436
|
:form_params => form_params,
|
|
@@ -764,91 +439,39 @@ module SparteraApiSdk
|
|
|
764
439
|
:return_type => return_type
|
|
765
440
|
)
|
|
766
441
|
|
|
767
|
-
data, status_code, headers = @api_client.call_api(:
|
|
442
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
768
443
|
if @api_client.config.debugging
|
|
769
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
444
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_patch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
770
445
|
end
|
|
771
446
|
return data, status_code, headers
|
|
772
447
|
end
|
|
773
448
|
|
|
774
|
-
# Get
|
|
775
|
-
# @param company_id [String]
|
|
449
|
+
# Get the total number of requests allocated in the company's current subscription plan.
|
|
450
|
+
# @param company_id [String]
|
|
776
451
|
# @param [Hash] opts the optional parameters
|
|
777
|
-
# @
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
781
|
-
# @option opts [String] :search Search term to filter results
|
|
782
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
783
|
-
def list_companies_objects(company_id, opts = {})
|
|
784
|
-
data, _status_code, _headers = list_companies_objects_with_http_info(company_id, opts)
|
|
452
|
+
# @return [Object]
|
|
453
|
+
def companies_company_id_requests_plan_get(company_id, opts = {})
|
|
454
|
+
data, _status_code, _headers = companies_company_id_requests_plan_get_with_http_info(company_id, opts)
|
|
785
455
|
data
|
|
786
456
|
end
|
|
787
457
|
|
|
788
|
-
# Get
|
|
789
|
-
# @param company_id [String]
|
|
458
|
+
# Get the total number of requests allocated in the company's current subscription plan.
|
|
459
|
+
# @param company_id [String]
|
|
790
460
|
# @param [Hash] opts the optional parameters
|
|
791
|
-
# @
|
|
792
|
-
|
|
793
|
-
# @option opts [String] :sort_by Field to sort by
|
|
794
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
795
|
-
# @option opts [String] :search Search term to filter results
|
|
796
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
797
|
-
def list_companies_objects_with_http_info(company_id, opts = {})
|
|
461
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
462
|
+
def companies_company_id_requests_plan_get_with_http_info(company_id, opts = {})
|
|
798
463
|
if @api_client.config.debugging
|
|
799
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
464
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_requests_plan_get ...'
|
|
800
465
|
end
|
|
801
466
|
# verify the required parameter 'company_id' is set
|
|
802
467
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
803
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
804
|
-
end
|
|
805
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
806
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_objects, the character length must be smaller than or equal to 255.'
|
|
807
|
-
end
|
|
808
|
-
|
|
809
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
810
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_objects, the character length must be greater than or equal to 1.'
|
|
468
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_requests_plan_get"
|
|
811
469
|
end
|
|
812
|
-
|
|
813
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
814
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
815
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_objects, must conform to the pattern #{pattern}."
|
|
816
|
-
end
|
|
817
|
-
|
|
818
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
819
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_objects, must be greater than or equal to 1.'
|
|
820
|
-
end
|
|
821
|
-
|
|
822
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
823
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_objects, must be smaller than or equal to 100.'
|
|
824
|
-
end
|
|
825
|
-
|
|
826
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
827
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_objects, must be greater than or equal to 1.'
|
|
828
|
-
end
|
|
829
|
-
|
|
830
|
-
allowable_values = ["asc", "desc"]
|
|
831
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
832
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
833
|
-
end
|
|
834
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
835
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_objects, the character length must be smaller than or equal to 255.'
|
|
836
|
-
end
|
|
837
|
-
|
|
838
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
839
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_objects, the character length must be greater than or equal to 1.'
|
|
840
|
-
end
|
|
841
|
-
|
|
842
470
|
# resource path
|
|
843
|
-
local_var_path = '/companies/{company_id}/
|
|
471
|
+
local_var_path = '/companies/{company_id}/requests/plan'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
844
472
|
|
|
845
473
|
# query parameters
|
|
846
474
|
query_params = opts[:query_params] || {}
|
|
847
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
848
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
849
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
850
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
851
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
852
475
|
|
|
853
476
|
# header parameters
|
|
854
477
|
header_params = opts[:header_params] || {}
|
|
@@ -862,13 +485,13 @@ module SparteraApiSdk
|
|
|
862
485
|
post_body = opts[:debug_body]
|
|
863
486
|
|
|
864
487
|
# return_type
|
|
865
|
-
return_type = opts[:debug_return_type] || '
|
|
488
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
866
489
|
|
|
867
490
|
# auth_names
|
|
868
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
491
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
869
492
|
|
|
870
493
|
new_options = opts.merge(
|
|
871
|
-
:operation => :"CompaniesApi.
|
|
494
|
+
:operation => :"CompaniesApi.companies_company_id_requests_plan_get",
|
|
872
495
|
:header_params => header_params,
|
|
873
496
|
:query_params => query_params,
|
|
874
497
|
:form_params => form_params,
|
|
@@ -879,89 +502,37 @@ module SparteraApiSdk
|
|
|
879
502
|
|
|
880
503
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
881
504
|
if @api_client.config.debugging
|
|
882
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
505
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_requests_plan_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
883
506
|
end
|
|
884
507
|
return data, status_code, headers
|
|
885
508
|
end
|
|
886
509
|
|
|
887
|
-
# Get company request usage data for a specific month.
|
|
888
|
-
# @param company_id [String]
|
|
510
|
+
# Get company request usage data for a specific month. Returns JSON metrics by default or CSV logs when download parameter is included.
|
|
511
|
+
# @param company_id [String]
|
|
889
512
|
# @param [Hash] opts the optional parameters
|
|
890
|
-
# @
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
894
|
-
# @option opts [String] :search Search term to filter results
|
|
895
|
-
# @return [ListCompaniesAnalyticsAssets200Response]
|
|
896
|
-
def list_companies_requests_usage(company_id, opts = {})
|
|
897
|
-
data, _status_code, _headers = list_companies_requests_usage_with_http_info(company_id, opts)
|
|
513
|
+
# @return [Object]
|
|
514
|
+
def companies_company_id_requests_usage_get(company_id, opts = {})
|
|
515
|
+
data, _status_code, _headers = companies_company_id_requests_usage_get_with_http_info(company_id, opts)
|
|
898
516
|
data
|
|
899
517
|
end
|
|
900
518
|
|
|
901
|
-
# Get company request usage data for a specific month.
|
|
902
|
-
# @param company_id [String]
|
|
519
|
+
# Get company request usage data for a specific month. Returns JSON metrics by default or CSV logs when download parameter is included.
|
|
520
|
+
# @param company_id [String]
|
|
903
521
|
# @param [Hash] opts the optional parameters
|
|
904
|
-
# @
|
|
905
|
-
|
|
906
|
-
# @option opts [String] :sort_by Field to sort by
|
|
907
|
-
# @option opts [String] :sort_order Sort order (ascending or descending) (default to 'desc')
|
|
908
|
-
# @option opts [String] :search Search term to filter results
|
|
909
|
-
# @return [Array<(ListCompaniesAnalyticsAssets200Response, Integer, Hash)>] ListCompaniesAnalyticsAssets200Response data, response status code and response headers
|
|
910
|
-
def list_companies_requests_usage_with_http_info(company_id, opts = {})
|
|
522
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
523
|
+
def companies_company_id_requests_usage_get_with_http_info(company_id, opts = {})
|
|
911
524
|
if @api_client.config.debugging
|
|
912
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.
|
|
525
|
+
@api_client.config.logger.debug 'Calling API: CompaniesApi.companies_company_id_requests_usage_get ...'
|
|
913
526
|
end
|
|
914
527
|
# verify the required parameter 'company_id' is set
|
|
915
528
|
if @api_client.config.client_side_validation && company_id.nil?
|
|
916
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.
|
|
917
|
-
end
|
|
918
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
919
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_requests_usage, the character length must be smaller than or equal to 255.'
|
|
920
|
-
end
|
|
921
|
-
|
|
922
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
923
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.list_companies_requests_usage, the character length must be greater than or equal to 1.'
|
|
924
|
-
end
|
|
925
|
-
|
|
926
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
927
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
928
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.list_companies_requests_usage, must conform to the pattern #{pattern}."
|
|
929
|
-
end
|
|
930
|
-
|
|
931
|
-
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 1
|
|
932
|
-
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling CompaniesApi.list_companies_requests_usage, must be greater than or equal to 1.'
|
|
933
|
-
end
|
|
934
|
-
|
|
935
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
936
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_requests_usage, must be smaller than or equal to 100.'
|
|
937
|
-
end
|
|
938
|
-
|
|
939
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
940
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling CompaniesApi.list_companies_requests_usage, must be greater than or equal to 1.'
|
|
941
|
-
end
|
|
942
|
-
|
|
943
|
-
allowable_values = ["asc", "desc"]
|
|
944
|
-
if @api_client.config.client_side_validation && opts[:'sort_order'] && !allowable_values.include?(opts[:'sort_order'])
|
|
945
|
-
fail ArgumentError, "invalid value for \"sort_order\", must be one of #{allowable_values}"
|
|
946
|
-
end
|
|
947
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length > 255
|
|
948
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_requests_usage, the character length must be smaller than or equal to 255.'
|
|
949
|
-
end
|
|
950
|
-
|
|
951
|
-
if @api_client.config.client_side_validation && !opts[:'search'].nil? && opts[:'search'].to_s.length < 1
|
|
952
|
-
fail ArgumentError, 'invalid value for "opts[:"search"]" when calling CompaniesApi.list_companies_requests_usage, the character length must be greater than or equal to 1.'
|
|
529
|
+
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.companies_company_id_requests_usage_get"
|
|
953
530
|
end
|
|
954
|
-
|
|
955
531
|
# resource path
|
|
956
532
|
local_var_path = '/companies/{company_id}/requests/usage'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
957
533
|
|
|
958
534
|
# query parameters
|
|
959
535
|
query_params = opts[:query_params] || {}
|
|
960
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
961
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
962
|
-
query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
|
|
963
|
-
query_params[:'sort_order'] = opts[:'sort_order'] if !opts[:'sort_order'].nil?
|
|
964
|
-
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
965
536
|
|
|
966
537
|
# header parameters
|
|
967
538
|
header_params = opts[:header_params] || {}
|
|
@@ -975,13 +546,13 @@ module SparteraApiSdk
|
|
|
975
546
|
post_body = opts[:debug_body]
|
|
976
547
|
|
|
977
548
|
# return_type
|
|
978
|
-
return_type = opts[:debug_return_type] || '
|
|
549
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
979
550
|
|
|
980
551
|
# auth_names
|
|
981
|
-
auth_names = opts[:debug_auth_names] || ['
|
|
552
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
982
553
|
|
|
983
554
|
new_options = opts.merge(
|
|
984
|
-
:operation => :"CompaniesApi.
|
|
555
|
+
:operation => :"CompaniesApi.companies_company_id_requests_usage_get",
|
|
985
556
|
:header_params => header_params,
|
|
986
557
|
:query_params => query_params,
|
|
987
558
|
:form_params => form_params,
|
|
@@ -992,92 +563,7 @@ module SparteraApiSdk
|
|
|
992
563
|
|
|
993
564
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
994
565
|
if @api_client.config.debugging
|
|
995
|
-
@api_client.config.logger.debug "API called: CompaniesApi#
|
|
996
|
-
end
|
|
997
|
-
return data, status_code, headers
|
|
998
|
-
end
|
|
999
|
-
|
|
1000
|
-
# Update an existing company by ID
|
|
1001
|
-
# @param company_id [String] Unique identifier for the Company
|
|
1002
|
-
# @param companies_update [CompaniesUpdate]
|
|
1003
|
-
# @param [Hash] opts the optional parameters
|
|
1004
|
-
# @return [UpdateCompanies200Response]
|
|
1005
|
-
def update_companies(company_id, companies_update, opts = {})
|
|
1006
|
-
data, _status_code, _headers = update_companies_with_http_info(company_id, companies_update, opts)
|
|
1007
|
-
data
|
|
1008
|
-
end
|
|
1009
|
-
|
|
1010
|
-
# Update an existing company by ID
|
|
1011
|
-
# @param company_id [String] Unique identifier for the Company
|
|
1012
|
-
# @param companies_update [CompaniesUpdate]
|
|
1013
|
-
# @param [Hash] opts the optional parameters
|
|
1014
|
-
# @return [Array<(UpdateCompanies200Response, Integer, Hash)>] UpdateCompanies200Response data, response status code and response headers
|
|
1015
|
-
def update_companies_with_http_info(company_id, companies_update, opts = {})
|
|
1016
|
-
if @api_client.config.debugging
|
|
1017
|
-
@api_client.config.logger.debug 'Calling API: CompaniesApi.update_companies ...'
|
|
1018
|
-
end
|
|
1019
|
-
# verify the required parameter 'company_id' is set
|
|
1020
|
-
if @api_client.config.client_side_validation && company_id.nil?
|
|
1021
|
-
fail ArgumentError, "Missing the required parameter 'company_id' when calling CompaniesApi.update_companies"
|
|
1022
|
-
end
|
|
1023
|
-
if @api_client.config.client_side_validation && company_id.to_s.length > 255
|
|
1024
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.update_companies, the character length must be smaller than or equal to 255.'
|
|
1025
|
-
end
|
|
1026
|
-
|
|
1027
|
-
if @api_client.config.client_side_validation && company_id.to_s.length < 1
|
|
1028
|
-
fail ArgumentError, 'invalid value for "company_id" when calling CompaniesApi.update_companies, the character length must be greater than or equal to 1.'
|
|
1029
|
-
end
|
|
1030
|
-
|
|
1031
|
-
pattern = Regexp.new(/^[a-zA-Z0-9_-]+$/)
|
|
1032
|
-
if @api_client.config.client_side_validation && company_id !~ pattern
|
|
1033
|
-
fail ArgumentError, "invalid value for 'company_id' when calling CompaniesApi.update_companies, must conform to the pattern #{pattern}."
|
|
1034
|
-
end
|
|
1035
|
-
|
|
1036
|
-
# verify the required parameter 'companies_update' is set
|
|
1037
|
-
if @api_client.config.client_side_validation && companies_update.nil?
|
|
1038
|
-
fail ArgumentError, "Missing the required parameter 'companies_update' when calling CompaniesApi.update_companies"
|
|
1039
|
-
end
|
|
1040
|
-
# resource path
|
|
1041
|
-
local_var_path = '/companies/{company_id}'.sub('{' + 'company_id' + '}', CGI.escape(company_id.to_s))
|
|
1042
|
-
|
|
1043
|
-
# query parameters
|
|
1044
|
-
query_params = opts[:query_params] || {}
|
|
1045
|
-
|
|
1046
|
-
# header parameters
|
|
1047
|
-
header_params = opts[:header_params] || {}
|
|
1048
|
-
# HTTP header 'Accept' (if needed)
|
|
1049
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1050
|
-
# HTTP header 'Content-Type'
|
|
1051
|
-
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1052
|
-
if !content_type.nil?
|
|
1053
|
-
header_params['Content-Type'] = content_type
|
|
1054
|
-
end
|
|
1055
|
-
|
|
1056
|
-
# form parameters
|
|
1057
|
-
form_params = opts[:form_params] || {}
|
|
1058
|
-
|
|
1059
|
-
# http body (model)
|
|
1060
|
-
post_body = opts[:debug_body] || @api_client.object_to_http_body(companies_update)
|
|
1061
|
-
|
|
1062
|
-
# return_type
|
|
1063
|
-
return_type = opts[:debug_return_type] || 'UpdateCompanies200Response'
|
|
1064
|
-
|
|
1065
|
-
# auth_names
|
|
1066
|
-
auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
|
|
1067
|
-
|
|
1068
|
-
new_options = opts.merge(
|
|
1069
|
-
:operation => :"CompaniesApi.update_companies",
|
|
1070
|
-
:header_params => header_params,
|
|
1071
|
-
:query_params => query_params,
|
|
1072
|
-
:form_params => form_params,
|
|
1073
|
-
:body => post_body,
|
|
1074
|
-
:auth_names => auth_names,
|
|
1075
|
-
:return_type => return_type
|
|
1076
|
-
)
|
|
1077
|
-
|
|
1078
|
-
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
1079
|
-
if @api_client.config.debugging
|
|
1080
|
-
@api_client.config.logger.debug "API called: CompaniesApi#update_companies\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
566
|
+
@api_client.config.logger.debug "API called: CompaniesApi#companies_company_id_requests_usage_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1081
567
|
end
|
|
1082
568
|
return data, status_code, headers
|
|
1083
569
|
end
|