From 00cd2fe389db858e35fcbab063ab16e48645a9a3 Mon Sep 17 00:00:00 2001 From: Ian Duffy Date: Fri, 24 Apr 2026 14:31:17 +0100 Subject: [PATCH 1/2] feat: update bindings to v2.0.26 (API v1.1137.0) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- bindings/java/src/README.md | 19 +- bindings/java/src/build.gradle | 2 +- bindings/java/src/build.json | 2 +- bindings/java/src/build.sbt | 2 +- bindings/java/src/docs/AlpineUpstream.md | 24 + .../java/src/docs/AlpineUpstreamRequest.md | 11 + .../src/docs/AlpineUpstreamRequestPatch.md | 11 + bindings/java/src/docs/CargoUpstream.md | 1 + bindings/java/src/docs/ComposerUpstream.md | 1 + bindings/java/src/docs/CondaUpstream.md | 1 + bindings/java/src/docs/CranUpstream.md | 1 + bindings/java/src/docs/DartUpstream.md | 1 + bindings/java/src/docs/DebUpstream.md | 1 + bindings/java/src/docs/DockerUpstream.md | 1 + bindings/java/src/docs/EntitlementsApi.md | 66 + bindings/java/src/docs/GenericUpstream.md | 1 + bindings/java/src/docs/GoUpstream.md | 1 + bindings/java/src/docs/HelmUpstream.md | 1 + bindings/java/src/docs/HexUpstream.md | 1 + bindings/java/src/docs/HuggingfaceUpstream.md | 1 + bindings/java/src/docs/MavenUpstream.md | 1 + bindings/java/src/docs/McpPackageUpload.md | 107 + .../java/src/docs/McpPackageUploadRequest.md | 13 + bindings/java/src/docs/NpmUpstream.md | 1 + bindings/java/src/docs/NugetUpstream.md | 1 + bindings/java/src/docs/PackageRecycleBin.md | 20 + bindings/java/src/docs/PackagesApi.md | 129 + bindings/java/src/docs/PythonUpstream.md | 1 + bindings/java/src/docs/RecycleBinApi.md | 138 + bindings/java/src/docs/RecycleBinPackage.md | 47 + bindings/java/src/docs/ReposApi.md | 6 +- .../docs/RepositoryTokenPrivateBroadcasts.md | 10 + ...RepositoryTokenPrivateBroadcastsRequest.md | 10 + .../src/docs/RepositoryTokenRefreshRequest.md | 1 - .../java/src/docs/RepositoryTokenRequest.md | 1 - .../src/docs/RepositoryTokenRequestPatch.md | 1 - bindings/java/src/docs/RpmUpstream.md | 1 + bindings/java/src/docs/RubyUpstream.md | 1 + .../java/src/docs/StorageAllocatedLimit.md | 1 + .../java/src/docs/StorageAllocatedLimitRaw.md | 1 + bindings/java/src/docs/SwiftUpstream.md | 1 + bindings/java/src/pom.xml | 2 +- .../java/io/cloudsmith/api/ApiClient.java | 2 +- .../src/main/java/io/cloudsmith/api/JSON.java | 6 + .../cloudsmith/api/apis/EntitlementsApi.java | 151 ++ .../io/cloudsmith/api/apis/PackagesApi.java | 296 ++ .../io/cloudsmith/api/apis/RecycleBinApi.java | 376 +++ .../java/io/cloudsmith/api/apis/ReposApi.java | 12 +- .../cloudsmith/api/models/AlpineUpstream.java | 178 +- .../api/models/AlpineUpstreamRequest.java | 97 +- .../models/AlpineUpstreamRequestPatch.java | 97 +- .../cloudsmith/api/models/CargoUpstream.java | 2 + .../api/models/ComposerUpstream.java | 2 + .../cloudsmith/api/models/CondaUpstream.java | 2 + .../cloudsmith/api/models/CranUpstream.java | 2 + .../cloudsmith/api/models/DartUpstream.java | 2 + .../io/cloudsmith/api/models/DebUpstream.java | 2 + .../cloudsmith/api/models/DockerUpstream.java | 2 + .../api/models/GenericUpstream.java | 2 + .../io/cloudsmith/api/models/GoUpstream.java | 2 + .../cloudsmith/api/models/HelmUpstream.java | 2 + .../io/cloudsmith/api/models/HexUpstream.java | 2 + .../api/models/HuggingfaceUpstream.java | 2 + .../cloudsmith/api/models/MavenUpstream.java | 2 + .../api/models/McpPackageUpload.java | 1379 ++++++++++ .../api/models/McpPackageUploadRequest.java | 169 ++ .../io/cloudsmith/api/models/NpmUpstream.java | 2 + .../cloudsmith/api/models/NugetUpstream.java | 2 + .../api/models/PackageRecycleBin.java | 201 ++ .../cloudsmith/api/models/PythonUpstream.java | 2 + .../api/models/RecycleBinPackage.java | 489 ++++ .../api/models/RepositoryToken.java | 9 - .../RepositoryTokenPrivateBroadcasts.java | 100 + ...positoryTokenPrivateBroadcastsRequest.java | 100 + .../api/models/RepositoryTokenRefresh.java | 9 - .../models/RepositoryTokenRefreshRequest.java | 27 +- .../api/models/RepositoryTokenRequest.java | 27 +- .../models/RepositoryTokenRequestPatch.java | 27 +- .../io/cloudsmith/api/models/RpmUpstream.java | 2 + .../cloudsmith/api/models/RubyUpstream.java | 2 + .../api/models/StorageAllocatedLimit.java | 27 +- .../api/models/StorageAllocatedLimitRaw.java | 27 +- .../cloudsmith/api/models/SwiftUpstream.java | 2 + .../api/apis/EntitlementsApiTest.java | 20 + .../cloudsmith/api/apis/PackagesApiTest.java | 38 + .../api/apis/RecycleBinApiTest.java | 74 + .../io/cloudsmith/api/apis/ReposApiTest.java | 4 +- bindings/python/src/README.md | 15 +- bindings/python/src/build.json | 2 +- .../python/src/cloudsmith_api/__init__.py | 7 + .../python/src/cloudsmith_api/api/__init__.py | 1 + .../cloudsmith_api/api/entitlements_api.py | 119 + .../src/cloudsmith_api/api/packages_api.py | 222 ++ .../src/cloudsmith_api/api/recycle_bin_api.py | 248 ++ .../src/cloudsmith_api/api/repos_api.py | 8 +- .../python/src/cloudsmith_api/api_client.py | 2 +- .../src/cloudsmith_api/configuration.py | 2 +- .../src/cloudsmith_api/models/__init__.py | 6 + .../cloudsmith_api/models/alpine_upstream.py | 133 +- .../models/alpine_upstream_request.py | 68 +- .../models/alpine_upstream_request_patch.py | 68 +- .../cloudsmith_api/models/cargo_upstream.py | 2 +- .../models/composer_upstream.py | 2 +- .../cloudsmith_api/models/conda_upstream.py | 2 +- .../cloudsmith_api/models/cran_upstream.py | 2 +- .../cloudsmith_api/models/dart_upstream.py | 2 +- .../src/cloudsmith_api/models/deb_upstream.py | 2 +- .../cloudsmith_api/models/docker_upstream.py | 2 +- .../cloudsmith_api/models/generic_upstream.py | 2 +- .../src/cloudsmith_api/models/go_upstream.py | 2 +- .../cloudsmith_api/models/helm_upstream.py | 2 +- .../src/cloudsmith_api/models/hex_upstream.py | 2 +- .../models/huggingface_upstream.py | 2 +- .../cloudsmith_api/models/maven_upstream.py | 2 +- .../models/mcp_package_upload.py | 2396 +++++++++++++++++ .../models/mcp_package_upload_request.py | 223 ++ .../src/cloudsmith_api/models/npm_upstream.py | 2 +- .../cloudsmith_api/models/nuget_upstream.py | 2 +- .../models/package_recycle_bin.py | 197 ++ .../cloudsmith_api/models/python_upstream.py | 2 +- .../models/recycle_bin_package.py | 775 ++++++ .../repository_token_private_broadcasts.py | 127 + ...sitory_token_private_broadcasts_request.py | 127 + .../repository_token_refresh_request.py | 30 +- .../models/repository_token_request.py | 30 +- .../models/repository_token_request_patch.py | 30 +- .../src/cloudsmith_api/models/rpm_upstream.py | 2 +- .../cloudsmith_api/models/ruby_upstream.py | 2 +- .../models/storage_allocated_limit.py | 38 +- .../models/storage_allocated_limit_raw.py | 32 +- .../cloudsmith_api/models/swift_upstream.py | 2 +- bindings/python/src/docs/AlpineUpstream.md | 4 + .../python/src/docs/AlpineUpstreamRequest.md | 2 + .../src/docs/AlpineUpstreamRequestPatch.md | 2 + bindings/python/src/docs/EntitlementsApi.md | 64 + bindings/python/src/docs/McpPackageUpload.md | 93 + .../src/docs/McpPackageUploadRequest.md | 13 + bindings/python/src/docs/PackageRecycleBin.md | 12 + bindings/python/src/docs/PackagesApi.md | 125 + bindings/python/src/docs/RecycleBinApi.md | 133 + bindings/python/src/docs/RecycleBinPackage.md | 33 + bindings/python/src/docs/ReposApi.md | 7 +- .../docs/RepositoryTokenPrivateBroadcasts.md | 10 + ...RepositoryTokenPrivateBroadcastsRequest.md | 10 + .../src/docs/RepositoryTokenRefreshRequest.md | 1 - .../python/src/docs/RepositoryTokenRequest.md | 1 - .../src/docs/RepositoryTokenRequestPatch.md | 1 - .../python/src/docs/StorageAllocatedLimit.md | 1 + .../src/docs/StorageAllocatedLimitRaw.md | 1 + bindings/python/src/setup.py | 2 +- .../python/src/test/test_entitlements_api.py | 7 + .../src/test/test_mcp_package_upload.py | 40 + .../test/test_mcp_package_upload_request.py | 40 + .../src/test/test_package_recycle_bin.py | 40 + bindings/python/src/test/test_packages_api.py | 14 + .../python/src/test/test_recycle_bin_api.py | 47 + .../src/test/test_recycle_bin_package.py | 40 + bindings/python/src/test/test_repos_api.py | 1 - ...est_repository_token_private_broadcasts.py | 40 + ...sitory_token_private_broadcasts_request.py | 40 + bindings/ruby/src/README.md | 21 +- bindings/ruby/src/build.json | 2 +- bindings/ruby/src/docs/AlpineUpstream.md | 4 + .../ruby/src/docs/AlpineUpstreamRequest.md | 2 + .../src/docs/AlpineUpstreamRequestPatch.md | 2 + bindings/ruby/src/docs/EntitlementsApi.md | 68 + bindings/ruby/src/docs/McpPackageUpload.md | 91 + .../ruby/src/docs/McpPackageUploadRequest.md | 11 + bindings/ruby/src/docs/PackageRecycleBin.md | 10 + bindings/ruby/src/docs/PackagesApi.md | 131 + bindings/ruby/src/docs/RecycleBinApi.md | 137 + bindings/ruby/src/docs/RecycleBinPackage.md | 31 + bindings/ruby/src/docs/ReposApi.md | 7 +- .../docs/RepositoryTokenPrivateBroadcasts.md | 8 + ...RepositoryTokenPrivateBroadcastsRequest.md | 8 + .../src/docs/RepositoryTokenRefreshRequest.md | 1 - .../ruby/src/docs/RepositoryTokenRequest.md | 1 - .../src/docs/RepositoryTokenRequestPatch.md | 1 - .../ruby/src/docs/StorageAllocatedLimit.md | 1 + .../ruby/src/docs/StorageAllocatedLimitRaw.md | 1 + bindings/ruby/src/lib/cloudsmith-api.rb | 7 + .../cloudsmith-api/api/entitlements_api.rb | 67 + .../lib/cloudsmith-api/api/packages_api.rb | 123 + .../lib/cloudsmith-api/api/recycle_bin_api.rb | 140 + .../src/lib/cloudsmith-api/api/repos_api.rb | 6 +- .../cloudsmith-api/models/alpine_upstream.rb | 74 +- .../models/alpine_upstream_request.rb | 36 +- .../models/alpine_upstream_request_patch.rb | 36 +- .../cloudsmith-api/models/cargo_upstream.rb | 4 +- .../models/composer_upstream.rb | 4 +- .../cloudsmith-api/models/conda_upstream.rb | 4 +- .../cloudsmith-api/models/cran_upstream.rb | 4 +- .../cloudsmith-api/models/dart_upstream.rb | 4 +- .../lib/cloudsmith-api/models/deb_upstream.rb | 4 +- .../cloudsmith-api/models/docker_upstream.rb | 4 +- .../cloudsmith-api/models/generic_upstream.rb | 4 +- .../lib/cloudsmith-api/models/go_upstream.rb | 4 +- .../cloudsmith-api/models/helm_upstream.rb | 4 +- .../lib/cloudsmith-api/models/hex_upstream.rb | 4 +- .../models/huggingface_upstream.rb | 4 +- .../cloudsmith-api/models/maven_upstream.rb | 4 +- .../models/mcp_package_upload.rb | 1001 +++++++ .../models/mcp_package_upload_request.rb | 220 ++ .../lib/cloudsmith-api/models/npm_upstream.rb | 4 +- .../cloudsmith-api/models/nuget_upstream.rb | 4 +- .../models/package_recycle_bin.rb | 251 ++ .../cloudsmith-api/models/python_upstream.rb | 4 +- .../models/recycle_bin_package.rb | 442 +++ .../repository_token_private_broadcasts.rb | 190 ++ ...sitory_token_private_broadcasts_request.rb | 190 ++ .../repository_token_refresh_request.rb | 12 +- .../models/repository_token_request.rb | 12 +- .../models/repository_token_request_patch.rb | 12 +- .../lib/cloudsmith-api/models/rpm_upstream.rb | 4 +- .../cloudsmith-api/models/ruby_upstream.rb | 4 +- .../models/storage_allocated_limit.rb | 17 +- .../models/storage_allocated_limit_raw.rb | 17 +- .../cloudsmith-api/models/swift_upstream.rb | 4 +- .../ruby/src/lib/cloudsmith-api/version.rb | 2 +- .../src/spec/api/entitlements_api_spec.rb | 15 + .../ruby/src/spec/api/packages_api_spec.rb | 28 + .../ruby/src/spec/api/recycle_bin_api_spec.rb | 62 + bindings/ruby/src/spec/api/repos_api_spec.rb | 3 +- .../alpine_upstream_request_patch_spec.rb | 16 + .../models/alpine_upstream_request_spec.rb | 16 + .../src/spec/models/alpine_upstream_spec.rb | 34 +- .../src/spec/models/cargo_upstream_spec.rb | 2 +- .../src/spec/models/composer_upstream_spec.rb | 2 +- .../src/spec/models/conda_upstream_spec.rb | 2 +- .../src/spec/models/cran_upstream_spec.rb | 2 +- .../src/spec/models/dart_upstream_spec.rb | 2 +- .../ruby/src/spec/models/deb_upstream_spec.rb | 2 +- .../src/spec/models/docker_upstream_spec.rb | 2 +- .../src/spec/models/generic_upstream_spec.rb | 2 +- .../ruby/src/spec/models/go_upstream_spec.rb | 2 +- .../src/spec/models/helm_upstream_spec.rb | 2 +- .../ruby/src/spec/models/hex_upstream_spec.rb | 2 +- .../spec/models/huggingface_upstream_spec.rb | 2 +- .../src/spec/models/maven_upstream_spec.rb | 2 +- .../models/mcp_package_upload_request_spec.rb | 59 + .../spec/models/mcp_package_upload_spec.rb | 543 ++++ .../ruby/src/spec/models/npm_upstream_spec.rb | 2 +- .../src/spec/models/nuget_upstream_spec.rb | 2 +- .../spec/models/package_recycle_bin_spec.rb | 57 + .../src/spec/models/python_upstream_spec.rb | 2 +- .../spec/models/recycle_bin_package_spec.rb | 183 ++ ...y_token_private_broadcasts_request_spec.rb | 41 + ...epository_token_private_broadcasts_spec.rb | 41 + .../repository_token_refresh_request_spec.rb | 6 - .../repository_token_request_patch_spec.rb | 6 - .../models/repository_token_request_spec.rb | 6 - .../ruby/src/spec/models/rpm_upstream_spec.rb | 2 +- .../src/spec/models/ruby_upstream_spec.rb | 2 +- .../storage_allocated_limit_raw_spec.rb | 6 + .../models/storage_allocated_limit_spec.rb | 6 + .../src/spec/models/swift_upstream_spec.rb | 2 +- scripts/common.sh | 2 +- 257 files changed, 14628 insertions(+), 400 deletions(-) create mode 100644 bindings/java/src/docs/McpPackageUpload.md create mode 100644 bindings/java/src/docs/McpPackageUploadRequest.md create mode 100644 bindings/java/src/docs/PackageRecycleBin.md create mode 100644 bindings/java/src/docs/RecycleBinApi.md create mode 100644 bindings/java/src/docs/RecycleBinPackage.md create mode 100644 bindings/java/src/docs/RepositoryTokenPrivateBroadcasts.md create mode 100644 bindings/java/src/docs/RepositoryTokenPrivateBroadcastsRequest.md create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/apis/RecycleBinApi.java create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUpload.java create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUploadRequest.java create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/models/PackageRecycleBin.java create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/models/RecycleBinPackage.java create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcasts.java create mode 100644 bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcastsRequest.java create mode 100644 bindings/java/src/src/test/java/io/cloudsmith/api/apis/RecycleBinApiTest.java create mode 100644 bindings/python/src/cloudsmith_api/api/recycle_bin_api.py create mode 100644 bindings/python/src/cloudsmith_api/models/mcp_package_upload.py create mode 100644 bindings/python/src/cloudsmith_api/models/mcp_package_upload_request.py create mode 100644 bindings/python/src/cloudsmith_api/models/package_recycle_bin.py create mode 100644 bindings/python/src/cloudsmith_api/models/recycle_bin_package.py create mode 100644 bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts.py create mode 100644 bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts_request.py create mode 100644 bindings/python/src/docs/McpPackageUpload.md create mode 100644 bindings/python/src/docs/McpPackageUploadRequest.md create mode 100644 bindings/python/src/docs/PackageRecycleBin.md create mode 100644 bindings/python/src/docs/RecycleBinApi.md create mode 100644 bindings/python/src/docs/RecycleBinPackage.md create mode 100644 bindings/python/src/docs/RepositoryTokenPrivateBroadcasts.md create mode 100644 bindings/python/src/docs/RepositoryTokenPrivateBroadcastsRequest.md create mode 100644 bindings/python/src/test/test_mcp_package_upload.py create mode 100644 bindings/python/src/test/test_mcp_package_upload_request.py create mode 100644 bindings/python/src/test/test_package_recycle_bin.py create mode 100644 bindings/python/src/test/test_recycle_bin_api.py create mode 100644 bindings/python/src/test/test_recycle_bin_package.py create mode 100644 bindings/python/src/test/test_repository_token_private_broadcasts.py create mode 100644 bindings/python/src/test/test_repository_token_private_broadcasts_request.py create mode 100644 bindings/ruby/src/docs/McpPackageUpload.md create mode 100644 bindings/ruby/src/docs/McpPackageUploadRequest.md create mode 100644 bindings/ruby/src/docs/PackageRecycleBin.md create mode 100644 bindings/ruby/src/docs/RecycleBinApi.md create mode 100644 bindings/ruby/src/docs/RecycleBinPackage.md create mode 100644 bindings/ruby/src/docs/RepositoryTokenPrivateBroadcasts.md create mode 100644 bindings/ruby/src/docs/RepositoryTokenPrivateBroadcastsRequest.md create mode 100644 bindings/ruby/src/lib/cloudsmith-api/api/recycle_bin_api.rb create mode 100644 bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload.rb create mode 100644 bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload_request.rb create mode 100644 bindings/ruby/src/lib/cloudsmith-api/models/package_recycle_bin.rb create mode 100644 bindings/ruby/src/lib/cloudsmith-api/models/recycle_bin_package.rb create mode 100644 bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts.rb create mode 100644 bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts_request.rb create mode 100644 bindings/ruby/src/spec/api/recycle_bin_api_spec.rb create mode 100644 bindings/ruby/src/spec/models/mcp_package_upload_request_spec.rb create mode 100644 bindings/ruby/src/spec/models/mcp_package_upload_spec.rb create mode 100644 bindings/ruby/src/spec/models/package_recycle_bin_spec.rb create mode 100644 bindings/ruby/src/spec/models/recycle_bin_package_spec.rb create mode 100644 bindings/ruby/src/spec/models/repository_token_private_broadcasts_request_spec.rb create mode 100644 bindings/ruby/src/spec/models/repository_token_private_broadcasts_spec.rb diff --git a/bindings/java/src/README.md b/bindings/java/src/README.md index d45a5fda..c66ce0cc 100644 --- a/bindings/java/src/README.md +++ b/bindings/java/src/README.md @@ -40,7 +40,7 @@ Add this dependency to your project's POM: io.cloudsmith.api cloudsmith-api - 2.0.25 + 2.0.26 compile ``` @@ -50,7 +50,7 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "io.cloudsmith.api:cloudsmith-api:2.0.25" +compile "io.cloudsmith.api:cloudsmith-api:2.0.26" ``` ### Others @@ -63,7 +63,7 @@ mvn clean package Then manually install the following JARs: -* `target/cloudsmith-api-2.0.25.jar` +* `target/cloudsmith-api-2.0.26.jar` * `target/lib/*.jar` ## Getting Started @@ -136,6 +136,7 @@ Class | Method | HTTP request | Description *EntitlementsApi* | [**entitlementsRefresh**](docs/EntitlementsApi.md#entitlementsRefresh) | **POST** /entitlements/{owner}/{repo}/{identifier}/refresh/ | Refresh an entitlement token in a repository. *EntitlementsApi* | [**entitlementsReset**](docs/EntitlementsApi.md#entitlementsReset) | **POST** /entitlements/{owner}/{repo}/{identifier}/reset/ | Reset the statistics for an entitlement token in a repository. *EntitlementsApi* | [**entitlementsSync**](docs/EntitlementsApi.md#entitlementsSync) | **POST** /entitlements/{owner}/{repo}/sync/ | Synchronise tokens from a source repository. +*EntitlementsApi* | [**entitlementsTogglePrivateBroadcasts**](docs/EntitlementsApi.md#entitlementsTogglePrivateBroadcasts) | **POST** /entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/ | Set private broadcast access for an entitlement token in a repository. *FilesApi* | [**filesAbort**](docs/FilesApi.md#filesAbort) | **POST** /files/{owner}/{repo}/{identifier}/abort/ | Abort a multipart file upload. *FilesApi* | [**filesComplete**](docs/FilesApi.md#filesComplete) | **POST** /files/{owner}/{repo}/{identifier}/complete/ | Complete a multipart file upload. *FilesApi* | [**filesCreate**](docs/FilesApi.md#filesCreate) | **POST** /files/{owner}/{repo}/ | Request URL(s) to upload new package file upload(s) to. @@ -251,6 +252,7 @@ Class | Method | HTTP request | Description *PackagesApi* | [**packagesUploadHuggingface**](docs/PackagesApi.md#packagesUploadHuggingface) | **POST** /packages/{owner}/{repo}/upload/huggingface/ | Create a new HuggingFace package *PackagesApi* | [**packagesUploadLuarocks**](docs/PackagesApi.md#packagesUploadLuarocks) | **POST** /packages/{owner}/{repo}/upload/luarocks/ | Create a new LuaRocks package *PackagesApi* | [**packagesUploadMaven**](docs/PackagesApi.md#packagesUploadMaven) | **POST** /packages/{owner}/{repo}/upload/maven/ | Create a new Maven package +*PackagesApi* | [**packagesUploadMcp**](docs/PackagesApi.md#packagesUploadMcp) | **POST** /packages/{owner}/{repo}/upload/mcp/ | Create a new MCP package *PackagesApi* | [**packagesUploadNpm**](docs/PackagesApi.md#packagesUploadNpm) | **POST** /packages/{owner}/{repo}/upload/npm/ | Create a new npm package *PackagesApi* | [**packagesUploadNuget**](docs/PackagesApi.md#packagesUploadNuget) | **POST** /packages/{owner}/{repo}/upload/nuget/ | Create a new NuGet package *PackagesApi* | [**packagesUploadP2**](docs/PackagesApi.md#packagesUploadP2) | **POST** /packages/{owner}/{repo}/upload/p2/ | Create a new P2 package @@ -279,6 +281,7 @@ Class | Method | HTTP request | Description *PackagesApi* | [**packagesValidateUploadHuggingface**](docs/PackagesApi.md#packagesValidateUploadHuggingface) | **POST** /packages/{owner}/{repo}/validate-upload/huggingface/ | Validate parameters for create HuggingFace package *PackagesApi* | [**packagesValidateUploadLuarocks**](docs/PackagesApi.md#packagesValidateUploadLuarocks) | **POST** /packages/{owner}/{repo}/validate-upload/luarocks/ | Validate parameters for create LuaRocks package *PackagesApi* | [**packagesValidateUploadMaven**](docs/PackagesApi.md#packagesValidateUploadMaven) | **POST** /packages/{owner}/{repo}/validate-upload/maven/ | Validate parameters for create Maven package +*PackagesApi* | [**packagesValidateUploadMcp**](docs/PackagesApi.md#packagesValidateUploadMcp) | **POST** /packages/{owner}/{repo}/validate-upload/mcp/ | Validate parameters for create MCP package *PackagesApi* | [**packagesValidateUploadNpm**](docs/PackagesApi.md#packagesValidateUploadNpm) | **POST** /packages/{owner}/{repo}/validate-upload/npm/ | Validate parameters for create npm package *PackagesApi* | [**packagesValidateUploadNuget**](docs/PackagesApi.md#packagesValidateUploadNuget) | **POST** /packages/{owner}/{repo}/validate-upload/nuget/ | Validate parameters for create NuGet package *PackagesApi* | [**packagesValidateUploadP2**](docs/PackagesApi.md#packagesValidateUploadP2) | **POST** /packages/{owner}/{repo}/validate-upload/p2/ | Validate parameters for create P2 package @@ -295,11 +298,13 @@ Class | Method | HTTP request | Description *QuotaApi* | [**quotaOssRead**](docs/QuotaApi.md#quotaOssRead) | **GET** /quota/oss/{owner}/ | Open-source Quota usage for a given namespace. *QuotaApi* | [**quotaRead**](docs/QuotaApi.md#quotaRead) | **GET** /quota/{owner}/ | Quota usage for a given namespace. *RatesApi* | [**ratesLimitsList**](docs/RatesApi.md#ratesLimitsList) | **GET** /rates/limits/ | Endpoint to check rate limits for current user. +*RecycleBinApi* | [**recycleBinList**](docs/RecycleBinApi.md#recycleBinList) | **GET** /recycle-bin/{owner}/ | List soft-deleted packages in recycle bin +*RecycleBinApi* | [**recycleBinRecycleBinAction**](docs/RecycleBinApi.md#recycleBinRecycleBinAction) | **POST** /recycle-bin/{owner}/action/ | *ReposApi* | [**apiReposGeoipStatus**](docs/ReposApi.md#apiReposGeoipStatus) | **GET** /repos/{owner}/{identifier}/geoip/status/ | Retrieve the GeoIP status for this repository. *ReposApi* | [**repoRetentionPartialUpdate**](docs/ReposApi.md#repoRetentionPartialUpdate) | **PATCH** /repos/{owner}/{repo}/retention/ | Update the retention rules for the repository. *ReposApi* | [**repoRetentionRead**](docs/ReposApi.md#repoRetentionRead) | **GET** /repos/{owner}/{repo}/retention/ | Retrieve the retention rules for the repository. *ReposApi* | [**reposCreate**](docs/ReposApi.md#reposCreate) | **POST** /repos/{owner}/ | Create a new repository in a given namespace. -*ReposApi* | [**reposDelete**](docs/ReposApi.md#reposDelete) | **DELETE** /repos/{owner}/{identifier}/ | Delete a repository in a given namespace. +*ReposApi* | [**reposDelete**](docs/ReposApi.md#reposDelete) | **DELETE** /repos/{owner}/{identifier}/ | *ReposApi* | [**reposEcdsaCreate**](docs/ReposApi.md#reposEcdsaCreate) | **POST** /repos/{owner}/{identifier}/ecdsa/ | Set the active ECDSA key for the Repository. *ReposApi* | [**reposEcdsaList**](docs/ReposApi.md#reposEcdsaList) | **GET** /repos/{owner}/{identifier}/ecdsa/ | Retrieve the active ECDSA key for the Repository. *ReposApi* | [**reposEcdsaRegenerate**](docs/ReposApi.md#reposEcdsaRegenerate) | **POST** /repos/{owner}/{identifier}/ecdsa/regenerate/ | Regenerate ECDSA Key for the Repository. @@ -569,6 +574,8 @@ Class | Method | HTTP request | Description - [MavenUpstream](docs/MavenUpstream.md) - [MavenUpstreamRequest](docs/MavenUpstreamRequest.md) - [MavenUpstreamRequestPatch](docs/MavenUpstreamRequestPatch.md) + - [McpPackageUpload](docs/McpPackageUpload.md) + - [McpPackageUploadRequest](docs/McpPackageUploadRequest.md) - [ModelPackage](docs/ModelPackage.md) - [Namespace](docs/Namespace.md) - [NamespaceAuditLog](docs/NamespaceAuditLog.md) @@ -640,6 +647,7 @@ Class | Method | HTTP request | Description - [PackageMoveRequest](docs/PackageMoveRequest.md) - [PackageQuarantine](docs/PackageQuarantine.md) - [PackageQuarantineRequest](docs/PackageQuarantineRequest.md) + - [PackageRecycleBin](docs/PackageRecycleBin.md) - [PackageResync](docs/PackageResync.md) - [PackageStatus](docs/PackageStatus.md) - [PackageTag](docs/PackageTag.md) @@ -665,6 +673,7 @@ Class | Method | HTTP request | Description - [RateCheck](docs/RateCheck.md) - [RawPackageUpload](docs/RawPackageUpload.md) - [RawPackageUploadRequest](docs/RawPackageUploadRequest.md) + - [RecycleBinPackage](docs/RecycleBinPackage.md) - [Repository](docs/Repository.md) - [RepositoryAuditLog](docs/RepositoryAuditLog.md) - [RepositoryCreate](docs/RepositoryCreate.md) @@ -693,6 +702,8 @@ Class | Method | HTTP request | Description - [RepositoryRsaKeyCreate](docs/RepositoryRsaKeyCreate.md) - [RepositoryToken](docs/RepositoryToken.md) - [RepositoryTokenAction](docs/RepositoryTokenAction.md) + - [RepositoryTokenPrivateBroadcasts](docs/RepositoryTokenPrivateBroadcasts.md) + - [RepositoryTokenPrivateBroadcastsRequest](docs/RepositoryTokenPrivateBroadcastsRequest.md) - [RepositoryTokenRefresh](docs/RepositoryTokenRefresh.md) - [RepositoryTokenRefreshRequest](docs/RepositoryTokenRefreshRequest.md) - [RepositoryTokenRequest](docs/RepositoryTokenRequest.md) diff --git a/bindings/java/src/build.gradle b/bindings/java/src/build.gradle index 3a918320..886b6a70 100644 --- a/bindings/java/src/build.gradle +++ b/bindings/java/src/build.gradle @@ -2,7 +2,7 @@ apply plugin: 'idea' apply plugin: 'eclipse' group = 'io.cloudsmith.api' -version = '2.0.25' +version = '2.0.26' buildscript { repositories { diff --git a/bindings/java/src/build.json b/bindings/java/src/build.json index b803f44b..dea9700b 100644 --- a/bindings/java/src/build.json +++ b/bindings/java/src/build.json @@ -3,7 +3,7 @@ "apiPackage": "io.cloudsmith.api.apis", "artifactId": "cloudsmith-api", "artifactUrl": "https://api.cloudsmith.io/?format=openapi", - "artifactVersion": "2.0.25", + "artifactVersion": "2.0.26", "artifactDescription": "Cloudsmith API", "dateLibrary": "java8", "developerName": "Cloudsmith Ltd", diff --git a/bindings/java/src/build.sbt b/bindings/java/src/build.sbt index 396b273f..e979ef48 100644 --- a/bindings/java/src/build.sbt +++ b/bindings/java/src/build.sbt @@ -2,7 +2,7 @@ lazy val root = (project in file(".")). settings( organization := "io.cloudsmith.api", name := "cloudsmith-api", - version := "2.0.25", + version := "2.0.26", scalaVersion := "2.11.4", scalacOptions ++= Seq("-feature"), javacOptions in compile ++= Seq("-Xlint:deprecation"), diff --git a/bindings/java/src/docs/AlpineUpstream.md b/bindings/java/src/docs/AlpineUpstream.md index 05ee1419..0ab6cc6a 100644 --- a/bindings/java/src/docs/AlpineUpstream.md +++ b/bindings/java/src/docs/AlpineUpstream.md @@ -25,6 +25,10 @@ Name | Type | Description | Notes **name** | **String** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | **pendingValidation** | **Boolean** | When true, this upstream source is pending validation. | [optional] **priority** | **java.math.BigInteger** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsaKeyInline** | **String** | A base64-encoded RSA public key in PEM format used to verify package signatures. | [optional] +**rsaKeyUrl** | **String** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsaVerification** | [**RsaVerificationEnum**](#RsaVerificationEnum) | The RSA signature verification mode for this upstream. | [optional] +**rsaVerificationStatus** | [**RsaVerificationStatusEnum**](#RsaVerificationStatusEnum) | The RSA signature verification status for this upstream. | [optional] **slugPerm** | **String** | | [optional] **updatedAt** | [**OffsetDateTime**](OffsetDateTime.md) | | [optional] **upstreamUrl** | **String** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | @@ -46,6 +50,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" @@ -57,4 +62,23 @@ PROXY_ONLY | "Proxy Only" CACHE_AND_PROXY | "Cache and Proxy" + +## Enum: RsaVerificationEnum +Name | Value +---- | ----- +ALLOW_ALL | "Allow All" +WARN_ON_INVALID | "Warn on Invalid" +REJECT_INVALID | "Reject Invalid" + + + +## Enum: RsaVerificationStatusEnum +Name | Value +---- | ----- +UNKNOWN | "Unknown" +INVALID | "Invalid" +VALID | "Valid" +INVALID_NO_KEY_ | "Invalid (No Key)" + + diff --git a/bindings/java/src/docs/AlpineUpstreamRequest.md b/bindings/java/src/docs/AlpineUpstreamRequest.md index 0efeea38..a56fae0d 100644 --- a/bindings/java/src/docs/AlpineUpstreamRequest.md +++ b/bindings/java/src/docs/AlpineUpstreamRequest.md @@ -15,6 +15,8 @@ Name | Type | Description | Notes **mode** | [**ModeEnum**](#ModeEnum) | The mode that this upstream should operate in. Upstream sources can be used to proxy resolved packages, as well as operate in a proxy/cache or cache only mode. | [optional] **name** | **String** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | **priority** | **java.math.BigInteger** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsaKeyUrl** | **String** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsaVerification** | [**RsaVerificationEnum**](#RsaVerificationEnum) | The RSA signature verification mode for this upstream. | [optional] **upstreamUrl** | **String** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | **verifySsl** | **Boolean** | If enabled, SSL certificates are verified when requests are made to this upstream. It's recommended to leave this enabled for all public sources to help mitigate Man-In-The-Middle (MITM) attacks. Please note this only applies to HTTPS upstreams. | [optional] @@ -35,4 +37,13 @@ PROXY_ONLY | "Proxy Only" CACHE_AND_PROXY | "Cache and Proxy" + +## Enum: RsaVerificationEnum +Name | Value +---- | ----- +ALLOW_ALL | "Allow All" +WARN_ON_INVALID | "Warn on Invalid" +REJECT_INVALID | "Reject Invalid" + + diff --git a/bindings/java/src/docs/AlpineUpstreamRequestPatch.md b/bindings/java/src/docs/AlpineUpstreamRequestPatch.md index 17ea7954..b1493081 100644 --- a/bindings/java/src/docs/AlpineUpstreamRequestPatch.md +++ b/bindings/java/src/docs/AlpineUpstreamRequestPatch.md @@ -15,6 +15,8 @@ Name | Type | Description | Notes **mode** | [**ModeEnum**](#ModeEnum) | The mode that this upstream should operate in. Upstream sources can be used to proxy resolved packages, as well as operate in a proxy/cache or cache only mode. | [optional] **name** | **String** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | [optional] **priority** | **java.math.BigInteger** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsaKeyUrl** | **String** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsaVerification** | [**RsaVerificationEnum**](#RsaVerificationEnum) | The RSA signature verification mode for this upstream. | [optional] **upstreamUrl** | **String** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | [optional] **verifySsl** | **Boolean** | If enabled, SSL certificates are verified when requests are made to this upstream. It's recommended to leave this enabled for all public sources to help mitigate Man-In-The-Middle (MITM) attacks. Please note this only applies to HTTPS upstreams. | [optional] @@ -35,4 +37,13 @@ PROXY_ONLY | "Proxy Only" CACHE_AND_PROXY | "Cache and Proxy" + +## Enum: RsaVerificationEnum +Name | Value +---- | ----- +ALLOW_ALL | "Allow All" +WARN_ON_INVALID | "Warn on Invalid" +REJECT_INVALID | "Reject Invalid" + + diff --git a/bindings/java/src/docs/CargoUpstream.md b/bindings/java/src/docs/CargoUpstream.md index cc31e341..65bcff72 100644 --- a/bindings/java/src/docs/CargoUpstream.md +++ b/bindings/java/src/docs/CargoUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/ComposerUpstream.md b/bindings/java/src/docs/ComposerUpstream.md index a950b4ec..99b5f1e1 100644 --- a/bindings/java/src/docs/ComposerUpstream.md +++ b/bindings/java/src/docs/ComposerUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/CondaUpstream.md b/bindings/java/src/docs/CondaUpstream.md index e23987cb..f7b05bec 100644 --- a/bindings/java/src/docs/CondaUpstream.md +++ b/bindings/java/src/docs/CondaUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/CranUpstream.md b/bindings/java/src/docs/CranUpstream.md index ab2baf7c..da195456 100644 --- a/bindings/java/src/docs/CranUpstream.md +++ b/bindings/java/src/docs/CranUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/DartUpstream.md b/bindings/java/src/docs/DartUpstream.md index b213ecd4..0b78c77b 100644 --- a/bindings/java/src/docs/DartUpstream.md +++ b/bindings/java/src/docs/DartUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/DebUpstream.md b/bindings/java/src/docs/DebUpstream.md index 3ee02669..7d7a8b52 100644 --- a/bindings/java/src/docs/DebUpstream.md +++ b/bindings/java/src/docs/DebUpstream.md @@ -55,6 +55,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/DockerUpstream.md b/bindings/java/src/docs/DockerUpstream.md index 3094e2f7..fce29829 100644 --- a/bindings/java/src/docs/DockerUpstream.md +++ b/bindings/java/src/docs/DockerUpstream.md @@ -43,6 +43,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/EntitlementsApi.md b/bindings/java/src/docs/EntitlementsApi.md index 02191a2f..a391f822 100644 --- a/bindings/java/src/docs/EntitlementsApi.md +++ b/bindings/java/src/docs/EntitlementsApi.md @@ -14,6 +14,7 @@ Method | HTTP request | Description [**entitlementsRefresh**](EntitlementsApi.md#entitlementsRefresh) | **POST** /entitlements/{owner}/{repo}/{identifier}/refresh/ | Refresh an entitlement token in a repository. [**entitlementsReset**](EntitlementsApi.md#entitlementsReset) | **POST** /entitlements/{owner}/{repo}/{identifier}/reset/ | Reset the statistics for an entitlement token in a repository. [**entitlementsSync**](EntitlementsApi.md#entitlementsSync) | **POST** /entitlements/{owner}/{repo}/sync/ | Synchronise tokens from a source repository. +[**entitlementsTogglePrivateBroadcasts**](EntitlementsApi.md#entitlementsTogglePrivateBroadcasts) | **POST** /entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/ | Set private broadcast access for an entitlement token in a repository. @@ -680,3 +681,68 @@ Name | Type | Description | Notes - **Content-Type**: application/json - **Accept**: application/json + +# **entitlementsTogglePrivateBroadcasts** +> entitlementsTogglePrivateBroadcasts(owner, repo, identifier, data) + +Set private broadcast access for an entitlement token in a repository. + +Set private broadcast access for an entitlement token in a repository. + +### Example +```java +// Import classes: +//import io.cloudsmith.api.ApiClient; +//import io.cloudsmith.api.ApiException; +//import io.cloudsmith.api.Configuration; +//import io.cloudsmith.api.auth.*; +//import io.cloudsmith.api.apis.EntitlementsApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: apikey +ApiKeyAuth apikey = (ApiKeyAuth) defaultClient.getAuthentication("apikey"); +apikey.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//apikey.setApiKeyPrefix("Token"); + +// Configure HTTP basic authorization: basic +HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic"); +basic.setUsername("YOUR USERNAME"); +basic.setPassword("YOUR PASSWORD"); + +EntitlementsApi apiInstance = new EntitlementsApi(); +String owner = "owner_example"; // String | +String repo = "repo_example"; // String | +String identifier = "identifier_example"; // String | +RepositoryTokenPrivateBroadcastsRequest data = new RepositoryTokenPrivateBroadcastsRequest(); // RepositoryTokenPrivateBroadcastsRequest | +try { + apiInstance.entitlementsTogglePrivateBroadcasts(owner, repo, identifier, data); +} catch (ApiException e) { + System.err.println("Exception when calling EntitlementsApi#entitlementsTogglePrivateBroadcasts"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **repo** | **String**| | + **identifier** | **String**| | + **data** | [**RepositoryTokenPrivateBroadcastsRequest**](RepositoryTokenPrivateBroadcastsRequest.md)| | [optional] + +### Return type + +null (empty response body) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + diff --git a/bindings/java/src/docs/GenericUpstream.md b/bindings/java/src/docs/GenericUpstream.md index df427fef..ac4bb09c 100644 --- a/bindings/java/src/docs/GenericUpstream.md +++ b/bindings/java/src/docs/GenericUpstream.md @@ -48,6 +48,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/GoUpstream.md b/bindings/java/src/docs/GoUpstream.md index 5770836b..4b8ce968 100644 --- a/bindings/java/src/docs/GoUpstream.md +++ b/bindings/java/src/docs/GoUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/HelmUpstream.md b/bindings/java/src/docs/HelmUpstream.md index 6a4bec62..4dc8593c 100644 --- a/bindings/java/src/docs/HelmUpstream.md +++ b/bindings/java/src/docs/HelmUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/HexUpstream.md b/bindings/java/src/docs/HexUpstream.md index 1eef4d2f..4f5bc990 100644 --- a/bindings/java/src/docs/HexUpstream.md +++ b/bindings/java/src/docs/HexUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/HuggingfaceUpstream.md b/bindings/java/src/docs/HuggingfaceUpstream.md index 4eaee127..f7321b01 100644 --- a/bindings/java/src/docs/HuggingfaceUpstream.md +++ b/bindings/java/src/docs/HuggingfaceUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/MavenUpstream.md b/bindings/java/src/docs/MavenUpstream.md index ecd244c6..db384ffe 100644 --- a/bindings/java/src/docs/MavenUpstream.md +++ b/bindings/java/src/docs/MavenUpstream.md @@ -52,6 +52,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/McpPackageUpload.md b/bindings/java/src/docs/McpPackageUpload.md new file mode 100644 index 00000000..a7d02975 --- /dev/null +++ b/bindings/java/src/docs/McpPackageUpload.md @@ -0,0 +1,107 @@ + +# McpPackageUpload + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**architectures** | [**List<Architecture>**](Architecture.md) | | [optional] +**cdnUrl** | **String** | | [optional] +**checksumMd5** | **String** | | [optional] +**checksumSha1** | **String** | | [optional] +**checksumSha256** | **String** | | [optional] +**checksumSha512** | **String** | | [optional] +**dependenciesChecksumMd5** | **String** | A checksum of all of the package's dependencies. | [optional] +**dependenciesUrl** | **String** | | [optional] +**description** | **String** | A textual description of this package. | [optional] +**displayName** | **String** | | [optional] +**distro** | [**Distribution**](Distribution.md) | | [optional] +**distroVersion** | [**DistributionVersion**](DistributionVersion.md) | | [optional] +**downloads** | **java.math.BigInteger** | | [optional] +**epoch** | **java.math.BigInteger** | The epoch of the package version (if any). | [optional] +**extension** | **String** | | [optional] +**filename** | **String** | | [optional] +**files** | [**List<PackageFile>**](PackageFile.md) | | [optional] +**format** | **String** | | [optional] +**formatUrl** | **String** | | [optional] +**freeableStorage** | **java.math.BigInteger** | Amount of storage that will be freed if this package is deleted | [optional] +**fullyQualifiedName** | **String** | | [optional] +**identifierPerm** | **String** | Unique and permanent identifier for the package. | [optional] +**identifiers** | **Map<String, String>** | Return a map of identifier field names and their values. | [optional] +**indexed** | **Boolean** | | [optional] +**isCancellable** | **Boolean** | | [optional] +**isCopyable** | **Boolean** | | [optional] +**isDeleteable** | **Boolean** | | [optional] +**isDownloadable** | **Boolean** | | [optional] +**isMoveable** | **Boolean** | | [optional] +**isQuarantinable** | **Boolean** | | [optional] +**isQuarantined** | **Boolean** | | [optional] +**isResyncable** | **Boolean** | | [optional] +**isSecurityScannable** | **Boolean** | | [optional] +**isSyncAwaiting** | **Boolean** | | [optional] +**isSyncCompleted** | **Boolean** | | [optional] +**isSyncFailed** | **Boolean** | | [optional] +**isSyncInFlight** | **Boolean** | | [optional] +**isSyncInProgress** | **Boolean** | | [optional] +**license** | **String** | The license of this package. | [optional] +**name** | **String** | The name of this package. | [optional] +**namespace** | **String** | | [optional] +**namespaceUrl** | **String** | | [optional] +**numFiles** | **java.math.BigInteger** | | [optional] +**originRepository** | **String** | | [optional] +**originRepositoryUrl** | **String** | | [optional] +**packageType** | **java.math.BigInteger** | The type of package contents. | [optional] +**policyViolated** | **Boolean** | Whether or not the package has violated any policy. | [optional] +**rawLicense** | **String** | The raw license string. | [optional] +**release** | **String** | The release of the package version (if any). | [optional] +**repository** | **String** | | [optional] +**repositoryUrl** | **String** | | [optional] +**securityScanCompletedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the security scanning was completed. | [optional] +**securityScanStartedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the security scanning was started. | [optional] +**securityScanStatus** | [**SecurityScanStatusEnum**](#SecurityScanStatusEnum) | | [optional] +**securityScanStatusUpdatedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the security scanning status was updated. | [optional] +**selfHtmlUrl** | **String** | | [optional] +**selfUrl** | **String** | | [optional] +**selfWebappUrl** | **String** | | [optional] +**signatureUrl** | **String** | | [optional] +**size** | **java.math.BigInteger** | The calculated size of the package. | [optional] +**slug** | **String** | The public unique identifier for the package. | [optional] +**slugPerm** | **String** | | [optional] +**spdxLicense** | **String** | The SPDX license identifier for this package. | [optional] +**stage** | **java.math.BigInteger** | The synchronisation (in progress) stage of the package. | [optional] +**stageStr** | **String** | | [optional] +**stageUpdatedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the package stage was updated at. | [optional] +**status** | **java.math.BigInteger** | The synchronisation status of the package. | [optional] +**statusReason** | **String** | A textual description for the synchronous status reason (if any | [optional] +**statusStr** | **String** | | [optional] +**statusUpdatedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the package status was updated at. | [optional] +**statusUrl** | **String** | | [optional] +**subtype** | **String** | | [optional] +**summary** | **String** | A one-liner synopsis of this package. | [optional] +**syncFinishedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the package sync was finished at. | [optional] +**syncProgress** | **java.math.BigInteger** | Synchronisation progress (from 0-100) | [optional] +**tagsAutomatic** | [**Tags**](Tags.md) | | [optional] +**tagsImmutable** | [**Tags**](Tags.md) | | [optional] +**typeDisplay** | **String** | | [optional] +**uploadedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date this package was uploaded. | [optional] +**uploader** | **String** | | [optional] +**uploaderUrl** | **String** | | [optional] +**version** | **String** | The raw version for this package. | [optional] +**versionOrig** | **String** | | [optional] +**vulnerabilityScanResultsUrl** | **String** | | [optional] + + + +## Enum: SecurityScanStatusEnum +Name | Value +---- | ----- +AWAITING_SECURITY_SCAN | "Awaiting Security Scan" +SECURITY_SCANNING_IN_PROGRESS | "Security Scanning in Progress" +SCAN_DETECTED_VULNERABILITIES | "Scan Detected Vulnerabilities" +SCAN_DETECTED_NO_VULNERABILITIES | "Scan Detected No Vulnerabilities" +SECURITY_SCANNING_DISABLED | "Security Scanning Disabled" +SECURITY_SCANNING_FAILED | "Security Scanning Failed" +SECURITY_SCANNING_SKIPPED | "Security Scanning Skipped" +SECURITY_SCANNING_NOT_SUPPORTED | "Security Scanning Not Supported" + + + diff --git a/bindings/java/src/docs/McpPackageUploadRequest.md b/bindings/java/src/docs/McpPackageUploadRequest.md new file mode 100644 index 00000000..7913223c --- /dev/null +++ b/bindings/java/src/docs/McpPackageUploadRequest.md @@ -0,0 +1,13 @@ + +# McpPackageUploadRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**packageFile** | **String** | The primary file for the package. | +**republish** | **Boolean** | If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. | [optional] +**tags** | **String** | A comma-separated values list of tags to add to the package. | [optional] +**version** | **String** | The raw version for this package. | [optional] + + + diff --git a/bindings/java/src/docs/NpmUpstream.md b/bindings/java/src/docs/NpmUpstream.md index 6eb32de1..aeae7c71 100644 --- a/bindings/java/src/docs/NpmUpstream.md +++ b/bindings/java/src/docs/NpmUpstream.md @@ -48,6 +48,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/NugetUpstream.md b/bindings/java/src/docs/NugetUpstream.md index 4d90ddf1..0c4159f8 100644 --- a/bindings/java/src/docs/NugetUpstream.md +++ b/bindings/java/src/docs/NugetUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/PackageRecycleBin.md b/bindings/java/src/docs/PackageRecycleBin.md new file mode 100644 index 00000000..3661dac9 --- /dev/null +++ b/bindings/java/src/docs/PackageRecycleBin.md @@ -0,0 +1,20 @@ + +# PackageRecycleBin + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action** | [**ActionEnum**](#ActionEnum) | The action to perform on soft-deleted packages. | +**identifiers** | **List<String>** | A list of soft-deleted package identifiers to action. | +**repository** | **String** | The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. | [optional] + + + +## Enum: ActionEnum +Name | Value +---- | ----- +HARD_DELETE | "hard_delete" +RESTORE | "restore" + + + diff --git a/bindings/java/src/docs/PackagesApi.md b/bindings/java/src/docs/PackagesApi.md index e694318e..7e60cd10 100644 --- a/bindings/java/src/docs/PackagesApi.md +++ b/bindings/java/src/docs/PackagesApi.md @@ -34,6 +34,7 @@ Method | HTTP request | Description [**packagesUploadHuggingface**](PackagesApi.md#packagesUploadHuggingface) | **POST** /packages/{owner}/{repo}/upload/huggingface/ | Create a new HuggingFace package [**packagesUploadLuarocks**](PackagesApi.md#packagesUploadLuarocks) | **POST** /packages/{owner}/{repo}/upload/luarocks/ | Create a new LuaRocks package [**packagesUploadMaven**](PackagesApi.md#packagesUploadMaven) | **POST** /packages/{owner}/{repo}/upload/maven/ | Create a new Maven package +[**packagesUploadMcp**](PackagesApi.md#packagesUploadMcp) | **POST** /packages/{owner}/{repo}/upload/mcp/ | Create a new MCP package [**packagesUploadNpm**](PackagesApi.md#packagesUploadNpm) | **POST** /packages/{owner}/{repo}/upload/npm/ | Create a new npm package [**packagesUploadNuget**](PackagesApi.md#packagesUploadNuget) | **POST** /packages/{owner}/{repo}/upload/nuget/ | Create a new NuGet package [**packagesUploadP2**](PackagesApi.md#packagesUploadP2) | **POST** /packages/{owner}/{repo}/upload/p2/ | Create a new P2 package @@ -62,6 +63,7 @@ Method | HTTP request | Description [**packagesValidateUploadHuggingface**](PackagesApi.md#packagesValidateUploadHuggingface) | **POST** /packages/{owner}/{repo}/validate-upload/huggingface/ | Validate parameters for create HuggingFace package [**packagesValidateUploadLuarocks**](PackagesApi.md#packagesValidateUploadLuarocks) | **POST** /packages/{owner}/{repo}/validate-upload/luarocks/ | Validate parameters for create LuaRocks package [**packagesValidateUploadMaven**](PackagesApi.md#packagesValidateUploadMaven) | **POST** /packages/{owner}/{repo}/validate-upload/maven/ | Validate parameters for create Maven package +[**packagesValidateUploadMcp**](PackagesApi.md#packagesValidateUploadMcp) | **POST** /packages/{owner}/{repo}/validate-upload/mcp/ | Validate parameters for create MCP package [**packagesValidateUploadNpm**](PackagesApi.md#packagesValidateUploadNpm) | **POST** /packages/{owner}/{repo}/validate-upload/npm/ | Validate parameters for create npm package [**packagesValidateUploadNuget**](PackagesApi.md#packagesValidateUploadNuget) | **POST** /packages/{owner}/{repo}/validate-upload/nuget/ | Validate parameters for create NuGet package [**packagesValidateUploadP2**](PackagesApi.md#packagesValidateUploadP2) | **POST** /packages/{owner}/{repo}/validate-upload/p2/ | Validate parameters for create P2 package @@ -2015,6 +2017,70 @@ Name | Type | Description | Notes [apikey](../README.md#apikey), [basic](../README.md#basic) +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **packagesUploadMcp** +> McpPackageUpload packagesUploadMcp(owner, repo, data) + +Create a new MCP package + +Create a new MCP package + +### Example +```java +// Import classes: +//import io.cloudsmith.api.ApiClient; +//import io.cloudsmith.api.ApiException; +//import io.cloudsmith.api.Configuration; +//import io.cloudsmith.api.auth.*; +//import io.cloudsmith.api.apis.PackagesApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: apikey +ApiKeyAuth apikey = (ApiKeyAuth) defaultClient.getAuthentication("apikey"); +apikey.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//apikey.setApiKeyPrefix("Token"); + +// Configure HTTP basic authorization: basic +HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic"); +basic.setUsername("YOUR USERNAME"); +basic.setPassword("YOUR PASSWORD"); + +PackagesApi apiInstance = new PackagesApi(); +String owner = "owner_example"; // String | +String repo = "repo_example"; // String | +McpPackageUploadRequest data = new McpPackageUploadRequest(); // McpPackageUploadRequest | +try { + McpPackageUpload result = apiInstance.packagesUploadMcp(owner, repo, data); + System.out.println(result); +} catch (ApiException e) { + System.err.println("Exception when calling PackagesApi#packagesUploadMcp"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **repo** | **String**| | + **data** | [**McpPackageUploadRequest**](McpPackageUploadRequest.md)| | [optional] + +### Return type + +[**McpPackageUpload**](McpPackageUpload.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + ### HTTP request headers - **Content-Type**: application/json @@ -3790,6 +3856,69 @@ null (empty response body) [apikey](../README.md#apikey), [basic](../README.md#basic) +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **packagesValidateUploadMcp** +> packagesValidateUploadMcp(owner, repo, data) + +Validate parameters for create MCP package + +Validate parameters for create MCP package + +### Example +```java +// Import classes: +//import io.cloudsmith.api.ApiClient; +//import io.cloudsmith.api.ApiException; +//import io.cloudsmith.api.Configuration; +//import io.cloudsmith.api.auth.*; +//import io.cloudsmith.api.apis.PackagesApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: apikey +ApiKeyAuth apikey = (ApiKeyAuth) defaultClient.getAuthentication("apikey"); +apikey.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//apikey.setApiKeyPrefix("Token"); + +// Configure HTTP basic authorization: basic +HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic"); +basic.setUsername("YOUR USERNAME"); +basic.setPassword("YOUR PASSWORD"); + +PackagesApi apiInstance = new PackagesApi(); +String owner = "owner_example"; // String | +String repo = "repo_example"; // String | +McpPackageUploadRequest data = new McpPackageUploadRequest(); // McpPackageUploadRequest | +try { + apiInstance.packagesValidateUploadMcp(owner, repo, data); +} catch (ApiException e) { + System.err.println("Exception when calling PackagesApi#packagesValidateUploadMcp"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **repo** | **String**| | + **data** | [**McpPackageUploadRequest**](McpPackageUploadRequest.md)| | [optional] + +### Return type + +null (empty response body) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + ### HTTP request headers - **Content-Type**: application/json diff --git a/bindings/java/src/docs/PythonUpstream.md b/bindings/java/src/docs/PythonUpstream.md index 217b933c..b3093403 100644 --- a/bindings/java/src/docs/PythonUpstream.md +++ b/bindings/java/src/docs/PythonUpstream.md @@ -47,6 +47,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/RecycleBinApi.md b/bindings/java/src/docs/RecycleBinApi.md new file mode 100644 index 00000000..84730e10 --- /dev/null +++ b/bindings/java/src/docs/RecycleBinApi.md @@ -0,0 +1,138 @@ +# RecycleBinApi + +All URIs are relative to *https://api.cloudsmith.io* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**recycleBinList**](RecycleBinApi.md#recycleBinList) | **GET** /recycle-bin/{owner}/ | List soft-deleted packages in recycle bin +[**recycleBinRecycleBinAction**](RecycleBinApi.md#recycleBinRecycleBinAction) | **POST** /recycle-bin/{owner}/action/ | + + + +# **recycleBinList** +> List<RecycleBinPackage> recycleBinList(owner, page, pageSize, repository) + +List soft-deleted packages in recycle bin + +Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + +### Example +```java +// Import classes: +//import io.cloudsmith.api.ApiClient; +//import io.cloudsmith.api.ApiException; +//import io.cloudsmith.api.Configuration; +//import io.cloudsmith.api.auth.*; +//import io.cloudsmith.api.apis.RecycleBinApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: apikey +ApiKeyAuth apikey = (ApiKeyAuth) defaultClient.getAuthentication("apikey"); +apikey.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//apikey.setApiKeyPrefix("Token"); + +// Configure HTTP basic authorization: basic +HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic"); +basic.setUsername("YOUR USERNAME"); +basic.setPassword("YOUR PASSWORD"); + +RecycleBinApi apiInstance = new RecycleBinApi(); +String owner = "owner_example"; // String | +java.math.BigInteger page = new java.math.BigInteger(); // java.math.BigInteger | A page number within the paginated result set. +java.math.BigInteger pageSize = new java.math.BigInteger(); // java.math.BigInteger | Number of results to return per page. +String repository = "repository_example"; // String | Filter packages by repository slug +try { + List result = apiInstance.recycleBinList(owner, page, pageSize, repository); + System.out.println(result); +} catch (ApiException e) { + System.err.println("Exception when calling RecycleBinApi#recycleBinList"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **page** | **java.math.BigInteger**| A page number within the paginated result set. | [optional] + **pageSize** | **java.math.BigInteger**| Number of results to return per page. | [optional] + **repository** | **String**| Filter packages by repository slug | [optional] + +### Return type + +[**List<RecycleBinPackage>**](RecycleBinPackage.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **recycleBinRecycleBinAction** +> PackageBulkActionResponse recycleBinRecycleBinAction(owner, data) + + + +Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + +### Example +```java +// Import classes: +//import io.cloudsmith.api.ApiClient; +//import io.cloudsmith.api.ApiException; +//import io.cloudsmith.api.Configuration; +//import io.cloudsmith.api.auth.*; +//import io.cloudsmith.api.apis.RecycleBinApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: apikey +ApiKeyAuth apikey = (ApiKeyAuth) defaultClient.getAuthentication("apikey"); +apikey.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//apikey.setApiKeyPrefix("Token"); + +// Configure HTTP basic authorization: basic +HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic"); +basic.setUsername("YOUR USERNAME"); +basic.setPassword("YOUR PASSWORD"); + +RecycleBinApi apiInstance = new RecycleBinApi(); +String owner = "owner_example"; // String | +PackageRecycleBin data = new PackageRecycleBin(); // PackageRecycleBin | +try { + PackageBulkActionResponse result = apiInstance.recycleBinRecycleBinAction(owner, data); + System.out.println(result); +} catch (ApiException e) { + System.err.println("Exception when calling RecycleBinApi#recycleBinRecycleBinAction"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **data** | [**PackageRecycleBin**](PackageRecycleBin.md)| | [optional] + +### Return type + +[**PackageBulkActionResponse**](PackageBulkActionResponse.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + diff --git a/bindings/java/src/docs/RecycleBinPackage.md b/bindings/java/src/docs/RecycleBinPackage.md new file mode 100644 index 00000000..993605a6 --- /dev/null +++ b/bindings/java/src/docs/RecycleBinPackage.md @@ -0,0 +1,47 @@ + +# RecycleBinPackage + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**actionBy** | **String** | The name of the user who deleted the package. | [optional] +**downloads** | **java.math.BigInteger** | | [optional] +**filename** | **String** | | [optional] +**format** | **String** | | [optional] +**fullyQualifiedName** | **String** | The fully qualified name of the package. | [optional] +**identifiers** | **Map<String, String>** | | [optional] +**invokedRetentionRule** | **Map<String, String>** | Information about the retention rule that triggered deletion (if any). | [optional] +**isDeleteable** | **Boolean** | | [optional] +**isQuarantined** | **Boolean** | | [optional] +**isRestorable** | **Boolean** | | [optional] +**name** | **String** | The name of this package. | [optional] +**policyViolated** | **Boolean** | Whether or not the package has violated any policy. | [optional] +**repository** | **String** | | [optional] +**securityScanCompletedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the security scanning was completed. | [optional] +**securityScanStatus** | [**SecurityScanStatusEnum**](#SecurityScanStatusEnum) | | [optional] +**size** | **java.math.BigInteger** | The calculated size of the package. | [optional] +**slugPerm** | **String** | | [optional] +**status** | **java.math.BigInteger** | The synchronisation status of the package. | [optional] +**statusUpdatedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The datetime the package status was updated at. | [optional] +**tags** | [**Tags**](Tags.md) | | [optional] +**typeDisplay** | **String** | | [optional] +**uploadedAt** | [**OffsetDateTime**](OffsetDateTime.md) | The date this package was uploaded. | [optional] +**uploader** | **String** | | [optional] +**version** | **String** | The raw version for this package. | [optional] + + + +## Enum: SecurityScanStatusEnum +Name | Value +---- | ----- +AWAITING_SECURITY_SCAN | "Awaiting Security Scan" +SECURITY_SCANNING_IN_PROGRESS | "Security Scanning in Progress" +SCAN_DETECTED_VULNERABILITIES | "Scan Detected Vulnerabilities" +SCAN_DETECTED_NO_VULNERABILITIES | "Scan Detected No Vulnerabilities" +SECURITY_SCANNING_DISABLED | "Security Scanning Disabled" +SECURITY_SCANNING_FAILED | "Security Scanning Failed" +SECURITY_SCANNING_SKIPPED | "Security Scanning Skipped" +SECURITY_SCANNING_NOT_SUPPORTED | "Security Scanning Not Supported" + + + diff --git a/bindings/java/src/docs/ReposApi.md b/bindings/java/src/docs/ReposApi.md index 5dfe9d63..465500cc 100644 --- a/bindings/java/src/docs/ReposApi.md +++ b/bindings/java/src/docs/ReposApi.md @@ -8,7 +8,7 @@ Method | HTTP request | Description [**repoRetentionPartialUpdate**](ReposApi.md#repoRetentionPartialUpdate) | **PATCH** /repos/{owner}/{repo}/retention/ | Update the retention rules for the repository. [**repoRetentionRead**](ReposApi.md#repoRetentionRead) | **GET** /repos/{owner}/{repo}/retention/ | Retrieve the retention rules for the repository. [**reposCreate**](ReposApi.md#reposCreate) | **POST** /repos/{owner}/ | Create a new repository in a given namespace. -[**reposDelete**](ReposApi.md#reposDelete) | **DELETE** /repos/{owner}/{identifier}/ | Delete a repository in a given namespace. +[**reposDelete**](ReposApi.md#reposDelete) | **DELETE** /repos/{owner}/{identifier}/ | [**reposEcdsaCreate**](ReposApi.md#reposEcdsaCreate) | **POST** /repos/{owner}/{identifier}/ecdsa/ | Set the active ECDSA key for the Repository. [**reposEcdsaList**](ReposApi.md#reposEcdsaList) | **GET** /repos/{owner}/{identifier}/ecdsa/ | Retrieve the active ECDSA key for the Repository. [**reposEcdsaRegenerate**](ReposApi.md#reposEcdsaRegenerate) | **POST** /repos/{owner}/{identifier}/ecdsa/regenerate/ | Regenerate ECDSA Key for the Repository. @@ -410,9 +410,9 @@ Name | Type | Description | Notes # **reposDelete** > reposDelete(owner, identifier) -Delete a repository in a given namespace. -Delete a repository in a given namespace. + +Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. ### Example ```java diff --git a/bindings/java/src/docs/RepositoryTokenPrivateBroadcasts.md b/bindings/java/src/docs/RepositoryTokenPrivateBroadcasts.md new file mode 100644 index 00000000..5ec11d14 --- /dev/null +++ b/bindings/java/src/docs/RepositoryTokenPrivateBroadcasts.md @@ -0,0 +1,10 @@ + +# RepositoryTokenPrivateBroadcasts + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**accessPrivateBroadcasts** | **Boolean** | Whether the token should have access to private broadcasts. | + + + diff --git a/bindings/java/src/docs/RepositoryTokenPrivateBroadcastsRequest.md b/bindings/java/src/docs/RepositoryTokenPrivateBroadcastsRequest.md new file mode 100644 index 00000000..2e58eb51 --- /dev/null +++ b/bindings/java/src/docs/RepositoryTokenPrivateBroadcastsRequest.md @@ -0,0 +1,10 @@ + +# RepositoryTokenPrivateBroadcastsRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**accessPrivateBroadcasts** | **Boolean** | Whether the token should have access to private broadcasts. | + + + diff --git a/bindings/java/src/docs/RepositoryTokenRefreshRequest.md b/bindings/java/src/docs/RepositoryTokenRefreshRequest.md index 8a2f2a65..a57c85fa 100644 --- a/bindings/java/src/docs/RepositoryTokenRefreshRequest.md +++ b/bindings/java/src/docs/RepositoryTokenRefreshRequest.md @@ -4,7 +4,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**accessPrivateBroadcasts** | **Boolean** | If enabled, this token can be used for private broadcasts | [optional] **eulaRequired** | **Boolean** | If checked, a EULA acceptance is required for this token. | [optional] **isActive** | **Boolean** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limitBandwidth** | **java.math.BigInteger** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/java/src/docs/RepositoryTokenRequest.md b/bindings/java/src/docs/RepositoryTokenRequest.md index ddf4361c..107f7fe8 100644 --- a/bindings/java/src/docs/RepositoryTokenRequest.md +++ b/bindings/java/src/docs/RepositoryTokenRequest.md @@ -4,7 +4,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**accessPrivateBroadcasts** | **Boolean** | If enabled, this token can be used for private broadcasts | [optional] **eulaRequired** | **Boolean** | If checked, a EULA acceptance is required for this token. | [optional] **isActive** | **Boolean** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limitBandwidth** | **java.math.BigInteger** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/java/src/docs/RepositoryTokenRequestPatch.md b/bindings/java/src/docs/RepositoryTokenRequestPatch.md index 88919ef6..b9532249 100644 --- a/bindings/java/src/docs/RepositoryTokenRequestPatch.md +++ b/bindings/java/src/docs/RepositoryTokenRequestPatch.md @@ -4,7 +4,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**accessPrivateBroadcasts** | **Boolean** | If enabled, this token can be used for private broadcasts | [optional] **eulaRequired** | **Boolean** | If checked, a EULA acceptance is required for this token. | [optional] **isActive** | **Boolean** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limitBandwidth** | **java.math.BigInteger** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/java/src/docs/RpmUpstream.md b/bindings/java/src/docs/RpmUpstream.md index 009555c8..434067c9 100644 --- a/bindings/java/src/docs/RpmUpstream.md +++ b/bindings/java/src/docs/RpmUpstream.md @@ -53,6 +53,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/RubyUpstream.md b/bindings/java/src/docs/RubyUpstream.md index d727c04a..610224de 100644 --- a/bindings/java/src/docs/RubyUpstream.md +++ b/bindings/java/src/docs/RubyUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/docs/StorageAllocatedLimit.md b/bindings/java/src/docs/StorageAllocatedLimit.md index c7c9c98a..dd5913cd 100644 --- a/bindings/java/src/docs/StorageAllocatedLimit.md +++ b/bindings/java/src/docs/StorageAllocatedLimit.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **percentageUsed** | **String** | | [optional] **planLimit** | **String** | | [optional] **used** | **String** | | [optional] +**usedPreDeduplication** | **String** | | [optional] diff --git a/bindings/java/src/docs/StorageAllocatedLimitRaw.md b/bindings/java/src/docs/StorageAllocatedLimitRaw.md index 8814bd8a..9760b7de 100644 --- a/bindings/java/src/docs/StorageAllocatedLimitRaw.md +++ b/bindings/java/src/docs/StorageAllocatedLimitRaw.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **percentageUsed** | **String** | | [optional] **planLimit** | **java.math.BigInteger** | | [optional] **used** | **java.math.BigInteger** | | [optional] +**usedPreDeduplication** | **java.math.BigInteger** | | [optional] diff --git a/bindings/java/src/docs/SwiftUpstream.md b/bindings/java/src/docs/SwiftUpstream.md index 913ed77f..51980093 100644 --- a/bindings/java/src/docs/SwiftUpstream.md +++ b/bindings/java/src/docs/SwiftUpstream.md @@ -46,6 +46,7 @@ Name | Value N_A | "N/A" UPSTREAM_POINTS_TO_ITS_OWN_REPOSITORY | "Upstream points to its own repository" MISSING_UPSTREAM_SOURCE | "Missing upstream source" +RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE | "RSA key did not verify the upstream's APKINDEX signature" UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER | "Upstream was disabled by request of user" diff --git a/bindings/java/src/pom.xml b/bindings/java/src/pom.xml index fdf2ee4f..202e13dc 100644 --- a/bindings/java/src/pom.xml +++ b/bindings/java/src/pom.xml @@ -5,7 +5,7 @@ cloudsmith-api jar cloudsmith-api - 2.0.25 + 2.0.26 https://api.cloudsmith.io/?format=openapi Cloudsmith API diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/ApiClient.java b/bindings/java/src/src/main/java/io/cloudsmith/api/ApiClient.java index 22996e73..5f3d325c 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/ApiClient.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/ApiClient.java @@ -87,7 +87,7 @@ public ApiClient() { json = new JSON(); // Set default User-Agent. - setUserAgent("Swagger-Codegen/2.0.25/java"); + setUserAgent("Swagger-Codegen/2.0.26/java"); // Setup authentications (key: authentication name, value: authentication). authentications = new HashMap(); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/JSON.java b/bindings/java/src/src/main/java/io/cloudsmith/api/JSON.java index 9f6367cf..43401033 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/JSON.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/JSON.java @@ -314,6 +314,12 @@ import io.cloudsmith.api.models.*; import io.cloudsmith.api.models.*; import io.cloudsmith.api.models.*; +import io.cloudsmith.api.models.*; +import io.cloudsmith.api.models.*; +import io.cloudsmith.api.models.*; +import io.cloudsmith.api.models.*; +import io.cloudsmith.api.models.*; +import io.cloudsmith.api.models.*; import okio.ByteString; import java.io.IOException; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/EntitlementsApi.java b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/EntitlementsApi.java index 83c861f7..dae7eab4 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/EntitlementsApi.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/EntitlementsApi.java @@ -38,6 +38,7 @@ import io.cloudsmith.api.models.ErrorDetail; import io.cloudsmith.api.models.RepositoryToken; +import io.cloudsmith.api.models.RepositoryTokenPrivateBroadcastsRequest; import io.cloudsmith.api.models.RepositoryTokenRefresh; import io.cloudsmith.api.models.RepositoryTokenRefreshRequest; import io.cloudsmith.api.models.RepositoryTokenRequest; @@ -1638,4 +1639,154 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, localVarReturnType, callback); return call; } + /** + * Build call for entitlementsTogglePrivateBroadcasts + * @param owner (required) + * @param repo (required) + * @param identifier (required) + * @param data (optional) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call entitlementsTogglePrivateBroadcastsCall(String owner, String repo, String identifier, RepositoryTokenPrivateBroadcastsRequest data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = data; + + // create path and map variables + String localVarPath = "/entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/" + .replaceAll("\\{" + "owner" + "\\}", apiClient.escapeString(owner.toString())) + .replaceAll("\\{" + "repo" + "\\}", apiClient.escapeString(repo.toString())) + .replaceAll("\\{" + "identifier" + "\\}", apiClient.escapeString(identifier.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + + Map localVarHeaderParams = new HashMap(); + + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if(progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "apikey", "basic" }; + if (headers != null) { + localVarHeaderParams.putAll(headers); + } + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call entitlementsTogglePrivateBroadcastsValidateBeforeCall(String owner, String repo, String identifier, RepositoryTokenPrivateBroadcastsRequest data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + try { + ValidatorFactory factory = Validation.buildDefaultValidatorFactory(); + ExecutableValidator executableValidator = factory.getValidator().forExecutables(); + + Object[] parameterValues = { owner, repo, identifier, data }; + Method method = this.getClass().getMethod("entitlementsTogglePrivateBroadcastsWithHttpInfo", String.class, String.class, String.class, RepositoryTokenPrivateBroadcastsRequest.class); + Set> violations = executableValidator.validateParameters(this, method, + parameterValues); + + if (violations.size() == 0) { + com.squareup.okhttp.Call call = entitlementsTogglePrivateBroadcastsCall(owner, repo, identifier, data, progressListener, progressRequestListener); + return call; + + } else { + throw new BeanValidationException((Set) violations); + } + } catch (NoSuchMethodException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } catch (SecurityException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } + + } + + /** + * Set private broadcast access for an entitlement token in a repository. + * Set private broadcast access for an entitlement token in a repository. + * @param owner (required) + * @param repo (required) + * @param identifier (required) + * @param data (optional) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public void entitlementsTogglePrivateBroadcasts(String owner, String repo, String identifier, RepositoryTokenPrivateBroadcastsRequest data) throws ApiException { + entitlementsTogglePrivateBroadcastsWithHttpInfo(owner, repo, identifier, data); + } + + /** + * Set private broadcast access for an entitlement token in a repository. + * Set private broadcast access for an entitlement token in a repository. + * @param owner (required) + * @param repo (required) + * @param identifier (required) + * @param data (optional) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse entitlementsTogglePrivateBroadcastsWithHttpInfo( @NotNull String owner, @NotNull String repo, @NotNull String identifier, RepositoryTokenPrivateBroadcastsRequest data) throws ApiException { + com.squareup.okhttp.Call call = entitlementsTogglePrivateBroadcastsValidateBeforeCall(owner, repo, identifier, data, null, null); + return apiClient.execute(call); + } + + /** + * Set private broadcast access for an entitlement token in a repository. (asynchronously) + * Set private broadcast access for an entitlement token in a repository. + * @param owner (required) + * @param repo (required) + * @param identifier (required) + * @param data (optional) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call entitlementsTogglePrivateBroadcastsAsync(String owner, String repo, String identifier, RepositoryTokenPrivateBroadcastsRequest data, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = entitlementsTogglePrivateBroadcastsValidateBeforeCall(owner, repo, identifier, data, progressListener, progressRequestListener); + apiClient.executeAsync(call, callback); + return call; + } } diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/PackagesApi.java b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/PackagesApi.java index 748d0083..af5c83f5 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/PackagesApi.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/PackagesApi.java @@ -72,6 +72,8 @@ import io.cloudsmith.api.models.LuarocksPackageUploadRequest; import io.cloudsmith.api.models.MavenPackageUpload; import io.cloudsmith.api.models.MavenPackageUploadRequest; +import io.cloudsmith.api.models.McpPackageUpload; +import io.cloudsmith.api.models.McpPackageUploadRequest; import io.cloudsmith.api.models.ModelPackage; import io.cloudsmith.api.models.NpmPackageUpload; import io.cloudsmith.api.models.NpmPackageUploadRequest; @@ -4686,6 +4688,155 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, localVarReturnType, callback); return call; } + /** + * Build call for packagesUploadMcp + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call packagesUploadMcpCall(String owner, String repo, McpPackageUploadRequest data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = data; + + // create path and map variables + String localVarPath = "/packages/{owner}/{repo}/upload/mcp/" + .replaceAll("\\{" + "owner" + "\\}", apiClient.escapeString(owner.toString())) + .replaceAll("\\{" + "repo" + "\\}", apiClient.escapeString(repo.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + + Map localVarHeaderParams = new HashMap(); + + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if(progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "apikey", "basic" }; + if (headers != null) { + localVarHeaderParams.putAll(headers); + } + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call packagesUploadMcpValidateBeforeCall(String owner, String repo, McpPackageUploadRequest data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + try { + ValidatorFactory factory = Validation.buildDefaultValidatorFactory(); + ExecutableValidator executableValidator = factory.getValidator().forExecutables(); + + Object[] parameterValues = { owner, repo, data }; + Method method = this.getClass().getMethod("packagesUploadMcpWithHttpInfo", String.class, String.class, McpPackageUploadRequest.class); + Set> violations = executableValidator.validateParameters(this, method, + parameterValues); + + if (violations.size() == 0) { + com.squareup.okhttp.Call call = packagesUploadMcpCall(owner, repo, data, progressListener, progressRequestListener); + return call; + + } else { + throw new BeanValidationException((Set) violations); + } + } catch (NoSuchMethodException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } catch (SecurityException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } + + } + + /** + * Create a new MCP package + * Create a new MCP package + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @return McpPackageUpload + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public McpPackageUpload packagesUploadMcp(String owner, String repo, McpPackageUploadRequest data) throws ApiException { + ApiResponse resp = packagesUploadMcpWithHttpInfo(owner, repo, data); + return resp.getData(); + } + + /** + * Create a new MCP package + * Create a new MCP package + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @return ApiResponse<McpPackageUpload> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse packagesUploadMcpWithHttpInfo( @NotNull String owner, @NotNull String repo, McpPackageUploadRequest data) throws ApiException { + com.squareup.okhttp.Call call = packagesUploadMcpValidateBeforeCall(owner, repo, data, null, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return apiClient.execute(call, localVarReturnType); + } + + /** + * Create a new MCP package (asynchronously) + * Create a new MCP package + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call packagesUploadMcpAsync(String owner, String repo, McpPackageUploadRequest data, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = packagesUploadMcpValidateBeforeCall(owner, repo, data, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); + return call; + } /** * Build call for packagesUploadNpm * @param owner (required) @@ -8790,6 +8941,151 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, callback); return call; } + /** + * Build call for packagesValidateUploadMcp + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call packagesValidateUploadMcpCall(String owner, String repo, McpPackageUploadRequest data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = data; + + // create path and map variables + String localVarPath = "/packages/{owner}/{repo}/validate-upload/mcp/" + .replaceAll("\\{" + "owner" + "\\}", apiClient.escapeString(owner.toString())) + .replaceAll("\\{" + "repo" + "\\}", apiClient.escapeString(repo.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + + Map localVarHeaderParams = new HashMap(); + + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if(progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "apikey", "basic" }; + if (headers != null) { + localVarHeaderParams.putAll(headers); + } + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call packagesValidateUploadMcpValidateBeforeCall(String owner, String repo, McpPackageUploadRequest data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + try { + ValidatorFactory factory = Validation.buildDefaultValidatorFactory(); + ExecutableValidator executableValidator = factory.getValidator().forExecutables(); + + Object[] parameterValues = { owner, repo, data }; + Method method = this.getClass().getMethod("packagesValidateUploadMcpWithHttpInfo", String.class, String.class, McpPackageUploadRequest.class); + Set> violations = executableValidator.validateParameters(this, method, + parameterValues); + + if (violations.size() == 0) { + com.squareup.okhttp.Call call = packagesValidateUploadMcpCall(owner, repo, data, progressListener, progressRequestListener); + return call; + + } else { + throw new BeanValidationException((Set) violations); + } + } catch (NoSuchMethodException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } catch (SecurityException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } + + } + + /** + * Validate parameters for create MCP package + * Validate parameters for create MCP package + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public void packagesValidateUploadMcp(String owner, String repo, McpPackageUploadRequest data) throws ApiException { + packagesValidateUploadMcpWithHttpInfo(owner, repo, data); + } + + /** + * Validate parameters for create MCP package + * Validate parameters for create MCP package + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse packagesValidateUploadMcpWithHttpInfo( @NotNull String owner, @NotNull String repo, McpPackageUploadRequest data) throws ApiException { + com.squareup.okhttp.Call call = packagesValidateUploadMcpValidateBeforeCall(owner, repo, data, null, null); + return apiClient.execute(call); + } + + /** + * Validate parameters for create MCP package (asynchronously) + * Validate parameters for create MCP package + * @param owner (required) + * @param repo (required) + * @param data (optional) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call packagesValidateUploadMcpAsync(String owner, String repo, McpPackageUploadRequest data, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = packagesValidateUploadMcpValidateBeforeCall(owner, repo, data, progressListener, progressRequestListener); + apiClient.executeAsync(call, callback); + return call; + } /** * Build call for packagesValidateUploadNpm * @param owner (required) diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/RecycleBinApi.java b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/RecycleBinApi.java new file mode 100644 index 00000000..c64a4a63 --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/RecycleBinApi.java @@ -0,0 +1,376 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.apis; + +import io.cloudsmith.api.ApiCallback; +import io.cloudsmith.api.ApiClient; +import io.cloudsmith.api.ApiException; +import io.cloudsmith.api.ApiResponse; +import io.cloudsmith.api.Configuration; +import io.cloudsmith.api.Pair; +import io.cloudsmith.api.ProgressRequestBody; +import io.cloudsmith.api.ProgressResponseBody; +import io.cloudsmith.api.BeanValidationException; + +import com.google.gson.reflect.TypeToken; + +import java.io.IOException; + +import javax.validation.constraints.*; +import javax.validation.ConstraintViolation; +import javax.validation.Validation; +import javax.validation.ValidatorFactory; +import javax.validation.executable.ExecutableValidator; +import java.util.Set; +import java.lang.reflect.Method; +import java.lang.reflect.Type; + +import io.cloudsmith.api.models.ErrorDetail; +import io.cloudsmith.api.models.PackageBulkActionResponse; +import io.cloudsmith.api.models.PackageRecycleBin; +import io.cloudsmith.api.models.RecycleBinPackage; + +import java.lang.reflect.Type; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class RecycleBinApi { + private ApiClient apiClient; + private Map headers; + + public RecycleBinApi() { + this(Configuration.getDefaultApiClient()); + } + + public RecycleBinApi(ApiClient apiClient) { + this.apiClient = apiClient; + } + + public ApiClient getApiClient() { + return apiClient; + } + + public void setApiClient(ApiClient apiClient) { + this.apiClient = apiClient; + } + + public void setHeadersOverrides(Map headers) { + this.headers = headers; + } + + /** + * Build call for recycleBinList + * @param owner (required) + * @param page A page number within the paginated result set. (optional) + * @param pageSize Number of results to return per page. (optional) + * @param repository Filter packages by repository slug (optional) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call recycleBinListCall(String owner, java.math.BigInteger page, java.math.BigInteger pageSize, String repository, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/recycle-bin/{owner}/" + .replaceAll("\\{" + "owner" + "\\}", apiClient.escapeString(owner.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (page != null) + localVarQueryParams.addAll(apiClient.parameterToPair("page", page)); + if (pageSize != null) + localVarQueryParams.addAll(apiClient.parameterToPair("page_size", pageSize)); + if (repository != null) + localVarQueryParams.addAll(apiClient.parameterToPair("repository", repository)); + + Map localVarHeaderParams = new HashMap(); + + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if(progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "apikey", "basic" }; + if (headers != null) { + localVarHeaderParams.putAll(headers); + } + return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call recycleBinListValidateBeforeCall(String owner, java.math.BigInteger page, java.math.BigInteger pageSize, String repository, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + try { + ValidatorFactory factory = Validation.buildDefaultValidatorFactory(); + ExecutableValidator executableValidator = factory.getValidator().forExecutables(); + + Object[] parameterValues = { owner, page, pageSize, repository }; + Method method = this.getClass().getMethod("recycleBinListWithHttpInfo", String.class, java.math.BigInteger.class, java.math.BigInteger.class, String.class); + Set> violations = executableValidator.validateParameters(this, method, + parameterValues); + + if (violations.size() == 0) { + com.squareup.okhttp.Call call = recycleBinListCall(owner, page, pageSize, repository, progressListener, progressRequestListener); + return call; + + } else { + throw new BeanValidationException((Set) violations); + } + } catch (NoSuchMethodException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } catch (SecurityException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } + + } + + /** + * List soft-deleted packages in recycle bin + * Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + * @param owner (required) + * @param page A page number within the paginated result set. (optional) + * @param pageSize Number of results to return per page. (optional) + * @param repository Filter packages by repository slug (optional) + * @return List<RecycleBinPackage> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public List recycleBinList(String owner, java.math.BigInteger page, java.math.BigInteger pageSize, String repository) throws ApiException { + ApiResponse> resp = recycleBinListWithHttpInfo(owner, page, pageSize, repository); + return resp.getData(); + } + + /** + * List soft-deleted packages in recycle bin + * Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + * @param owner (required) + * @param page A page number within the paginated result set. (optional) + * @param pageSize Number of results to return per page. (optional) + * @param repository Filter packages by repository slug (optional) + * @return ApiResponse<List<RecycleBinPackage>> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse> recycleBinListWithHttpInfo( @NotNull String owner, java.math.BigInteger page, java.math.BigInteger pageSize, String repository) throws ApiException { + com.squareup.okhttp.Call call = recycleBinListValidateBeforeCall(owner, page, pageSize, repository, null, null); + Type localVarReturnType = new TypeToken>(){}.getType(); + return apiClient.execute(call, localVarReturnType); + } + + /** + * List soft-deleted packages in recycle bin (asynchronously) + * Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + * @param owner (required) + * @param page A page number within the paginated result set. (optional) + * @param pageSize Number of results to return per page. (optional) + * @param repository Filter packages by repository slug (optional) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call recycleBinListAsync(String owner, java.math.BigInteger page, java.math.BigInteger pageSize, String repository, final ApiCallback> callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = recycleBinListValidateBeforeCall(owner, page, pageSize, repository, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken>(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); + return call; + } + /** + * Build call for recycleBinRecycleBinAction + * @param owner (required) + * @param data (optional) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call recycleBinRecycleBinActionCall(String owner, PackageRecycleBin data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = data; + + // create path and map variables + String localVarPath = "/recycle-bin/{owner}/action/" + .replaceAll("\\{" + "owner" + "\\}", apiClient.escapeString(owner.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + + Map localVarHeaderParams = new HashMap(); + + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if(progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "apikey", "basic" }; + if (headers != null) { + localVarHeaderParams.putAll(headers); + } + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call recycleBinRecycleBinActionValidateBeforeCall(String owner, PackageRecycleBin data, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + try { + ValidatorFactory factory = Validation.buildDefaultValidatorFactory(); + ExecutableValidator executableValidator = factory.getValidator().forExecutables(); + + Object[] parameterValues = { owner, data }; + Method method = this.getClass().getMethod("recycleBinRecycleBinActionWithHttpInfo", String.class, PackageRecycleBin.class); + Set> violations = executableValidator.validateParameters(this, method, + parameterValues); + + if (violations.size() == 0) { + com.squareup.okhttp.Call call = recycleBinRecycleBinActionCall(owner, data, progressListener, progressRequestListener); + return call; + + } else { + throw new BeanValidationException((Set) violations); + } + } catch (NoSuchMethodException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } catch (SecurityException e) { + e.printStackTrace(); + throw new ApiException(e.getMessage()); + } + + } + + /** + * + * Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + * @param owner (required) + * @param data (optional) + * @return PackageBulkActionResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public PackageBulkActionResponse recycleBinRecycleBinAction(String owner, PackageRecycleBin data) throws ApiException { + ApiResponse resp = recycleBinRecycleBinActionWithHttpInfo(owner, data); + return resp.getData(); + } + + /** + * + * Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + * @param owner (required) + * @param data (optional) + * @return ApiResponse<PackageBulkActionResponse> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse recycleBinRecycleBinActionWithHttpInfo( @NotNull String owner, PackageRecycleBin data) throws ApiException { + com.squareup.okhttp.Call call = recycleBinRecycleBinActionValidateBeforeCall(owner, data, null, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return apiClient.execute(call, localVarReturnType); + } + + /** + * (asynchronously) + * Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + * @param owner (required) + * @param data (optional) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call recycleBinRecycleBinActionAsync(String owner, PackageRecycleBin data, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = recycleBinRecycleBinActionValidateBeforeCall(owner, data, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); + return call; + } +} diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/ReposApi.java b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/ReposApi.java index 7ce611fc..b4e045cb 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/apis/ReposApi.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/apis/ReposApi.java @@ -820,8 +820,8 @@ private com.squareup.okhttp.Call reposDeleteValidateBeforeCall(String owner, Str } /** - * Delete a repository in a given namespace. - * Delete a repository in a given namespace. + * + * Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. * @param owner (required) * @param identifier (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body @@ -831,8 +831,8 @@ public void reposDelete(String owner, String identifier) throws ApiException { } /** - * Delete a repository in a given namespace. - * Delete a repository in a given namespace. + * + * Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. * @param owner (required) * @param identifier (required) * @return ApiResponse<Void> @@ -844,8 +844,8 @@ public ApiResponse reposDeleteWithHttpInfo( @NotNull String owner, @NotNu } /** - * Delete a repository in a given namespace. (asynchronously) - * Delete a repository in a given namespace. + * (asynchronously) + * Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. * @param owner (required) * @param identifier (required) * @param callback The callback to be executed when the API call finishes diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstream.java index 0405aa70..f8fd32c1 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; @@ -243,6 +245,118 @@ public ModeEnum read(final JsonReader jsonReader) throws IOException { @SerializedName("priority") private java.math.BigInteger priority = null; + @SerializedName("rsa_key_inline") + private String rsaKeyInline = null; + + @SerializedName("rsa_key_url") + private String rsaKeyUrl = null; + + /** + * The RSA signature verification mode for this upstream. + */ + @JsonAdapter(RsaVerificationEnum.Adapter.class) + public enum RsaVerificationEnum { + ALLOW_ALL("Allow All"), + + WARN_ON_INVALID("Warn on Invalid"), + + REJECT_INVALID("Reject Invalid"); + + private String value; + + RsaVerificationEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RsaVerificationEnum fromValue(String text) { + for (RsaVerificationEnum b : RsaVerificationEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RsaVerificationEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RsaVerificationEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RsaVerificationEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("rsa_verification") + private RsaVerificationEnum rsaVerification = RsaVerificationEnum.ALLOW_ALL; + + /** + * The RSA signature verification status for this upstream. + */ + @JsonAdapter(RsaVerificationStatusEnum.Adapter.class) + public enum RsaVerificationStatusEnum { + UNKNOWN("Unknown"), + + INVALID("Invalid"), + + VALID("Valid"), + + INVALID_NO_KEY_("Invalid (No Key)"); + + private String value; + + RsaVerificationStatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RsaVerificationStatusEnum fromValue(String text) { + for (RsaVerificationStatusEnum b : RsaVerificationStatusEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RsaVerificationStatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RsaVerificationStatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RsaVerificationStatusEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("rsa_verification_status") + private RsaVerificationStatusEnum rsaVerificationStatus = RsaVerificationStatusEnum.UNKNOWN; + @SerializedName("slug_perm") private String slugPerm = null; @@ -547,6 +661,60 @@ public void setPriority(java.math.BigInteger priority) { this.priority = priority; } + /** + * A base64-encoded RSA public key in PEM format used to verify package signatures. + * @return rsaKeyInline + **/ + @ApiModelProperty(value = "A base64-encoded RSA public key in PEM format used to verify package signatures.") + public String getRsaKeyInline() { + return rsaKeyInline; + } + + public AlpineUpstream rsaKeyUrl(String rsaKeyUrl) { + this.rsaKeyUrl = rsaKeyUrl; + return this; + } + + /** + * When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + * @return rsaKeyUrl + **/ + @Size(max=254) @ApiModelProperty(value = "When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream.") + public String getRsaKeyUrl() { + return rsaKeyUrl; + } + + public void setRsaKeyUrl(String rsaKeyUrl) { + this.rsaKeyUrl = rsaKeyUrl; + } + + public AlpineUpstream rsaVerification(RsaVerificationEnum rsaVerification) { + this.rsaVerification = rsaVerification; + return this; + } + + /** + * The RSA signature verification mode for this upstream. + * @return rsaVerification + **/ + @ApiModelProperty(value = "The RSA signature verification mode for this upstream.") + public RsaVerificationEnum getRsaVerification() { + return rsaVerification; + } + + public void setRsaVerification(RsaVerificationEnum rsaVerification) { + this.rsaVerification = rsaVerification; + } + + /** + * The RSA signature verification status for this upstream. + * @return rsaVerificationStatus + **/ + @ApiModelProperty(value = "The RSA signature verification status for this upstream.") + public RsaVerificationStatusEnum getRsaVerificationStatus() { + return rsaVerificationStatus; + } + /** * Get slugPerm * @return slugPerm @@ -634,6 +802,10 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.name, alpineUpstream.name) && Objects.equals(this.pendingValidation, alpineUpstream.pendingValidation) && Objects.equals(this.priority, alpineUpstream.priority) && + Objects.equals(this.rsaKeyInline, alpineUpstream.rsaKeyInline) && + Objects.equals(this.rsaKeyUrl, alpineUpstream.rsaKeyUrl) && + Objects.equals(this.rsaVerification, alpineUpstream.rsaVerification) && + Objects.equals(this.rsaVerificationStatus, alpineUpstream.rsaVerificationStatus) && Objects.equals(this.slugPerm, alpineUpstream.slugPerm) && Objects.equals(this.updatedAt, alpineUpstream.updatedAt) && Objects.equals(this.upstreamUrl, alpineUpstream.upstreamUrl) && @@ -642,7 +814,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(authMode, authSecret, authUsername, available, canReindex, createdAt, disableReason, disableReasonText, extraHeader1, extraHeader2, extraValue1, extraValue2, hasFailedSignatureVerification, indexPackageCount, indexStatus, isActive, lastIndexed, mode, name, pendingValidation, priority, slugPerm, updatedAt, upstreamUrl, verifySsl); + return Objects.hash(authMode, authSecret, authUsername, available, canReindex, createdAt, disableReason, disableReasonText, extraHeader1, extraHeader2, extraValue1, extraValue2, hasFailedSignatureVerification, indexPackageCount, indexStatus, isActive, lastIndexed, mode, name, pendingValidation, priority, rsaKeyInline, rsaKeyUrl, rsaVerification, rsaVerificationStatus, slugPerm, updatedAt, upstreamUrl, verifySsl); } @@ -672,6 +844,10 @@ public String toString() { sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" pendingValidation: ").append(toIndentedString(pendingValidation)).append("\n"); sb.append(" priority: ").append(toIndentedString(priority)).append("\n"); + sb.append(" rsaKeyInline: ").append(toIndentedString(rsaKeyInline)).append("\n"); + sb.append(" rsaKeyUrl: ").append(toIndentedString(rsaKeyUrl)).append("\n"); + sb.append(" rsaVerification: ").append(toIndentedString(rsaVerification)).append("\n"); + sb.append(" rsaVerificationStatus: ").append(toIndentedString(rsaVerificationStatus)).append("\n"); sb.append(" slugPerm: ").append(toIndentedString(slugPerm)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append(" upstreamUrl: ").append(toIndentedString(upstreamUrl)).append("\n"); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequest.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequest.java index c6c8d15f..c65038e5 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequest.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequest.java @@ -161,6 +161,61 @@ public ModeEnum read(final JsonReader jsonReader) throws IOException { @SerializedName("priority") private java.math.BigInteger priority = null; + @SerializedName("rsa_key_url") + private String rsaKeyUrl = null; + + /** + * The RSA signature verification mode for this upstream. + */ + @JsonAdapter(RsaVerificationEnum.Adapter.class) + public enum RsaVerificationEnum { + ALLOW_ALL("Allow All"), + + WARN_ON_INVALID("Warn on Invalid"), + + REJECT_INVALID("Reject Invalid"); + + private String value; + + RsaVerificationEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RsaVerificationEnum fromValue(String text) { + for (RsaVerificationEnum b : RsaVerificationEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RsaVerificationEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RsaVerificationEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RsaVerificationEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("rsa_verification") + private RsaVerificationEnum rsaVerification = RsaVerificationEnum.ALLOW_ALL; + @SerializedName("upstream_url") private String upstreamUrl = null; @@ -368,6 +423,42 @@ public void setPriority(java.math.BigInteger priority) { this.priority = priority; } + public AlpineUpstreamRequest rsaKeyUrl(String rsaKeyUrl) { + this.rsaKeyUrl = rsaKeyUrl; + return this; + } + + /** + * When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + * @return rsaKeyUrl + **/ + @Size(max=254) @ApiModelProperty(value = "When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream.") + public String getRsaKeyUrl() { + return rsaKeyUrl; + } + + public void setRsaKeyUrl(String rsaKeyUrl) { + this.rsaKeyUrl = rsaKeyUrl; + } + + public AlpineUpstreamRequest rsaVerification(RsaVerificationEnum rsaVerification) { + this.rsaVerification = rsaVerification; + return this; + } + + /** + * The RSA signature verification mode for this upstream. + * @return rsaVerification + **/ + @ApiModelProperty(value = "The RSA signature verification mode for this upstream.") + public RsaVerificationEnum getRsaVerification() { + return rsaVerification; + } + + public void setRsaVerification(RsaVerificationEnum rsaVerification) { + this.rsaVerification = rsaVerification; + } + public AlpineUpstreamRequest upstreamUrl(String upstreamUrl) { this.upstreamUrl = upstreamUrl; return this; @@ -426,13 +517,15 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.mode, alpineUpstreamRequest.mode) && Objects.equals(this.name, alpineUpstreamRequest.name) && Objects.equals(this.priority, alpineUpstreamRequest.priority) && + Objects.equals(this.rsaKeyUrl, alpineUpstreamRequest.rsaKeyUrl) && + Objects.equals(this.rsaVerification, alpineUpstreamRequest.rsaVerification) && Objects.equals(this.upstreamUrl, alpineUpstreamRequest.upstreamUrl) && Objects.equals(this.verifySsl, alpineUpstreamRequest.verifySsl); } @Override public int hashCode() { - return Objects.hash(authMode, authSecret, authUsername, extraHeader1, extraHeader2, extraValue1, extraValue2, isActive, mode, name, priority, upstreamUrl, verifySsl); + return Objects.hash(authMode, authSecret, authUsername, extraHeader1, extraHeader2, extraValue1, extraValue2, isActive, mode, name, priority, rsaKeyUrl, rsaVerification, upstreamUrl, verifySsl); } @@ -452,6 +545,8 @@ public String toString() { sb.append(" mode: ").append(toIndentedString(mode)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" priority: ").append(toIndentedString(priority)).append("\n"); + sb.append(" rsaKeyUrl: ").append(toIndentedString(rsaKeyUrl)).append("\n"); + sb.append(" rsaVerification: ").append(toIndentedString(rsaVerification)).append("\n"); sb.append(" upstreamUrl: ").append(toIndentedString(upstreamUrl)).append("\n"); sb.append(" verifySsl: ").append(toIndentedString(verifySsl)).append("\n"); sb.append("}"); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequestPatch.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequestPatch.java index 9c7701c9..7dc13c7e 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequestPatch.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/AlpineUpstreamRequestPatch.java @@ -161,6 +161,61 @@ public ModeEnum read(final JsonReader jsonReader) throws IOException { @SerializedName("priority") private java.math.BigInteger priority = null; + @SerializedName("rsa_key_url") + private String rsaKeyUrl = null; + + /** + * The RSA signature verification mode for this upstream. + */ + @JsonAdapter(RsaVerificationEnum.Adapter.class) + public enum RsaVerificationEnum { + ALLOW_ALL("Allow All"), + + WARN_ON_INVALID("Warn on Invalid"), + + REJECT_INVALID("Reject Invalid"); + + private String value; + + RsaVerificationEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static RsaVerificationEnum fromValue(String text) { + for (RsaVerificationEnum b : RsaVerificationEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final RsaVerificationEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public RsaVerificationEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return RsaVerificationEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("rsa_verification") + private RsaVerificationEnum rsaVerification = RsaVerificationEnum.ALLOW_ALL; + @SerializedName("upstream_url") private String upstreamUrl = null; @@ -367,6 +422,42 @@ public void setPriority(java.math.BigInteger priority) { this.priority = priority; } + public AlpineUpstreamRequestPatch rsaKeyUrl(String rsaKeyUrl) { + this.rsaKeyUrl = rsaKeyUrl; + return this; + } + + /** + * When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + * @return rsaKeyUrl + **/ + @Size(max=254) @ApiModelProperty(value = "When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream.") + public String getRsaKeyUrl() { + return rsaKeyUrl; + } + + public void setRsaKeyUrl(String rsaKeyUrl) { + this.rsaKeyUrl = rsaKeyUrl; + } + + public AlpineUpstreamRequestPatch rsaVerification(RsaVerificationEnum rsaVerification) { + this.rsaVerification = rsaVerification; + return this; + } + + /** + * The RSA signature verification mode for this upstream. + * @return rsaVerification + **/ + @ApiModelProperty(value = "The RSA signature verification mode for this upstream.") + public RsaVerificationEnum getRsaVerification() { + return rsaVerification; + } + + public void setRsaVerification(RsaVerificationEnum rsaVerification) { + this.rsaVerification = rsaVerification; + } + public AlpineUpstreamRequestPatch upstreamUrl(String upstreamUrl) { this.upstreamUrl = upstreamUrl; return this; @@ -424,13 +515,15 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.mode, alpineUpstreamRequestPatch.mode) && Objects.equals(this.name, alpineUpstreamRequestPatch.name) && Objects.equals(this.priority, alpineUpstreamRequestPatch.priority) && + Objects.equals(this.rsaKeyUrl, alpineUpstreamRequestPatch.rsaKeyUrl) && + Objects.equals(this.rsaVerification, alpineUpstreamRequestPatch.rsaVerification) && Objects.equals(this.upstreamUrl, alpineUpstreamRequestPatch.upstreamUrl) && Objects.equals(this.verifySsl, alpineUpstreamRequestPatch.verifySsl); } @Override public int hashCode() { - return Objects.hash(authMode, authSecret, authUsername, extraHeader1, extraHeader2, extraValue1, extraValue2, isActive, mode, name, priority, upstreamUrl, verifySsl); + return Objects.hash(authMode, authSecret, authUsername, extraHeader1, extraHeader2, extraValue1, extraValue2, isActive, mode, name, priority, rsaKeyUrl, rsaVerification, upstreamUrl, verifySsl); } @@ -450,6 +543,8 @@ public String toString() { sb.append(" mode: ").append(toIndentedString(mode)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" priority: ").append(toIndentedString(priority)).append("\n"); + sb.append(" rsaKeyUrl: ").append(toIndentedString(rsaKeyUrl)).append("\n"); + sb.append(" rsaVerification: ").append(toIndentedString(rsaVerification)).append("\n"); sb.append(" upstreamUrl: ").append(toIndentedString(upstreamUrl)).append("\n"); sb.append(" verifySsl: ").append(toIndentedString(verifySsl)).append("\n"); sb.append("}"); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/CargoUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/CargoUpstream.java index f74f0b0b..56977cf5 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/CargoUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/CargoUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/ComposerUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/ComposerUpstream.java index 0452abc5..5c430251 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/ComposerUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/ComposerUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/CondaUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/CondaUpstream.java index 984d459d..9cba60c3 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/CondaUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/CondaUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/CranUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/CranUpstream.java index 86a043cd..b60ec72b 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/CranUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/CranUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/DartUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/DartUpstream.java index 9332c595..38cafbb5 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/DartUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/DartUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/DebUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/DebUpstream.java index 18298c40..28f1b0a6 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/DebUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/DebUpstream.java @@ -116,6 +116,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/DockerUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/DockerUpstream.java index 3d44223a..216906a8 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/DockerUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/DockerUpstream.java @@ -110,6 +110,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/GenericUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/GenericUpstream.java index 41c716f2..9a0cf69f 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/GenericUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/GenericUpstream.java @@ -113,6 +113,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/GoUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/GoUpstream.java index 01ace9df..8703a2e5 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/GoUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/GoUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/HelmUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/HelmUpstream.java index 222383f2..3231aafd 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/HelmUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/HelmUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/HexUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/HexUpstream.java index 36381d46..e3b5d8f3 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/HexUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/HexUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/HuggingfaceUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/HuggingfaceUpstream.java index 07c3acdd..74dfd72a 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/HuggingfaceUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/HuggingfaceUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/MavenUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/MavenUpstream.java index 782d11d6..71d91848 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/MavenUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/MavenUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUpload.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUpload.java new file mode 100644 index 00000000..d82632a6 --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUpload.java @@ -0,0 +1,1379 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.models; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.cloudsmith.api.models.Architecture; +import io.cloudsmith.api.models.Distribution; +import io.cloudsmith.api.models.DistributionVersion; +import io.cloudsmith.api.models.PackageFile; +import io.cloudsmith.api.models.Tags; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.io.Serializable; +import javax.validation.constraints.*; +import javax.validation.Valid; + +/** + * McpPackageUpload + */ + +public class McpPackageUpload implements Serializable { + private static final long serialVersionUID = 1L; + + @SerializedName("architectures") + private List architectures = null; + + @SerializedName("cdn_url") + private String cdnUrl = null; + + @SerializedName("checksum_md5") + private String checksumMd5 = null; + + @SerializedName("checksum_sha1") + private String checksumSha1 = null; + + @SerializedName("checksum_sha256") + private String checksumSha256 = null; + + @SerializedName("checksum_sha512") + private String checksumSha512 = null; + + @SerializedName("dependencies_checksum_md5") + private String dependenciesChecksumMd5 = null; + + @SerializedName("dependencies_url") + private String dependenciesUrl = null; + + @SerializedName("description") + private String description = null; + + @SerializedName("display_name") + private String displayName = null; + + @SerializedName("distro") + private Distribution distro = null; + + @SerializedName("distro_version") + private DistributionVersion distroVersion = null; + + @SerializedName("downloads") + private java.math.BigInteger downloads = null; + + @SerializedName("epoch") + private java.math.BigInteger epoch = null; + + @SerializedName("extension") + private String extension = null; + + @SerializedName("filename") + private String filename = null; + + @SerializedName("files") + private List files = null; + + @SerializedName("format") + private String format = null; + + @SerializedName("format_url") + private String formatUrl = null; + + @SerializedName("freeable_storage") + private java.math.BigInteger freeableStorage = null; + + @SerializedName("fully_qualified_name") + private String fullyQualifiedName = null; + + @SerializedName("identifier_perm") + private String identifierPerm = null; + + @SerializedName("identifiers") + private Map identifiers = null; + + @SerializedName("indexed") + private Boolean indexed = null; + + @SerializedName("is_cancellable") + private Boolean isCancellable = null; + + @SerializedName("is_copyable") + private Boolean isCopyable = null; + + @SerializedName("is_deleteable") + private Boolean isDeleteable = null; + + @SerializedName("is_downloadable") + private Boolean isDownloadable = null; + + @SerializedName("is_moveable") + private Boolean isMoveable = null; + + @SerializedName("is_quarantinable") + private Boolean isQuarantinable = null; + + @SerializedName("is_quarantined") + private Boolean isQuarantined = null; + + @SerializedName("is_resyncable") + private Boolean isResyncable = null; + + @SerializedName("is_security_scannable") + private Boolean isSecurityScannable = null; + + @SerializedName("is_sync_awaiting") + private Boolean isSyncAwaiting = null; + + @SerializedName("is_sync_completed") + private Boolean isSyncCompleted = null; + + @SerializedName("is_sync_failed") + private Boolean isSyncFailed = null; + + @SerializedName("is_sync_in_flight") + private Boolean isSyncInFlight = null; + + @SerializedName("is_sync_in_progress") + private Boolean isSyncInProgress = null; + + @SerializedName("license") + private String license = null; + + @SerializedName("name") + private String name = null; + + @SerializedName("namespace") + private String namespace = null; + + @SerializedName("namespace_url") + private String namespaceUrl = null; + + @SerializedName("num_files") + private java.math.BigInteger numFiles = null; + + @SerializedName("origin_repository") + private String originRepository = null; + + @SerializedName("origin_repository_url") + private String originRepositoryUrl = null; + + @SerializedName("package_type") + private java.math.BigInteger packageType = null; + + @SerializedName("policy_violated") + private Boolean policyViolated = null; + + @SerializedName("raw_license") + private String rawLicense = null; + + @SerializedName("release") + private String release = null; + + @SerializedName("repository") + private String repository = null; + + @SerializedName("repository_url") + private String repositoryUrl = null; + + @SerializedName("security_scan_completed_at") + private OffsetDateTime securityScanCompletedAt = null; + + @SerializedName("security_scan_started_at") + private OffsetDateTime securityScanStartedAt = null; + + /** + * Gets or Sets securityScanStatus + */ + @JsonAdapter(SecurityScanStatusEnum.Adapter.class) + public enum SecurityScanStatusEnum { + AWAITING_SECURITY_SCAN("Awaiting Security Scan"), + + SECURITY_SCANNING_IN_PROGRESS("Security Scanning in Progress"), + + SCAN_DETECTED_VULNERABILITIES("Scan Detected Vulnerabilities"), + + SCAN_DETECTED_NO_VULNERABILITIES("Scan Detected No Vulnerabilities"), + + SECURITY_SCANNING_DISABLED("Security Scanning Disabled"), + + SECURITY_SCANNING_FAILED("Security Scanning Failed"), + + SECURITY_SCANNING_SKIPPED("Security Scanning Skipped"), + + SECURITY_SCANNING_NOT_SUPPORTED("Security Scanning Not Supported"); + + private String value; + + SecurityScanStatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static SecurityScanStatusEnum fromValue(String text) { + for (SecurityScanStatusEnum b : SecurityScanStatusEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final SecurityScanStatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public SecurityScanStatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return SecurityScanStatusEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("security_scan_status") + private SecurityScanStatusEnum securityScanStatus = SecurityScanStatusEnum.AWAITING_SECURITY_SCAN; + + @SerializedName("security_scan_status_updated_at") + private OffsetDateTime securityScanStatusUpdatedAt = null; + + @SerializedName("self_html_url") + private String selfHtmlUrl = null; + + @SerializedName("self_url") + private String selfUrl = null; + + @SerializedName("self_webapp_url") + private String selfWebappUrl = null; + + @SerializedName("signature_url") + private String signatureUrl = null; + + @SerializedName("size") + private java.math.BigInteger size = null; + + @SerializedName("slug") + private String slug = null; + + @SerializedName("slug_perm") + private String slugPerm = null; + + @SerializedName("spdx_license") + private String spdxLicense = null; + + @SerializedName("stage") + private java.math.BigInteger stage = null; + + @SerializedName("stage_str") + private String stageStr = null; + + @SerializedName("stage_updated_at") + private OffsetDateTime stageUpdatedAt = null; + + @SerializedName("status") + private java.math.BigInteger status = null; + + @SerializedName("status_reason") + private String statusReason = null; + + @SerializedName("status_str") + private String statusStr = null; + + @SerializedName("status_updated_at") + private OffsetDateTime statusUpdatedAt = null; + + @SerializedName("status_url") + private String statusUrl = null; + + @SerializedName("subtype") + private String subtype = null; + + @SerializedName("summary") + private String summary = null; + + @SerializedName("sync_finished_at") + private OffsetDateTime syncFinishedAt = null; + + @SerializedName("sync_progress") + private java.math.BigInteger syncProgress = null; + + @SerializedName("tags_automatic") + private Tags tagsAutomatic = null; + + @SerializedName("tags_immutable") + private Tags tagsImmutable = null; + + @SerializedName("type_display") + private String typeDisplay = null; + + @SerializedName("uploaded_at") + private OffsetDateTime uploadedAt = null; + + @SerializedName("uploader") + private String uploader = null; + + @SerializedName("uploader_url") + private String uploaderUrl = null; + + @SerializedName("version") + private String version = null; + + @SerializedName("version_orig") + private String versionOrig = null; + + @SerializedName("vulnerability_scan_results_url") + private String vulnerabilityScanResultsUrl = null; + + /** + * Get architectures + * @return architectures + **/ + @Valid + @ApiModelProperty(value = "") + public List getArchitectures() { + return architectures; + } + + /** + * Get cdnUrl + * @return cdnUrl + **/ + @ApiModelProperty(value = "") + public String getCdnUrl() { + return cdnUrl; + } + + /** + * Get checksumMd5 + * @return checksumMd5 + **/ + @ApiModelProperty(value = "") + public String getChecksumMd5() { + return checksumMd5; + } + + /** + * Get checksumSha1 + * @return checksumSha1 + **/ + @ApiModelProperty(value = "") + public String getChecksumSha1() { + return checksumSha1; + } + + /** + * Get checksumSha256 + * @return checksumSha256 + **/ + @ApiModelProperty(value = "") + public String getChecksumSha256() { + return checksumSha256; + } + + /** + * Get checksumSha512 + * @return checksumSha512 + **/ + @ApiModelProperty(value = "") + public String getChecksumSha512() { + return checksumSha512; + } + + /** + * A checksum of all of the package's dependencies. + * @return dependenciesChecksumMd5 + **/ + @ApiModelProperty(value = "A checksum of all of the package's dependencies.") + public String getDependenciesChecksumMd5() { + return dependenciesChecksumMd5; + } + + /** + * Get dependenciesUrl + * @return dependenciesUrl + **/ + @ApiModelProperty(value = "") + public String getDependenciesUrl() { + return dependenciesUrl; + } + + /** + * A textual description of this package. + * @return description + **/ + @ApiModelProperty(value = "A textual description of this package.") + public String getDescription() { + return description; + } + + /** + * Get displayName + * @return displayName + **/ + @ApiModelProperty(value = "") + public String getDisplayName() { + return displayName; + } + + public McpPackageUpload distro(Distribution distro) { + this.distro = distro; + return this; + } + + /** + * Get distro + * @return distro + **/ + @Valid + @ApiModelProperty(value = "") + public Distribution getDistro() { + return distro; + } + + public void setDistro(Distribution distro) { + this.distro = distro; + } + + public McpPackageUpload distroVersion(DistributionVersion distroVersion) { + this.distroVersion = distroVersion; + return this; + } + + /** + * Get distroVersion + * @return distroVersion + **/ + @Valid + @ApiModelProperty(value = "") + public DistributionVersion getDistroVersion() { + return distroVersion; + } + + public void setDistroVersion(DistributionVersion distroVersion) { + this.distroVersion = distroVersion; + } + + /** + * Get downloads + * @return downloads + **/ + @ApiModelProperty(value = "") + public java.math.BigInteger getDownloads() { + return downloads; + } + + /** + * The epoch of the package version (if any). + * @return epoch + **/ + @ApiModelProperty(value = "The epoch of the package version (if any).") + public java.math.BigInteger getEpoch() { + return epoch; + } + + /** + * Get extension + * @return extension + **/ + @ApiModelProperty(value = "") + public String getExtension() { + return extension; + } + + /** + * Get filename + * @return filename + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getFilename() { + return filename; + } + + /** + * Get files + * @return files + **/ + @Valid + @ApiModelProperty(value = "") + public List getFiles() { + return files; + } + + /** + * Get format + * @return format + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getFormat() { + return format; + } + + /** + * Get formatUrl + * @return formatUrl + **/ + @ApiModelProperty(value = "") + public String getFormatUrl() { + return formatUrl; + } + + /** + * Amount of storage that will be freed if this package is deleted + * @return freeableStorage + **/ + @ApiModelProperty(value = "Amount of storage that will be freed if this package is deleted") + public java.math.BigInteger getFreeableStorage() { + return freeableStorage; + } + + /** + * Get fullyQualifiedName + * @return fullyQualifiedName + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getFullyQualifiedName() { + return fullyQualifiedName; + } + + /** + * Unique and permanent identifier for the package. + * @return identifierPerm + **/ + @Size(min=1) @ApiModelProperty(value = "Unique and permanent identifier for the package.") + public String getIdentifierPerm() { + return identifierPerm; + } + + /** + * Return a map of identifier field names and their values. + * @return identifiers + **/ + @ApiModelProperty(value = "Return a map of identifier field names and their values.") + public Map getIdentifiers() { + return identifiers; + } + + /** + * Get indexed + * @return indexed + **/ + @ApiModelProperty(value = "") + public Boolean isIndexed() { + return indexed; + } + + /** + * Get isCancellable + * @return isCancellable + **/ + @ApiModelProperty(value = "") + public Boolean isIsCancellable() { + return isCancellable; + } + + /** + * Get isCopyable + * @return isCopyable + **/ + @ApiModelProperty(value = "") + public Boolean isIsCopyable() { + return isCopyable; + } + + /** + * Get isDeleteable + * @return isDeleteable + **/ + @ApiModelProperty(value = "") + public Boolean isIsDeleteable() { + return isDeleteable; + } + + /** + * Get isDownloadable + * @return isDownloadable + **/ + @ApiModelProperty(value = "") + public Boolean isIsDownloadable() { + return isDownloadable; + } + + /** + * Get isMoveable + * @return isMoveable + **/ + @ApiModelProperty(value = "") + public Boolean isIsMoveable() { + return isMoveable; + } + + /** + * Get isQuarantinable + * @return isQuarantinable + **/ + @ApiModelProperty(value = "") + public Boolean isIsQuarantinable() { + return isQuarantinable; + } + + /** + * Get isQuarantined + * @return isQuarantined + **/ + @ApiModelProperty(value = "") + public Boolean isIsQuarantined() { + return isQuarantined; + } + + /** + * Get isResyncable + * @return isResyncable + **/ + @ApiModelProperty(value = "") + public Boolean isIsResyncable() { + return isResyncable; + } + + /** + * Get isSecurityScannable + * @return isSecurityScannable + **/ + @ApiModelProperty(value = "") + public Boolean isIsSecurityScannable() { + return isSecurityScannable; + } + + /** + * Get isSyncAwaiting + * @return isSyncAwaiting + **/ + @ApiModelProperty(value = "") + public Boolean isIsSyncAwaiting() { + return isSyncAwaiting; + } + + /** + * Get isSyncCompleted + * @return isSyncCompleted + **/ + @ApiModelProperty(value = "") + public Boolean isIsSyncCompleted() { + return isSyncCompleted; + } + + /** + * Get isSyncFailed + * @return isSyncFailed + **/ + @ApiModelProperty(value = "") + public Boolean isIsSyncFailed() { + return isSyncFailed; + } + + /** + * Get isSyncInFlight + * @return isSyncInFlight + **/ + @ApiModelProperty(value = "") + public Boolean isIsSyncInFlight() { + return isSyncInFlight; + } + + /** + * Get isSyncInProgress + * @return isSyncInProgress + **/ + @ApiModelProperty(value = "") + public Boolean isIsSyncInProgress() { + return isSyncInProgress; + } + + /** + * The license of this package. + * @return license + **/ + @ApiModelProperty(value = "The license of this package.") + public String getLicense() { + return license; + } + + /** + * The name of this package. + * @return name + **/ + @ApiModelProperty(value = "The name of this package.") + public String getName() { + return name; + } + + /** + * Get namespace + * @return namespace + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getNamespace() { + return namespace; + } + + /** + * Get namespaceUrl + * @return namespaceUrl + **/ + @ApiModelProperty(value = "") + public String getNamespaceUrl() { + return namespaceUrl; + } + + /** + * Get numFiles + * @return numFiles + **/ + @ApiModelProperty(value = "") + public java.math.BigInteger getNumFiles() { + return numFiles; + } + + /** + * Get originRepository + * @return originRepository + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getOriginRepository() { + return originRepository; + } + + /** + * Get originRepositoryUrl + * @return originRepositoryUrl + **/ + @ApiModelProperty(value = "") + public String getOriginRepositoryUrl() { + return originRepositoryUrl; + } + + /** + * The type of package contents. + * @return packageType + **/ + @ApiModelProperty(value = "The type of package contents.") + public java.math.BigInteger getPackageType() { + return packageType; + } + + /** + * Whether or not the package has violated any policy. + * @return policyViolated + **/ + @ApiModelProperty(value = "Whether or not the package has violated any policy.") + public Boolean isPolicyViolated() { + return policyViolated; + } + + /** + * The raw license string. + * @return rawLicense + **/ + @Size(min=1) @ApiModelProperty(value = "The raw license string.") + public String getRawLicense() { + return rawLicense; + } + + /** + * The release of the package version (if any). + * @return release + **/ + @ApiModelProperty(value = "The release of the package version (if any).") + public String getRelease() { + return release; + } + + /** + * Get repository + * @return repository + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getRepository() { + return repository; + } + + /** + * Get repositoryUrl + * @return repositoryUrl + **/ + @ApiModelProperty(value = "") + public String getRepositoryUrl() { + return repositoryUrl; + } + + /** + * The datetime the security scanning was completed. + * @return securityScanCompletedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the security scanning was completed.") + public OffsetDateTime getSecurityScanCompletedAt() { + return securityScanCompletedAt; + } + + /** + * The datetime the security scanning was started. + * @return securityScanStartedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the security scanning was started.") + public OffsetDateTime getSecurityScanStartedAt() { + return securityScanStartedAt; + } + + /** + * Get securityScanStatus + * @return securityScanStatus + **/ + @ApiModelProperty(value = "") + public SecurityScanStatusEnum getSecurityScanStatus() { + return securityScanStatus; + } + + /** + * The datetime the security scanning status was updated. + * @return securityScanStatusUpdatedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the security scanning status was updated.") + public OffsetDateTime getSecurityScanStatusUpdatedAt() { + return securityScanStatusUpdatedAt; + } + + /** + * Get selfHtmlUrl + * @return selfHtmlUrl + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getSelfHtmlUrl() { + return selfHtmlUrl; + } + + /** + * Get selfUrl + * @return selfUrl + **/ + @ApiModelProperty(value = "") + public String getSelfUrl() { + return selfUrl; + } + + /** + * Get selfWebappUrl + * @return selfWebappUrl + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getSelfWebappUrl() { + return selfWebappUrl; + } + + /** + * Get signatureUrl + * @return signatureUrl + **/ + @ApiModelProperty(value = "") + public String getSignatureUrl() { + return signatureUrl; + } + + /** + * The calculated size of the package. + * @return size + **/ + @ApiModelProperty(value = "The calculated size of the package.") + public java.math.BigInteger getSize() { + return size; + } + + /** + * The public unique identifier for the package. + * @return slug + **/ + @Pattern(regexp="^[-a-zA-Z0-9_]+$") @Size(min=1) @ApiModelProperty(value = "The public unique identifier for the package.") + public String getSlug() { + return slug; + } + + /** + * Get slugPerm + * @return slugPerm + **/ + @Pattern(regexp="^[-a-zA-Z0-9_]+$") @Size(min=1) @ApiModelProperty(value = "") + public String getSlugPerm() { + return slugPerm; + } + + /** + * The SPDX license identifier for this package. + * @return spdxLicense + **/ + @Size(min=1) @ApiModelProperty(value = "The SPDX license identifier for this package.") + public String getSpdxLicense() { + return spdxLicense; + } + + /** + * The synchronisation (in progress) stage of the package. + * @return stage + **/ + @ApiModelProperty(value = "The synchronisation (in progress) stage of the package.") + public java.math.BigInteger getStage() { + return stage; + } + + /** + * Get stageStr + * @return stageStr + **/ + @ApiModelProperty(value = "") + public String getStageStr() { + return stageStr; + } + + /** + * The datetime the package stage was updated at. + * @return stageUpdatedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the package stage was updated at.") + public OffsetDateTime getStageUpdatedAt() { + return stageUpdatedAt; + } + + /** + * The synchronisation status of the package. + * @return status + **/ + @ApiModelProperty(value = "The synchronisation status of the package.") + public java.math.BigInteger getStatus() { + return status; + } + + /** + * A textual description for the synchronous status reason (if any + * @return statusReason + **/ + @ApiModelProperty(value = "A textual description for the synchronous status reason (if any") + public String getStatusReason() { + return statusReason; + } + + /** + * Get statusStr + * @return statusStr + **/ + @ApiModelProperty(value = "") + public String getStatusStr() { + return statusStr; + } + + /** + * The datetime the package status was updated at. + * @return statusUpdatedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the package status was updated at.") + public OffsetDateTime getStatusUpdatedAt() { + return statusUpdatedAt; + } + + /** + * Get statusUrl + * @return statusUrl + **/ + @ApiModelProperty(value = "") + public String getStatusUrl() { + return statusUrl; + } + + /** + * Get subtype + * @return subtype + **/ + @ApiModelProperty(value = "") + public String getSubtype() { + return subtype; + } + + /** + * A one-liner synopsis of this package. + * @return summary + **/ + @ApiModelProperty(value = "A one-liner synopsis of this package.") + public String getSummary() { + return summary; + } + + /** + * The datetime the package sync was finished at. + * @return syncFinishedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the package sync was finished at.") + public OffsetDateTime getSyncFinishedAt() { + return syncFinishedAt; + } + + /** + * Synchronisation progress (from 0-100) + * @return syncProgress + **/ + @ApiModelProperty(value = "Synchronisation progress (from 0-100)") + public java.math.BigInteger getSyncProgress() { + return syncProgress; + } + + public McpPackageUpload tagsAutomatic(Tags tagsAutomatic) { + this.tagsAutomatic = tagsAutomatic; + return this; + } + + /** + * Get tagsAutomatic + * @return tagsAutomatic + **/ + @Valid + @ApiModelProperty(value = "") + public Tags getTagsAutomatic() { + return tagsAutomatic; + } + + public void setTagsAutomatic(Tags tagsAutomatic) { + this.tagsAutomatic = tagsAutomatic; + } + + public McpPackageUpload tagsImmutable(Tags tagsImmutable) { + this.tagsImmutable = tagsImmutable; + return this; + } + + /** + * Get tagsImmutable + * @return tagsImmutable + **/ + @Valid + @ApiModelProperty(value = "") + public Tags getTagsImmutable() { + return tagsImmutable; + } + + public void setTagsImmutable(Tags tagsImmutable) { + this.tagsImmutable = tagsImmutable; + } + + /** + * Get typeDisplay + * @return typeDisplay + **/ + @ApiModelProperty(value = "") + public String getTypeDisplay() { + return typeDisplay; + } + + /** + * The date this package was uploaded. + * @return uploadedAt + **/ + @Valid + @ApiModelProperty(value = "The date this package was uploaded.") + public OffsetDateTime getUploadedAt() { + return uploadedAt; + } + + /** + * Get uploader + * @return uploader + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getUploader() { + return uploader; + } + + /** + * Get uploaderUrl + * @return uploaderUrl + **/ + @ApiModelProperty(value = "") + public String getUploaderUrl() { + return uploaderUrl; + } + + public McpPackageUpload version(String version) { + this.version = version; + return this; + } + + /** + * The raw version for this package. + * @return version + **/ + @Size(max=255) @ApiModelProperty(value = "The raw version for this package.") + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + /** + * Get versionOrig + * @return versionOrig + **/ + @ApiModelProperty(value = "") + public String getVersionOrig() { + return versionOrig; + } + + /** + * Get vulnerabilityScanResultsUrl + * @return vulnerabilityScanResultsUrl + **/ + @ApiModelProperty(value = "") + public String getVulnerabilityScanResultsUrl() { + return vulnerabilityScanResultsUrl; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + McpPackageUpload mcpPackageUpload = (McpPackageUpload) o; + return Objects.equals(this.architectures, mcpPackageUpload.architectures) && + Objects.equals(this.cdnUrl, mcpPackageUpload.cdnUrl) && + Objects.equals(this.checksumMd5, mcpPackageUpload.checksumMd5) && + Objects.equals(this.checksumSha1, mcpPackageUpload.checksumSha1) && + Objects.equals(this.checksumSha256, mcpPackageUpload.checksumSha256) && + Objects.equals(this.checksumSha512, mcpPackageUpload.checksumSha512) && + Objects.equals(this.dependenciesChecksumMd5, mcpPackageUpload.dependenciesChecksumMd5) && + Objects.equals(this.dependenciesUrl, mcpPackageUpload.dependenciesUrl) && + Objects.equals(this.description, mcpPackageUpload.description) && + Objects.equals(this.displayName, mcpPackageUpload.displayName) && + Objects.equals(this.distro, mcpPackageUpload.distro) && + Objects.equals(this.distroVersion, mcpPackageUpload.distroVersion) && + Objects.equals(this.downloads, mcpPackageUpload.downloads) && + Objects.equals(this.epoch, mcpPackageUpload.epoch) && + Objects.equals(this.extension, mcpPackageUpload.extension) && + Objects.equals(this.filename, mcpPackageUpload.filename) && + Objects.equals(this.files, mcpPackageUpload.files) && + Objects.equals(this.format, mcpPackageUpload.format) && + Objects.equals(this.formatUrl, mcpPackageUpload.formatUrl) && + Objects.equals(this.freeableStorage, mcpPackageUpload.freeableStorage) && + Objects.equals(this.fullyQualifiedName, mcpPackageUpload.fullyQualifiedName) && + Objects.equals(this.identifierPerm, mcpPackageUpload.identifierPerm) && + Objects.equals(this.identifiers, mcpPackageUpload.identifiers) && + Objects.equals(this.indexed, mcpPackageUpload.indexed) && + Objects.equals(this.isCancellable, mcpPackageUpload.isCancellable) && + Objects.equals(this.isCopyable, mcpPackageUpload.isCopyable) && + Objects.equals(this.isDeleteable, mcpPackageUpload.isDeleteable) && + Objects.equals(this.isDownloadable, mcpPackageUpload.isDownloadable) && + Objects.equals(this.isMoveable, mcpPackageUpload.isMoveable) && + Objects.equals(this.isQuarantinable, mcpPackageUpload.isQuarantinable) && + Objects.equals(this.isQuarantined, mcpPackageUpload.isQuarantined) && + Objects.equals(this.isResyncable, mcpPackageUpload.isResyncable) && + Objects.equals(this.isSecurityScannable, mcpPackageUpload.isSecurityScannable) && + Objects.equals(this.isSyncAwaiting, mcpPackageUpload.isSyncAwaiting) && + Objects.equals(this.isSyncCompleted, mcpPackageUpload.isSyncCompleted) && + Objects.equals(this.isSyncFailed, mcpPackageUpload.isSyncFailed) && + Objects.equals(this.isSyncInFlight, mcpPackageUpload.isSyncInFlight) && + Objects.equals(this.isSyncInProgress, mcpPackageUpload.isSyncInProgress) && + Objects.equals(this.license, mcpPackageUpload.license) && + Objects.equals(this.name, mcpPackageUpload.name) && + Objects.equals(this.namespace, mcpPackageUpload.namespace) && + Objects.equals(this.namespaceUrl, mcpPackageUpload.namespaceUrl) && + Objects.equals(this.numFiles, mcpPackageUpload.numFiles) && + Objects.equals(this.originRepository, mcpPackageUpload.originRepository) && + Objects.equals(this.originRepositoryUrl, mcpPackageUpload.originRepositoryUrl) && + Objects.equals(this.packageType, mcpPackageUpload.packageType) && + Objects.equals(this.policyViolated, mcpPackageUpload.policyViolated) && + Objects.equals(this.rawLicense, mcpPackageUpload.rawLicense) && + Objects.equals(this.release, mcpPackageUpload.release) && + Objects.equals(this.repository, mcpPackageUpload.repository) && + Objects.equals(this.repositoryUrl, mcpPackageUpload.repositoryUrl) && + Objects.equals(this.securityScanCompletedAt, mcpPackageUpload.securityScanCompletedAt) && + Objects.equals(this.securityScanStartedAt, mcpPackageUpload.securityScanStartedAt) && + Objects.equals(this.securityScanStatus, mcpPackageUpload.securityScanStatus) && + Objects.equals(this.securityScanStatusUpdatedAt, mcpPackageUpload.securityScanStatusUpdatedAt) && + Objects.equals(this.selfHtmlUrl, mcpPackageUpload.selfHtmlUrl) && + Objects.equals(this.selfUrl, mcpPackageUpload.selfUrl) && + Objects.equals(this.selfWebappUrl, mcpPackageUpload.selfWebappUrl) && + Objects.equals(this.signatureUrl, mcpPackageUpload.signatureUrl) && + Objects.equals(this.size, mcpPackageUpload.size) && + Objects.equals(this.slug, mcpPackageUpload.slug) && + Objects.equals(this.slugPerm, mcpPackageUpload.slugPerm) && + Objects.equals(this.spdxLicense, mcpPackageUpload.spdxLicense) && + Objects.equals(this.stage, mcpPackageUpload.stage) && + Objects.equals(this.stageStr, mcpPackageUpload.stageStr) && + Objects.equals(this.stageUpdatedAt, mcpPackageUpload.stageUpdatedAt) && + Objects.equals(this.status, mcpPackageUpload.status) && + Objects.equals(this.statusReason, mcpPackageUpload.statusReason) && + Objects.equals(this.statusStr, mcpPackageUpload.statusStr) && + Objects.equals(this.statusUpdatedAt, mcpPackageUpload.statusUpdatedAt) && + Objects.equals(this.statusUrl, mcpPackageUpload.statusUrl) && + Objects.equals(this.subtype, mcpPackageUpload.subtype) && + Objects.equals(this.summary, mcpPackageUpload.summary) && + Objects.equals(this.syncFinishedAt, mcpPackageUpload.syncFinishedAt) && + Objects.equals(this.syncProgress, mcpPackageUpload.syncProgress) && + Objects.equals(this.tagsAutomatic, mcpPackageUpload.tagsAutomatic) && + Objects.equals(this.tagsImmutable, mcpPackageUpload.tagsImmutable) && + Objects.equals(this.typeDisplay, mcpPackageUpload.typeDisplay) && + Objects.equals(this.uploadedAt, mcpPackageUpload.uploadedAt) && + Objects.equals(this.uploader, mcpPackageUpload.uploader) && + Objects.equals(this.uploaderUrl, mcpPackageUpload.uploaderUrl) && + Objects.equals(this.version, mcpPackageUpload.version) && + Objects.equals(this.versionOrig, mcpPackageUpload.versionOrig) && + Objects.equals(this.vulnerabilityScanResultsUrl, mcpPackageUpload.vulnerabilityScanResultsUrl); + } + + @Override + public int hashCode() { + return Objects.hash(architectures, cdnUrl, checksumMd5, checksumSha1, checksumSha256, checksumSha512, dependenciesChecksumMd5, dependenciesUrl, description, displayName, distro, distroVersion, downloads, epoch, extension, filename, files, format, formatUrl, freeableStorage, fullyQualifiedName, identifierPerm, identifiers, indexed, isCancellable, isCopyable, isDeleteable, isDownloadable, isMoveable, isQuarantinable, isQuarantined, isResyncable, isSecurityScannable, isSyncAwaiting, isSyncCompleted, isSyncFailed, isSyncInFlight, isSyncInProgress, license, name, namespace, namespaceUrl, numFiles, originRepository, originRepositoryUrl, packageType, policyViolated, rawLicense, release, repository, repositoryUrl, securityScanCompletedAt, securityScanStartedAt, securityScanStatus, securityScanStatusUpdatedAt, selfHtmlUrl, selfUrl, selfWebappUrl, signatureUrl, size, slug, slugPerm, spdxLicense, stage, stageStr, stageUpdatedAt, status, statusReason, statusStr, statusUpdatedAt, statusUrl, subtype, summary, syncFinishedAt, syncProgress, tagsAutomatic, tagsImmutable, typeDisplay, uploadedAt, uploader, uploaderUrl, version, versionOrig, vulnerabilityScanResultsUrl); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class McpPackageUpload {\n"); + + sb.append(" architectures: ").append(toIndentedString(architectures)).append("\n"); + sb.append(" cdnUrl: ").append(toIndentedString(cdnUrl)).append("\n"); + sb.append(" checksumMd5: ").append(toIndentedString(checksumMd5)).append("\n"); + sb.append(" checksumSha1: ").append(toIndentedString(checksumSha1)).append("\n"); + sb.append(" checksumSha256: ").append(toIndentedString(checksumSha256)).append("\n"); + sb.append(" checksumSha512: ").append(toIndentedString(checksumSha512)).append("\n"); + sb.append(" dependenciesChecksumMd5: ").append(toIndentedString(dependenciesChecksumMd5)).append("\n"); + sb.append(" dependenciesUrl: ").append(toIndentedString(dependenciesUrl)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" displayName: ").append(toIndentedString(displayName)).append("\n"); + sb.append(" distro: ").append(toIndentedString(distro)).append("\n"); + sb.append(" distroVersion: ").append(toIndentedString(distroVersion)).append("\n"); + sb.append(" downloads: ").append(toIndentedString(downloads)).append("\n"); + sb.append(" epoch: ").append(toIndentedString(epoch)).append("\n"); + sb.append(" extension: ").append(toIndentedString(extension)).append("\n"); + sb.append(" filename: ").append(toIndentedString(filename)).append("\n"); + sb.append(" files: ").append(toIndentedString(files)).append("\n"); + sb.append(" format: ").append(toIndentedString(format)).append("\n"); + sb.append(" formatUrl: ").append(toIndentedString(formatUrl)).append("\n"); + sb.append(" freeableStorage: ").append(toIndentedString(freeableStorage)).append("\n"); + sb.append(" fullyQualifiedName: ").append(toIndentedString(fullyQualifiedName)).append("\n"); + sb.append(" identifierPerm: ").append(toIndentedString(identifierPerm)).append("\n"); + sb.append(" identifiers: ").append(toIndentedString(identifiers)).append("\n"); + sb.append(" indexed: ").append(toIndentedString(indexed)).append("\n"); + sb.append(" isCancellable: ").append(toIndentedString(isCancellable)).append("\n"); + sb.append(" isCopyable: ").append(toIndentedString(isCopyable)).append("\n"); + sb.append(" isDeleteable: ").append(toIndentedString(isDeleteable)).append("\n"); + sb.append(" isDownloadable: ").append(toIndentedString(isDownloadable)).append("\n"); + sb.append(" isMoveable: ").append(toIndentedString(isMoveable)).append("\n"); + sb.append(" isQuarantinable: ").append(toIndentedString(isQuarantinable)).append("\n"); + sb.append(" isQuarantined: ").append(toIndentedString(isQuarantined)).append("\n"); + sb.append(" isResyncable: ").append(toIndentedString(isResyncable)).append("\n"); + sb.append(" isSecurityScannable: ").append(toIndentedString(isSecurityScannable)).append("\n"); + sb.append(" isSyncAwaiting: ").append(toIndentedString(isSyncAwaiting)).append("\n"); + sb.append(" isSyncCompleted: ").append(toIndentedString(isSyncCompleted)).append("\n"); + sb.append(" isSyncFailed: ").append(toIndentedString(isSyncFailed)).append("\n"); + sb.append(" isSyncInFlight: ").append(toIndentedString(isSyncInFlight)).append("\n"); + sb.append(" isSyncInProgress: ").append(toIndentedString(isSyncInProgress)).append("\n"); + sb.append(" license: ").append(toIndentedString(license)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); + sb.append(" namespaceUrl: ").append(toIndentedString(namespaceUrl)).append("\n"); + sb.append(" numFiles: ").append(toIndentedString(numFiles)).append("\n"); + sb.append(" originRepository: ").append(toIndentedString(originRepository)).append("\n"); + sb.append(" originRepositoryUrl: ").append(toIndentedString(originRepositoryUrl)).append("\n"); + sb.append(" packageType: ").append(toIndentedString(packageType)).append("\n"); + sb.append(" policyViolated: ").append(toIndentedString(policyViolated)).append("\n"); + sb.append(" rawLicense: ").append(toIndentedString(rawLicense)).append("\n"); + sb.append(" release: ").append(toIndentedString(release)).append("\n"); + sb.append(" repository: ").append(toIndentedString(repository)).append("\n"); + sb.append(" repositoryUrl: ").append(toIndentedString(repositoryUrl)).append("\n"); + sb.append(" securityScanCompletedAt: ").append(toIndentedString(securityScanCompletedAt)).append("\n"); + sb.append(" securityScanStartedAt: ").append(toIndentedString(securityScanStartedAt)).append("\n"); + sb.append(" securityScanStatus: ").append(toIndentedString(securityScanStatus)).append("\n"); + sb.append(" securityScanStatusUpdatedAt: ").append(toIndentedString(securityScanStatusUpdatedAt)).append("\n"); + sb.append(" selfHtmlUrl: ").append(toIndentedString(selfHtmlUrl)).append("\n"); + sb.append(" selfUrl: ").append(toIndentedString(selfUrl)).append("\n"); + sb.append(" selfWebappUrl: ").append(toIndentedString(selfWebappUrl)).append("\n"); + sb.append(" signatureUrl: ").append(toIndentedString(signatureUrl)).append("\n"); + sb.append(" size: ").append(toIndentedString(size)).append("\n"); + sb.append(" slug: ").append(toIndentedString(slug)).append("\n"); + sb.append(" slugPerm: ").append(toIndentedString(slugPerm)).append("\n"); + sb.append(" spdxLicense: ").append(toIndentedString(spdxLicense)).append("\n"); + sb.append(" stage: ").append(toIndentedString(stage)).append("\n"); + sb.append(" stageStr: ").append(toIndentedString(stageStr)).append("\n"); + sb.append(" stageUpdatedAt: ").append(toIndentedString(stageUpdatedAt)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" statusReason: ").append(toIndentedString(statusReason)).append("\n"); + sb.append(" statusStr: ").append(toIndentedString(statusStr)).append("\n"); + sb.append(" statusUpdatedAt: ").append(toIndentedString(statusUpdatedAt)).append("\n"); + sb.append(" statusUrl: ").append(toIndentedString(statusUrl)).append("\n"); + sb.append(" subtype: ").append(toIndentedString(subtype)).append("\n"); + sb.append(" summary: ").append(toIndentedString(summary)).append("\n"); + sb.append(" syncFinishedAt: ").append(toIndentedString(syncFinishedAt)).append("\n"); + sb.append(" syncProgress: ").append(toIndentedString(syncProgress)).append("\n"); + sb.append(" tagsAutomatic: ").append(toIndentedString(tagsAutomatic)).append("\n"); + sb.append(" tagsImmutable: ").append(toIndentedString(tagsImmutable)).append("\n"); + sb.append(" typeDisplay: ").append(toIndentedString(typeDisplay)).append("\n"); + sb.append(" uploadedAt: ").append(toIndentedString(uploadedAt)).append("\n"); + sb.append(" uploader: ").append(toIndentedString(uploader)).append("\n"); + sb.append(" uploaderUrl: ").append(toIndentedString(uploaderUrl)).append("\n"); + sb.append(" version: ").append(toIndentedString(version)).append("\n"); + sb.append(" versionOrig: ").append(toIndentedString(versionOrig)).append("\n"); + sb.append(" vulnerabilityScanResultsUrl: ").append(toIndentedString(vulnerabilityScanResultsUrl)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUploadRequest.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUploadRequest.java new file mode 100644 index 00000000..997dcdb7 --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/McpPackageUploadRequest.java @@ -0,0 +1,169 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.models; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.io.Serializable; +import javax.validation.constraints.*; +import javax.validation.Valid; + +/** + * McpPackageUploadRequest + */ + +public class McpPackageUploadRequest implements Serializable { + private static final long serialVersionUID = 1L; + + @SerializedName("package_file") + private String packageFile = null; + + @SerializedName("republish") + private Boolean republish = null; + + @SerializedName("tags") + private String tags = null; + + @SerializedName("version") + private String version = null; + + public McpPackageUploadRequest packageFile(String packageFile) { + this.packageFile = packageFile; + return this; + } + + /** + * The primary file for the package. + * @return packageFile + **/ + @NotNull + @Size(min=1) @ApiModelProperty(required = true, value = "The primary file for the package.") + public String getPackageFile() { + return packageFile; + } + + public void setPackageFile(String packageFile) { + this.packageFile = packageFile; + } + + public McpPackageUploadRequest republish(Boolean republish) { + this.republish = republish; + return this; + } + + /** + * If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. + * @return republish + **/ + @ApiModelProperty(value = "If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate.") + public Boolean isRepublish() { + return republish; + } + + public void setRepublish(Boolean republish) { + this.republish = republish; + } + + public McpPackageUploadRequest tags(String tags) { + this.tags = tags; + return this; + } + + /** + * A comma-separated values list of tags to add to the package. + * @return tags + **/ + @Size(min=1,max=1024) @ApiModelProperty(value = "A comma-separated values list of tags to add to the package.") + public String getTags() { + return tags; + } + + public void setTags(String tags) { + this.tags = tags; + } + + public McpPackageUploadRequest version(String version) { + this.version = version; + return this; + } + + /** + * The raw version for this package. + * @return version + **/ + @Size(max=255) @ApiModelProperty(value = "The raw version for this package.") + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + McpPackageUploadRequest mcpPackageUploadRequest = (McpPackageUploadRequest) o; + return Objects.equals(this.packageFile, mcpPackageUploadRequest.packageFile) && + Objects.equals(this.republish, mcpPackageUploadRequest.republish) && + Objects.equals(this.tags, mcpPackageUploadRequest.tags) && + Objects.equals(this.version, mcpPackageUploadRequest.version); + } + + @Override + public int hashCode() { + return Objects.hash(packageFile, republish, tags, version); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class McpPackageUploadRequest {\n"); + + sb.append(" packageFile: ").append(toIndentedString(packageFile)).append("\n"); + sb.append(" republish: ").append(toIndentedString(republish)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" version: ").append(toIndentedString(version)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/NpmUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/NpmUpstream.java index 12d3281e..d467e8e1 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/NpmUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/NpmUpstream.java @@ -113,6 +113,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/NugetUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/NugetUpstream.java index f77b5061..6d4043c2 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/NugetUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/NugetUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/PackageRecycleBin.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/PackageRecycleBin.java new file mode 100644 index 00000000..2639bf7d --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/PackageRecycleBin.java @@ -0,0 +1,201 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.models; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import java.io.Serializable; +import javax.validation.constraints.*; +import javax.validation.Valid; + +/** + * PackageRecycleBin + */ + +public class PackageRecycleBin implements Serializable { + private static final long serialVersionUID = 1L; + + /** + * The action to perform on soft-deleted packages. + */ + @JsonAdapter(ActionEnum.Adapter.class) + public enum ActionEnum { + HARD_DELETE("hard_delete"), + + RESTORE("restore"); + + private String value; + + ActionEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static ActionEnum fromValue(String text) { + for (ActionEnum b : ActionEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final ActionEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public ActionEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return ActionEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("action") + private ActionEnum action = null; + + @SerializedName("identifiers") + private List identifiers = new ArrayList<>(); + + @SerializedName("repository") + private String repository = null; + + public PackageRecycleBin action(ActionEnum action) { + this.action = action; + return this; + } + + /** + * The action to perform on soft-deleted packages. + * @return action + **/ + @NotNull + @ApiModelProperty(required = true, value = "The action to perform on soft-deleted packages.") + public ActionEnum getAction() { + return action; + } + + public void setAction(ActionEnum action) { + this.action = action; + } + + public PackageRecycleBin identifiers(List identifiers) { + this.identifiers = identifiers; + return this; + } + + public PackageRecycleBin addIdentifiersItem(String identifiersItem) { + this.identifiers.add(identifiersItem); + return this; + } + + /** + * A list of soft-deleted package identifiers to action. + * @return identifiers + **/ + @NotNull + @Size(min=1,max=100) @ApiModelProperty(required = true, value = "A list of soft-deleted package identifiers to action.") + public List getIdentifiers() { + return identifiers; + } + + public void setIdentifiers(List identifiers) { + this.identifiers = identifiers; + } + + public PackageRecycleBin repository(String repository) { + this.repository = repository; + return this; + } + + /** + * The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. + * @return repository + **/ + @Size(min=1,max=255) @ApiModelProperty(value = "The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace.") + public String getRepository() { + return repository; + } + + public void setRepository(String repository) { + this.repository = repository; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + PackageRecycleBin packageRecycleBin = (PackageRecycleBin) o; + return Objects.equals(this.action, packageRecycleBin.action) && + Objects.equals(this.identifiers, packageRecycleBin.identifiers) && + Objects.equals(this.repository, packageRecycleBin.repository); + } + + @Override + public int hashCode() { + return Objects.hash(action, identifiers, repository); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class PackageRecycleBin {\n"); + + sb.append(" action: ").append(toIndentedString(action)).append("\n"); + sb.append(" identifiers: ").append(toIndentedString(identifiers)).append("\n"); + sb.append(" repository: ").append(toIndentedString(repository)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/PythonUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/PythonUpstream.java index 92d3be88..fec4a2ef 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/PythonUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/PythonUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RecycleBinPackage.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RecycleBinPackage.java new file mode 100644 index 00000000..2ad249c7 --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RecycleBinPackage.java @@ -0,0 +1,489 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.models; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.cloudsmith.api.models.Tags; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.io.Serializable; +import javax.validation.constraints.*; +import javax.validation.Valid; + +/** + * RecycleBinPackage + */ + +public class RecycleBinPackage implements Serializable { + private static final long serialVersionUID = 1L; + + @SerializedName("action_by") + private String actionBy = null; + + @SerializedName("downloads") + private java.math.BigInteger downloads = null; + + @SerializedName("filename") + private String filename = null; + + @SerializedName("format") + private String format = null; + + @SerializedName("fully_qualified_name") + private String fullyQualifiedName = null; + + @SerializedName("identifiers") + private Map identifiers = null; + + @SerializedName("invoked_retention_rule") + private Map invokedRetentionRule = null; + + @SerializedName("is_deleteable") + private Boolean isDeleteable = null; + + @SerializedName("is_quarantined") + private Boolean isQuarantined = null; + + @SerializedName("is_restorable") + private Boolean isRestorable = null; + + @SerializedName("name") + private String name = null; + + @SerializedName("policy_violated") + private Boolean policyViolated = null; + + @SerializedName("repository") + private String repository = null; + + @SerializedName("security_scan_completed_at") + private OffsetDateTime securityScanCompletedAt = null; + + /** + * Gets or Sets securityScanStatus + */ + @JsonAdapter(SecurityScanStatusEnum.Adapter.class) + public enum SecurityScanStatusEnum { + AWAITING_SECURITY_SCAN("Awaiting Security Scan"), + + SECURITY_SCANNING_IN_PROGRESS("Security Scanning in Progress"), + + SCAN_DETECTED_VULNERABILITIES("Scan Detected Vulnerabilities"), + + SCAN_DETECTED_NO_VULNERABILITIES("Scan Detected No Vulnerabilities"), + + SECURITY_SCANNING_DISABLED("Security Scanning Disabled"), + + SECURITY_SCANNING_FAILED("Security Scanning Failed"), + + SECURITY_SCANNING_SKIPPED("Security Scanning Skipped"), + + SECURITY_SCANNING_NOT_SUPPORTED("Security Scanning Not Supported"); + + private String value; + + SecurityScanStatusEnum(String value) { + this.value = value; + } + + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + public static SecurityScanStatusEnum fromValue(String text) { + for (SecurityScanStatusEnum b : SecurityScanStatusEnum.values()) { + if (String.valueOf(b.value).equals(text)) { + return b; + } + } + return null; + } + + public static class Adapter extends TypeAdapter { + @Override + public void write(final JsonWriter jsonWriter, final SecurityScanStatusEnum enumeration) throws IOException { + jsonWriter.value(enumeration.getValue()); + } + + @Override + public SecurityScanStatusEnum read(final JsonReader jsonReader) throws IOException { + String value = jsonReader.nextString(); + return SecurityScanStatusEnum.fromValue(String.valueOf(value)); + } + } + } + + @SerializedName("security_scan_status") + private SecurityScanStatusEnum securityScanStatus = SecurityScanStatusEnum.AWAITING_SECURITY_SCAN; + + @SerializedName("size") + private java.math.BigInteger size = null; + + @SerializedName("slug_perm") + private String slugPerm = null; + + @SerializedName("status") + private java.math.BigInteger status = null; + + @SerializedName("status_updated_at") + private OffsetDateTime statusUpdatedAt = null; + + @SerializedName("tags") + private Tags tags = null; + + @SerializedName("type_display") + private String typeDisplay = null; + + @SerializedName("uploaded_at") + private OffsetDateTime uploadedAt = null; + + @SerializedName("uploader") + private String uploader = null; + + @SerializedName("version") + private String version = null; + + /** + * The name of the user who deleted the package. + * @return actionBy + **/ + @Size(min=1) @ApiModelProperty(value = "The name of the user who deleted the package.") + public String getActionBy() { + return actionBy; + } + + /** + * Get downloads + * @return downloads + **/ + @ApiModelProperty(value = "") + public java.math.BigInteger getDownloads() { + return downloads; + } + + /** + * Get filename + * @return filename + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getFilename() { + return filename; + } + + /** + * Get format + * @return format + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getFormat() { + return format; + } + + /** + * The fully qualified name of the package. + * @return fullyQualifiedName + **/ + @Size(min=1) @ApiModelProperty(value = "The fully qualified name of the package.") + public String getFullyQualifiedName() { + return fullyQualifiedName; + } + + /** + * Get identifiers + * @return identifiers + **/ + @ApiModelProperty(value = "") + public Map getIdentifiers() { + return identifiers; + } + + /** + * Information about the retention rule that triggered deletion (if any). + * @return invokedRetentionRule + **/ + @ApiModelProperty(value = "Information about the retention rule that triggered deletion (if any).") + public Map getInvokedRetentionRule() { + return invokedRetentionRule; + } + + /** + * Get isDeleteable + * @return isDeleteable + **/ + @ApiModelProperty(value = "") + public Boolean isIsDeleteable() { + return isDeleteable; + } + + /** + * Get isQuarantined + * @return isQuarantined + **/ + @ApiModelProperty(value = "") + public Boolean isIsQuarantined() { + return isQuarantined; + } + + /** + * Get isRestorable + * @return isRestorable + **/ + @ApiModelProperty(value = "") + public Boolean isIsRestorable() { + return isRestorable; + } + + /** + * The name of this package. + * @return name + **/ + @ApiModelProperty(value = "The name of this package.") + public String getName() { + return name; + } + + /** + * Whether or not the package has violated any policy. + * @return policyViolated + **/ + @ApiModelProperty(value = "Whether or not the package has violated any policy.") + public Boolean isPolicyViolated() { + return policyViolated; + } + + /** + * Get repository + * @return repository + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getRepository() { + return repository; + } + + /** + * The datetime the security scanning was completed. + * @return securityScanCompletedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the security scanning was completed.") + public OffsetDateTime getSecurityScanCompletedAt() { + return securityScanCompletedAt; + } + + /** + * Get securityScanStatus + * @return securityScanStatus + **/ + @ApiModelProperty(value = "") + public SecurityScanStatusEnum getSecurityScanStatus() { + return securityScanStatus; + } + + /** + * The calculated size of the package. + * @return size + **/ + @ApiModelProperty(value = "The calculated size of the package.") + public java.math.BigInteger getSize() { + return size; + } + + /** + * Get slugPerm + * @return slugPerm + **/ + @Pattern(regexp="^[-a-zA-Z0-9_]+$") @Size(min=1) @ApiModelProperty(value = "") + public String getSlugPerm() { + return slugPerm; + } + + /** + * The synchronisation status of the package. + * @return status + **/ + @ApiModelProperty(value = "The synchronisation status of the package.") + public java.math.BigInteger getStatus() { + return status; + } + + /** + * The datetime the package status was updated at. + * @return statusUpdatedAt + **/ + @Valid + @ApiModelProperty(value = "The datetime the package status was updated at.") + public OffsetDateTime getStatusUpdatedAt() { + return statusUpdatedAt; + } + + public RecycleBinPackage tags(Tags tags) { + this.tags = tags; + return this; + } + + /** + * Get tags + * @return tags + **/ + @Valid + @ApiModelProperty(value = "") + public Tags getTags() { + return tags; + } + + public void setTags(Tags tags) { + this.tags = tags; + } + + /** + * Get typeDisplay + * @return typeDisplay + **/ + @ApiModelProperty(value = "") + public String getTypeDisplay() { + return typeDisplay; + } + + /** + * The date this package was uploaded. + * @return uploadedAt + **/ + @Valid + @ApiModelProperty(value = "The date this package was uploaded.") + public OffsetDateTime getUploadedAt() { + return uploadedAt; + } + + /** + * Get uploader + * @return uploader + **/ + @Size(min=1) @ApiModelProperty(value = "") + public String getUploader() { + return uploader; + } + + /** + * The raw version for this package. + * @return version + **/ + @ApiModelProperty(value = "The raw version for this package.") + public String getVersion() { + return version; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RecycleBinPackage recycleBinPackage = (RecycleBinPackage) o; + return Objects.equals(this.actionBy, recycleBinPackage.actionBy) && + Objects.equals(this.downloads, recycleBinPackage.downloads) && + Objects.equals(this.filename, recycleBinPackage.filename) && + Objects.equals(this.format, recycleBinPackage.format) && + Objects.equals(this.fullyQualifiedName, recycleBinPackage.fullyQualifiedName) && + Objects.equals(this.identifiers, recycleBinPackage.identifiers) && + Objects.equals(this.invokedRetentionRule, recycleBinPackage.invokedRetentionRule) && + Objects.equals(this.isDeleteable, recycleBinPackage.isDeleteable) && + Objects.equals(this.isQuarantined, recycleBinPackage.isQuarantined) && + Objects.equals(this.isRestorable, recycleBinPackage.isRestorable) && + Objects.equals(this.name, recycleBinPackage.name) && + Objects.equals(this.policyViolated, recycleBinPackage.policyViolated) && + Objects.equals(this.repository, recycleBinPackage.repository) && + Objects.equals(this.securityScanCompletedAt, recycleBinPackage.securityScanCompletedAt) && + Objects.equals(this.securityScanStatus, recycleBinPackage.securityScanStatus) && + Objects.equals(this.size, recycleBinPackage.size) && + Objects.equals(this.slugPerm, recycleBinPackage.slugPerm) && + Objects.equals(this.status, recycleBinPackage.status) && + Objects.equals(this.statusUpdatedAt, recycleBinPackage.statusUpdatedAt) && + Objects.equals(this.tags, recycleBinPackage.tags) && + Objects.equals(this.typeDisplay, recycleBinPackage.typeDisplay) && + Objects.equals(this.uploadedAt, recycleBinPackage.uploadedAt) && + Objects.equals(this.uploader, recycleBinPackage.uploader) && + Objects.equals(this.version, recycleBinPackage.version); + } + + @Override + public int hashCode() { + return Objects.hash(actionBy, downloads, filename, format, fullyQualifiedName, identifiers, invokedRetentionRule, isDeleteable, isQuarantined, isRestorable, name, policyViolated, repository, securityScanCompletedAt, securityScanStatus, size, slugPerm, status, statusUpdatedAt, tags, typeDisplay, uploadedAt, uploader, version); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RecycleBinPackage {\n"); + + sb.append(" actionBy: ").append(toIndentedString(actionBy)).append("\n"); + sb.append(" downloads: ").append(toIndentedString(downloads)).append("\n"); + sb.append(" filename: ").append(toIndentedString(filename)).append("\n"); + sb.append(" format: ").append(toIndentedString(format)).append("\n"); + sb.append(" fullyQualifiedName: ").append(toIndentedString(fullyQualifiedName)).append("\n"); + sb.append(" identifiers: ").append(toIndentedString(identifiers)).append("\n"); + sb.append(" invokedRetentionRule: ").append(toIndentedString(invokedRetentionRule)).append("\n"); + sb.append(" isDeleteable: ").append(toIndentedString(isDeleteable)).append("\n"); + sb.append(" isQuarantined: ").append(toIndentedString(isQuarantined)).append("\n"); + sb.append(" isRestorable: ").append(toIndentedString(isRestorable)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" policyViolated: ").append(toIndentedString(policyViolated)).append("\n"); + sb.append(" repository: ").append(toIndentedString(repository)).append("\n"); + sb.append(" securityScanCompletedAt: ").append(toIndentedString(securityScanCompletedAt)).append("\n"); + sb.append(" securityScanStatus: ").append(toIndentedString(securityScanStatus)).append("\n"); + sb.append(" size: ").append(toIndentedString(size)).append("\n"); + sb.append(" slugPerm: ").append(toIndentedString(slugPerm)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" statusUpdatedAt: ").append(toIndentedString(statusUpdatedAt)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); + sb.append(" typeDisplay: ").append(toIndentedString(typeDisplay)).append("\n"); + sb.append(" uploadedAt: ").append(toIndentedString(uploadedAt)).append("\n"); + sb.append(" uploader: ").append(toIndentedString(uploader)).append("\n"); + sb.append(" version: ").append(toIndentedString(version)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryToken.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryToken.java index 63efba5d..801d9fb9 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryToken.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryToken.java @@ -278,11 +278,6 @@ public ScheduledResetPeriodEnum read(final JsonReader jsonReader) throws IOExcep @SerializedName("user_url") private String userUrl = null; - public RepositoryToken accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - return this; - } - /** * If enabled, this token can be used for private broadcasts * @return accessPrivateBroadcasts @@ -292,10 +287,6 @@ public Boolean isAccessPrivateBroadcasts() { return accessPrivateBroadcasts; } - public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - } - /** * Get clients * @return clients diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcasts.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcasts.java new file mode 100644 index 00000000..b9f98728 --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcasts.java @@ -0,0 +1,100 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.models; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.io.Serializable; +import javax.validation.constraints.*; +import javax.validation.Valid; + +/** + * RepositoryTokenPrivateBroadcasts + */ + +public class RepositoryTokenPrivateBroadcasts implements Serializable { + private static final long serialVersionUID = 1L; + + @SerializedName("access_private_broadcasts") + private Boolean accessPrivateBroadcasts = null; + + public RepositoryTokenPrivateBroadcasts accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { + this.accessPrivateBroadcasts = accessPrivateBroadcasts; + return this; + } + + /** + * Whether the token should have access to private broadcasts. + * @return accessPrivateBroadcasts + **/ + @NotNull + @ApiModelProperty(required = true, value = "Whether the token should have access to private broadcasts.") + public Boolean isAccessPrivateBroadcasts() { + return accessPrivateBroadcasts; + } + + public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { + this.accessPrivateBroadcasts = accessPrivateBroadcasts; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RepositoryTokenPrivateBroadcasts repositoryTokenPrivateBroadcasts = (RepositoryTokenPrivateBroadcasts) o; + return Objects.equals(this.accessPrivateBroadcasts, repositoryTokenPrivateBroadcasts.accessPrivateBroadcasts); + } + + @Override + public int hashCode() { + return Objects.hash(accessPrivateBroadcasts); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RepositoryTokenPrivateBroadcasts {\n"); + + sb.append(" accessPrivateBroadcasts: ").append(toIndentedString(accessPrivateBroadcasts)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcastsRequest.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcastsRequest.java new file mode 100644 index 00000000..bf8831f0 --- /dev/null +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenPrivateBroadcastsRequest.java @@ -0,0 +1,100 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.models; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.io.Serializable; +import javax.validation.constraints.*; +import javax.validation.Valid; + +/** + * RepositoryTokenPrivateBroadcastsRequest + */ + +public class RepositoryTokenPrivateBroadcastsRequest implements Serializable { + private static final long serialVersionUID = 1L; + + @SerializedName("access_private_broadcasts") + private Boolean accessPrivateBroadcasts = null; + + public RepositoryTokenPrivateBroadcastsRequest accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { + this.accessPrivateBroadcasts = accessPrivateBroadcasts; + return this; + } + + /** + * Whether the token should have access to private broadcasts. + * @return accessPrivateBroadcasts + **/ + @NotNull + @ApiModelProperty(required = true, value = "Whether the token should have access to private broadcasts.") + public Boolean isAccessPrivateBroadcasts() { + return accessPrivateBroadcasts; + } + + public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { + this.accessPrivateBroadcasts = accessPrivateBroadcasts; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RepositoryTokenPrivateBroadcastsRequest repositoryTokenPrivateBroadcastsRequest = (RepositoryTokenPrivateBroadcastsRequest) o; + return Objects.equals(this.accessPrivateBroadcasts, repositoryTokenPrivateBroadcastsRequest.accessPrivateBroadcasts); + } + + @Override + public int hashCode() { + return Objects.hash(accessPrivateBroadcasts); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RepositoryTokenPrivateBroadcastsRequest {\n"); + + sb.append(" accessPrivateBroadcasts: ").append(toIndentedString(accessPrivateBroadcasts)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefresh.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefresh.java index f56446bf..90761c00 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefresh.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefresh.java @@ -278,11 +278,6 @@ public ScheduledResetPeriodEnum read(final JsonReader jsonReader) throws IOExcep @SerializedName("user_url") private String userUrl = null; - public RepositoryTokenRefresh accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - return this; - } - /** * If enabled, this token can be used for private broadcasts * @return accessPrivateBroadcasts @@ -292,10 +287,6 @@ public Boolean isAccessPrivateBroadcasts() { return accessPrivateBroadcasts; } - public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - } - /** * Get clients * @return clients diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefreshRequest.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefreshRequest.java index 06f58816..209d8dd1 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefreshRequest.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRefreshRequest.java @@ -35,9 +35,6 @@ public class RepositoryTokenRefreshRequest implements Serializable { private static final long serialVersionUID = 1L; - @SerializedName("access_private_broadcasts") - private Boolean accessPrivateBroadcasts = null; - @SerializedName("eula_required") private Boolean eulaRequired = null; @@ -202,24 +199,6 @@ public ScheduledResetPeriodEnum read(final JsonReader jsonReader) throws IOExcep @SerializedName("token") private String token = null; - public RepositoryTokenRefreshRequest accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - return this; - } - - /** - * If enabled, this token can be used for private broadcasts - * @return accessPrivateBroadcasts - **/ - @ApiModelProperty(value = "If enabled, this token can be used for private broadcasts") - public Boolean isAccessPrivateBroadcasts() { - return accessPrivateBroadcasts; - } - - public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - } - public RepositoryTokenRefreshRequest eulaRequired(Boolean eulaRequired) { this.eulaRequired = eulaRequired; return this; @@ -491,8 +470,7 @@ public boolean equals(java.lang.Object o) { return false; } RepositoryTokenRefreshRequest repositoryTokenRefreshRequest = (RepositoryTokenRefreshRequest) o; - return Objects.equals(this.accessPrivateBroadcasts, repositoryTokenRefreshRequest.accessPrivateBroadcasts) && - Objects.equals(this.eulaRequired, repositoryTokenRefreshRequest.eulaRequired) && + return Objects.equals(this.eulaRequired, repositoryTokenRefreshRequest.eulaRequired) && Objects.equals(this.isActive, repositoryTokenRefreshRequest.isActive) && Objects.equals(this.limitBandwidth, repositoryTokenRefreshRequest.limitBandwidth) && Objects.equals(this.limitBandwidthUnit, repositoryTokenRefreshRequest.limitBandwidthUnit) && @@ -510,7 +488,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(accessPrivateBroadcasts, eulaRequired, isActive, limitBandwidth, limitBandwidthUnit, limitDateRangeFrom, limitDateRangeTo, limitNumClients, limitNumDownloads, limitPackageQuery, limitPathQuery, metadata, scheduledResetAt, scheduledResetPeriod, token); + return Objects.hash(eulaRequired, isActive, limitBandwidth, limitBandwidthUnit, limitDateRangeFrom, limitDateRangeTo, limitNumClients, limitNumDownloads, limitPackageQuery, limitPathQuery, metadata, scheduledResetAt, scheduledResetPeriod, token); } @@ -519,7 +497,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class RepositoryTokenRefreshRequest {\n"); - sb.append(" accessPrivateBroadcasts: ").append(toIndentedString(accessPrivateBroadcasts)).append("\n"); sb.append(" eulaRequired: ").append(toIndentedString(eulaRequired)).append("\n"); sb.append(" isActive: ").append(toIndentedString(isActive)).append("\n"); sb.append(" limitBandwidth: ").append(toIndentedString(limitBandwidth)).append("\n"); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequest.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequest.java index b6a5bad5..ece93fce 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequest.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequest.java @@ -35,9 +35,6 @@ public class RepositoryTokenRequest implements Serializable { private static final long serialVersionUID = 1L; - @SerializedName("access_private_broadcasts") - private Boolean accessPrivateBroadcasts = null; - @SerializedName("eula_required") private Boolean eulaRequired = null; @@ -205,24 +202,6 @@ public ScheduledResetPeriodEnum read(final JsonReader jsonReader) throws IOExcep @SerializedName("token") private String token = null; - public RepositoryTokenRequest accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - return this; - } - - /** - * If enabled, this token can be used for private broadcasts - * @return accessPrivateBroadcasts - **/ - @ApiModelProperty(value = "If enabled, this token can be used for private broadcasts") - public Boolean isAccessPrivateBroadcasts() { - return accessPrivateBroadcasts; - } - - public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - } - public RepositoryTokenRequest eulaRequired(Boolean eulaRequired) { this.eulaRequired = eulaRequired; return this; @@ -513,8 +492,7 @@ public boolean equals(java.lang.Object o) { return false; } RepositoryTokenRequest repositoryTokenRequest = (RepositoryTokenRequest) o; - return Objects.equals(this.accessPrivateBroadcasts, repositoryTokenRequest.accessPrivateBroadcasts) && - Objects.equals(this.eulaRequired, repositoryTokenRequest.eulaRequired) && + return Objects.equals(this.eulaRequired, repositoryTokenRequest.eulaRequired) && Objects.equals(this.isActive, repositoryTokenRequest.isActive) && Objects.equals(this.limitBandwidth, repositoryTokenRequest.limitBandwidth) && Objects.equals(this.limitBandwidthUnit, repositoryTokenRequest.limitBandwidthUnit) && @@ -533,7 +511,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(accessPrivateBroadcasts, eulaRequired, isActive, limitBandwidth, limitBandwidthUnit, limitDateRangeFrom, limitDateRangeTo, limitNumClients, limitNumDownloads, limitPackageQuery, limitPathQuery, metadata, name, scheduledResetAt, scheduledResetPeriod, token); + return Objects.hash(eulaRequired, isActive, limitBandwidth, limitBandwidthUnit, limitDateRangeFrom, limitDateRangeTo, limitNumClients, limitNumDownloads, limitPackageQuery, limitPathQuery, metadata, name, scheduledResetAt, scheduledResetPeriod, token); } @@ -542,7 +520,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class RepositoryTokenRequest {\n"); - sb.append(" accessPrivateBroadcasts: ").append(toIndentedString(accessPrivateBroadcasts)).append("\n"); sb.append(" eulaRequired: ").append(toIndentedString(eulaRequired)).append("\n"); sb.append(" isActive: ").append(toIndentedString(isActive)).append("\n"); sb.append(" limitBandwidth: ").append(toIndentedString(limitBandwidth)).append("\n"); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequestPatch.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequestPatch.java index 50e42450..e5d9b993 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequestPatch.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RepositoryTokenRequestPatch.java @@ -35,9 +35,6 @@ public class RepositoryTokenRequestPatch implements Serializable { private static final long serialVersionUID = 1L; - @SerializedName("access_private_broadcasts") - private Boolean accessPrivateBroadcasts = null; - @SerializedName("eula_required") private Boolean eulaRequired = null; @@ -205,24 +202,6 @@ public ScheduledResetPeriodEnum read(final JsonReader jsonReader) throws IOExcep @SerializedName("token") private String token = null; - public RepositoryTokenRequestPatch accessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - return this; - } - - /** - * If enabled, this token can be used for private broadcasts - * @return accessPrivateBroadcasts - **/ - @ApiModelProperty(value = "If enabled, this token can be used for private broadcasts") - public Boolean isAccessPrivateBroadcasts() { - return accessPrivateBroadcasts; - } - - public void setAccessPrivateBroadcasts(Boolean accessPrivateBroadcasts) { - this.accessPrivateBroadcasts = accessPrivateBroadcasts; - } - public RepositoryTokenRequestPatch eulaRequired(Boolean eulaRequired) { this.eulaRequired = eulaRequired; return this; @@ -512,8 +491,7 @@ public boolean equals(java.lang.Object o) { return false; } RepositoryTokenRequestPatch repositoryTokenRequestPatch = (RepositoryTokenRequestPatch) o; - return Objects.equals(this.accessPrivateBroadcasts, repositoryTokenRequestPatch.accessPrivateBroadcasts) && - Objects.equals(this.eulaRequired, repositoryTokenRequestPatch.eulaRequired) && + return Objects.equals(this.eulaRequired, repositoryTokenRequestPatch.eulaRequired) && Objects.equals(this.isActive, repositoryTokenRequestPatch.isActive) && Objects.equals(this.limitBandwidth, repositoryTokenRequestPatch.limitBandwidth) && Objects.equals(this.limitBandwidthUnit, repositoryTokenRequestPatch.limitBandwidthUnit) && @@ -532,7 +510,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(accessPrivateBroadcasts, eulaRequired, isActive, limitBandwidth, limitBandwidthUnit, limitDateRangeFrom, limitDateRangeTo, limitNumClients, limitNumDownloads, limitPackageQuery, limitPathQuery, metadata, name, scheduledResetAt, scheduledResetPeriod, token); + return Objects.hash(eulaRequired, isActive, limitBandwidth, limitBandwidthUnit, limitDateRangeFrom, limitDateRangeTo, limitNumClients, limitNumDownloads, limitPackageQuery, limitPathQuery, metadata, name, scheduledResetAt, scheduledResetPeriod, token); } @@ -541,7 +519,6 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class RepositoryTokenRequestPatch {\n"); - sb.append(" accessPrivateBroadcasts: ").append(toIndentedString(accessPrivateBroadcasts)).append("\n"); sb.append(" eulaRequired: ").append(toIndentedString(eulaRequired)).append("\n"); sb.append(" isActive: ").append(toIndentedString(isActive)).append("\n"); sb.append(" limitBandwidth: ").append(toIndentedString(limitBandwidth)).append("\n"); diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RpmUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RpmUpstream.java index 694e45de..6157506c 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RpmUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RpmUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RubyUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RubyUpstream.java index 1c6c6241..047d0b17 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/RubyUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/RubyUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimit.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimit.java index d0e33c12..fba50927 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimit.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimit.java @@ -49,6 +49,9 @@ public class StorageAllocatedLimit implements Serializable { @SerializedName("used") private String used = null; + @SerializedName("used_pre_deduplication") + private String usedPreDeduplication = null; + public StorageAllocatedLimit configured(String configured) { this.configured = configured; return this; @@ -139,6 +142,24 @@ public void setUsed(String used) { this.used = used; } + public StorageAllocatedLimit usedPreDeduplication(String usedPreDeduplication) { + this.usedPreDeduplication = usedPreDeduplication; + return this; + } + + /** + * Get usedPreDeduplication + * @return usedPreDeduplication + **/ + @Size(min=1,max=32) @ApiModelProperty(value = "") + public String getUsedPreDeduplication() { + return usedPreDeduplication; + } + + public void setUsedPreDeduplication(String usedPreDeduplication) { + this.usedPreDeduplication = usedPreDeduplication; + } + @Override public boolean equals(java.lang.Object o) { @@ -153,12 +174,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.peak, storageAllocatedLimit.peak) && Objects.equals(this.percentageUsed, storageAllocatedLimit.percentageUsed) && Objects.equals(this.planLimit, storageAllocatedLimit.planLimit) && - Objects.equals(this.used, storageAllocatedLimit.used); + Objects.equals(this.used, storageAllocatedLimit.used) && + Objects.equals(this.usedPreDeduplication, storageAllocatedLimit.usedPreDeduplication); } @Override public int hashCode() { - return Objects.hash(configured, peak, percentageUsed, planLimit, used); + return Objects.hash(configured, peak, percentageUsed, planLimit, used, usedPreDeduplication); } @@ -172,6 +194,7 @@ public String toString() { sb.append(" percentageUsed: ").append(toIndentedString(percentageUsed)).append("\n"); sb.append(" planLimit: ").append(toIndentedString(planLimit)).append("\n"); sb.append(" used: ").append(toIndentedString(used)).append("\n"); + sb.append(" usedPreDeduplication: ").append(toIndentedString(usedPreDeduplication)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimitRaw.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimitRaw.java index a6f11a5a..d365bd2c 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimitRaw.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/StorageAllocatedLimitRaw.java @@ -49,6 +49,9 @@ public class StorageAllocatedLimitRaw implements Serializable { @SerializedName("used") private java.math.BigInteger used = null; + @SerializedName("used_pre_deduplication") + private java.math.BigInteger usedPreDeduplication = null; + public StorageAllocatedLimitRaw configured(java.math.BigInteger configured) { this.configured = configured; return this; @@ -139,6 +142,24 @@ public void setUsed(java.math.BigInteger used) { this.used = used; } + public StorageAllocatedLimitRaw usedPreDeduplication(java.math.BigInteger usedPreDeduplication) { + this.usedPreDeduplication = usedPreDeduplication; + return this; + } + + /** + * Get usedPreDeduplication + * @return usedPreDeduplication + **/ + @ApiModelProperty(value = "") + public java.math.BigInteger getUsedPreDeduplication() { + return usedPreDeduplication; + } + + public void setUsedPreDeduplication(java.math.BigInteger usedPreDeduplication) { + this.usedPreDeduplication = usedPreDeduplication; + } + @Override public boolean equals(java.lang.Object o) { @@ -153,12 +174,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.peak, storageAllocatedLimitRaw.peak) && Objects.equals(this.percentageUsed, storageAllocatedLimitRaw.percentageUsed) && Objects.equals(this.planLimit, storageAllocatedLimitRaw.planLimit) && - Objects.equals(this.used, storageAllocatedLimitRaw.used); + Objects.equals(this.used, storageAllocatedLimitRaw.used) && + Objects.equals(this.usedPreDeduplication, storageAllocatedLimitRaw.usedPreDeduplication); } @Override public int hashCode() { - return Objects.hash(configured, peak, percentageUsed, planLimit, used); + return Objects.hash(configured, peak, percentageUsed, planLimit, used, usedPreDeduplication); } @@ -172,6 +194,7 @@ public String toString() { sb.append(" percentageUsed: ").append(toIndentedString(percentageUsed)).append("\n"); sb.append(" planLimit: ").append(toIndentedString(planLimit)).append("\n"); sb.append(" used: ").append(toIndentedString(used)).append("\n"); + sb.append(" usedPreDeduplication: ").append(toIndentedString(usedPreDeduplication)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/bindings/java/src/src/main/java/io/cloudsmith/api/models/SwiftUpstream.java b/bindings/java/src/src/main/java/io/cloudsmith/api/models/SwiftUpstream.java index 66de6978..fe1a2de7 100644 --- a/bindings/java/src/src/main/java/io/cloudsmith/api/models/SwiftUpstream.java +++ b/bindings/java/src/src/main/java/io/cloudsmith/api/models/SwiftUpstream.java @@ -111,6 +111,8 @@ public enum DisableReasonEnum { MISSING_UPSTREAM_SOURCE("Missing upstream source"), + RSA_KEY_DID_NOT_VERIFY_THE_UPSTREAM_S_APKINDEX_SIGNATURE("RSA key did not verify the upstream's APKINDEX signature"), + UPSTREAM_WAS_DISABLED_BY_REQUEST_OF_USER("Upstream was disabled by request of user"); private String value; diff --git a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/EntitlementsApiTest.java b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/EntitlementsApiTest.java index 02d513d8..31009cc3 100644 --- a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/EntitlementsApiTest.java +++ b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/EntitlementsApiTest.java @@ -15,6 +15,7 @@ import io.cloudsmith.api.models.ErrorDetail; import io.cloudsmith.api.models.RepositoryToken; +import io.cloudsmith.api.models.RepositoryTokenPrivateBroadcastsRequest; import io.cloudsmith.api.models.RepositoryTokenRefresh; import io.cloudsmith.api.models.RepositoryTokenRefreshRequest; import io.cloudsmith.api.models.RepositoryTokenRequest; @@ -233,4 +234,23 @@ public void entitlementsSyncTest() throws Exception { // TODO: test validations } + /** + * Set private broadcast access for an entitlement token in a repository. + * + * Set private broadcast access for an entitlement token in a repository. + * + * @throws Exception + * if the Api call fails + */ + @Test + public void entitlementsTogglePrivateBroadcastsTest() throws Exception { + String owner = null; + String repo = null; + String identifier = null; + RepositoryTokenPrivateBroadcastsRequest data = null; + api.entitlementsTogglePrivateBroadcasts(owner, repo, identifier, data); + + // TODO: test validations + } + } diff --git a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/PackagesApiTest.java b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/PackagesApiTest.java index 9804c97d..1a600b7b 100644 --- a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/PackagesApiTest.java +++ b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/PackagesApiTest.java @@ -49,6 +49,8 @@ import io.cloudsmith.api.models.LuarocksPackageUploadRequest; import io.cloudsmith.api.models.MavenPackageUpload; import io.cloudsmith.api.models.MavenPackageUploadRequest; +import io.cloudsmith.api.models.McpPackageUpload; +import io.cloudsmith.api.models.McpPackageUploadRequest; import io.cloudsmith.api.models.ModelPackage; import io.cloudsmith.api.models.NpmPackageUpload; import io.cloudsmith.api.models.NpmPackageUploadRequest; @@ -654,6 +656,24 @@ public void packagesUploadMavenTest() throws Exception { // TODO: test validations } + /** + * Create a new MCP package + * + * Create a new MCP package + * + * @throws Exception + * if the Api call fails + */ + @Test + public void packagesUploadMcpTest() throws Exception { + String owner = null; + String repo = null; + McpPackageUploadRequest data = null; + McpPackageUpload response = api.packagesUploadMcp(owner, repo, data); + + // TODO: test validations + } + /** * Create a new npm package * @@ -1158,6 +1178,24 @@ public void packagesValidateUploadMavenTest() throws Exception { // TODO: test validations } + /** + * Validate parameters for create MCP package + * + * Validate parameters for create MCP package + * + * @throws Exception + * if the Api call fails + */ + @Test + public void packagesValidateUploadMcpTest() throws Exception { + String owner = null; + String repo = null; + McpPackageUploadRequest data = null; + api.packagesValidateUploadMcp(owner, repo, data); + + // TODO: test validations + } + /** * Validate parameters for create npm package * diff --git a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/RecycleBinApiTest.java b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/RecycleBinApiTest.java new file mode 100644 index 00000000..32b41ebd --- /dev/null +++ b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/RecycleBinApiTest.java @@ -0,0 +1,74 @@ +/* + * Cloudsmith API (v1) + * The API to the Cloudsmith Service + * + * OpenAPI spec version: v1 + * Contact: support@cloudsmith.io + * + * NOTE: This class is auto generated by the swagger code generator program. + * https://github.com/swagger-api/swagger-codegen.git + * Do not edit the class manually. + */ + + +package io.cloudsmith.api.apis; + +import io.cloudsmith.api.models.ErrorDetail; +import io.cloudsmith.api.models.PackageBulkActionResponse; +import io.cloudsmith.api.models.PackageRecycleBin; +import io.cloudsmith.api.models.RecycleBinPackage; +import org.junit.Test; +import org.junit.Ignore; + + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * API tests for RecycleBinApi + */ +@Ignore +public class RecycleBinApiTest { + + private final RecycleBinApi api = new RecycleBinApi(); + + + /** + * List soft-deleted packages in recycle bin + * + * Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + * + * @throws Exception + * if the Api call fails + */ + @Test + public void recycleBinListTest() throws Exception { + String owner = null; + java.math.BigInteger page = null; + java.math.BigInteger pageSize = null; + String repository = null; + List response = api.recycleBinList(owner, page, pageSize, repository); + + // TODO: test validations + } + + /** + * + * + * Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + * + * @throws Exception + * if the Api call fails + */ + @Test + public void recycleBinRecycleBinActionTest() throws Exception { + String owner = null; + PackageRecycleBin data = null; + PackageBulkActionResponse response = api.recycleBinRecycleBinAction(owner, data); + + // TODO: test validations + } + +} diff --git a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/ReposApiTest.java b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/ReposApiTest.java index 7f269182..1b69709e 100644 --- a/bindings/java/src/src/test/java/io/cloudsmith/api/apis/ReposApiTest.java +++ b/bindings/java/src/src/test/java/io/cloudsmith/api/apis/ReposApiTest.java @@ -187,9 +187,9 @@ public void reposCreateTest() throws Exception { } /** - * Delete a repository in a given namespace. + * * - * Delete a repository in a given namespace. + * Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. * * @throws Exception * if the Api call fails diff --git a/bindings/python/src/README.md b/bindings/python/src/README.md index 911ca861..f510a895 100644 --- a/bindings/python/src/README.md +++ b/bindings/python/src/README.md @@ -4,7 +4,7 @@ The API to the Cloudsmith Service This Python package is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project: - API version: v1 -- Package version: 2.0.25 +- Package version: 2.0.26 - Build package: io.swagger.codegen.languages.PythonClientCodegen For more information, please visit [https://help.cloudsmith.io](https://help.cloudsmith.io) @@ -101,6 +101,7 @@ Class | Method | HTTP request | Description *EntitlementsApi* | [**entitlements_refresh**](docs/EntitlementsApi.md#entitlements_refresh) | **POST** /entitlements/{owner}/{repo}/{identifier}/refresh/ | Refresh an entitlement token in a repository. *EntitlementsApi* | [**entitlements_reset**](docs/EntitlementsApi.md#entitlements_reset) | **POST** /entitlements/{owner}/{repo}/{identifier}/reset/ | Reset the statistics for an entitlement token in a repository. *EntitlementsApi* | [**entitlements_sync**](docs/EntitlementsApi.md#entitlements_sync) | **POST** /entitlements/{owner}/{repo}/sync/ | Synchronise tokens from a source repository. +*EntitlementsApi* | [**entitlements_toggle_private_broadcasts**](docs/EntitlementsApi.md#entitlements_toggle_private_broadcasts) | **POST** /entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/ | Set private broadcast access for an entitlement token in a repository. *FilesApi* | [**files_abort**](docs/FilesApi.md#files_abort) | **POST** /files/{owner}/{repo}/{identifier}/abort/ | Abort a multipart file upload. *FilesApi* | [**files_complete**](docs/FilesApi.md#files_complete) | **POST** /files/{owner}/{repo}/{identifier}/complete/ | Complete a multipart file upload. *FilesApi* | [**files_create**](docs/FilesApi.md#files_create) | **POST** /files/{owner}/{repo}/ | Request URL(s) to upload new package file upload(s) to. @@ -216,6 +217,7 @@ Class | Method | HTTP request | Description *PackagesApi* | [**packages_upload_huggingface**](docs/PackagesApi.md#packages_upload_huggingface) | **POST** /packages/{owner}/{repo}/upload/huggingface/ | Create a new HuggingFace package *PackagesApi* | [**packages_upload_luarocks**](docs/PackagesApi.md#packages_upload_luarocks) | **POST** /packages/{owner}/{repo}/upload/luarocks/ | Create a new LuaRocks package *PackagesApi* | [**packages_upload_maven**](docs/PackagesApi.md#packages_upload_maven) | **POST** /packages/{owner}/{repo}/upload/maven/ | Create a new Maven package +*PackagesApi* | [**packages_upload_mcp**](docs/PackagesApi.md#packages_upload_mcp) | **POST** /packages/{owner}/{repo}/upload/mcp/ | Create a new MCP package *PackagesApi* | [**packages_upload_npm**](docs/PackagesApi.md#packages_upload_npm) | **POST** /packages/{owner}/{repo}/upload/npm/ | Create a new npm package *PackagesApi* | [**packages_upload_nuget**](docs/PackagesApi.md#packages_upload_nuget) | **POST** /packages/{owner}/{repo}/upload/nuget/ | Create a new NuGet package *PackagesApi* | [**packages_upload_p2**](docs/PackagesApi.md#packages_upload_p2) | **POST** /packages/{owner}/{repo}/upload/p2/ | Create a new P2 package @@ -244,6 +246,7 @@ Class | Method | HTTP request | Description *PackagesApi* | [**packages_validate_upload_huggingface**](docs/PackagesApi.md#packages_validate_upload_huggingface) | **POST** /packages/{owner}/{repo}/validate-upload/huggingface/ | Validate parameters for create HuggingFace package *PackagesApi* | [**packages_validate_upload_luarocks**](docs/PackagesApi.md#packages_validate_upload_luarocks) | **POST** /packages/{owner}/{repo}/validate-upload/luarocks/ | Validate parameters for create LuaRocks package *PackagesApi* | [**packages_validate_upload_maven**](docs/PackagesApi.md#packages_validate_upload_maven) | **POST** /packages/{owner}/{repo}/validate-upload/maven/ | Validate parameters for create Maven package +*PackagesApi* | [**packages_validate_upload_mcp**](docs/PackagesApi.md#packages_validate_upload_mcp) | **POST** /packages/{owner}/{repo}/validate-upload/mcp/ | Validate parameters for create MCP package *PackagesApi* | [**packages_validate_upload_npm**](docs/PackagesApi.md#packages_validate_upload_npm) | **POST** /packages/{owner}/{repo}/validate-upload/npm/ | Validate parameters for create npm package *PackagesApi* | [**packages_validate_upload_nuget**](docs/PackagesApi.md#packages_validate_upload_nuget) | **POST** /packages/{owner}/{repo}/validate-upload/nuget/ | Validate parameters for create NuGet package *PackagesApi* | [**packages_validate_upload_p2**](docs/PackagesApi.md#packages_validate_upload_p2) | **POST** /packages/{owner}/{repo}/validate-upload/p2/ | Validate parameters for create P2 package @@ -260,11 +263,13 @@ Class | Method | HTTP request | Description *QuotaApi* | [**quota_oss_read**](docs/QuotaApi.md#quota_oss_read) | **GET** /quota/oss/{owner}/ | Open-source Quota usage for a given namespace. *QuotaApi* | [**quota_read**](docs/QuotaApi.md#quota_read) | **GET** /quota/{owner}/ | Quota usage for a given namespace. *RatesApi* | [**rates_limits_list**](docs/RatesApi.md#rates_limits_list) | **GET** /rates/limits/ | Endpoint to check rate limits for current user. +*RecycleBinApi* | [**recycle_bin_list**](docs/RecycleBinApi.md#recycle_bin_list) | **GET** /recycle-bin/{owner}/ | List soft-deleted packages in recycle bin +*RecycleBinApi* | [**recycle_bin_recycle_bin_action**](docs/RecycleBinApi.md#recycle_bin_recycle_bin_action) | **POST** /recycle-bin/{owner}/action/ | *ReposApi* | [**api_repos_geoip_status**](docs/ReposApi.md#api_repos_geoip_status) | **GET** /repos/{owner}/{identifier}/geoip/status/ | Retrieve the GeoIP status for this repository. *ReposApi* | [**repo_retention_partial_update**](docs/ReposApi.md#repo_retention_partial_update) | **PATCH** /repos/{owner}/{repo}/retention/ | Update the retention rules for the repository. *ReposApi* | [**repo_retention_read**](docs/ReposApi.md#repo_retention_read) | **GET** /repos/{owner}/{repo}/retention/ | Retrieve the retention rules for the repository. *ReposApi* | [**repos_create**](docs/ReposApi.md#repos_create) | **POST** /repos/{owner}/ | Create a new repository in a given namespace. -*ReposApi* | [**repos_delete**](docs/ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | Delete a repository in a given namespace. +*ReposApi* | [**repos_delete**](docs/ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | *ReposApi* | [**repos_ecdsa_create**](docs/ReposApi.md#repos_ecdsa_create) | **POST** /repos/{owner}/{identifier}/ecdsa/ | Set the active ECDSA key for the Repository. *ReposApi* | [**repos_ecdsa_list**](docs/ReposApi.md#repos_ecdsa_list) | **GET** /repos/{owner}/{identifier}/ecdsa/ | Retrieve the active ECDSA key for the Repository. *ReposApi* | [**repos_ecdsa_regenerate**](docs/ReposApi.md#repos_ecdsa_regenerate) | **POST** /repos/{owner}/{identifier}/ecdsa/regenerate/ | Regenerate ECDSA Key for the Repository. @@ -534,6 +539,8 @@ Class | Method | HTTP request | Description - [MavenUpstream](docs/MavenUpstream.md) - [MavenUpstreamRequest](docs/MavenUpstreamRequest.md) - [MavenUpstreamRequestPatch](docs/MavenUpstreamRequestPatch.md) + - [McpPackageUpload](docs/McpPackageUpload.md) + - [McpPackageUploadRequest](docs/McpPackageUploadRequest.md) - [Namespace](docs/Namespace.md) - [NamespaceAuditLog](docs/NamespaceAuditLog.md) - [NestedLicensePolicy](docs/NestedLicensePolicy.md) @@ -605,6 +612,7 @@ Class | Method | HTTP request | Description - [PackageMoveRequest](docs/PackageMoveRequest.md) - [PackageQuarantine](docs/PackageQuarantine.md) - [PackageQuarantineRequest](docs/PackageQuarantineRequest.md) + - [PackageRecycleBin](docs/PackageRecycleBin.md) - [PackageResync](docs/PackageResync.md) - [PackageStatus](docs/PackageStatus.md) - [PackageTag](docs/PackageTag.md) @@ -630,6 +638,7 @@ Class | Method | HTTP request | Description - [RateCheck](docs/RateCheck.md) - [RawPackageUpload](docs/RawPackageUpload.md) - [RawPackageUploadRequest](docs/RawPackageUploadRequest.md) + - [RecycleBinPackage](docs/RecycleBinPackage.md) - [Repository](docs/Repository.md) - [RepositoryAuditLog](docs/RepositoryAuditLog.md) - [RepositoryCreate](docs/RepositoryCreate.md) @@ -658,6 +667,8 @@ Class | Method | HTTP request | Description - [RepositoryRsaKeyCreate](docs/RepositoryRsaKeyCreate.md) - [RepositoryToken](docs/RepositoryToken.md) - [RepositoryTokenAction](docs/RepositoryTokenAction.md) + - [RepositoryTokenPrivateBroadcasts](docs/RepositoryTokenPrivateBroadcasts.md) + - [RepositoryTokenPrivateBroadcastsRequest](docs/RepositoryTokenPrivateBroadcastsRequest.md) - [RepositoryTokenRefresh](docs/RepositoryTokenRefresh.md) - [RepositoryTokenRefreshRequest](docs/RepositoryTokenRefreshRequest.md) - [RepositoryTokenRequest](docs/RepositoryTokenRequest.md) diff --git a/bindings/python/src/build.json b/bindings/python/src/build.json index 5d1a4f3e..4c8ba3ce 100644 --- a/bindings/python/src/build.json +++ b/bindings/python/src/build.json @@ -2,7 +2,7 @@ "hideGenerationTimestamp": true, "packageName": "cloudsmith_api", "projectName": "cloudsmith_api", - "packageVersion": "2.0.25", + "packageVersion": "2.0.26", "packageUrl": "https://api.cloudsmith.io/?format=openapi", "sortParamsByRequiredFlag": true } diff --git a/bindings/python/src/cloudsmith_api/__init__.py b/bindings/python/src/cloudsmith_api/__init__.py index 82cc0de2..e4ce9113 100644 --- a/bindings/python/src/cloudsmith_api/__init__.py +++ b/bindings/python/src/cloudsmith_api/__init__.py @@ -30,6 +30,7 @@ from cloudsmith_api.api.packages_api import PackagesApi from cloudsmith_api.api.quota_api import QuotaApi from cloudsmith_api.api.rates_api import RatesApi +from cloudsmith_api.api.recycle_bin_api import RecycleBinApi from cloudsmith_api.api.repos_api import ReposApi from cloudsmith_api.api.status_api import StatusApi from cloudsmith_api.api.storage_regions_api import StorageRegionsApi @@ -144,6 +145,8 @@ from cloudsmith_api.models.maven_upstream import MavenUpstream from cloudsmith_api.models.maven_upstream_request import MavenUpstreamRequest from cloudsmith_api.models.maven_upstream_request_patch import MavenUpstreamRequestPatch +from cloudsmith_api.models.mcp_package_upload import McpPackageUpload +from cloudsmith_api.models.mcp_package_upload_request import McpPackageUploadRequest from cloudsmith_api.models.namespace import Namespace from cloudsmith_api.models.namespace_audit_log import NamespaceAuditLog from cloudsmith_api.models.nested_license_policy import NestedLicensePolicy @@ -215,6 +218,7 @@ from cloudsmith_api.models.package_move_request import PackageMoveRequest from cloudsmith_api.models.package_quarantine import PackageQuarantine from cloudsmith_api.models.package_quarantine_request import PackageQuarantineRequest +from cloudsmith_api.models.package_recycle_bin import PackageRecycleBin from cloudsmith_api.models.package_resync import PackageResync from cloudsmith_api.models.package_status import PackageStatus from cloudsmith_api.models.package_tag import PackageTag @@ -240,6 +244,7 @@ from cloudsmith_api.models.rate_check import RateCheck from cloudsmith_api.models.raw_package_upload import RawPackageUpload from cloudsmith_api.models.raw_package_upload_request import RawPackageUploadRequest +from cloudsmith_api.models.recycle_bin_package import RecycleBinPackage from cloudsmith_api.models.repository import Repository from cloudsmith_api.models.repository_audit_log import RepositoryAuditLog from cloudsmith_api.models.repository_create import RepositoryCreate @@ -268,6 +273,8 @@ from cloudsmith_api.models.repository_rsa_key_create import RepositoryRsaKeyCreate from cloudsmith_api.models.repository_token import RepositoryToken from cloudsmith_api.models.repository_token_action import RepositoryTokenAction +from cloudsmith_api.models.repository_token_private_broadcasts import RepositoryTokenPrivateBroadcasts +from cloudsmith_api.models.repository_token_private_broadcasts_request import RepositoryTokenPrivateBroadcastsRequest from cloudsmith_api.models.repository_token_refresh import RepositoryTokenRefresh from cloudsmith_api.models.repository_token_refresh_request import RepositoryTokenRefreshRequest from cloudsmith_api.models.repository_token_request import RepositoryTokenRequest diff --git a/bindings/python/src/cloudsmith_api/api/__init__.py b/bindings/python/src/cloudsmith_api/api/__init__.py index 12b303e6..3d33a8ad 100644 --- a/bindings/python/src/cloudsmith_api/api/__init__.py +++ b/bindings/python/src/cloudsmith_api/api/__init__.py @@ -17,6 +17,7 @@ from cloudsmith_api.api.packages_api import PackagesApi from cloudsmith_api.api.quota_api import QuotaApi from cloudsmith_api.api.rates_api import RatesApi +from cloudsmith_api.api.recycle_bin_api import RecycleBinApi from cloudsmith_api.api.repos_api import ReposApi from cloudsmith_api.api.status_api import StatusApi from cloudsmith_api.api.storage_regions_api import StorageRegionsApi diff --git a/bindings/python/src/cloudsmith_api/api/entitlements_api.py b/bindings/python/src/cloudsmith_api/api/entitlements_api.py index 5b70c17c..5ba69397 100644 --- a/bindings/python/src/cloudsmith_api/api/entitlements_api.py +++ b/bindings/python/src/cloudsmith_api/api/entitlements_api.py @@ -1226,3 +1226,122 @@ def entitlements_sync_with_http_info(self, owner, repo, **kwargs): # noqa: E501 _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) + + def entitlements_toggle_private_broadcasts(self, owner, repo, identifier, **kwargs): # noqa: E501 + """Set private broadcast access for an entitlement token in a repository. # noqa: E501 + + Set private broadcast access for an entitlement token in a repository. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.entitlements_toggle_private_broadcasts(owner, repo, identifier, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param str repo: (required) + :param str identifier: (required) + :param RepositoryTokenPrivateBroadcastsRequest data: + :return: None + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.entitlements_toggle_private_broadcasts_with_http_info(owner, repo, identifier, **kwargs) # noqa: E501 + else: + (data) = self.entitlements_toggle_private_broadcasts_with_http_info(owner, repo, identifier, **kwargs) # noqa: E501 + return data + + def entitlements_toggle_private_broadcasts_with_http_info(self, owner, repo, identifier, **kwargs): # noqa: E501 + """Set private broadcast access for an entitlement token in a repository. # noqa: E501 + + Set private broadcast access for an entitlement token in a repository. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.entitlements_toggle_private_broadcasts_with_http_info(owner, repo, identifier, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param str repo: (required) + :param str identifier: (required) + :param RepositoryTokenPrivateBroadcastsRequest data: + :return: None + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['owner', 'repo', 'identifier', 'data'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method entitlements_toggle_private_broadcasts" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'owner' is set + if self.api_client.client_side_validation and ('owner' not in params or + params['owner'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `owner` when calling `entitlements_toggle_private_broadcasts`") # noqa: E501 + # verify the required parameter 'repo' is set + if self.api_client.client_side_validation and ('repo' not in params or + params['repo'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `repo` when calling `entitlements_toggle_private_broadcasts`") # noqa: E501 + # verify the required parameter 'identifier' is set + if self.api_client.client_side_validation and ('identifier' not in params or + params['identifier'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `identifier` when calling `entitlements_toggle_private_broadcasts`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'owner' in params: + path_params['owner'] = params['owner'] # noqa: E501 + if 'repo' in params: + path_params['repo'] = params['repo'] # noqa: E501 + if 'identifier' in params: + path_params['identifier'] = params['identifier'] # noqa: E501 + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'data' in params: + body_params = params['data'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = ['apikey', 'basic'] # noqa: E501 + + return self.api_client.call_api( + '/entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type=None, # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) diff --git a/bindings/python/src/cloudsmith_api/api/packages_api.py b/bindings/python/src/cloudsmith_api/api/packages_api.py index b373c26a..33b405b7 100644 --- a/bindings/python/src/cloudsmith_api/api/packages_api.py +++ b/bindings/python/src/cloudsmith_api/api/packages_api.py @@ -3459,6 +3459,117 @@ def packages_upload_maven_with_http_info(self, owner, repo, **kwargs): # noqa: _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) + def packages_upload_mcp(self, owner, repo, **kwargs): # noqa: E501 + """Create a new MCP package # noqa: E501 + + Create a new MCP package # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.packages_upload_mcp(owner, repo, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param str repo: (required) + :param McpPackageUploadRequest data: + :return: McpPackageUpload + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.packages_upload_mcp_with_http_info(owner, repo, **kwargs) # noqa: E501 + else: + (data) = self.packages_upload_mcp_with_http_info(owner, repo, **kwargs) # noqa: E501 + return data + + def packages_upload_mcp_with_http_info(self, owner, repo, **kwargs): # noqa: E501 + """Create a new MCP package # noqa: E501 + + Create a new MCP package # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.packages_upload_mcp_with_http_info(owner, repo, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param str repo: (required) + :param McpPackageUploadRequest data: + :return: McpPackageUpload + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['owner', 'repo', 'data'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method packages_upload_mcp" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'owner' is set + if self.api_client.client_side_validation and ('owner' not in params or + params['owner'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `owner` when calling `packages_upload_mcp`") # noqa: E501 + # verify the required parameter 'repo' is set + if self.api_client.client_side_validation and ('repo' not in params or + params['repo'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `repo` when calling `packages_upload_mcp`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'owner' in params: + path_params['owner'] = params['owner'] # noqa: E501 + if 'repo' in params: + path_params['repo'] = params['repo'] # noqa: E501 + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'data' in params: + body_params = params['data'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = ['apikey', 'basic'] # noqa: E501 + + return self.api_client.call_api( + '/packages/{owner}/{repo}/upload/mcp/', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='McpPackageUpload', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) + def packages_upload_npm(self, owner, repo, **kwargs): # noqa: E501 """Create a new npm package # noqa: E501 @@ -6567,6 +6678,117 @@ def packages_validate_upload_maven_with_http_info(self, owner, repo, **kwargs): _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) + def packages_validate_upload_mcp(self, owner, repo, **kwargs): # noqa: E501 + """Validate parameters for create MCP package # noqa: E501 + + Validate parameters for create MCP package # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.packages_validate_upload_mcp(owner, repo, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param str repo: (required) + :param McpPackageUploadRequest data: + :return: None + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.packages_validate_upload_mcp_with_http_info(owner, repo, **kwargs) # noqa: E501 + else: + (data) = self.packages_validate_upload_mcp_with_http_info(owner, repo, **kwargs) # noqa: E501 + return data + + def packages_validate_upload_mcp_with_http_info(self, owner, repo, **kwargs): # noqa: E501 + """Validate parameters for create MCP package # noqa: E501 + + Validate parameters for create MCP package # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.packages_validate_upload_mcp_with_http_info(owner, repo, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param str repo: (required) + :param McpPackageUploadRequest data: + :return: None + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['owner', 'repo', 'data'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method packages_validate_upload_mcp" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'owner' is set + if self.api_client.client_side_validation and ('owner' not in params or + params['owner'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `owner` when calling `packages_validate_upload_mcp`") # noqa: E501 + # verify the required parameter 'repo' is set + if self.api_client.client_side_validation and ('repo' not in params or + params['repo'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `repo` when calling `packages_validate_upload_mcp`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'owner' in params: + path_params['owner'] = params['owner'] # noqa: E501 + if 'repo' in params: + path_params['repo'] = params['repo'] # noqa: E501 + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'data' in params: + body_params = params['data'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = ['apikey', 'basic'] # noqa: E501 + + return self.api_client.call_api( + '/packages/{owner}/{repo}/validate-upload/mcp/', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type=None, # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) + def packages_validate_upload_npm(self, owner, repo, **kwargs): # noqa: E501 """Validate parameters for create npm package # noqa: E501 diff --git a/bindings/python/src/cloudsmith_api/api/recycle_bin_api.py b/bindings/python/src/cloudsmith_api/api/recycle_bin_api.py new file mode 100644 index 00000000..6270ffc0 --- /dev/null +++ b/bindings/python/src/cloudsmith_api/api/recycle_bin_api.py @@ -0,0 +1,248 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import re # noqa: F401 + +# python 2 and python 3 compatibility library +import six + +from cloudsmith_api.api_client import ApiClient + + +class RecycleBinApi(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + Ref: https://github.com/swagger-api/swagger-codegen + """ + + def __init__(self, api_client=None): + if api_client is None: + api_client = ApiClient() + self.api_client = api_client + + def recycle_bin_list(self, owner, **kwargs): # noqa: E501 + """List soft-deleted packages in recycle bin # noqa: E501 + + Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.recycle_bin_list(owner, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param int page: A page number within the paginated result set. + :param int page_size: Number of results to return per page. + :param str repository: Filter packages by repository slug + :return: list[RecycleBinPackage] + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.recycle_bin_list_with_http_info(owner, **kwargs) # noqa: E501 + else: + (data) = self.recycle_bin_list_with_http_info(owner, **kwargs) # noqa: E501 + return data + + def recycle_bin_list_with_http_info(self, owner, **kwargs): # noqa: E501 + """List soft-deleted packages in recycle bin # noqa: E501 + + Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.recycle_bin_list_with_http_info(owner, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param int page: A page number within the paginated result set. + :param int page_size: Number of results to return per page. + :param str repository: Filter packages by repository slug + :return: list[RecycleBinPackage] + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['owner', 'page', 'page_size', 'repository'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method recycle_bin_list" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'owner' is set + if self.api_client.client_side_validation and ('owner' not in params or + params['owner'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `owner` when calling `recycle_bin_list`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'owner' in params: + path_params['owner'] = params['owner'] # noqa: E501 + + query_params = [] + if 'page' in params: + query_params.append(('page', params['page'])) # noqa: E501 + if 'page_size' in params: + query_params.append(('page_size', params['page_size'])) # noqa: E501 + if 'repository' in params: + query_params.append(('repository', params['repository'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = ['apikey', 'basic'] # noqa: E501 + + return self.api_client.call_api( + '/recycle-bin/{owner}/', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='list[RecycleBinPackage]', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) + + def recycle_bin_recycle_bin_action(self, owner, **kwargs): # noqa: E501 + """recycle_bin_recycle_bin_action # noqa: E501 + + Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.recycle_bin_recycle_bin_action(owner, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param PackageRecycleBin data: + :return: PackageBulkActionResponse + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + if kwargs.get('async_req'): + return self.recycle_bin_recycle_bin_action_with_http_info(owner, **kwargs) # noqa: E501 + else: + (data) = self.recycle_bin_recycle_bin_action_with_http_info(owner, **kwargs) # noqa: E501 + return data + + def recycle_bin_recycle_bin_action_with_http_info(self, owner, **kwargs): # noqa: E501 + """recycle_bin_recycle_bin_action # noqa: E501 + + Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.recycle_bin_recycle_bin_action_with_http_info(owner, async_req=True) + >>> result = thread.get() + + :param async_req bool + :param str owner: (required) + :param PackageRecycleBin data: + :return: PackageBulkActionResponse + If the method is called asynchronously, + returns the request thread. + """ + + all_params = ['owner', 'data'] # noqa: E501 + all_params.append('async_req') + all_params.append('_return_http_data_only') + all_params.append('_preload_content') + all_params.append('_request_timeout') + + params = locals() + for key, val in six.iteritems(params['kwargs']): + if key not in all_params: + raise TypeError( + "Got an unexpected keyword argument '%s'" + " to method recycle_bin_recycle_bin_action" % key + ) + params[key] = val + del params['kwargs'] + # verify the required parameter 'owner' is set + if self.api_client.client_side_validation and ('owner' not in params or + params['owner'] is None): # noqa: E501 + raise ValueError("Missing the required parameter `owner` when calling `recycle_bin_recycle_bin_action`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'owner' in params: + path_params['owner'] = params['owner'] # noqa: E501 + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'data' in params: + body_params = params['data'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json']) # noqa: E501 + + # Authentication setting + auth_settings = ['apikey', 'basic'] # noqa: E501 + + return self.api_client.call_api( + '/recycle-bin/{owner}/action/', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='PackageBulkActionResponse', # noqa: E501 + auth_settings=auth_settings, + async_req=params.get('async_req'), + _return_http_data_only=params.get('_return_http_data_only'), + _preload_content=params.get('_preload_content', True), + _request_timeout=params.get('_request_timeout'), + collection_formats=collection_formats) diff --git a/bindings/python/src/cloudsmith_api/api/repos_api.py b/bindings/python/src/cloudsmith_api/api/repos_api.py index 10d35493..e9adb406 100644 --- a/bindings/python/src/cloudsmith_api/api/repos_api.py +++ b/bindings/python/src/cloudsmith_api/api/repos_api.py @@ -462,9 +462,9 @@ def repos_create_with_http_info(self, owner, **kwargs): # noqa: E501 collection_formats=collection_formats) def repos_delete(self, owner, identifier, **kwargs): # noqa: E501 - """Delete a repository in a given namespace. # noqa: E501 + """repos_delete # noqa: E501 - Delete a repository in a given namespace. # noqa: E501 + Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.repos_delete(owner, identifier, async_req=True) @@ -485,9 +485,9 @@ def repos_delete(self, owner, identifier, **kwargs): # noqa: E501 return data def repos_delete_with_http_info(self, owner, identifier, **kwargs): # noqa: E501 - """Delete a repository in a given namespace. # noqa: E501 + """repos_delete # noqa: E501 - Delete a repository in a given namespace. # noqa: E501 + Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.repos_delete_with_http_info(owner, identifier, async_req=True) diff --git a/bindings/python/src/cloudsmith_api/api_client.py b/bindings/python/src/cloudsmith_api/api_client.py index da7e1dfc..689d8bd2 100644 --- a/bindings/python/src/cloudsmith_api/api_client.py +++ b/bindings/python/src/cloudsmith_api/api_client.py @@ -74,7 +74,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None, self.default_headers[header_name] = header_value self.cookie = cookie # Set default User-Agent. - self.user_agent = 'Swagger-Codegen/2.0.25/python' + self.user_agent = 'Swagger-Codegen/2.0.26/python' self.client_side_validation = configuration.client_side_validation def __del__(self): diff --git a/bindings/python/src/cloudsmith_api/configuration.py b/bindings/python/src/cloudsmith_api/configuration.py index dafa80c1..6dabca15 100644 --- a/bindings/python/src/cloudsmith_api/configuration.py +++ b/bindings/python/src/cloudsmith_api/configuration.py @@ -249,5 +249,5 @@ def to_debug_report(self): "OS: {env}\n"\ "Python Version: {pyversion}\n"\ "Version of the API: v1\n"\ - "SDK Package Version: 2.0.25".\ + "SDK Package Version: 2.0.26".\ format(env=sys.platform, pyversion=sys.version) diff --git a/bindings/python/src/cloudsmith_api/models/__init__.py b/bindings/python/src/cloudsmith_api/models/__init__.py index 532009bb..56c52e2e 100644 --- a/bindings/python/src/cloudsmith_api/models/__init__.py +++ b/bindings/python/src/cloudsmith_api/models/__init__.py @@ -117,6 +117,8 @@ from cloudsmith_api.models.maven_upstream import MavenUpstream from cloudsmith_api.models.maven_upstream_request import MavenUpstreamRequest from cloudsmith_api.models.maven_upstream_request_patch import MavenUpstreamRequestPatch +from cloudsmith_api.models.mcp_package_upload import McpPackageUpload +from cloudsmith_api.models.mcp_package_upload_request import McpPackageUploadRequest from cloudsmith_api.models.namespace import Namespace from cloudsmith_api.models.namespace_audit_log import NamespaceAuditLog from cloudsmith_api.models.nested_license_policy import NestedLicensePolicy @@ -188,6 +190,7 @@ from cloudsmith_api.models.package_move_request import PackageMoveRequest from cloudsmith_api.models.package_quarantine import PackageQuarantine from cloudsmith_api.models.package_quarantine_request import PackageQuarantineRequest +from cloudsmith_api.models.package_recycle_bin import PackageRecycleBin from cloudsmith_api.models.package_resync import PackageResync from cloudsmith_api.models.package_status import PackageStatus from cloudsmith_api.models.package_tag import PackageTag @@ -213,6 +216,7 @@ from cloudsmith_api.models.rate_check import RateCheck from cloudsmith_api.models.raw_package_upload import RawPackageUpload from cloudsmith_api.models.raw_package_upload_request import RawPackageUploadRequest +from cloudsmith_api.models.recycle_bin_package import RecycleBinPackage from cloudsmith_api.models.repository import Repository from cloudsmith_api.models.repository_audit_log import RepositoryAuditLog from cloudsmith_api.models.repository_create import RepositoryCreate @@ -241,6 +245,8 @@ from cloudsmith_api.models.repository_rsa_key_create import RepositoryRsaKeyCreate from cloudsmith_api.models.repository_token import RepositoryToken from cloudsmith_api.models.repository_token_action import RepositoryTokenAction +from cloudsmith_api.models.repository_token_private_broadcasts import RepositoryTokenPrivateBroadcasts +from cloudsmith_api.models.repository_token_private_broadcasts_request import RepositoryTokenPrivateBroadcastsRequest from cloudsmith_api.models.repository_token_refresh import RepositoryTokenRefresh from cloudsmith_api.models.repository_token_refresh_request import RepositoryTokenRefreshRequest from cloudsmith_api.models.repository_token_request import RepositoryTokenRequest diff --git a/bindings/python/src/cloudsmith_api/models/alpine_upstream.py b/bindings/python/src/cloudsmith_api/models/alpine_upstream.py index 7ae45a80..82e04a0e 100644 --- a/bindings/python/src/cloudsmith_api/models/alpine_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/alpine_upstream.py @@ -54,6 +54,10 @@ class AlpineUpstream(object): 'name': 'str', 'pending_validation': 'bool', 'priority': 'int', + 'rsa_key_inline': 'str', + 'rsa_key_url': 'str', + 'rsa_verification': 'str', + 'rsa_verification_status': 'str', 'slug_perm': 'str', 'updated_at': 'datetime', 'upstream_url': 'str', @@ -82,13 +86,17 @@ class AlpineUpstream(object): 'name': 'name', 'pending_validation': 'pending_validation', 'priority': 'priority', + 'rsa_key_inline': 'rsa_key_inline', + 'rsa_key_url': 'rsa_key_url', + 'rsa_verification': 'rsa_verification', + 'rsa_verification_status': 'rsa_verification_status', 'slug_perm': 'slug_perm', 'updated_at': 'updated_at', 'upstream_url': 'upstream_url', 'verify_ssl': 'verify_ssl' } - def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, available=None, can_reindex=None, created_at=None, disable_reason='N/A', disable_reason_text=None, extra_header_1=None, extra_header_2=None, extra_value_1=None, extra_value_2=None, has_failed_signature_verification=None, index_package_count=None, index_status=None, is_active=None, last_indexed=None, mode='Proxy Only', name=None, pending_validation=None, priority=None, slug_perm=None, updated_at=None, upstream_url=None, verify_ssl=None, _configuration=None): # noqa: E501 + def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, available=None, can_reindex=None, created_at=None, disable_reason='N/A', disable_reason_text=None, extra_header_1=None, extra_header_2=None, extra_value_1=None, extra_value_2=None, has_failed_signature_verification=None, index_package_count=None, index_status=None, is_active=None, last_indexed=None, mode='Proxy Only', name=None, pending_validation=None, priority=None, rsa_key_inline=None, rsa_key_url=None, rsa_verification='Allow All', rsa_verification_status='Unknown', slug_perm=None, updated_at=None, upstream_url=None, verify_ssl=None, _configuration=None): # noqa: E501 """AlpineUpstream - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() @@ -115,6 +123,10 @@ def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, avail self._name = None self._pending_validation = None self._priority = None + self._rsa_key_inline = None + self._rsa_key_url = None + self._rsa_verification = None + self._rsa_verification_status = None self._slug_perm = None self._updated_at = None self._upstream_url = None @@ -162,6 +174,14 @@ def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, avail self.pending_validation = pending_validation if priority is not None: self.priority = priority + if rsa_key_inline is not None: + self.rsa_key_inline = rsa_key_inline + if rsa_key_url is not None: + self.rsa_key_url = rsa_key_url + if rsa_verification is not None: + self.rsa_verification = rsa_verification + if rsa_verification_status is not None: + self.rsa_verification_status = rsa_verification_status if slug_perm is not None: self.slug_perm = slug_perm if updated_at is not None: @@ -339,7 +359,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this AlpineUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( @@ -719,6 +739,115 @@ def priority(self, priority): self._priority = priority + @property + def rsa_key_inline(self): + """Gets the rsa_key_inline of this AlpineUpstream. + + A base64-encoded RSA public key in PEM format used to verify package signatures. + + :return: The rsa_key_inline of this AlpineUpstream. + :rtype: str + """ + return self._rsa_key_inline + + @rsa_key_inline.setter + def rsa_key_inline(self, rsa_key_inline): + """Sets the rsa_key_inline of this AlpineUpstream. + + A base64-encoded RSA public key in PEM format used to verify package signatures. + + :param rsa_key_inline: The rsa_key_inline of this AlpineUpstream. + :type: str + """ + + self._rsa_key_inline = rsa_key_inline + + @property + def rsa_key_url(self): + """Gets the rsa_key_url of this AlpineUpstream. + + When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + + :return: The rsa_key_url of this AlpineUpstream. + :rtype: str + """ + return self._rsa_key_url + + @rsa_key_url.setter + def rsa_key_url(self, rsa_key_url): + """Sets the rsa_key_url of this AlpineUpstream. + + When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + + :param rsa_key_url: The rsa_key_url of this AlpineUpstream. + :type: str + """ + if (self._configuration.client_side_validation and + rsa_key_url is not None and len(rsa_key_url) > 254): + raise ValueError("Invalid value for `rsa_key_url`, length must be less than or equal to `254`") # noqa: E501 + + self._rsa_key_url = rsa_key_url + + @property + def rsa_verification(self): + """Gets the rsa_verification of this AlpineUpstream. + + The RSA signature verification mode for this upstream. + + :return: The rsa_verification of this AlpineUpstream. + :rtype: str + """ + return self._rsa_verification + + @rsa_verification.setter + def rsa_verification(self, rsa_verification): + """Sets the rsa_verification of this AlpineUpstream. + + The RSA signature verification mode for this upstream. + + :param rsa_verification: The rsa_verification of this AlpineUpstream. + :type: str + """ + allowed_values = ["Allow All", "Warn on Invalid", "Reject Invalid"] # noqa: E501 + if (self._configuration.client_side_validation and + rsa_verification not in allowed_values): + raise ValueError( + "Invalid value for `rsa_verification` ({0}), must be one of {1}" # noqa: E501 + .format(rsa_verification, allowed_values) + ) + + self._rsa_verification = rsa_verification + + @property + def rsa_verification_status(self): + """Gets the rsa_verification_status of this AlpineUpstream. + + The RSA signature verification status for this upstream. + + :return: The rsa_verification_status of this AlpineUpstream. + :rtype: str + """ + return self._rsa_verification_status + + @rsa_verification_status.setter + def rsa_verification_status(self, rsa_verification_status): + """Sets the rsa_verification_status of this AlpineUpstream. + + The RSA signature verification status for this upstream. + + :param rsa_verification_status: The rsa_verification_status of this AlpineUpstream. + :type: str + """ + allowed_values = ["Unknown", "Invalid", "Valid", "Invalid (No Key)"] # noqa: E501 + if (self._configuration.client_side_validation and + rsa_verification_status not in allowed_values): + raise ValueError( + "Invalid value for `rsa_verification_status` ({0}), must be one of {1}" # noqa: E501 + .format(rsa_verification_status, allowed_values) + ) + + self._rsa_verification_status = rsa_verification_status + @property def slug_perm(self): """Gets the slug_perm of this AlpineUpstream. diff --git a/bindings/python/src/cloudsmith_api/models/alpine_upstream_request.py b/bindings/python/src/cloudsmith_api/models/alpine_upstream_request.py index ee91fcef..b06cb314 100644 --- a/bindings/python/src/cloudsmith_api/models/alpine_upstream_request.py +++ b/bindings/python/src/cloudsmith_api/models/alpine_upstream_request.py @@ -44,6 +44,8 @@ class AlpineUpstreamRequest(object): 'mode': 'str', 'name': 'str', 'priority': 'int', + 'rsa_key_url': 'str', + 'rsa_verification': 'str', 'upstream_url': 'str', 'verify_ssl': 'bool' } @@ -60,11 +62,13 @@ class AlpineUpstreamRequest(object): 'mode': 'mode', 'name': 'name', 'priority': 'priority', + 'rsa_key_url': 'rsa_key_url', + 'rsa_verification': 'rsa_verification', 'upstream_url': 'upstream_url', 'verify_ssl': 'verify_ssl' } - def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra_header_1=None, extra_header_2=None, extra_value_1=None, extra_value_2=None, is_active=None, mode='Proxy Only', name=None, priority=None, upstream_url=None, verify_ssl=None, _configuration=None): # noqa: E501 + def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra_header_1=None, extra_header_2=None, extra_value_1=None, extra_value_2=None, is_active=None, mode='Proxy Only', name=None, priority=None, rsa_key_url=None, rsa_verification='Allow All', upstream_url=None, verify_ssl=None, _configuration=None): # noqa: E501 """AlpineUpstreamRequest - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() @@ -81,6 +85,8 @@ def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra self._mode = None self._name = None self._priority = None + self._rsa_key_url = None + self._rsa_verification = None self._upstream_url = None self._verify_ssl = None self.discriminator = None @@ -106,6 +112,10 @@ def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra self.name = name if priority is not None: self.priority = priority + if rsa_key_url is not None: + self.rsa_key_url = rsa_key_url + if rsa_verification is not None: + self.rsa_verification = rsa_verification self.upstream_url = upstream_url if verify_ssl is not None: self.verify_ssl = verify_ssl @@ -424,6 +434,62 @@ def priority(self, priority): self._priority = priority + @property + def rsa_key_url(self): + """Gets the rsa_key_url of this AlpineUpstreamRequest. + + When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + + :return: The rsa_key_url of this AlpineUpstreamRequest. + :rtype: str + """ + return self._rsa_key_url + + @rsa_key_url.setter + def rsa_key_url(self, rsa_key_url): + """Sets the rsa_key_url of this AlpineUpstreamRequest. + + When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + + :param rsa_key_url: The rsa_key_url of this AlpineUpstreamRequest. + :type: str + """ + if (self._configuration.client_side_validation and + rsa_key_url is not None and len(rsa_key_url) > 254): + raise ValueError("Invalid value for `rsa_key_url`, length must be less than or equal to `254`") # noqa: E501 + + self._rsa_key_url = rsa_key_url + + @property + def rsa_verification(self): + """Gets the rsa_verification of this AlpineUpstreamRequest. + + The RSA signature verification mode for this upstream. + + :return: The rsa_verification of this AlpineUpstreamRequest. + :rtype: str + """ + return self._rsa_verification + + @rsa_verification.setter + def rsa_verification(self, rsa_verification): + """Sets the rsa_verification of this AlpineUpstreamRequest. + + The RSA signature verification mode for this upstream. + + :param rsa_verification: The rsa_verification of this AlpineUpstreamRequest. + :type: str + """ + allowed_values = ["Allow All", "Warn on Invalid", "Reject Invalid"] # noqa: E501 + if (self._configuration.client_side_validation and + rsa_verification not in allowed_values): + raise ValueError( + "Invalid value for `rsa_verification` ({0}), must be one of {1}" # noqa: E501 + .format(rsa_verification, allowed_values) + ) + + self._rsa_verification = rsa_verification + @property def upstream_url(self): """Gets the upstream_url of this AlpineUpstreamRequest. diff --git a/bindings/python/src/cloudsmith_api/models/alpine_upstream_request_patch.py b/bindings/python/src/cloudsmith_api/models/alpine_upstream_request_patch.py index 8e07a77a..f021eed9 100644 --- a/bindings/python/src/cloudsmith_api/models/alpine_upstream_request_patch.py +++ b/bindings/python/src/cloudsmith_api/models/alpine_upstream_request_patch.py @@ -44,6 +44,8 @@ class AlpineUpstreamRequestPatch(object): 'mode': 'str', 'name': 'str', 'priority': 'int', + 'rsa_key_url': 'str', + 'rsa_verification': 'str', 'upstream_url': 'str', 'verify_ssl': 'bool' } @@ -60,11 +62,13 @@ class AlpineUpstreamRequestPatch(object): 'mode': 'mode', 'name': 'name', 'priority': 'priority', + 'rsa_key_url': 'rsa_key_url', + 'rsa_verification': 'rsa_verification', 'upstream_url': 'upstream_url', 'verify_ssl': 'verify_ssl' } - def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra_header_1=None, extra_header_2=None, extra_value_1=None, extra_value_2=None, is_active=None, mode='Proxy Only', name=None, priority=None, upstream_url=None, verify_ssl=None, _configuration=None): # noqa: E501 + def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra_header_1=None, extra_header_2=None, extra_value_1=None, extra_value_2=None, is_active=None, mode='Proxy Only', name=None, priority=None, rsa_key_url=None, rsa_verification='Allow All', upstream_url=None, verify_ssl=None, _configuration=None): # noqa: E501 """AlpineUpstreamRequestPatch - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() @@ -81,6 +85,8 @@ def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra self._mode = None self._name = None self._priority = None + self._rsa_key_url = None + self._rsa_verification = None self._upstream_url = None self._verify_ssl = None self.discriminator = None @@ -107,6 +113,10 @@ def __init__(self, auth_mode='None', auth_secret=None, auth_username=None, extra self.name = name if priority is not None: self.priority = priority + if rsa_key_url is not None: + self.rsa_key_url = rsa_key_url + if rsa_verification is not None: + self.rsa_verification = rsa_verification if upstream_url is not None: self.upstream_url = upstream_url if verify_ssl is not None: @@ -424,6 +434,62 @@ def priority(self, priority): self._priority = priority + @property + def rsa_key_url(self): + """Gets the rsa_key_url of this AlpineUpstreamRequestPatch. + + When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + + :return: The rsa_key_url of this AlpineUpstreamRequestPatch. + :rtype: str + """ + return self._rsa_key_url + + @rsa_key_url.setter + def rsa_key_url(self, rsa_key_url): + """Sets the rsa_key_url of this AlpineUpstreamRequestPatch. + + When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + + :param rsa_key_url: The rsa_key_url of this AlpineUpstreamRequestPatch. + :type: str + """ + if (self._configuration.client_side_validation and + rsa_key_url is not None and len(rsa_key_url) > 254): + raise ValueError("Invalid value for `rsa_key_url`, length must be less than or equal to `254`") # noqa: E501 + + self._rsa_key_url = rsa_key_url + + @property + def rsa_verification(self): + """Gets the rsa_verification of this AlpineUpstreamRequestPatch. + + The RSA signature verification mode for this upstream. + + :return: The rsa_verification of this AlpineUpstreamRequestPatch. + :rtype: str + """ + return self._rsa_verification + + @rsa_verification.setter + def rsa_verification(self, rsa_verification): + """Sets the rsa_verification of this AlpineUpstreamRequestPatch. + + The RSA signature verification mode for this upstream. + + :param rsa_verification: The rsa_verification of this AlpineUpstreamRequestPatch. + :type: str + """ + allowed_values = ["Allow All", "Warn on Invalid", "Reject Invalid"] # noqa: E501 + if (self._configuration.client_side_validation and + rsa_verification not in allowed_values): + raise ValueError( + "Invalid value for `rsa_verification` ({0}), must be one of {1}" # noqa: E501 + .format(rsa_verification, allowed_values) + ) + + self._rsa_verification = rsa_verification + @property def upstream_url(self): """Gets the upstream_url of this AlpineUpstreamRequestPatch. diff --git a/bindings/python/src/cloudsmith_api/models/cargo_upstream.py b/bindings/python/src/cloudsmith_api/models/cargo_upstream.py index f83bc3c7..96fb78c7 100644 --- a/bindings/python/src/cloudsmith_api/models/cargo_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/cargo_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this CargoUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/composer_upstream.py b/bindings/python/src/cloudsmith_api/models/composer_upstream.py index 1d229e29..93db1320 100644 --- a/bindings/python/src/cloudsmith_api/models/composer_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/composer_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this ComposerUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/conda_upstream.py b/bindings/python/src/cloudsmith_api/models/conda_upstream.py index fb48c53b..1074d72a 100644 --- a/bindings/python/src/cloudsmith_api/models/conda_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/conda_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this CondaUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/cran_upstream.py b/bindings/python/src/cloudsmith_api/models/cran_upstream.py index f99383e4..884bceae 100644 --- a/bindings/python/src/cloudsmith_api/models/cran_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/cran_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this CranUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/dart_upstream.py b/bindings/python/src/cloudsmith_api/models/dart_upstream.py index 86ed2788..88b4ff90 100644 --- a/bindings/python/src/cloudsmith_api/models/dart_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/dart_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this DartUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/deb_upstream.py b/bindings/python/src/cloudsmith_api/models/deb_upstream.py index c9f2e74d..43dd6ab5 100644 --- a/bindings/python/src/cloudsmith_api/models/deb_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/deb_upstream.py @@ -412,7 +412,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this DebUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/docker_upstream.py b/bindings/python/src/cloudsmith_api/models/docker_upstream.py index 125a578e..ed65f997 100644 --- a/bindings/python/src/cloudsmith_api/models/docker_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/docker_upstream.py @@ -296,7 +296,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this DockerUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/generic_upstream.py b/bindings/python/src/cloudsmith_api/models/generic_upstream.py index 46224d5a..1ab847bd 100644 --- a/bindings/python/src/cloudsmith_api/models/generic_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/generic_upstream.py @@ -344,7 +344,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this GenericUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/go_upstream.py b/bindings/python/src/cloudsmith_api/models/go_upstream.py index 041bef3e..e39b875f 100644 --- a/bindings/python/src/cloudsmith_api/models/go_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/go_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this GoUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/helm_upstream.py b/bindings/python/src/cloudsmith_api/models/helm_upstream.py index e52790e4..41a0468f 100644 --- a/bindings/python/src/cloudsmith_api/models/helm_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/helm_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this HelmUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/hex_upstream.py b/bindings/python/src/cloudsmith_api/models/hex_upstream.py index 69b3d7e7..d2e84e5d 100644 --- a/bindings/python/src/cloudsmith_api/models/hex_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/hex_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this HexUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/huggingface_upstream.py b/bindings/python/src/cloudsmith_api/models/huggingface_upstream.py index 7fcdba52..6eabbac7 100644 --- a/bindings/python/src/cloudsmith_api/models/huggingface_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/huggingface_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this HuggingfaceUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/maven_upstream.py b/bindings/python/src/cloudsmith_api/models/maven_upstream.py index 5dbbae0e..7be16631 100644 --- a/bindings/python/src/cloudsmith_api/models/maven_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/maven_upstream.py @@ -369,7 +369,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this MavenUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/mcp_package_upload.py b/bindings/python/src/cloudsmith_api/models/mcp_package_upload.py new file mode 100644 index 00000000..32585aaa --- /dev/null +++ b/bindings/python/src/cloudsmith_api/models/mcp_package_upload.py @@ -0,0 +1,2396 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +import pprint +import re # noqa: F401 + +import six + +from cloudsmith_api.configuration import Configuration + + +class McpPackageUpload(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + Attributes: + swagger_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + swagger_types = { + 'architectures': 'list[Architecture]', + 'cdn_url': 'str', + 'checksum_md5': 'str', + 'checksum_sha1': 'str', + 'checksum_sha256': 'str', + 'checksum_sha512': 'str', + 'dependencies_checksum_md5': 'str', + 'dependencies_url': 'str', + 'description': 'str', + 'display_name': 'str', + 'distro': 'Distribution', + 'distro_version': 'DistributionVersion', + 'downloads': 'int', + 'epoch': 'int', + 'extension': 'str', + 'filename': 'str', + 'files': 'list[PackageFile]', + 'format': 'str', + 'format_url': 'str', + 'freeable_storage': 'int', + 'fully_qualified_name': 'str', + 'identifier_perm': 'str', + 'identifiers': 'dict(str, str)', + 'indexed': 'bool', + 'is_cancellable': 'bool', + 'is_copyable': 'bool', + 'is_deleteable': 'bool', + 'is_downloadable': 'bool', + 'is_moveable': 'bool', + 'is_quarantinable': 'bool', + 'is_quarantined': 'bool', + 'is_resyncable': 'bool', + 'is_security_scannable': 'bool', + 'is_sync_awaiting': 'bool', + 'is_sync_completed': 'bool', + 'is_sync_failed': 'bool', + 'is_sync_in_flight': 'bool', + 'is_sync_in_progress': 'bool', + 'license': 'str', + 'name': 'str', + 'namespace': 'str', + 'namespace_url': 'str', + 'num_files': 'int', + 'origin_repository': 'str', + 'origin_repository_url': 'str', + 'package_type': 'int', + 'policy_violated': 'bool', + 'raw_license': 'str', + 'release': 'str', + 'repository': 'str', + 'repository_url': 'str', + 'security_scan_completed_at': 'datetime', + 'security_scan_started_at': 'datetime', + 'security_scan_status': 'str', + 'security_scan_status_updated_at': 'datetime', + 'self_html_url': 'str', + 'self_url': 'str', + 'self_webapp_url': 'str', + 'signature_url': 'str', + 'size': 'int', + 'slug': 'str', + 'slug_perm': 'str', + 'spdx_license': 'str', + 'stage': 'int', + 'stage_str': 'str', + 'stage_updated_at': 'datetime', + 'status': 'int', + 'status_reason': 'str', + 'status_str': 'str', + 'status_updated_at': 'datetime', + 'status_url': 'str', + 'subtype': 'str', + 'summary': 'str', + 'sync_finished_at': 'datetime', + 'sync_progress': 'int', + 'tags_automatic': 'Tags', + 'tags_immutable': 'Tags', + 'type_display': 'str', + 'uploaded_at': 'datetime', + 'uploader': 'str', + 'uploader_url': 'str', + 'version': 'str', + 'version_orig': 'str', + 'vulnerability_scan_results_url': 'str' + } + + attribute_map = { + 'architectures': 'architectures', + 'cdn_url': 'cdn_url', + 'checksum_md5': 'checksum_md5', + 'checksum_sha1': 'checksum_sha1', + 'checksum_sha256': 'checksum_sha256', + 'checksum_sha512': 'checksum_sha512', + 'dependencies_checksum_md5': 'dependencies_checksum_md5', + 'dependencies_url': 'dependencies_url', + 'description': 'description', + 'display_name': 'display_name', + 'distro': 'distro', + 'distro_version': 'distro_version', + 'downloads': 'downloads', + 'epoch': 'epoch', + 'extension': 'extension', + 'filename': 'filename', + 'files': 'files', + 'format': 'format', + 'format_url': 'format_url', + 'freeable_storage': 'freeable_storage', + 'fully_qualified_name': 'fully_qualified_name', + 'identifier_perm': 'identifier_perm', + 'identifiers': 'identifiers', + 'indexed': 'indexed', + 'is_cancellable': 'is_cancellable', + 'is_copyable': 'is_copyable', + 'is_deleteable': 'is_deleteable', + 'is_downloadable': 'is_downloadable', + 'is_moveable': 'is_moveable', + 'is_quarantinable': 'is_quarantinable', + 'is_quarantined': 'is_quarantined', + 'is_resyncable': 'is_resyncable', + 'is_security_scannable': 'is_security_scannable', + 'is_sync_awaiting': 'is_sync_awaiting', + 'is_sync_completed': 'is_sync_completed', + 'is_sync_failed': 'is_sync_failed', + 'is_sync_in_flight': 'is_sync_in_flight', + 'is_sync_in_progress': 'is_sync_in_progress', + 'license': 'license', + 'name': 'name', + 'namespace': 'namespace', + 'namespace_url': 'namespace_url', + 'num_files': 'num_files', + 'origin_repository': 'origin_repository', + 'origin_repository_url': 'origin_repository_url', + 'package_type': 'package_type', + 'policy_violated': 'policy_violated', + 'raw_license': 'raw_license', + 'release': 'release', + 'repository': 'repository', + 'repository_url': 'repository_url', + 'security_scan_completed_at': 'security_scan_completed_at', + 'security_scan_started_at': 'security_scan_started_at', + 'security_scan_status': 'security_scan_status', + 'security_scan_status_updated_at': 'security_scan_status_updated_at', + 'self_html_url': 'self_html_url', + 'self_url': 'self_url', + 'self_webapp_url': 'self_webapp_url', + 'signature_url': 'signature_url', + 'size': 'size', + 'slug': 'slug', + 'slug_perm': 'slug_perm', + 'spdx_license': 'spdx_license', + 'stage': 'stage', + 'stage_str': 'stage_str', + 'stage_updated_at': 'stage_updated_at', + 'status': 'status', + 'status_reason': 'status_reason', + 'status_str': 'status_str', + 'status_updated_at': 'status_updated_at', + 'status_url': 'status_url', + 'subtype': 'subtype', + 'summary': 'summary', + 'sync_finished_at': 'sync_finished_at', + 'sync_progress': 'sync_progress', + 'tags_automatic': 'tags_automatic', + 'tags_immutable': 'tags_immutable', + 'type_display': 'type_display', + 'uploaded_at': 'uploaded_at', + 'uploader': 'uploader', + 'uploader_url': 'uploader_url', + 'version': 'version', + 'version_orig': 'version_orig', + 'vulnerability_scan_results_url': 'vulnerability_scan_results_url' + } + + def __init__(self, architectures=None, cdn_url=None, checksum_md5=None, checksum_sha1=None, checksum_sha256=None, checksum_sha512=None, dependencies_checksum_md5=None, dependencies_url=None, description=None, display_name=None, distro=None, distro_version=None, downloads=None, epoch=None, extension=None, filename=None, files=None, format=None, format_url=None, freeable_storage=None, fully_qualified_name=None, identifier_perm=None, identifiers=None, indexed=None, is_cancellable=None, is_copyable=None, is_deleteable=None, is_downloadable=None, is_moveable=None, is_quarantinable=None, is_quarantined=None, is_resyncable=None, is_security_scannable=None, is_sync_awaiting=None, is_sync_completed=None, is_sync_failed=None, is_sync_in_flight=None, is_sync_in_progress=None, license=None, name=None, namespace=None, namespace_url=None, num_files=None, origin_repository=None, origin_repository_url=None, package_type=None, policy_violated=None, raw_license=None, release=None, repository=None, repository_url=None, security_scan_completed_at=None, security_scan_started_at=None, security_scan_status='Awaiting Security Scan', security_scan_status_updated_at=None, self_html_url=None, self_url=None, self_webapp_url=None, signature_url=None, size=None, slug=None, slug_perm=None, spdx_license=None, stage=None, stage_str=None, stage_updated_at=None, status=None, status_reason=None, status_str=None, status_updated_at=None, status_url=None, subtype=None, summary=None, sync_finished_at=None, sync_progress=None, tags_automatic=None, tags_immutable=None, type_display=None, uploaded_at=None, uploader=None, uploader_url=None, version=None, version_orig=None, vulnerability_scan_results_url=None, _configuration=None): # noqa: E501 + """McpPackageUpload - a model defined in Swagger""" # noqa: E501 + if _configuration is None: + _configuration = Configuration() + self._configuration = _configuration + + self._architectures = None + self._cdn_url = None + self._checksum_md5 = None + self._checksum_sha1 = None + self._checksum_sha256 = None + self._checksum_sha512 = None + self._dependencies_checksum_md5 = None + self._dependencies_url = None + self._description = None + self._display_name = None + self._distro = None + self._distro_version = None + self._downloads = None + self._epoch = None + self._extension = None + self._filename = None + self._files = None + self._format = None + self._format_url = None + self._freeable_storage = None + self._fully_qualified_name = None + self._identifier_perm = None + self._identifiers = None + self._indexed = None + self._is_cancellable = None + self._is_copyable = None + self._is_deleteable = None + self._is_downloadable = None + self._is_moveable = None + self._is_quarantinable = None + self._is_quarantined = None + self._is_resyncable = None + self._is_security_scannable = None + self._is_sync_awaiting = None + self._is_sync_completed = None + self._is_sync_failed = None + self._is_sync_in_flight = None + self._is_sync_in_progress = None + self._license = None + self._name = None + self._namespace = None + self._namespace_url = None + self._num_files = None + self._origin_repository = None + self._origin_repository_url = None + self._package_type = None + self._policy_violated = None + self._raw_license = None + self._release = None + self._repository = None + self._repository_url = None + self._security_scan_completed_at = None + self._security_scan_started_at = None + self._security_scan_status = None + self._security_scan_status_updated_at = None + self._self_html_url = None + self._self_url = None + self._self_webapp_url = None + self._signature_url = None + self._size = None + self._slug = None + self._slug_perm = None + self._spdx_license = None + self._stage = None + self._stage_str = None + self._stage_updated_at = None + self._status = None + self._status_reason = None + self._status_str = None + self._status_updated_at = None + self._status_url = None + self._subtype = None + self._summary = None + self._sync_finished_at = None + self._sync_progress = None + self._tags_automatic = None + self._tags_immutable = None + self._type_display = None + self._uploaded_at = None + self._uploader = None + self._uploader_url = None + self._version = None + self._version_orig = None + self._vulnerability_scan_results_url = None + self.discriminator = None + + if architectures is not None: + self.architectures = architectures + if cdn_url is not None: + self.cdn_url = cdn_url + if checksum_md5 is not None: + self.checksum_md5 = checksum_md5 + if checksum_sha1 is not None: + self.checksum_sha1 = checksum_sha1 + if checksum_sha256 is not None: + self.checksum_sha256 = checksum_sha256 + if checksum_sha512 is not None: + self.checksum_sha512 = checksum_sha512 + if dependencies_checksum_md5 is not None: + self.dependencies_checksum_md5 = dependencies_checksum_md5 + if dependencies_url is not None: + self.dependencies_url = dependencies_url + if description is not None: + self.description = description + if display_name is not None: + self.display_name = display_name + if distro is not None: + self.distro = distro + if distro_version is not None: + self.distro_version = distro_version + if downloads is not None: + self.downloads = downloads + if epoch is not None: + self.epoch = epoch + if extension is not None: + self.extension = extension + if filename is not None: + self.filename = filename + if files is not None: + self.files = files + if format is not None: + self.format = format + if format_url is not None: + self.format_url = format_url + if freeable_storage is not None: + self.freeable_storage = freeable_storage + if fully_qualified_name is not None: + self.fully_qualified_name = fully_qualified_name + if identifier_perm is not None: + self.identifier_perm = identifier_perm + if identifiers is not None: + self.identifiers = identifiers + if indexed is not None: + self.indexed = indexed + if is_cancellable is not None: + self.is_cancellable = is_cancellable + if is_copyable is not None: + self.is_copyable = is_copyable + if is_deleteable is not None: + self.is_deleteable = is_deleteable + if is_downloadable is not None: + self.is_downloadable = is_downloadable + if is_moveable is not None: + self.is_moveable = is_moveable + if is_quarantinable is not None: + self.is_quarantinable = is_quarantinable + if is_quarantined is not None: + self.is_quarantined = is_quarantined + if is_resyncable is not None: + self.is_resyncable = is_resyncable + if is_security_scannable is not None: + self.is_security_scannable = is_security_scannable + if is_sync_awaiting is not None: + self.is_sync_awaiting = is_sync_awaiting + if is_sync_completed is not None: + self.is_sync_completed = is_sync_completed + if is_sync_failed is not None: + self.is_sync_failed = is_sync_failed + if is_sync_in_flight is not None: + self.is_sync_in_flight = is_sync_in_flight + if is_sync_in_progress is not None: + self.is_sync_in_progress = is_sync_in_progress + if license is not None: + self.license = license + if name is not None: + self.name = name + if namespace is not None: + self.namespace = namespace + if namespace_url is not None: + self.namespace_url = namespace_url + if num_files is not None: + self.num_files = num_files + if origin_repository is not None: + self.origin_repository = origin_repository + if origin_repository_url is not None: + self.origin_repository_url = origin_repository_url + if package_type is not None: + self.package_type = package_type + if policy_violated is not None: + self.policy_violated = policy_violated + if raw_license is not None: + self.raw_license = raw_license + if release is not None: + self.release = release + if repository is not None: + self.repository = repository + if repository_url is not None: + self.repository_url = repository_url + if security_scan_completed_at is not None: + self.security_scan_completed_at = security_scan_completed_at + if security_scan_started_at is not None: + self.security_scan_started_at = security_scan_started_at + if security_scan_status is not None: + self.security_scan_status = security_scan_status + if security_scan_status_updated_at is not None: + self.security_scan_status_updated_at = security_scan_status_updated_at + if self_html_url is not None: + self.self_html_url = self_html_url + if self_url is not None: + self.self_url = self_url + if self_webapp_url is not None: + self.self_webapp_url = self_webapp_url + if signature_url is not None: + self.signature_url = signature_url + if size is not None: + self.size = size + if slug is not None: + self.slug = slug + if slug_perm is not None: + self.slug_perm = slug_perm + if spdx_license is not None: + self.spdx_license = spdx_license + if stage is not None: + self.stage = stage + if stage_str is not None: + self.stage_str = stage_str + if stage_updated_at is not None: + self.stage_updated_at = stage_updated_at + if status is not None: + self.status = status + if status_reason is not None: + self.status_reason = status_reason + if status_str is not None: + self.status_str = status_str + if status_updated_at is not None: + self.status_updated_at = status_updated_at + if status_url is not None: + self.status_url = status_url + if subtype is not None: + self.subtype = subtype + if summary is not None: + self.summary = summary + if sync_finished_at is not None: + self.sync_finished_at = sync_finished_at + if sync_progress is not None: + self.sync_progress = sync_progress + if tags_automatic is not None: + self.tags_automatic = tags_automatic + if tags_immutable is not None: + self.tags_immutable = tags_immutable + if type_display is not None: + self.type_display = type_display + if uploaded_at is not None: + self.uploaded_at = uploaded_at + if uploader is not None: + self.uploader = uploader + if uploader_url is not None: + self.uploader_url = uploader_url + if version is not None: + self.version = version + if version_orig is not None: + self.version_orig = version_orig + if vulnerability_scan_results_url is not None: + self.vulnerability_scan_results_url = vulnerability_scan_results_url + + @property + def architectures(self): + """Gets the architectures of this McpPackageUpload. + + + :return: The architectures of this McpPackageUpload. + :rtype: list[Architecture] + """ + return self._architectures + + @architectures.setter + def architectures(self, architectures): + """Sets the architectures of this McpPackageUpload. + + + :param architectures: The architectures of this McpPackageUpload. + :type: list[Architecture] + """ + + self._architectures = architectures + + @property + def cdn_url(self): + """Gets the cdn_url of this McpPackageUpload. + + + :return: The cdn_url of this McpPackageUpload. + :rtype: str + """ + return self._cdn_url + + @cdn_url.setter + def cdn_url(self, cdn_url): + """Sets the cdn_url of this McpPackageUpload. + + + :param cdn_url: The cdn_url of this McpPackageUpload. + :type: str + """ + + self._cdn_url = cdn_url + + @property + def checksum_md5(self): + """Gets the checksum_md5 of this McpPackageUpload. + + + :return: The checksum_md5 of this McpPackageUpload. + :rtype: str + """ + return self._checksum_md5 + + @checksum_md5.setter + def checksum_md5(self, checksum_md5): + """Sets the checksum_md5 of this McpPackageUpload. + + + :param checksum_md5: The checksum_md5 of this McpPackageUpload. + :type: str + """ + + self._checksum_md5 = checksum_md5 + + @property + def checksum_sha1(self): + """Gets the checksum_sha1 of this McpPackageUpload. + + + :return: The checksum_sha1 of this McpPackageUpload. + :rtype: str + """ + return self._checksum_sha1 + + @checksum_sha1.setter + def checksum_sha1(self, checksum_sha1): + """Sets the checksum_sha1 of this McpPackageUpload. + + + :param checksum_sha1: The checksum_sha1 of this McpPackageUpload. + :type: str + """ + + self._checksum_sha1 = checksum_sha1 + + @property + def checksum_sha256(self): + """Gets the checksum_sha256 of this McpPackageUpload. + + + :return: The checksum_sha256 of this McpPackageUpload. + :rtype: str + """ + return self._checksum_sha256 + + @checksum_sha256.setter + def checksum_sha256(self, checksum_sha256): + """Sets the checksum_sha256 of this McpPackageUpload. + + + :param checksum_sha256: The checksum_sha256 of this McpPackageUpload. + :type: str + """ + + self._checksum_sha256 = checksum_sha256 + + @property + def checksum_sha512(self): + """Gets the checksum_sha512 of this McpPackageUpload. + + + :return: The checksum_sha512 of this McpPackageUpload. + :rtype: str + """ + return self._checksum_sha512 + + @checksum_sha512.setter + def checksum_sha512(self, checksum_sha512): + """Sets the checksum_sha512 of this McpPackageUpload. + + + :param checksum_sha512: The checksum_sha512 of this McpPackageUpload. + :type: str + """ + + self._checksum_sha512 = checksum_sha512 + + @property + def dependencies_checksum_md5(self): + """Gets the dependencies_checksum_md5 of this McpPackageUpload. + + A checksum of all of the package's dependencies. + + :return: The dependencies_checksum_md5 of this McpPackageUpload. + :rtype: str + """ + return self._dependencies_checksum_md5 + + @dependencies_checksum_md5.setter + def dependencies_checksum_md5(self, dependencies_checksum_md5): + """Sets the dependencies_checksum_md5 of this McpPackageUpload. + + A checksum of all of the package's dependencies. + + :param dependencies_checksum_md5: The dependencies_checksum_md5 of this McpPackageUpload. + :type: str + """ + + self._dependencies_checksum_md5 = dependencies_checksum_md5 + + @property + def dependencies_url(self): + """Gets the dependencies_url of this McpPackageUpload. + + + :return: The dependencies_url of this McpPackageUpload. + :rtype: str + """ + return self._dependencies_url + + @dependencies_url.setter + def dependencies_url(self, dependencies_url): + """Sets the dependencies_url of this McpPackageUpload. + + + :param dependencies_url: The dependencies_url of this McpPackageUpload. + :type: str + """ + + self._dependencies_url = dependencies_url + + @property + def description(self): + """Gets the description of this McpPackageUpload. + + A textual description of this package. + + :return: The description of this McpPackageUpload. + :rtype: str + """ + return self._description + + @description.setter + def description(self, description): + """Sets the description of this McpPackageUpload. + + A textual description of this package. + + :param description: The description of this McpPackageUpload. + :type: str + """ + + self._description = description + + @property + def display_name(self): + """Gets the display_name of this McpPackageUpload. + + + :return: The display_name of this McpPackageUpload. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """Sets the display_name of this McpPackageUpload. + + + :param display_name: The display_name of this McpPackageUpload. + :type: str + """ + + self._display_name = display_name + + @property + def distro(self): + """Gets the distro of this McpPackageUpload. + + + :return: The distro of this McpPackageUpload. + :rtype: Distribution + """ + return self._distro + + @distro.setter + def distro(self, distro): + """Sets the distro of this McpPackageUpload. + + + :param distro: The distro of this McpPackageUpload. + :type: Distribution + """ + + self._distro = distro + + @property + def distro_version(self): + """Gets the distro_version of this McpPackageUpload. + + + :return: The distro_version of this McpPackageUpload. + :rtype: DistributionVersion + """ + return self._distro_version + + @distro_version.setter + def distro_version(self, distro_version): + """Sets the distro_version of this McpPackageUpload. + + + :param distro_version: The distro_version of this McpPackageUpload. + :type: DistributionVersion + """ + + self._distro_version = distro_version + + @property + def downloads(self): + """Gets the downloads of this McpPackageUpload. + + + :return: The downloads of this McpPackageUpload. + :rtype: int + """ + return self._downloads + + @downloads.setter + def downloads(self, downloads): + """Sets the downloads of this McpPackageUpload. + + + :param downloads: The downloads of this McpPackageUpload. + :type: int + """ + + self._downloads = downloads + + @property + def epoch(self): + """Gets the epoch of this McpPackageUpload. + + The epoch of the package version (if any). + + :return: The epoch of this McpPackageUpload. + :rtype: int + """ + return self._epoch + + @epoch.setter + def epoch(self, epoch): + """Sets the epoch of this McpPackageUpload. + + The epoch of the package version (if any). + + :param epoch: The epoch of this McpPackageUpload. + :type: int + """ + + self._epoch = epoch + + @property + def extension(self): + """Gets the extension of this McpPackageUpload. + + + :return: The extension of this McpPackageUpload. + :rtype: str + """ + return self._extension + + @extension.setter + def extension(self, extension): + """Sets the extension of this McpPackageUpload. + + + :param extension: The extension of this McpPackageUpload. + :type: str + """ + + self._extension = extension + + @property + def filename(self): + """Gets the filename of this McpPackageUpload. + + + :return: The filename of this McpPackageUpload. + :rtype: str + """ + return self._filename + + @filename.setter + def filename(self, filename): + """Sets the filename of this McpPackageUpload. + + + :param filename: The filename of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + filename is not None and len(filename) < 1): + raise ValueError("Invalid value for `filename`, length must be greater than or equal to `1`") # noqa: E501 + + self._filename = filename + + @property + def files(self): + """Gets the files of this McpPackageUpload. + + + :return: The files of this McpPackageUpload. + :rtype: list[PackageFile] + """ + return self._files + + @files.setter + def files(self, files): + """Sets the files of this McpPackageUpload. + + + :param files: The files of this McpPackageUpload. + :type: list[PackageFile] + """ + + self._files = files + + @property + def format(self): + """Gets the format of this McpPackageUpload. + + + :return: The format of this McpPackageUpload. + :rtype: str + """ + return self._format + + @format.setter + def format(self, format): + """Sets the format of this McpPackageUpload. + + + :param format: The format of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + format is not None and len(format) < 1): + raise ValueError("Invalid value for `format`, length must be greater than or equal to `1`") # noqa: E501 + + self._format = format + + @property + def format_url(self): + """Gets the format_url of this McpPackageUpload. + + + :return: The format_url of this McpPackageUpload. + :rtype: str + """ + return self._format_url + + @format_url.setter + def format_url(self, format_url): + """Sets the format_url of this McpPackageUpload. + + + :param format_url: The format_url of this McpPackageUpload. + :type: str + """ + + self._format_url = format_url + + @property + def freeable_storage(self): + """Gets the freeable_storage of this McpPackageUpload. + + Amount of storage that will be freed if this package is deleted + + :return: The freeable_storage of this McpPackageUpload. + :rtype: int + """ + return self._freeable_storage + + @freeable_storage.setter + def freeable_storage(self, freeable_storage): + """Sets the freeable_storage of this McpPackageUpload. + + Amount of storage that will be freed if this package is deleted + + :param freeable_storage: The freeable_storage of this McpPackageUpload. + :type: int + """ + + self._freeable_storage = freeable_storage + + @property + def fully_qualified_name(self): + """Gets the fully_qualified_name of this McpPackageUpload. + + + :return: The fully_qualified_name of this McpPackageUpload. + :rtype: str + """ + return self._fully_qualified_name + + @fully_qualified_name.setter + def fully_qualified_name(self, fully_qualified_name): + """Sets the fully_qualified_name of this McpPackageUpload. + + + :param fully_qualified_name: The fully_qualified_name of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + fully_qualified_name is not None and len(fully_qualified_name) < 1): + raise ValueError("Invalid value for `fully_qualified_name`, length must be greater than or equal to `1`") # noqa: E501 + + self._fully_qualified_name = fully_qualified_name + + @property + def identifier_perm(self): + """Gets the identifier_perm of this McpPackageUpload. + + Unique and permanent identifier for the package. + + :return: The identifier_perm of this McpPackageUpload. + :rtype: str + """ + return self._identifier_perm + + @identifier_perm.setter + def identifier_perm(self, identifier_perm): + """Sets the identifier_perm of this McpPackageUpload. + + Unique and permanent identifier for the package. + + :param identifier_perm: The identifier_perm of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + identifier_perm is not None and len(identifier_perm) < 1): + raise ValueError("Invalid value for `identifier_perm`, length must be greater than or equal to `1`") # noqa: E501 + + self._identifier_perm = identifier_perm + + @property + def identifiers(self): + """Gets the identifiers of this McpPackageUpload. + + Return a map of identifier field names and their values. + + :return: The identifiers of this McpPackageUpload. + :rtype: dict(str, str) + """ + return self._identifiers + + @identifiers.setter + def identifiers(self, identifiers): + """Sets the identifiers of this McpPackageUpload. + + Return a map of identifier field names and their values. + + :param identifiers: The identifiers of this McpPackageUpload. + :type: dict(str, str) + """ + + self._identifiers = identifiers + + @property + def indexed(self): + """Gets the indexed of this McpPackageUpload. + + + :return: The indexed of this McpPackageUpload. + :rtype: bool + """ + return self._indexed + + @indexed.setter + def indexed(self, indexed): + """Sets the indexed of this McpPackageUpload. + + + :param indexed: The indexed of this McpPackageUpload. + :type: bool + """ + + self._indexed = indexed + + @property + def is_cancellable(self): + """Gets the is_cancellable of this McpPackageUpload. + + + :return: The is_cancellable of this McpPackageUpload. + :rtype: bool + """ + return self._is_cancellable + + @is_cancellable.setter + def is_cancellable(self, is_cancellable): + """Sets the is_cancellable of this McpPackageUpload. + + + :param is_cancellable: The is_cancellable of this McpPackageUpload. + :type: bool + """ + + self._is_cancellable = is_cancellable + + @property + def is_copyable(self): + """Gets the is_copyable of this McpPackageUpload. + + + :return: The is_copyable of this McpPackageUpload. + :rtype: bool + """ + return self._is_copyable + + @is_copyable.setter + def is_copyable(self, is_copyable): + """Sets the is_copyable of this McpPackageUpload. + + + :param is_copyable: The is_copyable of this McpPackageUpload. + :type: bool + """ + + self._is_copyable = is_copyable + + @property + def is_deleteable(self): + """Gets the is_deleteable of this McpPackageUpload. + + + :return: The is_deleteable of this McpPackageUpload. + :rtype: bool + """ + return self._is_deleteable + + @is_deleteable.setter + def is_deleteable(self, is_deleteable): + """Sets the is_deleteable of this McpPackageUpload. + + + :param is_deleteable: The is_deleteable of this McpPackageUpload. + :type: bool + """ + + self._is_deleteable = is_deleteable + + @property + def is_downloadable(self): + """Gets the is_downloadable of this McpPackageUpload. + + + :return: The is_downloadable of this McpPackageUpload. + :rtype: bool + """ + return self._is_downloadable + + @is_downloadable.setter + def is_downloadable(self, is_downloadable): + """Sets the is_downloadable of this McpPackageUpload. + + + :param is_downloadable: The is_downloadable of this McpPackageUpload. + :type: bool + """ + + self._is_downloadable = is_downloadable + + @property + def is_moveable(self): + """Gets the is_moveable of this McpPackageUpload. + + + :return: The is_moveable of this McpPackageUpload. + :rtype: bool + """ + return self._is_moveable + + @is_moveable.setter + def is_moveable(self, is_moveable): + """Sets the is_moveable of this McpPackageUpload. + + + :param is_moveable: The is_moveable of this McpPackageUpload. + :type: bool + """ + + self._is_moveable = is_moveable + + @property + def is_quarantinable(self): + """Gets the is_quarantinable of this McpPackageUpload. + + + :return: The is_quarantinable of this McpPackageUpload. + :rtype: bool + """ + return self._is_quarantinable + + @is_quarantinable.setter + def is_quarantinable(self, is_quarantinable): + """Sets the is_quarantinable of this McpPackageUpload. + + + :param is_quarantinable: The is_quarantinable of this McpPackageUpload. + :type: bool + """ + + self._is_quarantinable = is_quarantinable + + @property + def is_quarantined(self): + """Gets the is_quarantined of this McpPackageUpload. + + + :return: The is_quarantined of this McpPackageUpload. + :rtype: bool + """ + return self._is_quarantined + + @is_quarantined.setter + def is_quarantined(self, is_quarantined): + """Sets the is_quarantined of this McpPackageUpload. + + + :param is_quarantined: The is_quarantined of this McpPackageUpload. + :type: bool + """ + + self._is_quarantined = is_quarantined + + @property + def is_resyncable(self): + """Gets the is_resyncable of this McpPackageUpload. + + + :return: The is_resyncable of this McpPackageUpload. + :rtype: bool + """ + return self._is_resyncable + + @is_resyncable.setter + def is_resyncable(self, is_resyncable): + """Sets the is_resyncable of this McpPackageUpload. + + + :param is_resyncable: The is_resyncable of this McpPackageUpload. + :type: bool + """ + + self._is_resyncable = is_resyncable + + @property + def is_security_scannable(self): + """Gets the is_security_scannable of this McpPackageUpload. + + + :return: The is_security_scannable of this McpPackageUpload. + :rtype: bool + """ + return self._is_security_scannable + + @is_security_scannable.setter + def is_security_scannable(self, is_security_scannable): + """Sets the is_security_scannable of this McpPackageUpload. + + + :param is_security_scannable: The is_security_scannable of this McpPackageUpload. + :type: bool + """ + + self._is_security_scannable = is_security_scannable + + @property + def is_sync_awaiting(self): + """Gets the is_sync_awaiting of this McpPackageUpload. + + + :return: The is_sync_awaiting of this McpPackageUpload. + :rtype: bool + """ + return self._is_sync_awaiting + + @is_sync_awaiting.setter + def is_sync_awaiting(self, is_sync_awaiting): + """Sets the is_sync_awaiting of this McpPackageUpload. + + + :param is_sync_awaiting: The is_sync_awaiting of this McpPackageUpload. + :type: bool + """ + + self._is_sync_awaiting = is_sync_awaiting + + @property + def is_sync_completed(self): + """Gets the is_sync_completed of this McpPackageUpload. + + + :return: The is_sync_completed of this McpPackageUpload. + :rtype: bool + """ + return self._is_sync_completed + + @is_sync_completed.setter + def is_sync_completed(self, is_sync_completed): + """Sets the is_sync_completed of this McpPackageUpload. + + + :param is_sync_completed: The is_sync_completed of this McpPackageUpload. + :type: bool + """ + + self._is_sync_completed = is_sync_completed + + @property + def is_sync_failed(self): + """Gets the is_sync_failed of this McpPackageUpload. + + + :return: The is_sync_failed of this McpPackageUpload. + :rtype: bool + """ + return self._is_sync_failed + + @is_sync_failed.setter + def is_sync_failed(self, is_sync_failed): + """Sets the is_sync_failed of this McpPackageUpload. + + + :param is_sync_failed: The is_sync_failed of this McpPackageUpload. + :type: bool + """ + + self._is_sync_failed = is_sync_failed + + @property + def is_sync_in_flight(self): + """Gets the is_sync_in_flight of this McpPackageUpload. + + + :return: The is_sync_in_flight of this McpPackageUpload. + :rtype: bool + """ + return self._is_sync_in_flight + + @is_sync_in_flight.setter + def is_sync_in_flight(self, is_sync_in_flight): + """Sets the is_sync_in_flight of this McpPackageUpload. + + + :param is_sync_in_flight: The is_sync_in_flight of this McpPackageUpload. + :type: bool + """ + + self._is_sync_in_flight = is_sync_in_flight + + @property + def is_sync_in_progress(self): + """Gets the is_sync_in_progress of this McpPackageUpload. + + + :return: The is_sync_in_progress of this McpPackageUpload. + :rtype: bool + """ + return self._is_sync_in_progress + + @is_sync_in_progress.setter + def is_sync_in_progress(self, is_sync_in_progress): + """Sets the is_sync_in_progress of this McpPackageUpload. + + + :param is_sync_in_progress: The is_sync_in_progress of this McpPackageUpload. + :type: bool + """ + + self._is_sync_in_progress = is_sync_in_progress + + @property + def license(self): + """Gets the license of this McpPackageUpload. + + The license of this package. + + :return: The license of this McpPackageUpload. + :rtype: str + """ + return self._license + + @license.setter + def license(self, license): + """Sets the license of this McpPackageUpload. + + The license of this package. + + :param license: The license of this McpPackageUpload. + :type: str + """ + + self._license = license + + @property + def name(self): + """Gets the name of this McpPackageUpload. + + The name of this package. + + :return: The name of this McpPackageUpload. + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this McpPackageUpload. + + The name of this package. + + :param name: The name of this McpPackageUpload. + :type: str + """ + + self._name = name + + @property + def namespace(self): + """Gets the namespace of this McpPackageUpload. + + + :return: The namespace of this McpPackageUpload. + :rtype: str + """ + return self._namespace + + @namespace.setter + def namespace(self, namespace): + """Sets the namespace of this McpPackageUpload. + + + :param namespace: The namespace of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + namespace is not None and len(namespace) < 1): + raise ValueError("Invalid value for `namespace`, length must be greater than or equal to `1`") # noqa: E501 + + self._namespace = namespace + + @property + def namespace_url(self): + """Gets the namespace_url of this McpPackageUpload. + + + :return: The namespace_url of this McpPackageUpload. + :rtype: str + """ + return self._namespace_url + + @namespace_url.setter + def namespace_url(self, namespace_url): + """Sets the namespace_url of this McpPackageUpload. + + + :param namespace_url: The namespace_url of this McpPackageUpload. + :type: str + """ + + self._namespace_url = namespace_url + + @property + def num_files(self): + """Gets the num_files of this McpPackageUpload. + + + :return: The num_files of this McpPackageUpload. + :rtype: int + """ + return self._num_files + + @num_files.setter + def num_files(self, num_files): + """Sets the num_files of this McpPackageUpload. + + + :param num_files: The num_files of this McpPackageUpload. + :type: int + """ + + self._num_files = num_files + + @property + def origin_repository(self): + """Gets the origin_repository of this McpPackageUpload. + + + :return: The origin_repository of this McpPackageUpload. + :rtype: str + """ + return self._origin_repository + + @origin_repository.setter + def origin_repository(self, origin_repository): + """Sets the origin_repository of this McpPackageUpload. + + + :param origin_repository: The origin_repository of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + origin_repository is not None and len(origin_repository) < 1): + raise ValueError("Invalid value for `origin_repository`, length must be greater than or equal to `1`") # noqa: E501 + + self._origin_repository = origin_repository + + @property + def origin_repository_url(self): + """Gets the origin_repository_url of this McpPackageUpload. + + + :return: The origin_repository_url of this McpPackageUpload. + :rtype: str + """ + return self._origin_repository_url + + @origin_repository_url.setter + def origin_repository_url(self, origin_repository_url): + """Sets the origin_repository_url of this McpPackageUpload. + + + :param origin_repository_url: The origin_repository_url of this McpPackageUpload. + :type: str + """ + + self._origin_repository_url = origin_repository_url + + @property + def package_type(self): + """Gets the package_type of this McpPackageUpload. + + The type of package contents. + + :return: The package_type of this McpPackageUpload. + :rtype: int + """ + return self._package_type + + @package_type.setter + def package_type(self, package_type): + """Sets the package_type of this McpPackageUpload. + + The type of package contents. + + :param package_type: The package_type of this McpPackageUpload. + :type: int + """ + + self._package_type = package_type + + @property + def policy_violated(self): + """Gets the policy_violated of this McpPackageUpload. + + Whether or not the package has violated any policy. + + :return: The policy_violated of this McpPackageUpload. + :rtype: bool + """ + return self._policy_violated + + @policy_violated.setter + def policy_violated(self, policy_violated): + """Sets the policy_violated of this McpPackageUpload. + + Whether or not the package has violated any policy. + + :param policy_violated: The policy_violated of this McpPackageUpload. + :type: bool + """ + + self._policy_violated = policy_violated + + @property + def raw_license(self): + """Gets the raw_license of this McpPackageUpload. + + The raw license string. + + :return: The raw_license of this McpPackageUpload. + :rtype: str + """ + return self._raw_license + + @raw_license.setter + def raw_license(self, raw_license): + """Sets the raw_license of this McpPackageUpload. + + The raw license string. + + :param raw_license: The raw_license of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + raw_license is not None and len(raw_license) < 1): + raise ValueError("Invalid value for `raw_license`, length must be greater than or equal to `1`") # noqa: E501 + + self._raw_license = raw_license + + @property + def release(self): + """Gets the release of this McpPackageUpload. + + The release of the package version (if any). + + :return: The release of this McpPackageUpload. + :rtype: str + """ + return self._release + + @release.setter + def release(self, release): + """Sets the release of this McpPackageUpload. + + The release of the package version (if any). + + :param release: The release of this McpPackageUpload. + :type: str + """ + + self._release = release + + @property + def repository(self): + """Gets the repository of this McpPackageUpload. + + + :return: The repository of this McpPackageUpload. + :rtype: str + """ + return self._repository + + @repository.setter + def repository(self, repository): + """Sets the repository of this McpPackageUpload. + + + :param repository: The repository of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + repository is not None and len(repository) < 1): + raise ValueError("Invalid value for `repository`, length must be greater than or equal to `1`") # noqa: E501 + + self._repository = repository + + @property + def repository_url(self): + """Gets the repository_url of this McpPackageUpload. + + + :return: The repository_url of this McpPackageUpload. + :rtype: str + """ + return self._repository_url + + @repository_url.setter + def repository_url(self, repository_url): + """Sets the repository_url of this McpPackageUpload. + + + :param repository_url: The repository_url of this McpPackageUpload. + :type: str + """ + + self._repository_url = repository_url + + @property + def security_scan_completed_at(self): + """Gets the security_scan_completed_at of this McpPackageUpload. + + The datetime the security scanning was completed. + + :return: The security_scan_completed_at of this McpPackageUpload. + :rtype: datetime + """ + return self._security_scan_completed_at + + @security_scan_completed_at.setter + def security_scan_completed_at(self, security_scan_completed_at): + """Sets the security_scan_completed_at of this McpPackageUpload. + + The datetime the security scanning was completed. + + :param security_scan_completed_at: The security_scan_completed_at of this McpPackageUpload. + :type: datetime + """ + + self._security_scan_completed_at = security_scan_completed_at + + @property + def security_scan_started_at(self): + """Gets the security_scan_started_at of this McpPackageUpload. + + The datetime the security scanning was started. + + :return: The security_scan_started_at of this McpPackageUpload. + :rtype: datetime + """ + return self._security_scan_started_at + + @security_scan_started_at.setter + def security_scan_started_at(self, security_scan_started_at): + """Sets the security_scan_started_at of this McpPackageUpload. + + The datetime the security scanning was started. + + :param security_scan_started_at: The security_scan_started_at of this McpPackageUpload. + :type: datetime + """ + + self._security_scan_started_at = security_scan_started_at + + @property + def security_scan_status(self): + """Gets the security_scan_status of this McpPackageUpload. + + + :return: The security_scan_status of this McpPackageUpload. + :rtype: str + """ + return self._security_scan_status + + @security_scan_status.setter + def security_scan_status(self, security_scan_status): + """Sets the security_scan_status of this McpPackageUpload. + + + :param security_scan_status: The security_scan_status of this McpPackageUpload. + :type: str + """ + allowed_values = ["Awaiting Security Scan", "Security Scanning in Progress", "Scan Detected Vulnerabilities", "Scan Detected No Vulnerabilities", "Security Scanning Disabled", "Security Scanning Failed", "Security Scanning Skipped", "Security Scanning Not Supported"] # noqa: E501 + if (self._configuration.client_side_validation and + security_scan_status not in allowed_values): + raise ValueError( + "Invalid value for `security_scan_status` ({0}), must be one of {1}" # noqa: E501 + .format(security_scan_status, allowed_values) + ) + + self._security_scan_status = security_scan_status + + @property + def security_scan_status_updated_at(self): + """Gets the security_scan_status_updated_at of this McpPackageUpload. + + The datetime the security scanning status was updated. + + :return: The security_scan_status_updated_at of this McpPackageUpload. + :rtype: datetime + """ + return self._security_scan_status_updated_at + + @security_scan_status_updated_at.setter + def security_scan_status_updated_at(self, security_scan_status_updated_at): + """Sets the security_scan_status_updated_at of this McpPackageUpload. + + The datetime the security scanning status was updated. + + :param security_scan_status_updated_at: The security_scan_status_updated_at of this McpPackageUpload. + :type: datetime + """ + + self._security_scan_status_updated_at = security_scan_status_updated_at + + @property + def self_html_url(self): + """Gets the self_html_url of this McpPackageUpload. + + + :return: The self_html_url of this McpPackageUpload. + :rtype: str + """ + return self._self_html_url + + @self_html_url.setter + def self_html_url(self, self_html_url): + """Sets the self_html_url of this McpPackageUpload. + + + :param self_html_url: The self_html_url of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + self_html_url is not None and len(self_html_url) < 1): + raise ValueError("Invalid value for `self_html_url`, length must be greater than or equal to `1`") # noqa: E501 + + self._self_html_url = self_html_url + + @property + def self_url(self): + """Gets the self_url of this McpPackageUpload. + + + :return: The self_url of this McpPackageUpload. + :rtype: str + """ + return self._self_url + + @self_url.setter + def self_url(self, self_url): + """Sets the self_url of this McpPackageUpload. + + + :param self_url: The self_url of this McpPackageUpload. + :type: str + """ + + self._self_url = self_url + + @property + def self_webapp_url(self): + """Gets the self_webapp_url of this McpPackageUpload. + + + :return: The self_webapp_url of this McpPackageUpload. + :rtype: str + """ + return self._self_webapp_url + + @self_webapp_url.setter + def self_webapp_url(self, self_webapp_url): + """Sets the self_webapp_url of this McpPackageUpload. + + + :param self_webapp_url: The self_webapp_url of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + self_webapp_url is not None and len(self_webapp_url) < 1): + raise ValueError("Invalid value for `self_webapp_url`, length must be greater than or equal to `1`") # noqa: E501 + + self._self_webapp_url = self_webapp_url + + @property + def signature_url(self): + """Gets the signature_url of this McpPackageUpload. + + + :return: The signature_url of this McpPackageUpload. + :rtype: str + """ + return self._signature_url + + @signature_url.setter + def signature_url(self, signature_url): + """Sets the signature_url of this McpPackageUpload. + + + :param signature_url: The signature_url of this McpPackageUpload. + :type: str + """ + + self._signature_url = signature_url + + @property + def size(self): + """Gets the size of this McpPackageUpload. + + The calculated size of the package. + + :return: The size of this McpPackageUpload. + :rtype: int + """ + return self._size + + @size.setter + def size(self, size): + """Sets the size of this McpPackageUpload. + + The calculated size of the package. + + :param size: The size of this McpPackageUpload. + :type: int + """ + + self._size = size + + @property + def slug(self): + """Gets the slug of this McpPackageUpload. + + The public unique identifier for the package. + + :return: The slug of this McpPackageUpload. + :rtype: str + """ + return self._slug + + @slug.setter + def slug(self, slug): + """Sets the slug of this McpPackageUpload. + + The public unique identifier for the package. + + :param slug: The slug of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + slug is not None and len(slug) < 1): + raise ValueError("Invalid value for `slug`, length must be greater than or equal to `1`") # noqa: E501 + if (self._configuration.client_side_validation and + slug is not None and not re.search('^[-a-zA-Z0-9_]+$', slug)): # noqa: E501 + raise ValueError(r"Invalid value for `slug`, must be a follow pattern or equal to `/^[-a-zA-Z0-9_]+$/`") # noqa: E501 + + self._slug = slug + + @property + def slug_perm(self): + """Gets the slug_perm of this McpPackageUpload. + + + :return: The slug_perm of this McpPackageUpload. + :rtype: str + """ + return self._slug_perm + + @slug_perm.setter + def slug_perm(self, slug_perm): + """Sets the slug_perm of this McpPackageUpload. + + + :param slug_perm: The slug_perm of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + slug_perm is not None and len(slug_perm) < 1): + raise ValueError("Invalid value for `slug_perm`, length must be greater than or equal to `1`") # noqa: E501 + if (self._configuration.client_side_validation and + slug_perm is not None and not re.search('^[-a-zA-Z0-9_]+$', slug_perm)): # noqa: E501 + raise ValueError(r"Invalid value for `slug_perm`, must be a follow pattern or equal to `/^[-a-zA-Z0-9_]+$/`") # noqa: E501 + + self._slug_perm = slug_perm + + @property + def spdx_license(self): + """Gets the spdx_license of this McpPackageUpload. + + The SPDX license identifier for this package. + + :return: The spdx_license of this McpPackageUpload. + :rtype: str + """ + return self._spdx_license + + @spdx_license.setter + def spdx_license(self, spdx_license): + """Sets the spdx_license of this McpPackageUpload. + + The SPDX license identifier for this package. + + :param spdx_license: The spdx_license of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + spdx_license is not None and len(spdx_license) < 1): + raise ValueError("Invalid value for `spdx_license`, length must be greater than or equal to `1`") # noqa: E501 + + self._spdx_license = spdx_license + + @property + def stage(self): + """Gets the stage of this McpPackageUpload. + + The synchronisation (in progress) stage of the package. + + :return: The stage of this McpPackageUpload. + :rtype: int + """ + return self._stage + + @stage.setter + def stage(self, stage): + """Sets the stage of this McpPackageUpload. + + The synchronisation (in progress) stage of the package. + + :param stage: The stage of this McpPackageUpload. + :type: int + """ + + self._stage = stage + + @property + def stage_str(self): + """Gets the stage_str of this McpPackageUpload. + + + :return: The stage_str of this McpPackageUpload. + :rtype: str + """ + return self._stage_str + + @stage_str.setter + def stage_str(self, stage_str): + """Sets the stage_str of this McpPackageUpload. + + + :param stage_str: The stage_str of this McpPackageUpload. + :type: str + """ + + self._stage_str = stage_str + + @property + def stage_updated_at(self): + """Gets the stage_updated_at of this McpPackageUpload. + + The datetime the package stage was updated at. + + :return: The stage_updated_at of this McpPackageUpload. + :rtype: datetime + """ + return self._stage_updated_at + + @stage_updated_at.setter + def stage_updated_at(self, stage_updated_at): + """Sets the stage_updated_at of this McpPackageUpload. + + The datetime the package stage was updated at. + + :param stage_updated_at: The stage_updated_at of this McpPackageUpload. + :type: datetime + """ + + self._stage_updated_at = stage_updated_at + + @property + def status(self): + """Gets the status of this McpPackageUpload. + + The synchronisation status of the package. + + :return: The status of this McpPackageUpload. + :rtype: int + """ + return self._status + + @status.setter + def status(self, status): + """Sets the status of this McpPackageUpload. + + The synchronisation status of the package. + + :param status: The status of this McpPackageUpload. + :type: int + """ + + self._status = status + + @property + def status_reason(self): + """Gets the status_reason of this McpPackageUpload. + + A textual description for the synchronous status reason (if any + + :return: The status_reason of this McpPackageUpload. + :rtype: str + """ + return self._status_reason + + @status_reason.setter + def status_reason(self, status_reason): + """Sets the status_reason of this McpPackageUpload. + + A textual description for the synchronous status reason (if any + + :param status_reason: The status_reason of this McpPackageUpload. + :type: str + """ + + self._status_reason = status_reason + + @property + def status_str(self): + """Gets the status_str of this McpPackageUpload. + + + :return: The status_str of this McpPackageUpload. + :rtype: str + """ + return self._status_str + + @status_str.setter + def status_str(self, status_str): + """Sets the status_str of this McpPackageUpload. + + + :param status_str: The status_str of this McpPackageUpload. + :type: str + """ + + self._status_str = status_str + + @property + def status_updated_at(self): + """Gets the status_updated_at of this McpPackageUpload. + + The datetime the package status was updated at. + + :return: The status_updated_at of this McpPackageUpload. + :rtype: datetime + """ + return self._status_updated_at + + @status_updated_at.setter + def status_updated_at(self, status_updated_at): + """Sets the status_updated_at of this McpPackageUpload. + + The datetime the package status was updated at. + + :param status_updated_at: The status_updated_at of this McpPackageUpload. + :type: datetime + """ + + self._status_updated_at = status_updated_at + + @property + def status_url(self): + """Gets the status_url of this McpPackageUpload. + + + :return: The status_url of this McpPackageUpload. + :rtype: str + """ + return self._status_url + + @status_url.setter + def status_url(self, status_url): + """Sets the status_url of this McpPackageUpload. + + + :param status_url: The status_url of this McpPackageUpload. + :type: str + """ + + self._status_url = status_url + + @property + def subtype(self): + """Gets the subtype of this McpPackageUpload. + + + :return: The subtype of this McpPackageUpload. + :rtype: str + """ + return self._subtype + + @subtype.setter + def subtype(self, subtype): + """Sets the subtype of this McpPackageUpload. + + + :param subtype: The subtype of this McpPackageUpload. + :type: str + """ + + self._subtype = subtype + + @property + def summary(self): + """Gets the summary of this McpPackageUpload. + + A one-liner synopsis of this package. + + :return: The summary of this McpPackageUpload. + :rtype: str + """ + return self._summary + + @summary.setter + def summary(self, summary): + """Sets the summary of this McpPackageUpload. + + A one-liner synopsis of this package. + + :param summary: The summary of this McpPackageUpload. + :type: str + """ + + self._summary = summary + + @property + def sync_finished_at(self): + """Gets the sync_finished_at of this McpPackageUpload. + + The datetime the package sync was finished at. + + :return: The sync_finished_at of this McpPackageUpload. + :rtype: datetime + """ + return self._sync_finished_at + + @sync_finished_at.setter + def sync_finished_at(self, sync_finished_at): + """Sets the sync_finished_at of this McpPackageUpload. + + The datetime the package sync was finished at. + + :param sync_finished_at: The sync_finished_at of this McpPackageUpload. + :type: datetime + """ + + self._sync_finished_at = sync_finished_at + + @property + def sync_progress(self): + """Gets the sync_progress of this McpPackageUpload. + + Synchronisation progress (from 0-100) + + :return: The sync_progress of this McpPackageUpload. + :rtype: int + """ + return self._sync_progress + + @sync_progress.setter + def sync_progress(self, sync_progress): + """Sets the sync_progress of this McpPackageUpload. + + Synchronisation progress (from 0-100) + + :param sync_progress: The sync_progress of this McpPackageUpload. + :type: int + """ + + self._sync_progress = sync_progress + + @property + def tags_automatic(self): + """Gets the tags_automatic of this McpPackageUpload. + + + :return: The tags_automatic of this McpPackageUpload. + :rtype: Tags + """ + return self._tags_automatic + + @tags_automatic.setter + def tags_automatic(self, tags_automatic): + """Sets the tags_automatic of this McpPackageUpload. + + + :param tags_automatic: The tags_automatic of this McpPackageUpload. + :type: Tags + """ + + self._tags_automatic = tags_automatic + + @property + def tags_immutable(self): + """Gets the tags_immutable of this McpPackageUpload. + + + :return: The tags_immutable of this McpPackageUpload. + :rtype: Tags + """ + return self._tags_immutable + + @tags_immutable.setter + def tags_immutable(self, tags_immutable): + """Sets the tags_immutable of this McpPackageUpload. + + + :param tags_immutable: The tags_immutable of this McpPackageUpload. + :type: Tags + """ + + self._tags_immutable = tags_immutable + + @property + def type_display(self): + """Gets the type_display of this McpPackageUpload. + + + :return: The type_display of this McpPackageUpload. + :rtype: str + """ + return self._type_display + + @type_display.setter + def type_display(self, type_display): + """Sets the type_display of this McpPackageUpload. + + + :param type_display: The type_display of this McpPackageUpload. + :type: str + """ + + self._type_display = type_display + + @property + def uploaded_at(self): + """Gets the uploaded_at of this McpPackageUpload. + + The date this package was uploaded. + + :return: The uploaded_at of this McpPackageUpload. + :rtype: datetime + """ + return self._uploaded_at + + @uploaded_at.setter + def uploaded_at(self, uploaded_at): + """Sets the uploaded_at of this McpPackageUpload. + + The date this package was uploaded. + + :param uploaded_at: The uploaded_at of this McpPackageUpload. + :type: datetime + """ + + self._uploaded_at = uploaded_at + + @property + def uploader(self): + """Gets the uploader of this McpPackageUpload. + + + :return: The uploader of this McpPackageUpload. + :rtype: str + """ + return self._uploader + + @uploader.setter + def uploader(self, uploader): + """Sets the uploader of this McpPackageUpload. + + + :param uploader: The uploader of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + uploader is not None and len(uploader) < 1): + raise ValueError("Invalid value for `uploader`, length must be greater than or equal to `1`") # noqa: E501 + + self._uploader = uploader + + @property + def uploader_url(self): + """Gets the uploader_url of this McpPackageUpload. + + + :return: The uploader_url of this McpPackageUpload. + :rtype: str + """ + return self._uploader_url + + @uploader_url.setter + def uploader_url(self, uploader_url): + """Sets the uploader_url of this McpPackageUpload. + + + :param uploader_url: The uploader_url of this McpPackageUpload. + :type: str + """ + + self._uploader_url = uploader_url + + @property + def version(self): + """Gets the version of this McpPackageUpload. + + The raw version for this package. + + :return: The version of this McpPackageUpload. + :rtype: str + """ + return self._version + + @version.setter + def version(self, version): + """Sets the version of this McpPackageUpload. + + The raw version for this package. + + :param version: The version of this McpPackageUpload. + :type: str + """ + if (self._configuration.client_side_validation and + version is not None and len(version) > 255): + raise ValueError("Invalid value for `version`, length must be less than or equal to `255`") # noqa: E501 + + self._version = version + + @property + def version_orig(self): + """Gets the version_orig of this McpPackageUpload. + + + :return: The version_orig of this McpPackageUpload. + :rtype: str + """ + return self._version_orig + + @version_orig.setter + def version_orig(self, version_orig): + """Sets the version_orig of this McpPackageUpload. + + + :param version_orig: The version_orig of this McpPackageUpload. + :type: str + """ + + self._version_orig = version_orig + + @property + def vulnerability_scan_results_url(self): + """Gets the vulnerability_scan_results_url of this McpPackageUpload. + + + :return: The vulnerability_scan_results_url of this McpPackageUpload. + :rtype: str + """ + return self._vulnerability_scan_results_url + + @vulnerability_scan_results_url.setter + def vulnerability_scan_results_url(self, vulnerability_scan_results_url): + """Sets the vulnerability_scan_results_url of this McpPackageUpload. + + + :param vulnerability_scan_results_url: The vulnerability_scan_results_url of this McpPackageUpload. + :type: str + """ + + self._vulnerability_scan_results_url = vulnerability_scan_results_url + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.swagger_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + if issubclass(McpPackageUpload, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, McpPackageUpload): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, McpPackageUpload): + return True + + return self.to_dict() != other.to_dict() + diff --git a/bindings/python/src/cloudsmith_api/models/mcp_package_upload_request.py b/bindings/python/src/cloudsmith_api/models/mcp_package_upload_request.py new file mode 100644 index 00000000..2db8655f --- /dev/null +++ b/bindings/python/src/cloudsmith_api/models/mcp_package_upload_request.py @@ -0,0 +1,223 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +import pprint +import re # noqa: F401 + +import six + +from cloudsmith_api.configuration import Configuration + + +class McpPackageUploadRequest(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + Attributes: + swagger_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + swagger_types = { + 'package_file': 'str', + 'republish': 'bool', + 'tags': 'str', + 'version': 'str' + } + + attribute_map = { + 'package_file': 'package_file', + 'republish': 'republish', + 'tags': 'tags', + 'version': 'version' + } + + def __init__(self, package_file=None, republish=None, tags=None, version=None, _configuration=None): # noqa: E501 + """McpPackageUploadRequest - a model defined in Swagger""" # noqa: E501 + if _configuration is None: + _configuration = Configuration() + self._configuration = _configuration + + self._package_file = None + self._republish = None + self._tags = None + self._version = None + self.discriminator = None + + self.package_file = package_file + if republish is not None: + self.republish = republish + if tags is not None: + self.tags = tags + if version is not None: + self.version = version + + @property + def package_file(self): + """Gets the package_file of this McpPackageUploadRequest. + + The primary file for the package. + + :return: The package_file of this McpPackageUploadRequest. + :rtype: str + """ + return self._package_file + + @package_file.setter + def package_file(self, package_file): + """Sets the package_file of this McpPackageUploadRequest. + + The primary file for the package. + + :param package_file: The package_file of this McpPackageUploadRequest. + :type: str + """ + if self._configuration.client_side_validation and package_file is None: + raise ValueError("Invalid value for `package_file`, must not be `None`") # noqa: E501 + if (self._configuration.client_side_validation and + package_file is not None and len(package_file) < 1): + raise ValueError("Invalid value for `package_file`, length must be greater than or equal to `1`") # noqa: E501 + + self._package_file = package_file + + @property + def republish(self): + """Gets the republish of this McpPackageUploadRequest. + + If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. + + :return: The republish of this McpPackageUploadRequest. + :rtype: bool + """ + return self._republish + + @republish.setter + def republish(self, republish): + """Sets the republish of this McpPackageUploadRequest. + + If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. + + :param republish: The republish of this McpPackageUploadRequest. + :type: bool + """ + + self._republish = republish + + @property + def tags(self): + """Gets the tags of this McpPackageUploadRequest. + + A comma-separated values list of tags to add to the package. + + :return: The tags of this McpPackageUploadRequest. + :rtype: str + """ + return self._tags + + @tags.setter + def tags(self, tags): + """Sets the tags of this McpPackageUploadRequest. + + A comma-separated values list of tags to add to the package. + + :param tags: The tags of this McpPackageUploadRequest. + :type: str + """ + if (self._configuration.client_side_validation and + tags is not None and len(tags) > 1024): + raise ValueError("Invalid value for `tags`, length must be less than or equal to `1024`") # noqa: E501 + if (self._configuration.client_side_validation and + tags is not None and len(tags) < 1): + raise ValueError("Invalid value for `tags`, length must be greater than or equal to `1`") # noqa: E501 + + self._tags = tags + + @property + def version(self): + """Gets the version of this McpPackageUploadRequest. + + The raw version for this package. + + :return: The version of this McpPackageUploadRequest. + :rtype: str + """ + return self._version + + @version.setter + def version(self, version): + """Sets the version of this McpPackageUploadRequest. + + The raw version for this package. + + :param version: The version of this McpPackageUploadRequest. + :type: str + """ + if (self._configuration.client_side_validation and + version is not None and len(version) > 255): + raise ValueError("Invalid value for `version`, length must be less than or equal to `255`") # noqa: E501 + + self._version = version + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.swagger_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + if issubclass(McpPackageUploadRequest, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, McpPackageUploadRequest): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, McpPackageUploadRequest): + return True + + return self.to_dict() != other.to_dict() + diff --git a/bindings/python/src/cloudsmith_api/models/npm_upstream.py b/bindings/python/src/cloudsmith_api/models/npm_upstream.py index b22bdf53..e9ad0564 100644 --- a/bindings/python/src/cloudsmith_api/models/npm_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/npm_upstream.py @@ -344,7 +344,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this NpmUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/nuget_upstream.py b/bindings/python/src/cloudsmith_api/models/nuget_upstream.py index 4929aeb9..18200923 100644 --- a/bindings/python/src/cloudsmith_api/models/nuget_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/nuget_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this NugetUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/package_recycle_bin.py b/bindings/python/src/cloudsmith_api/models/package_recycle_bin.py new file mode 100644 index 00000000..23479608 --- /dev/null +++ b/bindings/python/src/cloudsmith_api/models/package_recycle_bin.py @@ -0,0 +1,197 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +import pprint +import re # noqa: F401 + +import six + +from cloudsmith_api.configuration import Configuration + + +class PackageRecycleBin(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + Attributes: + swagger_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + swagger_types = { + 'action': 'str', + 'identifiers': 'list[str]', + 'repository': 'str' + } + + attribute_map = { + 'action': 'action', + 'identifiers': 'identifiers', + 'repository': 'repository' + } + + def __init__(self, action=None, identifiers=None, repository=None, _configuration=None): # noqa: E501 + """PackageRecycleBin - a model defined in Swagger""" # noqa: E501 + if _configuration is None: + _configuration = Configuration() + self._configuration = _configuration + + self._action = None + self._identifiers = None + self._repository = None + self.discriminator = None + + self.action = action + self.identifiers = identifiers + if repository is not None: + self.repository = repository + + @property + def action(self): + """Gets the action of this PackageRecycleBin. + + The action to perform on soft-deleted packages. + + :return: The action of this PackageRecycleBin. + :rtype: str + """ + return self._action + + @action.setter + def action(self, action): + """Sets the action of this PackageRecycleBin. + + The action to perform on soft-deleted packages. + + :param action: The action of this PackageRecycleBin. + :type: str + """ + if self._configuration.client_side_validation and action is None: + raise ValueError("Invalid value for `action`, must not be `None`") # noqa: E501 + allowed_values = ["hard_delete", "restore"] # noqa: E501 + if (self._configuration.client_side_validation and + action not in allowed_values): + raise ValueError( + "Invalid value for `action` ({0}), must be one of {1}" # noqa: E501 + .format(action, allowed_values) + ) + + self._action = action + + @property + def identifiers(self): + """Gets the identifiers of this PackageRecycleBin. + + A list of soft-deleted package identifiers to action. + + :return: The identifiers of this PackageRecycleBin. + :rtype: list[str] + """ + return self._identifiers + + @identifiers.setter + def identifiers(self, identifiers): + """Sets the identifiers of this PackageRecycleBin. + + A list of soft-deleted package identifiers to action. + + :param identifiers: The identifiers of this PackageRecycleBin. + :type: list[str] + """ + if self._configuration.client_side_validation and identifiers is None: + raise ValueError("Invalid value for `identifiers`, must not be `None`") # noqa: E501 + + self._identifiers = identifiers + + @property + def repository(self): + """Gets the repository of this PackageRecycleBin. + + The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. + + :return: The repository of this PackageRecycleBin. + :rtype: str + """ + return self._repository + + @repository.setter + def repository(self, repository): + """Sets the repository of this PackageRecycleBin. + + The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. + + :param repository: The repository of this PackageRecycleBin. + :type: str + """ + if (self._configuration.client_side_validation and + repository is not None and len(repository) > 255): + raise ValueError("Invalid value for `repository`, length must be less than or equal to `255`") # noqa: E501 + if (self._configuration.client_side_validation and + repository is not None and len(repository) < 1): + raise ValueError("Invalid value for `repository`, length must be greater than or equal to `1`") # noqa: E501 + + self._repository = repository + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.swagger_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + if issubclass(PackageRecycleBin, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, PackageRecycleBin): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, PackageRecycleBin): + return True + + return self.to_dict() != other.to_dict() + diff --git a/bindings/python/src/cloudsmith_api/models/python_upstream.py b/bindings/python/src/cloudsmith_api/models/python_upstream.py index c50f6499..35ad860c 100644 --- a/bindings/python/src/cloudsmith_api/models/python_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/python_upstream.py @@ -344,7 +344,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this PythonUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/recycle_bin_package.py b/bindings/python/src/cloudsmith_api/models/recycle_bin_package.py new file mode 100644 index 00000000..303e8caf --- /dev/null +++ b/bindings/python/src/cloudsmith_api/models/recycle_bin_package.py @@ -0,0 +1,775 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +import pprint +import re # noqa: F401 + +import six + +from cloudsmith_api.configuration import Configuration + + +class RecycleBinPackage(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + Attributes: + swagger_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + swagger_types = { + 'action_by': 'str', + 'downloads': 'int', + 'filename': 'str', + 'format': 'str', + 'fully_qualified_name': 'str', + 'identifiers': 'dict(str, str)', + 'invoked_retention_rule': 'dict(str, str)', + 'is_deleteable': 'bool', + 'is_quarantined': 'bool', + 'is_restorable': 'bool', + 'name': 'str', + 'policy_violated': 'bool', + 'repository': 'str', + 'security_scan_completed_at': 'datetime', + 'security_scan_status': 'str', + 'size': 'int', + 'slug_perm': 'str', + 'status': 'int', + 'status_updated_at': 'datetime', + 'tags': 'Tags', + 'type_display': 'str', + 'uploaded_at': 'datetime', + 'uploader': 'str', + 'version': 'str' + } + + attribute_map = { + 'action_by': 'action_by', + 'downloads': 'downloads', + 'filename': 'filename', + 'format': 'format', + 'fully_qualified_name': 'fully_qualified_name', + 'identifiers': 'identifiers', + 'invoked_retention_rule': 'invoked_retention_rule', + 'is_deleteable': 'is_deleteable', + 'is_quarantined': 'is_quarantined', + 'is_restorable': 'is_restorable', + 'name': 'name', + 'policy_violated': 'policy_violated', + 'repository': 'repository', + 'security_scan_completed_at': 'security_scan_completed_at', + 'security_scan_status': 'security_scan_status', + 'size': 'size', + 'slug_perm': 'slug_perm', + 'status': 'status', + 'status_updated_at': 'status_updated_at', + 'tags': 'tags', + 'type_display': 'type_display', + 'uploaded_at': 'uploaded_at', + 'uploader': 'uploader', + 'version': 'version' + } + + def __init__(self, action_by=None, downloads=None, filename=None, format=None, fully_qualified_name=None, identifiers=None, invoked_retention_rule=None, is_deleteable=None, is_quarantined=None, is_restorable=None, name=None, policy_violated=None, repository=None, security_scan_completed_at=None, security_scan_status='Awaiting Security Scan', size=None, slug_perm=None, status=None, status_updated_at=None, tags=None, type_display=None, uploaded_at=None, uploader=None, version=None, _configuration=None): # noqa: E501 + """RecycleBinPackage - a model defined in Swagger""" # noqa: E501 + if _configuration is None: + _configuration = Configuration() + self._configuration = _configuration + + self._action_by = None + self._downloads = None + self._filename = None + self._format = None + self._fully_qualified_name = None + self._identifiers = None + self._invoked_retention_rule = None + self._is_deleteable = None + self._is_quarantined = None + self._is_restorable = None + self._name = None + self._policy_violated = None + self._repository = None + self._security_scan_completed_at = None + self._security_scan_status = None + self._size = None + self._slug_perm = None + self._status = None + self._status_updated_at = None + self._tags = None + self._type_display = None + self._uploaded_at = None + self._uploader = None + self._version = None + self.discriminator = None + + if action_by is not None: + self.action_by = action_by + if downloads is not None: + self.downloads = downloads + if filename is not None: + self.filename = filename + if format is not None: + self.format = format + if fully_qualified_name is not None: + self.fully_qualified_name = fully_qualified_name + if identifiers is not None: + self.identifiers = identifiers + if invoked_retention_rule is not None: + self.invoked_retention_rule = invoked_retention_rule + if is_deleteable is not None: + self.is_deleteable = is_deleteable + if is_quarantined is not None: + self.is_quarantined = is_quarantined + if is_restorable is not None: + self.is_restorable = is_restorable + if name is not None: + self.name = name + if policy_violated is not None: + self.policy_violated = policy_violated + if repository is not None: + self.repository = repository + if security_scan_completed_at is not None: + self.security_scan_completed_at = security_scan_completed_at + if security_scan_status is not None: + self.security_scan_status = security_scan_status + if size is not None: + self.size = size + if slug_perm is not None: + self.slug_perm = slug_perm + if status is not None: + self.status = status + if status_updated_at is not None: + self.status_updated_at = status_updated_at + if tags is not None: + self.tags = tags + if type_display is not None: + self.type_display = type_display + if uploaded_at is not None: + self.uploaded_at = uploaded_at + if uploader is not None: + self.uploader = uploader + if version is not None: + self.version = version + + @property + def action_by(self): + """Gets the action_by of this RecycleBinPackage. + + The name of the user who deleted the package. + + :return: The action_by of this RecycleBinPackage. + :rtype: str + """ + return self._action_by + + @action_by.setter + def action_by(self, action_by): + """Sets the action_by of this RecycleBinPackage. + + The name of the user who deleted the package. + + :param action_by: The action_by of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + action_by is not None and len(action_by) < 1): + raise ValueError("Invalid value for `action_by`, length must be greater than or equal to `1`") # noqa: E501 + + self._action_by = action_by + + @property + def downloads(self): + """Gets the downloads of this RecycleBinPackage. + + + :return: The downloads of this RecycleBinPackage. + :rtype: int + """ + return self._downloads + + @downloads.setter + def downloads(self, downloads): + """Sets the downloads of this RecycleBinPackage. + + + :param downloads: The downloads of this RecycleBinPackage. + :type: int + """ + + self._downloads = downloads + + @property + def filename(self): + """Gets the filename of this RecycleBinPackage. + + + :return: The filename of this RecycleBinPackage. + :rtype: str + """ + return self._filename + + @filename.setter + def filename(self, filename): + """Sets the filename of this RecycleBinPackage. + + + :param filename: The filename of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + filename is not None and len(filename) < 1): + raise ValueError("Invalid value for `filename`, length must be greater than or equal to `1`") # noqa: E501 + + self._filename = filename + + @property + def format(self): + """Gets the format of this RecycleBinPackage. + + + :return: The format of this RecycleBinPackage. + :rtype: str + """ + return self._format + + @format.setter + def format(self, format): + """Sets the format of this RecycleBinPackage. + + + :param format: The format of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + format is not None and len(format) < 1): + raise ValueError("Invalid value for `format`, length must be greater than or equal to `1`") # noqa: E501 + + self._format = format + + @property + def fully_qualified_name(self): + """Gets the fully_qualified_name of this RecycleBinPackage. + + The fully qualified name of the package. + + :return: The fully_qualified_name of this RecycleBinPackage. + :rtype: str + """ + return self._fully_qualified_name + + @fully_qualified_name.setter + def fully_qualified_name(self, fully_qualified_name): + """Sets the fully_qualified_name of this RecycleBinPackage. + + The fully qualified name of the package. + + :param fully_qualified_name: The fully_qualified_name of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + fully_qualified_name is not None and len(fully_qualified_name) < 1): + raise ValueError("Invalid value for `fully_qualified_name`, length must be greater than or equal to `1`") # noqa: E501 + + self._fully_qualified_name = fully_qualified_name + + @property + def identifiers(self): + """Gets the identifiers of this RecycleBinPackage. + + + :return: The identifiers of this RecycleBinPackage. + :rtype: dict(str, str) + """ + return self._identifiers + + @identifiers.setter + def identifiers(self, identifiers): + """Sets the identifiers of this RecycleBinPackage. + + + :param identifiers: The identifiers of this RecycleBinPackage. + :type: dict(str, str) + """ + + self._identifiers = identifiers + + @property + def invoked_retention_rule(self): + """Gets the invoked_retention_rule of this RecycleBinPackage. + + Information about the retention rule that triggered deletion (if any). + + :return: The invoked_retention_rule of this RecycleBinPackage. + :rtype: dict(str, str) + """ + return self._invoked_retention_rule + + @invoked_retention_rule.setter + def invoked_retention_rule(self, invoked_retention_rule): + """Sets the invoked_retention_rule of this RecycleBinPackage. + + Information about the retention rule that triggered deletion (if any). + + :param invoked_retention_rule: The invoked_retention_rule of this RecycleBinPackage. + :type: dict(str, str) + """ + + self._invoked_retention_rule = invoked_retention_rule + + @property + def is_deleteable(self): + """Gets the is_deleteable of this RecycleBinPackage. + + + :return: The is_deleteable of this RecycleBinPackage. + :rtype: bool + """ + return self._is_deleteable + + @is_deleteable.setter + def is_deleteable(self, is_deleteable): + """Sets the is_deleteable of this RecycleBinPackage. + + + :param is_deleteable: The is_deleteable of this RecycleBinPackage. + :type: bool + """ + + self._is_deleteable = is_deleteable + + @property + def is_quarantined(self): + """Gets the is_quarantined of this RecycleBinPackage. + + + :return: The is_quarantined of this RecycleBinPackage. + :rtype: bool + """ + return self._is_quarantined + + @is_quarantined.setter + def is_quarantined(self, is_quarantined): + """Sets the is_quarantined of this RecycleBinPackage. + + + :param is_quarantined: The is_quarantined of this RecycleBinPackage. + :type: bool + """ + + self._is_quarantined = is_quarantined + + @property + def is_restorable(self): + """Gets the is_restorable of this RecycleBinPackage. + + + :return: The is_restorable of this RecycleBinPackage. + :rtype: bool + """ + return self._is_restorable + + @is_restorable.setter + def is_restorable(self, is_restorable): + """Sets the is_restorable of this RecycleBinPackage. + + + :param is_restorable: The is_restorable of this RecycleBinPackage. + :type: bool + """ + + self._is_restorable = is_restorable + + @property + def name(self): + """Gets the name of this RecycleBinPackage. + + The name of this package. + + :return: The name of this RecycleBinPackage. + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this RecycleBinPackage. + + The name of this package. + + :param name: The name of this RecycleBinPackage. + :type: str + """ + + self._name = name + + @property + def policy_violated(self): + """Gets the policy_violated of this RecycleBinPackage. + + Whether or not the package has violated any policy. + + :return: The policy_violated of this RecycleBinPackage. + :rtype: bool + """ + return self._policy_violated + + @policy_violated.setter + def policy_violated(self, policy_violated): + """Sets the policy_violated of this RecycleBinPackage. + + Whether or not the package has violated any policy. + + :param policy_violated: The policy_violated of this RecycleBinPackage. + :type: bool + """ + + self._policy_violated = policy_violated + + @property + def repository(self): + """Gets the repository of this RecycleBinPackage. + + + :return: The repository of this RecycleBinPackage. + :rtype: str + """ + return self._repository + + @repository.setter + def repository(self, repository): + """Sets the repository of this RecycleBinPackage. + + + :param repository: The repository of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + repository is not None and len(repository) < 1): + raise ValueError("Invalid value for `repository`, length must be greater than or equal to `1`") # noqa: E501 + + self._repository = repository + + @property + def security_scan_completed_at(self): + """Gets the security_scan_completed_at of this RecycleBinPackage. + + The datetime the security scanning was completed. + + :return: The security_scan_completed_at of this RecycleBinPackage. + :rtype: datetime + """ + return self._security_scan_completed_at + + @security_scan_completed_at.setter + def security_scan_completed_at(self, security_scan_completed_at): + """Sets the security_scan_completed_at of this RecycleBinPackage. + + The datetime the security scanning was completed. + + :param security_scan_completed_at: The security_scan_completed_at of this RecycleBinPackage. + :type: datetime + """ + + self._security_scan_completed_at = security_scan_completed_at + + @property + def security_scan_status(self): + """Gets the security_scan_status of this RecycleBinPackage. + + + :return: The security_scan_status of this RecycleBinPackage. + :rtype: str + """ + return self._security_scan_status + + @security_scan_status.setter + def security_scan_status(self, security_scan_status): + """Sets the security_scan_status of this RecycleBinPackage. + + + :param security_scan_status: The security_scan_status of this RecycleBinPackage. + :type: str + """ + allowed_values = ["Awaiting Security Scan", "Security Scanning in Progress", "Scan Detected Vulnerabilities", "Scan Detected No Vulnerabilities", "Security Scanning Disabled", "Security Scanning Failed", "Security Scanning Skipped", "Security Scanning Not Supported"] # noqa: E501 + if (self._configuration.client_side_validation and + security_scan_status not in allowed_values): + raise ValueError( + "Invalid value for `security_scan_status` ({0}), must be one of {1}" # noqa: E501 + .format(security_scan_status, allowed_values) + ) + + self._security_scan_status = security_scan_status + + @property + def size(self): + """Gets the size of this RecycleBinPackage. + + The calculated size of the package. + + :return: The size of this RecycleBinPackage. + :rtype: int + """ + return self._size + + @size.setter + def size(self, size): + """Sets the size of this RecycleBinPackage. + + The calculated size of the package. + + :param size: The size of this RecycleBinPackage. + :type: int + """ + + self._size = size + + @property + def slug_perm(self): + """Gets the slug_perm of this RecycleBinPackage. + + + :return: The slug_perm of this RecycleBinPackage. + :rtype: str + """ + return self._slug_perm + + @slug_perm.setter + def slug_perm(self, slug_perm): + """Sets the slug_perm of this RecycleBinPackage. + + + :param slug_perm: The slug_perm of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + slug_perm is not None and len(slug_perm) < 1): + raise ValueError("Invalid value for `slug_perm`, length must be greater than or equal to `1`") # noqa: E501 + if (self._configuration.client_side_validation and + slug_perm is not None and not re.search('^[-a-zA-Z0-9_]+$', slug_perm)): # noqa: E501 + raise ValueError(r"Invalid value for `slug_perm`, must be a follow pattern or equal to `/^[-a-zA-Z0-9_]+$/`") # noqa: E501 + + self._slug_perm = slug_perm + + @property + def status(self): + """Gets the status of this RecycleBinPackage. + + The synchronisation status of the package. + + :return: The status of this RecycleBinPackage. + :rtype: int + """ + return self._status + + @status.setter + def status(self, status): + """Sets the status of this RecycleBinPackage. + + The synchronisation status of the package. + + :param status: The status of this RecycleBinPackage. + :type: int + """ + + self._status = status + + @property + def status_updated_at(self): + """Gets the status_updated_at of this RecycleBinPackage. + + The datetime the package status was updated at. + + :return: The status_updated_at of this RecycleBinPackage. + :rtype: datetime + """ + return self._status_updated_at + + @status_updated_at.setter + def status_updated_at(self, status_updated_at): + """Sets the status_updated_at of this RecycleBinPackage. + + The datetime the package status was updated at. + + :param status_updated_at: The status_updated_at of this RecycleBinPackage. + :type: datetime + """ + + self._status_updated_at = status_updated_at + + @property + def tags(self): + """Gets the tags of this RecycleBinPackage. + + + :return: The tags of this RecycleBinPackage. + :rtype: Tags + """ + return self._tags + + @tags.setter + def tags(self, tags): + """Sets the tags of this RecycleBinPackage. + + + :param tags: The tags of this RecycleBinPackage. + :type: Tags + """ + + self._tags = tags + + @property + def type_display(self): + """Gets the type_display of this RecycleBinPackage. + + + :return: The type_display of this RecycleBinPackage. + :rtype: str + """ + return self._type_display + + @type_display.setter + def type_display(self, type_display): + """Sets the type_display of this RecycleBinPackage. + + + :param type_display: The type_display of this RecycleBinPackage. + :type: str + """ + + self._type_display = type_display + + @property + def uploaded_at(self): + """Gets the uploaded_at of this RecycleBinPackage. + + The date this package was uploaded. + + :return: The uploaded_at of this RecycleBinPackage. + :rtype: datetime + """ + return self._uploaded_at + + @uploaded_at.setter + def uploaded_at(self, uploaded_at): + """Sets the uploaded_at of this RecycleBinPackage. + + The date this package was uploaded. + + :param uploaded_at: The uploaded_at of this RecycleBinPackage. + :type: datetime + """ + + self._uploaded_at = uploaded_at + + @property + def uploader(self): + """Gets the uploader of this RecycleBinPackage. + + + :return: The uploader of this RecycleBinPackage. + :rtype: str + """ + return self._uploader + + @uploader.setter + def uploader(self, uploader): + """Sets the uploader of this RecycleBinPackage. + + + :param uploader: The uploader of this RecycleBinPackage. + :type: str + """ + if (self._configuration.client_side_validation and + uploader is not None and len(uploader) < 1): + raise ValueError("Invalid value for `uploader`, length must be greater than or equal to `1`") # noqa: E501 + + self._uploader = uploader + + @property + def version(self): + """Gets the version of this RecycleBinPackage. + + The raw version for this package. + + :return: The version of this RecycleBinPackage. + :rtype: str + """ + return self._version + + @version.setter + def version(self, version): + """Sets the version of this RecycleBinPackage. + + The raw version for this package. + + :param version: The version of this RecycleBinPackage. + :type: str + """ + + self._version = version + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.swagger_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + if issubclass(RecycleBinPackage, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, RecycleBinPackage): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, RecycleBinPackage): + return True + + return self.to_dict() != other.to_dict() + diff --git a/bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts.py b/bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts.py new file mode 100644 index 00000000..89e7a257 --- /dev/null +++ b/bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +import pprint +import re # noqa: F401 + +import six + +from cloudsmith_api.configuration import Configuration + + +class RepositoryTokenPrivateBroadcasts(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + Attributes: + swagger_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + swagger_types = { + 'access_private_broadcasts': 'bool' + } + + attribute_map = { + 'access_private_broadcasts': 'access_private_broadcasts' + } + + def __init__(self, access_private_broadcasts=None, _configuration=None): # noqa: E501 + """RepositoryTokenPrivateBroadcasts - a model defined in Swagger""" # noqa: E501 + if _configuration is None: + _configuration = Configuration() + self._configuration = _configuration + + self._access_private_broadcasts = None + self.discriminator = None + + self.access_private_broadcasts = access_private_broadcasts + + @property + def access_private_broadcasts(self): + """Gets the access_private_broadcasts of this RepositoryTokenPrivateBroadcasts. + + Whether the token should have access to private broadcasts. + + :return: The access_private_broadcasts of this RepositoryTokenPrivateBroadcasts. + :rtype: bool + """ + return self._access_private_broadcasts + + @access_private_broadcasts.setter + def access_private_broadcasts(self, access_private_broadcasts): + """Sets the access_private_broadcasts of this RepositoryTokenPrivateBroadcasts. + + Whether the token should have access to private broadcasts. + + :param access_private_broadcasts: The access_private_broadcasts of this RepositoryTokenPrivateBroadcasts. + :type: bool + """ + if self._configuration.client_side_validation and access_private_broadcasts is None: + raise ValueError("Invalid value for `access_private_broadcasts`, must not be `None`") # noqa: E501 + + self._access_private_broadcasts = access_private_broadcasts + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.swagger_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + if issubclass(RepositoryTokenPrivateBroadcasts, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, RepositoryTokenPrivateBroadcasts): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, RepositoryTokenPrivateBroadcasts): + return True + + return self.to_dict() != other.to_dict() + diff --git a/bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts_request.py b/bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts_request.py new file mode 100644 index 00000000..52c801e0 --- /dev/null +++ b/bindings/python/src/cloudsmith_api/models/repository_token_private_broadcasts_request.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +import pprint +import re # noqa: F401 + +import six + +from cloudsmith_api.configuration import Configuration + + +class RepositoryTokenPrivateBroadcastsRequest(object): + """NOTE: This class is auto generated by the swagger code generator program. + + Do not edit the class manually. + """ + + """ + Attributes: + swagger_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + swagger_types = { + 'access_private_broadcasts': 'bool' + } + + attribute_map = { + 'access_private_broadcasts': 'access_private_broadcasts' + } + + def __init__(self, access_private_broadcasts=None, _configuration=None): # noqa: E501 + """RepositoryTokenPrivateBroadcastsRequest - a model defined in Swagger""" # noqa: E501 + if _configuration is None: + _configuration = Configuration() + self._configuration = _configuration + + self._access_private_broadcasts = None + self.discriminator = None + + self.access_private_broadcasts = access_private_broadcasts + + @property + def access_private_broadcasts(self): + """Gets the access_private_broadcasts of this RepositoryTokenPrivateBroadcastsRequest. + + Whether the token should have access to private broadcasts. + + :return: The access_private_broadcasts of this RepositoryTokenPrivateBroadcastsRequest. + :rtype: bool + """ + return self._access_private_broadcasts + + @access_private_broadcasts.setter + def access_private_broadcasts(self, access_private_broadcasts): + """Sets the access_private_broadcasts of this RepositoryTokenPrivateBroadcastsRequest. + + Whether the token should have access to private broadcasts. + + :param access_private_broadcasts: The access_private_broadcasts of this RepositoryTokenPrivateBroadcastsRequest. + :type: bool + """ + if self._configuration.client_side_validation and access_private_broadcasts is None: + raise ValueError("Invalid value for `access_private_broadcasts`, must not be `None`") # noqa: E501 + + self._access_private_broadcasts = access_private_broadcasts + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.swagger_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + if issubclass(RepositoryTokenPrivateBroadcastsRequest, dict): + for key, value in self.items(): + result[key] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, RepositoryTokenPrivateBroadcastsRequest): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, RepositoryTokenPrivateBroadcastsRequest): + return True + + return self.to_dict() != other.to_dict() + diff --git a/bindings/python/src/cloudsmith_api/models/repository_token_refresh_request.py b/bindings/python/src/cloudsmith_api/models/repository_token_refresh_request.py index 75556097..6ab40462 100644 --- a/bindings/python/src/cloudsmith_api/models/repository_token_refresh_request.py +++ b/bindings/python/src/cloudsmith_api/models/repository_token_refresh_request.py @@ -33,7 +33,6 @@ class RepositoryTokenRefreshRequest(object): and the value is json key in definition. """ swagger_types = { - 'access_private_broadcasts': 'bool', 'eula_required': 'bool', 'is_active': 'bool', 'limit_bandwidth': 'int', @@ -51,7 +50,6 @@ class RepositoryTokenRefreshRequest(object): } attribute_map = { - 'access_private_broadcasts': 'access_private_broadcasts', 'eula_required': 'eula_required', 'is_active': 'is_active', 'limit_bandwidth': 'limit_bandwidth', @@ -68,13 +66,12 @@ class RepositoryTokenRefreshRequest(object): 'token': 'token' } - def __init__(self, access_private_broadcasts=None, eula_required=None, is_active=None, limit_bandwidth=None, limit_bandwidth_unit='Byte', limit_date_range_from=None, limit_date_range_to=None, limit_num_clients=None, limit_num_downloads=None, limit_package_query=None, limit_path_query=None, metadata=None, scheduled_reset_at=None, scheduled_reset_period='Never Reset', token=None, _configuration=None): # noqa: E501 + def __init__(self, eula_required=None, is_active=None, limit_bandwidth=None, limit_bandwidth_unit='Byte', limit_date_range_from=None, limit_date_range_to=None, limit_num_clients=None, limit_num_downloads=None, limit_package_query=None, limit_path_query=None, metadata=None, scheduled_reset_at=None, scheduled_reset_period='Never Reset', token=None, _configuration=None): # noqa: E501 """RepositoryTokenRefreshRequest - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() self._configuration = _configuration - self._access_private_broadcasts = None self._eula_required = None self._is_active = None self._limit_bandwidth = None @@ -91,8 +88,6 @@ def __init__(self, access_private_broadcasts=None, eula_required=None, is_active self._token = None self.discriminator = None - if access_private_broadcasts is not None: - self.access_private_broadcasts = access_private_broadcasts if eula_required is not None: self.eula_required = eula_required if is_active is not None: @@ -122,29 +117,6 @@ def __init__(self, access_private_broadcasts=None, eula_required=None, is_active if token is not None: self.token = token - @property - def access_private_broadcasts(self): - """Gets the access_private_broadcasts of this RepositoryTokenRefreshRequest. - - If enabled, this token can be used for private broadcasts - - :return: The access_private_broadcasts of this RepositoryTokenRefreshRequest. - :rtype: bool - """ - return self._access_private_broadcasts - - @access_private_broadcasts.setter - def access_private_broadcasts(self, access_private_broadcasts): - """Sets the access_private_broadcasts of this RepositoryTokenRefreshRequest. - - If enabled, this token can be used for private broadcasts - - :param access_private_broadcasts: The access_private_broadcasts of this RepositoryTokenRefreshRequest. - :type: bool - """ - - self._access_private_broadcasts = access_private_broadcasts - @property def eula_required(self): """Gets the eula_required of this RepositoryTokenRefreshRequest. diff --git a/bindings/python/src/cloudsmith_api/models/repository_token_request.py b/bindings/python/src/cloudsmith_api/models/repository_token_request.py index a51dd51b..ab095bea 100644 --- a/bindings/python/src/cloudsmith_api/models/repository_token_request.py +++ b/bindings/python/src/cloudsmith_api/models/repository_token_request.py @@ -33,7 +33,6 @@ class RepositoryTokenRequest(object): and the value is json key in definition. """ swagger_types = { - 'access_private_broadcasts': 'bool', 'eula_required': 'bool', 'is_active': 'bool', 'limit_bandwidth': 'int', @@ -52,7 +51,6 @@ class RepositoryTokenRequest(object): } attribute_map = { - 'access_private_broadcasts': 'access_private_broadcasts', 'eula_required': 'eula_required', 'is_active': 'is_active', 'limit_bandwidth': 'limit_bandwidth', @@ -70,13 +68,12 @@ class RepositoryTokenRequest(object): 'token': 'token' } - def __init__(self, access_private_broadcasts=None, eula_required=None, is_active=None, limit_bandwidth=None, limit_bandwidth_unit='Byte', limit_date_range_from=None, limit_date_range_to=None, limit_num_clients=None, limit_num_downloads=None, limit_package_query=None, limit_path_query=None, metadata=None, name=None, scheduled_reset_at=None, scheduled_reset_period='Never Reset', token=None, _configuration=None): # noqa: E501 + def __init__(self, eula_required=None, is_active=None, limit_bandwidth=None, limit_bandwidth_unit='Byte', limit_date_range_from=None, limit_date_range_to=None, limit_num_clients=None, limit_num_downloads=None, limit_package_query=None, limit_path_query=None, metadata=None, name=None, scheduled_reset_at=None, scheduled_reset_period='Never Reset', token=None, _configuration=None): # noqa: E501 """RepositoryTokenRequest - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() self._configuration = _configuration - self._access_private_broadcasts = None self._eula_required = None self._is_active = None self._limit_bandwidth = None @@ -94,8 +91,6 @@ def __init__(self, access_private_broadcasts=None, eula_required=None, is_active self._token = None self.discriminator = None - if access_private_broadcasts is not None: - self.access_private_broadcasts = access_private_broadcasts if eula_required is not None: self.eula_required = eula_required if is_active is not None: @@ -126,29 +121,6 @@ def __init__(self, access_private_broadcasts=None, eula_required=None, is_active if token is not None: self.token = token - @property - def access_private_broadcasts(self): - """Gets the access_private_broadcasts of this RepositoryTokenRequest. - - If enabled, this token can be used for private broadcasts - - :return: The access_private_broadcasts of this RepositoryTokenRequest. - :rtype: bool - """ - return self._access_private_broadcasts - - @access_private_broadcasts.setter - def access_private_broadcasts(self, access_private_broadcasts): - """Sets the access_private_broadcasts of this RepositoryTokenRequest. - - If enabled, this token can be used for private broadcasts - - :param access_private_broadcasts: The access_private_broadcasts of this RepositoryTokenRequest. - :type: bool - """ - - self._access_private_broadcasts = access_private_broadcasts - @property def eula_required(self): """Gets the eula_required of this RepositoryTokenRequest. diff --git a/bindings/python/src/cloudsmith_api/models/repository_token_request_patch.py b/bindings/python/src/cloudsmith_api/models/repository_token_request_patch.py index 2be47229..7f97e32d 100644 --- a/bindings/python/src/cloudsmith_api/models/repository_token_request_patch.py +++ b/bindings/python/src/cloudsmith_api/models/repository_token_request_patch.py @@ -33,7 +33,6 @@ class RepositoryTokenRequestPatch(object): and the value is json key in definition. """ swagger_types = { - 'access_private_broadcasts': 'bool', 'eula_required': 'bool', 'is_active': 'bool', 'limit_bandwidth': 'int', @@ -52,7 +51,6 @@ class RepositoryTokenRequestPatch(object): } attribute_map = { - 'access_private_broadcasts': 'access_private_broadcasts', 'eula_required': 'eula_required', 'is_active': 'is_active', 'limit_bandwidth': 'limit_bandwidth', @@ -70,13 +68,12 @@ class RepositoryTokenRequestPatch(object): 'token': 'token' } - def __init__(self, access_private_broadcasts=None, eula_required=None, is_active=None, limit_bandwidth=None, limit_bandwidth_unit='Byte', limit_date_range_from=None, limit_date_range_to=None, limit_num_clients=None, limit_num_downloads=None, limit_package_query=None, limit_path_query=None, metadata=None, name=None, scheduled_reset_at=None, scheduled_reset_period='Never Reset', token=None, _configuration=None): # noqa: E501 + def __init__(self, eula_required=None, is_active=None, limit_bandwidth=None, limit_bandwidth_unit='Byte', limit_date_range_from=None, limit_date_range_to=None, limit_num_clients=None, limit_num_downloads=None, limit_package_query=None, limit_path_query=None, metadata=None, name=None, scheduled_reset_at=None, scheduled_reset_period='Never Reset', token=None, _configuration=None): # noqa: E501 """RepositoryTokenRequestPatch - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() self._configuration = _configuration - self._access_private_broadcasts = None self._eula_required = None self._is_active = None self._limit_bandwidth = None @@ -94,8 +91,6 @@ def __init__(self, access_private_broadcasts=None, eula_required=None, is_active self._token = None self.discriminator = None - if access_private_broadcasts is not None: - self.access_private_broadcasts = access_private_broadcasts if eula_required is not None: self.eula_required = eula_required if is_active is not None: @@ -127,29 +122,6 @@ def __init__(self, access_private_broadcasts=None, eula_required=None, is_active if token is not None: self.token = token - @property - def access_private_broadcasts(self): - """Gets the access_private_broadcasts of this RepositoryTokenRequestPatch. - - If enabled, this token can be used for private broadcasts - - :return: The access_private_broadcasts of this RepositoryTokenRequestPatch. - :rtype: bool - """ - return self._access_private_broadcasts - - @access_private_broadcasts.setter - def access_private_broadcasts(self, access_private_broadcasts): - """Sets the access_private_broadcasts of this RepositoryTokenRequestPatch. - - If enabled, this token can be used for private broadcasts - - :param access_private_broadcasts: The access_private_broadcasts of this RepositoryTokenRequestPatch. - :type: bool - """ - - self._access_private_broadcasts = access_private_broadcasts - @property def eula_required(self): """Gets the eula_required of this RepositoryTokenRequestPatch. diff --git a/bindings/python/src/cloudsmith_api/models/rpm_upstream.py b/bindings/python/src/cloudsmith_api/models/rpm_upstream.py index c4ca5859..63464287 100644 --- a/bindings/python/src/cloudsmith_api/models/rpm_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/rpm_upstream.py @@ -373,7 +373,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this RpmUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/ruby_upstream.py b/bindings/python/src/cloudsmith_api/models/ruby_upstream.py index ff68cd46..8d22f047 100644 --- a/bindings/python/src/cloudsmith_api/models/ruby_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/ruby_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this RubyUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/cloudsmith_api/models/storage_allocated_limit.py b/bindings/python/src/cloudsmith_api/models/storage_allocated_limit.py index aee08bfe..7477dc99 100644 --- a/bindings/python/src/cloudsmith_api/models/storage_allocated_limit.py +++ b/bindings/python/src/cloudsmith_api/models/storage_allocated_limit.py @@ -37,7 +37,8 @@ class StorageAllocatedLimit(object): 'peak': 'str', 'percentage_used': 'str', 'plan_limit': 'str', - 'used': 'str' + 'used': 'str', + 'used_pre_deduplication': 'str' } attribute_map = { @@ -45,10 +46,11 @@ class StorageAllocatedLimit(object): 'peak': 'peak', 'percentage_used': 'percentage_used', 'plan_limit': 'plan_limit', - 'used': 'used' + 'used': 'used', + 'used_pre_deduplication': 'used_pre_deduplication' } - def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit=None, used=None, _configuration=None): # noqa: E501 + def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit=None, used=None, used_pre_deduplication=None, _configuration=None): # noqa: E501 """StorageAllocatedLimit - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() @@ -59,6 +61,7 @@ def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit= self._percentage_used = None self._plan_limit = None self._used = None + self._used_pre_deduplication = None self.discriminator = None if configured is not None: @@ -71,6 +74,8 @@ def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit= self.plan_limit = plan_limit if used is not None: self.used = used + if used_pre_deduplication is not None: + self.used_pre_deduplication = used_pre_deduplication @property def configured(self): @@ -207,6 +212,33 @@ def used(self, used): self._used = used + @property + def used_pre_deduplication(self): + """Gets the used_pre_deduplication of this StorageAllocatedLimit. + + + :return: The used_pre_deduplication of this StorageAllocatedLimit. + :rtype: str + """ + return self._used_pre_deduplication + + @used_pre_deduplication.setter + def used_pre_deduplication(self, used_pre_deduplication): + """Sets the used_pre_deduplication of this StorageAllocatedLimit. + + + :param used_pre_deduplication: The used_pre_deduplication of this StorageAllocatedLimit. + :type: str + """ + if (self._configuration.client_side_validation and + used_pre_deduplication is not None and len(used_pre_deduplication) > 32): + raise ValueError("Invalid value for `used_pre_deduplication`, length must be less than or equal to `32`") # noqa: E501 + if (self._configuration.client_side_validation and + used_pre_deduplication is not None and len(used_pre_deduplication) < 1): + raise ValueError("Invalid value for `used_pre_deduplication`, length must be greater than or equal to `1`") # noqa: E501 + + self._used_pre_deduplication = used_pre_deduplication + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/bindings/python/src/cloudsmith_api/models/storage_allocated_limit_raw.py b/bindings/python/src/cloudsmith_api/models/storage_allocated_limit_raw.py index 6b20a992..fcb7a14a 100644 --- a/bindings/python/src/cloudsmith_api/models/storage_allocated_limit_raw.py +++ b/bindings/python/src/cloudsmith_api/models/storage_allocated_limit_raw.py @@ -37,7 +37,8 @@ class StorageAllocatedLimitRaw(object): 'peak': 'int', 'percentage_used': 'str', 'plan_limit': 'int', - 'used': 'int' + 'used': 'int', + 'used_pre_deduplication': 'int' } attribute_map = { @@ -45,10 +46,11 @@ class StorageAllocatedLimitRaw(object): 'peak': 'peak', 'percentage_used': 'percentage_used', 'plan_limit': 'plan_limit', - 'used': 'used' + 'used': 'used', + 'used_pre_deduplication': 'used_pre_deduplication' } - def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit=None, used=None, _configuration=None): # noqa: E501 + def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit=None, used=None, used_pre_deduplication=None, _configuration=None): # noqa: E501 """StorageAllocatedLimitRaw - a model defined in Swagger""" # noqa: E501 if _configuration is None: _configuration = Configuration() @@ -59,6 +61,7 @@ def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit= self._percentage_used = None self._plan_limit = None self._used = None + self._used_pre_deduplication = None self.discriminator = None if configured is not None: @@ -71,6 +74,8 @@ def __init__(self, configured=None, peak=None, percentage_used=None, plan_limit= self.plan_limit = plan_limit if used is not None: self.used = used + if used_pre_deduplication is not None: + self.used_pre_deduplication = used_pre_deduplication @property def configured(self): @@ -177,6 +182,27 @@ def used(self, used): self._used = used + @property + def used_pre_deduplication(self): + """Gets the used_pre_deduplication of this StorageAllocatedLimitRaw. + + + :return: The used_pre_deduplication of this StorageAllocatedLimitRaw. + :rtype: int + """ + return self._used_pre_deduplication + + @used_pre_deduplication.setter + def used_pre_deduplication(self, used_pre_deduplication): + """Sets the used_pre_deduplication of this StorageAllocatedLimitRaw. + + + :param used_pre_deduplication: The used_pre_deduplication of this StorageAllocatedLimitRaw. + :type: int + """ + + self._used_pre_deduplication = used_pre_deduplication + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/bindings/python/src/cloudsmith_api/models/swift_upstream.py b/bindings/python/src/cloudsmith_api/models/swift_upstream.py index 629907fe..78438d45 100644 --- a/bindings/python/src/cloudsmith_api/models/swift_upstream.py +++ b/bindings/python/src/cloudsmith_api/models/swift_upstream.py @@ -339,7 +339,7 @@ def disable_reason(self, disable_reason): :param disable_reason: The disable_reason of this SwiftUpstream. :type: str """ - allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"] # noqa: E501 + allowed_values = ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"] # noqa: E501 if (self._configuration.client_side_validation and disable_reason not in allowed_values): raise ValueError( diff --git a/bindings/python/src/docs/AlpineUpstream.md b/bindings/python/src/docs/AlpineUpstream.md index 447c9f86..772bd8d1 100644 --- a/bindings/python/src/docs/AlpineUpstream.md +++ b/bindings/python/src/docs/AlpineUpstream.md @@ -24,6 +24,10 @@ Name | Type | Description | Notes **name** | **str** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | **pending_validation** | **bool** | When true, this upstream source is pending validation. | [optional] **priority** | **int** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsa_key_inline** | **str** | A base64-encoded RSA public key in PEM format used to verify package signatures. | [optional] +**rsa_key_url** | **str** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsa_verification** | **str** | The RSA signature verification mode for this upstream. | [optional] [default to 'Allow All'] +**rsa_verification_status** | **str** | The RSA signature verification status for this upstream. | [optional] [default to 'Unknown'] **slug_perm** | **str** | | [optional] **updated_at** | **datetime** | | [optional] **upstream_url** | **str** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | diff --git a/bindings/python/src/docs/AlpineUpstreamRequest.md b/bindings/python/src/docs/AlpineUpstreamRequest.md index 27ed41c7..e59efaa9 100644 --- a/bindings/python/src/docs/AlpineUpstreamRequest.md +++ b/bindings/python/src/docs/AlpineUpstreamRequest.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **mode** | **str** | The mode that this upstream should operate in. Upstream sources can be used to proxy resolved packages, as well as operate in a proxy/cache or cache only mode. | [optional] [default to 'Proxy Only'] **name** | **str** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | **priority** | **int** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsa_key_url** | **str** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsa_verification** | **str** | The RSA signature verification mode for this upstream. | [optional] [default to 'Allow All'] **upstream_url** | **str** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | **verify_ssl** | **bool** | If enabled, SSL certificates are verified when requests are made to this upstream. It's recommended to leave this enabled for all public sources to help mitigate Man-In-The-Middle (MITM) attacks. Please note this only applies to HTTPS upstreams. | [optional] diff --git a/bindings/python/src/docs/AlpineUpstreamRequestPatch.md b/bindings/python/src/docs/AlpineUpstreamRequestPatch.md index b78a9652..6e480389 100644 --- a/bindings/python/src/docs/AlpineUpstreamRequestPatch.md +++ b/bindings/python/src/docs/AlpineUpstreamRequestPatch.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **mode** | **str** | The mode that this upstream should operate in. Upstream sources can be used to proxy resolved packages, as well as operate in a proxy/cache or cache only mode. | [optional] [default to 'Proxy Only'] **name** | **str** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | [optional] **priority** | **int** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsa_key_url** | **str** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsa_verification** | **str** | The RSA signature verification mode for this upstream. | [optional] [default to 'Allow All'] **upstream_url** | **str** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | [optional] **verify_ssl** | **bool** | If enabled, SSL certificates are verified when requests are made to this upstream. It's recommended to leave this enabled for all public sources to help mitigate Man-In-The-Middle (MITM) attacks. Please note this only applies to HTTPS upstreams. | [optional] diff --git a/bindings/python/src/docs/EntitlementsApi.md b/bindings/python/src/docs/EntitlementsApi.md index dc89bcfa..4779c66d 100644 --- a/bindings/python/src/docs/EntitlementsApi.md +++ b/bindings/python/src/docs/EntitlementsApi.md @@ -14,6 +14,7 @@ Method | HTTP request | Description [**entitlements_refresh**](EntitlementsApi.md#entitlements_refresh) | **POST** /entitlements/{owner}/{repo}/{identifier}/refresh/ | Refresh an entitlement token in a repository. [**entitlements_reset**](EntitlementsApi.md#entitlements_reset) | **POST** /entitlements/{owner}/{repo}/{identifier}/reset/ | Reset the statistics for an entitlement token in a repository. [**entitlements_sync**](EntitlementsApi.md#entitlements_sync) | **POST** /entitlements/{owner}/{repo}/sync/ | Synchronise tokens from a source repository. +[**entitlements_toggle_private_broadcasts**](EntitlementsApi.md#entitlements_toggle_private_broadcasts) | **POST** /entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/ | Set private broadcast access for an entitlement token in a repository. # **entitlements_create** @@ -660,3 +661,66 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **entitlements_toggle_private_broadcasts** +> entitlements_toggle_private_broadcasts(owner, repo, identifier, data=data) + +Set private broadcast access for an entitlement token in a repository. + +Set private broadcast access for an entitlement token in a repository. + +### Example +```python +from __future__ import print_function +import time +import cloudsmith_api +from cloudsmith_api.rest import ApiException +from pprint import pprint + +# Configure API key authorization: apikey +configuration = cloudsmith_api.Configuration() +configuration.api_key['X-Api-Key'] = 'YOUR_API_KEY' +# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed +# configuration.api_key_prefix['X-Api-Key'] = 'Bearer' +# Configure HTTP basic authorization: basic +configuration = cloudsmith_api.Configuration() +configuration.username = 'YOUR_USERNAME' +configuration.password = 'YOUR_PASSWORD' + +# create an instance of the API class +api_instance = cloudsmith_api.EntitlementsApi(cloudsmith_api.ApiClient(configuration)) +owner = 'owner_example' # str | +repo = 'repo_example' # str | +identifier = 'identifier_example' # str | +data = cloudsmith_api.RepositoryTokenPrivateBroadcastsRequest() # RepositoryTokenPrivateBroadcastsRequest | (optional) + +try: + # Set private broadcast access for an entitlement token in a repository. + api_instance.entitlements_toggle_private_broadcasts(owner, repo, identifier, data=data) +except ApiException as e: + print("Exception when calling EntitlementsApi->entitlements_toggle_private_broadcasts: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **str**| | + **repo** | **str**| | + **identifier** | **str**| | + **data** | [**RepositoryTokenPrivateBroadcastsRequest**](RepositoryTokenPrivateBroadcastsRequest.md)| | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/bindings/python/src/docs/McpPackageUpload.md b/bindings/python/src/docs/McpPackageUpload.md new file mode 100644 index 00000000..3b185577 --- /dev/null +++ b/bindings/python/src/docs/McpPackageUpload.md @@ -0,0 +1,93 @@ +# McpPackageUpload + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**architectures** | [**list[Architecture]**](Architecture.md) | | [optional] +**cdn_url** | **str** | | [optional] +**checksum_md5** | **str** | | [optional] +**checksum_sha1** | **str** | | [optional] +**checksum_sha256** | **str** | | [optional] +**checksum_sha512** | **str** | | [optional] +**dependencies_checksum_md5** | **str** | A checksum of all of the package's dependencies. | [optional] +**dependencies_url** | **str** | | [optional] +**description** | **str** | A textual description of this package. | [optional] +**display_name** | **str** | | [optional] +**distro** | [**Distribution**](Distribution.md) | | [optional] +**distro_version** | [**DistributionVersion**](DistributionVersion.md) | | [optional] +**downloads** | **int** | | [optional] +**epoch** | **int** | The epoch of the package version (if any). | [optional] +**extension** | **str** | | [optional] +**filename** | **str** | | [optional] +**files** | [**list[PackageFile]**](PackageFile.md) | | [optional] +**format** | **str** | | [optional] +**format_url** | **str** | | [optional] +**freeable_storage** | **int** | Amount of storage that will be freed if this package is deleted | [optional] +**fully_qualified_name** | **str** | | [optional] +**identifier_perm** | **str** | Unique and permanent identifier for the package. | [optional] +**identifiers** | **dict(str, str)** | Return a map of identifier field names and their values. | [optional] +**indexed** | **bool** | | [optional] +**is_cancellable** | **bool** | | [optional] +**is_copyable** | **bool** | | [optional] +**is_deleteable** | **bool** | | [optional] +**is_downloadable** | **bool** | | [optional] +**is_moveable** | **bool** | | [optional] +**is_quarantinable** | **bool** | | [optional] +**is_quarantined** | **bool** | | [optional] +**is_resyncable** | **bool** | | [optional] +**is_security_scannable** | **bool** | | [optional] +**is_sync_awaiting** | **bool** | | [optional] +**is_sync_completed** | **bool** | | [optional] +**is_sync_failed** | **bool** | | [optional] +**is_sync_in_flight** | **bool** | | [optional] +**is_sync_in_progress** | **bool** | | [optional] +**license** | **str** | The license of this package. | [optional] +**name** | **str** | The name of this package. | [optional] +**namespace** | **str** | | [optional] +**namespace_url** | **str** | | [optional] +**num_files** | **int** | | [optional] +**origin_repository** | **str** | | [optional] +**origin_repository_url** | **str** | | [optional] +**package_type** | **int** | The type of package contents. | [optional] +**policy_violated** | **bool** | Whether or not the package has violated any policy. | [optional] +**raw_license** | **str** | The raw license string. | [optional] +**release** | **str** | The release of the package version (if any). | [optional] +**repository** | **str** | | [optional] +**repository_url** | **str** | | [optional] +**security_scan_completed_at** | **datetime** | The datetime the security scanning was completed. | [optional] +**security_scan_started_at** | **datetime** | The datetime the security scanning was started. | [optional] +**security_scan_status** | **str** | | [optional] [default to 'Awaiting Security Scan'] +**security_scan_status_updated_at** | **datetime** | The datetime the security scanning status was updated. | [optional] +**self_html_url** | **str** | | [optional] +**self_url** | **str** | | [optional] +**self_webapp_url** | **str** | | [optional] +**signature_url** | **str** | | [optional] +**size** | **int** | The calculated size of the package. | [optional] +**slug** | **str** | The public unique identifier for the package. | [optional] +**slug_perm** | **str** | | [optional] +**spdx_license** | **str** | The SPDX license identifier for this package. | [optional] +**stage** | **int** | The synchronisation (in progress) stage of the package. | [optional] +**stage_str** | **str** | | [optional] +**stage_updated_at** | **datetime** | The datetime the package stage was updated at. | [optional] +**status** | **int** | The synchronisation status of the package. | [optional] +**status_reason** | **str** | A textual description for the synchronous status reason (if any | [optional] +**status_str** | **str** | | [optional] +**status_updated_at** | **datetime** | The datetime the package status was updated at. | [optional] +**status_url** | **str** | | [optional] +**subtype** | **str** | | [optional] +**summary** | **str** | A one-liner synopsis of this package. | [optional] +**sync_finished_at** | **datetime** | The datetime the package sync was finished at. | [optional] +**sync_progress** | **int** | Synchronisation progress (from 0-100) | [optional] +**tags_automatic** | [**Tags**](Tags.md) | | [optional] +**tags_immutable** | [**Tags**](Tags.md) | | [optional] +**type_display** | **str** | | [optional] +**uploaded_at** | **datetime** | The date this package was uploaded. | [optional] +**uploader** | **str** | | [optional] +**uploader_url** | **str** | | [optional] +**version** | **str** | The raw version for this package. | [optional] +**version_orig** | **str** | | [optional] +**vulnerability_scan_results_url** | **str** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/bindings/python/src/docs/McpPackageUploadRequest.md b/bindings/python/src/docs/McpPackageUploadRequest.md new file mode 100644 index 00000000..a88c529d --- /dev/null +++ b/bindings/python/src/docs/McpPackageUploadRequest.md @@ -0,0 +1,13 @@ +# McpPackageUploadRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**package_file** | **str** | The primary file for the package. | +**republish** | **bool** | If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. | [optional] +**tags** | **str** | A comma-separated values list of tags to add to the package. | [optional] +**version** | **str** | The raw version for this package. | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/bindings/python/src/docs/PackageRecycleBin.md b/bindings/python/src/docs/PackageRecycleBin.md new file mode 100644 index 00000000..daa1f847 --- /dev/null +++ b/bindings/python/src/docs/PackageRecycleBin.md @@ -0,0 +1,12 @@ +# PackageRecycleBin + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action** | **str** | The action to perform on soft-deleted packages. | +**identifiers** | **list[str]** | A list of soft-deleted package identifiers to action. | +**repository** | **str** | The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/bindings/python/src/docs/PackagesApi.md b/bindings/python/src/docs/PackagesApi.md index 12b459e4..7edb6bf4 100644 --- a/bindings/python/src/docs/PackagesApi.md +++ b/bindings/python/src/docs/PackagesApi.md @@ -34,6 +34,7 @@ Method | HTTP request | Description [**packages_upload_huggingface**](PackagesApi.md#packages_upload_huggingface) | **POST** /packages/{owner}/{repo}/upload/huggingface/ | Create a new HuggingFace package [**packages_upload_luarocks**](PackagesApi.md#packages_upload_luarocks) | **POST** /packages/{owner}/{repo}/upload/luarocks/ | Create a new LuaRocks package [**packages_upload_maven**](PackagesApi.md#packages_upload_maven) | **POST** /packages/{owner}/{repo}/upload/maven/ | Create a new Maven package +[**packages_upload_mcp**](PackagesApi.md#packages_upload_mcp) | **POST** /packages/{owner}/{repo}/upload/mcp/ | Create a new MCP package [**packages_upload_npm**](PackagesApi.md#packages_upload_npm) | **POST** /packages/{owner}/{repo}/upload/npm/ | Create a new npm package [**packages_upload_nuget**](PackagesApi.md#packages_upload_nuget) | **POST** /packages/{owner}/{repo}/upload/nuget/ | Create a new NuGet package [**packages_upload_p2**](PackagesApi.md#packages_upload_p2) | **POST** /packages/{owner}/{repo}/upload/p2/ | Create a new P2 package @@ -62,6 +63,7 @@ Method | HTTP request | Description [**packages_validate_upload_huggingface**](PackagesApi.md#packages_validate_upload_huggingface) | **POST** /packages/{owner}/{repo}/validate-upload/huggingface/ | Validate parameters for create HuggingFace package [**packages_validate_upload_luarocks**](PackagesApi.md#packages_validate_upload_luarocks) | **POST** /packages/{owner}/{repo}/validate-upload/luarocks/ | Validate parameters for create LuaRocks package [**packages_validate_upload_maven**](PackagesApi.md#packages_validate_upload_maven) | **POST** /packages/{owner}/{repo}/validate-upload/maven/ | Validate parameters for create Maven package +[**packages_validate_upload_mcp**](PackagesApi.md#packages_validate_upload_mcp) | **POST** /packages/{owner}/{repo}/validate-upload/mcp/ | Validate parameters for create MCP package [**packages_validate_upload_npm**](PackagesApi.md#packages_validate_upload_npm) | **POST** /packages/{owner}/{repo}/validate-upload/npm/ | Validate parameters for create npm package [**packages_validate_upload_nuget**](PackagesApi.md#packages_validate_upload_nuget) | **POST** /packages/{owner}/{repo}/validate-upload/nuget/ | Validate parameters for create NuGet package [**packages_validate_upload_p2**](PackagesApi.md#packages_validate_upload_p2) | **POST** /packages/{owner}/{repo}/validate-upload/p2/ | Validate parameters for create P2 package @@ -1960,6 +1962,68 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **packages_upload_mcp** +> McpPackageUpload packages_upload_mcp(owner, repo, data=data) + +Create a new MCP package + +Create a new MCP package + +### Example +```python +from __future__ import print_function +import time +import cloudsmith_api +from cloudsmith_api.rest import ApiException +from pprint import pprint + +# Configure API key authorization: apikey +configuration = cloudsmith_api.Configuration() +configuration.api_key['X-Api-Key'] = 'YOUR_API_KEY' +# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed +# configuration.api_key_prefix['X-Api-Key'] = 'Bearer' +# Configure HTTP basic authorization: basic +configuration = cloudsmith_api.Configuration() +configuration.username = 'YOUR_USERNAME' +configuration.password = 'YOUR_PASSWORD' + +# create an instance of the API class +api_instance = cloudsmith_api.PackagesApi(cloudsmith_api.ApiClient(configuration)) +owner = 'owner_example' # str | +repo = 'repo_example' # str | +data = cloudsmith_api.McpPackageUploadRequest() # McpPackageUploadRequest | (optional) + +try: + # Create a new MCP package + api_response = api_instance.packages_upload_mcp(owner, repo, data=data) + pprint(api_response) +except ApiException as e: + print("Exception when calling PackagesApi->packages_upload_mcp: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **str**| | + **repo** | **str**| | + **data** | [**McpPackageUploadRequest**](McpPackageUploadRequest.md)| | [optional] + +### Return type + +[**McpPackageUpload**](McpPackageUpload.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **packages_upload_npm** > NpmPackageUpload packages_upload_npm(owner, repo, data=data) @@ -3679,6 +3743,67 @@ void (empty response body) [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **packages_validate_upload_mcp** +> packages_validate_upload_mcp(owner, repo, data=data) + +Validate parameters for create MCP package + +Validate parameters for create MCP package + +### Example +```python +from __future__ import print_function +import time +import cloudsmith_api +from cloudsmith_api.rest import ApiException +from pprint import pprint + +# Configure API key authorization: apikey +configuration = cloudsmith_api.Configuration() +configuration.api_key['X-Api-Key'] = 'YOUR_API_KEY' +# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed +# configuration.api_key_prefix['X-Api-Key'] = 'Bearer' +# Configure HTTP basic authorization: basic +configuration = cloudsmith_api.Configuration() +configuration.username = 'YOUR_USERNAME' +configuration.password = 'YOUR_PASSWORD' + +# create an instance of the API class +api_instance = cloudsmith_api.PackagesApi(cloudsmith_api.ApiClient(configuration)) +owner = 'owner_example' # str | +repo = 'repo_example' # str | +data = cloudsmith_api.McpPackageUploadRequest() # McpPackageUploadRequest | (optional) + +try: + # Validate parameters for create MCP package + api_instance.packages_validate_upload_mcp(owner, repo, data=data) +except ApiException as e: + print("Exception when calling PackagesApi->packages_validate_upload_mcp: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **str**| | + **repo** | **str**| | + **data** | [**McpPackageUploadRequest**](McpPackageUploadRequest.md)| | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **packages_validate_upload_npm** > packages_validate_upload_npm(owner, repo, data=data) diff --git a/bindings/python/src/docs/RecycleBinApi.md b/bindings/python/src/docs/RecycleBinApi.md new file mode 100644 index 00000000..2be20298 --- /dev/null +++ b/bindings/python/src/docs/RecycleBinApi.md @@ -0,0 +1,133 @@ +# cloudsmith_api.RecycleBinApi + +All URIs are relative to *https://api.cloudsmith.io* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**recycle_bin_list**](RecycleBinApi.md#recycle_bin_list) | **GET** /recycle-bin/{owner}/ | List soft-deleted packages in recycle bin +[**recycle_bin_recycle_bin_action**](RecycleBinApi.md#recycle_bin_recycle_bin_action) | **POST** /recycle-bin/{owner}/action/ | + + +# **recycle_bin_list** +> list[RecycleBinPackage] recycle_bin_list(owner, page=page, page_size=page_size, repository=repository) + +List soft-deleted packages in recycle bin + +Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + +### Example +```python +from __future__ import print_function +import time +import cloudsmith_api +from cloudsmith_api.rest import ApiException +from pprint import pprint + +# Configure API key authorization: apikey +configuration = cloudsmith_api.Configuration() +configuration.api_key['X-Api-Key'] = 'YOUR_API_KEY' +# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed +# configuration.api_key_prefix['X-Api-Key'] = 'Bearer' +# Configure HTTP basic authorization: basic +configuration = cloudsmith_api.Configuration() +configuration.username = 'YOUR_USERNAME' +configuration.password = 'YOUR_PASSWORD' + +# create an instance of the API class +api_instance = cloudsmith_api.RecycleBinApi(cloudsmith_api.ApiClient(configuration)) +owner = 'owner_example' # str | +page = 56 # int | A page number within the paginated result set. (optional) +page_size = 56 # int | Number of results to return per page. (optional) +repository = 'repository_example' # str | Filter packages by repository slug (optional) + +try: + # List soft-deleted packages in recycle bin + api_response = api_instance.recycle_bin_list(owner, page=page, page_size=page_size, repository=repository) + pprint(api_response) +except ApiException as e: + print("Exception when calling RecycleBinApi->recycle_bin_list: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **str**| | + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **repository** | **str**| Filter packages by repository slug | [optional] + +### Return type + +[**list[RecycleBinPackage]**](RecycleBinPackage.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **recycle_bin_recycle_bin_action** +> PackageBulkActionResponse recycle_bin_recycle_bin_action(owner, data=data) + + + +Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + +### Example +```python +from __future__ import print_function +import time +import cloudsmith_api +from cloudsmith_api.rest import ApiException +from pprint import pprint + +# Configure API key authorization: apikey +configuration = cloudsmith_api.Configuration() +configuration.api_key['X-Api-Key'] = 'YOUR_API_KEY' +# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed +# configuration.api_key_prefix['X-Api-Key'] = 'Bearer' +# Configure HTTP basic authorization: basic +configuration = cloudsmith_api.Configuration() +configuration.username = 'YOUR_USERNAME' +configuration.password = 'YOUR_PASSWORD' + +# create an instance of the API class +api_instance = cloudsmith_api.RecycleBinApi(cloudsmith_api.ApiClient(configuration)) +owner = 'owner_example' # str | +data = cloudsmith_api.PackageRecycleBin() # PackageRecycleBin | (optional) + +try: + api_response = api_instance.recycle_bin_recycle_bin_action(owner, data=data) + pprint(api_response) +except ApiException as e: + print("Exception when calling RecycleBinApi->recycle_bin_recycle_bin_action: %s\n" % e) +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **str**| | + **data** | [**PackageRecycleBin**](PackageRecycleBin.md)| | [optional] + +### Return type + +[**PackageBulkActionResponse**](PackageBulkActionResponse.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/bindings/python/src/docs/RecycleBinPackage.md b/bindings/python/src/docs/RecycleBinPackage.md new file mode 100644 index 00000000..d3a931ae --- /dev/null +++ b/bindings/python/src/docs/RecycleBinPackage.md @@ -0,0 +1,33 @@ +# RecycleBinPackage + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action_by** | **str** | The name of the user who deleted the package. | [optional] +**downloads** | **int** | | [optional] +**filename** | **str** | | [optional] +**format** | **str** | | [optional] +**fully_qualified_name** | **str** | The fully qualified name of the package. | [optional] +**identifiers** | **dict(str, str)** | | [optional] +**invoked_retention_rule** | **dict(str, str)** | Information about the retention rule that triggered deletion (if any). | [optional] +**is_deleteable** | **bool** | | [optional] +**is_quarantined** | **bool** | | [optional] +**is_restorable** | **bool** | | [optional] +**name** | **str** | The name of this package. | [optional] +**policy_violated** | **bool** | Whether or not the package has violated any policy. | [optional] +**repository** | **str** | | [optional] +**security_scan_completed_at** | **datetime** | The datetime the security scanning was completed. | [optional] +**security_scan_status** | **str** | | [optional] [default to 'Awaiting Security Scan'] +**size** | **int** | The calculated size of the package. | [optional] +**slug_perm** | **str** | | [optional] +**status** | **int** | The synchronisation status of the package. | [optional] +**status_updated_at** | **datetime** | The datetime the package status was updated at. | [optional] +**tags** | [**Tags**](Tags.md) | | [optional] +**type_display** | **str** | | [optional] +**uploaded_at** | **datetime** | The date this package was uploaded. | [optional] +**uploader** | **str** | | [optional] +**version** | **str** | The raw version for this package. | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/bindings/python/src/docs/ReposApi.md b/bindings/python/src/docs/ReposApi.md index 3d4d08d3..4a27f4bf 100644 --- a/bindings/python/src/docs/ReposApi.md +++ b/bindings/python/src/docs/ReposApi.md @@ -8,7 +8,7 @@ Method | HTTP request | Description [**repo_retention_partial_update**](ReposApi.md#repo_retention_partial_update) | **PATCH** /repos/{owner}/{repo}/retention/ | Update the retention rules for the repository. [**repo_retention_read**](ReposApi.md#repo_retention_read) | **GET** /repos/{owner}/{repo}/retention/ | Retrieve the retention rules for the repository. [**repos_create**](ReposApi.md#repos_create) | **POST** /repos/{owner}/ | Create a new repository in a given namespace. -[**repos_delete**](ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | Delete a repository in a given namespace. +[**repos_delete**](ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | [**repos_ecdsa_create**](ReposApi.md#repos_ecdsa_create) | **POST** /repos/{owner}/{identifier}/ecdsa/ | Set the active ECDSA key for the Repository. [**repos_ecdsa_list**](ReposApi.md#repos_ecdsa_list) | **GET** /repos/{owner}/{identifier}/ecdsa/ | Retrieve the active ECDSA key for the Repository. [**repos_ecdsa_regenerate**](ReposApi.md#repos_ecdsa_regenerate) | **POST** /repos/{owner}/{identifier}/ecdsa/regenerate/ | Regenerate ECDSA Key for the Repository. @@ -401,9 +401,9 @@ Name | Type | Description | Notes # **repos_delete** > repos_delete(owner, identifier) -Delete a repository in a given namespace. -Delete a repository in a given namespace. + +Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. ### Example ```python @@ -429,7 +429,6 @@ owner = 'owner_example' # str | identifier = 'identifier_example' # str | try: - # Delete a repository in a given namespace. api_instance.repos_delete(owner, identifier) except ApiException as e: print("Exception when calling ReposApi->repos_delete: %s\n" % e) diff --git a/bindings/python/src/docs/RepositoryTokenPrivateBroadcasts.md b/bindings/python/src/docs/RepositoryTokenPrivateBroadcasts.md new file mode 100644 index 00000000..839036b0 --- /dev/null +++ b/bindings/python/src/docs/RepositoryTokenPrivateBroadcasts.md @@ -0,0 +1,10 @@ +# RepositoryTokenPrivateBroadcasts + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**access_private_broadcasts** | **bool** | Whether the token should have access to private broadcasts. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/bindings/python/src/docs/RepositoryTokenPrivateBroadcastsRequest.md b/bindings/python/src/docs/RepositoryTokenPrivateBroadcastsRequest.md new file mode 100644 index 00000000..652e05df --- /dev/null +++ b/bindings/python/src/docs/RepositoryTokenPrivateBroadcastsRequest.md @@ -0,0 +1,10 @@ +# RepositoryTokenPrivateBroadcastsRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**access_private_broadcasts** | **bool** | Whether the token should have access to private broadcasts. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/bindings/python/src/docs/RepositoryTokenRefreshRequest.md b/bindings/python/src/docs/RepositoryTokenRefreshRequest.md index af47d4e9..bbd581c5 100644 --- a/bindings/python/src/docs/RepositoryTokenRefreshRequest.md +++ b/bindings/python/src/docs/RepositoryTokenRefreshRequest.md @@ -3,7 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**access_private_broadcasts** | **bool** | If enabled, this token can be used for private broadcasts | [optional] **eula_required** | **bool** | If checked, a EULA acceptance is required for this token. | [optional] **is_active** | **bool** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limit_bandwidth** | **int** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/python/src/docs/RepositoryTokenRequest.md b/bindings/python/src/docs/RepositoryTokenRequest.md index 5383cb46..3af1d577 100644 --- a/bindings/python/src/docs/RepositoryTokenRequest.md +++ b/bindings/python/src/docs/RepositoryTokenRequest.md @@ -3,7 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**access_private_broadcasts** | **bool** | If enabled, this token can be used for private broadcasts | [optional] **eula_required** | **bool** | If checked, a EULA acceptance is required for this token. | [optional] **is_active** | **bool** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limit_bandwidth** | **int** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/python/src/docs/RepositoryTokenRequestPatch.md b/bindings/python/src/docs/RepositoryTokenRequestPatch.md index 345cc5ae..f5dcbefa 100644 --- a/bindings/python/src/docs/RepositoryTokenRequestPatch.md +++ b/bindings/python/src/docs/RepositoryTokenRequestPatch.md @@ -3,7 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**access_private_broadcasts** | **bool** | If enabled, this token can be used for private broadcasts | [optional] **eula_required** | **bool** | If checked, a EULA acceptance is required for this token. | [optional] **is_active** | **bool** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limit_bandwidth** | **int** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/python/src/docs/StorageAllocatedLimit.md b/bindings/python/src/docs/StorageAllocatedLimit.md index e01b4028..c3f75050 100644 --- a/bindings/python/src/docs/StorageAllocatedLimit.md +++ b/bindings/python/src/docs/StorageAllocatedLimit.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes **percentage_used** | **str** | | [optional] **plan_limit** | **str** | | [optional] **used** | **str** | | [optional] +**used_pre_deduplication** | **str** | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/bindings/python/src/docs/StorageAllocatedLimitRaw.md b/bindings/python/src/docs/StorageAllocatedLimitRaw.md index eceaddc0..2fb2889b 100644 --- a/bindings/python/src/docs/StorageAllocatedLimitRaw.md +++ b/bindings/python/src/docs/StorageAllocatedLimitRaw.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes **percentage_used** | **str** | | [optional] **plan_limit** | **int** | | [optional] **used** | **int** | | [optional] +**used_pre_deduplication** | **int** | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/bindings/python/src/setup.py b/bindings/python/src/setup.py index e5964b95..dd9dd121 100644 --- a/bindings/python/src/setup.py +++ b/bindings/python/src/setup.py @@ -14,7 +14,7 @@ from setuptools import setup, find_packages # noqa: H301 NAME = "cloudsmith_api" -VERSION = "2.0.25" +VERSION = "2.0.26" # To install the library, run the following # # python setup.py install diff --git a/bindings/python/src/test/test_entitlements_api.py b/bindings/python/src/test/test_entitlements_api.py index c32a0ffd..a424374e 100644 --- a/bindings/python/src/test/test_entitlements_api.py +++ b/bindings/python/src/test/test_entitlements_api.py @@ -99,6 +99,13 @@ def test_entitlements_sync(self): """ pass + def test_entitlements_toggle_private_broadcasts(self): + """Test case for entitlements_toggle_private_broadcasts + + Set private broadcast access for an entitlement token in a repository. # noqa: E501 + """ + pass + if __name__ == '__main__': unittest.main() diff --git a/bindings/python/src/test/test_mcp_package_upload.py b/bindings/python/src/test/test_mcp_package_upload.py new file mode 100644 index 00000000..7c4a41f1 --- /dev/null +++ b/bindings/python/src/test/test_mcp_package_upload.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.models.mcp_package_upload import McpPackageUpload # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestMcpPackageUpload(unittest.TestCase): + """McpPackageUpload unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testMcpPackageUpload(self): + """Test McpPackageUpload""" + # FIXME: construct object with mandatory attributes with example values + # model = cloudsmith_api.models.mcp_package_upload.McpPackageUpload() # noqa: E501 + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/python/src/test/test_mcp_package_upload_request.py b/bindings/python/src/test/test_mcp_package_upload_request.py new file mode 100644 index 00000000..1588831b --- /dev/null +++ b/bindings/python/src/test/test_mcp_package_upload_request.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.models.mcp_package_upload_request import McpPackageUploadRequest # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestMcpPackageUploadRequest(unittest.TestCase): + """McpPackageUploadRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testMcpPackageUploadRequest(self): + """Test McpPackageUploadRequest""" + # FIXME: construct object with mandatory attributes with example values + # model = cloudsmith_api.models.mcp_package_upload_request.McpPackageUploadRequest() # noqa: E501 + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/python/src/test/test_package_recycle_bin.py b/bindings/python/src/test/test_package_recycle_bin.py new file mode 100644 index 00000000..e08684f0 --- /dev/null +++ b/bindings/python/src/test/test_package_recycle_bin.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.models.package_recycle_bin import PackageRecycleBin # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestPackageRecycleBin(unittest.TestCase): + """PackageRecycleBin unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testPackageRecycleBin(self): + """Test PackageRecycleBin""" + # FIXME: construct object with mandatory attributes with example values + # model = cloudsmith_api.models.package_recycle_bin.PackageRecycleBin() # noqa: E501 + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/python/src/test/test_packages_api.py b/bindings/python/src/test/test_packages_api.py index bfca8b4f..2b7a95b5 100644 --- a/bindings/python/src/test/test_packages_api.py +++ b/bindings/python/src/test/test_packages_api.py @@ -239,6 +239,13 @@ def test_packages_upload_maven(self): """ pass + def test_packages_upload_mcp(self): + """Test case for packages_upload_mcp + + Create a new MCP package # noqa: E501 + """ + pass + def test_packages_upload_npm(self): """Test case for packages_upload_npm @@ -435,6 +442,13 @@ def test_packages_validate_upload_maven(self): """ pass + def test_packages_validate_upload_mcp(self): + """Test case for packages_validate_upload_mcp + + Validate parameters for create MCP package # noqa: E501 + """ + pass + def test_packages_validate_upload_npm(self): """Test case for packages_validate_upload_npm diff --git a/bindings/python/src/test/test_recycle_bin_api.py b/bindings/python/src/test/test_recycle_bin_api.py new file mode 100644 index 00000000..b04b19fc --- /dev/null +++ b/bindings/python/src/test/test_recycle_bin_api.py @@ -0,0 +1,47 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.api.recycle_bin_api import RecycleBinApi # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestRecycleBinApi(unittest.TestCase): + """RecycleBinApi unit test stubs""" + + def setUp(self): + self.api = cloudsmith_api.api.recycle_bin_api.RecycleBinApi() # noqa: E501 + + def tearDown(self): + pass + + def test_recycle_bin_list(self): + """Test case for recycle_bin_list + + List soft-deleted packages in recycle bin # noqa: E501 + """ + pass + + def test_recycle_bin_recycle_bin_action(self): + """Test case for recycle_bin_recycle_bin_action + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/python/src/test/test_recycle_bin_package.py b/bindings/python/src/test/test_recycle_bin_package.py new file mode 100644 index 00000000..257c92cd --- /dev/null +++ b/bindings/python/src/test/test_recycle_bin_package.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.models.recycle_bin_package import RecycleBinPackage # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestRecycleBinPackage(unittest.TestCase): + """RecycleBinPackage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRecycleBinPackage(self): + """Test RecycleBinPackage""" + # FIXME: construct object with mandatory attributes with example values + # model = cloudsmith_api.models.recycle_bin_package.RecycleBinPackage() # noqa: E501 + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/python/src/test/test_repos_api.py b/bindings/python/src/test/test_repos_api.py index 6ca0e918..ac2a31a4 100644 --- a/bindings/python/src/test/test_repos_api.py +++ b/bindings/python/src/test/test_repos_api.py @@ -60,7 +60,6 @@ def test_repos_create(self): def test_repos_delete(self): """Test case for repos_delete - Delete a repository in a given namespace. # noqa: E501 """ pass diff --git a/bindings/python/src/test/test_repository_token_private_broadcasts.py b/bindings/python/src/test/test_repository_token_private_broadcasts.py new file mode 100644 index 00000000..5bfb86cc --- /dev/null +++ b/bindings/python/src/test/test_repository_token_private_broadcasts.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.models.repository_token_private_broadcasts import RepositoryTokenPrivateBroadcasts # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestRepositoryTokenPrivateBroadcasts(unittest.TestCase): + """RepositoryTokenPrivateBroadcasts unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRepositoryTokenPrivateBroadcasts(self): + """Test RepositoryTokenPrivateBroadcasts""" + # FIXME: construct object with mandatory attributes with example values + # model = cloudsmith_api.models.repository_token_private_broadcasts.RepositoryTokenPrivateBroadcasts() # noqa: E501 + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/python/src/test/test_repository_token_private_broadcasts_request.py b/bindings/python/src/test/test_repository_token_private_broadcasts_request.py new file mode 100644 index 00000000..60a40ec4 --- /dev/null +++ b/bindings/python/src/test/test_repository_token_private_broadcasts_request.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + Cloudsmith API (v1) + + The API to the Cloudsmith Service # noqa: E501 + + OpenAPI spec version: v1 + Contact: support@cloudsmith.io + Generated by: https://github.com/swagger-api/swagger-codegen.git +""" + + +from __future__ import absolute_import + +import unittest + +import cloudsmith_api +from cloudsmith_api.models.repository_token_private_broadcasts_request import RepositoryTokenPrivateBroadcastsRequest # noqa: E501 +from cloudsmith_api.rest import ApiException + + +class TestRepositoryTokenPrivateBroadcastsRequest(unittest.TestCase): + """RepositoryTokenPrivateBroadcastsRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRepositoryTokenPrivateBroadcastsRequest(self): + """Test RepositoryTokenPrivateBroadcastsRequest""" + # FIXME: construct object with mandatory attributes with example values + # model = cloudsmith_api.models.repository_token_private_broadcasts_request.RepositoryTokenPrivateBroadcastsRequest() # noqa: E501 + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/bindings/ruby/src/README.md b/bindings/ruby/src/README.md index d7f03f49..428a093a 100644 --- a/bindings/ruby/src/README.md +++ b/bindings/ruby/src/README.md @@ -7,7 +7,7 @@ The API to the Cloudsmith Service This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project: - API version: v1 -- Package version: 2.0.25 +- Package version: 2.0.26 - Build package: io.swagger.codegen.languages.RubyClientCodegen For more information, please visit [https://help.cloudsmith.io](https://help.cloudsmith.io) @@ -24,15 +24,15 @@ gem build cloudsmith-api.gemspec Then either install the gem locally: ```shell -gem install ./cloudsmith-api-2.0.25.gem +gem install ./cloudsmith-api-2.0.26.gem ``` -(for development, run `gem install --dev ./cloudsmith-api-2.0.25.gem` to install the development dependencies) +(for development, run `gem install --dev ./cloudsmith-api-2.0.26.gem` to install the development dependencies) or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/). Finally add this to the Gemfile: - gem 'cloudsmith-api', '~> 2.0.25' + gem 'cloudsmith-api', '~> 2.0.26' ### Install from Git @@ -110,6 +110,7 @@ Class | Method | HTTP request | Description *CloudsmithApi::EntitlementsApi* | [**entitlements_refresh**](docs/EntitlementsApi.md#entitlements_refresh) | **POST** /entitlements/{owner}/{repo}/{identifier}/refresh/ | Refresh an entitlement token in a repository. *CloudsmithApi::EntitlementsApi* | [**entitlements_reset**](docs/EntitlementsApi.md#entitlements_reset) | **POST** /entitlements/{owner}/{repo}/{identifier}/reset/ | Reset the statistics for an entitlement token in a repository. *CloudsmithApi::EntitlementsApi* | [**entitlements_sync**](docs/EntitlementsApi.md#entitlements_sync) | **POST** /entitlements/{owner}/{repo}/sync/ | Synchronise tokens from a source repository. +*CloudsmithApi::EntitlementsApi* | [**entitlements_toggle_private_broadcasts**](docs/EntitlementsApi.md#entitlements_toggle_private_broadcasts) | **POST** /entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/ | Set private broadcast access for an entitlement token in a repository. *CloudsmithApi::FilesApi* | [**files_abort**](docs/FilesApi.md#files_abort) | **POST** /files/{owner}/{repo}/{identifier}/abort/ | Abort a multipart file upload. *CloudsmithApi::FilesApi* | [**files_complete**](docs/FilesApi.md#files_complete) | **POST** /files/{owner}/{repo}/{identifier}/complete/ | Complete a multipart file upload. *CloudsmithApi::FilesApi* | [**files_create**](docs/FilesApi.md#files_create) | **POST** /files/{owner}/{repo}/ | Request URL(s) to upload new package file upload(s) to. @@ -225,6 +226,7 @@ Class | Method | HTTP request | Description *CloudsmithApi::PackagesApi* | [**packages_upload_huggingface**](docs/PackagesApi.md#packages_upload_huggingface) | **POST** /packages/{owner}/{repo}/upload/huggingface/ | Create a new HuggingFace package *CloudsmithApi::PackagesApi* | [**packages_upload_luarocks**](docs/PackagesApi.md#packages_upload_luarocks) | **POST** /packages/{owner}/{repo}/upload/luarocks/ | Create a new LuaRocks package *CloudsmithApi::PackagesApi* | [**packages_upload_maven**](docs/PackagesApi.md#packages_upload_maven) | **POST** /packages/{owner}/{repo}/upload/maven/ | Create a new Maven package +*CloudsmithApi::PackagesApi* | [**packages_upload_mcp**](docs/PackagesApi.md#packages_upload_mcp) | **POST** /packages/{owner}/{repo}/upload/mcp/ | Create a new MCP package *CloudsmithApi::PackagesApi* | [**packages_upload_npm**](docs/PackagesApi.md#packages_upload_npm) | **POST** /packages/{owner}/{repo}/upload/npm/ | Create a new npm package *CloudsmithApi::PackagesApi* | [**packages_upload_nuget**](docs/PackagesApi.md#packages_upload_nuget) | **POST** /packages/{owner}/{repo}/upload/nuget/ | Create a new NuGet package *CloudsmithApi::PackagesApi* | [**packages_upload_p2**](docs/PackagesApi.md#packages_upload_p2) | **POST** /packages/{owner}/{repo}/upload/p2/ | Create a new P2 package @@ -253,6 +255,7 @@ Class | Method | HTTP request | Description *CloudsmithApi::PackagesApi* | [**packages_validate_upload_huggingface**](docs/PackagesApi.md#packages_validate_upload_huggingface) | **POST** /packages/{owner}/{repo}/validate-upload/huggingface/ | Validate parameters for create HuggingFace package *CloudsmithApi::PackagesApi* | [**packages_validate_upload_luarocks**](docs/PackagesApi.md#packages_validate_upload_luarocks) | **POST** /packages/{owner}/{repo}/validate-upload/luarocks/ | Validate parameters for create LuaRocks package *CloudsmithApi::PackagesApi* | [**packages_validate_upload_maven**](docs/PackagesApi.md#packages_validate_upload_maven) | **POST** /packages/{owner}/{repo}/validate-upload/maven/ | Validate parameters for create Maven package +*CloudsmithApi::PackagesApi* | [**packages_validate_upload_mcp**](docs/PackagesApi.md#packages_validate_upload_mcp) | **POST** /packages/{owner}/{repo}/validate-upload/mcp/ | Validate parameters for create MCP package *CloudsmithApi::PackagesApi* | [**packages_validate_upload_npm**](docs/PackagesApi.md#packages_validate_upload_npm) | **POST** /packages/{owner}/{repo}/validate-upload/npm/ | Validate parameters for create npm package *CloudsmithApi::PackagesApi* | [**packages_validate_upload_nuget**](docs/PackagesApi.md#packages_validate_upload_nuget) | **POST** /packages/{owner}/{repo}/validate-upload/nuget/ | Validate parameters for create NuGet package *CloudsmithApi::PackagesApi* | [**packages_validate_upload_p2**](docs/PackagesApi.md#packages_validate_upload_p2) | **POST** /packages/{owner}/{repo}/validate-upload/p2/ | Validate parameters for create P2 package @@ -269,11 +272,13 @@ Class | Method | HTTP request | Description *CloudsmithApi::QuotaApi* | [**quota_oss_read**](docs/QuotaApi.md#quota_oss_read) | **GET** /quota/oss/{owner}/ | Open-source Quota usage for a given namespace. *CloudsmithApi::QuotaApi* | [**quota_read**](docs/QuotaApi.md#quota_read) | **GET** /quota/{owner}/ | Quota usage for a given namespace. *CloudsmithApi::RatesApi* | [**rates_limits_list**](docs/RatesApi.md#rates_limits_list) | **GET** /rates/limits/ | Endpoint to check rate limits for current user. +*CloudsmithApi::RecycleBinApi* | [**recycle_bin_list**](docs/RecycleBinApi.md#recycle_bin_list) | **GET** /recycle-bin/{owner}/ | List soft-deleted packages in recycle bin +*CloudsmithApi::RecycleBinApi* | [**recycle_bin_recycle_bin_action**](docs/RecycleBinApi.md#recycle_bin_recycle_bin_action) | **POST** /recycle-bin/{owner}/action/ | *CloudsmithApi::ReposApi* | [**api_repos_geoip_status**](docs/ReposApi.md#api_repos_geoip_status) | **GET** /repos/{owner}/{identifier}/geoip/status/ | Retrieve the GeoIP status for this repository. *CloudsmithApi::ReposApi* | [**repo_retention_partial_update**](docs/ReposApi.md#repo_retention_partial_update) | **PATCH** /repos/{owner}/{repo}/retention/ | Update the retention rules for the repository. *CloudsmithApi::ReposApi* | [**repo_retention_read**](docs/ReposApi.md#repo_retention_read) | **GET** /repos/{owner}/{repo}/retention/ | Retrieve the retention rules for the repository. *CloudsmithApi::ReposApi* | [**repos_create**](docs/ReposApi.md#repos_create) | **POST** /repos/{owner}/ | Create a new repository in a given namespace. -*CloudsmithApi::ReposApi* | [**repos_delete**](docs/ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | Delete a repository in a given namespace. +*CloudsmithApi::ReposApi* | [**repos_delete**](docs/ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | *CloudsmithApi::ReposApi* | [**repos_ecdsa_create**](docs/ReposApi.md#repos_ecdsa_create) | **POST** /repos/{owner}/{identifier}/ecdsa/ | Set the active ECDSA key for the Repository. *CloudsmithApi::ReposApi* | [**repos_ecdsa_list**](docs/ReposApi.md#repos_ecdsa_list) | **GET** /repos/{owner}/{identifier}/ecdsa/ | Retrieve the active ECDSA key for the Repository. *CloudsmithApi::ReposApi* | [**repos_ecdsa_regenerate**](docs/ReposApi.md#repos_ecdsa_regenerate) | **POST** /repos/{owner}/{identifier}/ecdsa/regenerate/ | Regenerate ECDSA Key for the Repository. @@ -543,6 +548,8 @@ Class | Method | HTTP request | Description - [CloudsmithApi::MavenUpstream](docs/MavenUpstream.md) - [CloudsmithApi::MavenUpstreamRequest](docs/MavenUpstreamRequest.md) - [CloudsmithApi::MavenUpstreamRequestPatch](docs/MavenUpstreamRequestPatch.md) + - [CloudsmithApi::McpPackageUpload](docs/McpPackageUpload.md) + - [CloudsmithApi::McpPackageUploadRequest](docs/McpPackageUploadRequest.md) - [CloudsmithApi::Namespace](docs/Namespace.md) - [CloudsmithApi::NamespaceAuditLog](docs/NamespaceAuditLog.md) - [CloudsmithApi::NestedLicensePolicy](docs/NestedLicensePolicy.md) @@ -614,6 +621,7 @@ Class | Method | HTTP request | Description - [CloudsmithApi::PackageMoveRequest](docs/PackageMoveRequest.md) - [CloudsmithApi::PackageQuarantine](docs/PackageQuarantine.md) - [CloudsmithApi::PackageQuarantineRequest](docs/PackageQuarantineRequest.md) + - [CloudsmithApi::PackageRecycleBin](docs/PackageRecycleBin.md) - [CloudsmithApi::PackageResync](docs/PackageResync.md) - [CloudsmithApi::PackageStatus](docs/PackageStatus.md) - [CloudsmithApi::PackageTag](docs/PackageTag.md) @@ -639,6 +647,7 @@ Class | Method | HTTP request | Description - [CloudsmithApi::RateCheck](docs/RateCheck.md) - [CloudsmithApi::RawPackageUpload](docs/RawPackageUpload.md) - [CloudsmithApi::RawPackageUploadRequest](docs/RawPackageUploadRequest.md) + - [CloudsmithApi::RecycleBinPackage](docs/RecycleBinPackage.md) - [CloudsmithApi::Repository](docs/Repository.md) - [CloudsmithApi::RepositoryAuditLog](docs/RepositoryAuditLog.md) - [CloudsmithApi::RepositoryCreate](docs/RepositoryCreate.md) @@ -667,6 +676,8 @@ Class | Method | HTTP request | Description - [CloudsmithApi::RepositoryRsaKeyCreate](docs/RepositoryRsaKeyCreate.md) - [CloudsmithApi::RepositoryToken](docs/RepositoryToken.md) - [CloudsmithApi::RepositoryTokenAction](docs/RepositoryTokenAction.md) + - [CloudsmithApi::RepositoryTokenPrivateBroadcasts](docs/RepositoryTokenPrivateBroadcasts.md) + - [CloudsmithApi::RepositoryTokenPrivateBroadcastsRequest](docs/RepositoryTokenPrivateBroadcastsRequest.md) - [CloudsmithApi::RepositoryTokenRefresh](docs/RepositoryTokenRefresh.md) - [CloudsmithApi::RepositoryTokenRefreshRequest](docs/RepositoryTokenRefreshRequest.md) - [CloudsmithApi::RepositoryTokenRequest](docs/RepositoryTokenRequest.md) diff --git a/bindings/ruby/src/build.json b/bindings/ruby/src/build.json index 0093dbca..14cbf785 100644 --- a/bindings/ruby/src/build.json +++ b/bindings/ruby/src/build.json @@ -8,7 +8,7 @@ "gemName": "cloudsmith-api", "gemRequiredRubyVersion": ">= 1.9", "gemSummary": "Cloudsmith API", - "gemVersion": "2.0.25", + "gemVersion": "2.0.26", "hideGenerationTimestamp": true, "moduleName": "CloudsmithApi", "sortParamsByRequiredFlag": true diff --git a/bindings/ruby/src/docs/AlpineUpstream.md b/bindings/ruby/src/docs/AlpineUpstream.md index 6413ecf5..1d74bdae 100644 --- a/bindings/ruby/src/docs/AlpineUpstream.md +++ b/bindings/ruby/src/docs/AlpineUpstream.md @@ -24,6 +24,10 @@ Name | Type | Description | Notes **name** | **String** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | **pending_validation** | **BOOLEAN** | When true, this upstream source is pending validation. | [optional] **priority** | **Integer** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsa_key_inline** | **String** | A base64-encoded RSA public key in PEM format used to verify package signatures. | [optional] +**rsa_key_url** | **String** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsa_verification** | **String** | The RSA signature verification mode for this upstream. | [optional] [default to 'Allow All'] +**rsa_verification_status** | **String** | The RSA signature verification status for this upstream. | [optional] [default to 'Unknown'] **slug_perm** | **String** | | [optional] **updated_at** | **DateTime** | | [optional] **upstream_url** | **String** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | diff --git a/bindings/ruby/src/docs/AlpineUpstreamRequest.md b/bindings/ruby/src/docs/AlpineUpstreamRequest.md index 52f0e664..db77c161 100644 --- a/bindings/ruby/src/docs/AlpineUpstreamRequest.md +++ b/bindings/ruby/src/docs/AlpineUpstreamRequest.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **mode** | **String** | The mode that this upstream should operate in. Upstream sources can be used to proxy resolved packages, as well as operate in a proxy/cache or cache only mode. | [optional] [default to 'Proxy Only'] **name** | **String** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | **priority** | **Integer** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsa_key_url** | **String** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsa_verification** | **String** | The RSA signature verification mode for this upstream. | [optional] [default to 'Allow All'] **upstream_url** | **String** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | **verify_ssl** | **BOOLEAN** | If enabled, SSL certificates are verified when requests are made to this upstream. It's recommended to leave this enabled for all public sources to help mitigate Man-In-The-Middle (MITM) attacks. Please note this only applies to HTTPS upstreams. | [optional] diff --git a/bindings/ruby/src/docs/AlpineUpstreamRequestPatch.md b/bindings/ruby/src/docs/AlpineUpstreamRequestPatch.md index bd58b0d9..07500487 100644 --- a/bindings/ruby/src/docs/AlpineUpstreamRequestPatch.md +++ b/bindings/ruby/src/docs/AlpineUpstreamRequestPatch.md @@ -14,6 +14,8 @@ Name | Type | Description | Notes **mode** | **String** | The mode that this upstream should operate in. Upstream sources can be used to proxy resolved packages, as well as operate in a proxy/cache or cache only mode. | [optional] [default to 'Proxy Only'] **name** | **String** | A descriptive name for this upstream source. A shortened version of this name will be used for tagging cached packages retrieved from this upstream. | [optional] **priority** | **Integer** | Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. | [optional] +**rsa_key_url** | **String** | When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. | [optional] +**rsa_verification** | **String** | The RSA signature verification mode for this upstream. | [optional] [default to 'Allow All'] **upstream_url** | **String** | The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. | [optional] **verify_ssl** | **BOOLEAN** | If enabled, SSL certificates are verified when requests are made to this upstream. It's recommended to leave this enabled for all public sources to help mitigate Man-In-The-Middle (MITM) attacks. Please note this only applies to HTTPS upstreams. | [optional] diff --git a/bindings/ruby/src/docs/EntitlementsApi.md b/bindings/ruby/src/docs/EntitlementsApi.md index 3a52008b..031f0107 100644 --- a/bindings/ruby/src/docs/EntitlementsApi.md +++ b/bindings/ruby/src/docs/EntitlementsApi.md @@ -14,6 +14,7 @@ Method | HTTP request | Description [**entitlements_refresh**](EntitlementsApi.md#entitlements_refresh) | **POST** /entitlements/{owner}/{repo}/{identifier}/refresh/ | Refresh an entitlement token in a repository. [**entitlements_reset**](EntitlementsApi.md#entitlements_reset) | **POST** /entitlements/{owner}/{repo}/{identifier}/reset/ | Reset the statistics for an entitlement token in a repository. [**entitlements_sync**](EntitlementsApi.md#entitlements_sync) | **POST** /entitlements/{owner}/{repo}/sync/ | Synchronise tokens from a source repository. +[**entitlements_toggle_private_broadcasts**](EntitlementsApi.md#entitlements_toggle_private_broadcasts) | **POST** /entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/ | Set private broadcast access for an entitlement token in a repository. # **entitlements_create** @@ -691,3 +692,70 @@ Name | Type | Description | Notes +# **entitlements_toggle_private_broadcasts** +> entitlements_toggle_private_broadcasts(owner, repo, identifier, opts) + +Set private broadcast access for an entitlement token in a repository. + +Set private broadcast access for an entitlement token in a repository. + +### Example +```ruby +# load the gem +require 'cloudsmith-api' +# setup authorization +CloudsmithApi.configure do |config| + # Configure API key authorization: apikey + config.api_key['X-Api-Key'] = 'YOUR API KEY' + # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil) + #config.api_key_prefix['X-Api-Key'] = 'Bearer' + + # Configure HTTP basic authorization: basic + config.username = 'YOUR USERNAME' + config.password = 'YOUR PASSWORD' +end + +api_instance = CloudsmithApi::EntitlementsApi.new + +owner = 'owner_example' # String | + +repo = 'repo_example' # String | + +identifier = 'identifier_example' # String | + +opts = { + data: CloudsmithApi::RepositoryTokenPrivateBroadcastsRequest.new # RepositoryTokenPrivateBroadcastsRequest | +} + +begin + #Set private broadcast access for an entitlement token in a repository. + api_instance.entitlements_toggle_private_broadcasts(owner, repo, identifier, opts) +rescue CloudsmithApi::ApiError => e + puts "Exception when calling EntitlementsApi->entitlements_toggle_private_broadcasts: #{e}" +end +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **repo** | **String**| | + **identifier** | **String**| | + **data** | [**RepositoryTokenPrivateBroadcastsRequest**](RepositoryTokenPrivateBroadcastsRequest.md)| | [optional] + +### Return type + +nil (empty response body) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + + diff --git a/bindings/ruby/src/docs/McpPackageUpload.md b/bindings/ruby/src/docs/McpPackageUpload.md new file mode 100644 index 00000000..ac70e5c0 --- /dev/null +++ b/bindings/ruby/src/docs/McpPackageUpload.md @@ -0,0 +1,91 @@ +# CloudsmithApi::McpPackageUpload + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**architectures** | [**Array<Architecture>**](Architecture.md) | | [optional] +**cdn_url** | **String** | | [optional] +**checksum_md5** | **String** | | [optional] +**checksum_sha1** | **String** | | [optional] +**checksum_sha256** | **String** | | [optional] +**checksum_sha512** | **String** | | [optional] +**dependencies_checksum_md5** | **String** | A checksum of all of the package's dependencies. | [optional] +**dependencies_url** | **String** | | [optional] +**description** | **String** | A textual description of this package. | [optional] +**display_name** | **String** | | [optional] +**distro** | [**Distribution**](Distribution.md) | | [optional] +**distro_version** | [**DistributionVersion**](DistributionVersion.md) | | [optional] +**downloads** | **Integer** | | [optional] +**epoch** | **Integer** | The epoch of the package version (if any). | [optional] +**extension** | **String** | | [optional] +**filename** | **String** | | [optional] +**files** | [**Array<PackageFile>**](PackageFile.md) | | [optional] +**format** | **String** | | [optional] +**format_url** | **String** | | [optional] +**freeable_storage** | **Integer** | Amount of storage that will be freed if this package is deleted | [optional] +**fully_qualified_name** | **String** | | [optional] +**identifier_perm** | **String** | Unique and permanent identifier for the package. | [optional] +**identifiers** | **Hash<String, String>** | Return a map of identifier field names and their values. | [optional] +**indexed** | **BOOLEAN** | | [optional] +**is_cancellable** | **BOOLEAN** | | [optional] +**is_copyable** | **BOOLEAN** | | [optional] +**is_deleteable** | **BOOLEAN** | | [optional] +**is_downloadable** | **BOOLEAN** | | [optional] +**is_moveable** | **BOOLEAN** | | [optional] +**is_quarantinable** | **BOOLEAN** | | [optional] +**is_quarantined** | **BOOLEAN** | | [optional] +**is_resyncable** | **BOOLEAN** | | [optional] +**is_security_scannable** | **BOOLEAN** | | [optional] +**is_sync_awaiting** | **BOOLEAN** | | [optional] +**is_sync_completed** | **BOOLEAN** | | [optional] +**is_sync_failed** | **BOOLEAN** | | [optional] +**is_sync_in_flight** | **BOOLEAN** | | [optional] +**is_sync_in_progress** | **BOOLEAN** | | [optional] +**license** | **String** | The license of this package. | [optional] +**name** | **String** | The name of this package. | [optional] +**namespace** | **String** | | [optional] +**namespace_url** | **String** | | [optional] +**num_files** | **Integer** | | [optional] +**origin_repository** | **String** | | [optional] +**origin_repository_url** | **String** | | [optional] +**package_type** | **Integer** | The type of package contents. | [optional] +**policy_violated** | **BOOLEAN** | Whether or not the package has violated any policy. | [optional] +**raw_license** | **String** | The raw license string. | [optional] +**release** | **String** | The release of the package version (if any). | [optional] +**repository** | **String** | | [optional] +**repository_url** | **String** | | [optional] +**security_scan_completed_at** | **DateTime** | The datetime the security scanning was completed. | [optional] +**security_scan_started_at** | **DateTime** | The datetime the security scanning was started. | [optional] +**security_scan_status** | **String** | | [optional] [default to 'Awaiting Security Scan'] +**security_scan_status_updated_at** | **DateTime** | The datetime the security scanning status was updated. | [optional] +**self_html_url** | **String** | | [optional] +**self_url** | **String** | | [optional] +**self_webapp_url** | **String** | | [optional] +**signature_url** | **String** | | [optional] +**size** | **Integer** | The calculated size of the package. | [optional] +**slug** | **String** | The public unique identifier for the package. | [optional] +**slug_perm** | **String** | | [optional] +**spdx_license** | **String** | The SPDX license identifier for this package. | [optional] +**stage** | **Integer** | The synchronisation (in progress) stage of the package. | [optional] +**stage_str** | **String** | | [optional] +**stage_updated_at** | **DateTime** | The datetime the package stage was updated at. | [optional] +**status** | **Integer** | The synchronisation status of the package. | [optional] +**status_reason** | **String** | A textual description for the synchronous status reason (if any | [optional] +**status_str** | **String** | | [optional] +**status_updated_at** | **DateTime** | The datetime the package status was updated at. | [optional] +**status_url** | **String** | | [optional] +**subtype** | **String** | | [optional] +**summary** | **String** | A one-liner synopsis of this package. | [optional] +**sync_finished_at** | **DateTime** | The datetime the package sync was finished at. | [optional] +**sync_progress** | **Integer** | Synchronisation progress (from 0-100) | [optional] +**tags_automatic** | [**Tags**](Tags.md) | | [optional] +**tags_immutable** | [**Tags**](Tags.md) | | [optional] +**type_display** | **String** | | [optional] +**uploaded_at** | **DateTime** | The date this package was uploaded. | [optional] +**uploader** | **String** | | [optional] +**uploader_url** | **String** | | [optional] +**version** | **String** | The raw version for this package. | [optional] +**version_orig** | **String** | | [optional] +**vulnerability_scan_results_url** | **String** | | [optional] + + diff --git a/bindings/ruby/src/docs/McpPackageUploadRequest.md b/bindings/ruby/src/docs/McpPackageUploadRequest.md new file mode 100644 index 00000000..c8b43974 --- /dev/null +++ b/bindings/ruby/src/docs/McpPackageUploadRequest.md @@ -0,0 +1,11 @@ +# CloudsmithApi::McpPackageUploadRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**package_file** | **String** | The primary file for the package. | +**republish** | **BOOLEAN** | If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. | [optional] +**tags** | **String** | A comma-separated values list of tags to add to the package. | [optional] +**version** | **String** | The raw version for this package. | [optional] + + diff --git a/bindings/ruby/src/docs/PackageRecycleBin.md b/bindings/ruby/src/docs/PackageRecycleBin.md new file mode 100644 index 00000000..4600279f --- /dev/null +++ b/bindings/ruby/src/docs/PackageRecycleBin.md @@ -0,0 +1,10 @@ +# CloudsmithApi::PackageRecycleBin + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action** | **String** | The action to perform on soft-deleted packages. | +**identifiers** | **Array<String>** | A list of soft-deleted package identifiers to action. | +**repository** | **String** | The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. | [optional] + + diff --git a/bindings/ruby/src/docs/PackagesApi.md b/bindings/ruby/src/docs/PackagesApi.md index 181a82b8..c36dc503 100644 --- a/bindings/ruby/src/docs/PackagesApi.md +++ b/bindings/ruby/src/docs/PackagesApi.md @@ -34,6 +34,7 @@ Method | HTTP request | Description [**packages_upload_huggingface**](PackagesApi.md#packages_upload_huggingface) | **POST** /packages/{owner}/{repo}/upload/huggingface/ | Create a new HuggingFace package [**packages_upload_luarocks**](PackagesApi.md#packages_upload_luarocks) | **POST** /packages/{owner}/{repo}/upload/luarocks/ | Create a new LuaRocks package [**packages_upload_maven**](PackagesApi.md#packages_upload_maven) | **POST** /packages/{owner}/{repo}/upload/maven/ | Create a new Maven package +[**packages_upload_mcp**](PackagesApi.md#packages_upload_mcp) | **POST** /packages/{owner}/{repo}/upload/mcp/ | Create a new MCP package [**packages_upload_npm**](PackagesApi.md#packages_upload_npm) | **POST** /packages/{owner}/{repo}/upload/npm/ | Create a new npm package [**packages_upload_nuget**](PackagesApi.md#packages_upload_nuget) | **POST** /packages/{owner}/{repo}/upload/nuget/ | Create a new NuGet package [**packages_upload_p2**](PackagesApi.md#packages_upload_p2) | **POST** /packages/{owner}/{repo}/upload/p2/ | Create a new P2 package @@ -62,6 +63,7 @@ Method | HTTP request | Description [**packages_validate_upload_huggingface**](PackagesApi.md#packages_validate_upload_huggingface) | **POST** /packages/{owner}/{repo}/validate-upload/huggingface/ | Validate parameters for create HuggingFace package [**packages_validate_upload_luarocks**](PackagesApi.md#packages_validate_upload_luarocks) | **POST** /packages/{owner}/{repo}/validate-upload/luarocks/ | Validate parameters for create LuaRocks package [**packages_validate_upload_maven**](PackagesApi.md#packages_validate_upload_maven) | **POST** /packages/{owner}/{repo}/validate-upload/maven/ | Validate parameters for create Maven package +[**packages_validate_upload_mcp**](PackagesApi.md#packages_validate_upload_mcp) | **POST** /packages/{owner}/{repo}/validate-upload/mcp/ | Validate parameters for create MCP package [**packages_validate_upload_npm**](PackagesApi.md#packages_validate_upload_npm) | **POST** /packages/{owner}/{repo}/validate-upload/npm/ | Validate parameters for create npm package [**packages_validate_upload_nuget**](PackagesApi.md#packages_validate_upload_nuget) | **POST** /packages/{owner}/{repo}/validate-upload/nuget/ | Validate parameters for create NuGet package [**packages_validate_upload_p2**](PackagesApi.md#packages_validate_upload_p2) | **POST** /packages/{owner}/{repo}/validate-upload/p2/ | Validate parameters for create P2 package @@ -2049,6 +2051,71 @@ Name | Type | Description | Notes +# **packages_upload_mcp** +> McpPackageUpload packages_upload_mcp(owner, repo, opts) + +Create a new MCP package + +Create a new MCP package + +### Example +```ruby +# load the gem +require 'cloudsmith-api' +# setup authorization +CloudsmithApi.configure do |config| + # Configure API key authorization: apikey + config.api_key['X-Api-Key'] = 'YOUR API KEY' + # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil) + #config.api_key_prefix['X-Api-Key'] = 'Bearer' + + # Configure HTTP basic authorization: basic + config.username = 'YOUR USERNAME' + config.password = 'YOUR PASSWORD' +end + +api_instance = CloudsmithApi::PackagesApi.new + +owner = 'owner_example' # String | + +repo = 'repo_example' # String | + +opts = { + data: CloudsmithApi::McpPackageUploadRequest.new # McpPackageUploadRequest | +} + +begin + #Create a new MCP package + result = api_instance.packages_upload_mcp(owner, repo, opts) + p result +rescue CloudsmithApi::ApiError => e + puts "Exception when calling PackagesApi->packages_upload_mcp: #{e}" +end +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **repo** | **String**| | + **data** | [**McpPackageUploadRequest**](McpPackageUploadRequest.md)| | [optional] + +### Return type + +[**McpPackageUpload**](McpPackageUpload.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + + # **packages_upload_npm** > NpmPackageUpload packages_upload_npm(owner, repo, opts) @@ -3852,6 +3919,70 @@ nil (empty response body) +# **packages_validate_upload_mcp** +> packages_validate_upload_mcp(owner, repo, opts) + +Validate parameters for create MCP package + +Validate parameters for create MCP package + +### Example +```ruby +# load the gem +require 'cloudsmith-api' +# setup authorization +CloudsmithApi.configure do |config| + # Configure API key authorization: apikey + config.api_key['X-Api-Key'] = 'YOUR API KEY' + # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil) + #config.api_key_prefix['X-Api-Key'] = 'Bearer' + + # Configure HTTP basic authorization: basic + config.username = 'YOUR USERNAME' + config.password = 'YOUR PASSWORD' +end + +api_instance = CloudsmithApi::PackagesApi.new + +owner = 'owner_example' # String | + +repo = 'repo_example' # String | + +opts = { + data: CloudsmithApi::McpPackageUploadRequest.new # McpPackageUploadRequest | +} + +begin + #Validate parameters for create MCP package + api_instance.packages_validate_upload_mcp(owner, repo, opts) +rescue CloudsmithApi::ApiError => e + puts "Exception when calling PackagesApi->packages_validate_upload_mcp: #{e}" +end +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **repo** | **String**| | + **data** | [**McpPackageUploadRequest**](McpPackageUploadRequest.md)| | [optional] + +### Return type + +nil (empty response body) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + + # **packages_validate_upload_npm** > packages_validate_upload_npm(owner, repo, opts) diff --git a/bindings/ruby/src/docs/RecycleBinApi.md b/bindings/ruby/src/docs/RecycleBinApi.md new file mode 100644 index 00000000..2d2e93aa --- /dev/null +++ b/bindings/ruby/src/docs/RecycleBinApi.md @@ -0,0 +1,137 @@ +# CloudsmithApi::RecycleBinApi + +All URIs are relative to *https://api.cloudsmith.io* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**recycle_bin_list**](RecycleBinApi.md#recycle_bin_list) | **GET** /recycle-bin/{owner}/ | List soft-deleted packages in recycle bin +[**recycle_bin_recycle_bin_action**](RecycleBinApi.md#recycle_bin_recycle_bin_action) | **POST** /recycle-bin/{owner}/action/ | + + +# **recycle_bin_list** +> Array<RecycleBinPackage> recycle_bin_list(owner, opts) + +List soft-deleted packages in recycle bin + +Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + +### Example +```ruby +# load the gem +require 'cloudsmith-api' +# setup authorization +CloudsmithApi.configure do |config| + # Configure API key authorization: apikey + config.api_key['X-Api-Key'] = 'YOUR API KEY' + # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil) + #config.api_key_prefix['X-Api-Key'] = 'Bearer' + + # Configure HTTP basic authorization: basic + config.username = 'YOUR USERNAME' + config.password = 'YOUR PASSWORD' +end + +api_instance = CloudsmithApi::RecycleBinApi.new + +owner = 'owner_example' # String | + +opts = { + page: 56, # Integer | A page number within the paginated result set. + page_size: 56, # Integer | Number of results to return per page. + repository: 'repository_example' # String | Filter packages by repository slug +} + +begin + #List soft-deleted packages in recycle bin + result = api_instance.recycle_bin_list(owner, opts) + p result +rescue CloudsmithApi::ApiError => e + puts "Exception when calling RecycleBinApi->recycle_bin_list: #{e}" +end +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **page** | **Integer**| A page number within the paginated result set. | [optional] + **page_size** | **Integer**| Number of results to return per page. | [optional] + **repository** | **String**| Filter packages by repository slug | [optional] + +### Return type + +[**Array<RecycleBinPackage>**](RecycleBinPackage.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + + +# **recycle_bin_recycle_bin_action** +> PackageBulkActionResponse recycle_bin_recycle_bin_action(owner, opts) + + + +Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + +### Example +```ruby +# load the gem +require 'cloudsmith-api' +# setup authorization +CloudsmithApi.configure do |config| + # Configure API key authorization: apikey + config.api_key['X-Api-Key'] = 'YOUR API KEY' + # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil) + #config.api_key_prefix['X-Api-Key'] = 'Bearer' + + # Configure HTTP basic authorization: basic + config.username = 'YOUR USERNAME' + config.password = 'YOUR PASSWORD' +end + +api_instance = CloudsmithApi::RecycleBinApi.new + +owner = 'owner_example' # String | + +opts = { + data: CloudsmithApi::PackageRecycleBin.new # PackageRecycleBin | +} + +begin + result = api_instance.recycle_bin_recycle_bin_action(owner, opts) + p result +rescue CloudsmithApi::ApiError => e + puts "Exception when calling RecycleBinApi->recycle_bin_recycle_bin_action: #{e}" +end +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **owner** | **String**| | + **data** | [**PackageRecycleBin**](PackageRecycleBin.md)| | [optional] + +### Return type + +[**PackageBulkActionResponse**](PackageBulkActionResponse.md) + +### Authorization + +[apikey](../README.md#apikey), [basic](../README.md#basic) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + + diff --git a/bindings/ruby/src/docs/RecycleBinPackage.md b/bindings/ruby/src/docs/RecycleBinPackage.md new file mode 100644 index 00000000..5b1b1a88 --- /dev/null +++ b/bindings/ruby/src/docs/RecycleBinPackage.md @@ -0,0 +1,31 @@ +# CloudsmithApi::RecycleBinPackage + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action_by** | **String** | The name of the user who deleted the package. | [optional] +**downloads** | **Integer** | | [optional] +**filename** | **String** | | [optional] +**format** | **String** | | [optional] +**fully_qualified_name** | **String** | The fully qualified name of the package. | [optional] +**identifiers** | **Hash<String, String>** | | [optional] +**invoked_retention_rule** | **Hash<String, String>** | Information about the retention rule that triggered deletion (if any). | [optional] +**is_deleteable** | **BOOLEAN** | | [optional] +**is_quarantined** | **BOOLEAN** | | [optional] +**is_restorable** | **BOOLEAN** | | [optional] +**name** | **String** | The name of this package. | [optional] +**policy_violated** | **BOOLEAN** | Whether or not the package has violated any policy. | [optional] +**repository** | **String** | | [optional] +**security_scan_completed_at** | **DateTime** | The datetime the security scanning was completed. | [optional] +**security_scan_status** | **String** | | [optional] [default to 'Awaiting Security Scan'] +**size** | **Integer** | The calculated size of the package. | [optional] +**slug_perm** | **String** | | [optional] +**status** | **Integer** | The synchronisation status of the package. | [optional] +**status_updated_at** | **DateTime** | The datetime the package status was updated at. | [optional] +**tags** | [**Tags**](Tags.md) | | [optional] +**type_display** | **String** | | [optional] +**uploaded_at** | **DateTime** | The date this package was uploaded. | [optional] +**uploader** | **String** | | [optional] +**version** | **String** | The raw version for this package. | [optional] + + diff --git a/bindings/ruby/src/docs/ReposApi.md b/bindings/ruby/src/docs/ReposApi.md index d2f1b819..8e942ad7 100644 --- a/bindings/ruby/src/docs/ReposApi.md +++ b/bindings/ruby/src/docs/ReposApi.md @@ -8,7 +8,7 @@ Method | HTTP request | Description [**repo_retention_partial_update**](ReposApi.md#repo_retention_partial_update) | **PATCH** /repos/{owner}/{repo}/retention/ | Update the retention rules for the repository. [**repo_retention_read**](ReposApi.md#repo_retention_read) | **GET** /repos/{owner}/{repo}/retention/ | Retrieve the retention rules for the repository. [**repos_create**](ReposApi.md#repos_create) | **POST** /repos/{owner}/ | Create a new repository in a given namespace. -[**repos_delete**](ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | Delete a repository in a given namespace. +[**repos_delete**](ReposApi.md#repos_delete) | **DELETE** /repos/{owner}/{identifier}/ | [**repos_ecdsa_create**](ReposApi.md#repos_ecdsa_create) | **POST** /repos/{owner}/{identifier}/ecdsa/ | Set the active ECDSA key for the Repository. [**repos_ecdsa_list**](ReposApi.md#repos_ecdsa_list) | **GET** /repos/{owner}/{identifier}/ecdsa/ | Retrieve the active ECDSA key for the Repository. [**repos_ecdsa_regenerate**](ReposApi.md#repos_ecdsa_regenerate) | **POST** /repos/{owner}/{identifier}/ecdsa/regenerate/ | Regenerate ECDSA Key for the Repository. @@ -408,9 +408,9 @@ Name | Type | Description | Notes # **repos_delete** > repos_delete(owner, identifier) -Delete a repository in a given namespace. -Delete a repository in a given namespace. + +Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. ### Example ```ruby @@ -436,7 +436,6 @@ identifier = 'identifier_example' # String | begin - #Delete a repository in a given namespace. api_instance.repos_delete(owner, identifier) rescue CloudsmithApi::ApiError => e puts "Exception when calling ReposApi->repos_delete: #{e}" diff --git a/bindings/ruby/src/docs/RepositoryTokenPrivateBroadcasts.md b/bindings/ruby/src/docs/RepositoryTokenPrivateBroadcasts.md new file mode 100644 index 00000000..89014702 --- /dev/null +++ b/bindings/ruby/src/docs/RepositoryTokenPrivateBroadcasts.md @@ -0,0 +1,8 @@ +# CloudsmithApi::RepositoryTokenPrivateBroadcasts + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**access_private_broadcasts** | **BOOLEAN** | Whether the token should have access to private broadcasts. | + + diff --git a/bindings/ruby/src/docs/RepositoryTokenPrivateBroadcastsRequest.md b/bindings/ruby/src/docs/RepositoryTokenPrivateBroadcastsRequest.md new file mode 100644 index 00000000..4dafbc31 --- /dev/null +++ b/bindings/ruby/src/docs/RepositoryTokenPrivateBroadcastsRequest.md @@ -0,0 +1,8 @@ +# CloudsmithApi::RepositoryTokenPrivateBroadcastsRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**access_private_broadcasts** | **BOOLEAN** | Whether the token should have access to private broadcasts. | + + diff --git a/bindings/ruby/src/docs/RepositoryTokenRefreshRequest.md b/bindings/ruby/src/docs/RepositoryTokenRefreshRequest.md index d48ffb24..f4131cc3 100644 --- a/bindings/ruby/src/docs/RepositoryTokenRefreshRequest.md +++ b/bindings/ruby/src/docs/RepositoryTokenRefreshRequest.md @@ -3,7 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**access_private_broadcasts** | **BOOLEAN** | If enabled, this token can be used for private broadcasts | [optional] **eula_required** | **BOOLEAN** | If checked, a EULA acceptance is required for this token. | [optional] **is_active** | **BOOLEAN** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limit_bandwidth** | **Integer** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/ruby/src/docs/RepositoryTokenRequest.md b/bindings/ruby/src/docs/RepositoryTokenRequest.md index bdc8db11..94ac6c76 100644 --- a/bindings/ruby/src/docs/RepositoryTokenRequest.md +++ b/bindings/ruby/src/docs/RepositoryTokenRequest.md @@ -3,7 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**access_private_broadcasts** | **BOOLEAN** | If enabled, this token can be used for private broadcasts | [optional] **eula_required** | **BOOLEAN** | If checked, a EULA acceptance is required for this token. | [optional] **is_active** | **BOOLEAN** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limit_bandwidth** | **Integer** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/ruby/src/docs/RepositoryTokenRequestPatch.md b/bindings/ruby/src/docs/RepositoryTokenRequestPatch.md index db98264a..83f20775 100644 --- a/bindings/ruby/src/docs/RepositoryTokenRequestPatch.md +++ b/bindings/ruby/src/docs/RepositoryTokenRequestPatch.md @@ -3,7 +3,6 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**access_private_broadcasts** | **BOOLEAN** | If enabled, this token can be used for private broadcasts | [optional] **eula_required** | **BOOLEAN** | If checked, a EULA acceptance is required for this token. | [optional] **is_active** | **BOOLEAN** | If enabled, the token will allow downloads based on configured restrictions (if any). | [optional] **limit_bandwidth** | **Integer** | The maximum download bandwidth allowed for the token. Values are expressed as the selected unit of bandwidth. Please note that since downloads are calculated asynchronously (after the download happens), the limit may not be imposed immediately but at a later point. | [optional] diff --git a/bindings/ruby/src/docs/StorageAllocatedLimit.md b/bindings/ruby/src/docs/StorageAllocatedLimit.md index 62647150..269476f1 100644 --- a/bindings/ruby/src/docs/StorageAllocatedLimit.md +++ b/bindings/ruby/src/docs/StorageAllocatedLimit.md @@ -8,5 +8,6 @@ Name | Type | Description | Notes **percentage_used** | **String** | | [optional] **plan_limit** | **String** | | [optional] **used** | **String** | | [optional] +**used_pre_deduplication** | **String** | | [optional] diff --git a/bindings/ruby/src/docs/StorageAllocatedLimitRaw.md b/bindings/ruby/src/docs/StorageAllocatedLimitRaw.md index bcec020d..c21d1170 100644 --- a/bindings/ruby/src/docs/StorageAllocatedLimitRaw.md +++ b/bindings/ruby/src/docs/StorageAllocatedLimitRaw.md @@ -8,5 +8,6 @@ Name | Type | Description | Notes **percentage_used** | **String** | | [optional] **plan_limit** | **Integer** | | [optional] **used** | **Integer** | | [optional] +**used_pre_deduplication** | **Integer** | | [optional] diff --git a/bindings/ruby/src/lib/cloudsmith-api.rb b/bindings/ruby/src/lib/cloudsmith-api.rb index d3d590ff..7f844a39 100644 --- a/bindings/ruby/src/lib/cloudsmith-api.rb +++ b/bindings/ruby/src/lib/cloudsmith-api.rb @@ -119,6 +119,8 @@ require 'cloudsmith-api/models/maven_upstream' require 'cloudsmith-api/models/maven_upstream_request' require 'cloudsmith-api/models/maven_upstream_request_patch' +require 'cloudsmith-api/models/mcp_package_upload' +require 'cloudsmith-api/models/mcp_package_upload_request' require 'cloudsmith-api/models/namespace' require 'cloudsmith-api/models/namespace_audit_log' require 'cloudsmith-api/models/nested_license_policy' @@ -190,6 +192,7 @@ require 'cloudsmith-api/models/package_move_request' require 'cloudsmith-api/models/package_quarantine' require 'cloudsmith-api/models/package_quarantine_request' +require 'cloudsmith-api/models/package_recycle_bin' require 'cloudsmith-api/models/package_resync' require 'cloudsmith-api/models/package_status' require 'cloudsmith-api/models/package_tag' @@ -215,6 +218,7 @@ require 'cloudsmith-api/models/rate_check' require 'cloudsmith-api/models/raw_package_upload' require 'cloudsmith-api/models/raw_package_upload_request' +require 'cloudsmith-api/models/recycle_bin_package' require 'cloudsmith-api/models/repository' require 'cloudsmith-api/models/repository_audit_log' require 'cloudsmith-api/models/repository_create' @@ -243,6 +247,8 @@ require 'cloudsmith-api/models/repository_rsa_key_create' require 'cloudsmith-api/models/repository_token' require 'cloudsmith-api/models/repository_token_action' +require 'cloudsmith-api/models/repository_token_private_broadcasts' +require 'cloudsmith-api/models/repository_token_private_broadcasts_request' require 'cloudsmith-api/models/repository_token_refresh' require 'cloudsmith-api/models/repository_token_refresh_request' require 'cloudsmith-api/models/repository_token_request' @@ -323,6 +329,7 @@ require 'cloudsmith-api/api/packages_api' require 'cloudsmith-api/api/quota_api' require 'cloudsmith-api/api/rates_api' +require 'cloudsmith-api/api/recycle_bin_api' require 'cloudsmith-api/api/repos_api' require 'cloudsmith-api/api/status_api' require 'cloudsmith-api/api/storage_regions_api' diff --git a/bindings/ruby/src/lib/cloudsmith-api/api/entitlements_api.rb b/bindings/ruby/src/lib/cloudsmith-api/api/entitlements_api.rb index 4a257d73..2961c600 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/api/entitlements_api.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/api/entitlements_api.rb @@ -704,5 +704,72 @@ def entitlements_sync_with_http_info(owner, repo, opts = {}) end return data, status_code, headers end + # Set private broadcast access for an entitlement token in a repository. + # Set private broadcast access for an entitlement token in a repository. + # @param owner + # @param repo + # @param identifier + # @param [Hash] opts the optional parameters + # @option opts [RepositoryTokenPrivateBroadcastsRequest] :data + # @return [nil] + def entitlements_toggle_private_broadcasts(owner, repo, identifier, opts = {}) + entitlements_toggle_private_broadcasts_with_http_info(owner, repo, identifier, opts) + nil + end + + # Set private broadcast access for an entitlement token in a repository. + # Set private broadcast access for an entitlement token in a repository. + # @param owner + # @param repo + # @param identifier + # @param [Hash] opts the optional parameters + # @option opts [RepositoryTokenPrivateBroadcastsRequest] :data + # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers + def entitlements_toggle_private_broadcasts_with_http_info(owner, repo, identifier, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: EntitlementsApi.entitlements_toggle_private_broadcasts ...' + end + # verify the required parameter 'owner' is set + if @api_client.config.client_side_validation && owner.nil? + fail ArgumentError, "Missing the required parameter 'owner' when calling EntitlementsApi.entitlements_toggle_private_broadcasts" + end + # verify the required parameter 'repo' is set + if @api_client.config.client_side_validation && repo.nil? + fail ArgumentError, "Missing the required parameter 'repo' when calling EntitlementsApi.entitlements_toggle_private_broadcasts" + end + # verify the required parameter 'identifier' is set + if @api_client.config.client_side_validation && identifier.nil? + fail ArgumentError, "Missing the required parameter 'identifier' when calling EntitlementsApi.entitlements_toggle_private_broadcasts" + end + # resource path + local_var_path = '/entitlements/{owner}/{repo}/{identifier}/toggle-private-broadcasts/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s).sub('{' + 'identifier' + '}', identifier.to_s) + + # query parameters + query_params = {} + + # header parameters + header_params = {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = {} + + # http body (model) + post_body = @api_client.object_to_http_body(opts[:'data']) + auth_names = ['apikey', 'basic'] + data, status_code, headers = @api_client.call_api(:POST, local_var_path, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names) + if @api_client.config.debugging + @api_client.config.logger.debug "API called: EntitlementsApi#entitlements_toggle_private_broadcasts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end end end diff --git a/bindings/ruby/src/lib/cloudsmith-api/api/packages_api.rb b/bindings/ruby/src/lib/cloudsmith-api/api/packages_api.rb index 6af67177..01fc8092 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/api/packages_api.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/api/packages_api.rb @@ -1958,6 +1958,68 @@ def packages_upload_maven_with_http_info(owner, repo, opts = {}) end return data, status_code, headers end + # Create a new MCP package + # Create a new MCP package + # @param owner + # @param repo + # @param [Hash] opts the optional parameters + # @option opts [McpPackageUploadRequest] :data + # @return [McpPackageUpload] + def packages_upload_mcp(owner, repo, opts = {}) + data, _status_code, _headers = packages_upload_mcp_with_http_info(owner, repo, opts) + data + end + + # Create a new MCP package + # Create a new MCP package + # @param owner + # @param repo + # @param [Hash] opts the optional parameters + # @option opts [McpPackageUploadRequest] :data + # @return [Array<(McpPackageUpload, Fixnum, Hash)>] McpPackageUpload data, response status code and response headers + def packages_upload_mcp_with_http_info(owner, repo, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: PackagesApi.packages_upload_mcp ...' + end + # verify the required parameter 'owner' is set + if @api_client.config.client_side_validation && owner.nil? + fail ArgumentError, "Missing the required parameter 'owner' when calling PackagesApi.packages_upload_mcp" + end + # verify the required parameter 'repo' is set + if @api_client.config.client_side_validation && repo.nil? + fail ArgumentError, "Missing the required parameter 'repo' when calling PackagesApi.packages_upload_mcp" + end + # resource path + local_var_path = '/packages/{owner}/{repo}/upload/mcp/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s) + + # query parameters + query_params = {} + + # header parameters + header_params = {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = {} + + # http body (model) + post_body = @api_client.object_to_http_body(opts[:'data']) + auth_names = ['apikey', 'basic'] + data, status_code, headers = @api_client.call_api(:POST, local_var_path, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => 'McpPackageUpload') + if @api_client.config.debugging + @api_client.config.logger.debug "API called: PackagesApi#packages_upload_mcp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end # Create a new npm package # Create a new npm package # @param owner @@ -3677,6 +3739,67 @@ def packages_validate_upload_maven_with_http_info(owner, repo, opts = {}) end return data, status_code, headers end + # Validate parameters for create MCP package + # Validate parameters for create MCP package + # @param owner + # @param repo + # @param [Hash] opts the optional parameters + # @option opts [McpPackageUploadRequest] :data + # @return [nil] + def packages_validate_upload_mcp(owner, repo, opts = {}) + packages_validate_upload_mcp_with_http_info(owner, repo, opts) + nil + end + + # Validate parameters for create MCP package + # Validate parameters for create MCP package + # @param owner + # @param repo + # @param [Hash] opts the optional parameters + # @option opts [McpPackageUploadRequest] :data + # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers + def packages_validate_upload_mcp_with_http_info(owner, repo, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: PackagesApi.packages_validate_upload_mcp ...' + end + # verify the required parameter 'owner' is set + if @api_client.config.client_side_validation && owner.nil? + fail ArgumentError, "Missing the required parameter 'owner' when calling PackagesApi.packages_validate_upload_mcp" + end + # verify the required parameter 'repo' is set + if @api_client.config.client_side_validation && repo.nil? + fail ArgumentError, "Missing the required parameter 'repo' when calling PackagesApi.packages_validate_upload_mcp" + end + # resource path + local_var_path = '/packages/{owner}/{repo}/validate-upload/mcp/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s) + + # query parameters + query_params = {} + + # header parameters + header_params = {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = {} + + # http body (model) + post_body = @api_client.object_to_http_body(opts[:'data']) + auth_names = ['apikey', 'basic'] + data, status_code, headers = @api_client.call_api(:POST, local_var_path, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names) + if @api_client.config.debugging + @api_client.config.logger.debug "API called: PackagesApi#packages_validate_upload_mcp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end # Validate parameters for create npm package # Validate parameters for create npm package # @param owner diff --git a/bindings/ruby/src/lib/cloudsmith-api/api/recycle_bin_api.rb b/bindings/ruby/src/lib/cloudsmith-api/api/recycle_bin_api.rb new file mode 100644 index 00000000..d692432d --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/api/recycle_bin_api.rb @@ -0,0 +1,140 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'uri' + +module CloudsmithApi + class RecycleBinApi + attr_accessor :api_client + + def initialize(api_client = ApiClient.default) + @api_client = api_client + end + # List soft-deleted packages in recycle bin + # Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + # @param owner + # @param [Hash] opts the optional parameters + # @option opts [Integer] :page A page number within the paginated result set. + # @option opts [Integer] :page_size Number of results to return per page. + # @option opts [String] :repository Filter packages by repository slug + # @return [Array] + def recycle_bin_list(owner, opts = {}) + data, _status_code, _headers = recycle_bin_list_with_http_info(owner, opts) + data + end + + # List soft-deleted packages in recycle bin + # Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + # @param owner + # @param [Hash] opts the optional parameters + # @option opts [Integer] :page A page number within the paginated result set. + # @option opts [Integer] :page_size Number of results to return per page. + # @option opts [String] :repository Filter packages by repository slug + # @return [Array<(Array, Fixnum, Hash)>] Array data, response status code and response headers + def recycle_bin_list_with_http_info(owner, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: RecycleBinApi.recycle_bin_list ...' + end + # verify the required parameter 'owner' is set + if @api_client.config.client_side_validation && owner.nil? + fail ArgumentError, "Missing the required parameter 'owner' when calling RecycleBinApi.recycle_bin_list" + end + # resource path + local_var_path = '/recycle-bin/{owner}/'.sub('{' + 'owner' + '}', owner.to_s) + + # query parameters + query_params = {} + query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? + query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? + query_params[:'repository'] = opts[:'repository'] if !opts[:'repository'].nil? + + # header parameters + header_params = {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = {} + + # http body (model) + post_body = nil + auth_names = ['apikey', 'basic'] + data, status_code, headers = @api_client.call_api(:GET, local_var_path, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => 'Array') + if @api_client.config.debugging + @api_client.config.logger.debug "API called: RecycleBinApi#recycle_bin_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + # Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + # @param owner + # @param [Hash] opts the optional parameters + # @option opts [PackageRecycleBin] :data + # @return [PackageBulkActionResponse] + def recycle_bin_recycle_bin_action(owner, opts = {}) + data, _status_code, _headers = recycle_bin_recycle_bin_action_with_http_info(owner, opts) + data + end + + # Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + # @param owner + # @param [Hash] opts the optional parameters + # @option opts [PackageRecycleBin] :data + # @return [Array<(PackageBulkActionResponse, Fixnum, Hash)>] PackageBulkActionResponse data, response status code and response headers + def recycle_bin_recycle_bin_action_with_http_info(owner, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: RecycleBinApi.recycle_bin_recycle_bin_action ...' + end + # verify the required parameter 'owner' is set + if @api_client.config.client_side_validation && owner.nil? + fail ArgumentError, "Missing the required parameter 'owner' when calling RecycleBinApi.recycle_bin_recycle_bin_action" + end + # resource path + local_var_path = '/recycle-bin/{owner}/action/'.sub('{' + 'owner' + '}', owner.to_s) + + # query parameters + query_params = {} + + # header parameters + header_params = {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + + # form parameters + form_params = {} + + # http body (model) + post_body = @api_client.object_to_http_body(opts[:'data']) + auth_names = ['apikey', 'basic'] + data, status_code, headers = @api_client.call_api(:POST, local_var_path, + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => 'PackageBulkActionResponse') + if @api_client.config.debugging + @api_client.config.logger.debug "API called: RecycleBinApi#recycle_bin_recycle_bin_action\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/api/repos_api.rb b/bindings/ruby/src/lib/cloudsmith-api/api/repos_api.rb index b0cd6bb8..5b1b8e28 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/api/repos_api.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/api/repos_api.rb @@ -257,8 +257,7 @@ def repos_create_with_http_info(owner, opts = {}) end return data, status_code, headers end - # Delete a repository in a given namespace. - # Delete a repository in a given namespace. + # Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. # @param owner # @param identifier # @param [Hash] opts the optional parameters @@ -268,8 +267,7 @@ def repos_delete(owner, identifier, opts = {}) nil end - # Delete a repository in a given namespace. - # Delete a repository in a given namespace. + # Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. # @param owner # @param identifier # @param [Hash] opts the optional parameters diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb index 39086fd7..afbfeb42 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb @@ -76,6 +76,18 @@ class AlpineUpstream # Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. attr_accessor :priority + # A base64-encoded RSA public key in PEM format used to verify package signatures. + attr_accessor :rsa_key_inline + + # When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + attr_accessor :rsa_key_url + + # The RSA signature verification mode for this upstream. + attr_accessor :rsa_verification + + # The RSA signature verification status for this upstream. + attr_accessor :rsa_verification_status + attr_accessor :slug_perm attr_accessor :updated_at @@ -132,6 +144,10 @@ def self.attribute_map :'name' => :'name', :'pending_validation' => :'pending_validation', :'priority' => :'priority', + :'rsa_key_inline' => :'rsa_key_inline', + :'rsa_key_url' => :'rsa_key_url', + :'rsa_verification' => :'rsa_verification', + :'rsa_verification_status' => :'rsa_verification_status', :'slug_perm' => :'slug_perm', :'updated_at' => :'updated_at', :'upstream_url' => :'upstream_url', @@ -163,6 +179,10 @@ def self.swagger_types :'name' => :'String', :'pending_validation' => :'BOOLEAN', :'priority' => :'Integer', + :'rsa_key_inline' => :'String', + :'rsa_key_url' => :'String', + :'rsa_verification' => :'String', + :'rsa_verification_status' => :'String', :'slug_perm' => :'String', :'updated_at' => :'DateTime', :'upstream_url' => :'String', @@ -268,6 +288,26 @@ def initialize(attributes = {}) self.priority = attributes[:'priority'] end + if attributes.has_key?(:'rsa_key_inline') + self.rsa_key_inline = attributes[:'rsa_key_inline'] + end + + if attributes.has_key?(:'rsa_key_url') + self.rsa_key_url = attributes[:'rsa_key_url'] + end + + if attributes.has_key?(:'rsa_verification') + self.rsa_verification = attributes[:'rsa_verification'] + else + self.rsa_verification = 'Allow All' + end + + if attributes.has_key?(:'rsa_verification_status') + self.rsa_verification_status = attributes[:'rsa_verification_status'] + else + self.rsa_verification_status = 'Unknown' + end + if attributes.has_key?(:'slug_perm') self.slug_perm = attributes[:'slug_perm'] end @@ -305,11 +345,15 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) return false if @name.nil? + rsa_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) + return false unless rsa_verification_validator.valid?(@rsa_verification) + rsa_verification_status_validator = EnumAttributeValidator.new('String', ['Unknown', 'Invalid', 'Valid', 'Invalid (No Key)']) + return false unless rsa_verification_status_validator.valid?(@rsa_verification_status) return false if @upstream_url.nil? true end @@ -327,7 +371,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end @@ -344,6 +388,26 @@ def mode=(mode) @mode = mode end + # Custom attribute writer method checking allowed values (enum). + # @param [Object] rsa_verification Object to be assigned + def rsa_verification=(rsa_verification) + validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) + unless validator.valid?(rsa_verification) + fail ArgumentError, 'invalid value for "rsa_verification", must be one of #{validator.allowable_values}.' + end + @rsa_verification = rsa_verification + end + + # Custom attribute writer method checking allowed values (enum). + # @param [Object] rsa_verification_status Object to be assigned + def rsa_verification_status=(rsa_verification_status) + validator = EnumAttributeValidator.new('String', ['Unknown', 'Invalid', 'Valid', 'Invalid (No Key)']) + unless validator.valid?(rsa_verification_status) + fail ArgumentError, 'invalid value for "rsa_verification_status", must be one of #{validator.allowable_values}.' + end + @rsa_verification_status = rsa_verification_status + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) @@ -370,6 +434,10 @@ def ==(o) name == o.name && pending_validation == o.pending_validation && priority == o.priority && + rsa_key_inline == o.rsa_key_inline && + rsa_key_url == o.rsa_key_url && + rsa_verification == o.rsa_verification && + rsa_verification_status == o.rsa_verification_status && slug_perm == o.slug_perm && updated_at == o.updated_at && upstream_url == o.upstream_url && @@ -385,7 +453,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [auth_mode, auth_secret, auth_username, available, can_reindex, created_at, disable_reason, disable_reason_text, extra_header_1, extra_header_2, extra_value_1, extra_value_2, has_failed_signature_verification, index_package_count, index_status, is_active, last_indexed, mode, name, pending_validation, priority, slug_perm, updated_at, upstream_url, verify_ssl].hash + [auth_mode, auth_secret, auth_username, available, can_reindex, created_at, disable_reason, disable_reason_text, extra_header_1, extra_header_2, extra_value_1, extra_value_2, has_failed_signature_verification, index_package_count, index_status, is_active, last_indexed, mode, name, pending_validation, priority, rsa_key_inline, rsa_key_url, rsa_verification, rsa_verification_status, slug_perm, updated_at, upstream_url, verify_ssl].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request.rb b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request.rb index c7936be9..9bd642ab 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request.rb @@ -47,6 +47,12 @@ class AlpineUpstreamRequest # Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. attr_accessor :priority + # When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + attr_accessor :rsa_key_url + + # The RSA signature verification mode for this upstream. + attr_accessor :rsa_verification + # The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. attr_accessor :upstream_url @@ -89,6 +95,8 @@ def self.attribute_map :'mode' => :'mode', :'name' => :'name', :'priority' => :'priority', + :'rsa_key_url' => :'rsa_key_url', + :'rsa_verification' => :'rsa_verification', :'upstream_url' => :'upstream_url', :'verify_ssl' => :'verify_ssl' } @@ -108,6 +116,8 @@ def self.swagger_types :'mode' => :'String', :'name' => :'String', :'priority' => :'Integer', + :'rsa_key_url' => :'String', + :'rsa_verification' => :'String', :'upstream_url' => :'String', :'verify_ssl' => :'BOOLEAN' } @@ -169,6 +179,16 @@ def initialize(attributes = {}) self.priority = attributes[:'priority'] end + if attributes.has_key?(:'rsa_key_url') + self.rsa_key_url = attributes[:'rsa_key_url'] + end + + if attributes.has_key?(:'rsa_verification') + self.rsa_verification = attributes[:'rsa_verification'] + else + self.rsa_verification = 'Allow All' + end + if attributes.has_key?(:'upstream_url') self.upstream_url = attributes[:'upstream_url'] end @@ -201,6 +221,8 @@ def valid? mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) return false if @name.nil? + rsa_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) + return false unless rsa_verification_validator.valid?(@rsa_verification) return false if @upstream_url.nil? true end @@ -225,6 +247,16 @@ def mode=(mode) @mode = mode end + # Custom attribute writer method checking allowed values (enum). + # @param [Object] rsa_verification Object to be assigned + def rsa_verification=(rsa_verification) + validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) + unless validator.valid?(rsa_verification) + fail ArgumentError, 'invalid value for "rsa_verification", must be one of #{validator.allowable_values}.' + end + @rsa_verification = rsa_verification + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) @@ -241,6 +273,8 @@ def ==(o) mode == o.mode && name == o.name && priority == o.priority && + rsa_key_url == o.rsa_key_url && + rsa_verification == o.rsa_verification && upstream_url == o.upstream_url && verify_ssl == o.verify_ssl end @@ -254,7 +288,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [auth_mode, auth_secret, auth_username, extra_header_1, extra_header_2, extra_value_1, extra_value_2, is_active, mode, name, priority, upstream_url, verify_ssl].hash + [auth_mode, auth_secret, auth_username, extra_header_1, extra_header_2, extra_value_1, extra_value_2, is_active, mode, name, priority, rsa_key_url, rsa_verification, upstream_url, verify_ssl].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request_patch.rb b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request_patch.rb index e7d2364a..759e5b8c 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request_patch.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream_request_patch.rb @@ -47,6 +47,12 @@ class AlpineUpstreamRequestPatch # Upstream sources are selected for resolving requests by sequential order (1..n), followed by creation date. attr_accessor :priority + # When provided, Cloudsmith will fetch and validate the RSA public key at this URL and use it to verify package signatures from this upstream. + attr_accessor :rsa_key_url + + # The RSA signature verification mode for this upstream. + attr_accessor :rsa_verification + # The URL for this upstream source. This must be a fully qualified URL including any path elements required to reach the root of the repository. attr_accessor :upstream_url @@ -89,6 +95,8 @@ def self.attribute_map :'mode' => :'mode', :'name' => :'name', :'priority' => :'priority', + :'rsa_key_url' => :'rsa_key_url', + :'rsa_verification' => :'rsa_verification', :'upstream_url' => :'upstream_url', :'verify_ssl' => :'verify_ssl' } @@ -108,6 +116,8 @@ def self.swagger_types :'mode' => :'String', :'name' => :'String', :'priority' => :'Integer', + :'rsa_key_url' => :'String', + :'rsa_verification' => :'String', :'upstream_url' => :'String', :'verify_ssl' => :'BOOLEAN' } @@ -169,6 +179,16 @@ def initialize(attributes = {}) self.priority = attributes[:'priority'] end + if attributes.has_key?(:'rsa_key_url') + self.rsa_key_url = attributes[:'rsa_key_url'] + end + + if attributes.has_key?(:'rsa_verification') + self.rsa_verification = attributes[:'rsa_verification'] + else + self.rsa_verification = 'Allow All' + end + if attributes.has_key?(:'upstream_url') self.upstream_url = attributes[:'upstream_url'] end @@ -192,6 +212,8 @@ def valid? return false unless auth_mode_validator.valid?(@auth_mode) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) + rsa_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) + return false unless rsa_verification_validator.valid?(@rsa_verification) true end @@ -215,6 +237,16 @@ def mode=(mode) @mode = mode end + # Custom attribute writer method checking allowed values (enum). + # @param [Object] rsa_verification Object to be assigned + def rsa_verification=(rsa_verification) + validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) + unless validator.valid?(rsa_verification) + fail ArgumentError, 'invalid value for "rsa_verification", must be one of #{validator.allowable_values}.' + end + @rsa_verification = rsa_verification + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) @@ -231,6 +263,8 @@ def ==(o) mode == o.mode && name == o.name && priority == o.priority && + rsa_key_url == o.rsa_key_url && + rsa_verification == o.rsa_verification && upstream_url == o.upstream_url && verify_ssl == o.verify_ssl end @@ -244,7 +278,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [auth_mode, auth_secret, auth_username, extra_header_1, extra_header_2, extra_value_1, extra_value_2, is_active, mode, name, priority, upstream_url, verify_ssl].hash + [auth_mode, auth_secret, auth_username, extra_header_1, extra_header_2, extra_value_1, extra_value_2, is_active, mode, name, priority, rsa_key_url, rsa_verification, upstream_url, verify_ssl].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb index ba93b278..04968b1e 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb index feae4723..21482de2 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb index 68da02e1..e1e94c36 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb index a24badcc..402ace7b 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb index f4978343..d9d7b9a2 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb index 28b9f224..c2c489ca 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb @@ -395,7 +395,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) return false if @distro_versions.nil? gpg_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) @@ -422,7 +422,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb index 20056ded..a49d275f 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb @@ -269,7 +269,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password', 'Certificate and Key']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -291,7 +291,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb index 0838d029..1615d8cd 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb @@ -314,7 +314,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password', 'Token']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -336,7 +336,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb index 0d18f9fc..5b969776 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb index d40d3142..4df35c24 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb index 044bccb0..314fd109 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb index ef079185..8aed3692 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Token']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb index dde53ced..c6a5a6cb 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb @@ -364,7 +364,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) gpg_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) return false unless gpg_verification_validator.valid?(@gpg_verification) @@ -392,7 +392,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload.rb b/bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload.rb new file mode 100644 index 00000000..a1f7a684 --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload.rb @@ -0,0 +1,1001 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'date' + +module CloudsmithApi +class McpPackageUpload + attr_accessor :architectures + + attr_accessor :cdn_url + + attr_accessor :checksum_md5 + + attr_accessor :checksum_sha1 + + attr_accessor :checksum_sha256 + + attr_accessor :checksum_sha512 + + # A checksum of all of the package's dependencies. + attr_accessor :dependencies_checksum_md5 + + attr_accessor :dependencies_url + + # A textual description of this package. + attr_accessor :description + + attr_accessor :display_name + + attr_accessor :distro + + attr_accessor :distro_version + + attr_accessor :downloads + + # The epoch of the package version (if any). + attr_accessor :epoch + + attr_accessor :extension + + attr_accessor :filename + + attr_accessor :files + + attr_accessor :format + + attr_accessor :format_url + + # Amount of storage that will be freed if this package is deleted + attr_accessor :freeable_storage + + attr_accessor :fully_qualified_name + + # Unique and permanent identifier for the package. + attr_accessor :identifier_perm + + # Return a map of identifier field names and their values. + attr_accessor :identifiers + + attr_accessor :indexed + + attr_accessor :is_cancellable + + attr_accessor :is_copyable + + attr_accessor :is_deleteable + + attr_accessor :is_downloadable + + attr_accessor :is_moveable + + attr_accessor :is_quarantinable + + attr_accessor :is_quarantined + + attr_accessor :is_resyncable + + attr_accessor :is_security_scannable + + attr_accessor :is_sync_awaiting + + attr_accessor :is_sync_completed + + attr_accessor :is_sync_failed + + attr_accessor :is_sync_in_flight + + attr_accessor :is_sync_in_progress + + # The license of this package. + attr_accessor :license + + # The name of this package. + attr_accessor :name + + attr_accessor :namespace + + attr_accessor :namespace_url + + attr_accessor :num_files + + attr_accessor :origin_repository + + attr_accessor :origin_repository_url + + # The type of package contents. + attr_accessor :package_type + + # Whether or not the package has violated any policy. + attr_accessor :policy_violated + + # The raw license string. + attr_accessor :raw_license + + # The release of the package version (if any). + attr_accessor :release + + attr_accessor :repository + + attr_accessor :repository_url + + # The datetime the security scanning was completed. + attr_accessor :security_scan_completed_at + + # The datetime the security scanning was started. + attr_accessor :security_scan_started_at + + attr_accessor :security_scan_status + + # The datetime the security scanning status was updated. + attr_accessor :security_scan_status_updated_at + + attr_accessor :self_html_url + + attr_accessor :self_url + + attr_accessor :self_webapp_url + + attr_accessor :signature_url + + # The calculated size of the package. + attr_accessor :size + + # The public unique identifier for the package. + attr_accessor :slug + + attr_accessor :slug_perm + + # The SPDX license identifier for this package. + attr_accessor :spdx_license + + # The synchronisation (in progress) stage of the package. + attr_accessor :stage + + attr_accessor :stage_str + + # The datetime the package stage was updated at. + attr_accessor :stage_updated_at + + # The synchronisation status of the package. + attr_accessor :status + + # A textual description for the synchronous status reason (if any + attr_accessor :status_reason + + attr_accessor :status_str + + # The datetime the package status was updated at. + attr_accessor :status_updated_at + + attr_accessor :status_url + + attr_accessor :subtype + + # A one-liner synopsis of this package. + attr_accessor :summary + + # The datetime the package sync was finished at. + attr_accessor :sync_finished_at + + # Synchronisation progress (from 0-100) + attr_accessor :sync_progress + + attr_accessor :tags_automatic + + attr_accessor :tags_immutable + + attr_accessor :type_display + + # The date this package was uploaded. + attr_accessor :uploaded_at + + attr_accessor :uploader + + attr_accessor :uploader_url + + # The raw version for this package. + attr_accessor :version + + attr_accessor :version_orig + + attr_accessor :vulnerability_scan_results_url + + class EnumAttributeValidator + attr_reader :datatype + attr_reader :allowable_values + + def initialize(datatype, allowable_values) + @allowable_values = allowable_values.map do |value| + case datatype.to_s + when /Integer/i + value.to_i + when /Float/i + value.to_f + else + value + end + end + end + + def valid?(value) + !value || allowable_values.include?(value) + end + end + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'architectures' => :'architectures', + :'cdn_url' => :'cdn_url', + :'checksum_md5' => :'checksum_md5', + :'checksum_sha1' => :'checksum_sha1', + :'checksum_sha256' => :'checksum_sha256', + :'checksum_sha512' => :'checksum_sha512', + :'dependencies_checksum_md5' => :'dependencies_checksum_md5', + :'dependencies_url' => :'dependencies_url', + :'description' => :'description', + :'display_name' => :'display_name', + :'distro' => :'distro', + :'distro_version' => :'distro_version', + :'downloads' => :'downloads', + :'epoch' => :'epoch', + :'extension' => :'extension', + :'filename' => :'filename', + :'files' => :'files', + :'format' => :'format', + :'format_url' => :'format_url', + :'freeable_storage' => :'freeable_storage', + :'fully_qualified_name' => :'fully_qualified_name', + :'identifier_perm' => :'identifier_perm', + :'identifiers' => :'identifiers', + :'indexed' => :'indexed', + :'is_cancellable' => :'is_cancellable', + :'is_copyable' => :'is_copyable', + :'is_deleteable' => :'is_deleteable', + :'is_downloadable' => :'is_downloadable', + :'is_moveable' => :'is_moveable', + :'is_quarantinable' => :'is_quarantinable', + :'is_quarantined' => :'is_quarantined', + :'is_resyncable' => :'is_resyncable', + :'is_security_scannable' => :'is_security_scannable', + :'is_sync_awaiting' => :'is_sync_awaiting', + :'is_sync_completed' => :'is_sync_completed', + :'is_sync_failed' => :'is_sync_failed', + :'is_sync_in_flight' => :'is_sync_in_flight', + :'is_sync_in_progress' => :'is_sync_in_progress', + :'license' => :'license', + :'name' => :'name', + :'namespace' => :'namespace', + :'namespace_url' => :'namespace_url', + :'num_files' => :'num_files', + :'origin_repository' => :'origin_repository', + :'origin_repository_url' => :'origin_repository_url', + :'package_type' => :'package_type', + :'policy_violated' => :'policy_violated', + :'raw_license' => :'raw_license', + :'release' => :'release', + :'repository' => :'repository', + :'repository_url' => :'repository_url', + :'security_scan_completed_at' => :'security_scan_completed_at', + :'security_scan_started_at' => :'security_scan_started_at', + :'security_scan_status' => :'security_scan_status', + :'security_scan_status_updated_at' => :'security_scan_status_updated_at', + :'self_html_url' => :'self_html_url', + :'self_url' => :'self_url', + :'self_webapp_url' => :'self_webapp_url', + :'signature_url' => :'signature_url', + :'size' => :'size', + :'slug' => :'slug', + :'slug_perm' => :'slug_perm', + :'spdx_license' => :'spdx_license', + :'stage' => :'stage', + :'stage_str' => :'stage_str', + :'stage_updated_at' => :'stage_updated_at', + :'status' => :'status', + :'status_reason' => :'status_reason', + :'status_str' => :'status_str', + :'status_updated_at' => :'status_updated_at', + :'status_url' => :'status_url', + :'subtype' => :'subtype', + :'summary' => :'summary', + :'sync_finished_at' => :'sync_finished_at', + :'sync_progress' => :'sync_progress', + :'tags_automatic' => :'tags_automatic', + :'tags_immutable' => :'tags_immutable', + :'type_display' => :'type_display', + :'uploaded_at' => :'uploaded_at', + :'uploader' => :'uploader', + :'uploader_url' => :'uploader_url', + :'version' => :'version', + :'version_orig' => :'version_orig', + :'vulnerability_scan_results_url' => :'vulnerability_scan_results_url' + } + end + + # Attribute type mapping. + def self.swagger_types + { + :'architectures' => :'Array', + :'cdn_url' => :'String', + :'checksum_md5' => :'String', + :'checksum_sha1' => :'String', + :'checksum_sha256' => :'String', + :'checksum_sha512' => :'String', + :'dependencies_checksum_md5' => :'String', + :'dependencies_url' => :'String', + :'description' => :'String', + :'display_name' => :'String', + :'distro' => :'Distribution', + :'distro_version' => :'DistributionVersion', + :'downloads' => :'Integer', + :'epoch' => :'Integer', + :'extension' => :'String', + :'filename' => :'String', + :'files' => :'Array', + :'format' => :'String', + :'format_url' => :'String', + :'freeable_storage' => :'Integer', + :'fully_qualified_name' => :'String', + :'identifier_perm' => :'String', + :'identifiers' => :'Hash', + :'indexed' => :'BOOLEAN', + :'is_cancellable' => :'BOOLEAN', + :'is_copyable' => :'BOOLEAN', + :'is_deleteable' => :'BOOLEAN', + :'is_downloadable' => :'BOOLEAN', + :'is_moveable' => :'BOOLEAN', + :'is_quarantinable' => :'BOOLEAN', + :'is_quarantined' => :'BOOLEAN', + :'is_resyncable' => :'BOOLEAN', + :'is_security_scannable' => :'BOOLEAN', + :'is_sync_awaiting' => :'BOOLEAN', + :'is_sync_completed' => :'BOOLEAN', + :'is_sync_failed' => :'BOOLEAN', + :'is_sync_in_flight' => :'BOOLEAN', + :'is_sync_in_progress' => :'BOOLEAN', + :'license' => :'String', + :'name' => :'String', + :'namespace' => :'String', + :'namespace_url' => :'String', + :'num_files' => :'Integer', + :'origin_repository' => :'String', + :'origin_repository_url' => :'String', + :'package_type' => :'Integer', + :'policy_violated' => :'BOOLEAN', + :'raw_license' => :'String', + :'release' => :'String', + :'repository' => :'String', + :'repository_url' => :'String', + :'security_scan_completed_at' => :'DateTime', + :'security_scan_started_at' => :'DateTime', + :'security_scan_status' => :'String', + :'security_scan_status_updated_at' => :'DateTime', + :'self_html_url' => :'String', + :'self_url' => :'String', + :'self_webapp_url' => :'String', + :'signature_url' => :'String', + :'size' => :'Integer', + :'slug' => :'String', + :'slug_perm' => :'String', + :'spdx_license' => :'String', + :'stage' => :'Integer', + :'stage_str' => :'String', + :'stage_updated_at' => :'DateTime', + :'status' => :'Integer', + :'status_reason' => :'String', + :'status_str' => :'String', + :'status_updated_at' => :'DateTime', + :'status_url' => :'String', + :'subtype' => :'String', + :'summary' => :'String', + :'sync_finished_at' => :'DateTime', + :'sync_progress' => :'Integer', + :'tags_automatic' => :'Tags', + :'tags_immutable' => :'Tags', + :'type_display' => :'String', + :'uploaded_at' => :'DateTime', + :'uploader' => :'String', + :'uploader_url' => :'String', + :'version' => :'String', + :'version_orig' => :'String', + :'vulnerability_scan_results_url' => :'String' + } + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + return unless attributes.is_a?(Hash) + + # convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + + if attributes.has_key?(:'architectures') + if (value = attributes[:'architectures']).is_a?(Array) + self.architectures = value + end + end + + if attributes.has_key?(:'cdn_url') + self.cdn_url = attributes[:'cdn_url'] + end + + if attributes.has_key?(:'checksum_md5') + self.checksum_md5 = attributes[:'checksum_md5'] + end + + if attributes.has_key?(:'checksum_sha1') + self.checksum_sha1 = attributes[:'checksum_sha1'] + end + + if attributes.has_key?(:'checksum_sha256') + self.checksum_sha256 = attributes[:'checksum_sha256'] + end + + if attributes.has_key?(:'checksum_sha512') + self.checksum_sha512 = attributes[:'checksum_sha512'] + end + + if attributes.has_key?(:'dependencies_checksum_md5') + self.dependencies_checksum_md5 = attributes[:'dependencies_checksum_md5'] + end + + if attributes.has_key?(:'dependencies_url') + self.dependencies_url = attributes[:'dependencies_url'] + end + + if attributes.has_key?(:'description') + self.description = attributes[:'description'] + end + + if attributes.has_key?(:'display_name') + self.display_name = attributes[:'display_name'] + end + + if attributes.has_key?(:'distro') + self.distro = attributes[:'distro'] + end + + if attributes.has_key?(:'distro_version') + self.distro_version = attributes[:'distro_version'] + end + + if attributes.has_key?(:'downloads') + self.downloads = attributes[:'downloads'] + end + + if attributes.has_key?(:'epoch') + self.epoch = attributes[:'epoch'] + end + + if attributes.has_key?(:'extension') + self.extension = attributes[:'extension'] + end + + if attributes.has_key?(:'filename') + self.filename = attributes[:'filename'] + end + + if attributes.has_key?(:'files') + if (value = attributes[:'files']).is_a?(Array) + self.files = value + end + end + + if attributes.has_key?(:'format') + self.format = attributes[:'format'] + end + + if attributes.has_key?(:'format_url') + self.format_url = attributes[:'format_url'] + end + + if attributes.has_key?(:'freeable_storage') + self.freeable_storage = attributes[:'freeable_storage'] + end + + if attributes.has_key?(:'fully_qualified_name') + self.fully_qualified_name = attributes[:'fully_qualified_name'] + end + + if attributes.has_key?(:'identifier_perm') + self.identifier_perm = attributes[:'identifier_perm'] + end + + if attributes.has_key?(:'identifiers') + if (value = attributes[:'identifiers']).is_a?(Hash) + self.identifiers = value + end + end + + if attributes.has_key?(:'indexed') + self.indexed = attributes[:'indexed'] + end + + if attributes.has_key?(:'is_cancellable') + self.is_cancellable = attributes[:'is_cancellable'] + end + + if attributes.has_key?(:'is_copyable') + self.is_copyable = attributes[:'is_copyable'] + end + + if attributes.has_key?(:'is_deleteable') + self.is_deleteable = attributes[:'is_deleteable'] + end + + if attributes.has_key?(:'is_downloadable') + self.is_downloadable = attributes[:'is_downloadable'] + end + + if attributes.has_key?(:'is_moveable') + self.is_moveable = attributes[:'is_moveable'] + end + + if attributes.has_key?(:'is_quarantinable') + self.is_quarantinable = attributes[:'is_quarantinable'] + end + + if attributes.has_key?(:'is_quarantined') + self.is_quarantined = attributes[:'is_quarantined'] + end + + if attributes.has_key?(:'is_resyncable') + self.is_resyncable = attributes[:'is_resyncable'] + end + + if attributes.has_key?(:'is_security_scannable') + self.is_security_scannable = attributes[:'is_security_scannable'] + end + + if attributes.has_key?(:'is_sync_awaiting') + self.is_sync_awaiting = attributes[:'is_sync_awaiting'] + end + + if attributes.has_key?(:'is_sync_completed') + self.is_sync_completed = attributes[:'is_sync_completed'] + end + + if attributes.has_key?(:'is_sync_failed') + self.is_sync_failed = attributes[:'is_sync_failed'] + end + + if attributes.has_key?(:'is_sync_in_flight') + self.is_sync_in_flight = attributes[:'is_sync_in_flight'] + end + + if attributes.has_key?(:'is_sync_in_progress') + self.is_sync_in_progress = attributes[:'is_sync_in_progress'] + end + + if attributes.has_key?(:'license') + self.license = attributes[:'license'] + end + + if attributes.has_key?(:'name') + self.name = attributes[:'name'] + end + + if attributes.has_key?(:'namespace') + self.namespace = attributes[:'namespace'] + end + + if attributes.has_key?(:'namespace_url') + self.namespace_url = attributes[:'namespace_url'] + end + + if attributes.has_key?(:'num_files') + self.num_files = attributes[:'num_files'] + end + + if attributes.has_key?(:'origin_repository') + self.origin_repository = attributes[:'origin_repository'] + end + + if attributes.has_key?(:'origin_repository_url') + self.origin_repository_url = attributes[:'origin_repository_url'] + end + + if attributes.has_key?(:'package_type') + self.package_type = attributes[:'package_type'] + end + + if attributes.has_key?(:'policy_violated') + self.policy_violated = attributes[:'policy_violated'] + end + + if attributes.has_key?(:'raw_license') + self.raw_license = attributes[:'raw_license'] + end + + if attributes.has_key?(:'release') + self.release = attributes[:'release'] + end + + if attributes.has_key?(:'repository') + self.repository = attributes[:'repository'] + end + + if attributes.has_key?(:'repository_url') + self.repository_url = attributes[:'repository_url'] + end + + if attributes.has_key?(:'security_scan_completed_at') + self.security_scan_completed_at = attributes[:'security_scan_completed_at'] + end + + if attributes.has_key?(:'security_scan_started_at') + self.security_scan_started_at = attributes[:'security_scan_started_at'] + end + + if attributes.has_key?(:'security_scan_status') + self.security_scan_status = attributes[:'security_scan_status'] + else + self.security_scan_status = 'Awaiting Security Scan' + end + + if attributes.has_key?(:'security_scan_status_updated_at') + self.security_scan_status_updated_at = attributes[:'security_scan_status_updated_at'] + end + + if attributes.has_key?(:'self_html_url') + self.self_html_url = attributes[:'self_html_url'] + end + + if attributes.has_key?(:'self_url') + self.self_url = attributes[:'self_url'] + end + + if attributes.has_key?(:'self_webapp_url') + self.self_webapp_url = attributes[:'self_webapp_url'] + end + + if attributes.has_key?(:'signature_url') + self.signature_url = attributes[:'signature_url'] + end + + if attributes.has_key?(:'size') + self.size = attributes[:'size'] + end + + if attributes.has_key?(:'slug') + self.slug = attributes[:'slug'] + end + + if attributes.has_key?(:'slug_perm') + self.slug_perm = attributes[:'slug_perm'] + end + + if attributes.has_key?(:'spdx_license') + self.spdx_license = attributes[:'spdx_license'] + end + + if attributes.has_key?(:'stage') + self.stage = attributes[:'stage'] + end + + if attributes.has_key?(:'stage_str') + self.stage_str = attributes[:'stage_str'] + end + + if attributes.has_key?(:'stage_updated_at') + self.stage_updated_at = attributes[:'stage_updated_at'] + end + + if attributes.has_key?(:'status') + self.status = attributes[:'status'] + end + + if attributes.has_key?(:'status_reason') + self.status_reason = attributes[:'status_reason'] + end + + if attributes.has_key?(:'status_str') + self.status_str = attributes[:'status_str'] + end + + if attributes.has_key?(:'status_updated_at') + self.status_updated_at = attributes[:'status_updated_at'] + end + + if attributes.has_key?(:'status_url') + self.status_url = attributes[:'status_url'] + end + + if attributes.has_key?(:'subtype') + self.subtype = attributes[:'subtype'] + end + + if attributes.has_key?(:'summary') + self.summary = attributes[:'summary'] + end + + if attributes.has_key?(:'sync_finished_at') + self.sync_finished_at = attributes[:'sync_finished_at'] + end + + if attributes.has_key?(:'sync_progress') + self.sync_progress = attributes[:'sync_progress'] + end + + if attributes.has_key?(:'tags_automatic') + self.tags_automatic = attributes[:'tags_automatic'] + end + + if attributes.has_key?(:'tags_immutable') + self.tags_immutable = attributes[:'tags_immutable'] + end + + if attributes.has_key?(:'type_display') + self.type_display = attributes[:'type_display'] + end + + if attributes.has_key?(:'uploaded_at') + self.uploaded_at = attributes[:'uploaded_at'] + end + + if attributes.has_key?(:'uploader') + self.uploader = attributes[:'uploader'] + end + + if attributes.has_key?(:'uploader_url') + self.uploader_url = attributes[:'uploader_url'] + end + + if attributes.has_key?(:'version') + self.version = attributes[:'version'] + end + + if attributes.has_key?(:'version_orig') + self.version_orig = attributes[:'version_orig'] + end + + if attributes.has_key?(:'vulnerability_scan_results_url') + self.vulnerability_scan_results_url = attributes[:'vulnerability_scan_results_url'] + end + end + + # Show invalid properties with the reasons. Usually used together with valid? + # @return Array for valid properties with the reasons + def list_invalid_properties + invalid_properties = Array.new + invalid_properties + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + def valid? + security_scan_status_validator = EnumAttributeValidator.new('String', ['Awaiting Security Scan', 'Security Scanning in Progress', 'Scan Detected Vulnerabilities', 'Scan Detected No Vulnerabilities', 'Security Scanning Disabled', 'Security Scanning Failed', 'Security Scanning Skipped', 'Security Scanning Not Supported']) + return false unless security_scan_status_validator.valid?(@security_scan_status) + true + end + + # Custom attribute writer method checking allowed values (enum). + # @param [Object] security_scan_status Object to be assigned + def security_scan_status=(security_scan_status) + validator = EnumAttributeValidator.new('String', ['Awaiting Security Scan', 'Security Scanning in Progress', 'Scan Detected Vulnerabilities', 'Scan Detected No Vulnerabilities', 'Security Scanning Disabled', 'Security Scanning Failed', 'Security Scanning Skipped', 'Security Scanning Not Supported']) + unless validator.valid?(security_scan_status) + fail ArgumentError, 'invalid value for "security_scan_status", must be one of #{validator.allowable_values}.' + end + @security_scan_status = security_scan_status + end + + # Checks equality by comparing each attribute. + # @param [Object] Object to be compared + def ==(o) + return true if self.equal?(o) + self.class == o.class && + architectures == o.architectures && + cdn_url == o.cdn_url && + checksum_md5 == o.checksum_md5 && + checksum_sha1 == o.checksum_sha1 && + checksum_sha256 == o.checksum_sha256 && + checksum_sha512 == o.checksum_sha512 && + dependencies_checksum_md5 == o.dependencies_checksum_md5 && + dependencies_url == o.dependencies_url && + description == o.description && + display_name == o.display_name && + distro == o.distro && + distro_version == o.distro_version && + downloads == o.downloads && + epoch == o.epoch && + extension == o.extension && + filename == o.filename && + files == o.files && + format == o.format && + format_url == o.format_url && + freeable_storage == o.freeable_storage && + fully_qualified_name == o.fully_qualified_name && + identifier_perm == o.identifier_perm && + identifiers == o.identifiers && + indexed == o.indexed && + is_cancellable == o.is_cancellable && + is_copyable == o.is_copyable && + is_deleteable == o.is_deleteable && + is_downloadable == o.is_downloadable && + is_moveable == o.is_moveable && + is_quarantinable == o.is_quarantinable && + is_quarantined == o.is_quarantined && + is_resyncable == o.is_resyncable && + is_security_scannable == o.is_security_scannable && + is_sync_awaiting == o.is_sync_awaiting && + is_sync_completed == o.is_sync_completed && + is_sync_failed == o.is_sync_failed && + is_sync_in_flight == o.is_sync_in_flight && + is_sync_in_progress == o.is_sync_in_progress && + license == o.license && + name == o.name && + namespace == o.namespace && + namespace_url == o.namespace_url && + num_files == o.num_files && + origin_repository == o.origin_repository && + origin_repository_url == o.origin_repository_url && + package_type == o.package_type && + policy_violated == o.policy_violated && + raw_license == o.raw_license && + release == o.release && + repository == o.repository && + repository_url == o.repository_url && + security_scan_completed_at == o.security_scan_completed_at && + security_scan_started_at == o.security_scan_started_at && + security_scan_status == o.security_scan_status && + security_scan_status_updated_at == o.security_scan_status_updated_at && + self_html_url == o.self_html_url && + self_url == o.self_url && + self_webapp_url == o.self_webapp_url && + signature_url == o.signature_url && + size == o.size && + slug == o.slug && + slug_perm == o.slug_perm && + spdx_license == o.spdx_license && + stage == o.stage && + stage_str == o.stage_str && + stage_updated_at == o.stage_updated_at && + status == o.status && + status_reason == o.status_reason && + status_str == o.status_str && + status_updated_at == o.status_updated_at && + status_url == o.status_url && + subtype == o.subtype && + summary == o.summary && + sync_finished_at == o.sync_finished_at && + sync_progress == o.sync_progress && + tags_automatic == o.tags_automatic && + tags_immutable == o.tags_immutable && + type_display == o.type_display && + uploaded_at == o.uploaded_at && + uploader == o.uploader && + uploader_url == o.uploader_url && + version == o.version && + version_orig == o.version_orig && + vulnerability_scan_results_url == o.vulnerability_scan_results_url + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Fixnum] Hash code + def hash + [architectures, cdn_url, checksum_md5, checksum_sha1, checksum_sha256, checksum_sha512, dependencies_checksum_md5, dependencies_url, description, display_name, distro, distro_version, downloads, epoch, extension, filename, files, format, format_url, freeable_storage, fully_qualified_name, identifier_perm, identifiers, indexed, is_cancellable, is_copyable, is_deleteable, is_downloadable, is_moveable, is_quarantinable, is_quarantined, is_resyncable, is_security_scannable, is_sync_awaiting, is_sync_completed, is_sync_failed, is_sync_in_flight, is_sync_in_progress, license, name, namespace, namespace_url, num_files, origin_repository, origin_repository_url, package_type, policy_violated, raw_license, release, repository, repository_url, security_scan_completed_at, security_scan_started_at, security_scan_status, security_scan_status_updated_at, self_html_url, self_url, self_webapp_url, signature_url, size, slug, slug_perm, spdx_license, stage, stage_str, stage_updated_at, status, status_reason, status_str, status_updated_at, status_url, subtype, summary, sync_finished_at, sync_progress, tags_automatic, tags_immutable, type_display, uploaded_at, uploader, uploader_url, version, version_orig, vulnerability_scan_results_url].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def build_from_hash(attributes) + return nil unless attributes.is_a?(Hash) + self.class.swagger_types.each_pair do |key, type| + if type =~ /\AArray<(.*)>/i + # check to ensure the input is an array given that the attribute + # is documented as an array but the input is not + if attributes[self.class.attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[self.class.attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) + end # or else data not found in attributes(hash), not an issue as the data can be optional + end + + self + end + + # Deserializes the data based on type + # @param string type Data type + # @param string value Value to be deserialized + # @return [Object] Deserialized data + def _deserialize(type, value) + case type.to_sym + when :DateTime + DateTime.parse(value) + when :Date + Date.parse(value) + when :String + value.to_s + when :Integer + value.to_i + when :Float + value.to_f + when :BOOLEAN + if value.to_s =~ /\A(true|t|yes|y|1)\z/i + true + else + false + end + when :Object + # generic object (usually a Hash), return directly + value + when /\AArray<(?.+)>\z/ + inner_type = Regexp.last_match[:inner_type] + value.map { |v| _deserialize(inner_type, v) } + when /\AHash<(?.+?), (?.+)>\z/ + k_type = Regexp.last_match[:k_type] + v_type = Regexp.last_match[:v_type] + {}.tap do |hash| + value.each do |k, v| + hash[_deserialize(k_type, k)] = _deserialize(v_type, v) + end + end + else # model + temp_model = CloudsmithApi.const_get(type).new + temp_model.build_from_hash(value) + end + end + + # Returns the string representation of the object + # @return [String] String presentation of the object + def to_s + to_hash.to_s + end + + # to_body is an alias to to_hash (backward compatibility) + # @return [Hash] Returns the object in the form of hash + def to_body + to_hash + end + + # Returns the object in the form of hash + # @return [Hash] Returns the object in the form of hash + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + next if value.nil? + hash[param] = _to_hash(value) + end + hash + end + + # Outputs non-array value in the form of hash + # For object, use to_hash. Otherwise, just return the value + # @param [Object] value Any valid value + # @return [Hash] Returns the value in the form of hash + def _to_hash(value) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v) } + end + elsif value.respond_to? :to_hash + value.to_hash + else + value + end + end + +end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload_request.rb b/bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload_request.rb new file mode 100644 index 00000000..3fceb8d5 --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/models/mcp_package_upload_request.rb @@ -0,0 +1,220 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'date' + +module CloudsmithApi +class McpPackageUploadRequest + # The primary file for the package. + attr_accessor :package_file + + # If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. + attr_accessor :republish + + # A comma-separated values list of tags to add to the package. + attr_accessor :tags + + # The raw version for this package. + attr_accessor :version + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'package_file' => :'package_file', + :'republish' => :'republish', + :'tags' => :'tags', + :'version' => :'version' + } + end + + # Attribute type mapping. + def self.swagger_types + { + :'package_file' => :'String', + :'republish' => :'BOOLEAN', + :'tags' => :'String', + :'version' => :'String' + } + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + return unless attributes.is_a?(Hash) + + # convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + + if attributes.has_key?(:'package_file') + self.package_file = attributes[:'package_file'] + end + + if attributes.has_key?(:'republish') + self.republish = attributes[:'republish'] + end + + if attributes.has_key?(:'tags') + self.tags = attributes[:'tags'] + end + + if attributes.has_key?(:'version') + self.version = attributes[:'version'] + end + end + + # Show invalid properties with the reasons. Usually used together with valid? + # @return Array for valid properties with the reasons + def list_invalid_properties + invalid_properties = Array.new + if @package_file.nil? + invalid_properties.push('invalid value for "package_file", package_file cannot be nil.') + end + + invalid_properties + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + def valid? + return false if @package_file.nil? + true + end + + # Checks equality by comparing each attribute. + # @param [Object] Object to be compared + def ==(o) + return true if self.equal?(o) + self.class == o.class && + package_file == o.package_file && + republish == o.republish && + tags == o.tags && + version == o.version + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Fixnum] Hash code + def hash + [package_file, republish, tags, version].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def build_from_hash(attributes) + return nil unless attributes.is_a?(Hash) + self.class.swagger_types.each_pair do |key, type| + if type =~ /\AArray<(.*)>/i + # check to ensure the input is an array given that the attribute + # is documented as an array but the input is not + if attributes[self.class.attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[self.class.attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) + end # or else data not found in attributes(hash), not an issue as the data can be optional + end + + self + end + + # Deserializes the data based on type + # @param string type Data type + # @param string value Value to be deserialized + # @return [Object] Deserialized data + def _deserialize(type, value) + case type.to_sym + when :DateTime + DateTime.parse(value) + when :Date + Date.parse(value) + when :String + value.to_s + when :Integer + value.to_i + when :Float + value.to_f + when :BOOLEAN + if value.to_s =~ /\A(true|t|yes|y|1)\z/i + true + else + false + end + when :Object + # generic object (usually a Hash), return directly + value + when /\AArray<(?.+)>\z/ + inner_type = Regexp.last_match[:inner_type] + value.map { |v| _deserialize(inner_type, v) } + when /\AHash<(?.+?), (?.+)>\z/ + k_type = Regexp.last_match[:k_type] + v_type = Regexp.last_match[:v_type] + {}.tap do |hash| + value.each do |k, v| + hash[_deserialize(k_type, k)] = _deserialize(v_type, v) + end + end + else # model + temp_model = CloudsmithApi.const_get(type).new + temp_model.build_from_hash(value) + end + end + + # Returns the string representation of the object + # @return [String] String presentation of the object + def to_s + to_hash.to_s + end + + # to_body is an alias to to_hash (backward compatibility) + # @return [Hash] Returns the object in the form of hash + def to_body + to_hash + end + + # Returns the object in the form of hash + # @return [Hash] Returns the object in the form of hash + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + next if value.nil? + hash[param] = _to_hash(value) + end + hash + end + + # Outputs non-array value in the form of hash + # For object, use to_hash. Otherwise, just return the value + # @param [Object] value Any valid value + # @return [Hash] Returns the value in the form of hash + def _to_hash(value) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v) } + end + elsif value.respond_to? :to_hash + value.to_hash + else + value + end + end + +end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb index c1162564..f843d07a 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb @@ -316,7 +316,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password', 'Token']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -340,7 +340,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb index d27c2184..69367424 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/package_recycle_bin.rb b/bindings/ruby/src/lib/cloudsmith-api/models/package_recycle_bin.rb new file mode 100644 index 00000000..e84a5741 --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/models/package_recycle_bin.rb @@ -0,0 +1,251 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'date' + +module CloudsmithApi +class PackageRecycleBin + # The action to perform on soft-deleted packages. + attr_accessor :action + + # A list of soft-deleted package identifiers to action. + attr_accessor :identifiers + + # The repository name to filter packages to. If not provided, the action will be performed across all accessible repositories in the workspace. + attr_accessor :repository + + class EnumAttributeValidator + attr_reader :datatype + attr_reader :allowable_values + + def initialize(datatype, allowable_values) + @allowable_values = allowable_values.map do |value| + case datatype.to_s + when /Integer/i + value.to_i + when /Float/i + value.to_f + else + value + end + end + end + + def valid?(value) + !value || allowable_values.include?(value) + end + end + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'action' => :'action', + :'identifiers' => :'identifiers', + :'repository' => :'repository' + } + end + + # Attribute type mapping. + def self.swagger_types + { + :'action' => :'String', + :'identifiers' => :'Array', + :'repository' => :'String' + } + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + return unless attributes.is_a?(Hash) + + # convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + + if attributes.has_key?(:'action') + self.action = attributes[:'action'] + end + + if attributes.has_key?(:'identifiers') + if (value = attributes[:'identifiers']).is_a?(Array) + self.identifiers = value + end + end + + if attributes.has_key?(:'repository') + self.repository = attributes[:'repository'] + end + end + + # Show invalid properties with the reasons. Usually used together with valid? + # @return Array for valid properties with the reasons + def list_invalid_properties + invalid_properties = Array.new + if @action.nil? + invalid_properties.push('invalid value for "action", action cannot be nil.') + end + + if @identifiers.nil? + invalid_properties.push('invalid value for "identifiers", identifiers cannot be nil.') + end + + invalid_properties + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + def valid? + return false if @action.nil? + action_validator = EnumAttributeValidator.new('String', ['hard_delete', 'restore']) + return false unless action_validator.valid?(@action) + return false if @identifiers.nil? + true + end + + # Custom attribute writer method checking allowed values (enum). + # @param [Object] action Object to be assigned + def action=(action) + validator = EnumAttributeValidator.new('String', ['hard_delete', 'restore']) + unless validator.valid?(action) + fail ArgumentError, 'invalid value for "action", must be one of #{validator.allowable_values}.' + end + @action = action + end + + # Checks equality by comparing each attribute. + # @param [Object] Object to be compared + def ==(o) + return true if self.equal?(o) + self.class == o.class && + action == o.action && + identifiers == o.identifiers && + repository == o.repository + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Fixnum] Hash code + def hash + [action, identifiers, repository].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def build_from_hash(attributes) + return nil unless attributes.is_a?(Hash) + self.class.swagger_types.each_pair do |key, type| + if type =~ /\AArray<(.*)>/i + # check to ensure the input is an array given that the attribute + # is documented as an array but the input is not + if attributes[self.class.attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[self.class.attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) + end # or else data not found in attributes(hash), not an issue as the data can be optional + end + + self + end + + # Deserializes the data based on type + # @param string type Data type + # @param string value Value to be deserialized + # @return [Object] Deserialized data + def _deserialize(type, value) + case type.to_sym + when :DateTime + DateTime.parse(value) + when :Date + Date.parse(value) + when :String + value.to_s + when :Integer + value.to_i + when :Float + value.to_f + when :BOOLEAN + if value.to_s =~ /\A(true|t|yes|y|1)\z/i + true + else + false + end + when :Object + # generic object (usually a Hash), return directly + value + when /\AArray<(?.+)>\z/ + inner_type = Regexp.last_match[:inner_type] + value.map { |v| _deserialize(inner_type, v) } + when /\AHash<(?.+?), (?.+)>\z/ + k_type = Regexp.last_match[:k_type] + v_type = Regexp.last_match[:v_type] + {}.tap do |hash| + value.each do |k, v| + hash[_deserialize(k_type, k)] = _deserialize(v_type, v) + end + end + else # model + temp_model = CloudsmithApi.const_get(type).new + temp_model.build_from_hash(value) + end + end + + # Returns the string representation of the object + # @return [String] String presentation of the object + def to_s + to_hash.to_s + end + + # to_body is an alias to to_hash (backward compatibility) + # @return [Hash] Returns the object in the form of hash + def to_body + to_hash + end + + # Returns the object in the form of hash + # @return [Hash] Returns the object in the form of hash + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + next if value.nil? + hash[param] = _to_hash(value) + end + hash + end + + # Outputs non-array value in the form of hash + # For object, use to_hash. Otherwise, just return the value + # @param [Object] value Any valid value + # @return [Hash] Returns the value in the form of hash + def _to_hash(value) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v) } + end + elsif value.respond_to? :to_hash + value.to_hash + else + value + end + end + +end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb index 0797c3af..430e2ce6 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb @@ -316,7 +316,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -340,7 +340,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/recycle_bin_package.rb b/bindings/ruby/src/lib/cloudsmith-api/models/recycle_bin_package.rb new file mode 100644 index 00000000..7e27293d --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/models/recycle_bin_package.rb @@ -0,0 +1,442 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'date' + +module CloudsmithApi +class RecycleBinPackage + # The name of the user who deleted the package. + attr_accessor :action_by + + attr_accessor :downloads + + attr_accessor :filename + + attr_accessor :format + + # The fully qualified name of the package. + attr_accessor :fully_qualified_name + + attr_accessor :identifiers + + # Information about the retention rule that triggered deletion (if any). + attr_accessor :invoked_retention_rule + + attr_accessor :is_deleteable + + attr_accessor :is_quarantined + + attr_accessor :is_restorable + + # The name of this package. + attr_accessor :name + + # Whether or not the package has violated any policy. + attr_accessor :policy_violated + + attr_accessor :repository + + # The datetime the security scanning was completed. + attr_accessor :security_scan_completed_at + + attr_accessor :security_scan_status + + # The calculated size of the package. + attr_accessor :size + + attr_accessor :slug_perm + + # The synchronisation status of the package. + attr_accessor :status + + # The datetime the package status was updated at. + attr_accessor :status_updated_at + + attr_accessor :tags + + attr_accessor :type_display + + # The date this package was uploaded. + attr_accessor :uploaded_at + + attr_accessor :uploader + + # The raw version for this package. + attr_accessor :version + + class EnumAttributeValidator + attr_reader :datatype + attr_reader :allowable_values + + def initialize(datatype, allowable_values) + @allowable_values = allowable_values.map do |value| + case datatype.to_s + when /Integer/i + value.to_i + when /Float/i + value.to_f + else + value + end + end + end + + def valid?(value) + !value || allowable_values.include?(value) + end + end + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'action_by' => :'action_by', + :'downloads' => :'downloads', + :'filename' => :'filename', + :'format' => :'format', + :'fully_qualified_name' => :'fully_qualified_name', + :'identifiers' => :'identifiers', + :'invoked_retention_rule' => :'invoked_retention_rule', + :'is_deleteable' => :'is_deleteable', + :'is_quarantined' => :'is_quarantined', + :'is_restorable' => :'is_restorable', + :'name' => :'name', + :'policy_violated' => :'policy_violated', + :'repository' => :'repository', + :'security_scan_completed_at' => :'security_scan_completed_at', + :'security_scan_status' => :'security_scan_status', + :'size' => :'size', + :'slug_perm' => :'slug_perm', + :'status' => :'status', + :'status_updated_at' => :'status_updated_at', + :'tags' => :'tags', + :'type_display' => :'type_display', + :'uploaded_at' => :'uploaded_at', + :'uploader' => :'uploader', + :'version' => :'version' + } + end + + # Attribute type mapping. + def self.swagger_types + { + :'action_by' => :'String', + :'downloads' => :'Integer', + :'filename' => :'String', + :'format' => :'String', + :'fully_qualified_name' => :'String', + :'identifiers' => :'Hash', + :'invoked_retention_rule' => :'Hash', + :'is_deleteable' => :'BOOLEAN', + :'is_quarantined' => :'BOOLEAN', + :'is_restorable' => :'BOOLEAN', + :'name' => :'String', + :'policy_violated' => :'BOOLEAN', + :'repository' => :'String', + :'security_scan_completed_at' => :'DateTime', + :'security_scan_status' => :'String', + :'size' => :'Integer', + :'slug_perm' => :'String', + :'status' => :'Integer', + :'status_updated_at' => :'DateTime', + :'tags' => :'Tags', + :'type_display' => :'String', + :'uploaded_at' => :'DateTime', + :'uploader' => :'String', + :'version' => :'String' + } + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + return unless attributes.is_a?(Hash) + + # convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + + if attributes.has_key?(:'action_by') + self.action_by = attributes[:'action_by'] + end + + if attributes.has_key?(:'downloads') + self.downloads = attributes[:'downloads'] + end + + if attributes.has_key?(:'filename') + self.filename = attributes[:'filename'] + end + + if attributes.has_key?(:'format') + self.format = attributes[:'format'] + end + + if attributes.has_key?(:'fully_qualified_name') + self.fully_qualified_name = attributes[:'fully_qualified_name'] + end + + if attributes.has_key?(:'identifiers') + if (value = attributes[:'identifiers']).is_a?(Hash) + self.identifiers = value + end + end + + if attributes.has_key?(:'invoked_retention_rule') + if (value = attributes[:'invoked_retention_rule']).is_a?(Hash) + self.invoked_retention_rule = value + end + end + + if attributes.has_key?(:'is_deleteable') + self.is_deleteable = attributes[:'is_deleteable'] + end + + if attributes.has_key?(:'is_quarantined') + self.is_quarantined = attributes[:'is_quarantined'] + end + + if attributes.has_key?(:'is_restorable') + self.is_restorable = attributes[:'is_restorable'] + end + + if attributes.has_key?(:'name') + self.name = attributes[:'name'] + end + + if attributes.has_key?(:'policy_violated') + self.policy_violated = attributes[:'policy_violated'] + end + + if attributes.has_key?(:'repository') + self.repository = attributes[:'repository'] + end + + if attributes.has_key?(:'security_scan_completed_at') + self.security_scan_completed_at = attributes[:'security_scan_completed_at'] + end + + if attributes.has_key?(:'security_scan_status') + self.security_scan_status = attributes[:'security_scan_status'] + else + self.security_scan_status = 'Awaiting Security Scan' + end + + if attributes.has_key?(:'size') + self.size = attributes[:'size'] + end + + if attributes.has_key?(:'slug_perm') + self.slug_perm = attributes[:'slug_perm'] + end + + if attributes.has_key?(:'status') + self.status = attributes[:'status'] + end + + if attributes.has_key?(:'status_updated_at') + self.status_updated_at = attributes[:'status_updated_at'] + end + + if attributes.has_key?(:'tags') + self.tags = attributes[:'tags'] + end + + if attributes.has_key?(:'type_display') + self.type_display = attributes[:'type_display'] + end + + if attributes.has_key?(:'uploaded_at') + self.uploaded_at = attributes[:'uploaded_at'] + end + + if attributes.has_key?(:'uploader') + self.uploader = attributes[:'uploader'] + end + + if attributes.has_key?(:'version') + self.version = attributes[:'version'] + end + end + + # Show invalid properties with the reasons. Usually used together with valid? + # @return Array for valid properties with the reasons + def list_invalid_properties + invalid_properties = Array.new + invalid_properties + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + def valid? + security_scan_status_validator = EnumAttributeValidator.new('String', ['Awaiting Security Scan', 'Security Scanning in Progress', 'Scan Detected Vulnerabilities', 'Scan Detected No Vulnerabilities', 'Security Scanning Disabled', 'Security Scanning Failed', 'Security Scanning Skipped', 'Security Scanning Not Supported']) + return false unless security_scan_status_validator.valid?(@security_scan_status) + true + end + + # Custom attribute writer method checking allowed values (enum). + # @param [Object] security_scan_status Object to be assigned + def security_scan_status=(security_scan_status) + validator = EnumAttributeValidator.new('String', ['Awaiting Security Scan', 'Security Scanning in Progress', 'Scan Detected Vulnerabilities', 'Scan Detected No Vulnerabilities', 'Security Scanning Disabled', 'Security Scanning Failed', 'Security Scanning Skipped', 'Security Scanning Not Supported']) + unless validator.valid?(security_scan_status) + fail ArgumentError, 'invalid value for "security_scan_status", must be one of #{validator.allowable_values}.' + end + @security_scan_status = security_scan_status + end + + # Checks equality by comparing each attribute. + # @param [Object] Object to be compared + def ==(o) + return true if self.equal?(o) + self.class == o.class && + action_by == o.action_by && + downloads == o.downloads && + filename == o.filename && + format == o.format && + fully_qualified_name == o.fully_qualified_name && + identifiers == o.identifiers && + invoked_retention_rule == o.invoked_retention_rule && + is_deleteable == o.is_deleteable && + is_quarantined == o.is_quarantined && + is_restorable == o.is_restorable && + name == o.name && + policy_violated == o.policy_violated && + repository == o.repository && + security_scan_completed_at == o.security_scan_completed_at && + security_scan_status == o.security_scan_status && + size == o.size && + slug_perm == o.slug_perm && + status == o.status && + status_updated_at == o.status_updated_at && + tags == o.tags && + type_display == o.type_display && + uploaded_at == o.uploaded_at && + uploader == o.uploader && + version == o.version + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Fixnum] Hash code + def hash + [action_by, downloads, filename, format, fully_qualified_name, identifiers, invoked_retention_rule, is_deleteable, is_quarantined, is_restorable, name, policy_violated, repository, security_scan_completed_at, security_scan_status, size, slug_perm, status, status_updated_at, tags, type_display, uploaded_at, uploader, version].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def build_from_hash(attributes) + return nil unless attributes.is_a?(Hash) + self.class.swagger_types.each_pair do |key, type| + if type =~ /\AArray<(.*)>/i + # check to ensure the input is an array given that the attribute + # is documented as an array but the input is not + if attributes[self.class.attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[self.class.attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) + end # or else data not found in attributes(hash), not an issue as the data can be optional + end + + self + end + + # Deserializes the data based on type + # @param string type Data type + # @param string value Value to be deserialized + # @return [Object] Deserialized data + def _deserialize(type, value) + case type.to_sym + when :DateTime + DateTime.parse(value) + when :Date + Date.parse(value) + when :String + value.to_s + when :Integer + value.to_i + when :Float + value.to_f + when :BOOLEAN + if value.to_s =~ /\A(true|t|yes|y|1)\z/i + true + else + false + end + when :Object + # generic object (usually a Hash), return directly + value + when /\AArray<(?.+)>\z/ + inner_type = Regexp.last_match[:inner_type] + value.map { |v| _deserialize(inner_type, v) } + when /\AHash<(?.+?), (?.+)>\z/ + k_type = Regexp.last_match[:k_type] + v_type = Regexp.last_match[:v_type] + {}.tap do |hash| + value.each do |k, v| + hash[_deserialize(k_type, k)] = _deserialize(v_type, v) + end + end + else # model + temp_model = CloudsmithApi.const_get(type).new + temp_model.build_from_hash(value) + end + end + + # Returns the string representation of the object + # @return [String] String presentation of the object + def to_s + to_hash.to_s + end + + # to_body is an alias to to_hash (backward compatibility) + # @return [Hash] Returns the object in the form of hash + def to_body + to_hash + end + + # Returns the object in the form of hash + # @return [Hash] Returns the object in the form of hash + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + next if value.nil? + hash[param] = _to_hash(value) + end + hash + end + + # Outputs non-array value in the form of hash + # For object, use to_hash. Otherwise, just return the value + # @param [Object] value Any valid value + # @return [Hash] Returns the value in the form of hash + def _to_hash(value) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v) } + end + elsif value.respond_to? :to_hash + value.to_hash + else + value + end + end + +end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts.rb b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts.rb new file mode 100644 index 00000000..6e505299 --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts.rb @@ -0,0 +1,190 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'date' + +module CloudsmithApi +class RepositoryTokenPrivateBroadcasts + # Whether the token should have access to private broadcasts. + attr_accessor :access_private_broadcasts + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'access_private_broadcasts' => :'access_private_broadcasts' + } + end + + # Attribute type mapping. + def self.swagger_types + { + :'access_private_broadcasts' => :'BOOLEAN' + } + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + return unless attributes.is_a?(Hash) + + # convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + + if attributes.has_key?(:'access_private_broadcasts') + self.access_private_broadcasts = attributes[:'access_private_broadcasts'] + end + end + + # Show invalid properties with the reasons. Usually used together with valid? + # @return Array for valid properties with the reasons + def list_invalid_properties + invalid_properties = Array.new + if @access_private_broadcasts.nil? + invalid_properties.push('invalid value for "access_private_broadcasts", access_private_broadcasts cannot be nil.') + end + + invalid_properties + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + def valid? + return false if @access_private_broadcasts.nil? + true + end + + # Checks equality by comparing each attribute. + # @param [Object] Object to be compared + def ==(o) + return true if self.equal?(o) + self.class == o.class && + access_private_broadcasts == o.access_private_broadcasts + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Fixnum] Hash code + def hash + [access_private_broadcasts].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def build_from_hash(attributes) + return nil unless attributes.is_a?(Hash) + self.class.swagger_types.each_pair do |key, type| + if type =~ /\AArray<(.*)>/i + # check to ensure the input is an array given that the attribute + # is documented as an array but the input is not + if attributes[self.class.attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[self.class.attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) + end # or else data not found in attributes(hash), not an issue as the data can be optional + end + + self + end + + # Deserializes the data based on type + # @param string type Data type + # @param string value Value to be deserialized + # @return [Object] Deserialized data + def _deserialize(type, value) + case type.to_sym + when :DateTime + DateTime.parse(value) + when :Date + Date.parse(value) + when :String + value.to_s + when :Integer + value.to_i + when :Float + value.to_f + when :BOOLEAN + if value.to_s =~ /\A(true|t|yes|y|1)\z/i + true + else + false + end + when :Object + # generic object (usually a Hash), return directly + value + when /\AArray<(?.+)>\z/ + inner_type = Regexp.last_match[:inner_type] + value.map { |v| _deserialize(inner_type, v) } + when /\AHash<(?.+?), (?.+)>\z/ + k_type = Regexp.last_match[:k_type] + v_type = Regexp.last_match[:v_type] + {}.tap do |hash| + value.each do |k, v| + hash[_deserialize(k_type, k)] = _deserialize(v_type, v) + end + end + else # model + temp_model = CloudsmithApi.const_get(type).new + temp_model.build_from_hash(value) + end + end + + # Returns the string representation of the object + # @return [String] String presentation of the object + def to_s + to_hash.to_s + end + + # to_body is an alias to to_hash (backward compatibility) + # @return [Hash] Returns the object in the form of hash + def to_body + to_hash + end + + # Returns the object in the form of hash + # @return [Hash] Returns the object in the form of hash + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + next if value.nil? + hash[param] = _to_hash(value) + end + hash + end + + # Outputs non-array value in the form of hash + # For object, use to_hash. Otherwise, just return the value + # @param [Object] value Any valid value + # @return [Hash] Returns the value in the form of hash + def _to_hash(value) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v) } + end + elsif value.respond_to? :to_hash + value.to_hash + else + value + end + end + +end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts_request.rb b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts_request.rb new file mode 100644 index 00000000..47a6d42d --- /dev/null +++ b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_private_broadcasts_request.rb @@ -0,0 +1,190 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'date' + +module CloudsmithApi +class RepositoryTokenPrivateBroadcastsRequest + # Whether the token should have access to private broadcasts. + attr_accessor :access_private_broadcasts + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'access_private_broadcasts' => :'access_private_broadcasts' + } + end + + # Attribute type mapping. + def self.swagger_types + { + :'access_private_broadcasts' => :'BOOLEAN' + } + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + return unless attributes.is_a?(Hash) + + # convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + + if attributes.has_key?(:'access_private_broadcasts') + self.access_private_broadcasts = attributes[:'access_private_broadcasts'] + end + end + + # Show invalid properties with the reasons. Usually used together with valid? + # @return Array for valid properties with the reasons + def list_invalid_properties + invalid_properties = Array.new + if @access_private_broadcasts.nil? + invalid_properties.push('invalid value for "access_private_broadcasts", access_private_broadcasts cannot be nil.') + end + + invalid_properties + end + + # Check to see if the all the properties in the model are valid + # @return true if the model is valid + def valid? + return false if @access_private_broadcasts.nil? + true + end + + # Checks equality by comparing each attribute. + # @param [Object] Object to be compared + def ==(o) + return true if self.equal?(o) + self.class == o.class && + access_private_broadcasts == o.access_private_broadcasts + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Fixnum] Hash code + def hash + [access_private_broadcasts].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def build_from_hash(attributes) + return nil unless attributes.is_a?(Hash) + self.class.swagger_types.each_pair do |key, type| + if type =~ /\AArray<(.*)>/i + # check to ensure the input is an array given that the attribute + # is documented as an array but the input is not + if attributes[self.class.attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[self.class.attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) + end # or else data not found in attributes(hash), not an issue as the data can be optional + end + + self + end + + # Deserializes the data based on type + # @param string type Data type + # @param string value Value to be deserialized + # @return [Object] Deserialized data + def _deserialize(type, value) + case type.to_sym + when :DateTime + DateTime.parse(value) + when :Date + Date.parse(value) + when :String + value.to_s + when :Integer + value.to_i + when :Float + value.to_f + when :BOOLEAN + if value.to_s =~ /\A(true|t|yes|y|1)\z/i + true + else + false + end + when :Object + # generic object (usually a Hash), return directly + value + when /\AArray<(?.+)>\z/ + inner_type = Regexp.last_match[:inner_type] + value.map { |v| _deserialize(inner_type, v) } + when /\AHash<(?.+?), (?.+)>\z/ + k_type = Regexp.last_match[:k_type] + v_type = Regexp.last_match[:v_type] + {}.tap do |hash| + value.each do |k, v| + hash[_deserialize(k_type, k)] = _deserialize(v_type, v) + end + end + else # model + temp_model = CloudsmithApi.const_get(type).new + temp_model.build_from_hash(value) + end + end + + # Returns the string representation of the object + # @return [String] String presentation of the object + def to_s + to_hash.to_s + end + + # to_body is an alias to to_hash (backward compatibility) + # @return [Hash] Returns the object in the form of hash + def to_body + to_hash + end + + # Returns the object in the form of hash + # @return [Hash] Returns the object in the form of hash + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + next if value.nil? + hash[param] = _to_hash(value) + end + hash + end + + # Outputs non-array value in the form of hash + # For object, use to_hash. Otherwise, just return the value + # @param [Object] value Any valid value + # @return [Hash] Returns the value in the form of hash + def _to_hash(value) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v) } + end + elsif value.respond_to? :to_hash + value.to_hash + else + value + end + end + +end +end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_refresh_request.rb b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_refresh_request.rb index 0e528ac1..49572835 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_refresh_request.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_refresh_request.rb @@ -14,9 +14,6 @@ module CloudsmithApi class RepositoryTokenRefreshRequest - # If enabled, this token can be used for private broadcasts - attr_accessor :access_private_broadcasts - # If checked, a EULA acceptance is required for this token. attr_accessor :eula_required @@ -80,7 +77,6 @@ def valid?(value) # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { - :'access_private_broadcasts' => :'access_private_broadcasts', :'eula_required' => :'eula_required', :'is_active' => :'is_active', :'limit_bandwidth' => :'limit_bandwidth', @@ -101,7 +97,6 @@ def self.attribute_map # Attribute type mapping. def self.swagger_types { - :'access_private_broadcasts' => :'BOOLEAN', :'eula_required' => :'BOOLEAN', :'is_active' => :'BOOLEAN', :'limit_bandwidth' => :'Integer', @@ -127,10 +122,6 @@ def initialize(attributes = {}) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } - if attributes.has_key?(:'access_private_broadcasts') - self.access_private_broadcasts = attributes[:'access_private_broadcasts'] - end - if attributes.has_key?(:'eula_required') self.eula_required = attributes[:'eula_required'] end @@ -234,7 +225,6 @@ def scheduled_reset_period=(scheduled_reset_period) def ==(o) return true if self.equal?(o) self.class == o.class && - access_private_broadcasts == o.access_private_broadcasts && eula_required == o.eula_required && is_active == o.is_active && limit_bandwidth == o.limit_bandwidth && @@ -260,7 +250,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [access_private_broadcasts, eula_required, is_active, limit_bandwidth, limit_bandwidth_unit, limit_date_range_from, limit_date_range_to, limit_num_clients, limit_num_downloads, limit_package_query, limit_path_query, metadata, scheduled_reset_at, scheduled_reset_period, token].hash + [eula_required, is_active, limit_bandwidth, limit_bandwidth_unit, limit_date_range_from, limit_date_range_to, limit_num_clients, limit_num_downloads, limit_package_query, limit_path_query, metadata, scheduled_reset_at, scheduled_reset_period, token].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request.rb b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request.rb index 85a0a3e5..0c10ca58 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request.rb @@ -14,9 +14,6 @@ module CloudsmithApi class RepositoryTokenRequest - # If enabled, this token can be used for private broadcasts - attr_accessor :access_private_broadcasts - # If checked, a EULA acceptance is required for this token. attr_accessor :eula_required @@ -82,7 +79,6 @@ def valid?(value) # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { - :'access_private_broadcasts' => :'access_private_broadcasts', :'eula_required' => :'eula_required', :'is_active' => :'is_active', :'limit_bandwidth' => :'limit_bandwidth', @@ -104,7 +100,6 @@ def self.attribute_map # Attribute type mapping. def self.swagger_types { - :'access_private_broadcasts' => :'BOOLEAN', :'eula_required' => :'BOOLEAN', :'is_active' => :'BOOLEAN', :'limit_bandwidth' => :'Integer', @@ -131,10 +126,6 @@ def initialize(attributes = {}) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } - if attributes.has_key?(:'access_private_broadcasts') - self.access_private_broadcasts = attributes[:'access_private_broadcasts'] - end - if attributes.has_key?(:'eula_required') self.eula_required = attributes[:'eula_required'] end @@ -247,7 +238,6 @@ def scheduled_reset_period=(scheduled_reset_period) def ==(o) return true if self.equal?(o) self.class == o.class && - access_private_broadcasts == o.access_private_broadcasts && eula_required == o.eula_required && is_active == o.is_active && limit_bandwidth == o.limit_bandwidth && @@ -274,7 +264,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [access_private_broadcasts, eula_required, is_active, limit_bandwidth, limit_bandwidth_unit, limit_date_range_from, limit_date_range_to, limit_num_clients, limit_num_downloads, limit_package_query, limit_path_query, metadata, name, scheduled_reset_at, scheduled_reset_period, token].hash + [eula_required, is_active, limit_bandwidth, limit_bandwidth_unit, limit_date_range_from, limit_date_range_to, limit_num_clients, limit_num_downloads, limit_package_query, limit_path_query, metadata, name, scheduled_reset_at, scheduled_reset_period, token].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request_patch.rb b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request_patch.rb index 77e301b1..7dcb280a 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request_patch.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/repository_token_request_patch.rb @@ -14,9 +14,6 @@ module CloudsmithApi class RepositoryTokenRequestPatch - # If enabled, this token can be used for private broadcasts - attr_accessor :access_private_broadcasts - # If checked, a EULA acceptance is required for this token. attr_accessor :eula_required @@ -82,7 +79,6 @@ def valid?(value) # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { - :'access_private_broadcasts' => :'access_private_broadcasts', :'eula_required' => :'eula_required', :'is_active' => :'is_active', :'limit_bandwidth' => :'limit_bandwidth', @@ -104,7 +100,6 @@ def self.attribute_map # Attribute type mapping. def self.swagger_types { - :'access_private_broadcasts' => :'BOOLEAN', :'eula_required' => :'BOOLEAN', :'is_active' => :'BOOLEAN', :'limit_bandwidth' => :'Integer', @@ -131,10 +126,6 @@ def initialize(attributes = {}) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } - if attributes.has_key?(:'access_private_broadcasts') - self.access_private_broadcasts = attributes[:'access_private_broadcasts'] - end - if attributes.has_key?(:'eula_required') self.eula_required = attributes[:'eula_required'] end @@ -242,7 +233,6 @@ def scheduled_reset_period=(scheduled_reset_period) def ==(o) return true if self.equal?(o) self.class == o.class && - access_private_broadcasts == o.access_private_broadcasts && eula_required == o.eula_required && is_active == o.is_active && limit_bandwidth == o.limit_bandwidth && @@ -269,7 +259,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [access_private_broadcasts, eula_required, is_active, limit_bandwidth, limit_bandwidth_unit, limit_date_range_from, limit_date_range_to, limit_num_clients, limit_num_downloads, limit_package_query, limit_path_query, metadata, name, scheduled_reset_at, scheduled_reset_period, token].hash + [eula_required, is_active, limit_bandwidth, limit_bandwidth_unit, limit_date_range_from, limit_date_range_to, limit_num_clients, limit_num_downloads, limit_package_query, limit_path_query, metadata, name, scheduled_reset_at, scheduled_reset_period, token].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb index 5b9963d1..68a94140 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb @@ -375,7 +375,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) return false if @distro_version.nil? gpg_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) @@ -402,7 +402,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb index c63a13b2..b0bffca8 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit.rb b/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit.rb index 1b3362fb..c9fdaf8a 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit.rb @@ -24,6 +24,8 @@ class StorageAllocatedLimit attr_accessor :used + attr_accessor :used_pre_deduplication + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { @@ -31,7 +33,8 @@ def self.attribute_map :'peak' => :'peak', :'percentage_used' => :'percentage_used', :'plan_limit' => :'plan_limit', - :'used' => :'used' + :'used' => :'used', + :'used_pre_deduplication' => :'used_pre_deduplication' } end @@ -42,7 +45,8 @@ def self.swagger_types :'peak' => :'String', :'percentage_used' => :'String', :'plan_limit' => :'String', - :'used' => :'String' + :'used' => :'String', + :'used_pre_deduplication' => :'String' } end @@ -73,6 +77,10 @@ def initialize(attributes = {}) if attributes.has_key?(:'used') self.used = attributes[:'used'] end + + if attributes.has_key?(:'used_pre_deduplication') + self.used_pre_deduplication = attributes[:'used_pre_deduplication'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -97,7 +105,8 @@ def ==(o) peak == o.peak && percentage_used == o.percentage_used && plan_limit == o.plan_limit && - used == o.used + used == o.used && + used_pre_deduplication == o.used_pre_deduplication end # @see the `==` method @@ -109,7 +118,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [configured, peak, percentage_used, plan_limit, used].hash + [configured, peak, percentage_used, plan_limit, used, used_pre_deduplication].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit_raw.rb b/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit_raw.rb index b0c9173c..5708e131 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit_raw.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/storage_allocated_limit_raw.rb @@ -24,6 +24,8 @@ class StorageAllocatedLimitRaw attr_accessor :used + attr_accessor :used_pre_deduplication + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { @@ -31,7 +33,8 @@ def self.attribute_map :'peak' => :'peak', :'percentage_used' => :'percentage_used', :'plan_limit' => :'plan_limit', - :'used' => :'used' + :'used' => :'used', + :'used_pre_deduplication' => :'used_pre_deduplication' } end @@ -42,7 +45,8 @@ def self.swagger_types :'peak' => :'Integer', :'percentage_used' => :'String', :'plan_limit' => :'Integer', - :'used' => :'Integer' + :'used' => :'Integer', + :'used_pre_deduplication' => :'Integer' } end @@ -73,6 +77,10 @@ def initialize(attributes = {}) if attributes.has_key?(:'used') self.used = attributes[:'used'] end + + if attributes.has_key?(:'used_pre_deduplication') + self.used_pre_deduplication = attributes[:'used_pre_deduplication'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -97,7 +105,8 @@ def ==(o) peak == o.peak && percentage_used == o.percentage_used && plan_limit == o.plan_limit && - used == o.used + used == o.used && + used_pre_deduplication == o.used_pre_deduplication end # @see the `==` method @@ -109,7 +118,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [configured, peak, percentage_used, plan_limit, used].hash + [configured, peak, percentage_used, plan_limit, used, used_pre_deduplication].hash end # Builds the object from hash diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb index 7165c7ff..2afe0b73 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/version.rb b/bindings/ruby/src/lib/cloudsmith-api/version.rb index 4be629de..906356c8 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/version.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/version.rb @@ -11,5 +11,5 @@ =end module CloudsmithApi - VERSION = '2.0.25' + VERSION = '2.0.26' end diff --git a/bindings/ruby/src/spec/api/entitlements_api_spec.rb b/bindings/ruby/src/spec/api/entitlements_api_spec.rb index a4ac8947..1f603bf1 100644 --- a/bindings/ruby/src/spec/api/entitlements_api_spec.rb +++ b/bindings/ruby/src/spec/api/entitlements_api_spec.rb @@ -186,4 +186,19 @@ end end + # unit tests for entitlements_toggle_private_broadcasts + # Set private broadcast access for an entitlement token in a repository. + # Set private broadcast access for an entitlement token in a repository. + # @param owner + # @param repo + # @param identifier + # @param [Hash] opts the optional parameters + # @option opts [RepositoryTokenPrivateBroadcastsRequest] :data + # @return [nil] + describe 'entitlements_toggle_private_broadcasts test' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + end diff --git a/bindings/ruby/src/spec/api/packages_api_spec.rb b/bindings/ruby/src/spec/api/packages_api_spec.rb index 6c4ef18c..0aefb371 100644 --- a/bindings/ruby/src/spec/api/packages_api_spec.rb +++ b/bindings/ruby/src/spec/api/packages_api_spec.rb @@ -465,6 +465,20 @@ end end + # unit tests for packages_upload_mcp + # Create a new MCP package + # Create a new MCP package + # @param owner + # @param repo + # @param [Hash] opts the optional parameters + # @option opts [McpPackageUploadRequest] :data + # @return [McpPackageUpload] + describe 'packages_upload_mcp test' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + # unit tests for packages_upload_npm # Create a new npm package # Create a new npm package @@ -857,6 +871,20 @@ end end + # unit tests for packages_validate_upload_mcp + # Validate parameters for create MCP package + # Validate parameters for create MCP package + # @param owner + # @param repo + # @param [Hash] opts the optional parameters + # @option opts [McpPackageUploadRequest] :data + # @return [nil] + describe 'packages_validate_upload_mcp test' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + # unit tests for packages_validate_upload_npm # Validate parameters for create npm package # Validate parameters for create npm package diff --git a/bindings/ruby/src/spec/api/recycle_bin_api_spec.rb b/bindings/ruby/src/spec/api/recycle_bin_api_spec.rb new file mode 100644 index 00000000..273cfc63 --- /dev/null +++ b/bindings/ruby/src/spec/api/recycle_bin_api_spec.rb @@ -0,0 +1,62 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' + +# Unit tests for CloudsmithApi::RecycleBinApi +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'RecycleBinApi' do + before do + # run before each test + @instance = CloudsmithApi::RecycleBinApi.new + end + + after do + # run after each test + end + + describe 'test an instance of RecycleBinApi' do + it 'should create an instance of RecycleBinApi' do + expect(@instance).to be_instance_of(CloudsmithApi::RecycleBinApi) + end + end + + # unit tests for recycle_bin_list + # List soft-deleted packages in recycle bin + # Retrieve all soft-deleted packages in the workspace. Optionally filter by repository using the 'repository' query parameter. + # @param owner + # @param [Hash] opts the optional parameters + # @option opts [Integer] :page A page number within the paginated result set. + # @option opts [Integer] :page_size Number of results to return per page. + # @option opts [String] :repository Filter packages by repository slug + # @return [Array] + describe 'recycle_bin_list test' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + # unit tests for recycle_bin_recycle_bin_action + # Perform actions on soft-deleted packages in the recycle bin. Supported actions: permanently delete (hard delete), restore. Returns a list of successfully actioned packages and any packages that failed with error details. + # @param owner + # @param [Hash] opts the optional parameters + # @option opts [PackageRecycleBin] :data + # @return [PackageBulkActionResponse] + describe 'recycle_bin_recycle_bin_action test' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/api/repos_api_spec.rb b/bindings/ruby/src/spec/api/repos_api_spec.rb index 4c0bb692..9efaad12 100644 --- a/bindings/ruby/src/spec/api/repos_api_spec.rb +++ b/bindings/ruby/src/spec/api/repos_api_spec.rb @@ -86,8 +86,7 @@ end # unit tests for repos_delete - # Delete a repository in a given namespace. - # Delete a repository in a given namespace. + # Delete a repository in a given namespace.Repositories are soft-deleted and can be restored within a retention period. During this time, the repository's slug remains reserved and cannot be reused for new repositories. # @param owner # @param identifier # @param [Hash] opts the optional parameters diff --git a/bindings/ruby/src/spec/models/alpine_upstream_request_patch_spec.rb b/bindings/ruby/src/spec/models/alpine_upstream_request_patch_spec.rb index 8d876a98..4f163703 100644 --- a/bindings/ruby/src/spec/models/alpine_upstream_request_patch_spec.rb +++ b/bindings/ruby/src/spec/models/alpine_upstream_request_patch_spec.rb @@ -106,6 +106,22 @@ end end + describe 'test attribute "rsa_key_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "rsa_verification"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["Allow All", "Warn on Invalid", "Reject Invalid"]) + # validator.allowable_values.each do |value| + # expect { @instance.rsa_verification = value }.not_to raise_error + # end + end + end + describe 'test attribute "upstream_url"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/bindings/ruby/src/spec/models/alpine_upstream_request_spec.rb b/bindings/ruby/src/spec/models/alpine_upstream_request_spec.rb index 64eb3798..f8fa0c03 100644 --- a/bindings/ruby/src/spec/models/alpine_upstream_request_spec.rb +++ b/bindings/ruby/src/spec/models/alpine_upstream_request_spec.rb @@ -106,6 +106,22 @@ end end + describe 'test attribute "rsa_key_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "rsa_verification"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["Allow All", "Warn on Invalid", "Reject Invalid"]) + # validator.allowable_values.each do |value| + # expect { @instance.rsa_verification = value }.not_to raise_error + # end + end + end + describe 'test attribute "upstream_url"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/bindings/ruby/src/spec/models/alpine_upstream_spec.rb b/bindings/ruby/src/spec/models/alpine_upstream_spec.rb index 0076d516..74ae57b6 100644 --- a/bindings/ruby/src/spec/models/alpine_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/alpine_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end @@ -170,6 +170,38 @@ end end + describe 'test attribute "rsa_key_inline"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "rsa_key_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "rsa_verification"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["Allow All", "Warn on Invalid", "Reject Invalid"]) + # validator.allowable_values.each do |value| + # expect { @instance.rsa_verification = value }.not_to raise_error + # end + end + end + + describe 'test attribute "rsa_verification_status"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["Unknown", "Invalid", "Valid", "Invalid (No Key)"]) + # validator.allowable_values.each do |value| + # expect { @instance.rsa_verification_status = value }.not_to raise_error + # end + end + end + describe 'test attribute "slug_perm"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/bindings/ruby/src/spec/models/cargo_upstream_spec.rb b/bindings/ruby/src/spec/models/cargo_upstream_spec.rb index fe9a987d..2762c8db 100644 --- a/bindings/ruby/src/spec/models/cargo_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/cargo_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/composer_upstream_spec.rb b/bindings/ruby/src/spec/models/composer_upstream_spec.rb index 5ea0722e..95efb86c 100644 --- a/bindings/ruby/src/spec/models/composer_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/composer_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/conda_upstream_spec.rb b/bindings/ruby/src/spec/models/conda_upstream_spec.rb index d3c9b728..869df5bb 100644 --- a/bindings/ruby/src/spec/models/conda_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/conda_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/cran_upstream_spec.rb b/bindings/ruby/src/spec/models/cran_upstream_spec.rb index 631bd782..5f54bfe3 100644 --- a/bindings/ruby/src/spec/models/cran_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/cran_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/dart_upstream_spec.rb b/bindings/ruby/src/spec/models/dart_upstream_spec.rb index 87b9f950..fc057153 100644 --- a/bindings/ruby/src/spec/models/dart_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/dart_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/deb_upstream_spec.rb b/bindings/ruby/src/spec/models/deb_upstream_spec.rb index d7f0b58a..4f51f896 100644 --- a/bindings/ruby/src/spec/models/deb_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/deb_upstream_spec.rb @@ -81,7 +81,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/docker_upstream_spec.rb b/bindings/ruby/src/spec/models/docker_upstream_spec.rb index cc11faaf..d3965074 100644 --- a/bindings/ruby/src/spec/models/docker_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/docker_upstream_spec.rb @@ -69,7 +69,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/generic_upstream_spec.rb b/bindings/ruby/src/spec/models/generic_upstream_spec.rb index dba64158..3013c2bb 100644 --- a/bindings/ruby/src/spec/models/generic_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/generic_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/go_upstream_spec.rb b/bindings/ruby/src/spec/models/go_upstream_spec.rb index 60186a00..8e5391b1 100644 --- a/bindings/ruby/src/spec/models/go_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/go_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/helm_upstream_spec.rb b/bindings/ruby/src/spec/models/helm_upstream_spec.rb index a405e66e..56508cf9 100644 --- a/bindings/ruby/src/spec/models/helm_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/helm_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/hex_upstream_spec.rb b/bindings/ruby/src/spec/models/hex_upstream_spec.rb index eb4b7b0b..a8705e58 100644 --- a/bindings/ruby/src/spec/models/hex_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/hex_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/huggingface_upstream_spec.rb b/bindings/ruby/src/spec/models/huggingface_upstream_spec.rb index 019c07a1..378b11c8 100644 --- a/bindings/ruby/src/spec/models/huggingface_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/huggingface_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/maven_upstream_spec.rb b/bindings/ruby/src/spec/models/maven_upstream_spec.rb index ef972baa..4af2b9b3 100644 --- a/bindings/ruby/src/spec/models/maven_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/maven_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/mcp_package_upload_request_spec.rb b/bindings/ruby/src/spec/models/mcp_package_upload_request_spec.rb new file mode 100644 index 00000000..19fd180d --- /dev/null +++ b/bindings/ruby/src/spec/models/mcp_package_upload_request_spec.rb @@ -0,0 +1,59 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' +require 'date' + +# Unit tests for CloudsmithApi::McpPackageUploadRequest +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'McpPackageUploadRequest' do + before do + # run before each test + @instance = CloudsmithApi::McpPackageUploadRequest.new + end + + after do + # run after each test + end + + describe 'test an instance of McpPackageUploadRequest' do + it 'should create an instance of McpPackageUploadRequest' do + expect(@instance).to be_instance_of(CloudsmithApi::McpPackageUploadRequest) + end + end + describe 'test attribute "package_file"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "republish"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "tags"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "version"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/models/mcp_package_upload_spec.rb b/bindings/ruby/src/spec/models/mcp_package_upload_spec.rb new file mode 100644 index 00000000..6cc8e597 --- /dev/null +++ b/bindings/ruby/src/spec/models/mcp_package_upload_spec.rb @@ -0,0 +1,543 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' +require 'date' + +# Unit tests for CloudsmithApi::McpPackageUpload +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'McpPackageUpload' do + before do + # run before each test + @instance = CloudsmithApi::McpPackageUpload.new + end + + after do + # run after each test + end + + describe 'test an instance of McpPackageUpload' do + it 'should create an instance of McpPackageUpload' do + expect(@instance).to be_instance_of(CloudsmithApi::McpPackageUpload) + end + end + describe 'test attribute "architectures"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "cdn_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "checksum_md5"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "checksum_sha1"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "checksum_sha256"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "checksum_sha512"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "dependencies_checksum_md5"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "dependencies_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "description"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "display_name"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "distro"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "distro_version"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "downloads"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "epoch"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "extension"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "filename"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "files"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "format"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "format_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "freeable_storage"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "fully_qualified_name"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "identifier_perm"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "identifiers"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "indexed"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_cancellable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_copyable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_deleteable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_downloadable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_moveable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_quarantinable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_quarantined"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_resyncable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_security_scannable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_sync_awaiting"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_sync_completed"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_sync_failed"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_sync_in_flight"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_sync_in_progress"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "license"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "name"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "namespace"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "namespace_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "num_files"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "origin_repository"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "origin_repository_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "package_type"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "policy_violated"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "raw_license"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "release"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "repository"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "repository_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "security_scan_completed_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "security_scan_started_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "security_scan_status"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["Awaiting Security Scan", "Security Scanning in Progress", "Scan Detected Vulnerabilities", "Scan Detected No Vulnerabilities", "Security Scanning Disabled", "Security Scanning Failed", "Security Scanning Skipped", "Security Scanning Not Supported"]) + # validator.allowable_values.each do |value| + # expect { @instance.security_scan_status = value }.not_to raise_error + # end + end + end + + describe 'test attribute "security_scan_status_updated_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "self_html_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "self_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "self_webapp_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "signature_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "size"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "slug"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "slug_perm"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "spdx_license"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "stage"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "stage_str"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "stage_updated_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status_reason"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status_str"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status_updated_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "subtype"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "summary"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "sync_finished_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "sync_progress"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "tags_automatic"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "tags_immutable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "type_display"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "uploaded_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "uploader"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "uploader_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "version"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "version_orig"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "vulnerability_scan_results_url"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/models/npm_upstream_spec.rb b/bindings/ruby/src/spec/models/npm_upstream_spec.rb index 73b5ee0e..23ca77c6 100644 --- a/bindings/ruby/src/spec/models/npm_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/npm_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/nuget_upstream_spec.rb b/bindings/ruby/src/spec/models/nuget_upstream_spec.rb index b6ae091e..fc073669 100644 --- a/bindings/ruby/src/spec/models/nuget_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/nuget_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/package_recycle_bin_spec.rb b/bindings/ruby/src/spec/models/package_recycle_bin_spec.rb new file mode 100644 index 00000000..b60ce0ea --- /dev/null +++ b/bindings/ruby/src/spec/models/package_recycle_bin_spec.rb @@ -0,0 +1,57 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' +require 'date' + +# Unit tests for CloudsmithApi::PackageRecycleBin +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'PackageRecycleBin' do + before do + # run before each test + @instance = CloudsmithApi::PackageRecycleBin.new + end + + after do + # run after each test + end + + describe 'test an instance of PackageRecycleBin' do + it 'should create an instance of PackageRecycleBin' do + expect(@instance).to be_instance_of(CloudsmithApi::PackageRecycleBin) + end + end + describe 'test attribute "action"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["hard_delete", "restore"]) + # validator.allowable_values.each do |value| + # expect { @instance.action = value }.not_to raise_error + # end + end + end + + describe 'test attribute "identifiers"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "repository"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/models/python_upstream_spec.rb b/bindings/ruby/src/spec/models/python_upstream_spec.rb index 42ca98e1..40037b7a 100644 --- a/bindings/ruby/src/spec/models/python_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/python_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/recycle_bin_package_spec.rb b/bindings/ruby/src/spec/models/recycle_bin_package_spec.rb new file mode 100644 index 00000000..09477e6d --- /dev/null +++ b/bindings/ruby/src/spec/models/recycle_bin_package_spec.rb @@ -0,0 +1,183 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' +require 'date' + +# Unit tests for CloudsmithApi::RecycleBinPackage +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'RecycleBinPackage' do + before do + # run before each test + @instance = CloudsmithApi::RecycleBinPackage.new + end + + after do + # run after each test + end + + describe 'test an instance of RecycleBinPackage' do + it 'should create an instance of RecycleBinPackage' do + expect(@instance).to be_instance_of(CloudsmithApi::RecycleBinPackage) + end + end + describe 'test attribute "action_by"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "downloads"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "filename"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "format"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "fully_qualified_name"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "identifiers"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "invoked_retention_rule"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_deleteable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_quarantined"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "is_restorable"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "name"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "policy_violated"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "repository"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "security_scan_completed_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "security_scan_status"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["Awaiting Security Scan", "Security Scanning in Progress", "Scan Detected Vulnerabilities", "Scan Detected No Vulnerabilities", "Security Scanning Disabled", "Security Scanning Failed", "Security Scanning Skipped", "Security Scanning Not Supported"]) + # validator.allowable_values.each do |value| + # expect { @instance.security_scan_status = value }.not_to raise_error + # end + end + end + + describe 'test attribute "size"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "slug_perm"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "status_updated_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "tags"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "type_display"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "uploaded_at"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "uploader"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + + describe 'test attribute "version"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/models/repository_token_private_broadcasts_request_spec.rb b/bindings/ruby/src/spec/models/repository_token_private_broadcasts_request_spec.rb new file mode 100644 index 00000000..4bf8517a --- /dev/null +++ b/bindings/ruby/src/spec/models/repository_token_private_broadcasts_request_spec.rb @@ -0,0 +1,41 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' +require 'date' + +# Unit tests for CloudsmithApi::RepositoryTokenPrivateBroadcastsRequest +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'RepositoryTokenPrivateBroadcastsRequest' do + before do + # run before each test + @instance = CloudsmithApi::RepositoryTokenPrivateBroadcastsRequest.new + end + + after do + # run after each test + end + + describe 'test an instance of RepositoryTokenPrivateBroadcastsRequest' do + it 'should create an instance of RepositoryTokenPrivateBroadcastsRequest' do + expect(@instance).to be_instance_of(CloudsmithApi::RepositoryTokenPrivateBroadcastsRequest) + end + end + describe 'test attribute "access_private_broadcasts"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/models/repository_token_private_broadcasts_spec.rb b/bindings/ruby/src/spec/models/repository_token_private_broadcasts_spec.rb new file mode 100644 index 00000000..55a8f6b1 --- /dev/null +++ b/bindings/ruby/src/spec/models/repository_token_private_broadcasts_spec.rb @@ -0,0 +1,41 @@ +=begin +#Cloudsmith API (v1) + +#The API to the Cloudsmith Service + +OpenAPI spec version: v1 +Contact: support@cloudsmith.io +Generated by: https://github.com/swagger-api/swagger-codegen.git +Swagger Codegen version: 2.4.50 + +=end + +require 'spec_helper' +require 'json' +require 'date' + +# Unit tests for CloudsmithApi::RepositoryTokenPrivateBroadcasts +# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen) +# Please update as you see appropriate +describe 'RepositoryTokenPrivateBroadcasts' do + before do + # run before each test + @instance = CloudsmithApi::RepositoryTokenPrivateBroadcasts.new + end + + after do + # run after each test + end + + describe 'test an instance of RepositoryTokenPrivateBroadcasts' do + it 'should create an instance of RepositoryTokenPrivateBroadcasts' do + expect(@instance).to be_instance_of(CloudsmithApi::RepositoryTokenPrivateBroadcasts) + end + end + describe 'test attribute "access_private_broadcasts"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + +end diff --git a/bindings/ruby/src/spec/models/repository_token_refresh_request_spec.rb b/bindings/ruby/src/spec/models/repository_token_refresh_request_spec.rb index afed7eb9..4f5e1af2 100644 --- a/bindings/ruby/src/spec/models/repository_token_refresh_request_spec.rb +++ b/bindings/ruby/src/spec/models/repository_token_refresh_request_spec.rb @@ -32,12 +32,6 @@ expect(@instance).to be_instance_of(CloudsmithApi::RepositoryTokenRefreshRequest) end end - describe 'test attribute "access_private_broadcasts"' do - it 'should work' do - # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - end - end - describe 'test attribute "eula_required"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/bindings/ruby/src/spec/models/repository_token_request_patch_spec.rb b/bindings/ruby/src/spec/models/repository_token_request_patch_spec.rb index 6cf8dc53..b91c451f 100644 --- a/bindings/ruby/src/spec/models/repository_token_request_patch_spec.rb +++ b/bindings/ruby/src/spec/models/repository_token_request_patch_spec.rb @@ -32,12 +32,6 @@ expect(@instance).to be_instance_of(CloudsmithApi::RepositoryTokenRequestPatch) end end - describe 'test attribute "access_private_broadcasts"' do - it 'should work' do - # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - end - end - describe 'test attribute "eula_required"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/bindings/ruby/src/spec/models/repository_token_request_spec.rb b/bindings/ruby/src/spec/models/repository_token_request_spec.rb index 50d4116c..51de796d 100644 --- a/bindings/ruby/src/spec/models/repository_token_request_spec.rb +++ b/bindings/ruby/src/spec/models/repository_token_request_spec.rb @@ -32,12 +32,6 @@ expect(@instance).to be_instance_of(CloudsmithApi::RepositoryTokenRequest) end end - describe 'test attribute "access_private_broadcasts"' do - it 'should work' do - # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - end - end - describe 'test attribute "eula_required"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/bindings/ruby/src/spec/models/rpm_upstream_spec.rb b/bindings/ruby/src/spec/models/rpm_upstream_spec.rb index b097964a..42755234 100644 --- a/bindings/ruby/src/spec/models/rpm_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/rpm_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/ruby_upstream_spec.rb b/bindings/ruby/src/spec/models/ruby_upstream_spec.rb index d94a35ba..76e80514 100644 --- a/bindings/ruby/src/spec/models/ruby_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/ruby_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/bindings/ruby/src/spec/models/storage_allocated_limit_raw_spec.rb b/bindings/ruby/src/spec/models/storage_allocated_limit_raw_spec.rb index fe934ea5..6831d75d 100644 --- a/bindings/ruby/src/spec/models/storage_allocated_limit_raw_spec.rb +++ b/bindings/ruby/src/spec/models/storage_allocated_limit_raw_spec.rb @@ -62,4 +62,10 @@ end end + describe 'test attribute "used_pre_deduplication"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + end diff --git a/bindings/ruby/src/spec/models/storage_allocated_limit_spec.rb b/bindings/ruby/src/spec/models/storage_allocated_limit_spec.rb index 970247ad..3c227d03 100644 --- a/bindings/ruby/src/spec/models/storage_allocated_limit_spec.rb +++ b/bindings/ruby/src/spec/models/storage_allocated_limit_spec.rb @@ -62,4 +62,10 @@ end end + describe 'test attribute "used_pre_deduplication"' do + it 'should work' do + # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers + end + end + end diff --git a/bindings/ruby/src/spec/models/swift_upstream_spec.rb b/bindings/ruby/src/spec/models/swift_upstream_spec.rb index 12334f23..3a971efb 100644 --- a/bindings/ruby/src/spec/models/swift_upstream_spec.rb +++ b/bindings/ruby/src/spec/models/swift_upstream_spec.rb @@ -75,7 +75,7 @@ describe 'test attribute "disable_reason"' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers - # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "Upstream was disabled by request of user"]) + # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["N/A", "Upstream points to its own repository", "Missing upstream source", "RSA key did not verify the upstream's APKINDEX signature", "Upstream was disabled by request of user"]) # validator.allowable_values.each do |value| # expect { @instance.disable_reason = value }.not_to raise_error # end diff --git a/scripts/common.sh b/scripts/common.sh index bdc59f6e..e4d85843 100644 --- a/scripts/common.sh +++ b/scripts/common.sh @@ -3,7 +3,7 @@ language=${1:-""} api_url=${2:-${api_url:-"https://api.cloudsmith.io/"}} api_version=$(curl -s "${api_url}status/check/basic/" | jq -r '.version') openapi_url="${api_url}?format=openapi" -package_version="2.0.25" +package_version="2.0.26" swagger_codegen_cli_image="swaggerapi/swagger-codegen-cli:v2.4.50" location=$(curl -s $openapi_url | grep Location | cut -d' ' -f2) From 48007fe78e43c13d340608b7fad921e7df737811 Mon Sep 17 00:00:00 2001 From: Ian Duffy Date: Fri, 24 Apr 2026 14:43:58 +0100 Subject: [PATCH 2/2] Fix Ruby syntax errors: escape apostrophe in upstream disable_reason enum values swagger-codegen emits 'RSA key did not verify the upstream's APKINDEX signature' as a single-quoted Ruby string, but the apostrophe in upstream's breaks the string literal. Escape it as upstream\'s in all 20 affected model files. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb | 4 ++-- .../ruby/src/lib/cloudsmith-api/models/composer_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb | 4 ++-- .../ruby/src/lib/cloudsmith-api/models/docker_upstream.rb | 4 ++-- .../ruby/src/lib/cloudsmith-api/models/generic_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb | 4 ++-- .../src/lib/cloudsmith-api/models/huggingface_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb | 4 ++-- .../ruby/src/lib/cloudsmith-api/models/python_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb | 4 ++-- bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb | 4 ++-- 20 files changed, 40 insertions(+), 40 deletions(-) diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb index afbfeb42..9b3a06eb 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/alpine_upstream.rb @@ -345,7 +345,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -371,7 +371,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb index 04968b1e..712e9ff3 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/cargo_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb index 21482de2..d1605201 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/composer_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb index e1e94c36..866eb2e7 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/conda_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb index 402ace7b..240c2229 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/cran_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb index d9d7b9a2..d5079dac 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/dart_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb index c2c489ca..7025ef84 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/deb_upstream.rb @@ -395,7 +395,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) return false if @distro_versions.nil? gpg_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) @@ -422,7 +422,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb index a49d275f..d40bc780 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/docker_upstream.rb @@ -269,7 +269,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password', 'Certificate and Key']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -291,7 +291,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb index 1615d8cd..08181c91 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/generic_upstream.rb @@ -314,7 +314,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password', 'Token']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -336,7 +336,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb index 5b969776..f4e58359 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/go_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb index 4df35c24..ae2345fe 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/helm_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb index 314fd109..4510e48d 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/hex_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb index 8aed3692..07b032f5 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/huggingface_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Token']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb index c6a5a6cb..5b41d591 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/maven_upstream.rb @@ -364,7 +364,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) gpg_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) return false unless gpg_verification_validator.valid?(@gpg_verification) @@ -392,7 +392,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb index f843d07a..5fdb34e8 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/npm_upstream.rb @@ -316,7 +316,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password', 'Token']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -340,7 +340,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb index 69367424..e4a9c150 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/nuget_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb index 430e2ce6..d5c34163 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/python_upstream.rb @@ -316,7 +316,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -340,7 +340,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb index 68a94140..d3dedb9a 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/rpm_upstream.rb @@ -375,7 +375,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) return false if @distro_version.nil? gpg_verification_validator = EnumAttributeValidator.new('String', ['Allow All', 'Warn on Invalid', 'Reject Invalid']) @@ -402,7 +402,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb index b0bffca8..a183477b 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/ruby_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end diff --git a/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb b/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb index 2afe0b73..0ecb4595 100644 --- a/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb +++ b/bindings/ruby/src/lib/cloudsmith-api/models/swift_upstream.rb @@ -305,7 +305,7 @@ def list_invalid_properties def valid? auth_mode_validator = EnumAttributeValidator.new('String', ['None', 'Username and Password']) return false unless auth_mode_validator.valid?(@auth_mode) - disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + disable_reason_validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) return false unless disable_reason_validator.valid?(@disable_reason) mode_validator = EnumAttributeValidator.new('String', ['Proxy Only', 'Cache and Proxy']) return false unless mode_validator.valid?(@mode) @@ -327,7 +327,7 @@ def auth_mode=(auth_mode) # Custom attribute writer method checking allowed values (enum). # @param [Object] disable_reason Object to be assigned def disable_reason=(disable_reason) - validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream's APKINDEX signature', 'Upstream was disabled by request of user']) + validator = EnumAttributeValidator.new('String', ['N/A', 'Upstream points to its own repository', 'Missing upstream source', 'RSA key did not verify the upstream\'s APKINDEX signature', 'Upstream was disabled by request of user']) unless validator.valid?(disable_reason) fail ArgumentError, 'invalid value for "disable_reason", must be one of #{validator.allowable_values}.' end