From 419576f422fc3dd1262075636f3fa4403120456b Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Mon, 12 Aug 2024 13:46:47 -0400 Subject: [PATCH 01/12] /fax_lines API spec and regenerate SDKs --- examples/FaxLineAddUser.cs | 0 examples/FaxLineAddUser.java | 0 examples/FaxLineAddUser.js | 0 examples/FaxLineAddUser.php | 0 examples/FaxLineAddUser.py | 0 examples/FaxLineAddUser.rb | 0 examples/FaxLineAddUser.sh | 0 examples/FaxLineAddUser.ts | 0 examples/FaxLineAreaCodeGet.cs | 0 examples/FaxLineAreaCodeGet.java | 0 examples/FaxLineAreaCodeGet.js | 0 examples/FaxLineAreaCodeGet.php | 0 examples/FaxLineAreaCodeGet.py | 0 examples/FaxLineAreaCodeGet.rb | 0 examples/FaxLineAreaCodeGet.sh | 0 examples/FaxLineAreaCodeGet.ts | 0 examples/FaxLineCreate.cs | 0 examples/FaxLineCreate.java | 0 examples/FaxLineCreate.js | 0 examples/FaxLineCreate.php | 0 examples/FaxLineCreate.py | 0 examples/FaxLineCreate.rb | 0 examples/FaxLineCreate.sh | 0 examples/FaxLineCreate.ts | 0 examples/FaxLineDelete.cs | 0 examples/FaxLineDelete.java | 0 examples/FaxLineDelete.js | 0 examples/FaxLineDelete.php | 0 examples/FaxLineDelete.py | 0 examples/FaxLineDelete.rb | 0 examples/FaxLineDelete.sh | 0 examples/FaxLineDelete.ts | 0 examples/FaxLineGet.cs | 0 examples/FaxLineGet.java | 0 examples/FaxLineGet.js | 0 examples/FaxLineGet.php | 0 examples/FaxLineGet.py | 0 examples/FaxLineGet.rb | 0 examples/FaxLineGet.sh | 0 examples/FaxLineGet.ts | 0 examples/FaxLineList.cs | 0 examples/FaxLineList.java | 0 examples/FaxLineList.js | 0 examples/FaxLineList.php | 0 examples/FaxLineList.py | 0 examples/FaxLineList.rb | 0 examples/FaxLineList.sh | 0 examples/FaxLineList.ts | 0 examples/FaxLineRemoveUser.cs | 0 examples/FaxLineRemoveUser.java | 0 examples/FaxLineRemoveUser.js | 0 examples/FaxLineRemoveUser.php | 0 examples/FaxLineRemoveUser.py | 0 examples/FaxLineRemoveUser.rb | 0 examples/FaxLineRemoveUser.sh | 0 examples/FaxLineRemoveUser.ts | 0 openapi-raw.yaml | 917 +++++++ openapi-sdk.yaml | 917 +++++++ openapi.yaml | 917 +++++++ sdks/dotnet/README.md | 17 + sdks/dotnet/docs/FaxLineAddUserRequest.md | 12 + sdks/dotnet/docs/FaxLineApi.md | 444 ++++ .../docs/FaxLineAreaCodeGetCountryEnum.md | 9 + .../docs/FaxLineAreaCodeGetProvinceEnum.md | 9 + .../dotnet/docs/FaxLineAreaCodeGetResponse.md | 10 + .../docs/FaxLineAreaCodeGetStateEnum.md | 9 + sdks/dotnet/docs/FaxLineCreateRequest.md | 13 + sdks/dotnet/docs/FaxLineDeleteRequest.md | 10 + sdks/dotnet/docs/FaxLineListResponse.md | 12 + sdks/dotnet/docs/FaxLineRemoveUserRequest.md | 12 + sdks/dotnet/docs/FaxLineResponse.md | 11 + .../dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs | 1717 ++++++++++++ .../Model/FaxLineAddUserRequest.cs | 221 ++ .../Model/FaxLineAreaCodeGetCountryEnum.cs | 55 + .../Model/FaxLineAreaCodeGetProvinceEnum.cs | 115 + .../Model/FaxLineAreaCodeGetResponse.cs | 166 ++ .../Model/FaxLineAreaCodeGetStateEnum.cs | 343 +++ .../Model/FaxLineCreateRequest.cs | 246 ++ .../Model/FaxLineDeleteRequest.cs | 171 ++ .../Dropbox.Sign/Model/FaxLineListResponse.cs | 214 ++ .../Model/FaxLineRemoveUserRequest.cs | 221 ++ .../src/Dropbox.Sign/Model/FaxLineResponse.cs | 189 ++ sdks/java-v1/README.md | 17 + sdks/java-v1/docs/FaxLineAddUserRequest.md | 16 + sdks/java-v1/docs/FaxLineApi.md | 308 +++ .../docs/FaxLineAreaCodeGetCountryEnum.md | 15 + .../docs/FaxLineAreaCodeGetProvinceEnum.md | 35 + .../docs/FaxLineAreaCodeGetResponse.md | 14 + .../docs/FaxLineAreaCodeGetStateEnum.md | 111 + sdks/java-v1/docs/FaxLineCreateRequest.md | 17 + sdks/java-v1/docs/FaxLineDeleteRequest.md | 14 + sdks/java-v1/docs/FaxLineListResponse.md | 16 + sdks/java-v1/docs/FaxLineRemoveUserRequest.md | 16 + sdks/java-v1/docs/FaxLineResponse.md | 15 + .../java/com/dropbox/sign/api/FaxLineApi.java | 742 ++++++ .../sign/model/FaxLineAddUserRequest.java | 283 ++ .../model/FaxLineAreaCodeGetCountryEnum.java | 66 + .../model/FaxLineAreaCodeGetProvinceEnum.java | 86 + .../model/FaxLineAreaCodeGetResponse.java | 191 ++ .../model/FaxLineAreaCodeGetStateEnum.java | 162 ++ .../sign/model/FaxLineCreateRequest.java | 335 +++ .../sign/model/FaxLineDeleteRequest.java | 181 ++ .../sign/model/FaxLineListResponse.java | 296 +++ .../sign/model/FaxLineRemoveUserRequest.java | 283 ++ .../dropbox/sign/model/FaxLineResponse.java | 233 ++ sdks/java-v2/README.md | 17 + sdks/java-v2/docs/FaxLineAddUserRequest.md | 16 + sdks/java-v2/docs/FaxLineApi.md | 308 +++ .../docs/FaxLineAreaCodeGetCountryEnum.md | 15 + .../docs/FaxLineAreaCodeGetProvinceEnum.md | 35 + .../docs/FaxLineAreaCodeGetResponse.md | 14 + .../docs/FaxLineAreaCodeGetStateEnum.md | 111 + sdks/java-v2/docs/FaxLineCreateRequest.md | 17 + sdks/java-v2/docs/FaxLineDeleteRequest.md | 14 + sdks/java-v2/docs/FaxLineListResponse.md | 16 + sdks/java-v2/docs/FaxLineRemoveUserRequest.md | 16 + sdks/java-v2/docs/FaxLineResponse.md | 15 + .../java/com/dropbox/sign/api/FaxLineApi.java | 743 ++++++ .../sign/model/FaxLineAddUserRequest.java | 283 ++ .../model/FaxLineAreaCodeGetCountryEnum.java | 67 + .../model/FaxLineAreaCodeGetProvinceEnum.java | 87 + .../model/FaxLineAreaCodeGetResponse.java | 191 ++ .../model/FaxLineAreaCodeGetStateEnum.java | 163 ++ .../sign/model/FaxLineCreateRequest.java | 335 +++ .../sign/model/FaxLineDeleteRequest.java | 181 ++ .../sign/model/FaxLineListResponse.java | 296 +++ .../sign/model/FaxLineRemoveUserRequest.java | 283 ++ .../dropbox/sign/model/FaxLineResponse.java | 233 ++ sdks/node/README.md | 17 + sdks/node/api/faxLineApi.ts | 1209 +++++++++ sdks/node/api/index.ts | 3 + sdks/node/dist/api.js | 1219 ++++++++- sdks/node/docs/api/FaxLineApi.md | 335 +++ sdks/node/docs/model/FaxLineAddUserRequest.md | 13 + .../model/FaxLineAreaCodeGetCountryEnum.md | 10 + .../model/FaxLineAreaCodeGetProvinceEnum.md | 10 + .../docs/model/FaxLineAreaCodeGetResponse.md | 11 + .../docs/model/FaxLineAreaCodeGetStateEnum.md | 10 + sdks/node/docs/model/FaxLineCreateRequest.md | 14 + sdks/node/docs/model/FaxLineDeleteRequest.md | 11 + sdks/node/docs/model/FaxLineListResponse.md | 13 + .../docs/model/FaxLineRemoveUserRequest.md | 13 + sdks/node/docs/model/FaxLineResponse.md | 12 + sdks/node/model/faxLineAddUserRequest.ts | 69 + .../model/faxLineAreaCodeGetCountryEnum.ts | 31 + .../model/faxLineAreaCodeGetProvinceEnum.ts | 41 + sdks/node/model/faxLineAreaCodeGetResponse.ts | 48 + .../node/model/faxLineAreaCodeGetStateEnum.ts | 79 + sdks/node/model/faxLineCreateRequest.ts | 76 + sdks/node/model/faxLineDeleteRequest.ts | 51 + sdks/node/model/faxLineListResponse.ts | 63 + sdks/node/model/faxLineRemoveUserRequest.ts | 69 + sdks/node/model/faxLineResponse.ts | 55 + sdks/node/model/index.ts | 30 + sdks/node/types/api/faxLineApi.d.ts | 34 + sdks/node/types/api/index.d.ts | 5 +- .../types/model/faxLineAddUserRequest.d.ts | 10 + .../model/faxLineAreaCodeGetCountryEnum.d.ts | 5 + .../model/faxLineAreaCodeGetProvinceEnum.d.ts | 15 + .../model/faxLineAreaCodeGetResponse.d.ts | 8 + .../model/faxLineAreaCodeGetStateEnum.d.ts | 53 + .../types/model/faxLineCreateRequest.d.ts | 12 + .../types/model/faxLineDeleteRequest.d.ts | 8 + .../node/types/model/faxLineListResponse.d.ts | 13 + .../types/model/faxLineRemoveUserRequest.d.ts | 10 + sdks/node/types/model/faxLineResponse.d.ts | 10 + sdks/node/types/model/index.d.ts | 10 + sdks/php/README.md | 17 + sdks/php/docs/Api/FaxLineApi.md | 293 ++ sdks/php/docs/Model/FaxLineAddUserRequest.md | 13 + .../Model/FaxLineAreaCodeGetCountryEnum.md | 10 + .../Model/FaxLineAreaCodeGetProvinceEnum.md | 10 + .../docs/Model/FaxLineAreaCodeGetResponse.md | 11 + .../docs/Model/FaxLineAreaCodeGetStateEnum.md | 10 + sdks/php/docs/Model/FaxLineCreateRequest.md | 14 + sdks/php/docs/Model/FaxLineDeleteRequest.md | 11 + sdks/php/docs/Model/FaxLineListResponse.md | 13 + .../docs/Model/FaxLineRemoveUserRequest.md | 13 + sdks/php/docs/Model/FaxLineResponse.md | 12 + sdks/php/src/Api/FaxLineApi.php | 2359 +++++++++++++++++ sdks/php/src/Model/FaxLineAddUserRequest.php | 405 +++ .../Model/FaxLineAreaCodeGetCountryEnum.php | 61 + .../Model/FaxLineAreaCodeGetProvinceEnum.php | 91 + .../src/Model/FaxLineAreaCodeGetResponse.php | 342 +++ .../src/Model/FaxLineAreaCodeGetStateEnum.php | 205 ++ sdks/php/src/Model/FaxLineCreateRequest.php | 441 +++ sdks/php/src/Model/FaxLineDeleteRequest.php | 345 +++ sdks/php/src/Model/FaxLineListResponse.php | 402 +++ .../src/Model/FaxLineRemoveUserRequest.php | 405 +++ sdks/php/src/Model/FaxLineResponse.php | 372 +++ sdks/python/.openapi-generator/FILES | 22 + sdks/python/README.md | 17 + sdks/python/docs/FaxLineAddUserRequest.md | 16 + sdks/python/docs/FaxLineApi.md | 336 +++ .../docs/FaxLineAreaCodeGetCountryEnum.md | 13 + .../docs/FaxLineAreaCodeGetProvinceEnum.md | 13 + .../python/docs/FaxLineAreaCodeGetResponse.md | 14 + .../docs/FaxLineAreaCodeGetStateEnum.md | 13 + sdks/python/docs/FaxLineCreateRequest.md | 17 + sdks/python/docs/FaxLineDeleteRequest.md | 14 + sdks/python/docs/FaxLineListResponse.md | 16 + sdks/python/docs/FaxLineRemoveUserRequest.md | 16 + sdks/python/docs/FaxLineResponse.md | 15 + sdks/python/dropbox_sign/api/fax_line_api.py | 1119 ++++++++ sdks/python/dropbox_sign/apis/__init__.py | 1 + .../model/fax_line_add_user_request.py | 313 +++ .../fax_line_area_code_get_country_enum.py | 304 +++ .../fax_line_area_code_get_province_enum.py | 314 +++ .../model/fax_line_area_code_get_response.py | 283 ++ .../fax_line_area_code_get_state_enum.py | 352 +++ .../model/fax_line_create_request.py | 337 +++ .../model/fax_line_delete_request.py | 289 ++ .../model/fax_line_list_response.py | 321 +++ .../model/fax_line_remove_user_request.py | 313 +++ .../dropbox_sign/model/fax_line_response.py | 303 +++ sdks/python/dropbox_sign/models/__init__.py | 10 + sdks/ruby/.openapi-generator/FILES | 22 + sdks/ruby/README.md | 17 + sdks/ruby/docs/FaxLineAddUserRequest.md | 12 + sdks/ruby/docs/FaxLineApi.md | 384 +++ .../docs/FaxLineAreaCodeGetCountryEnum.md | 9 + .../docs/FaxLineAreaCodeGetProvinceEnum.md | 9 + sdks/ruby/docs/FaxLineAreaCodeGetResponse.md | 10 + sdks/ruby/docs/FaxLineAreaCodeGetStateEnum.md | 9 + sdks/ruby/docs/FaxLineCreateRequest.md | 13 + sdks/ruby/docs/FaxLineDeleteRequest.md | 10 + sdks/ruby/docs/FaxLineListResponse.md | 12 + sdks/ruby/docs/FaxLineRemoveUserRequest.md | 12 + sdks/ruby/docs/FaxLineResponse.md | 11 + sdks/ruby/lib/dropbox-sign.rb | 11 + .../ruby/lib/dropbox-sign/api/fax_line_api.rb | 732 +++++ .../models/fax_line_add_user_request.rb | 278 ++ .../fax_line_area_code_get_country_enum.rb | 41 + .../fax_line_area_code_get_province_enum.rb | 51 + .../models/fax_line_area_code_get_response.rb | 252 ++ .../fax_line_area_code_get_state_enum.rb | 89 + .../models/fax_line_create_request.rb | 298 +++ .../models/fax_line_delete_request.rb | 256 ++ .../models/fax_line_list_response.rb | 272 ++ .../models/fax_line_remove_user_request.rb | 278 ++ .../dropbox-sign/models/fax_line_response.rb | 260 ++ translations/en.yaml | 49 + 242 files changed, 31579 insertions(+), 44 deletions(-) create mode 100644 examples/FaxLineAddUser.cs create mode 100644 examples/FaxLineAddUser.java create mode 100644 examples/FaxLineAddUser.js create mode 100644 examples/FaxLineAddUser.php create mode 100644 examples/FaxLineAddUser.py create mode 100644 examples/FaxLineAddUser.rb create mode 100644 examples/FaxLineAddUser.sh create mode 100644 examples/FaxLineAddUser.ts create mode 100644 examples/FaxLineAreaCodeGet.cs create mode 100644 examples/FaxLineAreaCodeGet.java create mode 100644 examples/FaxLineAreaCodeGet.js create mode 100644 examples/FaxLineAreaCodeGet.php create mode 100644 examples/FaxLineAreaCodeGet.py create mode 100644 examples/FaxLineAreaCodeGet.rb create mode 100644 examples/FaxLineAreaCodeGet.sh create mode 100644 examples/FaxLineAreaCodeGet.ts create mode 100644 examples/FaxLineCreate.cs create mode 100644 examples/FaxLineCreate.java create mode 100644 examples/FaxLineCreate.js create mode 100644 examples/FaxLineCreate.php create mode 100644 examples/FaxLineCreate.py create mode 100644 examples/FaxLineCreate.rb create mode 100644 examples/FaxLineCreate.sh create mode 100644 examples/FaxLineCreate.ts create mode 100644 examples/FaxLineDelete.cs create mode 100644 examples/FaxLineDelete.java create mode 100644 examples/FaxLineDelete.js create mode 100644 examples/FaxLineDelete.php create mode 100644 examples/FaxLineDelete.py create mode 100644 examples/FaxLineDelete.rb create mode 100644 examples/FaxLineDelete.sh create mode 100644 examples/FaxLineDelete.ts create mode 100644 examples/FaxLineGet.cs create mode 100644 examples/FaxLineGet.java create mode 100644 examples/FaxLineGet.js create mode 100644 examples/FaxLineGet.php create mode 100644 examples/FaxLineGet.py create mode 100644 examples/FaxLineGet.rb create mode 100644 examples/FaxLineGet.sh create mode 100644 examples/FaxLineGet.ts create mode 100644 examples/FaxLineList.cs create mode 100644 examples/FaxLineList.java create mode 100644 examples/FaxLineList.js create mode 100644 examples/FaxLineList.php create mode 100644 examples/FaxLineList.py create mode 100644 examples/FaxLineList.rb create mode 100644 examples/FaxLineList.sh create mode 100644 examples/FaxLineList.ts create mode 100644 examples/FaxLineRemoveUser.cs create mode 100644 examples/FaxLineRemoveUser.java create mode 100644 examples/FaxLineRemoveUser.js create mode 100644 examples/FaxLineRemoveUser.php create mode 100644 examples/FaxLineRemoveUser.py create mode 100644 examples/FaxLineRemoveUser.rb create mode 100644 examples/FaxLineRemoveUser.sh create mode 100644 examples/FaxLineRemoveUser.ts create mode 100644 sdks/dotnet/docs/FaxLineAddUserRequest.md create mode 100644 sdks/dotnet/docs/FaxLineApi.md create mode 100644 sdks/dotnet/docs/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/dotnet/docs/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/dotnet/docs/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/dotnet/docs/FaxLineCreateRequest.md create mode 100644 sdks/dotnet/docs/FaxLineDeleteRequest.md create mode 100644 sdks/dotnet/docs/FaxLineListResponse.md create mode 100644 sdks/dotnet/docs/FaxLineRemoveUserRequest.md create mode 100644 sdks/dotnet/docs/FaxLineResponse.md create mode 100644 sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAddUserRequest.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetCountryEnum.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetProvinceEnum.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetStateEnum.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineDeleteRequest.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineRemoveUserRequest.cs create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs create mode 100644 sdks/java-v1/docs/FaxLineAddUserRequest.md create mode 100644 sdks/java-v1/docs/FaxLineApi.md create mode 100644 sdks/java-v1/docs/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/java-v1/docs/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/java-v1/docs/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/java-v1/docs/FaxLineCreateRequest.md create mode 100644 sdks/java-v1/docs/FaxLineDeleteRequest.md create mode 100644 sdks/java-v1/docs/FaxLineListResponse.md create mode 100644 sdks/java-v1/docs/FaxLineRemoveUserRequest.md create mode 100644 sdks/java-v1/docs/FaxLineResponse.md create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java create mode 100644 sdks/java-v2/docs/FaxLineAddUserRequest.md create mode 100644 sdks/java-v2/docs/FaxLineApi.md create mode 100644 sdks/java-v2/docs/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/java-v2/docs/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/java-v2/docs/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/java-v2/docs/FaxLineCreateRequest.md create mode 100644 sdks/java-v2/docs/FaxLineDeleteRequest.md create mode 100644 sdks/java-v2/docs/FaxLineListResponse.md create mode 100644 sdks/java-v2/docs/FaxLineRemoveUserRequest.md create mode 100644 sdks/java-v2/docs/FaxLineResponse.md create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java create mode 100644 sdks/node/api/faxLineApi.ts create mode 100644 sdks/node/docs/api/FaxLineApi.md create mode 100644 sdks/node/docs/model/FaxLineAddUserRequest.md create mode 100644 sdks/node/docs/model/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/node/docs/model/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/node/docs/model/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/node/docs/model/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/node/docs/model/FaxLineCreateRequest.md create mode 100644 sdks/node/docs/model/FaxLineDeleteRequest.md create mode 100644 sdks/node/docs/model/FaxLineListResponse.md create mode 100644 sdks/node/docs/model/FaxLineRemoveUserRequest.md create mode 100644 sdks/node/docs/model/FaxLineResponse.md create mode 100644 sdks/node/model/faxLineAddUserRequest.ts create mode 100644 sdks/node/model/faxLineAreaCodeGetCountryEnum.ts create mode 100644 sdks/node/model/faxLineAreaCodeGetProvinceEnum.ts create mode 100644 sdks/node/model/faxLineAreaCodeGetResponse.ts create mode 100644 sdks/node/model/faxLineAreaCodeGetStateEnum.ts create mode 100644 sdks/node/model/faxLineCreateRequest.ts create mode 100644 sdks/node/model/faxLineDeleteRequest.ts create mode 100644 sdks/node/model/faxLineListResponse.ts create mode 100644 sdks/node/model/faxLineRemoveUserRequest.ts create mode 100644 sdks/node/model/faxLineResponse.ts create mode 100644 sdks/node/types/api/faxLineApi.d.ts create mode 100644 sdks/node/types/model/faxLineAddUserRequest.d.ts create mode 100644 sdks/node/types/model/faxLineAreaCodeGetCountryEnum.d.ts create mode 100644 sdks/node/types/model/faxLineAreaCodeGetProvinceEnum.d.ts create mode 100644 sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts create mode 100644 sdks/node/types/model/faxLineAreaCodeGetStateEnum.d.ts create mode 100644 sdks/node/types/model/faxLineCreateRequest.d.ts create mode 100644 sdks/node/types/model/faxLineDeleteRequest.d.ts create mode 100644 sdks/node/types/model/faxLineListResponse.d.ts create mode 100644 sdks/node/types/model/faxLineRemoveUserRequest.d.ts create mode 100644 sdks/node/types/model/faxLineResponse.d.ts create mode 100644 sdks/php/docs/Api/FaxLineApi.md create mode 100644 sdks/php/docs/Model/FaxLineAddUserRequest.md create mode 100644 sdks/php/docs/Model/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/php/docs/Model/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/php/docs/Model/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/php/docs/Model/FaxLineCreateRequest.md create mode 100644 sdks/php/docs/Model/FaxLineDeleteRequest.md create mode 100644 sdks/php/docs/Model/FaxLineListResponse.md create mode 100644 sdks/php/docs/Model/FaxLineRemoveUserRequest.md create mode 100644 sdks/php/docs/Model/FaxLineResponse.md create mode 100644 sdks/php/src/Api/FaxLineApi.php create mode 100644 sdks/php/src/Model/FaxLineAddUserRequest.php create mode 100644 sdks/php/src/Model/FaxLineAreaCodeGetCountryEnum.php create mode 100644 sdks/php/src/Model/FaxLineAreaCodeGetProvinceEnum.php create mode 100644 sdks/php/src/Model/FaxLineAreaCodeGetResponse.php create mode 100644 sdks/php/src/Model/FaxLineAreaCodeGetStateEnum.php create mode 100644 sdks/php/src/Model/FaxLineCreateRequest.php create mode 100644 sdks/php/src/Model/FaxLineDeleteRequest.php create mode 100644 sdks/php/src/Model/FaxLineListResponse.php create mode 100644 sdks/php/src/Model/FaxLineRemoveUserRequest.php create mode 100644 sdks/php/src/Model/FaxLineResponse.php create mode 100644 sdks/python/docs/FaxLineAddUserRequest.md create mode 100644 sdks/python/docs/FaxLineApi.md create mode 100644 sdks/python/docs/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/python/docs/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/python/docs/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/python/docs/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/python/docs/FaxLineCreateRequest.md create mode 100644 sdks/python/docs/FaxLineDeleteRequest.md create mode 100644 sdks/python/docs/FaxLineListResponse.md create mode 100644 sdks/python/docs/FaxLineRemoveUserRequest.md create mode 100644 sdks/python/docs/FaxLineResponse.md create mode 100644 sdks/python/dropbox_sign/api/fax_line_api.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_add_user_request.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_area_code_get_country_enum.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_area_code_get_province_enum.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_area_code_get_state_enum.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_create_request.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_delete_request.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_list_response.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_remove_user_request.py create mode 100644 sdks/python/dropbox_sign/model/fax_line_response.py create mode 100644 sdks/ruby/docs/FaxLineAddUserRequest.md create mode 100644 sdks/ruby/docs/FaxLineApi.md create mode 100644 sdks/ruby/docs/FaxLineAreaCodeGetCountryEnum.md create mode 100644 sdks/ruby/docs/FaxLineAreaCodeGetProvinceEnum.md create mode 100644 sdks/ruby/docs/FaxLineAreaCodeGetResponse.md create mode 100644 sdks/ruby/docs/FaxLineAreaCodeGetStateEnum.md create mode 100644 sdks/ruby/docs/FaxLineCreateRequest.md create mode 100644 sdks/ruby/docs/FaxLineDeleteRequest.md create mode 100644 sdks/ruby/docs/FaxLineListResponse.md create mode 100644 sdks/ruby/docs/FaxLineRemoveUserRequest.md create mode 100644 sdks/ruby/docs/FaxLineResponse.md create mode 100644 sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb diff --git a/examples/FaxLineAddUser.cs b/examples/FaxLineAddUser.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.java b/examples/FaxLineAddUser.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.js b/examples/FaxLineAddUser.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.php b/examples/FaxLineAddUser.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.py b/examples/FaxLineAddUser.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.rb b/examples/FaxLineAddUser.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.sh b/examples/FaxLineAddUser.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAddUser.ts b/examples/FaxLineAddUser.ts new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.cs b/examples/FaxLineAreaCodeGet.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.java b/examples/FaxLineAreaCodeGet.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.js b/examples/FaxLineAreaCodeGet.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.php b/examples/FaxLineAreaCodeGet.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.py b/examples/FaxLineAreaCodeGet.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.rb b/examples/FaxLineAreaCodeGet.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.sh b/examples/FaxLineAreaCodeGet.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineAreaCodeGet.ts b/examples/FaxLineAreaCodeGet.ts new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.cs b/examples/FaxLineCreate.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.java b/examples/FaxLineCreate.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.js b/examples/FaxLineCreate.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.php b/examples/FaxLineCreate.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.py b/examples/FaxLineCreate.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.rb b/examples/FaxLineCreate.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.sh b/examples/FaxLineCreate.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineCreate.ts b/examples/FaxLineCreate.ts new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.cs b/examples/FaxLineDelete.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.java b/examples/FaxLineDelete.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.js b/examples/FaxLineDelete.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.php b/examples/FaxLineDelete.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.py b/examples/FaxLineDelete.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.rb b/examples/FaxLineDelete.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.sh b/examples/FaxLineDelete.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineDelete.ts b/examples/FaxLineDelete.ts new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.cs b/examples/FaxLineGet.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.java b/examples/FaxLineGet.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.js b/examples/FaxLineGet.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.php b/examples/FaxLineGet.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.py b/examples/FaxLineGet.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.rb b/examples/FaxLineGet.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.sh b/examples/FaxLineGet.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineGet.ts b/examples/FaxLineGet.ts new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.cs b/examples/FaxLineList.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.java b/examples/FaxLineList.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.js b/examples/FaxLineList.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.php b/examples/FaxLineList.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.py b/examples/FaxLineList.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.rb b/examples/FaxLineList.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.sh b/examples/FaxLineList.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineList.ts b/examples/FaxLineList.ts new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.cs b/examples/FaxLineRemoveUser.cs new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.java b/examples/FaxLineRemoveUser.java new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.js b/examples/FaxLineRemoveUser.js new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.php b/examples/FaxLineRemoveUser.php new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.py b/examples/FaxLineRemoveUser.py new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.rb b/examples/FaxLineRemoveUser.rb new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.sh b/examples/FaxLineRemoveUser.sh new file mode 100644 index 000000000..e69de29bb diff --git a/examples/FaxLineRemoveUser.ts b/examples/FaxLineRemoveUser.ts new file mode 100644 index 000000000..e69de29bb diff --git a/openapi-raw.yaml b/openapi-raw.yaml index b5f3915fb..1b7cb300f 100644 --- a/openapi-raw.yaml +++ b/openapi-raw.yaml @@ -1403,6 +1403,732 @@ paths: seo: title: '_t__EmbeddedSignUrl::SEO::TITLE' description: '_t__EmbeddedSignUrl::SEO::DESCRIPTION' + /fax_line/add_user: + post: + tags: + - 'Fax Line' + summary: '_t__FaxLineAddUser::SUMMARY' + description: '_t__FaxLineAddUser::DESCRIPTION' + operationId: faxLineAddUser + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineAddUserRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineAddUserRequestExample' + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineAddUser.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineAddUser.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineAddUser.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineAddUser.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineAddUser.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineAddUser.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineAddUser.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineAddUser.sh + x-meta: + seo: + title: '_t__FaxLineAddUser::SEO::TITLE' + description: '_t__FaxLineAddUser::SEO::DESCRIPTION' + /fax_line/area_codes: + get: + tags: + - 'Fax Line' + summary: '_t__FaxLineAreaCodeGet::SUMMARY' + description: '_t__FaxLineAreaCodeGet::DESCRIPTION' + operationId: faxLineAreaCodeGet + parameters: + - + name: country + in: query + description: '_t__FaxLineAreaCodeGet::COUNTRY' + required: true + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + - + name: state + in: query + description: '_t__FaxLineAreaCodeGet::STATE' + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetStateEnum' + - + name: province + in: query + description: '_t__FaxLineAreaCodeGet::PROVINCE' + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetProvinceEnum' + - + name: city + in: query + description: '_t__FaxLineAreaCodeGet::CITY' + schema: + type: string + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineAreaCodeGetResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineAreaCodeGet.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineAreaCodeGet.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineAreaCodeGet.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineAreaCodeGet.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineAreaCodeGet.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineAreaCodeGet.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineAreaCodeGet.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineAreaCodeGet.sh + x-meta: + seo: + title: '_t__FaxLineAreaCodeGet::SEO::TITLE' + description: '_t__FaxLineAreaCodeGet::SEO::DESCRIPTION' + /fax_line/create: + post: + tags: + - 'Fax Line' + summary: '_t__FaxLineCreate::SUMMARY' + description: '_t__FaxLineCreate::DESCRIPTION' + operationId: faxLineCreate + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineCreateRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineCreateRequestExample' + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineCreate.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineCreate.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineCreate.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineCreate.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineCreate.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineCreate.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineCreate.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineCreate.sh + x-meta: + seo: + title: '_t__FaxLineCreate::SEO::TITLE' + description: '_t__FaxLineCreate::SEO::DESCRIPTION' + /fax_line/delete: + delete: + tags: + - 'Fax Line' + summary: '_t__FaxLineDelete::SUMMARY' + description: '_t__FaxLineDelete::DESCRIPTION' + operationId: faxLineDelete + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineDeleteRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineDeleteRequestExample' + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: { } + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineDelete.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineDelete.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineDelete.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineDelete.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineDelete.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineDelete.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineDelete.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineDelete.sh + x-meta: + seo: + title: '_t__FaxLineDelete::SEO::TITLE' + description: '_t__FaxLineDelete::SEO::DESCRIPTION' + '/fax_line/{number}': + get: + tags: + - 'Fax Line' + summary: '_t__FaxLineGet::SUMMARY' + description: '_t__FaxLineGet::DESCRIPTION' + operationId: faxLineGet + parameters: + - + name: number + in: path + description: '_t__FaxLineGet::NUMBER' + required: true + schema: + type: string + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineGet.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineGet.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineGet.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineGet.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineGet.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineGet.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineGet.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineGet.sh + x-meta: + seo: + title: '_t__FaxLineGet::SEO::TITLE' + description: '_t__FaxLineGet::SEO::DESCRIPTION' + /fax_line/list: + get: + tags: + - 'Fax Line' + summary: '_t__FaxLineList::SUMMARY' + description: '_t__FaxLineList::DESCRIPTION' + operationId: faxLineList + parameters: + - + name: account_id + in: query + description: '_t__FaxLineList::ACCOUNT_ID' + schema: + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + - + name: page + in: query + description: '_t__FaxLineList::PAGE' + schema: + type: integer + example: 1 + - + name: page_size + in: query + description: '_t__FaxLineList::PAGE_SIZE' + schema: + type: integer + example: 20 + - + name: show_team_lines + in: query + description: '_t__FaxLineList::SHOW_TEAM_LINES' + schema: + type: boolean + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineListResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineListResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineList.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineList.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineList.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineList.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineList.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineList.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineList.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineList.sh + x-meta: + seo: + title: '_t__FaxLineList::SEO::TITLE' + description: '_t__FaxLineList::SEO::DESCRIPTION' + /fax_line/remove_user: + post: + tags: + - 'Fax Line' + summary: '_t__FaxLineRemoveUser::SUMMARY' + description: '_t__FaxLineRemoveUser::DESCRIPTION' + operationId: faxLineRemoveUser + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineRemoveUserRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineRemoveUserRequestExample' + responses: + '200': + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineRemoveUser.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineRemoveUser.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineRemoveUser.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineRemoveUser.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineRemoveUser.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineRemoveUser.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineRemoveUser.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineRemoveUser.sh + x-meta: + seo: + title: '_t__FaxLineRemoveUser::SEO::TITLE' + description: '_t__FaxLineRemoveUser::SEO::DESCRIPTION' /oauth/token: post: tags: @@ -6315,6 +7041,141 @@ components: type: boolean default: false type: object + FaxLineAddUserRequest: + required: + - number + properties: + number: + description: '_t__FaxLineAddUser::NUMBER' + type: string + account_id: + description: '_t__FaxLineAddUser::ACCOUNT_ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + email_address: + description: '_t__FaxLineCreate::EMAIL_ADDRESS' + type: string + format: email + type: object + FaxLineAreaCodeGetStateEnum: + type: string + enum: + - AK + - AL + - AR + - AZ + - CA + - CO + - CT + - DC + - DE + - FL + - GA + - HI + - IA + - ID + - IL + - IN + - KS + - KY + - LA + - MA + - MD + - ME + - MI + - MN + - MO + - MS + - MT + - NC + - ND + - NE + - NH + - NJ + - NM + - NV + - NY + - OH + - OK + - OR + - PA + - RI + - SC + - SD + - TN + - TX + - UT + - VA + - VT + - WA + - WI + - WV + - WY + FaxLineAreaCodeGetProvinceEnum: + type: string + enum: + - AB + - BC + - MB + - NB + - NL + - NT + - NS + - NU + - 'ON' + - PE + - QC + - SK + - YT + FaxLineAreaCodeGetCountryEnum: + type: string + enum: + - CA + - US + - UK + FaxLineCreateRequest: + required: + - area_code + - country + - city + properties: + area_code: + description: '_t__FaxLineCreate::AREA_CODE' + type: string + country: + $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + city: + description: '_t__FaxLineCreate::CITY' + type: string + account_id: + description: '_t__FaxLineCreate::ACCOUNT_ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + type: object + FaxLineDeleteRequest: + required: + - number + properties: + number: + description: '_t__FaxLineDelete::NUMBER' + type: string + type: object + FaxLineRemoveUserRequest: + required: + - number + properties: + number: + description: '_t__FaxLineDelete::NUMBER' + type: string + account_id: + description: '_t__FaxLineCreate::ACCOUNT_ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + email_address: + description: '_t__FaxLineCreate::EMAIL_ADDRESS' + type: string + format: email + type: object OAuthTokenGenerateRequest: required: - client_id @@ -8645,6 +9506,34 @@ components: error: $ref: '#/components/schemas/ErrorResponseError' type: object + FaxLineResponse: + properties: + fax_line: + $ref: '#/components/schemas/FaxLineResponse' + warnings: + $ref: '#/components/schemas/WarningResponse' + type: object + x-internal: true + FaxLineAreaCodeGetResponse: + properties: + area_codes: + type: array + items: + type: string + type: object + x-internal: true + FaxLineListResponse: + properties: + list_info: + $ref: '#/components/schemas/ListInfoResponse' + fax_lines: + type: array + items: + $ref: '#/components/schemas/FaxLineResponse' + warnings: + $ref: '#/components/schemas/WarningResponse' + type: object + x-internal: true FileResponse: properties: file_url: @@ -10558,6 +11447,22 @@ components: summary: 'Default Example' value: $ref: examples/json/EmbeddedEditUrlRequestDefaultExample.json + FaxLineAddUserRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineAddUserRequestExample.json + FaxLineCreateRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineCreateRequestExample.json + FaxLineDeleteRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineDeleteRequestExample.json + FaxLineRemoveUserRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineRemoveUserRequestExample.json OAuthTokenGenerateRequestExample: summary: 'OAuth Token Generate Example' value: @@ -10802,6 +11707,18 @@ components: summary: '_t__Error::4XX' value: $ref: examples/json/Error4XXResponseExample.json + FaxLineResponseExample: + summary: '_t__FaxLineResponseExample::SUMMARY' + value: + $ref: examples/json/FaxLineResponseExample.json + FaxLineAreaCodeGetResponseExample: + summary: '_t__FaxLineAreaCodeGetResponseExample::SUMMARY' + value: + $ref: examples/json/FaxLineAreaCodeGetResponseExample.json + FaxLineListResponseExample: + summary: '_t__FaxLineListResponseExample::SUMMARY' + value: + $ref: examples/json/FaxLineListResponseExample.json ReportCreateResponseExample: summary: '_t__ReportCreateResponseExample::SUMMARY' value: diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index 9bf5a68ea..0c6798e27 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -1409,6 +1409,732 @@ paths: seo: title: 'Get Embedded Sign URL | iFrame | Dropbox Sign for Developers' description: 'The Dropbox Sign API allows you to build custom integrations. To find out how to retrieve an embedded iFrame object containing a signature url, click here.' + /fax_line/add_user: + post: + tags: + - 'Fax Line' + summary: 'Add Fax Line User' + description: 'Grants a user access to the specified Fax Line.' + operationId: faxLineAddUser + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineAddUserRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineAddUserRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineAddUser.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineAddUser.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineAddUser.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineAddUser.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineAddUser.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineAddUser.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineAddUser.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineAddUser.sh + x-meta: + seo: + title: 'Fax Line Add User | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to add a user to an existing fax line, click here.' + /fax_line/area_codes: + get: + tags: + - 'Fax Line' + summary: 'Get Available Fax Line Area Codes' + description: 'Returns a response with the area codes available for a given state/provice and city.' + operationId: faxLineAreaCodeGet + parameters: + - + name: country + in: query + description: 'Filter area codes by country.' + required: true + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + - + name: state + in: query + description: 'Filter area codes by state.' + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetStateEnum' + - + name: province + in: query + description: 'Filter area codes by province.' + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetProvinceEnum' + - + name: city + in: query + description: 'Filter area codes by city.' + schema: + type: string + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineAreaCodeGetResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineAreaCodeGet.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineAreaCodeGet.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineAreaCodeGet.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineAreaCodeGet.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineAreaCodeGet.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineAreaCodeGet.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineAreaCodeGet.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineAreaCodeGet.sh + x-meta: + seo: + title: 'Fax Line Get Area Codes | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here.' + /fax_line/create: + post: + tags: + - 'Fax Line' + summary: 'Purchase Fax Line' + description: 'Purchases a new Fax Line.' + operationId: faxLineCreate + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineCreateRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineCreateRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineCreate.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineCreate.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineCreate.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineCreate.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineCreate.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineCreate.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineCreate.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineCreate.sh + x-meta: + seo: + title: 'Purchase Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here.' + /fax_line/delete: + delete: + tags: + - 'Fax Line' + summary: 'Delete Fax Line' + description: 'Deletes the specified Fax Line from the subscription.' + operationId: faxLineDelete + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineDeleteRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineDeleteRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: {} + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineDelete.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineDelete.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineDelete.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineDelete.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineDelete.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineDelete.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineDelete.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineDelete.sh + x-meta: + seo: + title: 'Delete Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here.' + '/fax_line/{number}': + get: + tags: + - 'Fax Line' + summary: 'Get Fax Line' + description: 'Returns the properties and settings of a Fax Line.' + operationId: faxLineGet + parameters: + - + name: number + in: path + description: 'The Fax Line number.' + required: true + schema: + type: string + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineGet.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineGet.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineGet.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineGet.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineGet.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineGet.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineGet.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineGet.sh + x-meta: + seo: + title: 'Get Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here.' + /fax_line/list: + get: + tags: + - 'Fax Line' + summary: 'List Fax Lines' + description: 'Returns the properties and settings of multiple Fax Lines.' + operationId: faxLineList + parameters: + - + name: account_id + in: query + description: 'Account ID' + schema: + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + - + name: page + in: query + description: Page + schema: + type: integer + example: 1 + - + name: page_size + in: query + description: 'Page size' + schema: + type: integer + example: 20 + - + name: show_team_lines + in: query + description: 'Show team lines' + schema: + type: boolean + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineListResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineListResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineList.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineList.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineList.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineList.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineList.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineList.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineList.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineList.sh + x-meta: + seo: + title: 'List Fax Lines | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to list your fax lines, click here.' + /fax_line/remove_user: + post: + tags: + - 'Fax Line' + summary: 'Remove Fax Line Access' + description: 'Removes a user''s access to the specified Fax Line.' + operationId: faxLineRemoveUser + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineRemoveUserRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineRemoveUserRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineRemoveUser.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineRemoveUser.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineRemoveUser.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineRemoveUser.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineRemoveUser.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineRemoveUser.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineRemoveUser.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineRemoveUser.sh + x-meta: + seo: + title: 'Fax Line Remove User | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to remove a user from an existing fax line, click here.' /oauth/token: post: tags: @@ -6409,6 +7135,141 @@ components: type: boolean default: false type: object + FaxLineAddUserRequest: + required: + - number + properties: + number: + description: 'The Fax Line number.' + type: string + account_id: + description: 'Account ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + email_address: + description: 'Email address' + type: string + format: email + type: object + FaxLineAreaCodeGetStateEnum: + type: string + enum: + - AK + - AL + - AR + - AZ + - CA + - CO + - CT + - DC + - DE + - FL + - GA + - HI + - IA + - ID + - IL + - IN + - KS + - KY + - LA + - MA + - MD + - ME + - MI + - MN + - MO + - MS + - MT + - NC + - ND + - NE + - NH + - NJ + - NM + - NV + - NY + - OH + - OK + - OR + - PA + - RI + - SC + - SD + - TN + - TX + - UT + - VA + - VT + - WA + - WI + - WV + - WY + FaxLineAreaCodeGetProvinceEnum: + type: string + enum: + - AB + - BC + - MB + - NB + - NL + - NT + - NS + - NU + - 'ON' + - PE + - QC + - SK + - YT + FaxLineAreaCodeGetCountryEnum: + type: string + enum: + - CA + - US + - UK + FaxLineCreateRequest: + required: + - area_code + - country + - city + properties: + area_code: + description: 'Area code' + type: string + country: + $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + city: + description: City + type: string + account_id: + description: 'Account ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + type: object + FaxLineDeleteRequest: + required: + - number + properties: + number: + description: 'The Fax Line number.' + type: string + type: object + FaxLineRemoveUserRequest: + required: + - number + properties: + number: + description: 'The Fax Line number.' + type: string + account_id: + description: 'Account ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + email_address: + description: 'Email address' + type: string + format: email + type: object OAuthTokenGenerateRequest: required: - client_id @@ -9253,6 +10114,34 @@ components: error: $ref: '#/components/schemas/ErrorResponseError' type: object + FaxLineResponse: + properties: + fax_line: + $ref: '#/components/schemas/FaxLineResponse' + warnings: + $ref: '#/components/schemas/WarningResponse' + type: object + x-internal: true + FaxLineAreaCodeGetResponse: + properties: + area_codes: + type: array + items: + type: string + type: object + x-internal: true + FaxLineListResponse: + properties: + list_info: + $ref: '#/components/schemas/ListInfoResponse' + fax_lines: + type: array + items: + $ref: '#/components/schemas/FaxLineResponse' + warnings: + $ref: '#/components/schemas/WarningResponse' + type: object + x-internal: true FileResponse: properties: file_url: @@ -11350,6 +12239,22 @@ components: summary: 'Default Example' value: $ref: examples/json/EmbeddedEditUrlRequestDefaultExample.json + FaxLineAddUserRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineAddUserRequestExample.json + FaxLineCreateRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineCreateRequestExample.json + FaxLineDeleteRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineDeleteRequestExample.json + FaxLineRemoveUserRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineRemoveUserRequestExample.json OAuthTokenGenerateRequestExample: summary: 'OAuth Token Generate Example' value: @@ -11594,6 +12499,18 @@ components: summary: 'Error 4XX failed_operation' value: $ref: examples/json/Error4XXResponseExample.json + FaxLineResponseExample: + summary: 'Sample Fax Line Response' + value: + $ref: examples/json/FaxLineResponseExample.json + FaxLineAreaCodeGetResponseExample: + summary: 'Sample Area Code Response' + value: + $ref: examples/json/FaxLineAreaCodeGetResponseExample.json + FaxLineListResponseExample: + summary: 'Sample Fax Line List Response' + value: + $ref: examples/json/FaxLineListResponseExample.json ReportCreateResponseExample: summary: Report value: diff --git a/openapi.yaml b/openapi.yaml index 63b2059ab..5bb23ff13 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1409,6 +1409,732 @@ paths: seo: title: 'Get Embedded Sign URL | iFrame | Dropbox Sign for Developers' description: 'The Dropbox Sign API allows you to build custom integrations. To find out how to retrieve an embedded iFrame object containing a signature url, click here.' + /fax_line/add_user: + post: + tags: + - 'Fax Line' + summary: 'Add Fax Line User' + description: 'Grants a user access to the specified Fax Line.' + operationId: faxLineAddUser + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineAddUserRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineAddUserRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineAddUser.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineAddUser.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineAddUser.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineAddUser.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineAddUser.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineAddUser.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineAddUser.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineAddUser.sh + x-meta: + seo: + title: 'Fax Line Add User | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to add a user to an existing fax line, click here.' + /fax_line/area_codes: + get: + tags: + - 'Fax Line' + summary: 'Get Available Fax Line Area Codes' + description: 'Returns a response with the area codes available for a given state/provice and city.' + operationId: faxLineAreaCodeGet + parameters: + - + name: country + in: query + description: 'Filter area codes by country.' + required: true + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + - + name: state + in: query + description: 'Filter area codes by state.' + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetStateEnum' + - + name: province + in: query + description: 'Filter area codes by province.' + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetProvinceEnum' + - + name: city + in: query + description: 'Filter area codes by city.' + schema: + type: string + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineAreaCodeGetResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineAreaCodeGetResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineAreaCodeGet.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineAreaCodeGet.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineAreaCodeGet.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineAreaCodeGet.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineAreaCodeGet.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineAreaCodeGet.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineAreaCodeGet.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineAreaCodeGet.sh + x-meta: + seo: + title: 'Fax Line Get Area Codes | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here.' + /fax_line/create: + post: + tags: + - 'Fax Line' + summary: 'Purchase Fax Line' + description: 'Purchases a new Fax Line.' + operationId: faxLineCreate + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineCreateRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineCreateRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineCreate.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineCreate.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineCreate.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineCreate.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineCreate.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineCreate.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineCreate.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineCreate.sh + x-meta: + seo: + title: 'Purchase Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here.' + /fax_line/delete: + delete: + tags: + - 'Fax Line' + summary: 'Delete Fax Line' + description: 'Deletes the specified Fax Line from the subscription.' + operationId: faxLineDelete + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineDeleteRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineDeleteRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: {} + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineDelete.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineDelete.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineDelete.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineDelete.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineDelete.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineDelete.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineDelete.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineDelete.sh + x-meta: + seo: + title: 'Delete Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here.' + '/fax_line/{number}': + get: + tags: + - 'Fax Line' + summary: 'Get Fax Line' + description: 'Returns the properties and settings of a Fax Line.' + operationId: faxLineGet + parameters: + - + name: number + in: path + description: 'The Fax Line number.' + required: true + schema: + type: string + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineGet.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineGet.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineGet.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineGet.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineGet.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineGet.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineGet.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineGet.sh + x-meta: + seo: + title: 'Get Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here.' + /fax_line/list: + get: + tags: + - 'Fax Line' + summary: 'List Fax Lines' + description: 'Returns the properties and settings of multiple Fax Lines.' + operationId: faxLineList + parameters: + - + name: account_id + in: query + description: 'Account ID' + schema: + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + - + name: page + in: query + description: Page + schema: + type: integer + example: 1 + - + name: page_size + in: query + description: 'Page size' + schema: + type: integer + example: 20 + - + name: show_team_lines + in: query + description: 'Show team lines' + schema: + type: boolean + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineListResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineListResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineList.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineList.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineList.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineList.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineList.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineList.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineList.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineList.sh + x-meta: + seo: + title: 'List Fax Lines | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to list your fax lines, click here.' + /fax_line/remove_user: + post: + tags: + - 'Fax Line' + summary: 'Remove Fax Line Access' + description: 'Removes a user''s access to the specified Fax Line.' + operationId: faxLineRemoveUser + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineRemoveUserRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineRemoveUserRequestExample' + responses: + 200: + description: 'successful operation' + headers: + X-RateLimit-Limit: + $ref: '#/components/headers/X-RateLimit-Limit' + X-RateLimit-Remaining: + $ref: '#/components/headers/X-RateLimit-Remaining' + X-Ratelimit-Reset: + $ref: '#/components/headers/X-Ratelimit-Reset' + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' + 4XX: + description: failed_operation + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + examples: + 400_example: + $ref: '#/components/examples/Error400ResponseExample' + 401_example: + $ref: '#/components/examples/Error401ResponseExample' + 402_example: + $ref: '#/components/examples/Error402ResponseExample' + 403_example: + $ref: '#/components/examples/Error403ResponseExample' + 404_example: + $ref: '#/components/examples/Error404ResponseExample' + 4XX_example: + $ref: '#/components/examples/Error4XXResponseExample' + security: + - + api_key: [] + x-codeSamples: + - + lang: PHP + label: PHP + source: + $ref: examples/FaxLineRemoveUser.php + - + lang: 'C#' + label: 'C#' + source: + $ref: examples/FaxLineRemoveUser.cs + - + lang: JavaScript + label: JavaScript + source: + $ref: examples/FaxLineRemoveUser.js + - + lang: TypeScript + label: TypeScript + source: + $ref: examples/FaxLineRemoveUser.ts + - + lang: Java + label: Java + source: + $ref: examples/FaxLineRemoveUser.java + - + lang: Ruby + label: Ruby + source: + $ref: examples/FaxLineRemoveUser.rb + - + lang: Python + label: Python + source: + $ref: examples/FaxLineRemoveUser.py + - + lang: cURL + label: cURL + source: + $ref: examples/FaxLineRemoveUser.sh + x-meta: + seo: + title: 'Fax Line Remove User | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to remove a user from an existing fax line, click here.' /oauth/token: post: tags: @@ -6409,6 +7135,141 @@ components: type: boolean default: false type: object + FaxLineAddUserRequest: + required: + - number + properties: + number: + description: 'The Fax Line number.' + type: string + account_id: + description: 'Account ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + email_address: + description: 'Email address' + type: string + format: email + type: object + FaxLineAreaCodeGetStateEnum: + type: string + enum: + - AK + - AL + - AR + - AZ + - CA + - CO + - CT + - DC + - DE + - FL + - GA + - HI + - IA + - ID + - IL + - IN + - KS + - KY + - LA + - MA + - MD + - ME + - MI + - MN + - MO + - MS + - MT + - NC + - ND + - NE + - NH + - NJ + - NM + - NV + - NY + - OH + - OK + - OR + - PA + - RI + - SC + - SD + - TN + - TX + - UT + - VA + - VT + - WA + - WI + - WV + - WY + FaxLineAreaCodeGetProvinceEnum: + type: string + enum: + - AB + - BC + - MB + - NB + - NL + - NT + - NS + - NU + - 'ON' + - PE + - QC + - SK + - YT + FaxLineAreaCodeGetCountryEnum: + type: string + enum: + - CA + - US + - UK + FaxLineCreateRequest: + required: + - area_code + - country + - city + properties: + area_code: + description: 'Area code' + type: string + country: + $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + city: + description: City + type: string + account_id: + description: 'Account ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + type: object + FaxLineDeleteRequest: + required: + - number + properties: + number: + description: 'The Fax Line number.' + type: string + type: object + FaxLineRemoveUserRequest: + required: + - number + properties: + number: + description: 'The Fax Line number.' + type: string + account_id: + description: 'Account ID' + type: string + example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 + email_address: + description: 'Email address' + type: string + format: email + type: object OAuthTokenGenerateRequest: required: - client_id @@ -9231,6 +10092,34 @@ components: error: $ref: '#/components/schemas/ErrorResponseError' type: object + FaxLineResponse: + properties: + fax_line: + $ref: '#/components/schemas/FaxLineResponse' + warnings: + $ref: '#/components/schemas/WarningResponse' + type: object + x-internal: true + FaxLineAreaCodeGetResponse: + properties: + area_codes: + type: array + items: + type: string + type: object + x-internal: true + FaxLineListResponse: + properties: + list_info: + $ref: '#/components/schemas/ListInfoResponse' + fax_lines: + type: array + items: + $ref: '#/components/schemas/FaxLineResponse' + warnings: + $ref: '#/components/schemas/WarningResponse' + type: object + x-internal: true FileResponse: properties: file_url: @@ -11328,6 +12217,22 @@ components: summary: 'Default Example' value: $ref: examples/json/EmbeddedEditUrlRequestDefaultExample.json + FaxLineAddUserRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineAddUserRequestExample.json + FaxLineCreateRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineCreateRequestExample.json + FaxLineDeleteRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineDeleteRequestExample.json + FaxLineRemoveUserRequestExample: + summary: 'Default Example' + value: + $ref: examples/json/FaxLineRemoveUserRequestExample.json OAuthTokenGenerateRequestExample: summary: 'OAuth Token Generate Example' value: @@ -11572,6 +12477,18 @@ components: summary: 'Error 4XX failed_operation' value: $ref: examples/json/Error4XXResponseExample.json + FaxLineResponseExample: + summary: 'Sample Fax Line Response' + value: + $ref: examples/json/FaxLineResponseExample.json + FaxLineAreaCodeGetResponseExample: + summary: 'Sample Area Code Response' + value: + $ref: examples/json/FaxLineAreaCodeGetResponseExample.json + FaxLineListResponseExample: + summary: 'Sample Fax Line List Response' + value: + $ref: examples/json/FaxLineListResponseExample.json ReportCreateResponseExample: summary: Report value: diff --git a/sdks/dotnet/README.md b/sdks/dotnet/README.md index 19444f601..f9358f79a 100644 --- a/sdks/dotnet/README.md +++ b/sdks/dotnet/README.md @@ -137,6 +137,13 @@ Class | Method | HTTP request | Description *BulkSendJobApi* | [**BulkSendJobList**](docs/BulkSendJobApi.md#bulksendjoblist) | **GET** /bulk_send_job/list | List Bulk Send Jobs *EmbeddedApi* | [**EmbeddedEditUrl**](docs/EmbeddedApi.md#embeddedediturl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL *EmbeddedApi* | [**EmbeddedSignUrl**](docs/EmbeddedApi.md#embeddedsignurl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL +*FaxLineApi* | [**FaxLineAddUser**](docs/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User +*FaxLineApi* | [**FaxLineAreaCodeGet**](docs/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes +*FaxLineApi* | [**FaxLineCreate**](docs/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line +*FaxLineApi* | [**FaxLineDelete**](docs/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line +*FaxLineApi* | [**FaxLineGet**](docs/FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line +*FaxLineApi* | [**FaxLineList**](docs/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines +*FaxLineApi* | [**FaxLineRemoveUser**](docs/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**OauthTokenGenerate**](docs/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate *OAuthApi* | [**OauthTokenRefresh**](docs/OAuthApi.md#oauthtokenrefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh *ReportApi* | [**ReportCreate**](docs/ReportApi.md#reportcreate) | **POST** /report/create | Create Report @@ -220,6 +227,16 @@ Class | Method | HTTP request | Description - [Model.EventCallbackRequest](docs/EventCallbackRequest.md) - [Model.EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [Model.EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [Model.FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) + - [Model.FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) + - [Model.FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) + - [Model.FaxLineAreaCodeGetResponse](docs/FaxLineAreaCodeGetResponse.md) + - [Model.FaxLineAreaCodeGetStateEnum](docs/FaxLineAreaCodeGetStateEnum.md) + - [Model.FaxLineCreateRequest](docs/FaxLineCreateRequest.md) + - [Model.FaxLineDeleteRequest](docs/FaxLineDeleteRequest.md) + - [Model.FaxLineListResponse](docs/FaxLineListResponse.md) + - [Model.FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) + - [Model.FaxLineResponse](docs/FaxLineResponse.md) - [Model.FileResponse](docs/FileResponse.md) - [Model.FileResponseDataUri](docs/FileResponseDataUri.md) - [Model.ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/dotnet/docs/FaxLineAddUserRequest.md b/sdks/dotnet/docs/FaxLineAddUserRequest.md new file mode 100644 index 000000000..16d672e58 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineAddUserRequest.md @@ -0,0 +1,12 @@ +# Dropbox.Sign.Model.FaxLineAddUserRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Number** | **string** | The Fax Line number. | +**AccountId** | **string** | Account ID | [optional] +**EmailAddress** | **string** | Email address | [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/sdks/dotnet/docs/FaxLineApi.md b/sdks/dotnet/docs/FaxLineApi.md new file mode 100644 index 000000000..c97e9d57f --- /dev/null +++ b/sdks/dotnet/docs/FaxLineApi.md @@ -0,0 +1,444 @@ +# Dropbox.Sign.Api.FaxLineApi + +All URIs are relative to *https://api.hellosign.com/v3* + +| Method | HTTP request | Description | +|--------|--------------|-------------| +| [**FaxLineAddUser**](FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | +| [**FaxLineAreaCodeGet**](FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | +| [**FaxLineCreate**](FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | +| [**FaxLineDelete**](FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line | +| [**FaxLineGet**](FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line | +| [**FaxLineList**](FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | +| [**FaxLineRemoveUser**](FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | + + +# **FaxLineAddUser** +> FaxLineResponse FaxLineAddUser (FaxLineAddUserRequest faxLineAddUserRequest) + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### Example +```csharp + +``` + +#### Using the FaxLineAddUserWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // Add Fax Line User + ApiResponse response = apiInstance.FaxLineAddUserWithHttpInfo(faxLineAddUserRequest); + Debug.Write("Status Code: " + response.StatusCode); + Debug.Write("Response Headers: " + response.Headers); + Debug.Write("Response Body: " + response.Data); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineAddUserWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **faxLineAddUserRequest** | [**FaxLineAddUserRequest**](FaxLineAddUserRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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) + + +# **FaxLineAreaCodeGet** +> FaxLineAreaCodeGetResponse FaxLineAreaCodeGet (FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = null, FaxLineAreaCodeGetProvinceEnum? province = null, string? city = null) + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### Example +```csharp + +``` + +#### Using the FaxLineAreaCodeGetWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // Get Available Fax Line Area Codes + ApiResponse response = apiInstance.FaxLineAreaCodeGetWithHttpInfo(country, state, province, city); + Debug.Write("Status Code: " + response.StatusCode); + Debug.Write("Response Headers: " + response.Headers); + Debug.Write("Response Body: " + response.Data); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineAreaCodeGetWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **country** | **FaxLineAreaCodeGetCountryEnum** | Filter area codes by country. | | +| **state** | [**FaxLineAreaCodeGetStateEnum?**](FaxLineAreaCodeGetStateEnum?.md) | Filter area codes by state. | [optional] | +| **province** | [**FaxLineAreaCodeGetProvinceEnum?**](FaxLineAreaCodeGetProvinceEnum?.md) | Filter area codes by province. | [optional] | +| **city** | **string?** | Filter area codes by city. | [optional] | + +### Return type + +[**FaxLineAreaCodeGetResponse**](FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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) + + +# **FaxLineCreate** +> FaxLineResponse FaxLineCreate (FaxLineCreateRequest faxLineCreateRequest) + +Purchase Fax Line + +Purchases a new Fax Line. + +### Example +```csharp + +``` + +#### Using the FaxLineCreateWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // Purchase Fax Line + ApiResponse response = apiInstance.FaxLineCreateWithHttpInfo(faxLineCreateRequest); + Debug.Write("Status Code: " + response.StatusCode); + Debug.Write("Response Headers: " + response.Headers); + Debug.Write("Response Body: " + response.Data); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineCreateWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **faxLineCreateRequest** | [**FaxLineCreateRequest**](FaxLineCreateRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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) + + +# **FaxLineDelete** +> void FaxLineDelete (FaxLineDeleteRequest faxLineDeleteRequest) + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### Example +```csharp + +``` + +#### Using the FaxLineDeleteWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // Delete Fax Line + apiInstance.FaxLineDeleteWithHttpInfo(faxLineDeleteRequest); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineDeleteWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **faxLineDeleteRequest** | [**FaxLineDeleteRequest**](FaxLineDeleteRequest.md) | | | + +### Return type + +void (empty response body) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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) + + +# **FaxLineGet** +> FaxLineResponse FaxLineGet (string number) + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### Example +```csharp + +``` + +#### Using the FaxLineGetWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // Get Fax Line + ApiResponse response = apiInstance.FaxLineGetWithHttpInfo(number); + Debug.Write("Status Code: " + response.StatusCode); + Debug.Write("Response Headers: " + response.Headers); + Debug.Write("Response Body: " + response.Data); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineGetWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **number** | **string** | The Fax Line number. | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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) + + +# **FaxLineList** +> FaxLineListResponse FaxLineList (string? accountId = null, int? page = null, int? pageSize = null, bool? showTeamLines = null) + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### Example +```csharp + +``` + +#### Using the FaxLineListWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // List Fax Lines + ApiResponse response = apiInstance.FaxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + Debug.Write("Status Code: " + response.StatusCode); + Debug.Write("Response Headers: " + response.Headers); + Debug.Write("Response Body: " + response.Data); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineListWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **accountId** | **string?** | Account ID | [optional] | +| **page** | **int?** | Page | [optional] | +| **pageSize** | **int?** | Page size | [optional] | +| **showTeamLines** | **bool?** | Show team lines | [optional] | + +### Return type + +[**FaxLineListResponse**](FaxLineListResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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) + + +# **FaxLineRemoveUser** +> FaxLineResponse FaxLineRemoveUser (FaxLineRemoveUserRequest faxLineRemoveUserRequest) + +Remove Fax Line Access + +Removes a user's access to the specified Fax Line. + +### Example +```csharp + +``` + +#### Using the FaxLineRemoveUserWithHttpInfo variant +This returns an ApiResponse object which contains the response data, status code and headers. + +```csharp +try +{ + // Remove Fax Line Access + ApiResponse response = apiInstance.FaxLineRemoveUserWithHttpInfo(faxLineRemoveUserRequest); + Debug.Write("Status Code: " + response.StatusCode); + Debug.Write("Response Headers: " + response.Headers); + Debug.Write("Response Body: " + response.Data); +} +catch (ApiException e) +{ + Debug.Print("Exception when calling FaxLineApi.FaxLineRemoveUserWithHttpInfo: " + e.Message); + Debug.Print("Status Code: " + e.ErrorCode); + Debug.Print(e.StackTrace); +} +``` + +### Parameters + +| Name | Type | Description | Notes | +|------|------|-------------|-------| +| **faxLineRemoveUserRequest** | [**FaxLineRemoveUserRequest**](FaxLineRemoveUserRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + +[[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/sdks/dotnet/docs/FaxLineAreaCodeGetCountryEnum.md b/sdks/dotnet/docs/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..fa6c2e31b --- /dev/null +++ b/sdks/dotnet/docs/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,9 @@ +# Dropbox.Sign.Model.FaxLineAreaCodeGetCountryEnum + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[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/sdks/dotnet/docs/FaxLineAreaCodeGetProvinceEnum.md b/sdks/dotnet/docs/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..ad9e935c5 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,9 @@ +# Dropbox.Sign.Model.FaxLineAreaCodeGetProvinceEnum + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[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/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md b/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..acd41c460 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,10 @@ +# Dropbox.Sign.Model.FaxLineAreaCodeGetResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AreaCodes** | **List<string>** | | [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/sdks/dotnet/docs/FaxLineAreaCodeGetStateEnum.md b/sdks/dotnet/docs/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..f63df05ce --- /dev/null +++ b/sdks/dotnet/docs/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,9 @@ +# Dropbox.Sign.Model.FaxLineAreaCodeGetStateEnum + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[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/sdks/dotnet/docs/FaxLineCreateRequest.md b/sdks/dotnet/docs/FaxLineCreateRequest.md new file mode 100644 index 000000000..d2789845b --- /dev/null +++ b/sdks/dotnet/docs/FaxLineCreateRequest.md @@ -0,0 +1,13 @@ +# Dropbox.Sign.Model.FaxLineCreateRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AreaCode** | **string** | Area code | +**Country** | **FaxLineAreaCodeGetCountryEnum** | | +**City** | **string** | City | +**AccountId** | **string** | Account ID | [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/sdks/dotnet/docs/FaxLineDeleteRequest.md b/sdks/dotnet/docs/FaxLineDeleteRequest.md new file mode 100644 index 000000000..673880d28 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineDeleteRequest.md @@ -0,0 +1,10 @@ +# Dropbox.Sign.Model.FaxLineDeleteRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Number** | **string** | The Fax Line number. | + +[[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/sdks/dotnet/docs/FaxLineListResponse.md b/sdks/dotnet/docs/FaxLineListResponse.md new file mode 100644 index 000000000..a8e55b5d1 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineListResponse.md @@ -0,0 +1,12 @@ +# Dropbox.Sign.Model.FaxLineListResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**ListInfo** | [**ListInfoResponse**](ListInfoResponse.md) | | [optional] +**FaxLines** | [**List<FaxLineResponse>**](FaxLineResponse.md) | | [optional] +**Warnings** | [**WarningResponse**](WarningResponse.md) | | [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/sdks/dotnet/docs/FaxLineRemoveUserRequest.md b/sdks/dotnet/docs/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..fa351fad7 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineRemoveUserRequest.md @@ -0,0 +1,12 @@ +# Dropbox.Sign.Model.FaxLineRemoveUserRequest + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Number** | **string** | The Fax Line number. | +**AccountId** | **string** | Account ID | [optional] +**EmailAddress** | **string** | Email address | [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/sdks/dotnet/docs/FaxLineResponse.md b/sdks/dotnet/docs/FaxLineResponse.md new file mode 100644 index 000000000..2be5447e6 --- /dev/null +++ b/sdks/dotnet/docs/FaxLineResponse.md @@ -0,0 +1,11 @@ +# Dropbox.Sign.Model.FaxLineResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**FaxLine** | [**FaxLineResponse**](FaxLineResponse.md) | | [optional] +**Warnings** | [**WarningResponse**](WarningResponse.md) | | [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/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs new file mode 100644 index 000000000..d5770080f --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs @@ -0,0 +1,1717 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.Net; +using System.Net.Mime; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +namespace Dropbox.Sign.Api +{ + + /// + /// Represents a collection of functions to interact with the API endpoints + /// + public interface IFaxLineApiSync : IApiAccessor + { + #region Synchronous Operations + /// + /// Add Fax Line User + /// + /// + /// Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// FaxLineResponse + FaxLineResponse FaxLineAddUser(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0); + + /// + /// Add Fax Line User + /// + /// + /// Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + ApiResponse FaxLineAddUserWithHttpInfo(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0); + /// + /// Get Available Fax Line Area Codes + /// + /// + /// Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// FaxLineAreaCodeGetResponse + FaxLineAreaCodeGetResponse FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0); + + /// + /// Get Available Fax Line Area Codes + /// + /// + /// Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// ApiResponse of FaxLineAreaCodeGetResponse + ApiResponse FaxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0); + /// + /// Purchase Fax Line + /// + /// + /// Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// FaxLineResponse + FaxLineResponse FaxLineCreate(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0); + + /// + /// Purchase Fax Line + /// + /// + /// Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + ApiResponse FaxLineCreateWithHttpInfo(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0); + /// + /// Delete Fax Line + /// + /// + /// Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// + void FaxLineDelete(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0); + + /// + /// Delete Fax Line + /// + /// + /// Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of Object(void) + ApiResponse FaxLineDeleteWithHttpInfo(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0); + /// + /// Get Fax Line + /// + /// + /// Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// FaxLineResponse + FaxLineResponse FaxLineGet(string number, int operationIndex = 0); + + /// + /// Get Fax Line + /// + /// + /// Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + ApiResponse FaxLineGetWithHttpInfo(string number, int operationIndex = 0); + /// + /// List Fax Lines + /// + /// + /// Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// FaxLineListResponse + FaxLineListResponse FaxLineList(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0); + + /// + /// List Fax Lines + /// + /// + /// Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// ApiResponse of FaxLineListResponse + ApiResponse FaxLineListWithHttpInfo(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0); + /// + /// Remove Fax Line Access + /// + /// + /// Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// FaxLineResponse + FaxLineResponse FaxLineRemoveUser(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0); + + /// + /// Remove Fax Line Access + /// + /// + /// Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + ApiResponse FaxLineRemoveUserWithHttpInfo(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0); + #endregion Synchronous Operations + } + + /// + /// Represents a collection of functions to interact with the API endpoints + /// + public interface IFaxLineApiAsync : IApiAccessor + { + #region Asynchronous Operations + /// + /// Add Fax Line User + /// + /// + /// Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + System.Threading.Tasks.Task FaxLineAddUserAsync(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// Add Fax Line User + /// + /// + /// Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + System.Threading.Tasks.Task> FaxLineAddUserWithHttpInfoAsync(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + /// + /// Get Available Fax Line Area Codes + /// + /// + /// Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineAreaCodeGetResponse + System.Threading.Tasks.Task FaxLineAreaCodeGetAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// Get Available Fax Line Area Codes + /// + /// + /// Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineAreaCodeGetResponse) + System.Threading.Tasks.Task> FaxLineAreaCodeGetWithHttpInfoAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + /// + /// Purchase Fax Line + /// + /// + /// Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + System.Threading.Tasks.Task FaxLineCreateAsync(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// Purchase Fax Line + /// + /// + /// Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + System.Threading.Tasks.Task> FaxLineCreateWithHttpInfoAsync(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + /// + /// Delete Fax Line + /// + /// + /// Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of void + System.Threading.Tasks.Task FaxLineDeleteAsync(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// Delete Fax Line + /// + /// + /// Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse + System.Threading.Tasks.Task> FaxLineDeleteWithHttpInfoAsync(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + /// + /// Get Fax Line + /// + /// + /// Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + System.Threading.Tasks.Task FaxLineGetAsync(string number, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// Get Fax Line + /// + /// + /// Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + System.Threading.Tasks.Task> FaxLineGetWithHttpInfoAsync(string number, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + /// + /// List Fax Lines + /// + /// + /// Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineListResponse + System.Threading.Tasks.Task FaxLineListAsync(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// List Fax Lines + /// + /// + /// Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineListResponse) + System.Threading.Tasks.Task> FaxLineListWithHttpInfoAsync(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + /// + /// Remove Fax Line Access + /// + /// + /// Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + System.Threading.Tasks.Task FaxLineRemoveUserAsync(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + + /// + /// Remove Fax Line Access + /// + /// + /// Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + System.Threading.Tasks.Task> FaxLineRemoveUserWithHttpInfoAsync(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + #endregion Asynchronous Operations + } + + /// + /// Represents a collection of functions to interact with the API endpoints + /// + public interface IFaxLineApi : IFaxLineApiSync, IFaxLineApiAsync + { + + } + + /// + /// Represents a collection of functions to interact with the API endpoints + /// + public partial class FaxLineApi : IFaxLineApi + { + private Dropbox.Sign.Client.ExceptionFactory _exceptionFactory = (name, response) => null; + + /// + /// Initializes a new instance of the class. + /// + /// + public FaxLineApi() : this((string)null) + { + } + + /// + /// Initializes a new instance of the class. + /// + /// + public FaxLineApi(string basePath) + { + this.Configuration = Dropbox.Sign.Client.Configuration.MergeConfigurations( + Dropbox.Sign.Client.GlobalConfiguration.Instance, + new Dropbox.Sign.Client.Configuration { BasePath = basePath } + ); + this.Client = new Dropbox.Sign.Client.ApiClient(this.Configuration.BasePath); + this.AsynchronousClient = new Dropbox.Sign.Client.ApiClient(this.Configuration.BasePath); + this.ExceptionFactory = Dropbox.Sign.Client.Configuration.DefaultExceptionFactory; + } + + /// + /// Initializes a new instance of the class + /// using Configuration object + /// + /// An instance of Configuration + /// + public FaxLineApi(Dropbox.Sign.Client.Configuration configuration) + { + if (configuration == null) throw new ArgumentNullException("configuration"); + + this.Configuration = Dropbox.Sign.Client.Configuration.MergeConfigurations( + Dropbox.Sign.Client.GlobalConfiguration.Instance, + configuration + ); + this.Client = new Dropbox.Sign.Client.ApiClient(this.Configuration.BasePath); + this.AsynchronousClient = new Dropbox.Sign.Client.ApiClient(this.Configuration.BasePath); + ExceptionFactory = Dropbox.Sign.Client.Configuration.DefaultExceptionFactory; + } + + /// + /// Initializes a new instance of the class + /// using a Configuration object and client instance. + /// + /// The client interface for synchronous API access. + /// The client interface for asynchronous API access. + /// The configuration object. + public FaxLineApi(Dropbox.Sign.Client.ISynchronousClient client, Dropbox.Sign.Client.IAsynchronousClient asyncClient, Dropbox.Sign.Client.IReadableConfiguration configuration) + { + if (client == null) throw new ArgumentNullException("client"); + if (asyncClient == null) throw new ArgumentNullException("asyncClient"); + if (configuration == null) throw new ArgumentNullException("configuration"); + + this.Client = client; + this.AsynchronousClient = asyncClient; + this.Configuration = configuration; + this.ExceptionFactory = Dropbox.Sign.Client.Configuration.DefaultExceptionFactory; + } + + /// + /// The client for accessing this underlying API asynchronously. + /// + public Dropbox.Sign.Client.IAsynchronousClient AsynchronousClient { get; set; } + + /// + /// The client for accessing this underlying API synchronously. + /// + public Dropbox.Sign.Client.ISynchronousClient Client { get; set; } + + /// + /// Gets the base path of the API client. + /// + /// The base path + public string GetBasePath() + { + return this.Configuration.BasePath; + } + + /// + /// Gets or sets the configuration object + /// + /// An instance of the Configuration + public Dropbox.Sign.Client.IReadableConfiguration Configuration { get; set; } + + /// + /// Provides a factory method hook for the creation of exceptions. + /// + public Dropbox.Sign.Client.ExceptionFactory ExceptionFactory + { + get + { + if (_exceptionFactory != null && _exceptionFactory.GetInvocationList().Length > 1) + { + throw new InvalidOperationException("Multicast delegate for ExceptionFactory is unsupported."); + } + return _exceptionFactory; + } + set { _exceptionFactory = value; } + } + + /// + /// Add Fax Line User Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// FaxLineResponse + public FaxLineResponse FaxLineAddUser(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineAddUserWithHttpInfo(faxLineAddUserRequest); + return localVarResponse.Data; + } + + /// + /// Add Fax Line User Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpInfo(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0) + { + // verify the required parameter 'faxLineAddUserRequest' is set + if (faxLineAddUserRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineAddUserRequest' when calling FaxLineApi->FaxLineAddUser"); + } + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineAddUserRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineAddUserRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineAddUser"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Post("/fax_line/add_user", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineAddUser", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Add Fax Line User Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + public async System.Threading.Tasks.Task FaxLineAddUserAsync(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineAddUserWithHttpInfoAsync(faxLineAddUserRequest, operationIndex, cancellationToken).ConfigureAwait(false); + return localVarResponse.Data; + } + + /// + /// Add Fax Line User Grants a user access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + public async System.Threading.Tasks.Task> FaxLineAddUserWithHttpInfoAsync(FaxLineAddUserRequest faxLineAddUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + // verify the required parameter 'faxLineAddUserRequest' is set + if (faxLineAddUserRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineAddUserRequest' when calling FaxLineApi->FaxLineAddUser"); + } + + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineAddUserRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineAddUserRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineAddUser"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.PostAsync("/fax_line/add_user", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineAddUser", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Get Available Fax Line Area Codes Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// FaxLineAreaCodeGetResponse + public FaxLineAreaCodeGetResponse FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineAreaCodeGetWithHttpInfo(country, state, province, city); + return localVarResponse.Data; + } + + /// + /// Get Available Fax Line Area Codes Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// ApiResponse of FaxLineAreaCodeGetResponse + public Dropbox.Sign.Client.ApiResponse FaxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0) + { + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + string[] _contentTypes = new string[] { + }; + var localVarContentType = Dropbox.Sign.Client.ClientUtils.SelectHeaderContentType(_contentTypes); + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "country", country)); + if (state != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "state", state)); + } + if (province != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "province", province)); + } + if (city != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "city", city)); + } + localVarRequestOptions.Operation = "FaxLineApi.FaxLineAreaCodeGet"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Get("/fax_line/area_codes", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineAreaCodeGet", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Get Available Fax Line Area Codes Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineAreaCodeGetResponse + public async System.Threading.Tasks.Task FaxLineAreaCodeGetAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineAreaCodeGetWithHttpInfoAsync(country, state, province, city, operationIndex, cancellationToken).ConfigureAwait(false); + return localVarResponse.Data; + } + + /// + /// Get Available Fax Line Area Codes Returns a response with the area codes available for a given state/provice and city. + /// + /// Thrown when fails to make API call + /// Filter area codes by country. + /// Filter area codes by state. (optional) + /// Filter area codes by province. (optional) + /// Filter area codes by city. (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineAreaCodeGetResponse) + public async System.Threading.Tasks.Task> FaxLineAreaCodeGetWithHttpInfoAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + string[] _contentTypes = new string[] { + }; + + var localVarContentType = Dropbox.Sign.Client.ClientUtils.SelectHeaderContentType(_contentTypes); + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "country", country)); + if (state != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "state", state)); + } + if (province != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "province", province)); + } + if (city != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "city", city)); + } + localVarRequestOptions.Operation = "FaxLineApi.FaxLineAreaCodeGet"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.GetAsync("/fax_line/area_codes", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineAreaCodeGet", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Purchase Fax Line Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// FaxLineResponse + public FaxLineResponse FaxLineCreate(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineCreateWithHttpInfo(faxLineCreateRequest); + return localVarResponse.Data; + } + + /// + /// Purchase Fax Line Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + public Dropbox.Sign.Client.ApiResponse FaxLineCreateWithHttpInfo(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0) + { + // verify the required parameter 'faxLineCreateRequest' is set + if (faxLineCreateRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineCreateRequest' when calling FaxLineApi->FaxLineCreate"); + } + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineCreateRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineCreateRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineCreate"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Post("/fax_line/create", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineCreate", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Purchase Fax Line Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + public async System.Threading.Tasks.Task FaxLineCreateAsync(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineCreateWithHttpInfoAsync(faxLineCreateRequest, operationIndex, cancellationToken).ConfigureAwait(false); + return localVarResponse.Data; + } + + /// + /// Purchase Fax Line Purchases a new Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + public async System.Threading.Tasks.Task> FaxLineCreateWithHttpInfoAsync(FaxLineCreateRequest faxLineCreateRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + // verify the required parameter 'faxLineCreateRequest' is set + if (faxLineCreateRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineCreateRequest' when calling FaxLineApi->FaxLineCreate"); + } + + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineCreateRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineCreateRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineCreate"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.PostAsync("/fax_line/create", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineCreate", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Delete Fax Line Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// + public void FaxLineDelete(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0) + { + FaxLineDeleteWithHttpInfo(faxLineDeleteRequest); + } + + /// + /// Delete Fax Line Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of Object(void) + public Dropbox.Sign.Client.ApiResponse FaxLineDeleteWithHttpInfo(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0) + { + // verify the required parameter 'faxLineDeleteRequest' is set + if (faxLineDeleteRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineDeleteRequest' when calling FaxLineApi->FaxLineDelete"); + } + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineDeleteRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineDeleteRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineDelete"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Delete("/fax_line/delete", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineDelete", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Delete Fax Line Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of void + public async System.Threading.Tasks.Task FaxLineDeleteAsync(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + await FaxLineDeleteWithHttpInfoAsync(faxLineDeleteRequest, operationIndex, cancellationToken).ConfigureAwait(false); + } + + /// + /// Delete Fax Line Deletes the specified Fax Line from the subscription. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse + public async System.Threading.Tasks.Task> FaxLineDeleteWithHttpInfoAsync(FaxLineDeleteRequest faxLineDeleteRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + // verify the required parameter 'faxLineDeleteRequest' is set + if (faxLineDeleteRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineDeleteRequest' when calling FaxLineApi->FaxLineDelete"); + } + + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineDeleteRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineDeleteRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineDelete"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.DeleteAsync("/fax_line/delete", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineDelete", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Get Fax Line Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// FaxLineResponse + public FaxLineResponse FaxLineGet(string number, int operationIndex = 0) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineGetWithHttpInfo(number); + return localVarResponse.Data; + } + + /// + /// Get Fax Line Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(string number, int operationIndex = 0) + { + // verify the required parameter 'number' is set + if (number == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'number' when calling FaxLineApi->FaxLineGet"); + } + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + string[] _contentTypes = new string[] { + }; + var localVarContentType = Dropbox.Sign.Client.ClientUtils.SelectHeaderContentType(_contentTypes); + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.PathParameters.Add("number", Dropbox.Sign.Client.ClientUtils.ParameterToString(number)); // path parameter + localVarRequestOptions.Operation = "FaxLineApi.FaxLineGet"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Get("/fax_line/{number}", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineGet", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Get Fax Line Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + public async System.Threading.Tasks.Task FaxLineGetAsync(string number, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineGetWithHttpInfoAsync(number, operationIndex, cancellationToken).ConfigureAwait(false); + return localVarResponse.Data; + } + + /// + /// Get Fax Line Returns the properties and settings of a Fax Line. + /// + /// Thrown when fails to make API call + /// The Fax Line number. + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + public async System.Threading.Tasks.Task> FaxLineGetWithHttpInfoAsync(string number, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + // verify the required parameter 'number' is set + if (number == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'number' when calling FaxLineApi->FaxLineGet"); + } + + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + string[] _contentTypes = new string[] { + }; + + var localVarContentType = Dropbox.Sign.Client.ClientUtils.SelectHeaderContentType(_contentTypes); + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.PathParameters.Add("number", Dropbox.Sign.Client.ClientUtils.ParameterToString(number)); // path parameter + localVarRequestOptions.Operation = "FaxLineApi.FaxLineGet"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.GetAsync("/fax_line/{number}", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineGet", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// List Fax Lines Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// FaxLineListResponse + public FaxLineListResponse FaxLineList(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + return localVarResponse.Data; + } + + /// + /// List Fax Lines Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// ApiResponse of FaxLineListResponse + public Dropbox.Sign.Client.ApiResponse FaxLineListWithHttpInfo(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0) + { + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + string[] _contentTypes = new string[] { + }; + var localVarContentType = Dropbox.Sign.Client.ClientUtils.SelectHeaderContentType(_contentTypes); + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + if (accountId != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "account_id", accountId)); + } + if (page != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "page", page)); + } + if (pageSize != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "page_size", pageSize)); + } + if (showTeamLines != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "show_team_lines", showTeamLines)); + } + localVarRequestOptions.Operation = "FaxLineApi.FaxLineList"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Get("/fax_line/list", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineList", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// List Fax Lines Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineListResponse + public async System.Threading.Tasks.Task FaxLineListAsync(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineListWithHttpInfoAsync(accountId, page, pageSize, showTeamLines, operationIndex, cancellationToken).ConfigureAwait(false); + return localVarResponse.Data; + } + + /// + /// List Fax Lines Returns the properties and settings of multiple Fax Lines. + /// + /// Thrown when fails to make API call + /// Account ID (optional) + /// Page (optional) + /// Page size (optional) + /// Show team lines (optional) + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineListResponse) + public async System.Threading.Tasks.Task> FaxLineListWithHttpInfoAsync(string? accountId = default(string?), int? page = default(int?), int? pageSize = default(int?), bool? showTeamLines = default(bool?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + string[] _contentTypes = new string[] { + }; + + var localVarContentType = Dropbox.Sign.Client.ClientUtils.SelectHeaderContentType(_contentTypes); + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + if (accountId != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "account_id", accountId)); + } + if (page != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "page", page)); + } + if (pageSize != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "page_size", pageSize)); + } + if (showTeamLines != null) + { + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "show_team_lines", showTeamLines)); + } + localVarRequestOptions.Operation = "FaxLineApi.FaxLineList"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.GetAsync("/fax_line/list", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineList", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Remove Fax Line Access Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// FaxLineResponse + public FaxLineResponse FaxLineRemoveUser(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineRemoveUserWithHttpInfo(faxLineRemoveUserRequest); + return localVarResponse.Data; + } + + /// + /// Remove Fax Line Access Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// ApiResponse of FaxLineResponse + public Dropbox.Sign.Client.ApiResponse FaxLineRemoveUserWithHttpInfo(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0) + { + // verify the required parameter 'faxLineRemoveUserRequest' is set + if (faxLineRemoveUserRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineRemoveUserRequest' when calling FaxLineApi->FaxLineRemoveUser"); + } + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineRemoveUserRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineRemoveUserRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineRemoveUser"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = this.Client.Post("/fax_line/remove_user", localVarRequestOptions, this.Configuration); + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineRemoveUser", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + /// + /// Remove Fax Line Access Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of FaxLineResponse + public async System.Threading.Tasks.Task FaxLineRemoveUserAsync(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineRemoveUserWithHttpInfoAsync(faxLineRemoveUserRequest, operationIndex, cancellationToken).ConfigureAwait(false); + return localVarResponse.Data; + } + + /// + /// Remove Fax Line Access Removes a user's access to the specified Fax Line. + /// + /// Thrown when fails to make API call + /// + /// Index associated with the operation. + /// Cancellation Token to cancel the request. + /// Task of ApiResponse (FaxLineResponse) + public async System.Threading.Tasks.Task> FaxLineRemoveUserWithHttpInfoAsync(FaxLineRemoveUserRequest faxLineRemoveUserRequest, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + { + // verify the required parameter 'faxLineRemoveUserRequest' is set + if (faxLineRemoveUserRequest == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'faxLineRemoveUserRequest' when calling FaxLineApi->FaxLineRemoveUser"); + } + + + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); + + var localVarContentType = ""; + var openApiTypes = faxLineRemoveUserRequest.GetOpenApiTypes(); + if (ClientUtils.HasFileType(openApiTypes)) + { + ClientUtils.SetFormData(localVarRequestOptions, openApiTypes); + localVarContentType = "multipart/form-data"; + } + else + { + localVarContentType = "application/json"; + localVarRequestOptions.Data = faxLineRemoveUserRequest; + } + + // to determine the Accept header + string[] _accepts = new string[] { + "application/json" + }; + + if (localVarContentType != null) + { + localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType); + } + + var localVarAccept = Dropbox.Sign.Client.ClientUtils.SelectHeaderAccept(_accepts); + if (localVarAccept != null) + { + localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); + } + + localVarRequestOptions.Operation = "FaxLineApi.FaxLineRemoveUser"; + localVarRequestOptions.OperationIndex = operationIndex; + + // authentication (api_key) required + // http basic authentication required + if (!string.IsNullOrEmpty(this.Configuration.Username) || !string.IsNullOrEmpty(this.Configuration.Password) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization")) + { + localVarRequestOptions.HeaderParameters.Add("Authorization", "Basic " + Dropbox.Sign.Client.ClientUtils.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password)); + } + + // make the HTTP request + var localVarResponse = await this.AsynchronousClient.PostAsync("/fax_line/remove_user", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + + if (this.ExceptionFactory != null) + { + Exception _exception = this.ExceptionFactory("FaxLineRemoveUser", localVarResponse); + if (_exception != null) + { + throw _exception; + } + } + + return localVarResponse; + } + + } +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAddUserRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAddUserRequest.cs new file mode 100644 index 000000000..3db56c254 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAddUserRequest.cs @@ -0,0 +1,221 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineAddUserRequest + /// + [DataContract(Name = "FaxLineAddUserRequest")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineAddUserRequest : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineAddUserRequest() { } + /// + /// Initializes a new instance of the class. + /// + /// The Fax Line number. (required). + /// Account ID. + /// Email address. + public FaxLineAddUserRequest(string number = default(string), string accountId = default(string), string emailAddress = default(string)) + { + + // to ensure "number" is required (not null) + if (number == null) + { + throw new ArgumentNullException("number is a required property for FaxLineAddUserRequest and cannot be null"); + } + this.Number = number; + this.AccountId = accountId; + this.EmailAddress = emailAddress; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineAddUserRequest Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineAddUserRequest"); + } + + return obj; + } + + /// + /// The Fax Line number. + /// + /// The Fax Line number. + [DataMember(Name = "number", IsRequired = true, EmitDefaultValue = true)] + public string Number { get; set; } + + /// + /// Account ID + /// + /// Account ID + [DataMember(Name = "account_id", EmitDefaultValue = true)] + public string AccountId { get; set; } + + /// + /// Email address + /// + /// Email address + [DataMember(Name = "email_address", EmitDefaultValue = true)] + public string EmailAddress { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineAddUserRequest {\n"); + sb.Append(" Number: ").Append(Number).Append("\n"); + sb.Append(" AccountId: ").Append(AccountId).Append("\n"); + sb.Append(" EmailAddress: ").Append(EmailAddress).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineAddUserRequest); + } + + /// + /// Returns true if FaxLineAddUserRequest instances are equal + /// + /// Instance of FaxLineAddUserRequest to be compared + /// Boolean + public bool Equals(FaxLineAddUserRequest input) + { + if (input == null) + { + return false; + } + return + ( + this.Number == input.Number || + (this.Number != null && + this.Number.Equals(input.Number)) + ) && + ( + this.AccountId == input.AccountId || + (this.AccountId != null && + this.AccountId.Equals(input.AccountId)) + ) && + ( + this.EmailAddress == input.EmailAddress || + (this.EmailAddress != null && + this.EmailAddress.Equals(input.EmailAddress)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Number != null) + { + hashCode = (hashCode * 59) + this.Number.GetHashCode(); + } + if (this.AccountId != null) + { + hashCode = (hashCode * 59) + this.AccountId.GetHashCode(); + } + if (this.EmailAddress != null) + { + hashCode = (hashCode * 59) + this.EmailAddress.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "number", + Property = "Number", + Type = "string", + Value = Number, + }); + types.Add(new OpenApiType(){ + Name = "account_id", + Property = "AccountId", + Type = "string", + Value = AccountId, + }); + types.Add(new OpenApiType(){ + Name = "email_address", + Property = "EmailAddress", + Type = "string", + Value = EmailAddress, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetCountryEnum.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetCountryEnum.cs new file mode 100644 index 000000000..efea05942 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetCountryEnum.cs @@ -0,0 +1,55 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// Defines FaxLineAreaCodeGetCountryEnum + /// + [JsonConverter(typeof(StringEnumConverter))] + public enum FaxLineAreaCodeGetCountryEnum + { + /// + /// Enum CA for value: CA + /// + [EnumMember(Value = "CA")] + CA = 1, + + /// + /// Enum US for value: US + /// + [EnumMember(Value = "US")] + US = 2, + + /// + /// Enum UK for value: UK + /// + [EnumMember(Value = "UK")] + UK = 3 + + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetProvinceEnum.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetProvinceEnum.cs new file mode 100644 index 000000000..13c01beb4 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetProvinceEnum.cs @@ -0,0 +1,115 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// Defines FaxLineAreaCodeGetProvinceEnum + /// + [JsonConverter(typeof(StringEnumConverter))] + public enum FaxLineAreaCodeGetProvinceEnum + { + /// + /// Enum AB for value: AB + /// + [EnumMember(Value = "AB")] + AB = 1, + + /// + /// Enum BC for value: BC + /// + [EnumMember(Value = "BC")] + BC = 2, + + /// + /// Enum MB for value: MB + /// + [EnumMember(Value = "MB")] + MB = 3, + + /// + /// Enum NB for value: NB + /// + [EnumMember(Value = "NB")] + NB = 4, + + /// + /// Enum NL for value: NL + /// + [EnumMember(Value = "NL")] + NL = 5, + + /// + /// Enum NT for value: NT + /// + [EnumMember(Value = "NT")] + NT = 6, + + /// + /// Enum NS for value: NS + /// + [EnumMember(Value = "NS")] + NS = 7, + + /// + /// Enum NU for value: NU + /// + [EnumMember(Value = "NU")] + NU = 8, + + /// + /// Enum ON for value: ON + /// + [EnumMember(Value = "ON")] + ON = 9, + + /// + /// Enum PE for value: PE + /// + [EnumMember(Value = "PE")] + PE = 10, + + /// + /// Enum QC for value: QC + /// + [EnumMember(Value = "QC")] + QC = 11, + + /// + /// Enum SK for value: SK + /// + [EnumMember(Value = "SK")] + SK = 12, + + /// + /// Enum YT for value: YT + /// + [EnumMember(Value = "YT")] + YT = 13 + + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs new file mode 100644 index 000000000..55942f18a --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs @@ -0,0 +1,166 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineAreaCodeGetResponse + /// + [DataContract(Name = "FaxLineAreaCodeGetResponse")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineAreaCodeGetResponse : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineAreaCodeGetResponse() { } + /// + /// Initializes a new instance of the class. + /// + /// areaCodes. + public FaxLineAreaCodeGetResponse(List areaCodes = default(List)) + { + + this.AreaCodes = areaCodes; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineAreaCodeGetResponse Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineAreaCodeGetResponse"); + } + + return obj; + } + + /// + /// Gets or Sets AreaCodes + /// + [DataMember(Name = "area_codes", EmitDefaultValue = true)] + public List AreaCodes { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineAreaCodeGetResponse {\n"); + sb.Append(" AreaCodes: ").Append(AreaCodes).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineAreaCodeGetResponse); + } + + /// + /// Returns true if FaxLineAreaCodeGetResponse instances are equal + /// + /// Instance of FaxLineAreaCodeGetResponse to be compared + /// Boolean + public bool Equals(FaxLineAreaCodeGetResponse input) + { + if (input == null) + { + return false; + } + return + ( + this.AreaCodes == input.AreaCodes || + this.AreaCodes != null && + input.AreaCodes != null && + this.AreaCodes.SequenceEqual(input.AreaCodes) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.AreaCodes != null) + { + hashCode = (hashCode * 59) + this.AreaCodes.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "area_codes", + Property = "AreaCodes", + Type = "List", + Value = AreaCodes, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetStateEnum.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetStateEnum.cs new file mode 100644 index 000000000..b42d0e327 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetStateEnum.cs @@ -0,0 +1,343 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// Defines FaxLineAreaCodeGetStateEnum + /// + [JsonConverter(typeof(StringEnumConverter))] + public enum FaxLineAreaCodeGetStateEnum + { + /// + /// Enum AK for value: AK + /// + [EnumMember(Value = "AK")] + AK = 1, + + /// + /// Enum AL for value: AL + /// + [EnumMember(Value = "AL")] + AL = 2, + + /// + /// Enum AR for value: AR + /// + [EnumMember(Value = "AR")] + AR = 3, + + /// + /// Enum AZ for value: AZ + /// + [EnumMember(Value = "AZ")] + AZ = 4, + + /// + /// Enum CA for value: CA + /// + [EnumMember(Value = "CA")] + CA = 5, + + /// + /// Enum CO for value: CO + /// + [EnumMember(Value = "CO")] + CO = 6, + + /// + /// Enum CT for value: CT + /// + [EnumMember(Value = "CT")] + CT = 7, + + /// + /// Enum DC for value: DC + /// + [EnumMember(Value = "DC")] + DC = 8, + + /// + /// Enum DE for value: DE + /// + [EnumMember(Value = "DE")] + DE = 9, + + /// + /// Enum FL for value: FL + /// + [EnumMember(Value = "FL")] + FL = 10, + + /// + /// Enum GA for value: GA + /// + [EnumMember(Value = "GA")] + GA = 11, + + /// + /// Enum HI for value: HI + /// + [EnumMember(Value = "HI")] + HI = 12, + + /// + /// Enum IA for value: IA + /// + [EnumMember(Value = "IA")] + IA = 13, + + /// + /// Enum ID for value: ID + /// + [EnumMember(Value = "ID")] + ID = 14, + + /// + /// Enum IL for value: IL + /// + [EnumMember(Value = "IL")] + IL = 15, + + /// + /// Enum IN for value: IN + /// + [EnumMember(Value = "IN")] + IN = 16, + + /// + /// Enum KS for value: KS + /// + [EnumMember(Value = "KS")] + KS = 17, + + /// + /// Enum KY for value: KY + /// + [EnumMember(Value = "KY")] + KY = 18, + + /// + /// Enum LA for value: LA + /// + [EnumMember(Value = "LA")] + LA = 19, + + /// + /// Enum MA for value: MA + /// + [EnumMember(Value = "MA")] + MA = 20, + + /// + /// Enum MD for value: MD + /// + [EnumMember(Value = "MD")] + MD = 21, + + /// + /// Enum ME for value: ME + /// + [EnumMember(Value = "ME")] + ME = 22, + + /// + /// Enum MI for value: MI + /// + [EnumMember(Value = "MI")] + MI = 23, + + /// + /// Enum MN for value: MN + /// + [EnumMember(Value = "MN")] + MN = 24, + + /// + /// Enum MO for value: MO + /// + [EnumMember(Value = "MO")] + MO = 25, + + /// + /// Enum MS for value: MS + /// + [EnumMember(Value = "MS")] + MS = 26, + + /// + /// Enum MT for value: MT + /// + [EnumMember(Value = "MT")] + MT = 27, + + /// + /// Enum NC for value: NC + /// + [EnumMember(Value = "NC")] + NC = 28, + + /// + /// Enum ND for value: ND + /// + [EnumMember(Value = "ND")] + ND = 29, + + /// + /// Enum NE for value: NE + /// + [EnumMember(Value = "NE")] + NE = 30, + + /// + /// Enum NH for value: NH + /// + [EnumMember(Value = "NH")] + NH = 31, + + /// + /// Enum NJ for value: NJ + /// + [EnumMember(Value = "NJ")] + NJ = 32, + + /// + /// Enum NM for value: NM + /// + [EnumMember(Value = "NM")] + NM = 33, + + /// + /// Enum NV for value: NV + /// + [EnumMember(Value = "NV")] + NV = 34, + + /// + /// Enum NY for value: NY + /// + [EnumMember(Value = "NY")] + NY = 35, + + /// + /// Enum OH for value: OH + /// + [EnumMember(Value = "OH")] + OH = 36, + + /// + /// Enum OK for value: OK + /// + [EnumMember(Value = "OK")] + OK = 37, + + /// + /// Enum OR for value: OR + /// + [EnumMember(Value = "OR")] + OR = 38, + + /// + /// Enum PA for value: PA + /// + [EnumMember(Value = "PA")] + PA = 39, + + /// + /// Enum RI for value: RI + /// + [EnumMember(Value = "RI")] + RI = 40, + + /// + /// Enum SC for value: SC + /// + [EnumMember(Value = "SC")] + SC = 41, + + /// + /// Enum SD for value: SD + /// + [EnumMember(Value = "SD")] + SD = 42, + + /// + /// Enum TN for value: TN + /// + [EnumMember(Value = "TN")] + TN = 43, + + /// + /// Enum TX for value: TX + /// + [EnumMember(Value = "TX")] + TX = 44, + + /// + /// Enum UT for value: UT + /// + [EnumMember(Value = "UT")] + UT = 45, + + /// + /// Enum VA for value: VA + /// + [EnumMember(Value = "VA")] + VA = 46, + + /// + /// Enum VT for value: VT + /// + [EnumMember(Value = "VT")] + VT = 47, + + /// + /// Enum WA for value: WA + /// + [EnumMember(Value = "WA")] + WA = 48, + + /// + /// Enum WI for value: WI + /// + [EnumMember(Value = "WI")] + WI = 49, + + /// + /// Enum WV for value: WV + /// + [EnumMember(Value = "WV")] + WV = 50, + + /// + /// Enum WY for value: WY + /// + [EnumMember(Value = "WY")] + WY = 51 + + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs new file mode 100644 index 000000000..ae20ad586 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs @@ -0,0 +1,246 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineCreateRequest + /// + [DataContract(Name = "FaxLineCreateRequest")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineCreateRequest : IOpenApiTyped, IEquatable, IValidatableObject + { + + /// + /// Gets or Sets Country + /// + [DataMember(Name = "country", IsRequired = true, EmitDefaultValue = true)] + public FaxLineAreaCodeGetCountryEnum Country { get; set; } + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineCreateRequest() { } + /// + /// Initializes a new instance of the class. + /// + /// Area code (required). + /// country (required). + /// City (required). + /// Account ID. + public FaxLineCreateRequest(string areaCode = default(string), FaxLineAreaCodeGetCountryEnum country = default(FaxLineAreaCodeGetCountryEnum), string city = default(string), string accountId = default(string)) + { + + // to ensure "areaCode" is required (not null) + if (areaCode == null) + { + throw new ArgumentNullException("areaCode is a required property for FaxLineCreateRequest and cannot be null"); + } + this.AreaCode = areaCode; + this.Country = country; + // to ensure "city" is required (not null) + if (city == null) + { + throw new ArgumentNullException("city is a required property for FaxLineCreateRequest and cannot be null"); + } + this.City = city; + this.AccountId = accountId; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineCreateRequest Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineCreateRequest"); + } + + return obj; + } + + /// + /// Area code + /// + /// Area code + [DataMember(Name = "area_code", IsRequired = true, EmitDefaultValue = true)] + public string AreaCode { get; set; } + + /// + /// City + /// + /// City + [DataMember(Name = "city", IsRequired = true, EmitDefaultValue = true)] + public string City { get; set; } + + /// + /// Account ID + /// + /// Account ID + [DataMember(Name = "account_id", EmitDefaultValue = true)] + public string AccountId { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineCreateRequest {\n"); + sb.Append(" AreaCode: ").Append(AreaCode).Append("\n"); + sb.Append(" Country: ").Append(Country).Append("\n"); + sb.Append(" City: ").Append(City).Append("\n"); + sb.Append(" AccountId: ").Append(AccountId).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineCreateRequest); + } + + /// + /// Returns true if FaxLineCreateRequest instances are equal + /// + /// Instance of FaxLineCreateRequest to be compared + /// Boolean + public bool Equals(FaxLineCreateRequest input) + { + if (input == null) + { + return false; + } + return + ( + this.AreaCode == input.AreaCode || + (this.AreaCode != null && + this.AreaCode.Equals(input.AreaCode)) + ) && + ( + this.Country == input.Country || + this.Country.Equals(input.Country) + ) && + ( + this.City == input.City || + (this.City != null && + this.City.Equals(input.City)) + ) && + ( + this.AccountId == input.AccountId || + (this.AccountId != null && + this.AccountId.Equals(input.AccountId)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.AreaCode != null) + { + hashCode = (hashCode * 59) + this.AreaCode.GetHashCode(); + } + hashCode = (hashCode * 59) + this.Country.GetHashCode(); + if (this.City != null) + { + hashCode = (hashCode * 59) + this.City.GetHashCode(); + } + if (this.AccountId != null) + { + hashCode = (hashCode * 59) + this.AccountId.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "area_code", + Property = "AreaCode", + Type = "string", + Value = AreaCode, + }); + types.Add(new OpenApiType(){ + Name = "country", + Property = "Country", + Type = "FaxLineAreaCodeGetCountryEnum", + Value = Country, + }); + types.Add(new OpenApiType(){ + Name = "city", + Property = "City", + Type = "string", + Value = City, + }); + types.Add(new OpenApiType(){ + Name = "account_id", + Property = "AccountId", + Type = "string", + Value = AccountId, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineDeleteRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineDeleteRequest.cs new file mode 100644 index 000000000..6c3daabad --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineDeleteRequest.cs @@ -0,0 +1,171 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineDeleteRequest + /// + [DataContract(Name = "FaxLineDeleteRequest")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineDeleteRequest : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineDeleteRequest() { } + /// + /// Initializes a new instance of the class. + /// + /// The Fax Line number. (required). + public FaxLineDeleteRequest(string number = default(string)) + { + + // to ensure "number" is required (not null) + if (number == null) + { + throw new ArgumentNullException("number is a required property for FaxLineDeleteRequest and cannot be null"); + } + this.Number = number; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineDeleteRequest Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineDeleteRequest"); + } + + return obj; + } + + /// + /// The Fax Line number. + /// + /// The Fax Line number. + [DataMember(Name = "number", IsRequired = true, EmitDefaultValue = true)] + public string Number { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineDeleteRequest {\n"); + sb.Append(" Number: ").Append(Number).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineDeleteRequest); + } + + /// + /// Returns true if FaxLineDeleteRequest instances are equal + /// + /// Instance of FaxLineDeleteRequest to be compared + /// Boolean + public bool Equals(FaxLineDeleteRequest input) + { + if (input == null) + { + return false; + } + return + ( + this.Number == input.Number || + (this.Number != null && + this.Number.Equals(input.Number)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Number != null) + { + hashCode = (hashCode * 59) + this.Number.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "number", + Property = "Number", + Type = "string", + Value = Number, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs new file mode 100644 index 000000000..19367d5d1 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs @@ -0,0 +1,214 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineListResponse + /// + [DataContract(Name = "FaxLineListResponse")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineListResponse : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineListResponse() { } + /// + /// Initializes a new instance of the class. + /// + /// listInfo. + /// faxLines. + /// warnings. + public FaxLineListResponse(ListInfoResponse listInfo = default(ListInfoResponse), List faxLines = default(List), WarningResponse warnings = default(WarningResponse)) + { + + this.ListInfo = listInfo; + this.FaxLines = faxLines; + this.Warnings = warnings; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineListResponse Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineListResponse"); + } + + return obj; + } + + /// + /// Gets or Sets ListInfo + /// + [DataMember(Name = "list_info", EmitDefaultValue = true)] + public ListInfoResponse ListInfo { get; set; } + + /// + /// Gets or Sets FaxLines + /// + [DataMember(Name = "fax_lines", EmitDefaultValue = true)] + public List FaxLines { get; set; } + + /// + /// Gets or Sets Warnings + /// + [DataMember(Name = "warnings", EmitDefaultValue = true)] + public WarningResponse Warnings { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineListResponse {\n"); + sb.Append(" ListInfo: ").Append(ListInfo).Append("\n"); + sb.Append(" FaxLines: ").Append(FaxLines).Append("\n"); + sb.Append(" Warnings: ").Append(Warnings).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineListResponse); + } + + /// + /// Returns true if FaxLineListResponse instances are equal + /// + /// Instance of FaxLineListResponse to be compared + /// Boolean + public bool Equals(FaxLineListResponse input) + { + if (input == null) + { + return false; + } + return + ( + this.ListInfo == input.ListInfo || + (this.ListInfo != null && + this.ListInfo.Equals(input.ListInfo)) + ) && + ( + this.FaxLines == input.FaxLines || + this.FaxLines != null && + input.FaxLines != null && + this.FaxLines.SequenceEqual(input.FaxLines) + ) && + ( + this.Warnings == input.Warnings || + (this.Warnings != null && + this.Warnings.Equals(input.Warnings)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.ListInfo != null) + { + hashCode = (hashCode * 59) + this.ListInfo.GetHashCode(); + } + if (this.FaxLines != null) + { + hashCode = (hashCode * 59) + this.FaxLines.GetHashCode(); + } + if (this.Warnings != null) + { + hashCode = (hashCode * 59) + this.Warnings.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "list_info", + Property = "ListInfo", + Type = "ListInfoResponse", + Value = ListInfo, + }); + types.Add(new OpenApiType(){ + Name = "fax_lines", + Property = "FaxLines", + Type = "List", + Value = FaxLines, + }); + types.Add(new OpenApiType(){ + Name = "warnings", + Property = "Warnings", + Type = "WarningResponse", + Value = Warnings, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineRemoveUserRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineRemoveUserRequest.cs new file mode 100644 index 000000000..ddac6924d --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineRemoveUserRequest.cs @@ -0,0 +1,221 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineRemoveUserRequest + /// + [DataContract(Name = "FaxLineRemoveUserRequest")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineRemoveUserRequest : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineRemoveUserRequest() { } + /// + /// Initializes a new instance of the class. + /// + /// The Fax Line number. (required). + /// Account ID. + /// Email address. + public FaxLineRemoveUserRequest(string number = default(string), string accountId = default(string), string emailAddress = default(string)) + { + + // to ensure "number" is required (not null) + if (number == null) + { + throw new ArgumentNullException("number is a required property for FaxLineRemoveUserRequest and cannot be null"); + } + this.Number = number; + this.AccountId = accountId; + this.EmailAddress = emailAddress; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineRemoveUserRequest Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineRemoveUserRequest"); + } + + return obj; + } + + /// + /// The Fax Line number. + /// + /// The Fax Line number. + [DataMember(Name = "number", IsRequired = true, EmitDefaultValue = true)] + public string Number { get; set; } + + /// + /// Account ID + /// + /// Account ID + [DataMember(Name = "account_id", EmitDefaultValue = true)] + public string AccountId { get; set; } + + /// + /// Email address + /// + /// Email address + [DataMember(Name = "email_address", EmitDefaultValue = true)] + public string EmailAddress { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineRemoveUserRequest {\n"); + sb.Append(" Number: ").Append(Number).Append("\n"); + sb.Append(" AccountId: ").Append(AccountId).Append("\n"); + sb.Append(" EmailAddress: ").Append(EmailAddress).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineRemoveUserRequest); + } + + /// + /// Returns true if FaxLineRemoveUserRequest instances are equal + /// + /// Instance of FaxLineRemoveUserRequest to be compared + /// Boolean + public bool Equals(FaxLineRemoveUserRequest input) + { + if (input == null) + { + return false; + } + return + ( + this.Number == input.Number || + (this.Number != null && + this.Number.Equals(input.Number)) + ) && + ( + this.AccountId == input.AccountId || + (this.AccountId != null && + this.AccountId.Equals(input.AccountId)) + ) && + ( + this.EmailAddress == input.EmailAddress || + (this.EmailAddress != null && + this.EmailAddress.Equals(input.EmailAddress)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Number != null) + { + hashCode = (hashCode * 59) + this.Number.GetHashCode(); + } + if (this.AccountId != null) + { + hashCode = (hashCode * 59) + this.AccountId.GetHashCode(); + } + if (this.EmailAddress != null) + { + hashCode = (hashCode * 59) + this.EmailAddress.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "number", + Property = "Number", + Type = "string", + Value = Number, + }); + types.Add(new OpenApiType(){ + Name = "account_id", + Property = "AccountId", + Type = "string", + Value = AccountId, + }); + types.Add(new OpenApiType(){ + Name = "email_address", + Property = "EmailAddress", + Type = "string", + Value = EmailAddress, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs new file mode 100644 index 000000000..d74b37b78 --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs @@ -0,0 +1,189 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineResponse + /// + [DataContract(Name = "FaxLineResponse")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineResponse : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineResponse() { } + /// + /// Initializes a new instance of the class. + /// + /// faxLine. + /// warnings. + public FaxLineResponse(FaxLineResponse faxLine = default(FaxLineResponse), WarningResponse warnings = default(WarningResponse)) + { + + this.FaxLine = faxLine; + this.Warnings = warnings; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineResponse Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineResponse"); + } + + return obj; + } + + /// + /// Gets or Sets FaxLine + /// + [DataMember(Name = "fax_line", EmitDefaultValue = true)] + public FaxLineResponse FaxLine { get; set; } + + /// + /// Gets or Sets Warnings + /// + [DataMember(Name = "warnings", EmitDefaultValue = true)] + public WarningResponse Warnings { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineResponse {\n"); + sb.Append(" FaxLine: ").Append(FaxLine).Append("\n"); + sb.Append(" Warnings: ").Append(Warnings).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineResponse); + } + + /// + /// Returns true if FaxLineResponse instances are equal + /// + /// Instance of FaxLineResponse to be compared + /// Boolean + public bool Equals(FaxLineResponse input) + { + if (input == null) + { + return false; + } + return + ( + this.FaxLine == input.FaxLine || + (this.FaxLine != null && + this.FaxLine.Equals(input.FaxLine)) + ) && + ( + this.Warnings == input.Warnings || + (this.Warnings != null && + this.Warnings.Equals(input.Warnings)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.FaxLine != null) + { + hashCode = (hashCode * 59) + this.FaxLine.GetHashCode(); + } + if (this.Warnings != null) + { + hashCode = (hashCode * 59) + this.Warnings.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "fax_line", + Property = "FaxLine", + Type = "FaxLineResponse", + Value = FaxLine, + }); + types.Add(new OpenApiType(){ + Name = "warnings", + Property = "Warnings", + Type = "WarningResponse", + Value = Warnings, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/java-v1/README.md b/sdks/java-v1/README.md index 228374aac..023657591 100644 --- a/sdks/java-v1/README.md +++ b/sdks/java-v1/README.md @@ -178,6 +178,13 @@ Class | Method | HTTP request | Description *BulkSendJobApi* | [**bulkSendJobList**](docs/BulkSendJobApi.md#bulkSendJobList) | **GET** /bulk_send_job/list | List Bulk Send Jobs *EmbeddedApi* | [**embeddedEditUrl**](docs/EmbeddedApi.md#embeddedEditUrl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL *EmbeddedApi* | [**embeddedSignUrl**](docs/EmbeddedApi.md#embeddedSignUrl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL +*FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +*FaxLineApi* | [**faxLineAreaCodeGet**](docs/FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes +*FaxLineApi* | [**faxLineCreate**](docs/FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line +*FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line +*FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +*FaxLineApi* | [**faxLineList**](docs/FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines +*FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**oauthTokenGenerate**](docs/OAuthApi.md#oauthTokenGenerate) | **POST** /oauth/token | OAuth Token Generate *OAuthApi* | [**oauthTokenRefresh**](docs/OAuthApi.md#oauthTokenRefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh *ReportApi* | [**reportCreate**](docs/ReportApi.md#reportCreate) | **POST** /report/create | Create Report @@ -260,6 +267,16 @@ Class | Method | HTTP request | Description - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) + - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) + - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) + - [FaxLineAreaCodeGetResponse](docs/FaxLineAreaCodeGetResponse.md) + - [FaxLineAreaCodeGetStateEnum](docs/FaxLineAreaCodeGetStateEnum.md) + - [FaxLineCreateRequest](docs/FaxLineCreateRequest.md) + - [FaxLineDeleteRequest](docs/FaxLineDeleteRequest.md) + - [FaxLineListResponse](docs/FaxLineListResponse.md) + - [FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) + - [FaxLineResponse](docs/FaxLineResponse.md) - [FileResponse](docs/FileResponse.md) - [FileResponseDataUri](docs/FileResponseDataUri.md) - [ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/java-v1/docs/FaxLineAddUserRequest.md b/sdks/java-v1/docs/FaxLineAddUserRequest.md new file mode 100644 index 000000000..011d4d047 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineAddUserRequest.md @@ -0,0 +1,16 @@ + + +# FaxLineAddUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```String``` | The Fax Line number. | | +| `accountId` | ```String``` | Account ID | | +| `emailAddress` | ```String``` | Email address | | + + + diff --git a/sdks/java-v1/docs/FaxLineApi.md b/sdks/java-v1/docs/FaxLineApi.md new file mode 100644 index 000000000..3ab18f277 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineApi.md @@ -0,0 +1,308 @@ +# FaxLineApi + +All URIs are relative to *https://api.hellosign.com/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +[**faxLineAreaCodeGet**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes +[**faxLineCreate**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line +[**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line +[**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +[**faxLineList**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines +[**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access + + + +## faxLineAddUser + +> FaxLineResponse faxLineAddUser(faxLineAddUserRequest) + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineAddUserRequest** | [**FaxLineAddUserRequest**](FaxLineAddUserRequest.md)| | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineAreaCodeGet + +> FaxLineAreaCodeGetResponse faxLineAreaCodeGet(country, state, province, city) + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **country** | **FaxLineAreaCodeGetCountryEnum**| Filter area codes by country. | [enum: CA, US, UK] + **state** | **FaxLineAreaCodeGetStateEnum**| Filter area codes by state. | [optional] [enum: AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY] + **province** | **FaxLineAreaCodeGetProvinceEnum**| Filter area codes by province. | [optional] [enum: AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT] + **city** | **String**| Filter area codes by city. | [optional] + +### Return type + +[**FaxLineAreaCodeGetResponse**](FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineCreate + +> FaxLineResponse faxLineCreate(faxLineCreateRequest) + +Purchase Fax Line + +Purchases a new Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineCreateRequest** | [**FaxLineCreateRequest**](FaxLineCreateRequest.md)| | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineDelete + +> faxLineDelete(faxLineDeleteRequest) + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineDeleteRequest** | [**FaxLineDeleteRequest**](FaxLineDeleteRequest.md)| | + +### Return type + +null (empty response body) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineGet + +> FaxLineResponse faxLineGet(number) + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **number** | **String**| The Fax Line number. | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineList + +> FaxLineListResponse faxLineList(accountId, page, pageSize, showTeamLines) + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **accountId** | **String**| Account ID | [optional] + **page** | **Integer**| Page | [optional] + **pageSize** | **Integer**| Page size | [optional] + **showTeamLines** | **Boolean**| Show team lines | [optional] + +### Return type + +[**FaxLineListResponse**](FaxLineListResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineRemoveUser + +> FaxLineResponse faxLineRemoveUser(faxLineRemoveUserRequest) + +Remove Fax Line Access + +Removes a user's access to the specified Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineRemoveUserRequest** | [**FaxLineRemoveUserRequest**](FaxLineRemoveUserRequest.md)| | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + diff --git a/sdks/java-v1/docs/FaxLineAreaCodeGetCountryEnum.md b/sdks/java-v1/docs/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..10275bc6c --- /dev/null +++ b/sdks/java-v1/docs/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,15 @@ + + +# FaxLineAreaCodeGetCountryEnum + +## Enum + + +* `CA` (value: `"CA"`) + +* `US` (value: `"US"`) + +* `UK` (value: `"UK"`) + + + diff --git a/sdks/java-v1/docs/FaxLineAreaCodeGetProvinceEnum.md b/sdks/java-v1/docs/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..13cf50078 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,35 @@ + + +# FaxLineAreaCodeGetProvinceEnum + +## Enum + + +* `AB` (value: `"AB"`) + +* `BC` (value: `"BC"`) + +* `MB` (value: `"MB"`) + +* `NB` (value: `"NB"`) + +* `NL` (value: `"NL"`) + +* `NT` (value: `"NT"`) + +* `NS` (value: `"NS"`) + +* `NU` (value: `"NU"`) + +* `ON` (value: `"ON"`) + +* `PE` (value: `"PE"`) + +* `QC` (value: `"QC"`) + +* `SK` (value: `"SK"`) + +* `YT` (value: `"YT"`) + + + diff --git a/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md b/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..0b231dcf9 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,14 @@ + + +# FaxLineAreaCodeGetResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `areaCodes` | ```List``` | | | + + + diff --git a/sdks/java-v1/docs/FaxLineAreaCodeGetStateEnum.md b/sdks/java-v1/docs/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..577a48c63 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,111 @@ + + +# FaxLineAreaCodeGetStateEnum + +## Enum + + +* `AK` (value: `"AK"`) + +* `AL` (value: `"AL"`) + +* `AR` (value: `"AR"`) + +* `AZ` (value: `"AZ"`) + +* `CA` (value: `"CA"`) + +* `CO` (value: `"CO"`) + +* `CT` (value: `"CT"`) + +* `DC` (value: `"DC"`) + +* `DE` (value: `"DE"`) + +* `FL` (value: `"FL"`) + +* `GA` (value: `"GA"`) + +* `HI` (value: `"HI"`) + +* `IA` (value: `"IA"`) + +* `ID` (value: `"ID"`) + +* `IL` (value: `"IL"`) + +* `IN` (value: `"IN"`) + +* `KS` (value: `"KS"`) + +* `KY` (value: `"KY"`) + +* `LA` (value: `"LA"`) + +* `MA` (value: `"MA"`) + +* `MD` (value: `"MD"`) + +* `ME` (value: `"ME"`) + +* `MI` (value: `"MI"`) + +* `MN` (value: `"MN"`) + +* `MO` (value: `"MO"`) + +* `MS` (value: `"MS"`) + +* `MT` (value: `"MT"`) + +* `NC` (value: `"NC"`) + +* `ND` (value: `"ND"`) + +* `NE` (value: `"NE"`) + +* `NH` (value: `"NH"`) + +* `NJ` (value: `"NJ"`) + +* `NM` (value: `"NM"`) + +* `NV` (value: `"NV"`) + +* `NY` (value: `"NY"`) + +* `OH` (value: `"OH"`) + +* `OK` (value: `"OK"`) + +* `OR` (value: `"OR"`) + +* `PA` (value: `"PA"`) + +* `RI` (value: `"RI"`) + +* `SC` (value: `"SC"`) + +* `SD` (value: `"SD"`) + +* `TN` (value: `"TN"`) + +* `TX` (value: `"TX"`) + +* `UT` (value: `"UT"`) + +* `VA` (value: `"VA"`) + +* `VT` (value: `"VT"`) + +* `WA` (value: `"WA"`) + +* `WI` (value: `"WI"`) + +* `WV` (value: `"WV"`) + +* `WY` (value: `"WY"`) + + + diff --git a/sdks/java-v1/docs/FaxLineCreateRequest.md b/sdks/java-v1/docs/FaxLineCreateRequest.md new file mode 100644 index 000000000..6c4bf7d18 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineCreateRequest.md @@ -0,0 +1,17 @@ + + +# FaxLineCreateRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `areaCode`*_required_ | ```String``` | Area code | | +| `country`*_required_ | ```FaxLineAreaCodeGetCountryEnum``` | | | +| `city`*_required_ | ```String``` | City | | +| `accountId` | ```String``` | Account ID | | + + + diff --git a/sdks/java-v1/docs/FaxLineDeleteRequest.md b/sdks/java-v1/docs/FaxLineDeleteRequest.md new file mode 100644 index 000000000..d00dac614 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineDeleteRequest.md @@ -0,0 +1,14 @@ + + +# FaxLineDeleteRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```String``` | The Fax Line number. | | + + + diff --git a/sdks/java-v1/docs/FaxLineListResponse.md b/sdks/java-v1/docs/FaxLineListResponse.md new file mode 100644 index 000000000..f4724aaae --- /dev/null +++ b/sdks/java-v1/docs/FaxLineListResponse.md @@ -0,0 +1,16 @@ + + +# FaxLineListResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | +| `faxLines` | [```List```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + + + diff --git a/sdks/java-v1/docs/FaxLineRemoveUserRequest.md b/sdks/java-v1/docs/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..f353fdee6 --- /dev/null +++ b/sdks/java-v1/docs/FaxLineRemoveUserRequest.md @@ -0,0 +1,16 @@ + + +# FaxLineRemoveUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```String``` | The Fax Line number. | | +| `accountId` | ```String``` | Account ID | | +| `emailAddress` | ```String``` | Email address | | + + + diff --git a/sdks/java-v1/docs/FaxLineResponse.md b/sdks/java-v1/docs/FaxLineResponse.md new file mode 100644 index 000000000..4e373231e --- /dev/null +++ b/sdks/java-v1/docs/FaxLineResponse.md @@ -0,0 +1,15 @@ + + +# FaxLineResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `faxLine` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + + + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java new file mode 100644 index 000000000..eb9dd8dc3 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -0,0 +1,742 @@ +package com.dropbox.sign.api; + +import com.dropbox.sign.ApiException; +import com.dropbox.sign.ApiClient; +import com.dropbox.sign.ApiResponse; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.Pair; + +import javax.ws.rs.core.GenericType; + +import com.dropbox.sign.model.ErrorResponse; +import com.dropbox.sign.model.FaxLineAddUserRequest; +import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; +import com.dropbox.sign.model.FaxLineAreaCodeGetProvinceEnum; +import com.dropbox.sign.model.FaxLineAreaCodeGetResponse; +import com.dropbox.sign.model.FaxLineAreaCodeGetStateEnum; +import com.dropbox.sign.model.FaxLineCreateRequest; +import com.dropbox.sign.model.FaxLineDeleteRequest; +import com.dropbox.sign.model.FaxLineListResponse; +import com.dropbox.sign.model.FaxLineRemoveUserRequest; +import com.dropbox.sign.model.FaxLineResponse; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineApi { + private ApiClient apiClient; + + public FaxLineApi() { + this(Configuration.getDefaultApiClient()); + } + + public FaxLineApi(ApiClient apiClient) { + this.apiClient = apiClient; + } + + /** + * Get the API client + * + * @return API client + */ + public ApiClient getApiClient() { + return apiClient; + } + + /** + * Set the API client + * + * @param apiClient an instance of API client + */ + public void setApiClient(ApiClient apiClient) { + this.apiClient = apiClient; + } + + /** + * Add Fax Line User + * Grants a user access to the specified Fax Line. + * @param faxLineAddUserRequest (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineAddUser(FaxLineAddUserRequest faxLineAddUserRequest) throws ApiException { + return faxLineAddUserWithHttpInfo(faxLineAddUserRequest).getData(); + } + + + /** + * Add Fax Line User + * Grants a user access to the specified Fax Line. + * @param faxLineAddUserRequest (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineAddUserWithHttpInfo(FaxLineAddUserRequest faxLineAddUserRequest) throws ApiException { + + Object localVarPostBody = faxLineAddUserRequest; + + // verify the required parameter 'faxLineAddUserRequest' is set + if (faxLineAddUserRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineAddUserRequest' when calling faxLineAddUser"); + } + + // create path and map variables + String localVarPath = "/fax_line/add_user"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineAddUserRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineAddUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Get Available Fax Line Area Codes + * Returns a response with the area codes available for a given state/provice and city. + * @param country Filter area codes by country. (required) + * @param state Filter area codes by state. (optional) + * @param province Filter area codes by province. (optional) + * @param city Filter area codes by city. (optional) + * @return FaxLineAreaCodeGetResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + + /** + * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country) throws ApiException { + FaxLineAreaCodeGetStateEnum state = null; + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country) throws ApiException { + FaxLineAreaCodeGetStateEnum state = null; + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); + } + + + /** + * Get Available Fax Line Area Codes + * Returns a response with the area codes available for a given state/provice and city. + * @param country Filter area codes by country. (required) + * @param state Filter area codes by state. (optional) + * @param province Filter area codes by province. (optional) + * @param city Filter area codes by city. (optional) + * @return ApiResponse<FaxLineAreaCodeGetResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + + Object localVarPostBody = null; + + // verify the required parameter 'country' is set + if (country == null) { + throw new ApiException(400, "Missing the required parameter 'country' when calling faxLineAreaCodeGet"); + } + + // create path and map variables + String localVarPath = "/fax_line/area_codes"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + localVarQueryParams.addAll(apiClient.parameterToPairs("", "country", country)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "state", state)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "province", province)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "city", city)); + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + + }; + + localVarFormParams = new HashMap(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineAreaCodeGet", localVarPath, "GET", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Purchase Fax Line + * Purchases a new Fax Line. + * @param faxLineCreateRequest (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineCreate(FaxLineCreateRequest faxLineCreateRequest) throws ApiException { + return faxLineCreateWithHttpInfo(faxLineCreateRequest).getData(); + } + + + /** + * Purchase Fax Line + * Purchases a new Fax Line. + * @param faxLineCreateRequest (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineCreateWithHttpInfo(FaxLineCreateRequest faxLineCreateRequest) throws ApiException { + + Object localVarPostBody = faxLineCreateRequest; + + // verify the required parameter 'faxLineCreateRequest' is set + if (faxLineCreateRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineCreateRequest' when calling faxLineCreate"); + } + + // create path and map variables + String localVarPath = "/fax_line/create"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineCreateRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineCreate", localVarPath, "POST", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Delete Fax Line + * Deletes the specified Fax Line from the subscription. + * @param faxLineDeleteRequest (required) + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public void faxLineDelete(FaxLineDeleteRequest faxLineDeleteRequest) throws ApiException { + faxLineDeleteWithHttpInfo(faxLineDeleteRequest); + } + + + /** + * Delete Fax Line + * Deletes the specified Fax Line from the subscription. + * @param faxLineDeleteRequest (required) + * @return ApiResponse<Void> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineDeleteWithHttpInfo(FaxLineDeleteRequest faxLineDeleteRequest) throws ApiException { + + Object localVarPostBody = faxLineDeleteRequest; + + // verify the required parameter 'faxLineDeleteRequest' is set + if (faxLineDeleteRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineDeleteRequest' when calling faxLineDelete"); + } + + // create path and map variables + String localVarPath = "/fax_line/delete"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineDeleteRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + return apiClient.invokeAPI("FaxLineApi.faxLineDelete", localVarPath, "DELETE", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, null, false); + } + /** + * Get Fax Line + * Returns the properties and settings of a Fax Line. + * @param number The Fax Line number. (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineGet(String number) throws ApiException { + return faxLineGetWithHttpInfo(number).getData(); + } + + + /** + * Get Fax Line + * Returns the properties and settings of a Fax Line. + * @param number The Fax Line number. (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineGetWithHttpInfo(String number) throws ApiException { + + Object localVarPostBody = null; + + // verify the required parameter 'number' is set + if (number == null) { + throw new ApiException(400, "Missing the required parameter 'number' when calling faxLineGet"); + } + + // create path and map variables + String localVarPath = "/fax_line/{number}" + .replaceAll("\\{" + "number" + "\\}", apiClient.escapeString(number.toString())); + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + + }; + + localVarFormParams = new HashMap(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineGet", localVarPath, "GET", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * List Fax Lines + * Returns the properties and settings of multiple Fax Lines. + * @param accountId Account ID (optional) + * @param page Page (optional) + * @param pageSize Page size (optional) + * @param showTeamLines Show team lines (optional) + * @return FaxLineListResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineListResponse faxLineList(String accountId, Integer page, Integer pageSize, Boolean showTeamLines) throws ApiException { + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList() throws ApiException { + String accountId = null; + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo() throws ApiException { + String accountId = null; + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList(String accountId) throws ApiException { + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo(String accountId) throws ApiException { + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList(String accountId, Integer page) throws ApiException { + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page) throws ApiException { + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList(String accountId, Integer page, Integer pageSize) throws ApiException { + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page, Integer pageSize) throws ApiException { + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + + /** + * List Fax Lines + * Returns the properties and settings of multiple Fax Lines. + * @param accountId Account ID (optional) + * @param page Page (optional) + * @param pageSize Page size (optional) + * @param showTeamLines Show team lines (optional) + * @return ApiResponse<FaxLineListResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page, Integer pageSize, Boolean showTeamLines) throws ApiException { + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/fax_line/list"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + localVarQueryParams.addAll(apiClient.parameterToPairs("", "account_id", accountId)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "page", page)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "page_size", pageSize)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "show_team_lines", showTeamLines)); + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + + }; + + localVarFormParams = new HashMap(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineList", localVarPath, "GET", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Remove Fax Line Access + * Removes a user's access to the specified Fax Line. + * @param faxLineRemoveUserRequest (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineRemoveUser(FaxLineRemoveUserRequest faxLineRemoveUserRequest) throws ApiException { + return faxLineRemoveUserWithHttpInfo(faxLineRemoveUserRequest).getData(); + } + + + /** + * Remove Fax Line Access + * Removes a user's access to the specified Fax Line. + * @param faxLineRemoveUserRequest (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineRemoveUserWithHttpInfo(FaxLineRemoveUserRequest faxLineRemoveUserRequest) throws ApiException { + + Object localVarPostBody = faxLineRemoveUserRequest; + + // verify the required parameter 'faxLineRemoveUserRequest' is set + if (faxLineRemoveUserRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineRemoveUserRequest' when calling faxLineRemoveUser"); + } + + // create path and map variables + String localVarPath = "/fax_line/remove_user"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineRemoveUserRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineRemoveUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } +} \ No newline at end of file diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java new file mode 100644 index 000000000..d4d812fc3 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java @@ -0,0 +1,283 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineAddUserRequest + */ +@JsonPropertyOrder({ + FaxLineAddUserRequest.JSON_PROPERTY_NUMBER, + FaxLineAddUserRequest.JSON_PROPERTY_ACCOUNT_ID, + FaxLineAddUserRequest.JSON_PROPERTY_EMAIL_ADDRESS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineAddUserRequest { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public static final String JSON_PROPERTY_ACCOUNT_ID = "account_id"; + private String accountId; + + public static final String JSON_PROPERTY_EMAIL_ADDRESS = "email_address"; + private String emailAddress; + + public FaxLineAddUserRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineAddUserRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineAddUserRequest.class); + } + + static public FaxLineAddUserRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineAddUserRequest.class + ); + } + + public FaxLineAddUserRequest number(String number) { + this.number = number; + return this; + } + + /** + * The Fax Line number. + * @return number + **/ + @javax.annotation.Nonnull + @ApiModelProperty(required = true, value = "The Fax Line number.") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setNumber(String number) { + this.number = number; + } + + + public FaxLineAddUserRequest accountId(String accountId) { + this.accountId = accountId; + return this; + } + + /** + * Account ID + * @return accountId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97", value = "Account ID") + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getAccountId() { + return accountId; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccountId(String accountId) { + this.accountId = accountId; + } + + + public FaxLineAddUserRequest emailAddress(String emailAddress) { + this.emailAddress = emailAddress; + return this; + } + + /** + * Email address + * @return emailAddress + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Email address") + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getEmailAddress() { + return emailAddress; + } + + + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setEmailAddress(String emailAddress) { + this.emailAddress = emailAddress; + } + + + /** + * Return true if this FaxLineAddUserRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineAddUserRequest faxLineAddUserRequest = (FaxLineAddUserRequest) o; + return Objects.equals(this.number, faxLineAddUserRequest.number) && + Objects.equals(this.accountId, faxLineAddUserRequest.accountId) && + Objects.equals(this.emailAddress, faxLineAddUserRequest.emailAddress); + } + + @Override + public int hashCode() { + return Objects.hash(number, accountId, emailAddress); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineAddUserRequest {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append(" emailAddress: ").append(toIndentedString(emailAddress)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + if (accountId != null) { + if (isFileTypeOrListOfFiles(accountId)) { + fileTypeFound = true; + } + + if (accountId.getClass().equals(java.io.File.class) || + accountId.getClass().equals(Integer.class) || + accountId.getClass().equals(String.class) || + accountId.getClass().isEnum()) { + map.put("account_id", accountId); + } else if (isListOfFile(accountId)) { + for(int i = 0; i< getListSize(accountId); i++) { + map.put("account_id[" + i + "]", getFromList(accountId, i)); + } + } + else { + map.put("account_id", JSON.getDefault().getMapper().writeValueAsString(accountId)); + } + } + if (emailAddress != null) { + if (isFileTypeOrListOfFiles(emailAddress)) { + fileTypeFound = true; + } + + if (emailAddress.getClass().equals(java.io.File.class) || + emailAddress.getClass().equals(Integer.class) || + emailAddress.getClass().equals(String.class) || + emailAddress.getClass().isEnum()) { + map.put("email_address", emailAddress); + } else if (isListOfFile(emailAddress)) { + for(int i = 0; i< getListSize(emailAddress); i++) { + map.put("email_address[" + i + "]", getFromList(emailAddress, i)); + } + } + else { + map.put("email_address", JSON.getDefault().getMapper().writeValueAsString(emailAddress)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java new file mode 100644 index 000000000..fbc25957c --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java @@ -0,0 +1,66 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Gets or Sets FaxLineAreaCodeGetCountryEnum + */ +public enum FaxLineAreaCodeGetCountryEnum { + + CA("CA"), + + US("US"), + + UK("UK"); + + private String value; + + FaxLineAreaCodeGetCountryEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static FaxLineAreaCodeGetCountryEnum fromValue(String value) { + for (FaxLineAreaCodeGetCountryEnum b : FaxLineAreaCodeGetCountryEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java new file mode 100644 index 000000000..f9d4d3d41 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java @@ -0,0 +1,86 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Gets or Sets FaxLineAreaCodeGetProvinceEnum + */ +public enum FaxLineAreaCodeGetProvinceEnum { + + AB("AB"), + + BC("BC"), + + MB("MB"), + + NB("NB"), + + NL("NL"), + + NT("NT"), + + NS("NS"), + + NU("NU"), + + ON("ON"), + + PE("PE"), + + QC("QC"), + + SK("SK"), + + YT("YT"); + + private String value; + + FaxLineAreaCodeGetProvinceEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static FaxLineAreaCodeGetProvinceEnum fromValue(String value) { + for (FaxLineAreaCodeGetProvinceEnum b : FaxLineAreaCodeGetProvinceEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java new file mode 100644 index 000000000..b218d8f4e --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java @@ -0,0 +1,191 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.util.ArrayList; +import java.util.List; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineAreaCodeGetResponse + */ +@JsonPropertyOrder({ + FaxLineAreaCodeGetResponse.JSON_PROPERTY_AREA_CODES +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineAreaCodeGetResponse { + public static final String JSON_PROPERTY_AREA_CODES = "area_codes"; + private List areaCodes = null; + + public FaxLineAreaCodeGetResponse() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineAreaCodeGetResponse init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineAreaCodeGetResponse.class); + } + + static public FaxLineAreaCodeGetResponse init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineAreaCodeGetResponse.class + ); + } + + public FaxLineAreaCodeGetResponse areaCodes(List areaCodes) { + this.areaCodes = areaCodes; + return this; + } + + public FaxLineAreaCodeGetResponse addAreaCodesItem(String areaCodesItem) { + if (this.areaCodes == null) { + this.areaCodes = new ArrayList<>(); + } + this.areaCodes.add(areaCodesItem); + return this; + } + + /** + * Get areaCodes + * @return areaCodes + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_AREA_CODES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public List getAreaCodes() { + return areaCodes; + } + + + @JsonProperty(JSON_PROPERTY_AREA_CODES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAreaCodes(List areaCodes) { + this.areaCodes = areaCodes; + } + + + /** + * Return true if this FaxLineAreaCodeGetResponse object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineAreaCodeGetResponse faxLineAreaCodeGetResponse = (FaxLineAreaCodeGetResponse) o; + return Objects.equals(this.areaCodes, faxLineAreaCodeGetResponse.areaCodes); + } + + @Override + public int hashCode() { + return Objects.hash(areaCodes); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineAreaCodeGetResponse {\n"); + sb.append(" areaCodes: ").append(toIndentedString(areaCodes)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (areaCodes != null) { + if (isFileTypeOrListOfFiles(areaCodes)) { + fileTypeFound = true; + } + + if (areaCodes.getClass().equals(java.io.File.class) || + areaCodes.getClass().equals(Integer.class) || + areaCodes.getClass().equals(String.class) || + areaCodes.getClass().isEnum()) { + map.put("area_codes", areaCodes); + } else if (isListOfFile(areaCodes)) { + for(int i = 0; i< getListSize(areaCodes); i++) { + map.put("area_codes[" + i + "]", getFromList(areaCodes, i)); + } + } + else { + map.put("area_codes", JSON.getDefault().getMapper().writeValueAsString(areaCodes)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java new file mode 100644 index 000000000..dadc588f7 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java @@ -0,0 +1,162 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Gets or Sets FaxLineAreaCodeGetStateEnum + */ +public enum FaxLineAreaCodeGetStateEnum { + + AK("AK"), + + AL("AL"), + + AR("AR"), + + AZ("AZ"), + + CA("CA"), + + CO("CO"), + + CT("CT"), + + DC("DC"), + + DE("DE"), + + FL("FL"), + + GA("GA"), + + HI("HI"), + + IA("IA"), + + ID("ID"), + + IL("IL"), + + IN("IN"), + + KS("KS"), + + KY("KY"), + + LA("LA"), + + MA("MA"), + + MD("MD"), + + ME("ME"), + + MI("MI"), + + MN("MN"), + + MO("MO"), + + MS("MS"), + + MT("MT"), + + NC("NC"), + + ND("ND"), + + NE("NE"), + + NH("NH"), + + NJ("NJ"), + + NM("NM"), + + NV("NV"), + + NY("NY"), + + OH("OH"), + + OK("OK"), + + OR("OR"), + + PA("PA"), + + RI("RI"), + + SC("SC"), + + SD("SD"), + + TN("TN"), + + TX("TX"), + + UT("UT"), + + VA("VA"), + + VT("VT"), + + WA("WA"), + + WI("WI"), + + WV("WV"), + + WY("WY"); + + private String value; + + FaxLineAreaCodeGetStateEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static FaxLineAreaCodeGetStateEnum fromValue(String value) { + for (FaxLineAreaCodeGetStateEnum b : FaxLineAreaCodeGetStateEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java new file mode 100644 index 000000000..65460137d --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -0,0 +1,335 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineCreateRequest + */ +@JsonPropertyOrder({ + FaxLineCreateRequest.JSON_PROPERTY_AREA_CODE, + FaxLineCreateRequest.JSON_PROPERTY_COUNTRY, + FaxLineCreateRequest.JSON_PROPERTY_CITY, + FaxLineCreateRequest.JSON_PROPERTY_ACCOUNT_ID +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineCreateRequest { + public static final String JSON_PROPERTY_AREA_CODE = "area_code"; + private String areaCode; + + public static final String JSON_PROPERTY_COUNTRY = "country"; + private FaxLineAreaCodeGetCountryEnum country; + + public static final String JSON_PROPERTY_CITY = "city"; + private String city; + + public static final String JSON_PROPERTY_ACCOUNT_ID = "account_id"; + private String accountId; + + public FaxLineCreateRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineCreateRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineCreateRequest.class); + } + + static public FaxLineCreateRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineCreateRequest.class + ); + } + + public FaxLineCreateRequest areaCode(String areaCode) { + this.areaCode = areaCode; + return this; + } + + /** + * Area code + * @return areaCode + **/ + @javax.annotation.Nonnull + @ApiModelProperty(required = true, value = "Area code") + @JsonProperty(JSON_PROPERTY_AREA_CODE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getAreaCode() { + return areaCode; + } + + + @JsonProperty(JSON_PROPERTY_AREA_CODE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setAreaCode(String areaCode) { + this.areaCode = areaCode; + } + + + public FaxLineCreateRequest country(FaxLineAreaCodeGetCountryEnum country) { + this.country = country; + return this; + } + + /** + * Get country + * @return country + **/ + @javax.annotation.Nonnull + @ApiModelProperty(required = true, value = "") + @JsonProperty(JSON_PROPERTY_COUNTRY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public FaxLineAreaCodeGetCountryEnum getCountry() { + return country; + } + + + @JsonProperty(JSON_PROPERTY_COUNTRY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setCountry(FaxLineAreaCodeGetCountryEnum country) { + this.country = country; + } + + + public FaxLineCreateRequest city(String city) { + this.city = city; + return this; + } + + /** + * City + * @return city + **/ + @javax.annotation.Nonnull + @ApiModelProperty(required = true, value = "City") + @JsonProperty(JSON_PROPERTY_CITY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getCity() { + return city; + } + + + @JsonProperty(JSON_PROPERTY_CITY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setCity(String city) { + this.city = city; + } + + + public FaxLineCreateRequest accountId(String accountId) { + this.accountId = accountId; + return this; + } + + /** + * Account ID + * @return accountId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97", value = "Account ID") + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getAccountId() { + return accountId; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccountId(String accountId) { + this.accountId = accountId; + } + + + /** + * Return true if this FaxLineCreateRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineCreateRequest faxLineCreateRequest = (FaxLineCreateRequest) o; + return Objects.equals(this.areaCode, faxLineCreateRequest.areaCode) && + Objects.equals(this.country, faxLineCreateRequest.country) && + Objects.equals(this.city, faxLineCreateRequest.city) && + Objects.equals(this.accountId, faxLineCreateRequest.accountId); + } + + @Override + public int hashCode() { + return Objects.hash(areaCode, country, city, accountId); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineCreateRequest {\n"); + sb.append(" areaCode: ").append(toIndentedString(areaCode)).append("\n"); + sb.append(" country: ").append(toIndentedString(country)).append("\n"); + sb.append(" city: ").append(toIndentedString(city)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (areaCode != null) { + if (isFileTypeOrListOfFiles(areaCode)) { + fileTypeFound = true; + } + + if (areaCode.getClass().equals(java.io.File.class) || + areaCode.getClass().equals(Integer.class) || + areaCode.getClass().equals(String.class) || + areaCode.getClass().isEnum()) { + map.put("area_code", areaCode); + } else if (isListOfFile(areaCode)) { + for(int i = 0; i< getListSize(areaCode); i++) { + map.put("area_code[" + i + "]", getFromList(areaCode, i)); + } + } + else { + map.put("area_code", JSON.getDefault().getMapper().writeValueAsString(areaCode)); + } + } + if (country != null) { + if (isFileTypeOrListOfFiles(country)) { + fileTypeFound = true; + } + + if (country.getClass().equals(java.io.File.class) || + country.getClass().equals(Integer.class) || + country.getClass().equals(String.class) || + country.getClass().isEnum()) { + map.put("country", country); + } else if (isListOfFile(country)) { + for(int i = 0; i< getListSize(country); i++) { + map.put("country[" + i + "]", getFromList(country, i)); + } + } + else { + map.put("country", JSON.getDefault().getMapper().writeValueAsString(country)); + } + } + if (city != null) { + if (isFileTypeOrListOfFiles(city)) { + fileTypeFound = true; + } + + if (city.getClass().equals(java.io.File.class) || + city.getClass().equals(Integer.class) || + city.getClass().equals(String.class) || + city.getClass().isEnum()) { + map.put("city", city); + } else if (isListOfFile(city)) { + for(int i = 0; i< getListSize(city); i++) { + map.put("city[" + i + "]", getFromList(city, i)); + } + } + else { + map.put("city", JSON.getDefault().getMapper().writeValueAsString(city)); + } + } + if (accountId != null) { + if (isFileTypeOrListOfFiles(accountId)) { + fileTypeFound = true; + } + + if (accountId.getClass().equals(java.io.File.class) || + accountId.getClass().equals(Integer.class) || + accountId.getClass().equals(String.class) || + accountId.getClass().isEnum()) { + map.put("account_id", accountId); + } else if (isListOfFile(accountId)) { + for(int i = 0; i< getListSize(accountId); i++) { + map.put("account_id[" + i + "]", getFromList(accountId, i)); + } + } + else { + map.put("account_id", JSON.getDefault().getMapper().writeValueAsString(accountId)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java new file mode 100644 index 000000000..8979d782b --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java @@ -0,0 +1,181 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineDeleteRequest + */ +@JsonPropertyOrder({ + FaxLineDeleteRequest.JSON_PROPERTY_NUMBER +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineDeleteRequest { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public FaxLineDeleteRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineDeleteRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineDeleteRequest.class); + } + + static public FaxLineDeleteRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineDeleteRequest.class + ); + } + + public FaxLineDeleteRequest number(String number) { + this.number = number; + return this; + } + + /** + * The Fax Line number. + * @return number + **/ + @javax.annotation.Nonnull + @ApiModelProperty(required = true, value = "The Fax Line number.") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setNumber(String number) { + this.number = number; + } + + + /** + * Return true if this FaxLineDeleteRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineDeleteRequest faxLineDeleteRequest = (FaxLineDeleteRequest) o; + return Objects.equals(this.number, faxLineDeleteRequest.number); + } + + @Override + public int hashCode() { + return Objects.hash(number); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineDeleteRequest {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java new file mode 100644 index 000000000..b744c0bde --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java @@ -0,0 +1,296 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.FaxLineResponse; +import com.dropbox.sign.model.ListInfoResponse; +import com.dropbox.sign.model.WarningResponse; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.util.ArrayList; +import java.util.List; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineListResponse + */ +@JsonPropertyOrder({ + FaxLineListResponse.JSON_PROPERTY_LIST_INFO, + FaxLineListResponse.JSON_PROPERTY_FAX_LINES, + FaxLineListResponse.JSON_PROPERTY_WARNINGS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineListResponse { + public static final String JSON_PROPERTY_LIST_INFO = "list_info"; + private ListInfoResponse listInfo; + + public static final String JSON_PROPERTY_FAX_LINES = "fax_lines"; + private List faxLines = null; + + public static final String JSON_PROPERTY_WARNINGS = "warnings"; + private WarningResponse warnings; + + public FaxLineListResponse() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineListResponse init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineListResponse.class); + } + + static public FaxLineListResponse init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineListResponse.class + ); + } + + public FaxLineListResponse listInfo(ListInfoResponse listInfo) { + this.listInfo = listInfo; + return this; + } + + /** + * Get listInfo + * @return listInfo + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_LIST_INFO) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public ListInfoResponse getListInfo() { + return listInfo; + } + + + @JsonProperty(JSON_PROPERTY_LIST_INFO) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setListInfo(ListInfoResponse listInfo) { + this.listInfo = listInfo; + } + + + public FaxLineListResponse faxLines(List faxLines) { + this.faxLines = faxLines; + return this; + } + + public FaxLineListResponse addFaxLinesItem(FaxLineResponse faxLinesItem) { + if (this.faxLines == null) { + this.faxLines = new ArrayList<>(); + } + this.faxLines.add(faxLinesItem); + return this; + } + + /** + * Get faxLines + * @return faxLines + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_FAX_LINES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public List getFaxLines() { + return faxLines; + } + + + @JsonProperty(JSON_PROPERTY_FAX_LINES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setFaxLines(List faxLines) { + this.faxLines = faxLines; + } + + + public FaxLineListResponse warnings(WarningResponse warnings) { + this.warnings = warnings; + return this; + } + + /** + * Get warnings + * @return warnings + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public WarningResponse getWarnings() { + return warnings; + } + + + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setWarnings(WarningResponse warnings) { + this.warnings = warnings; + } + + + /** + * Return true if this FaxLineListResponse object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineListResponse faxLineListResponse = (FaxLineListResponse) o; + return Objects.equals(this.listInfo, faxLineListResponse.listInfo) && + Objects.equals(this.faxLines, faxLineListResponse.faxLines) && + Objects.equals(this.warnings, faxLineListResponse.warnings); + } + + @Override + public int hashCode() { + return Objects.hash(listInfo, faxLines, warnings); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineListResponse {\n"); + sb.append(" listInfo: ").append(toIndentedString(listInfo)).append("\n"); + sb.append(" faxLines: ").append(toIndentedString(faxLines)).append("\n"); + sb.append(" warnings: ").append(toIndentedString(warnings)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (listInfo != null) { + if (isFileTypeOrListOfFiles(listInfo)) { + fileTypeFound = true; + } + + if (listInfo.getClass().equals(java.io.File.class) || + listInfo.getClass().equals(Integer.class) || + listInfo.getClass().equals(String.class) || + listInfo.getClass().isEnum()) { + map.put("list_info", listInfo); + } else if (isListOfFile(listInfo)) { + for(int i = 0; i< getListSize(listInfo); i++) { + map.put("list_info[" + i + "]", getFromList(listInfo, i)); + } + } + else { + map.put("list_info", JSON.getDefault().getMapper().writeValueAsString(listInfo)); + } + } + if (faxLines != null) { + if (isFileTypeOrListOfFiles(faxLines)) { + fileTypeFound = true; + } + + if (faxLines.getClass().equals(java.io.File.class) || + faxLines.getClass().equals(Integer.class) || + faxLines.getClass().equals(String.class) || + faxLines.getClass().isEnum()) { + map.put("fax_lines", faxLines); + } else if (isListOfFile(faxLines)) { + for(int i = 0; i< getListSize(faxLines); i++) { + map.put("fax_lines[" + i + "]", getFromList(faxLines, i)); + } + } + else { + map.put("fax_lines", JSON.getDefault().getMapper().writeValueAsString(faxLines)); + } + } + if (warnings != null) { + if (isFileTypeOrListOfFiles(warnings)) { + fileTypeFound = true; + } + + if (warnings.getClass().equals(java.io.File.class) || + warnings.getClass().equals(Integer.class) || + warnings.getClass().equals(String.class) || + warnings.getClass().isEnum()) { + map.put("warnings", warnings); + } else if (isListOfFile(warnings)) { + for(int i = 0; i< getListSize(warnings); i++) { + map.put("warnings[" + i + "]", getFromList(warnings, i)); + } + } + else { + map.put("warnings", JSON.getDefault().getMapper().writeValueAsString(warnings)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java new file mode 100644 index 000000000..6711ad3a8 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java @@ -0,0 +1,283 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineRemoveUserRequest + */ +@JsonPropertyOrder({ + FaxLineRemoveUserRequest.JSON_PROPERTY_NUMBER, + FaxLineRemoveUserRequest.JSON_PROPERTY_ACCOUNT_ID, + FaxLineRemoveUserRequest.JSON_PROPERTY_EMAIL_ADDRESS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineRemoveUserRequest { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public static final String JSON_PROPERTY_ACCOUNT_ID = "account_id"; + private String accountId; + + public static final String JSON_PROPERTY_EMAIL_ADDRESS = "email_address"; + private String emailAddress; + + public FaxLineRemoveUserRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineRemoveUserRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineRemoveUserRequest.class); + } + + static public FaxLineRemoveUserRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineRemoveUserRequest.class + ); + } + + public FaxLineRemoveUserRequest number(String number) { + this.number = number; + return this; + } + + /** + * The Fax Line number. + * @return number + **/ + @javax.annotation.Nonnull + @ApiModelProperty(required = true, value = "The Fax Line number.") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setNumber(String number) { + this.number = number; + } + + + public FaxLineRemoveUserRequest accountId(String accountId) { + this.accountId = accountId; + return this; + } + + /** + * Account ID + * @return accountId + **/ + @javax.annotation.Nullable + @ApiModelProperty(example = "ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97", value = "Account ID") + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getAccountId() { + return accountId; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccountId(String accountId) { + this.accountId = accountId; + } + + + public FaxLineRemoveUserRequest emailAddress(String emailAddress) { + this.emailAddress = emailAddress; + return this; + } + + /** + * Email address + * @return emailAddress + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Email address") + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getEmailAddress() { + return emailAddress; + } + + + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setEmailAddress(String emailAddress) { + this.emailAddress = emailAddress; + } + + + /** + * Return true if this FaxLineRemoveUserRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineRemoveUserRequest faxLineRemoveUserRequest = (FaxLineRemoveUserRequest) o; + return Objects.equals(this.number, faxLineRemoveUserRequest.number) && + Objects.equals(this.accountId, faxLineRemoveUserRequest.accountId) && + Objects.equals(this.emailAddress, faxLineRemoveUserRequest.emailAddress); + } + + @Override + public int hashCode() { + return Objects.hash(number, accountId, emailAddress); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineRemoveUserRequest {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append(" emailAddress: ").append(toIndentedString(emailAddress)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + if (accountId != null) { + if (isFileTypeOrListOfFiles(accountId)) { + fileTypeFound = true; + } + + if (accountId.getClass().equals(java.io.File.class) || + accountId.getClass().equals(Integer.class) || + accountId.getClass().equals(String.class) || + accountId.getClass().isEnum()) { + map.put("account_id", accountId); + } else if (isListOfFile(accountId)) { + for(int i = 0; i< getListSize(accountId); i++) { + map.put("account_id[" + i + "]", getFromList(accountId, i)); + } + } + else { + map.put("account_id", JSON.getDefault().getMapper().writeValueAsString(accountId)); + } + } + if (emailAddress != null) { + if (isFileTypeOrListOfFiles(emailAddress)) { + fileTypeFound = true; + } + + if (emailAddress.getClass().equals(java.io.File.class) || + emailAddress.getClass().equals(Integer.class) || + emailAddress.getClass().equals(String.class) || + emailAddress.getClass().isEnum()) { + map.put("email_address", emailAddress); + } else if (isListOfFile(emailAddress)) { + for(int i = 0; i< getListSize(emailAddress); i++) { + map.put("email_address[" + i + "]", getFromList(emailAddress, i)); + } + } + else { + map.put("email_address", JSON.getDefault().getMapper().writeValueAsString(emailAddress)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java new file mode 100644 index 000000000..62e1b7c64 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java @@ -0,0 +1,233 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.WarningResponse; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineResponse + */ +@JsonPropertyOrder({ + FaxLineResponse.JSON_PROPERTY_FAX_LINE, + FaxLineResponse.JSON_PROPERTY_WARNINGS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineResponse { + public static final String JSON_PROPERTY_FAX_LINE = "fax_line"; + private FaxLineResponse faxLine; + + public static final String JSON_PROPERTY_WARNINGS = "warnings"; + private WarningResponse warnings; + + public FaxLineResponse() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineResponse init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineResponse.class); + } + + static public FaxLineResponse init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineResponse.class + ); + } + + public FaxLineResponse faxLine(FaxLineResponse faxLine) { + this.faxLine = faxLine; + return this; + } + + /** + * Get faxLine + * @return faxLine + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_FAX_LINE) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public FaxLineResponse getFaxLine() { + return faxLine; + } + + + @JsonProperty(JSON_PROPERTY_FAX_LINE) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setFaxLine(FaxLineResponse faxLine) { + this.faxLine = faxLine; + } + + + public FaxLineResponse warnings(WarningResponse warnings) { + this.warnings = warnings; + return this; + } + + /** + * Get warnings + * @return warnings + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public WarningResponse getWarnings() { + return warnings; + } + + + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setWarnings(WarningResponse warnings) { + this.warnings = warnings; + } + + + /** + * Return true if this FaxLineResponse object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineResponse faxLineResponse = (FaxLineResponse) o; + return Objects.equals(this.faxLine, faxLineResponse.faxLine) && + Objects.equals(this.warnings, faxLineResponse.warnings); + } + + @Override + public int hashCode() { + return Objects.hash(faxLine, warnings); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineResponse {\n"); + sb.append(" faxLine: ").append(toIndentedString(faxLine)).append("\n"); + sb.append(" warnings: ").append(toIndentedString(warnings)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (faxLine != null) { + if (isFileTypeOrListOfFiles(faxLine)) { + fileTypeFound = true; + } + + if (faxLine.getClass().equals(java.io.File.class) || + faxLine.getClass().equals(Integer.class) || + faxLine.getClass().equals(String.class) || + faxLine.getClass().isEnum()) { + map.put("fax_line", faxLine); + } else if (isListOfFile(faxLine)) { + for(int i = 0; i< getListSize(faxLine); i++) { + map.put("fax_line[" + i + "]", getFromList(faxLine, i)); + } + } + else { + map.put("fax_line", JSON.getDefault().getMapper().writeValueAsString(faxLine)); + } + } + if (warnings != null) { + if (isFileTypeOrListOfFiles(warnings)) { + fileTypeFound = true; + } + + if (warnings.getClass().equals(java.io.File.class) || + warnings.getClass().equals(Integer.class) || + warnings.getClass().equals(String.class) || + warnings.getClass().isEnum()) { + map.put("warnings", warnings); + } else if (isListOfFile(warnings)) { + for(int i = 0; i< getListSize(warnings); i++) { + map.put("warnings[" + i + "]", getFromList(warnings, i)); + } + } + else { + map.put("warnings", JSON.getDefault().getMapper().writeValueAsString(warnings)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/README.md b/sdks/java-v2/README.md index 2453f49d3..ad91ca574 100644 --- a/sdks/java-v2/README.md +++ b/sdks/java-v2/README.md @@ -179,6 +179,13 @@ Class | Method | HTTP request | Description *BulkSendJobApi* | [**bulkSendJobList**](docs/BulkSendJobApi.md#bulkSendJobList) | **GET** /bulk_send_job/list | List Bulk Send Jobs *EmbeddedApi* | [**embeddedEditUrl**](docs/EmbeddedApi.md#embeddedEditUrl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL *EmbeddedApi* | [**embeddedSignUrl**](docs/EmbeddedApi.md#embeddedSignUrl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL +*FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +*FaxLineApi* | [**faxLineAreaCodeGet**](docs/FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes +*FaxLineApi* | [**faxLineCreate**](docs/FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line +*FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line +*FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +*FaxLineApi* | [**faxLineList**](docs/FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines +*FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**oauthTokenGenerate**](docs/OAuthApi.md#oauthTokenGenerate) | **POST** /oauth/token | OAuth Token Generate *OAuthApi* | [**oauthTokenRefresh**](docs/OAuthApi.md#oauthTokenRefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh *ReportApi* | [**reportCreate**](docs/ReportApi.md#reportCreate) | **POST** /report/create | Create Report @@ -261,6 +268,16 @@ Class | Method | HTTP request | Description - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) + - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) + - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) + - [FaxLineAreaCodeGetResponse](docs/FaxLineAreaCodeGetResponse.md) + - [FaxLineAreaCodeGetStateEnum](docs/FaxLineAreaCodeGetStateEnum.md) + - [FaxLineCreateRequest](docs/FaxLineCreateRequest.md) + - [FaxLineDeleteRequest](docs/FaxLineDeleteRequest.md) + - [FaxLineListResponse](docs/FaxLineListResponse.md) + - [FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) + - [FaxLineResponse](docs/FaxLineResponse.md) - [FileResponse](docs/FileResponse.md) - [FileResponseDataUri](docs/FileResponseDataUri.md) - [ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/java-v2/docs/FaxLineAddUserRequest.md b/sdks/java-v2/docs/FaxLineAddUserRequest.md new file mode 100644 index 000000000..011d4d047 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineAddUserRequest.md @@ -0,0 +1,16 @@ + + +# FaxLineAddUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```String``` | The Fax Line number. | | +| `accountId` | ```String``` | Account ID | | +| `emailAddress` | ```String``` | Email address | | + + + diff --git a/sdks/java-v2/docs/FaxLineApi.md b/sdks/java-v2/docs/FaxLineApi.md new file mode 100644 index 000000000..3ab18f277 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineApi.md @@ -0,0 +1,308 @@ +# FaxLineApi + +All URIs are relative to *https://api.hellosign.com/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +[**faxLineAreaCodeGet**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes +[**faxLineCreate**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line +[**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line +[**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +[**faxLineList**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines +[**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access + + + +## faxLineAddUser + +> FaxLineResponse faxLineAddUser(faxLineAddUserRequest) + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineAddUserRequest** | [**FaxLineAddUserRequest**](FaxLineAddUserRequest.md)| | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineAreaCodeGet + +> FaxLineAreaCodeGetResponse faxLineAreaCodeGet(country, state, province, city) + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **country** | **FaxLineAreaCodeGetCountryEnum**| Filter area codes by country. | [enum: CA, US, UK] + **state** | **FaxLineAreaCodeGetStateEnum**| Filter area codes by state. | [optional] [enum: AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY] + **province** | **FaxLineAreaCodeGetProvinceEnum**| Filter area codes by province. | [optional] [enum: AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT] + **city** | **String**| Filter area codes by city. | [optional] + +### Return type + +[**FaxLineAreaCodeGetResponse**](FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineCreate + +> FaxLineResponse faxLineCreate(faxLineCreateRequest) + +Purchase Fax Line + +Purchases a new Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineCreateRequest** | [**FaxLineCreateRequest**](FaxLineCreateRequest.md)| | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineDelete + +> faxLineDelete(faxLineDeleteRequest) + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineDeleteRequest** | [**FaxLineDeleteRequest**](FaxLineDeleteRequest.md)| | + +### Return type + +null (empty response body) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineGet + +> FaxLineResponse faxLineGet(number) + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **number** | **String**| The Fax Line number. | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineList + +> FaxLineListResponse faxLineList(accountId, page, pageSize, showTeamLines) + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **accountId** | **String**| Account ID | [optional] + **page** | **Integer**| Page | [optional] + **pageSize** | **Integer**| Page size | [optional] + **showTeamLines** | **Boolean**| Show team lines | [optional] + +### Return type + +[**FaxLineListResponse**](FaxLineListResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + + +## faxLineRemoveUser + +> FaxLineResponse faxLineRemoveUser(faxLineRemoveUserRequest) + +Remove Fax Line Access + +Removes a user's access to the specified Fax Line. + +### Example + +```java + +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **faxLineRemoveUserRequest** | [**FaxLineRemoveUserRequest**](FaxLineRemoveUserRequest.md)| | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +| **4XX** | failed_operation | - | + diff --git a/sdks/java-v2/docs/FaxLineAreaCodeGetCountryEnum.md b/sdks/java-v2/docs/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..10275bc6c --- /dev/null +++ b/sdks/java-v2/docs/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,15 @@ + + +# FaxLineAreaCodeGetCountryEnum + +## Enum + + +* `CA` (value: `"CA"`) + +* `US` (value: `"US"`) + +* `UK` (value: `"UK"`) + + + diff --git a/sdks/java-v2/docs/FaxLineAreaCodeGetProvinceEnum.md b/sdks/java-v2/docs/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..13cf50078 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,35 @@ + + +# FaxLineAreaCodeGetProvinceEnum + +## Enum + + +* `AB` (value: `"AB"`) + +* `BC` (value: `"BC"`) + +* `MB` (value: `"MB"`) + +* `NB` (value: `"NB"`) + +* `NL` (value: `"NL"`) + +* `NT` (value: `"NT"`) + +* `NS` (value: `"NS"`) + +* `NU` (value: `"NU"`) + +* `ON` (value: `"ON"`) + +* `PE` (value: `"PE"`) + +* `QC` (value: `"QC"`) + +* `SK` (value: `"SK"`) + +* `YT` (value: `"YT"`) + + + diff --git a/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md b/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..0b231dcf9 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,14 @@ + + +# FaxLineAreaCodeGetResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `areaCodes` | ```List``` | | | + + + diff --git a/sdks/java-v2/docs/FaxLineAreaCodeGetStateEnum.md b/sdks/java-v2/docs/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..577a48c63 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,111 @@ + + +# FaxLineAreaCodeGetStateEnum + +## Enum + + +* `AK` (value: `"AK"`) + +* `AL` (value: `"AL"`) + +* `AR` (value: `"AR"`) + +* `AZ` (value: `"AZ"`) + +* `CA` (value: `"CA"`) + +* `CO` (value: `"CO"`) + +* `CT` (value: `"CT"`) + +* `DC` (value: `"DC"`) + +* `DE` (value: `"DE"`) + +* `FL` (value: `"FL"`) + +* `GA` (value: `"GA"`) + +* `HI` (value: `"HI"`) + +* `IA` (value: `"IA"`) + +* `ID` (value: `"ID"`) + +* `IL` (value: `"IL"`) + +* `IN` (value: `"IN"`) + +* `KS` (value: `"KS"`) + +* `KY` (value: `"KY"`) + +* `LA` (value: `"LA"`) + +* `MA` (value: `"MA"`) + +* `MD` (value: `"MD"`) + +* `ME` (value: `"ME"`) + +* `MI` (value: `"MI"`) + +* `MN` (value: `"MN"`) + +* `MO` (value: `"MO"`) + +* `MS` (value: `"MS"`) + +* `MT` (value: `"MT"`) + +* `NC` (value: `"NC"`) + +* `ND` (value: `"ND"`) + +* `NE` (value: `"NE"`) + +* `NH` (value: `"NH"`) + +* `NJ` (value: `"NJ"`) + +* `NM` (value: `"NM"`) + +* `NV` (value: `"NV"`) + +* `NY` (value: `"NY"`) + +* `OH` (value: `"OH"`) + +* `OK` (value: `"OK"`) + +* `OR` (value: `"OR"`) + +* `PA` (value: `"PA"`) + +* `RI` (value: `"RI"`) + +* `SC` (value: `"SC"`) + +* `SD` (value: `"SD"`) + +* `TN` (value: `"TN"`) + +* `TX` (value: `"TX"`) + +* `UT` (value: `"UT"`) + +* `VA` (value: `"VA"`) + +* `VT` (value: `"VT"`) + +* `WA` (value: `"WA"`) + +* `WI` (value: `"WI"`) + +* `WV` (value: `"WV"`) + +* `WY` (value: `"WY"`) + + + diff --git a/sdks/java-v2/docs/FaxLineCreateRequest.md b/sdks/java-v2/docs/FaxLineCreateRequest.md new file mode 100644 index 000000000..6c4bf7d18 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineCreateRequest.md @@ -0,0 +1,17 @@ + + +# FaxLineCreateRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `areaCode`*_required_ | ```String``` | Area code | | +| `country`*_required_ | ```FaxLineAreaCodeGetCountryEnum``` | | | +| `city`*_required_ | ```String``` | City | | +| `accountId` | ```String``` | Account ID | | + + + diff --git a/sdks/java-v2/docs/FaxLineDeleteRequest.md b/sdks/java-v2/docs/FaxLineDeleteRequest.md new file mode 100644 index 000000000..d00dac614 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineDeleteRequest.md @@ -0,0 +1,14 @@ + + +# FaxLineDeleteRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```String``` | The Fax Line number. | | + + + diff --git a/sdks/java-v2/docs/FaxLineListResponse.md b/sdks/java-v2/docs/FaxLineListResponse.md new file mode 100644 index 000000000..f4724aaae --- /dev/null +++ b/sdks/java-v2/docs/FaxLineListResponse.md @@ -0,0 +1,16 @@ + + +# FaxLineListResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | +| `faxLines` | [```List```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + + + diff --git a/sdks/java-v2/docs/FaxLineRemoveUserRequest.md b/sdks/java-v2/docs/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..f353fdee6 --- /dev/null +++ b/sdks/java-v2/docs/FaxLineRemoveUserRequest.md @@ -0,0 +1,16 @@ + + +# FaxLineRemoveUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```String``` | The Fax Line number. | | +| `accountId` | ```String``` | Account ID | | +| `emailAddress` | ```String``` | Email address | | + + + diff --git a/sdks/java-v2/docs/FaxLineResponse.md b/sdks/java-v2/docs/FaxLineResponse.md new file mode 100644 index 000000000..4e373231e --- /dev/null +++ b/sdks/java-v2/docs/FaxLineResponse.md @@ -0,0 +1,15 @@ + + +# FaxLineResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `faxLine` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + + + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java new file mode 100644 index 000000000..65c5da4b9 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -0,0 +1,743 @@ +package com.dropbox.sign.api; + +import com.dropbox.sign.ApiException; +import com.dropbox.sign.ApiClient; +import com.dropbox.sign.ApiResponse; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.Pair; + +import jakarta.ws.rs.core.GenericType; + +import com.dropbox.sign.model.ErrorResponse; +import com.dropbox.sign.model.FaxLineAddUserRequest; +import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; +import com.dropbox.sign.model.FaxLineAreaCodeGetProvinceEnum; +import com.dropbox.sign.model.FaxLineAreaCodeGetResponse; +import com.dropbox.sign.model.FaxLineAreaCodeGetStateEnum; +import com.dropbox.sign.model.FaxLineCreateRequest; +import com.dropbox.sign.model.FaxLineDeleteRequest; +import com.dropbox.sign.model.FaxLineListResponse; +import com.dropbox.sign.model.FaxLineRemoveUserRequest; +import com.dropbox.sign.model.FaxLineResponse; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; + +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineApi { + private ApiClient apiClient; + + public FaxLineApi() { + this(Configuration.getDefaultApiClient()); + } + + public FaxLineApi(ApiClient apiClient) { + this.apiClient = apiClient; + } + + /** + * Get the API client + * + * @return API client + */ + public ApiClient getApiClient() { + return apiClient; + } + + /** + * Set the API client + * + * @param apiClient an instance of API client + */ + public void setApiClient(ApiClient apiClient) { + this.apiClient = apiClient; + } + + /** + * Add Fax Line User + * Grants a user access to the specified Fax Line. + * @param faxLineAddUserRequest (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineAddUser(FaxLineAddUserRequest faxLineAddUserRequest) throws ApiException { + return faxLineAddUserWithHttpInfo(faxLineAddUserRequest).getData(); + } + + + /** + * Add Fax Line User + * Grants a user access to the specified Fax Line. + * @param faxLineAddUserRequest (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineAddUserWithHttpInfo(FaxLineAddUserRequest faxLineAddUserRequest) throws ApiException { + + Object localVarPostBody = faxLineAddUserRequest; + + // verify the required parameter 'faxLineAddUserRequest' is set + if (faxLineAddUserRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineAddUserRequest' when calling faxLineAddUser"); + } + + // create path and map variables + String localVarPath = "/fax_line/add_user"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineAddUserRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineAddUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Get Available Fax Line Area Codes + * Returns a response with the area codes available for a given state/provice and city. + * @param country Filter area codes by country. (required) + * @param state Filter area codes by state. (optional) + * @param province Filter area codes by province. (optional) + * @param city Filter area codes by city. (optional) + * @return FaxLineAreaCodeGetResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + + /** + * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country) throws ApiException { + FaxLineAreaCodeGetStateEnum state = null; + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country) throws ApiException { + FaxLineAreaCodeGetStateEnum state = null; + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { + FaxLineAreaCodeGetProvinceEnum province = null; + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); + } + + /** + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + String city = null; + + return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); + } + + + /** + * Get Available Fax Line Area Codes + * Returns a response with the area codes available for a given state/provice and city. + * @param country Filter area codes by country. (required) + * @param state Filter area codes by state. (optional) + * @param province Filter area codes by province. (optional) + * @param city Filter area codes by city. (optional) + * @return ApiResponse<FaxLineAreaCodeGetResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + + Object localVarPostBody = null; + + // verify the required parameter 'country' is set + if (country == null) { + throw new ApiException(400, "Missing the required parameter 'country' when calling faxLineAreaCodeGet"); + } + + // create path and map variables + String localVarPath = "/fax_line/area_codes"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + localVarQueryParams.addAll(apiClient.parameterToPairs("", "country", country)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "state", state)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "province", province)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "city", city)); + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + + }; + + localVarFormParams = new HashMap(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineAreaCodeGet", localVarPath, "GET", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Purchase Fax Line + * Purchases a new Fax Line. + * @param faxLineCreateRequest (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineCreate(FaxLineCreateRequest faxLineCreateRequest) throws ApiException { + return faxLineCreateWithHttpInfo(faxLineCreateRequest).getData(); + } + + + /** + * Purchase Fax Line + * Purchases a new Fax Line. + * @param faxLineCreateRequest (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineCreateWithHttpInfo(FaxLineCreateRequest faxLineCreateRequest) throws ApiException { + + Object localVarPostBody = faxLineCreateRequest; + + // verify the required parameter 'faxLineCreateRequest' is set + if (faxLineCreateRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineCreateRequest' when calling faxLineCreate"); + } + + // create path and map variables + String localVarPath = "/fax_line/create"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineCreateRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineCreate", localVarPath, "POST", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Delete Fax Line + * Deletes the specified Fax Line from the subscription. + * @param faxLineDeleteRequest (required) + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public void faxLineDelete(FaxLineDeleteRequest faxLineDeleteRequest) throws ApiException { + faxLineDeleteWithHttpInfo(faxLineDeleteRequest); + } + + + /** + * Delete Fax Line + * Deletes the specified Fax Line from the subscription. + * @param faxLineDeleteRequest (required) + * @return ApiResponse<Void> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineDeleteWithHttpInfo(FaxLineDeleteRequest faxLineDeleteRequest) throws ApiException { + + Object localVarPostBody = faxLineDeleteRequest; + + // verify the required parameter 'faxLineDeleteRequest' is set + if (faxLineDeleteRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineDeleteRequest' when calling faxLineDelete"); + } + + // create path and map variables + String localVarPath = "/fax_line/delete"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineDeleteRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + return apiClient.invokeAPI("FaxLineApi.faxLineDelete", localVarPath, "DELETE", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, null, false); + } + /** + * Get Fax Line + * Returns the properties and settings of a Fax Line. + * @param number The Fax Line number. (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineGet(String number) throws ApiException { + return faxLineGetWithHttpInfo(number).getData(); + } + + + /** + * Get Fax Line + * Returns the properties and settings of a Fax Line. + * @param number The Fax Line number. (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineGetWithHttpInfo(String number) throws ApiException { + + Object localVarPostBody = null; + + // verify the required parameter 'number' is set + if (number == null) { + throw new ApiException(400, "Missing the required parameter 'number' when calling faxLineGet"); + } + + // create path and map variables + String localVarPath = "/fax_line/{number}" + .replaceAll("\\{" + "number" + "\\}", apiClient.escapeString(number.toString())); + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + + }; + + localVarFormParams = new HashMap(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineGet", localVarPath, "GET", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * List Fax Lines + * Returns the properties and settings of multiple Fax Lines. + * @param accountId Account ID (optional) + * @param page Page (optional) + * @param pageSize Page size (optional) + * @param showTeamLines Show team lines (optional) + * @return FaxLineListResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineListResponse faxLineList(String accountId, Integer page, Integer pageSize, Boolean showTeamLines) throws ApiException { + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList() throws ApiException { + String accountId = null; + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo() throws ApiException { + String accountId = null; + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList(String accountId) throws ApiException { + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo(String accountId) throws ApiException { + Integer page = null; + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList(String accountId, Integer page) throws ApiException { + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page) throws ApiException { + Integer pageSize = null; + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + /** + * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) + */ + public FaxLineListResponse faxLineList(String accountId, Integer page, Integer pageSize) throws ApiException { + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); + } + + /** + * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) + */ + public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page, Integer pageSize) throws ApiException { + Boolean showTeamLines = null; + + return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); + } + + + /** + * List Fax Lines + * Returns the properties and settings of multiple Fax Lines. + * @param accountId Account ID (optional) + * @param page Page (optional) + * @param pageSize Page size (optional) + * @param showTeamLines Show team lines (optional) + * @return ApiResponse<FaxLineListResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page, Integer pageSize, Boolean showTeamLines) throws ApiException { + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = "/fax_line/list"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + localVarQueryParams.addAll(apiClient.parameterToPairs("", "account_id", accountId)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "page", page)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "page_size", pageSize)); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "show_team_lines", showTeamLines)); + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + + }; + + localVarFormParams = new HashMap(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineList", localVarPath, "GET", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } + /** + * Remove Fax Line Access + * Removes a user's access to the specified Fax Line. + * @param faxLineRemoveUserRequest (required) + * @return FaxLineResponse + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public FaxLineResponse faxLineRemoveUser(FaxLineRemoveUserRequest faxLineRemoveUserRequest) throws ApiException { + return faxLineRemoveUserWithHttpInfo(faxLineRemoveUserRequest).getData(); + } + + + /** + * Remove Fax Line Access + * Removes a user's access to the specified Fax Line. + * @param faxLineRemoveUserRequest (required) + * @return ApiResponse<FaxLineResponse> + * @throws ApiException if fails to make API call + * @http.response.details + + + + +
Status Code Description Response Headers
200 successful operation * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
4XX failed_operation -
+ */ + public ApiResponse faxLineRemoveUserWithHttpInfo(FaxLineRemoveUserRequest faxLineRemoveUserRequest) throws ApiException { + + Object localVarPostBody = faxLineRemoveUserRequest; + + // verify the required parameter 'faxLineRemoveUserRequest' is set + if (faxLineRemoveUserRequest == null) { + throw new ApiException(400, "Missing the required parameter 'faxLineRemoveUserRequest' when calling faxLineRemoveUser"); + } + + // create path and map variables + String localVarPath = "/fax_line/remove_user"; + + // query params + List localVarQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + + + + + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + + final String[] localVarContentTypes = { + "application/json" + }; + + localVarFormParams = faxLineRemoveUserRequest.createFormData(); + boolean isFileTypeFound = !localVarFormParams.isEmpty(); + + final String localVarContentType = isFileTypeFound? "multipart/form-data" : apiClient.selectHeaderContentType(localVarContentTypes); + + String[] localVarAuthNames = new String[] { "api_key" }; + + GenericType localVarReturnType = new GenericType() {}; + + return apiClient.invokeAPI("FaxLineApi.faxLineRemoveUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, + localVarAuthNames, localVarReturnType, false); + } +} \ No newline at end of file diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java new file mode 100644 index 000000000..f2ca18c0b --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAddUserRequest.java @@ -0,0 +1,283 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.Arrays; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineAddUserRequest + */ +@JsonPropertyOrder({ + FaxLineAddUserRequest.JSON_PROPERTY_NUMBER, + FaxLineAddUserRequest.JSON_PROPERTY_ACCOUNT_ID, + FaxLineAddUserRequest.JSON_PROPERTY_EMAIL_ADDRESS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineAddUserRequest { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public static final String JSON_PROPERTY_ACCOUNT_ID = "account_id"; + private String accountId; + + public static final String JSON_PROPERTY_EMAIL_ADDRESS = "email_address"; + private String emailAddress; + + public FaxLineAddUserRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineAddUserRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineAddUserRequest.class); + } + + static public FaxLineAddUserRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineAddUserRequest.class + ); + } + + public FaxLineAddUserRequest number(String number) { + this.number = number; + return this; + } + + /** + * The Fax Line number. + * @return number + **/ + @jakarta.annotation.Nonnull + @ApiModelProperty(required = true, value = "The Fax Line number.") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setNumber(String number) { + this.number = number; + } + + + public FaxLineAddUserRequest accountId(String accountId) { + this.accountId = accountId; + return this; + } + + /** + * Account ID + * @return accountId + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(example = "ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97", value = "Account ID") + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getAccountId() { + return accountId; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccountId(String accountId) { + this.accountId = accountId; + } + + + public FaxLineAddUserRequest emailAddress(String emailAddress) { + this.emailAddress = emailAddress; + return this; + } + + /** + * Email address + * @return emailAddress + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "Email address") + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getEmailAddress() { + return emailAddress; + } + + + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setEmailAddress(String emailAddress) { + this.emailAddress = emailAddress; + } + + + /** + * Return true if this FaxLineAddUserRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineAddUserRequest faxLineAddUserRequest = (FaxLineAddUserRequest) o; + return Objects.equals(this.number, faxLineAddUserRequest.number) && + Objects.equals(this.accountId, faxLineAddUserRequest.accountId) && + Objects.equals(this.emailAddress, faxLineAddUserRequest.emailAddress); + } + + @Override + public int hashCode() { + return Objects.hash(number, accountId, emailAddress); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineAddUserRequest {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append(" emailAddress: ").append(toIndentedString(emailAddress)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + if (accountId != null) { + if (isFileTypeOrListOfFiles(accountId)) { + fileTypeFound = true; + } + + if (accountId.getClass().equals(java.io.File.class) || + accountId.getClass().equals(Integer.class) || + accountId.getClass().equals(String.class) || + accountId.getClass().isEnum()) { + map.put("account_id", accountId); + } else if (isListOfFile(accountId)) { + for(int i = 0; i< getListSize(accountId); i++) { + map.put("account_id[" + i + "]", getFromList(accountId, i)); + } + } + else { + map.put("account_id", JSON.getDefault().getMapper().writeValueAsString(accountId)); + } + } + if (emailAddress != null) { + if (isFileTypeOrListOfFiles(emailAddress)) { + fileTypeFound = true; + } + + if (emailAddress.getClass().equals(java.io.File.class) || + emailAddress.getClass().equals(Integer.class) || + emailAddress.getClass().equals(String.class) || + emailAddress.getClass().isEnum()) { + map.put("email_address", emailAddress); + } else if (isListOfFile(emailAddress)) { + for(int i = 0; i< getListSize(emailAddress); i++) { + map.put("email_address[" + i + "]", getFromList(emailAddress, i)); + } + } + else { + map.put("email_address", JSON.getDefault().getMapper().writeValueAsString(emailAddress)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java new file mode 100644 index 000000000..08da9731a --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetCountryEnum.java @@ -0,0 +1,67 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Gets or Sets FaxLineAreaCodeGetCountryEnum + */ +public enum FaxLineAreaCodeGetCountryEnum { + + CA("CA"), + + US("US"), + + UK("UK"); + + private String value; + + FaxLineAreaCodeGetCountryEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static FaxLineAreaCodeGetCountryEnum fromValue(String value) { + for (FaxLineAreaCodeGetCountryEnum b : FaxLineAreaCodeGetCountryEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java new file mode 100644 index 000000000..566181f56 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetProvinceEnum.java @@ -0,0 +1,87 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Gets or Sets FaxLineAreaCodeGetProvinceEnum + */ +public enum FaxLineAreaCodeGetProvinceEnum { + + AB("AB"), + + BC("BC"), + + MB("MB"), + + NB("NB"), + + NL("NL"), + + NT("NT"), + + NS("NS"), + + NU("NU"), + + ON("ON"), + + PE("PE"), + + QC("QC"), + + SK("SK"), + + YT("YT"); + + private String value; + + FaxLineAreaCodeGetProvinceEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static FaxLineAreaCodeGetProvinceEnum fromValue(String value) { + for (FaxLineAreaCodeGetProvinceEnum b : FaxLineAreaCodeGetProvinceEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java new file mode 100644 index 000000000..b8dfac3e1 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java @@ -0,0 +1,191 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineAreaCodeGetResponse + */ +@JsonPropertyOrder({ + FaxLineAreaCodeGetResponse.JSON_PROPERTY_AREA_CODES +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineAreaCodeGetResponse { + public static final String JSON_PROPERTY_AREA_CODES = "area_codes"; + private List areaCodes; + + public FaxLineAreaCodeGetResponse() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineAreaCodeGetResponse init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineAreaCodeGetResponse.class); + } + + static public FaxLineAreaCodeGetResponse init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineAreaCodeGetResponse.class + ); + } + + public FaxLineAreaCodeGetResponse areaCodes(List areaCodes) { + this.areaCodes = areaCodes; + return this; + } + + public FaxLineAreaCodeGetResponse addAreaCodesItem(String areaCodesItem) { + if (this.areaCodes == null) { + this.areaCodes = new ArrayList<>(); + } + this.areaCodes.add(areaCodesItem); + return this; + } + + /** + * Get areaCodes + * @return areaCodes + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_AREA_CODES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public List getAreaCodes() { + return areaCodes; + } + + + @JsonProperty(JSON_PROPERTY_AREA_CODES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAreaCodes(List areaCodes) { + this.areaCodes = areaCodes; + } + + + /** + * Return true if this FaxLineAreaCodeGetResponse object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineAreaCodeGetResponse faxLineAreaCodeGetResponse = (FaxLineAreaCodeGetResponse) o; + return Objects.equals(this.areaCodes, faxLineAreaCodeGetResponse.areaCodes); + } + + @Override + public int hashCode() { + return Objects.hash(areaCodes); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineAreaCodeGetResponse {\n"); + sb.append(" areaCodes: ").append(toIndentedString(areaCodes)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (areaCodes != null) { + if (isFileTypeOrListOfFiles(areaCodes)) { + fileTypeFound = true; + } + + if (areaCodes.getClass().equals(java.io.File.class) || + areaCodes.getClass().equals(Integer.class) || + areaCodes.getClass().equals(String.class) || + areaCodes.getClass().isEnum()) { + map.put("area_codes", areaCodes); + } else if (isListOfFile(areaCodes)) { + for(int i = 0; i< getListSize(areaCodes); i++) { + map.put("area_codes[" + i + "]", getFromList(areaCodes, i)); + } + } + else { + map.put("area_codes", JSON.getDefault().getMapper().writeValueAsString(areaCodes)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java new file mode 100644 index 000000000..6a136e116 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetStateEnum.java @@ -0,0 +1,163 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Gets or Sets FaxLineAreaCodeGetStateEnum + */ +public enum FaxLineAreaCodeGetStateEnum { + + AK("AK"), + + AL("AL"), + + AR("AR"), + + AZ("AZ"), + + CA("CA"), + + CO("CO"), + + CT("CT"), + + DC("DC"), + + DE("DE"), + + FL("FL"), + + GA("GA"), + + HI("HI"), + + IA("IA"), + + ID("ID"), + + IL("IL"), + + IN("IN"), + + KS("KS"), + + KY("KY"), + + LA("LA"), + + MA("MA"), + + MD("MD"), + + ME("ME"), + + MI("MI"), + + MN("MN"), + + MO("MO"), + + MS("MS"), + + MT("MT"), + + NC("NC"), + + ND("ND"), + + NE("NE"), + + NH("NH"), + + NJ("NJ"), + + NM("NM"), + + NV("NV"), + + NY("NY"), + + OH("OH"), + + OK("OK"), + + OR("OR"), + + PA("PA"), + + RI("RI"), + + SC("SC"), + + SD("SD"), + + TN("TN"), + + TX("TX"), + + UT("UT"), + + VA("VA"), + + VT("VT"), + + WA("WA"), + + WI("WI"), + + WV("WV"), + + WY("WY"); + + private String value; + + FaxLineAreaCodeGetStateEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static FaxLineAreaCodeGetStateEnum fromValue(String value) { + for (FaxLineAreaCodeGetStateEnum b : FaxLineAreaCodeGetStateEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java new file mode 100644 index 000000000..3288b6bb6 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -0,0 +1,335 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.Arrays; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineCreateRequest + */ +@JsonPropertyOrder({ + FaxLineCreateRequest.JSON_PROPERTY_AREA_CODE, + FaxLineCreateRequest.JSON_PROPERTY_COUNTRY, + FaxLineCreateRequest.JSON_PROPERTY_CITY, + FaxLineCreateRequest.JSON_PROPERTY_ACCOUNT_ID +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineCreateRequest { + public static final String JSON_PROPERTY_AREA_CODE = "area_code"; + private String areaCode; + + public static final String JSON_PROPERTY_COUNTRY = "country"; + private FaxLineAreaCodeGetCountryEnum country; + + public static final String JSON_PROPERTY_CITY = "city"; + private String city; + + public static final String JSON_PROPERTY_ACCOUNT_ID = "account_id"; + private String accountId; + + public FaxLineCreateRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineCreateRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineCreateRequest.class); + } + + static public FaxLineCreateRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineCreateRequest.class + ); + } + + public FaxLineCreateRequest areaCode(String areaCode) { + this.areaCode = areaCode; + return this; + } + + /** + * Area code + * @return areaCode + **/ + @jakarta.annotation.Nonnull + @ApiModelProperty(required = true, value = "Area code") + @JsonProperty(JSON_PROPERTY_AREA_CODE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getAreaCode() { + return areaCode; + } + + + @JsonProperty(JSON_PROPERTY_AREA_CODE) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setAreaCode(String areaCode) { + this.areaCode = areaCode; + } + + + public FaxLineCreateRequest country(FaxLineAreaCodeGetCountryEnum country) { + this.country = country; + return this; + } + + /** + * Get country + * @return country + **/ + @jakarta.annotation.Nonnull + @ApiModelProperty(required = true, value = "") + @JsonProperty(JSON_PROPERTY_COUNTRY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public FaxLineAreaCodeGetCountryEnum getCountry() { + return country; + } + + + @JsonProperty(JSON_PROPERTY_COUNTRY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setCountry(FaxLineAreaCodeGetCountryEnum country) { + this.country = country; + } + + + public FaxLineCreateRequest city(String city) { + this.city = city; + return this; + } + + /** + * City + * @return city + **/ + @jakarta.annotation.Nonnull + @ApiModelProperty(required = true, value = "City") + @JsonProperty(JSON_PROPERTY_CITY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getCity() { + return city; + } + + + @JsonProperty(JSON_PROPERTY_CITY) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setCity(String city) { + this.city = city; + } + + + public FaxLineCreateRequest accountId(String accountId) { + this.accountId = accountId; + return this; + } + + /** + * Account ID + * @return accountId + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(example = "ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97", value = "Account ID") + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getAccountId() { + return accountId; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccountId(String accountId) { + this.accountId = accountId; + } + + + /** + * Return true if this FaxLineCreateRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineCreateRequest faxLineCreateRequest = (FaxLineCreateRequest) o; + return Objects.equals(this.areaCode, faxLineCreateRequest.areaCode) && + Objects.equals(this.country, faxLineCreateRequest.country) && + Objects.equals(this.city, faxLineCreateRequest.city) && + Objects.equals(this.accountId, faxLineCreateRequest.accountId); + } + + @Override + public int hashCode() { + return Objects.hash(areaCode, country, city, accountId); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineCreateRequest {\n"); + sb.append(" areaCode: ").append(toIndentedString(areaCode)).append("\n"); + sb.append(" country: ").append(toIndentedString(country)).append("\n"); + sb.append(" city: ").append(toIndentedString(city)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (areaCode != null) { + if (isFileTypeOrListOfFiles(areaCode)) { + fileTypeFound = true; + } + + if (areaCode.getClass().equals(java.io.File.class) || + areaCode.getClass().equals(Integer.class) || + areaCode.getClass().equals(String.class) || + areaCode.getClass().isEnum()) { + map.put("area_code", areaCode); + } else if (isListOfFile(areaCode)) { + for(int i = 0; i< getListSize(areaCode); i++) { + map.put("area_code[" + i + "]", getFromList(areaCode, i)); + } + } + else { + map.put("area_code", JSON.getDefault().getMapper().writeValueAsString(areaCode)); + } + } + if (country != null) { + if (isFileTypeOrListOfFiles(country)) { + fileTypeFound = true; + } + + if (country.getClass().equals(java.io.File.class) || + country.getClass().equals(Integer.class) || + country.getClass().equals(String.class) || + country.getClass().isEnum()) { + map.put("country", country); + } else if (isListOfFile(country)) { + for(int i = 0; i< getListSize(country); i++) { + map.put("country[" + i + "]", getFromList(country, i)); + } + } + else { + map.put("country", JSON.getDefault().getMapper().writeValueAsString(country)); + } + } + if (city != null) { + if (isFileTypeOrListOfFiles(city)) { + fileTypeFound = true; + } + + if (city.getClass().equals(java.io.File.class) || + city.getClass().equals(Integer.class) || + city.getClass().equals(String.class) || + city.getClass().isEnum()) { + map.put("city", city); + } else if (isListOfFile(city)) { + for(int i = 0; i< getListSize(city); i++) { + map.put("city[" + i + "]", getFromList(city, i)); + } + } + else { + map.put("city", JSON.getDefault().getMapper().writeValueAsString(city)); + } + } + if (accountId != null) { + if (isFileTypeOrListOfFiles(accountId)) { + fileTypeFound = true; + } + + if (accountId.getClass().equals(java.io.File.class) || + accountId.getClass().equals(Integer.class) || + accountId.getClass().equals(String.class) || + accountId.getClass().isEnum()) { + map.put("account_id", accountId); + } else if (isListOfFile(accountId)) { + for(int i = 0; i< getListSize(accountId); i++) { + map.put("account_id[" + i + "]", getFromList(accountId, i)); + } + } + else { + map.put("account_id", JSON.getDefault().getMapper().writeValueAsString(accountId)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java new file mode 100644 index 000000000..0cd834207 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineDeleteRequest.java @@ -0,0 +1,181 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.Arrays; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineDeleteRequest + */ +@JsonPropertyOrder({ + FaxLineDeleteRequest.JSON_PROPERTY_NUMBER +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineDeleteRequest { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public FaxLineDeleteRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineDeleteRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineDeleteRequest.class); + } + + static public FaxLineDeleteRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineDeleteRequest.class + ); + } + + public FaxLineDeleteRequest number(String number) { + this.number = number; + return this; + } + + /** + * The Fax Line number. + * @return number + **/ + @jakarta.annotation.Nonnull + @ApiModelProperty(required = true, value = "The Fax Line number.") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setNumber(String number) { + this.number = number; + } + + + /** + * Return true if this FaxLineDeleteRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineDeleteRequest faxLineDeleteRequest = (FaxLineDeleteRequest) o; + return Objects.equals(this.number, faxLineDeleteRequest.number); + } + + @Override + public int hashCode() { + return Objects.hash(number); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineDeleteRequest {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java new file mode 100644 index 000000000..d3324410f --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java @@ -0,0 +1,296 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.FaxLineResponse; +import com.dropbox.sign.model.ListInfoResponse; +import com.dropbox.sign.model.WarningResponse; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineListResponse + */ +@JsonPropertyOrder({ + FaxLineListResponse.JSON_PROPERTY_LIST_INFO, + FaxLineListResponse.JSON_PROPERTY_FAX_LINES, + FaxLineListResponse.JSON_PROPERTY_WARNINGS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineListResponse { + public static final String JSON_PROPERTY_LIST_INFO = "list_info"; + private ListInfoResponse listInfo; + + public static final String JSON_PROPERTY_FAX_LINES = "fax_lines"; + private List faxLines; + + public static final String JSON_PROPERTY_WARNINGS = "warnings"; + private WarningResponse warnings; + + public FaxLineListResponse() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineListResponse init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineListResponse.class); + } + + static public FaxLineListResponse init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineListResponse.class + ); + } + + public FaxLineListResponse listInfo(ListInfoResponse listInfo) { + this.listInfo = listInfo; + return this; + } + + /** + * Get listInfo + * @return listInfo + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_LIST_INFO) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public ListInfoResponse getListInfo() { + return listInfo; + } + + + @JsonProperty(JSON_PROPERTY_LIST_INFO) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setListInfo(ListInfoResponse listInfo) { + this.listInfo = listInfo; + } + + + public FaxLineListResponse faxLines(List faxLines) { + this.faxLines = faxLines; + return this; + } + + public FaxLineListResponse addFaxLinesItem(FaxLineResponse faxLinesItem) { + if (this.faxLines == null) { + this.faxLines = new ArrayList<>(); + } + this.faxLines.add(faxLinesItem); + return this; + } + + /** + * Get faxLines + * @return faxLines + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_FAX_LINES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public List getFaxLines() { + return faxLines; + } + + + @JsonProperty(JSON_PROPERTY_FAX_LINES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setFaxLines(List faxLines) { + this.faxLines = faxLines; + } + + + public FaxLineListResponse warnings(WarningResponse warnings) { + this.warnings = warnings; + return this; + } + + /** + * Get warnings + * @return warnings + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public WarningResponse getWarnings() { + return warnings; + } + + + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setWarnings(WarningResponse warnings) { + this.warnings = warnings; + } + + + /** + * Return true if this FaxLineListResponse object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineListResponse faxLineListResponse = (FaxLineListResponse) o; + return Objects.equals(this.listInfo, faxLineListResponse.listInfo) && + Objects.equals(this.faxLines, faxLineListResponse.faxLines) && + Objects.equals(this.warnings, faxLineListResponse.warnings); + } + + @Override + public int hashCode() { + return Objects.hash(listInfo, faxLines, warnings); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineListResponse {\n"); + sb.append(" listInfo: ").append(toIndentedString(listInfo)).append("\n"); + sb.append(" faxLines: ").append(toIndentedString(faxLines)).append("\n"); + sb.append(" warnings: ").append(toIndentedString(warnings)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (listInfo != null) { + if (isFileTypeOrListOfFiles(listInfo)) { + fileTypeFound = true; + } + + if (listInfo.getClass().equals(java.io.File.class) || + listInfo.getClass().equals(Integer.class) || + listInfo.getClass().equals(String.class) || + listInfo.getClass().isEnum()) { + map.put("list_info", listInfo); + } else if (isListOfFile(listInfo)) { + for(int i = 0; i< getListSize(listInfo); i++) { + map.put("list_info[" + i + "]", getFromList(listInfo, i)); + } + } + else { + map.put("list_info", JSON.getDefault().getMapper().writeValueAsString(listInfo)); + } + } + if (faxLines != null) { + if (isFileTypeOrListOfFiles(faxLines)) { + fileTypeFound = true; + } + + if (faxLines.getClass().equals(java.io.File.class) || + faxLines.getClass().equals(Integer.class) || + faxLines.getClass().equals(String.class) || + faxLines.getClass().isEnum()) { + map.put("fax_lines", faxLines); + } else if (isListOfFile(faxLines)) { + for(int i = 0; i< getListSize(faxLines); i++) { + map.put("fax_lines[" + i + "]", getFromList(faxLines, i)); + } + } + else { + map.put("fax_lines", JSON.getDefault().getMapper().writeValueAsString(faxLines)); + } + } + if (warnings != null) { + if (isFileTypeOrListOfFiles(warnings)) { + fileTypeFound = true; + } + + if (warnings.getClass().equals(java.io.File.class) || + warnings.getClass().equals(Integer.class) || + warnings.getClass().equals(String.class) || + warnings.getClass().isEnum()) { + map.put("warnings", warnings); + } else if (isListOfFile(warnings)) { + for(int i = 0; i< getListSize(warnings); i++) { + map.put("warnings[" + i + "]", getFromList(warnings, i)); + } + } + else { + map.put("warnings", JSON.getDefault().getMapper().writeValueAsString(warnings)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java new file mode 100644 index 000000000..1fd430a68 --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineRemoveUserRequest.java @@ -0,0 +1,283 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.Arrays; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineRemoveUserRequest + */ +@JsonPropertyOrder({ + FaxLineRemoveUserRequest.JSON_PROPERTY_NUMBER, + FaxLineRemoveUserRequest.JSON_PROPERTY_ACCOUNT_ID, + FaxLineRemoveUserRequest.JSON_PROPERTY_EMAIL_ADDRESS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineRemoveUserRequest { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public static final String JSON_PROPERTY_ACCOUNT_ID = "account_id"; + private String accountId; + + public static final String JSON_PROPERTY_EMAIL_ADDRESS = "email_address"; + private String emailAddress; + + public FaxLineRemoveUserRequest() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineRemoveUserRequest init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineRemoveUserRequest.class); + } + + static public FaxLineRemoveUserRequest init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineRemoveUserRequest.class + ); + } + + public FaxLineRemoveUserRequest number(String number) { + this.number = number; + return this; + } + + /** + * The Fax Line number. + * @return number + **/ + @jakarta.annotation.Nonnull + @ApiModelProperty(required = true, value = "The Fax Line number.") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.ALWAYS) + public void setNumber(String number) { + this.number = number; + } + + + public FaxLineRemoveUserRequest accountId(String accountId) { + this.accountId = accountId; + return this; + } + + /** + * Account ID + * @return accountId + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(example = "ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97", value = "Account ID") + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getAccountId() { + return accountId; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNT_ID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccountId(String accountId) { + this.accountId = accountId; + } + + + public FaxLineRemoveUserRequest emailAddress(String emailAddress) { + this.emailAddress = emailAddress; + return this; + } + + /** + * Email address + * @return emailAddress + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "Email address") + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getEmailAddress() { + return emailAddress; + } + + + @JsonProperty(JSON_PROPERTY_EMAIL_ADDRESS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setEmailAddress(String emailAddress) { + this.emailAddress = emailAddress; + } + + + /** + * Return true if this FaxLineRemoveUserRequest object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineRemoveUserRequest faxLineRemoveUserRequest = (FaxLineRemoveUserRequest) o; + return Objects.equals(this.number, faxLineRemoveUserRequest.number) && + Objects.equals(this.accountId, faxLineRemoveUserRequest.accountId) && + Objects.equals(this.emailAddress, faxLineRemoveUserRequest.emailAddress); + } + + @Override + public int hashCode() { + return Objects.hash(number, accountId, emailAddress); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineRemoveUserRequest {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append(" emailAddress: ").append(toIndentedString(emailAddress)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + if (accountId != null) { + if (isFileTypeOrListOfFiles(accountId)) { + fileTypeFound = true; + } + + if (accountId.getClass().equals(java.io.File.class) || + accountId.getClass().equals(Integer.class) || + accountId.getClass().equals(String.class) || + accountId.getClass().isEnum()) { + map.put("account_id", accountId); + } else if (isListOfFile(accountId)) { + for(int i = 0; i< getListSize(accountId); i++) { + map.put("account_id[" + i + "]", getFromList(accountId, i)); + } + } + else { + map.put("account_id", JSON.getDefault().getMapper().writeValueAsString(accountId)); + } + } + if (emailAddress != null) { + if (isFileTypeOrListOfFiles(emailAddress)) { + fileTypeFound = true; + } + + if (emailAddress.getClass().equals(java.io.File.class) || + emailAddress.getClass().equals(Integer.class) || + emailAddress.getClass().equals(String.class) || + emailAddress.getClass().isEnum()) { + map.put("email_address", emailAddress); + } else if (isListOfFile(emailAddress)) { + for(int i = 0; i< getListSize(emailAddress); i++) { + map.put("email_address[" + i + "]", getFromList(emailAddress, i)); + } + } + else { + map.put("email_address", JSON.getDefault().getMapper().writeValueAsString(emailAddress)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java new file mode 100644 index 000000000..d9fe0bc0c --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java @@ -0,0 +1,233 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.WarningResponse; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.Arrays; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLineResponse + */ +@JsonPropertyOrder({ + FaxLineResponse.JSON_PROPERTY_FAX_LINE, + FaxLineResponse.JSON_PROPERTY_WARNINGS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLineResponse { + public static final String JSON_PROPERTY_FAX_LINE = "fax_line"; + private FaxLineResponse faxLine; + + public static final String JSON_PROPERTY_WARNINGS = "warnings"; + private WarningResponse warnings; + + public FaxLineResponse() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLineResponse init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineResponse.class); + } + + static public FaxLineResponse init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLineResponse.class + ); + } + + public FaxLineResponse faxLine(FaxLineResponse faxLine) { + this.faxLine = faxLine; + return this; + } + + /** + * Get faxLine + * @return faxLine + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_FAX_LINE) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public FaxLineResponse getFaxLine() { + return faxLine; + } + + + @JsonProperty(JSON_PROPERTY_FAX_LINE) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setFaxLine(FaxLineResponse faxLine) { + this.faxLine = faxLine; + } + + + public FaxLineResponse warnings(WarningResponse warnings) { + this.warnings = warnings; + return this; + } + + /** + * Get warnings + * @return warnings + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public WarningResponse getWarnings() { + return warnings; + } + + + @JsonProperty(JSON_PROPERTY_WARNINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setWarnings(WarningResponse warnings) { + this.warnings = warnings; + } + + + /** + * Return true if this FaxLineResponse object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLineResponse faxLineResponse = (FaxLineResponse) o; + return Objects.equals(this.faxLine, faxLineResponse.faxLine) && + Objects.equals(this.warnings, faxLineResponse.warnings); + } + + @Override + public int hashCode() { + return Objects.hash(faxLine, warnings); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLineResponse {\n"); + sb.append(" faxLine: ").append(toIndentedString(faxLine)).append("\n"); + sb.append(" warnings: ").append(toIndentedString(warnings)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (faxLine != null) { + if (isFileTypeOrListOfFiles(faxLine)) { + fileTypeFound = true; + } + + if (faxLine.getClass().equals(java.io.File.class) || + faxLine.getClass().equals(Integer.class) || + faxLine.getClass().equals(String.class) || + faxLine.getClass().isEnum()) { + map.put("fax_line", faxLine); + } else if (isListOfFile(faxLine)) { + for(int i = 0; i< getListSize(faxLine); i++) { + map.put("fax_line[" + i + "]", getFromList(faxLine, i)); + } + } + else { + map.put("fax_line", JSON.getDefault().getMapper().writeValueAsString(faxLine)); + } + } + if (warnings != null) { + if (isFileTypeOrListOfFiles(warnings)) { + fileTypeFound = true; + } + + if (warnings.getClass().equals(java.io.File.class) || + warnings.getClass().equals(Integer.class) || + warnings.getClass().equals(String.class) || + warnings.getClass().isEnum()) { + map.put("warnings", warnings); + } else if (isListOfFile(warnings)) { + for(int i = 0; i< getListSize(warnings); i++) { + map.put("warnings[" + i + "]", getFromList(warnings, i)); + } + } + else { + map.put("warnings", JSON.getDefault().getMapper().writeValueAsString(warnings)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/node/README.md b/sdks/node/README.md index 0d019cc7a..999b7fc46 100644 --- a/sdks/node/README.md +++ b/sdks/node/README.md @@ -120,6 +120,13 @@ All URIs are relative to *https://api.hellosign.com/v3* | *BulkSendJobApi* | [**bulkSendJobList**](./docs/api/BulkSendJobApi.md#bulksendjoblist) | **GET** /bulk_send_job/list | List Bulk Send Jobs | | *EmbeddedApi* | [**embeddedEditUrl**](./docs/api/EmbeddedApi.md#embeddedediturl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL | | *EmbeddedApi* | [**embeddedSignUrl**](./docs/api/EmbeddedApi.md#embeddedsignurl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL | +| *FaxLineApi* | [**faxLineAddUser**](./docs/api/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | +| *FaxLineApi* | [**faxLineAreaCodeGet**](./docs/api/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | +| *FaxLineApi* | [**faxLineCreate**](./docs/api/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | +| *FaxLineApi* | [**faxLineDelete**](./docs/api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line | +| *FaxLineApi* | [**faxLineGet**](./docs/api/FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line | +| *FaxLineApi* | [**faxLineList**](./docs/api/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | +| *FaxLineApi* | [**faxLineRemoveUser**](./docs/api/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | | *OAuthApi* | [**oauthTokenGenerate**](./docs/api/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate | | *OAuthApi* | [**oauthTokenRefresh**](./docs/api/OAuthApi.md#oauthtokenrefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh | | *ReportApi* | [**reportCreate**](./docs/api/ReportApi.md#reportcreate) | **POST** /report/create | Create Report | @@ -201,6 +208,16 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](./docs/model/EventCallbackRequest.md) - [EventCallbackRequestEvent](./docs/model/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](./docs/model/EventCallbackRequestEventMetadata.md) +- [FaxLineAddUserRequest](./docs/model/FaxLineAddUserRequest.md) +- [FaxLineAreaCodeGetCountryEnum](./docs/model/FaxLineAreaCodeGetCountryEnum.md) +- [FaxLineAreaCodeGetProvinceEnum](./docs/model/FaxLineAreaCodeGetProvinceEnum.md) +- [FaxLineAreaCodeGetResponse](./docs/model/FaxLineAreaCodeGetResponse.md) +- [FaxLineAreaCodeGetStateEnum](./docs/model/FaxLineAreaCodeGetStateEnum.md) +- [FaxLineCreateRequest](./docs/model/FaxLineCreateRequest.md) +- [FaxLineDeleteRequest](./docs/model/FaxLineDeleteRequest.md) +- [FaxLineListResponse](./docs/model/FaxLineListResponse.md) +- [FaxLineRemoveUserRequest](./docs/model/FaxLineRemoveUserRequest.md) +- [FaxLineResponse](./docs/model/FaxLineResponse.md) - [FileResponse](./docs/model/FileResponse.md) - [FileResponseDataUri](./docs/model/FileResponseDataUri.md) - [ListInfoResponse](./docs/model/ListInfoResponse.md) diff --git a/sdks/node/api/faxLineApi.ts b/sdks/node/api/faxLineApi.ts new file mode 100644 index 000000000..d4cbbec6b --- /dev/null +++ b/sdks/node/api/faxLineApi.ts @@ -0,0 +1,1209 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import axios, { AxiosError, AxiosRequestConfig } from "axios"; + +/* tslint:disable:no-unused-locals */ +import { + ObjectSerializer, + Authentication, + VoidAuth, + Interceptor, + HttpBasicAuth, + HttpBearerAuth, + ApiKeyAuth, + OAuth, + ErrorResponse, + FaxLineAddUserRequest, + FaxLineAreaCodeGetCountryEnum, + FaxLineAreaCodeGetProvinceEnum, + FaxLineAreaCodeGetResponse, + FaxLineAreaCodeGetStateEnum, + FaxLineCreateRequest, + FaxLineDeleteRequest, + FaxLineListResponse, + FaxLineRemoveUserRequest, + FaxLineResponse, +} from "../model"; + +import { + HttpError, + optionsI, + returnTypeT, + returnTypeI, + generateFormData, + toFormData, + queryParamsSerializer, + USER_AGENT, +} from "./"; + +let defaultBasePath = "https://api.hellosign.com/v3"; + +// =============================================== +// This file is autogenerated - Please do not edit +// =============================================== + +export enum FaxLineApiApiKeys {} + +export class FaxLineApi { + protected _basePath = defaultBasePath; + protected _defaultHeaders: any = { + "User-Agent": USER_AGENT, + }; + protected _useQuerystring: boolean = false; + + protected authentications = { + default: new VoidAuth(), + api_key: new HttpBasicAuth(), + oauth2: new HttpBearerAuth(), + }; + + protected interceptors: Interceptor[] = []; + + constructor(basePath?: string) { + if (basePath) { + this.basePath = basePath; + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + set defaultHeaders(defaultHeaders: any) { + this._defaultHeaders = defaultHeaders; + } + + get defaultHeaders() { + return this._defaultHeaders; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: string) { + this.authentications.api_key.username = key; + } + + set username(username: string) { + this.authentications.api_key.username = username; + } + + set password(password: string) { + this.authentications.api_key.password = password; + } + + set accessToken(accessToken: string | (() => string)) { + this.authentications.oauth2.accessToken = accessToken; + } + + public addInterceptor(interceptor: Interceptor) { + this.interceptors.push(interceptor); + } + + /** + * Grants a user access to the specified Fax Line. + * @summary Add Fax Line User + * @param faxLineAddUserRequest + * @param options + */ + public async faxLineAddUser( + faxLineAddUserRequest: FaxLineAddUserRequest, + options: optionsI = { headers: {} } + ): Promise> { + if ( + faxLineAddUserRequest !== null && + faxLineAddUserRequest !== undefined && + faxLineAddUserRequest.constructor.name !== "FaxLineAddUserRequest" + ) { + faxLineAddUserRequest = ObjectSerializer.deserialize( + faxLineAddUserRequest, + "FaxLineAddUserRequest" + ); + } + + const localVarPath = this.basePath + "/fax_line/add_user"; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + // verify required parameter 'faxLineAddUserRequest' is not null or undefined + if (faxLineAddUserRequest === null || faxLineAddUserRequest === undefined) { + throw new Error( + "Required parameter faxLineAddUserRequest was null or undefined when calling faxLineAddUser." + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + const result = generateFormData( + faxLineAddUserRequest, + FaxLineAddUserRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + + let data = {}; + if (localVarUseFormData) { + const formData = toFormData(result.data); + data = formData; + localVarHeaderParams = { + ...localVarHeaderParams, + ...formData.getHeaders(), + }; + } else { + data = ObjectSerializer.serialize( + faxLineAddUserRequest, + "FaxLineAddUserRequest" + ); + } + + let localVarRequestOptions: AxiosRequestConfig = { + method: "POST", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data, + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise>((resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + }); + }); + } + /** + * Returns a response with the area codes available for a given state/provice and city. + * @summary Get Available Fax Line Area Codes + * @param country Filter area codes by country. + * @param state Filter area codes by state. + * @param province Filter area codes by province. + * @param city Filter area codes by city. + * @param options + */ + public async faxLineAreaCodeGet( + country: FaxLineAreaCodeGetCountryEnum, + state?: FaxLineAreaCodeGetStateEnum, + province?: FaxLineAreaCodeGetProvinceEnum, + city?: string, + options: optionsI = { headers: {} } + ): Promise> { + const localVarPath = this.basePath + "/fax_line/area_codes"; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + // verify required parameter 'country' is not null or undefined + if (country === null || country === undefined) { + throw new Error( + "Required parameter country was null or undefined when calling faxLineAreaCodeGet." + ); + } + + if (country !== undefined) { + localVarQueryParameters["country"] = ObjectSerializer.serialize( + country, + "FaxLineAreaCodeGetCountryEnum" + ); + } + + if (state !== undefined) { + localVarQueryParameters["state"] = ObjectSerializer.serialize( + state, + "FaxLineAreaCodeGetStateEnum" + ); + } + + if (province !== undefined) { + localVarQueryParameters["province"] = ObjectSerializer.serialize( + province, + "FaxLineAreaCodeGetProvinceEnum" + ); + } + + if (city !== undefined) { + localVarQueryParameters["city"] = ObjectSerializer.serialize( + city, + "string" + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + let localVarRequestOptions: AxiosRequestConfig = { + method: "GET", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise>( + (resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + body = ObjectSerializer.deserialize( + body, + "FaxLineAreaCodeGetResponse" + ); + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineAreaCodeGetResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + } + ); + }); + } + /** + * Purchases a new Fax Line. + * @summary Purchase Fax Line + * @param faxLineCreateRequest + * @param options + */ + public async faxLineCreate( + faxLineCreateRequest: FaxLineCreateRequest, + options: optionsI = { headers: {} } + ): Promise> { + if ( + faxLineCreateRequest !== null && + faxLineCreateRequest !== undefined && + faxLineCreateRequest.constructor.name !== "FaxLineCreateRequest" + ) { + faxLineCreateRequest = ObjectSerializer.deserialize( + faxLineCreateRequest, + "FaxLineCreateRequest" + ); + } + + const localVarPath = this.basePath + "/fax_line/create"; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + // verify required parameter 'faxLineCreateRequest' is not null or undefined + if (faxLineCreateRequest === null || faxLineCreateRequest === undefined) { + throw new Error( + "Required parameter faxLineCreateRequest was null or undefined when calling faxLineCreate." + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + const result = generateFormData( + faxLineCreateRequest, + FaxLineCreateRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + + let data = {}; + if (localVarUseFormData) { + const formData = toFormData(result.data); + data = formData; + localVarHeaderParams = { + ...localVarHeaderParams, + ...formData.getHeaders(), + }; + } else { + data = ObjectSerializer.serialize( + faxLineCreateRequest, + "FaxLineCreateRequest" + ); + } + + let localVarRequestOptions: AxiosRequestConfig = { + method: "POST", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data, + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise>((resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + }); + }); + } + /** + * Deletes the specified Fax Line from the subscription. + * @summary Delete Fax Line + * @param faxLineDeleteRequest + * @param options + */ + public async faxLineDelete( + faxLineDeleteRequest: FaxLineDeleteRequest, + options: optionsI = { headers: {} } + ): Promise { + if ( + faxLineDeleteRequest !== null && + faxLineDeleteRequest !== undefined && + faxLineDeleteRequest.constructor.name !== "FaxLineDeleteRequest" + ) { + faxLineDeleteRequest = ObjectSerializer.deserialize( + faxLineDeleteRequest, + "FaxLineDeleteRequest" + ); + } + + const localVarPath = this.basePath + "/fax_line/delete"; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + // verify required parameter 'faxLineDeleteRequest' is not null or undefined + if (faxLineDeleteRequest === null || faxLineDeleteRequest === undefined) { + throw new Error( + "Required parameter faxLineDeleteRequest was null or undefined when calling faxLineDelete." + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + const result = generateFormData( + faxLineDeleteRequest, + FaxLineDeleteRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + + let data = {}; + if (localVarUseFormData) { + const formData = toFormData(result.data); + data = formData; + localVarHeaderParams = { + ...localVarHeaderParams, + ...formData.getHeaders(), + }; + } else { + data = ObjectSerializer.serialize( + faxLineDeleteRequest, + "FaxLineDeleteRequest" + ); + } + + let localVarRequestOptions: AxiosRequestConfig = { + method: "DELETE", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data, + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise((resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + }); + }); + } + /** + * Returns the properties and settings of a Fax Line. + * @summary Get Fax Line + * @param number The Fax Line number. + * @param options + */ + public async faxLineGet( + number: string, + options: optionsI = { headers: {} } + ): Promise> { + const localVarPath = + this.basePath + + "/fax_line/{number}".replace( + "{" + "number" + "}", + encodeURIComponent(String(number)) + ); + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + // verify required parameter 'number' is not null or undefined + if (number === null || number === undefined) { + throw new Error( + "Required parameter number was null or undefined when calling faxLineGet." + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + let localVarRequestOptions: AxiosRequestConfig = { + method: "GET", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise>((resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + }); + }); + } + /** + * Returns the properties and settings of multiple Fax Lines. + * @summary List Fax Lines + * @param accountId Account ID + * @param page Page + * @param pageSize Page size + * @param showTeamLines Show team lines + * @param options + */ + public async faxLineList( + accountId?: string, + page?: number, + pageSize?: number, + showTeamLines?: boolean, + options: optionsI = { headers: {} } + ): Promise> { + const localVarPath = this.basePath + "/fax_line/list"; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + if (accountId !== undefined) { + localVarQueryParameters["account_id"] = ObjectSerializer.serialize( + accountId, + "string" + ); + } + + if (page !== undefined) { + localVarQueryParameters["page"] = ObjectSerializer.serialize( + page, + "number" + ); + } + + if (pageSize !== undefined) { + localVarQueryParameters["page_size"] = ObjectSerializer.serialize( + pageSize, + "number" + ); + } + + if (showTeamLines !== undefined) { + localVarQueryParameters["show_team_lines"] = ObjectSerializer.serialize( + showTeamLines, + "boolean" + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + let localVarRequestOptions: AxiosRequestConfig = { + method: "GET", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise>( + (resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + body = ObjectSerializer.deserialize( + body, + "FaxLineListResponse" + ); + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineListResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + } + ); + }); + } + /** + * Removes a user\'s access to the specified Fax Line. + * @summary Remove Fax Line Access + * @param faxLineRemoveUserRequest + * @param options + */ + public async faxLineRemoveUser( + faxLineRemoveUserRequest: FaxLineRemoveUserRequest, + options: optionsI = { headers: {} } + ): Promise> { + if ( + faxLineRemoveUserRequest !== null && + faxLineRemoveUserRequest !== undefined && + faxLineRemoveUserRequest.constructor.name !== "FaxLineRemoveUserRequest" + ) { + faxLineRemoveUserRequest = ObjectSerializer.deserialize( + faxLineRemoveUserRequest, + "FaxLineRemoveUserRequest" + ); + } + + const localVarPath = this.basePath + "/fax_line/remove_user"; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + // give precedence to 'application/json' + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams: any = {}; + let localVarBodyParams: any = undefined; + + // verify required parameter 'faxLineRemoveUserRequest' is not null or undefined + if ( + faxLineRemoveUserRequest === null || + faxLineRemoveUserRequest === undefined + ) { + throw new Error( + "Required parameter faxLineRemoveUserRequest was null or undefined when calling faxLineRemoveUser." + ); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + const result = generateFormData( + faxLineRemoveUserRequest, + FaxLineRemoveUserRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + + let data = {}; + if (localVarUseFormData) { + const formData = toFormData(result.data); + data = formData; + localVarHeaderParams = { + ...localVarHeaderParams, + ...formData.getHeaders(), + }; + } else { + data = ObjectSerializer.serialize( + faxLineRemoveUserRequest, + "FaxLineRemoveUserRequest" + ); + } + + let localVarRequestOptions: AxiosRequestConfig = { + method: "POST", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring + ? queryParamsSerializer + : undefined, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data, + }; + + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then(() => + this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then(() => + this.authentications.default.applyToRequest(localVarRequestOptions) + ); + + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then(() => + interceptor(localVarRequestOptions) + ); + } + + return interceptorPromise.then(() => { + return new Promise>((resolve, reject) => { + axios.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + + if ( + response.status && + response.status >= 200 && + response.status <= 299 + ) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response: response, body: body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error: AxiosError) => { + if (error.response == null) { + reject(error); + return; + } + + const response = error.response; + + let body; + + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if ( + response.status >= rangeCodeLeft && + response.status <= rangeCodeRight + ) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + + reject(new HttpError(response, body, response.status)); + return; + } + + reject(error); + } + ); + }); + }); + } +} diff --git a/sdks/node/api/index.ts b/sdks/node/api/index.ts index fa778faf6..35c0b5b66 100644 --- a/sdks/node/api/index.ts +++ b/sdks/node/api/index.ts @@ -2,6 +2,7 @@ import { AccountApi } from "./accountApi"; import { ApiAppApi } from "./apiAppApi"; import { BulkSendJobApi } from "./bulkSendJobApi"; import { EmbeddedApi } from "./embeddedApi"; +import { FaxLineApi } from "./faxLineApi"; import { OAuthApi } from "./oAuthApi"; import { ReportApi } from "./reportApi"; import { SignatureRequestApi } from "./signatureRequestApi"; @@ -14,6 +15,7 @@ export { ApiAppApi, BulkSendJobApi, EmbeddedApi, + FaxLineApi, OAuthApi, ReportApi, SignatureRequestApi, @@ -38,6 +40,7 @@ export const APIS = [ ApiAppApi, BulkSendJobApi, EmbeddedApi, + FaxLineApi, OAuthApi, ReportApi, SignatureRequestApi, diff --git a/sdks/node/dist/api.js b/sdks/node/dist/api.js index a55935245..58428135e 100644 --- a/sdks/node/dist/api.js +++ b/sdks/node/dist/api.js @@ -12973,6 +12973,17 @@ __export(api_exports, { EventCallbackRequest: () => EventCallbackRequest, EventCallbackRequestEvent: () => EventCallbackRequestEvent, EventCallbackRequestEventMetadata: () => EventCallbackRequestEventMetadata, + FaxLineAddUserRequest: () => FaxLineAddUserRequest, + FaxLineApi: () => FaxLineApi, + FaxLineAreaCodeGetCountryEnum: () => FaxLineAreaCodeGetCountryEnum, + FaxLineAreaCodeGetProvinceEnum: () => FaxLineAreaCodeGetProvinceEnum, + FaxLineAreaCodeGetResponse: () => FaxLineAreaCodeGetResponse, + FaxLineAreaCodeGetStateEnum: () => FaxLineAreaCodeGetStateEnum, + FaxLineCreateRequest: () => FaxLineCreateRequest, + FaxLineDeleteRequest: () => FaxLineDeleteRequest, + FaxLineListResponse: () => FaxLineListResponse, + FaxLineRemoveUserRequest: () => FaxLineRemoveUserRequest, + FaxLineResponse: () => FaxLineResponse, FileResponse: () => FileResponse, FileResponseDataUri: () => FileResponseDataUri, HttpBasicAuth: () => HttpBasicAuth, @@ -17652,6 +17663,271 @@ EventCallbackRequestEventMetadata.attributeTypeMap = [ } ]; +// model/faxLineAddUserRequest.ts +var _FaxLineAddUserRequest = class { + static getAttributeTypeMap() { + return _FaxLineAddUserRequest.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineAddUserRequest"); + } +}; +var FaxLineAddUserRequest = _FaxLineAddUserRequest; +FaxLineAddUserRequest.discriminator = void 0; +FaxLineAddUserRequest.attributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string" + }, + { + name: "accountId", + baseName: "account_id", + type: "string" + }, + { + name: "emailAddress", + baseName: "email_address", + type: "string" + } +]; + +// model/faxLineAreaCodeGetCountryEnum.ts +var FaxLineAreaCodeGetCountryEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetCountryEnum3) => { + FaxLineAreaCodeGetCountryEnum3["Ca"] = "CA"; + FaxLineAreaCodeGetCountryEnum3["Us"] = "US"; + FaxLineAreaCodeGetCountryEnum3["Uk"] = "UK"; + return FaxLineAreaCodeGetCountryEnum3; +})(FaxLineAreaCodeGetCountryEnum || {}); + +// model/faxLineAreaCodeGetProvinceEnum.ts +var FaxLineAreaCodeGetProvinceEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetProvinceEnum3) => { + FaxLineAreaCodeGetProvinceEnum3["Ab"] = "AB"; + FaxLineAreaCodeGetProvinceEnum3["Bc"] = "BC"; + FaxLineAreaCodeGetProvinceEnum3["Mb"] = "MB"; + FaxLineAreaCodeGetProvinceEnum3["Nb"] = "NB"; + FaxLineAreaCodeGetProvinceEnum3["Nl"] = "NL"; + FaxLineAreaCodeGetProvinceEnum3["Nt"] = "NT"; + FaxLineAreaCodeGetProvinceEnum3["Ns"] = "NS"; + FaxLineAreaCodeGetProvinceEnum3["Nu"] = "NU"; + FaxLineAreaCodeGetProvinceEnum3["On"] = "ON"; + FaxLineAreaCodeGetProvinceEnum3["Pe"] = "PE"; + FaxLineAreaCodeGetProvinceEnum3["Qc"] = "QC"; + FaxLineAreaCodeGetProvinceEnum3["Sk"] = "SK"; + FaxLineAreaCodeGetProvinceEnum3["Yt"] = "YT"; + return FaxLineAreaCodeGetProvinceEnum3; +})(FaxLineAreaCodeGetProvinceEnum || {}); + +// model/faxLineAreaCodeGetResponse.ts +var _FaxLineAreaCodeGetResponse = class { + static getAttributeTypeMap() { + return _FaxLineAreaCodeGetResponse.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineAreaCodeGetResponse"); + } +}; +var FaxLineAreaCodeGetResponse = _FaxLineAreaCodeGetResponse; +FaxLineAreaCodeGetResponse.discriminator = void 0; +FaxLineAreaCodeGetResponse.attributeTypeMap = [ + { + name: "areaCodes", + baseName: "area_codes", + type: "Array" + } +]; + +// model/faxLineAreaCodeGetStateEnum.ts +var FaxLineAreaCodeGetStateEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetStateEnum3) => { + FaxLineAreaCodeGetStateEnum3["Ak"] = "AK"; + FaxLineAreaCodeGetStateEnum3["Al"] = "AL"; + FaxLineAreaCodeGetStateEnum3["Ar"] = "AR"; + FaxLineAreaCodeGetStateEnum3["Az"] = "AZ"; + FaxLineAreaCodeGetStateEnum3["Ca"] = "CA"; + FaxLineAreaCodeGetStateEnum3["Co"] = "CO"; + FaxLineAreaCodeGetStateEnum3["Ct"] = "CT"; + FaxLineAreaCodeGetStateEnum3["Dc"] = "DC"; + FaxLineAreaCodeGetStateEnum3["De"] = "DE"; + FaxLineAreaCodeGetStateEnum3["Fl"] = "FL"; + FaxLineAreaCodeGetStateEnum3["Ga"] = "GA"; + FaxLineAreaCodeGetStateEnum3["Hi"] = "HI"; + FaxLineAreaCodeGetStateEnum3["Ia"] = "IA"; + FaxLineAreaCodeGetStateEnum3["Id"] = "ID"; + FaxLineAreaCodeGetStateEnum3["Il"] = "IL"; + FaxLineAreaCodeGetStateEnum3["In"] = "IN"; + FaxLineAreaCodeGetStateEnum3["Ks"] = "KS"; + FaxLineAreaCodeGetStateEnum3["Ky"] = "KY"; + FaxLineAreaCodeGetStateEnum3["La"] = "LA"; + FaxLineAreaCodeGetStateEnum3["Ma"] = "MA"; + FaxLineAreaCodeGetStateEnum3["Md"] = "MD"; + FaxLineAreaCodeGetStateEnum3["Me"] = "ME"; + FaxLineAreaCodeGetStateEnum3["Mi"] = "MI"; + FaxLineAreaCodeGetStateEnum3["Mn"] = "MN"; + FaxLineAreaCodeGetStateEnum3["Mo"] = "MO"; + FaxLineAreaCodeGetStateEnum3["Ms"] = "MS"; + FaxLineAreaCodeGetStateEnum3["Mt"] = "MT"; + FaxLineAreaCodeGetStateEnum3["Nc"] = "NC"; + FaxLineAreaCodeGetStateEnum3["Nd"] = "ND"; + FaxLineAreaCodeGetStateEnum3["Ne"] = "NE"; + FaxLineAreaCodeGetStateEnum3["Nh"] = "NH"; + FaxLineAreaCodeGetStateEnum3["Nj"] = "NJ"; + FaxLineAreaCodeGetStateEnum3["Nm"] = "NM"; + FaxLineAreaCodeGetStateEnum3["Nv"] = "NV"; + FaxLineAreaCodeGetStateEnum3["Ny"] = "NY"; + FaxLineAreaCodeGetStateEnum3["Oh"] = "OH"; + FaxLineAreaCodeGetStateEnum3["Ok"] = "OK"; + FaxLineAreaCodeGetStateEnum3["Or"] = "OR"; + FaxLineAreaCodeGetStateEnum3["Pa"] = "PA"; + FaxLineAreaCodeGetStateEnum3["Ri"] = "RI"; + FaxLineAreaCodeGetStateEnum3["Sc"] = "SC"; + FaxLineAreaCodeGetStateEnum3["Sd"] = "SD"; + FaxLineAreaCodeGetStateEnum3["Tn"] = "TN"; + FaxLineAreaCodeGetStateEnum3["Tx"] = "TX"; + FaxLineAreaCodeGetStateEnum3["Ut"] = "UT"; + FaxLineAreaCodeGetStateEnum3["Va"] = "VA"; + FaxLineAreaCodeGetStateEnum3["Vt"] = "VT"; + FaxLineAreaCodeGetStateEnum3["Wa"] = "WA"; + FaxLineAreaCodeGetStateEnum3["Wi"] = "WI"; + FaxLineAreaCodeGetStateEnum3["Wv"] = "WV"; + FaxLineAreaCodeGetStateEnum3["Wy"] = "WY"; + return FaxLineAreaCodeGetStateEnum3; +})(FaxLineAreaCodeGetStateEnum || {}); + +// model/faxLineCreateRequest.ts +var _FaxLineCreateRequest = class { + static getAttributeTypeMap() { + return _FaxLineCreateRequest.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineCreateRequest"); + } +}; +var FaxLineCreateRequest = _FaxLineCreateRequest; +FaxLineCreateRequest.discriminator = void 0; +FaxLineCreateRequest.attributeTypeMap = [ + { + name: "areaCode", + baseName: "area_code", + type: "string" + }, + { + name: "country", + baseName: "country", + type: "FaxLineAreaCodeGetCountryEnum" + }, + { + name: "city", + baseName: "city", + type: "string" + }, + { + name: "accountId", + baseName: "account_id", + type: "string" + } +]; + +// model/faxLineDeleteRequest.ts +var _FaxLineDeleteRequest = class { + static getAttributeTypeMap() { + return _FaxLineDeleteRequest.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineDeleteRequest"); + } +}; +var FaxLineDeleteRequest = _FaxLineDeleteRequest; +FaxLineDeleteRequest.discriminator = void 0; +FaxLineDeleteRequest.attributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string" + } +]; + +// model/faxLineListResponse.ts +var _FaxLineListResponse = class { + static getAttributeTypeMap() { + return _FaxLineListResponse.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineListResponse"); + } +}; +var FaxLineListResponse = _FaxLineListResponse; +FaxLineListResponse.discriminator = void 0; +FaxLineListResponse.attributeTypeMap = [ + { + name: "listInfo", + baseName: "list_info", + type: "ListInfoResponse" + }, + { + name: "faxLines", + baseName: "fax_lines", + type: "Array" + }, + { + name: "warnings", + baseName: "warnings", + type: "WarningResponse" + } +]; + +// model/faxLineRemoveUserRequest.ts +var _FaxLineRemoveUserRequest = class { + static getAttributeTypeMap() { + return _FaxLineRemoveUserRequest.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineRemoveUserRequest"); + } +}; +var FaxLineRemoveUserRequest = _FaxLineRemoveUserRequest; +FaxLineRemoveUserRequest.discriminator = void 0; +FaxLineRemoveUserRequest.attributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string" + }, + { + name: "accountId", + baseName: "account_id", + type: "string" + }, + { + name: "emailAddress", + baseName: "email_address", + type: "string" + } +]; + +// model/faxLineResponse.ts +var _FaxLineResponse = class { + static getAttributeTypeMap() { + return _FaxLineResponse.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineResponse"); + } +}; +var FaxLineResponse = _FaxLineResponse; +FaxLineResponse.discriminator = void 0; +FaxLineResponse.attributeTypeMap = [ + { + name: "faxLine", + baseName: "fax_line", + type: "FaxLineResponse" + }, + { + name: "warnings", + baseName: "warnings", + type: "WarningResponse" + } +]; + // model/fileResponse.ts var _FileResponse = class { static getAttributeTypeMap() { @@ -24082,6 +24358,9 @@ var VoidAuth = class { // model/index.ts var enumsMap = { "EventCallbackRequestEvent.EventTypeEnum": EventCallbackRequestEvent.EventTypeEnum, + FaxLineAreaCodeGetCountryEnum, + FaxLineAreaCodeGetProvinceEnum, + FaxLineAreaCodeGetStateEnum, "ReportCreateRequest.ReportTypeEnum": ReportCreateRequest.ReportTypeEnum, "ReportResponse.ReportTypeEnum": ReportResponse.ReportTypeEnum, SignatureRequestResponseCustomFieldTypeEnum, @@ -24144,6 +24423,13 @@ var typeMap = { EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, + FaxLineAddUserRequest, + FaxLineAreaCodeGetResponse, + FaxLineCreateRequest, + FaxLineDeleteRequest, + FaxLineListResponse, + FaxLineRemoveUserRequest, + FaxLineResponse, FileResponse, FileResponseDataUri, ListInfoResponse, @@ -25977,9 +26263,9 @@ var EmbeddedApi = class { } }; -// api/oAuthApi.ts -var defaultBasePath5 = "https://app.hellosign.com"; -var OAuthApi = class { +// api/faxLineApi.ts +var defaultBasePath5 = "https://api.hellosign.com/v3"; +var FaxLineApi = class { constructor(basePath) { this._basePath = defaultBasePath5; this._defaultHeaders = { @@ -26029,15 +26315,15 @@ var OAuthApi = class { addInterceptor(interceptor) { this.interceptors.push(interceptor); } - oauthTokenGenerate(_0) { - return __async(this, arguments, function* (oAuthTokenGenerateRequest, options = { headers: {} }) { - if (oAuthTokenGenerateRequest !== null && oAuthTokenGenerateRequest !== void 0 && oAuthTokenGenerateRequest.constructor.name !== "OAuthTokenGenerateRequest") { - oAuthTokenGenerateRequest = ObjectSerializer.deserialize( - oAuthTokenGenerateRequest, - "OAuthTokenGenerateRequest" + faxLineAddUser(_0) { + return __async(this, arguments, function* (faxLineAddUserRequest, options = { headers: {} }) { + if (faxLineAddUserRequest !== null && faxLineAddUserRequest !== void 0 && faxLineAddUserRequest.constructor.name !== "FaxLineAddUserRequest") { + faxLineAddUserRequest = ObjectSerializer.deserialize( + faxLineAddUserRequest, + "FaxLineAddUserRequest" ); } - const localVarPath = this.basePath + "/oauth/token"; + const localVarPath = this.basePath + "/fax_line/add_user"; let localVarQueryParameters = {}; let localVarHeaderParams = Object.assign( {}, @@ -26051,16 +26337,16 @@ var OAuthApi = class { } let localVarFormParams = {}; let localVarBodyParams = void 0; - if (oAuthTokenGenerateRequest === null || oAuthTokenGenerateRequest === void 0) { + if (faxLineAddUserRequest === null || faxLineAddUserRequest === void 0) { throw new Error( - "Required parameter oAuthTokenGenerateRequest was null or undefined when calling oauthTokenGenerate." + "Required parameter faxLineAddUserRequest was null or undefined when calling faxLineAddUser." ); } Object.assign(localVarHeaderParams, options.headers); let localVarUseFormData = false; const result = generateFormData( - oAuthTokenGenerateRequest, - OAuthTokenGenerateRequest.attributeTypeMap + faxLineAddUserRequest, + FaxLineAddUserRequest.attributeTypeMap ); localVarUseFormData = result.localVarUseFormData; let data = {}; @@ -26070,8 +26356,8 @@ var OAuthApi = class { localVarHeaderParams = __spreadValues(__spreadValues({}, localVarHeaderParams), formData2.getHeaders()); } else { data = ObjectSerializer.serialize( - oAuthTokenGenerateRequest, - "OAuthTokenGenerateRequest" + faxLineAddUserRequest, + "FaxLineAddUserRequest" ); } let localVarRequestOptions = { @@ -26086,6 +26372,11 @@ var OAuthApi = class { data }; let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } authenticationPromise = authenticationPromise.then( () => this.authentications.default.applyToRequest(localVarRequestOptions) ); @@ -26101,7 +26392,7 @@ var OAuthApi = class { (response) => { let body = response.data; if (response.status && response.status >= 200 && response.status <= 299) { - body = ObjectSerializer.deserialize(body, "OAuthTokenResponse"); + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); resolve({ response, body }); } else { reject(new HttpError(response, body, response.status)); @@ -26117,7 +26408,17 @@ var OAuthApi = class { if (response.status === 200) { body = ObjectSerializer.deserialize( response.data, - "OAuthTokenResponse" + "FaxLineResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" ); reject(new HttpError(response, body, response.status)); return; @@ -26129,15 +26430,136 @@ var OAuthApi = class { }); }); } - oauthTokenRefresh(_0) { - return __async(this, arguments, function* (oAuthTokenRefreshRequest, options = { headers: {} }) { - if (oAuthTokenRefreshRequest !== null && oAuthTokenRefreshRequest !== void 0 && oAuthTokenRefreshRequest.constructor.name !== "OAuthTokenRefreshRequest") { - oAuthTokenRefreshRequest = ObjectSerializer.deserialize( - oAuthTokenRefreshRequest, - "OAuthTokenRefreshRequest" + faxLineAreaCodeGet(_0, _1, _2, _3) { + return __async(this, arguments, function* (country, state, province, city, options = { headers: {} }) { + const localVarPath = this.basePath + "/fax_line/area_codes"; + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (country === null || country === void 0) { + throw new Error( + "Required parameter country was null or undefined when calling faxLineAreaCodeGet." ); } - const localVarPath = this.basePath + "/oauth/token?refresh"; + if (country !== void 0) { + localVarQueryParameters["country"] = ObjectSerializer.serialize( + country, + "FaxLineAreaCodeGetCountryEnum" + ); + } + if (state !== void 0) { + localVarQueryParameters["state"] = ObjectSerializer.serialize( + state, + "FaxLineAreaCodeGetStateEnum" + ); + } + if (province !== void 0) { + localVarQueryParameters["province"] = ObjectSerializer.serialize( + province, + "FaxLineAreaCodeGetProvinceEnum" + ); + } + if (city !== void 0) { + localVarQueryParameters["city"] = ObjectSerializer.serialize( + city, + "string" + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + let localVarRequestOptions = { + method: "GET", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json" + }; + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise( + (resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + body = ObjectSerializer.deserialize( + body, + "FaxLineAreaCodeGetResponse" + ); + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineAreaCodeGetResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + } + ); + }); + }); + } + faxLineCreate(_0) { + return __async(this, arguments, function* (faxLineCreateRequest, options = { headers: {} }) { + if (faxLineCreateRequest !== null && faxLineCreateRequest !== void 0 && faxLineCreateRequest.constructor.name !== "FaxLineCreateRequest") { + faxLineCreateRequest = ObjectSerializer.deserialize( + faxLineCreateRequest, + "FaxLineCreateRequest" + ); + } + const localVarPath = this.basePath + "/fax_line/create"; let localVarQueryParameters = {}; let localVarHeaderParams = Object.assign( {}, @@ -26151,16 +26573,16 @@ var OAuthApi = class { } let localVarFormParams = {}; let localVarBodyParams = void 0; - if (oAuthTokenRefreshRequest === null || oAuthTokenRefreshRequest === void 0) { + if (faxLineCreateRequest === null || faxLineCreateRequest === void 0) { throw new Error( - "Required parameter oAuthTokenRefreshRequest was null or undefined when calling oauthTokenRefresh." + "Required parameter faxLineCreateRequest was null or undefined when calling faxLineCreate." ); } Object.assign(localVarHeaderParams, options.headers); let localVarUseFormData = false; const result = generateFormData( - oAuthTokenRefreshRequest, - OAuthTokenRefreshRequest.attributeTypeMap + faxLineCreateRequest, + FaxLineCreateRequest.attributeTypeMap ); localVarUseFormData = result.localVarUseFormData; let data = {}; @@ -26170,8 +26592,8 @@ var OAuthApi = class { localVarHeaderParams = __spreadValues(__spreadValues({}, localVarHeaderParams), formData2.getHeaders()); } else { data = ObjectSerializer.serialize( - oAuthTokenRefreshRequest, - "OAuthTokenRefreshRequest" + faxLineCreateRequest, + "FaxLineCreateRequest" ); } let localVarRequestOptions = { @@ -26186,7 +26608,708 @@ var OAuthApi = class { data }; let authenticationPromise = Promise.resolve(); - authenticationPromise = authenticationPromise.then( + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise((resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + }); + }); + }); + } + faxLineDelete(_0) { + return __async(this, arguments, function* (faxLineDeleteRequest, options = { headers: {} }) { + if (faxLineDeleteRequest !== null && faxLineDeleteRequest !== void 0 && faxLineDeleteRequest.constructor.name !== "FaxLineDeleteRequest") { + faxLineDeleteRequest = ObjectSerializer.deserialize( + faxLineDeleteRequest, + "FaxLineDeleteRequest" + ); + } + const localVarPath = this.basePath + "/fax_line/delete"; + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (faxLineDeleteRequest === null || faxLineDeleteRequest === void 0) { + throw new Error( + "Required parameter faxLineDeleteRequest was null or undefined when calling faxLineDelete." + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + const result = generateFormData( + faxLineDeleteRequest, + FaxLineDeleteRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + let data = {}; + if (localVarUseFormData) { + const formData2 = toFormData3(result.data); + data = formData2; + localVarHeaderParams = __spreadValues(__spreadValues({}, localVarHeaderParams), formData2.getHeaders()); + } else { + data = ObjectSerializer.serialize( + faxLineDeleteRequest, + "FaxLineDeleteRequest" + ); + } + let localVarRequestOptions = { + method: "DELETE", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data + }; + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise((resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + }); + }); + }); + } + faxLineGet(_0) { + return __async(this, arguments, function* (number, options = { headers: {} }) { + const localVarPath = this.basePath + "/fax_line/{number}".replace( + "{number}", + encodeURIComponent(String(number)) + ); + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (number === null || number === void 0) { + throw new Error( + "Required parameter number was null or undefined when calling faxLineGet." + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + let localVarRequestOptions = { + method: "GET", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json" + }; + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise((resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + }); + }); + }); + } + faxLineList(_0, _1, _2, _3) { + return __async(this, arguments, function* (accountId, page, pageSize, showTeamLines, options = { headers: {} }) { + const localVarPath = this.basePath + "/fax_line/list"; + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (accountId !== void 0) { + localVarQueryParameters["account_id"] = ObjectSerializer.serialize( + accountId, + "string" + ); + } + if (page !== void 0) { + localVarQueryParameters["page"] = ObjectSerializer.serialize( + page, + "number" + ); + } + if (pageSize !== void 0) { + localVarQueryParameters["page_size"] = ObjectSerializer.serialize( + pageSize, + "number" + ); + } + if (showTeamLines !== void 0) { + localVarQueryParameters["show_team_lines"] = ObjectSerializer.serialize( + showTeamLines, + "boolean" + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + let localVarRequestOptions = { + method: "GET", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json" + }; + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise( + (resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + body = ObjectSerializer.deserialize( + body, + "FaxLineListResponse" + ); + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineListResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + } + ); + }); + }); + } + faxLineRemoveUser(_0) { + return __async(this, arguments, function* (faxLineRemoveUserRequest, options = { headers: {} }) { + if (faxLineRemoveUserRequest !== null && faxLineRemoveUserRequest !== void 0 && faxLineRemoveUserRequest.constructor.name !== "FaxLineRemoveUserRequest") { + faxLineRemoveUserRequest = ObjectSerializer.deserialize( + faxLineRemoveUserRequest, + "FaxLineRemoveUserRequest" + ); + } + const localVarPath = this.basePath + "/fax_line/remove_user"; + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (faxLineRemoveUserRequest === null || faxLineRemoveUserRequest === void 0) { + throw new Error( + "Required parameter faxLineRemoveUserRequest was null or undefined when calling faxLineRemoveUser." + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + const result = generateFormData( + faxLineRemoveUserRequest, + FaxLineRemoveUserRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + let data = {}; + if (localVarUseFormData) { + const formData2 = toFormData3(result.data); + data = formData2; + localVarHeaderParams = __spreadValues(__spreadValues({}, localVarHeaderParams), formData2.getHeaders()); + } else { + data = ObjectSerializer.serialize( + faxLineRemoveUserRequest, + "FaxLineRemoveUserRequest" + ); + } + let localVarRequestOptions = { + method: "POST", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data + }; + let authenticationPromise = Promise.resolve(); + if (this.authentications.api_key.username) { + authenticationPromise = authenticationPromise.then( + () => this.authentications.api_key.applyToRequest(localVarRequestOptions) + ); + } + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise((resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + body = ObjectSerializer.deserialize(body, "FaxLineResponse"); + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "FaxLineResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + let rangeCodeLeft = Number("4XX"[0] + "00"); + let rangeCodeRight = Number("4XX"[0] + "99"); + if (response.status >= rangeCodeLeft && response.status <= rangeCodeRight) { + body = ObjectSerializer.deserialize( + response.data, + "ErrorResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + }); + }); + }); + } +}; + +// api/oAuthApi.ts +var defaultBasePath6 = "https://app.hellosign.com"; +var OAuthApi = class { + constructor(basePath) { + this._basePath = defaultBasePath6; + this._defaultHeaders = { + "User-Agent": USER_AGENT + }; + this._useQuerystring = false; + this.authentications = { + default: new VoidAuth(), + api_key: new HttpBasicAuth(), + oauth2: new HttpBearerAuth() + }; + this.interceptors = []; + if (basePath) { + this.basePath = basePath; + } + } + set useQuerystring(value) { + this._useQuerystring = value; + } + set basePath(basePath) { + this._basePath = basePath; + } + set defaultHeaders(defaultHeaders) { + this._defaultHeaders = defaultHeaders; + } + get defaultHeaders() { + return this._defaultHeaders; + } + get basePath() { + return this._basePath; + } + setDefaultAuthentication(auth) { + this.authentications.default = auth; + } + setApiKey(key) { + this.authentications.api_key.username = key; + } + set username(username) { + this.authentications.api_key.username = username; + } + set password(password) { + this.authentications.api_key.password = password; + } + set accessToken(accessToken) { + this.authentications.oauth2.accessToken = accessToken; + } + addInterceptor(interceptor) { + this.interceptors.push(interceptor); + } + oauthTokenGenerate(_0) { + return __async(this, arguments, function* (oAuthTokenGenerateRequest, options = { headers: {} }) { + if (oAuthTokenGenerateRequest !== null && oAuthTokenGenerateRequest !== void 0 && oAuthTokenGenerateRequest.constructor.name !== "OAuthTokenGenerateRequest") { + oAuthTokenGenerateRequest = ObjectSerializer.deserialize( + oAuthTokenGenerateRequest, + "OAuthTokenGenerateRequest" + ); + } + const localVarPath = this.basePath + "/oauth/token"; + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (oAuthTokenGenerateRequest === null || oAuthTokenGenerateRequest === void 0) { + throw new Error( + "Required parameter oAuthTokenGenerateRequest was null or undefined when calling oauthTokenGenerate." + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + const result = generateFormData( + oAuthTokenGenerateRequest, + OAuthTokenGenerateRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + let data = {}; + if (localVarUseFormData) { + const formData2 = toFormData3(result.data); + data = formData2; + localVarHeaderParams = __spreadValues(__spreadValues({}, localVarHeaderParams), formData2.getHeaders()); + } else { + data = ObjectSerializer.serialize( + oAuthTokenGenerateRequest, + "OAuthTokenGenerateRequest" + ); + } + let localVarRequestOptions = { + method: "POST", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data + }; + let authenticationPromise = Promise.resolve(); + authenticationPromise = authenticationPromise.then( + () => this.authentications.default.applyToRequest(localVarRequestOptions) + ); + let interceptorPromise = authenticationPromise; + for (const interceptor of this.interceptors) { + interceptorPromise = interceptorPromise.then( + () => interceptor(localVarRequestOptions) + ); + } + return interceptorPromise.then(() => { + return new Promise((resolve, reject) => { + axios_default.request(localVarRequestOptions).then( + (response) => { + let body = response.data; + if (response.status && response.status >= 200 && response.status <= 299) { + body = ObjectSerializer.deserialize(body, "OAuthTokenResponse"); + resolve({ response, body }); + } else { + reject(new HttpError(response, body, response.status)); + } + }, + (error) => { + if (error.response == null) { + reject(error); + return; + } + const response = error.response; + let body; + if (response.status === 200) { + body = ObjectSerializer.deserialize( + response.data, + "OAuthTokenResponse" + ); + reject(new HttpError(response, body, response.status)); + return; + } + reject(error); + } + ); + }); + }); + }); + } + oauthTokenRefresh(_0) { + return __async(this, arguments, function* (oAuthTokenRefreshRequest, options = { headers: {} }) { + if (oAuthTokenRefreshRequest !== null && oAuthTokenRefreshRequest !== void 0 && oAuthTokenRefreshRequest.constructor.name !== "OAuthTokenRefreshRequest") { + oAuthTokenRefreshRequest = ObjectSerializer.deserialize( + oAuthTokenRefreshRequest, + "OAuthTokenRefreshRequest" + ); + } + const localVarPath = this.basePath + "/oauth/token?refresh"; + let localVarQueryParameters = {}; + let localVarHeaderParams = Object.assign( + {}, + this._defaultHeaders + ); + const produces = ["application/json"]; + if (produces.indexOf("application/json") >= 0) { + localVarHeaderParams["content-type"] = "application/json"; + } else { + localVarHeaderParams["content-type"] = produces.join(","); + } + let localVarFormParams = {}; + let localVarBodyParams = void 0; + if (oAuthTokenRefreshRequest === null || oAuthTokenRefreshRequest === void 0) { + throw new Error( + "Required parameter oAuthTokenRefreshRequest was null or undefined when calling oauthTokenRefresh." + ); + } + Object.assign(localVarHeaderParams, options.headers); + let localVarUseFormData = false; + const result = generateFormData( + oAuthTokenRefreshRequest, + OAuthTokenRefreshRequest.attributeTypeMap + ); + localVarUseFormData = result.localVarUseFormData; + let data = {}; + if (localVarUseFormData) { + const formData2 = toFormData3(result.data); + data = formData2; + localVarHeaderParams = __spreadValues(__spreadValues({}, localVarHeaderParams), formData2.getHeaders()); + } else { + data = ObjectSerializer.serialize( + oAuthTokenRefreshRequest, + "OAuthTokenRefreshRequest" + ); + } + let localVarRequestOptions = { + method: "POST", + params: localVarQueryParameters, + headers: localVarHeaderParams, + url: localVarPath, + paramsSerializer: this._useQuerystring ? queryParamsSerializer : void 0, + maxContentLength: Infinity, + maxBodyLength: Infinity, + responseType: "json", + data + }; + let authenticationPromise = Promise.resolve(); + authenticationPromise = authenticationPromise.then( () => this.authentications.default.applyToRequest(localVarRequestOptions) ); let interceptorPromise = authenticationPromise; @@ -26232,10 +27355,10 @@ var OAuthApi = class { }; // api/reportApi.ts -var defaultBasePath6 = "https://api.hellosign.com/v3"; +var defaultBasePath7 = "https://api.hellosign.com/v3"; var ReportApi = class { constructor(basePath) { - this._basePath = defaultBasePath6; + this._basePath = defaultBasePath7; this._defaultHeaders = { "User-Agent": USER_AGENT }; @@ -26406,10 +27529,10 @@ var ReportApi = class { }; // api/signatureRequestApi.ts -var defaultBasePath7 = "https://api.hellosign.com/v3"; +var defaultBasePath8 = "https://api.hellosign.com/v3"; var SignatureRequestApi = class { constructor(basePath) { - this._basePath = defaultBasePath7; + this._basePath = defaultBasePath8; this._defaultHeaders = { "User-Agent": USER_AGENT }; @@ -28293,10 +29416,10 @@ var SignatureRequestApi = class { }; // api/teamApi.ts -var defaultBasePath8 = "https://api.hellosign.com/v3"; +var defaultBasePath9 = "https://api.hellosign.com/v3"; var TeamApi = class { constructor(basePath) { - this._basePath = defaultBasePath8; + this._basePath = defaultBasePath9; this._defaultHeaders = { "User-Agent": USER_AGENT }; @@ -29442,10 +30565,10 @@ var TeamApi = class { }; // api/templateApi.ts -var defaultBasePath9 = "https://api.hellosign.com/v3"; +var defaultBasePath10 = "https://api.hellosign.com/v3"; var TemplateApi = class { constructor(basePath) { - this._basePath = defaultBasePath9; + this._basePath = defaultBasePath10; this._defaultHeaders = { "User-Agent": USER_AGENT }; @@ -30776,10 +31899,10 @@ var TemplateApi = class { }; // api/unclaimedDraftApi.ts -var defaultBasePath10 = "https://api.hellosign.com/v3"; +var defaultBasePath11 = "https://api.hellosign.com/v3"; var UnclaimedDraftApi = class { constructor(basePath) { - this._basePath = defaultBasePath10; + this._basePath = defaultBasePath11; this._defaultHeaders = { "User-Agent": USER_AGENT }; @@ -31416,6 +32539,7 @@ var APIS = [ ApiAppApi, BulkSendJobApi, EmbeddedApi, + FaxLineApi, OAuthApi, ReportApi, SignatureRequestApi, @@ -31466,6 +32590,17 @@ var APIS = [ EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, + FaxLineAddUserRequest, + FaxLineApi, + FaxLineAreaCodeGetCountryEnum, + FaxLineAreaCodeGetProvinceEnum, + FaxLineAreaCodeGetResponse, + FaxLineAreaCodeGetStateEnum, + FaxLineCreateRequest, + FaxLineDeleteRequest, + FaxLineListResponse, + FaxLineRemoveUserRequest, + FaxLineResponse, FileResponse, FileResponseDataUri, HttpBasicAuth, diff --git a/sdks/node/docs/api/FaxLineApi.md b/sdks/node/docs/api/FaxLineApi.md new file mode 100644 index 000000000..70db7f60b --- /dev/null +++ b/sdks/node/docs/api/FaxLineApi.md @@ -0,0 +1,335 @@ +# FaxLineApi + +All URIs are relative to https://api.hellosign.com/v3. + +| Method | HTTP request | Description | +| ------------- | ------------- | ------------- | +| [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User | +| [**faxLineAreaCodeGet()**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | +| [**faxLineCreate()**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line | +| [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line | +| [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line | +| [**faxLineList()**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines | +| [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access | + + +## `faxLineAddUser()` + +```typescript +faxLineAddUser(faxLineAddUserRequest: FaxLineAddUserRequest): FaxLineResponse +``` + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **faxLineAddUserRequest** | [**FaxLineAddUserRequest**](../model/FaxLineAddUserRequest.md)| | | + +### Return type + +[**FaxLineResponse**](../model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineAreaCodeGet()` + +```typescript +faxLineAreaCodeGet(country: FaxLineAreaCodeGetCountryEnum, state: FaxLineAreaCodeGetStateEnum, province: FaxLineAreaCodeGetProvinceEnum, city: string): FaxLineAreaCodeGetResponse +``` + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **country** | [**FaxLineAreaCodeGetCountryEnum**](../model/.md)| Filter area codes by country. | | +| **state** | [**FaxLineAreaCodeGetStateEnum**](../model/.md)| Filter area codes by state. | [optional] | +| **province** | [**FaxLineAreaCodeGetProvinceEnum**](../model/.md)| Filter area codes by province. | [optional] | +| **city** | **string**| Filter area codes by city. | [optional] | + +### Return type + +[**FaxLineAreaCodeGetResponse**](../model/FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineCreate()` + +```typescript +faxLineCreate(faxLineCreateRequest: FaxLineCreateRequest): FaxLineResponse +``` + +Purchase Fax Line + +Purchases a new Fax Line. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **faxLineCreateRequest** | [**FaxLineCreateRequest**](../model/FaxLineCreateRequest.md)| | | + +### Return type + +[**FaxLineResponse**](../model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineDelete()` + +```typescript +faxLineDelete(faxLineDeleteRequest: FaxLineDeleteRequest) +``` + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **faxLineDeleteRequest** | [**FaxLineDeleteRequest**](../model/FaxLineDeleteRequest.md)| | | + +### Return type + +void (empty response body) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineGet()` + +```typescript +faxLineGet(number: string): FaxLineResponse +``` + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **number** | **string**| The Fax Line number. | | + +### Return type + +[**FaxLineResponse**](../model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineList()` + +```typescript +faxLineList(accountId: string, page: number, pageSize: number, showTeamLines: boolean): FaxLineListResponse +``` + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **accountId** | **string**| Account ID | [optional] | +| **page** | **number**| Page | [optional] | +| **pageSize** | **number**| Page size | [optional] | +| **showTeamLines** | **boolean**| Show team lines | [optional] | + +### Return type + +[**FaxLineListResponse**](../model/FaxLineListResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineRemoveUser()` + +```typescript +faxLineRemoveUser(faxLineRemoveUserRequest: FaxLineRemoveUserRequest): FaxLineResponse +``` + +Remove Fax Line Access + +Removes a user\'s access to the specified Fax Line. + +### TypeScript Example + +```typescript + +``` + +### JavaScript Example + +```javascript + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **faxLineRemoveUserRequest** | [**FaxLineRemoveUserRequest**](../model/FaxLineRemoveUserRequest.md)| | | + +### Return type + +[**FaxLineResponse**](../model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineAddUserRequest.md b/sdks/node/docs/model/FaxLineAddUserRequest.md new file mode 100644 index 000000000..df23c2cdb --- /dev/null +++ b/sdks/node/docs/model/FaxLineAddUserRequest.md @@ -0,0 +1,13 @@ +# # FaxLineAddUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```string``` | The Fax Line number. | | +| `accountId` | ```string``` | Account ID | | +| `emailAddress` | ```string``` | Email address | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineAreaCodeGetCountryEnum.md b/sdks/node/docs/model/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..91b758d8f --- /dev/null +++ b/sdks/node/docs/model/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,10 @@ +# # FaxLineAreaCodeGetCountryEnum + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineAreaCodeGetProvinceEnum.md b/sdks/node/docs/model/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..369a34359 --- /dev/null +++ b/sdks/node/docs/model/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,10 @@ +# # FaxLineAreaCodeGetProvinceEnum + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md b/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..c348038bc --- /dev/null +++ b/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,11 @@ +# # FaxLineAreaCodeGetResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `areaCodes` | ```Array``` | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineAreaCodeGetStateEnum.md b/sdks/node/docs/model/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..f978b75a2 --- /dev/null +++ b/sdks/node/docs/model/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,10 @@ +# # FaxLineAreaCodeGetStateEnum + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineCreateRequest.md b/sdks/node/docs/model/FaxLineCreateRequest.md new file mode 100644 index 000000000..0df864824 --- /dev/null +++ b/sdks/node/docs/model/FaxLineCreateRequest.md @@ -0,0 +1,14 @@ +# # FaxLineCreateRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `areaCode`*_required_ | ```string``` | Area code | | +| `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `city`*_required_ | ```string``` | City | | +| `accountId` | ```string``` | Account ID | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineDeleteRequest.md b/sdks/node/docs/model/FaxLineDeleteRequest.md new file mode 100644 index 000000000..a2112ed33 --- /dev/null +++ b/sdks/node/docs/model/FaxLineDeleteRequest.md @@ -0,0 +1,11 @@ +# # FaxLineDeleteRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```string``` | The Fax Line number. | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineListResponse.md b/sdks/node/docs/model/FaxLineListResponse.md new file mode 100644 index 000000000..e2841f04e --- /dev/null +++ b/sdks/node/docs/model/FaxLineListResponse.md @@ -0,0 +1,13 @@ +# # FaxLineListResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | +| `faxLines` | [```Array```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineRemoveUserRequest.md b/sdks/node/docs/model/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..e161ecf38 --- /dev/null +++ b/sdks/node/docs/model/FaxLineRemoveUserRequest.md @@ -0,0 +1,13 @@ +# # FaxLineRemoveUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```string``` | The Fax Line number. | | +| `accountId` | ```string``` | Account ID | | +| `emailAddress` | ```string``` | Email address | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineResponse.md b/sdks/node/docs/model/FaxLineResponse.md new file mode 100644 index 000000000..7145365aa --- /dev/null +++ b/sdks/node/docs/model/FaxLineResponse.md @@ -0,0 +1,12 @@ +# # FaxLineResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `faxLine` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/model/faxLineAddUserRequest.ts b/sdks/node/model/faxLineAddUserRequest.ts new file mode 100644 index 000000000..6e297b5a8 --- /dev/null +++ b/sdks/node/model/faxLineAddUserRequest.ts @@ -0,0 +1,69 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export class FaxLineAddUserRequest { + /** + * The Fax Line number. + */ + "number": string; + /** + * Account ID + */ + "accountId"?: string; + /** + * Email address + */ + "emailAddress"?: string; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string", + }, + { + name: "accountId", + baseName: "account_id", + type: "string", + }, + { + name: "emailAddress", + baseName: "email_address", + type: "string", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineAddUserRequest.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineAddUserRequest { + return ObjectSerializer.deserialize(data, "FaxLineAddUserRequest"); + } +} diff --git a/sdks/node/model/faxLineAreaCodeGetCountryEnum.ts b/sdks/node/model/faxLineAreaCodeGetCountryEnum.ts new file mode 100644 index 000000000..abcd32ba3 --- /dev/null +++ b/sdks/node/model/faxLineAreaCodeGetCountryEnum.ts @@ -0,0 +1,31 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export enum FaxLineAreaCodeGetCountryEnum { + Ca = "CA", + Us = "US", + Uk = "UK", +} diff --git a/sdks/node/model/faxLineAreaCodeGetProvinceEnum.ts b/sdks/node/model/faxLineAreaCodeGetProvinceEnum.ts new file mode 100644 index 000000000..4c4ced02b --- /dev/null +++ b/sdks/node/model/faxLineAreaCodeGetProvinceEnum.ts @@ -0,0 +1,41 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export enum FaxLineAreaCodeGetProvinceEnum { + Ab = "AB", + Bc = "BC", + Mb = "MB", + Nb = "NB", + Nl = "NL", + Nt = "NT", + Ns = "NS", + Nu = "NU", + On = "ON", + Pe = "PE", + Qc = "QC", + Sk = "SK", + Yt = "YT", +} diff --git a/sdks/node/model/faxLineAreaCodeGetResponse.ts b/sdks/node/model/faxLineAreaCodeGetResponse.ts new file mode 100644 index 000000000..ffffcc2a1 --- /dev/null +++ b/sdks/node/model/faxLineAreaCodeGetResponse.ts @@ -0,0 +1,48 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export class FaxLineAreaCodeGetResponse { + "areaCodes"?: Array; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "areaCodes", + baseName: "area_codes", + type: "Array", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineAreaCodeGetResponse.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineAreaCodeGetResponse { + return ObjectSerializer.deserialize(data, "FaxLineAreaCodeGetResponse"); + } +} diff --git a/sdks/node/model/faxLineAreaCodeGetStateEnum.ts b/sdks/node/model/faxLineAreaCodeGetStateEnum.ts new file mode 100644 index 000000000..83eb8ead1 --- /dev/null +++ b/sdks/node/model/faxLineAreaCodeGetStateEnum.ts @@ -0,0 +1,79 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export enum FaxLineAreaCodeGetStateEnum { + Ak = "AK", + Al = "AL", + Ar = "AR", + Az = "AZ", + Ca = "CA", + Co = "CO", + Ct = "CT", + Dc = "DC", + De = "DE", + Fl = "FL", + Ga = "GA", + Hi = "HI", + Ia = "IA", + Id = "ID", + Il = "IL", + In = "IN", + Ks = "KS", + Ky = "KY", + La = "LA", + Ma = "MA", + Md = "MD", + Me = "ME", + Mi = "MI", + Mn = "MN", + Mo = "MO", + Ms = "MS", + Mt = "MT", + Nc = "NC", + Nd = "ND", + Ne = "NE", + Nh = "NH", + Nj = "NJ", + Nm = "NM", + Nv = "NV", + Ny = "NY", + Oh = "OH", + Ok = "OK", + Or = "OR", + Pa = "PA", + Ri = "RI", + Sc = "SC", + Sd = "SD", + Tn = "TN", + Tx = "TX", + Ut = "UT", + Va = "VA", + Vt = "VT", + Wa = "WA", + Wi = "WI", + Wv = "WV", + Wy = "WY", +} diff --git a/sdks/node/model/faxLineCreateRequest.ts b/sdks/node/model/faxLineCreateRequest.ts new file mode 100644 index 000000000..8f7d03a2a --- /dev/null +++ b/sdks/node/model/faxLineCreateRequest.ts @@ -0,0 +1,76 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; +import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; + +export class FaxLineCreateRequest { + /** + * Area code + */ + "areaCode": string; + "country": FaxLineAreaCodeGetCountryEnum; + /** + * City + */ + "city": string; + /** + * Account ID + */ + "accountId"?: string; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "areaCode", + baseName: "area_code", + type: "string", + }, + { + name: "country", + baseName: "country", + type: "FaxLineAreaCodeGetCountryEnum", + }, + { + name: "city", + baseName: "city", + type: "string", + }, + { + name: "accountId", + baseName: "account_id", + type: "string", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineCreateRequest.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineCreateRequest { + return ObjectSerializer.deserialize(data, "FaxLineCreateRequest"); + } +} diff --git a/sdks/node/model/faxLineDeleteRequest.ts b/sdks/node/model/faxLineDeleteRequest.ts new file mode 100644 index 000000000..9db23ffeb --- /dev/null +++ b/sdks/node/model/faxLineDeleteRequest.ts @@ -0,0 +1,51 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export class FaxLineDeleteRequest { + /** + * The Fax Line number. + */ + "number": string; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineDeleteRequest.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineDeleteRequest { + return ObjectSerializer.deserialize(data, "FaxLineDeleteRequest"); + } +} diff --git a/sdks/node/model/faxLineListResponse.ts b/sdks/node/model/faxLineListResponse.ts new file mode 100644 index 000000000..b67942a1e --- /dev/null +++ b/sdks/node/model/faxLineListResponse.ts @@ -0,0 +1,63 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; +import { FaxLineResponse } from "./faxLineResponse"; +import { ListInfoResponse } from "./listInfoResponse"; +import { WarningResponse } from "./warningResponse"; + +export class FaxLineListResponse { + "listInfo"?: ListInfoResponse; + "faxLines"?: Array; + "warnings"?: WarningResponse; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "listInfo", + baseName: "list_info", + type: "ListInfoResponse", + }, + { + name: "faxLines", + baseName: "fax_lines", + type: "Array", + }, + { + name: "warnings", + baseName: "warnings", + type: "WarningResponse", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineListResponse.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineListResponse { + return ObjectSerializer.deserialize(data, "FaxLineListResponse"); + } +} diff --git a/sdks/node/model/faxLineRemoveUserRequest.ts b/sdks/node/model/faxLineRemoveUserRequest.ts new file mode 100644 index 000000000..b415b8eb5 --- /dev/null +++ b/sdks/node/model/faxLineRemoveUserRequest.ts @@ -0,0 +1,69 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; + +export class FaxLineRemoveUserRequest { + /** + * The Fax Line number. + */ + "number": string; + /** + * Account ID + */ + "accountId"?: string; + /** + * Email address + */ + "emailAddress"?: string; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string", + }, + { + name: "accountId", + baseName: "account_id", + type: "string", + }, + { + name: "emailAddress", + baseName: "email_address", + type: "string", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineRemoveUserRequest.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineRemoveUserRequest { + return ObjectSerializer.deserialize(data, "FaxLineRemoveUserRequest"); + } +} diff --git a/sdks/node/model/faxLineResponse.ts b/sdks/node/model/faxLineResponse.ts new file mode 100644 index 000000000..b682f51fa --- /dev/null +++ b/sdks/node/model/faxLineResponse.ts @@ -0,0 +1,55 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; +import { WarningResponse } from "./warningResponse"; + +export class FaxLineResponse { + "faxLine"?: FaxLineResponse; + "warnings"?: WarningResponse; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "faxLine", + baseName: "fax_line", + type: "FaxLineResponse", + }, + { + name: "warnings", + baseName: "warnings", + type: "WarningResponse", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLineResponse.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLineResponse { + return ObjectSerializer.deserialize(data, "FaxLineResponse"); + } +} diff --git a/sdks/node/model/index.ts b/sdks/node/model/index.ts index 60062191f..c771f9709 100644 --- a/sdks/node/model/index.ts +++ b/sdks/node/model/index.ts @@ -32,6 +32,16 @@ import { ErrorResponseError } from "./errorResponseError"; import { EventCallbackRequest } from "./eventCallbackRequest"; import { EventCallbackRequestEvent } from "./eventCallbackRequestEvent"; import { EventCallbackRequestEventMetadata } from "./eventCallbackRequestEventMetadata"; +import { FaxLineAddUserRequest } from "./faxLineAddUserRequest"; +import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; +import { FaxLineAreaCodeGetProvinceEnum } from "./faxLineAreaCodeGetProvinceEnum"; +import { FaxLineAreaCodeGetResponse } from "./faxLineAreaCodeGetResponse"; +import { FaxLineAreaCodeGetStateEnum } from "./faxLineAreaCodeGetStateEnum"; +import { FaxLineCreateRequest } from "./faxLineCreateRequest"; +import { FaxLineDeleteRequest } from "./faxLineDeleteRequest"; +import { FaxLineListResponse } from "./faxLineListResponse"; +import { FaxLineRemoveUserRequest } from "./faxLineRemoveUserRequest"; +import { FaxLineResponse } from "./faxLineResponse"; import { FileResponse } from "./fileResponse"; import { FileResponseDataUri } from "./fileResponseDataUri"; import { ListInfoResponse } from "./listInfoResponse"; @@ -188,6 +198,9 @@ import { export let enumsMap: { [index: string]: any } = { "EventCallbackRequestEvent.EventTypeEnum": EventCallbackRequestEvent.EventTypeEnum, + FaxLineAreaCodeGetCountryEnum: FaxLineAreaCodeGetCountryEnum, + FaxLineAreaCodeGetProvinceEnum: FaxLineAreaCodeGetProvinceEnum, + FaxLineAreaCodeGetStateEnum: FaxLineAreaCodeGetStateEnum, "ReportCreateRequest.ReportTypeEnum": ReportCreateRequest.ReportTypeEnum, "ReportResponse.ReportTypeEnum": ReportResponse.ReportTypeEnum, SignatureRequestResponseCustomFieldTypeEnum: @@ -264,6 +277,13 @@ export let typeMap: { [index: string]: any } = { EventCallbackRequest: EventCallbackRequest, EventCallbackRequestEvent: EventCallbackRequestEvent, EventCallbackRequestEventMetadata: EventCallbackRequestEventMetadata, + FaxLineAddUserRequest: FaxLineAddUserRequest, + FaxLineAreaCodeGetResponse: FaxLineAreaCodeGetResponse, + FaxLineCreateRequest: FaxLineCreateRequest, + FaxLineDeleteRequest: FaxLineDeleteRequest, + FaxLineListResponse: FaxLineListResponse, + FaxLineRemoveUserRequest: FaxLineRemoveUserRequest, + FaxLineResponse: FaxLineResponse, FileResponse: FileResponse, FileResponseDataUri: FileResponseDataUri, ListInfoResponse: ListInfoResponse, @@ -472,6 +492,16 @@ export { EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, + FaxLineAddUserRequest, + FaxLineAreaCodeGetCountryEnum, + FaxLineAreaCodeGetProvinceEnum, + FaxLineAreaCodeGetResponse, + FaxLineAreaCodeGetStateEnum, + FaxLineCreateRequest, + FaxLineDeleteRequest, + FaxLineListResponse, + FaxLineRemoveUserRequest, + FaxLineResponse, FileResponse, FileResponseDataUri, ListInfoResponse, diff --git a/sdks/node/types/api/faxLineApi.d.ts b/sdks/node/types/api/faxLineApi.d.ts new file mode 100644 index 000000000..c6e55927d --- /dev/null +++ b/sdks/node/types/api/faxLineApi.d.ts @@ -0,0 +1,34 @@ +import { Authentication, Interceptor, HttpBasicAuth, HttpBearerAuth, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetResponse, FaxLineAreaCodeGetStateEnum, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse } from "../model"; +import { optionsI, returnTypeT, returnTypeI } from "./"; +export declare enum FaxLineApiApiKeys { +} +export declare class FaxLineApi { + protected _basePath: string; + protected _defaultHeaders: any; + protected _useQuerystring: boolean; + protected authentications: { + default: Authentication; + api_key: HttpBasicAuth; + oauth2: HttpBearerAuth; + }; + protected interceptors: Interceptor[]; + constructor(basePath?: string); + set useQuerystring(value: boolean); + set basePath(basePath: string); + set defaultHeaders(defaultHeaders: any); + get defaultHeaders(): any; + get basePath(): string; + setDefaultAuthentication(auth: Authentication): void; + setApiKey(key: string): void; + set username(username: string); + set password(password: string); + set accessToken(accessToken: string | (() => string)); + addInterceptor(interceptor: Interceptor): void; + faxLineAddUser(faxLineAddUserRequest: FaxLineAddUserRequest, options?: optionsI): Promise>; + faxLineAreaCodeGet(country: FaxLineAreaCodeGetCountryEnum, state?: FaxLineAreaCodeGetStateEnum, province?: FaxLineAreaCodeGetProvinceEnum, city?: string, options?: optionsI): Promise>; + faxLineCreate(faxLineCreateRequest: FaxLineCreateRequest, options?: optionsI): Promise>; + faxLineDelete(faxLineDeleteRequest: FaxLineDeleteRequest, options?: optionsI): Promise; + faxLineGet(number: string, options?: optionsI): Promise>; + faxLineList(accountId?: string, page?: number, pageSize?: number, showTeamLines?: boolean, options?: optionsI): Promise>; + faxLineRemoveUser(faxLineRemoveUserRequest: FaxLineRemoveUserRequest, options?: optionsI): Promise>; +} diff --git a/sdks/node/types/api/index.d.ts b/sdks/node/types/api/index.d.ts index 42c100179..05ccdbb0e 100644 --- a/sdks/node/types/api/index.d.ts +++ b/sdks/node/types/api/index.d.ts @@ -2,12 +2,13 @@ import { AccountApi } from "./accountApi"; import { ApiAppApi } from "./apiAppApi"; import { BulkSendJobApi } from "./bulkSendJobApi"; import { EmbeddedApi } from "./embeddedApi"; +import { FaxLineApi } from "./faxLineApi"; import { OAuthApi } from "./oAuthApi"; import { ReportApi } from "./reportApi"; import { SignatureRequestApi } from "./signatureRequestApi"; import { TeamApi } from "./teamApi"; import { TemplateApi } from "./templateApi"; import { UnclaimedDraftApi } from "./unclaimedDraftApi"; -export { AccountApi, ApiAppApi, BulkSendJobApi, EmbeddedApi, OAuthApi, ReportApi, SignatureRequestApi, TeamApi, TemplateApi, UnclaimedDraftApi, }; +export { AccountApi, ApiAppApi, BulkSendJobApi, EmbeddedApi, FaxLineApi, OAuthApi, ReportApi, SignatureRequestApi, TeamApi, TemplateApi, UnclaimedDraftApi, }; export { HttpError, optionsI, returnTypeT, returnTypeI, generateFormData, toFormData, queryParamsSerializer, USER_AGENT, } from "./apis"; -export declare const APIS: (typeof AccountApi | typeof ApiAppApi | typeof BulkSendJobApi | typeof EmbeddedApi | typeof OAuthApi | typeof ReportApi | typeof SignatureRequestApi | typeof TeamApi | typeof TemplateApi | typeof UnclaimedDraftApi)[]; +export declare const APIS: (typeof AccountApi | typeof ApiAppApi | typeof BulkSendJobApi | typeof EmbeddedApi | typeof FaxLineApi | typeof OAuthApi | typeof ReportApi | typeof SignatureRequestApi | typeof TeamApi | typeof TemplateApi | typeof UnclaimedDraftApi)[]; diff --git a/sdks/node/types/model/faxLineAddUserRequest.d.ts b/sdks/node/types/model/faxLineAddUserRequest.d.ts new file mode 100644 index 000000000..56fefd2f3 --- /dev/null +++ b/sdks/node/types/model/faxLineAddUserRequest.d.ts @@ -0,0 +1,10 @@ +import { AttributeTypeMap } from "./"; +export declare class FaxLineAddUserRequest { + "number": string; + "accountId"?: string; + "emailAddress"?: string; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineAddUserRequest; +} diff --git a/sdks/node/types/model/faxLineAreaCodeGetCountryEnum.d.ts b/sdks/node/types/model/faxLineAreaCodeGetCountryEnum.d.ts new file mode 100644 index 000000000..8352fd878 --- /dev/null +++ b/sdks/node/types/model/faxLineAreaCodeGetCountryEnum.d.ts @@ -0,0 +1,5 @@ +export declare enum FaxLineAreaCodeGetCountryEnum { + Ca = "CA", + Us = "US", + Uk = "UK" +} diff --git a/sdks/node/types/model/faxLineAreaCodeGetProvinceEnum.d.ts b/sdks/node/types/model/faxLineAreaCodeGetProvinceEnum.d.ts new file mode 100644 index 000000000..e43edf5df --- /dev/null +++ b/sdks/node/types/model/faxLineAreaCodeGetProvinceEnum.d.ts @@ -0,0 +1,15 @@ +export declare enum FaxLineAreaCodeGetProvinceEnum { + Ab = "AB", + Bc = "BC", + Mb = "MB", + Nb = "NB", + Nl = "NL", + Nt = "NT", + Ns = "NS", + Nu = "NU", + On = "ON", + Pe = "PE", + Qc = "QC", + Sk = "SK", + Yt = "YT" +} diff --git a/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts b/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts new file mode 100644 index 000000000..407a8b125 --- /dev/null +++ b/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts @@ -0,0 +1,8 @@ +import { AttributeTypeMap } from "./"; +export declare class FaxLineAreaCodeGetResponse { + "areaCodes"?: Array; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineAreaCodeGetResponse; +} diff --git a/sdks/node/types/model/faxLineAreaCodeGetStateEnum.d.ts b/sdks/node/types/model/faxLineAreaCodeGetStateEnum.d.ts new file mode 100644 index 000000000..4193d07bd --- /dev/null +++ b/sdks/node/types/model/faxLineAreaCodeGetStateEnum.d.ts @@ -0,0 +1,53 @@ +export declare enum FaxLineAreaCodeGetStateEnum { + Ak = "AK", + Al = "AL", + Ar = "AR", + Az = "AZ", + Ca = "CA", + Co = "CO", + Ct = "CT", + Dc = "DC", + De = "DE", + Fl = "FL", + Ga = "GA", + Hi = "HI", + Ia = "IA", + Id = "ID", + Il = "IL", + In = "IN", + Ks = "KS", + Ky = "KY", + La = "LA", + Ma = "MA", + Md = "MD", + Me = "ME", + Mi = "MI", + Mn = "MN", + Mo = "MO", + Ms = "MS", + Mt = "MT", + Nc = "NC", + Nd = "ND", + Ne = "NE", + Nh = "NH", + Nj = "NJ", + Nm = "NM", + Nv = "NV", + Ny = "NY", + Oh = "OH", + Ok = "OK", + Or = "OR", + Pa = "PA", + Ri = "RI", + Sc = "SC", + Sd = "SD", + Tn = "TN", + Tx = "TX", + Ut = "UT", + Va = "VA", + Vt = "VT", + Wa = "WA", + Wi = "WI", + Wv = "WV", + Wy = "WY" +} diff --git a/sdks/node/types/model/faxLineCreateRequest.d.ts b/sdks/node/types/model/faxLineCreateRequest.d.ts new file mode 100644 index 000000000..a8333bcee --- /dev/null +++ b/sdks/node/types/model/faxLineCreateRequest.d.ts @@ -0,0 +1,12 @@ +import { AttributeTypeMap } from "./"; +import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; +export declare class FaxLineCreateRequest { + "areaCode": string; + "country": FaxLineAreaCodeGetCountryEnum; + "city": string; + "accountId"?: string; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineCreateRequest; +} diff --git a/sdks/node/types/model/faxLineDeleteRequest.d.ts b/sdks/node/types/model/faxLineDeleteRequest.d.ts new file mode 100644 index 000000000..3dd720983 --- /dev/null +++ b/sdks/node/types/model/faxLineDeleteRequest.d.ts @@ -0,0 +1,8 @@ +import { AttributeTypeMap } from "./"; +export declare class FaxLineDeleteRequest { + "number": string; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineDeleteRequest; +} diff --git a/sdks/node/types/model/faxLineListResponse.d.ts b/sdks/node/types/model/faxLineListResponse.d.ts new file mode 100644 index 000000000..3cdc48693 --- /dev/null +++ b/sdks/node/types/model/faxLineListResponse.d.ts @@ -0,0 +1,13 @@ +import { AttributeTypeMap } from "./"; +import { FaxLineResponse } from "./faxLineResponse"; +import { ListInfoResponse } from "./listInfoResponse"; +import { WarningResponse } from "./warningResponse"; +export declare class FaxLineListResponse { + "listInfo"?: ListInfoResponse; + "faxLines"?: Array; + "warnings"?: WarningResponse; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineListResponse; +} diff --git a/sdks/node/types/model/faxLineRemoveUserRequest.d.ts b/sdks/node/types/model/faxLineRemoveUserRequest.d.ts new file mode 100644 index 000000000..a57a09421 --- /dev/null +++ b/sdks/node/types/model/faxLineRemoveUserRequest.d.ts @@ -0,0 +1,10 @@ +import { AttributeTypeMap } from "./"; +export declare class FaxLineRemoveUserRequest { + "number": string; + "accountId"?: string; + "emailAddress"?: string; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineRemoveUserRequest; +} diff --git a/sdks/node/types/model/faxLineResponse.d.ts b/sdks/node/types/model/faxLineResponse.d.ts new file mode 100644 index 000000000..f8e5eb3fb --- /dev/null +++ b/sdks/node/types/model/faxLineResponse.d.ts @@ -0,0 +1,10 @@ +import { AttributeTypeMap } from "./"; +import { WarningResponse } from "./warningResponse"; +export declare class FaxLineResponse { + "faxLine"?: FaxLineResponse; + "warnings"?: WarningResponse; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLineResponse; +} diff --git a/sdks/node/types/model/index.d.ts b/sdks/node/types/model/index.d.ts index f748121c4..645124b51 100644 --- a/sdks/node/types/model/index.d.ts +++ b/sdks/node/types/model/index.d.ts @@ -32,6 +32,16 @@ import { ErrorResponseError } from "./errorResponseError"; import { EventCallbackRequest } from "./eventCallbackRequest"; import { EventCallbackRequestEvent } from "./eventCallbackRequestEvent"; import { EventCallbackRequestEventMetadata } from "./eventCallbackRequestEventMetadata"; +import { FaxLineAddUserRequest } from "./faxLineAddUserRequest"; +import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; +import { FaxLineAreaCodeGetProvinceEnum } from "./faxLineAreaCodeGetProvinceEnum"; +import { FaxLineAreaCodeGetResponse } from "./faxLineAreaCodeGetResponse"; +import { FaxLineAreaCodeGetStateEnum } from "./faxLineAreaCodeGetStateEnum"; +import { FaxLineCreateRequest } from "./faxLineCreateRequest"; +import { FaxLineDeleteRequest } from "./faxLineDeleteRequest"; +import { FaxLineListResponse } from "./faxLineListResponse"; +import { FaxLineRemoveUserRequest } from "./faxLineRemoveUserRequest"; +import { FaxLineResponse } from "./faxLineResponse"; import { FileResponse } from "./fileResponse"; import { FileResponseDataUri } from "./fileResponseDataUri"; import { ListInfoResponse } from "./listInfoResponse"; diff --git a/sdks/php/README.md b/sdks/php/README.md index 6dc14707d..346a5de2d 100644 --- a/sdks/php/README.md +++ b/sdks/php/README.md @@ -160,6 +160,13 @@ All URIs are relative to *https://api.hellosign.com/v3* | *BulkSendJobApi* | [**bulkSendJobList**](docs/Api/BulkSendJobApi.md#bulksendjoblist) | **GET** /bulk_send_job/list | List Bulk Send Jobs | | *EmbeddedApi* | [**embeddedEditUrl**](docs/Api/EmbeddedApi.md#embeddedediturl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL | | *EmbeddedApi* | [**embeddedSignUrl**](docs/Api/EmbeddedApi.md#embeddedsignurl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL | +| *FaxLineApi* | [**faxLineAddUser**](docs/Api/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | +| *FaxLineApi* | [**faxLineAreaCodeGet**](docs/Api/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | +| *FaxLineApi* | [**faxLineCreate**](docs/Api/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | +| *FaxLineApi* | [**faxLineDelete**](docs/Api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line | +| *FaxLineApi* | [**faxLineGet**](docs/Api/FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line | +| *FaxLineApi* | [**faxLineList**](docs/Api/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | +| *FaxLineApi* | [**faxLineRemoveUser**](docs/Api/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | | *OAuthApi* | [**oauthTokenGenerate**](docs/Api/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate | | *OAuthApi* | [**oauthTokenRefresh**](docs/Api/OAuthApi.md#oauthtokenrefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh | | *ReportApi* | [**reportCreate**](docs/Api/ReportApi.md#reportcreate) | **POST** /report/create | Create Report | @@ -241,6 +248,16 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](docs/Model/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/Model/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/Model/EventCallbackRequestEventMetadata.md) +- [FaxLineAddUserRequest](docs/Model/FaxLineAddUserRequest.md) +- [FaxLineAreaCodeGetCountryEnum](docs/Model/FaxLineAreaCodeGetCountryEnum.md) +- [FaxLineAreaCodeGetProvinceEnum](docs/Model/FaxLineAreaCodeGetProvinceEnum.md) +- [FaxLineAreaCodeGetResponse](docs/Model/FaxLineAreaCodeGetResponse.md) +- [FaxLineAreaCodeGetStateEnum](docs/Model/FaxLineAreaCodeGetStateEnum.md) +- [FaxLineCreateRequest](docs/Model/FaxLineCreateRequest.md) +- [FaxLineDeleteRequest](docs/Model/FaxLineDeleteRequest.md) +- [FaxLineListResponse](docs/Model/FaxLineListResponse.md) +- [FaxLineRemoveUserRequest](docs/Model/FaxLineRemoveUserRequest.md) +- [FaxLineResponse](docs/Model/FaxLineResponse.md) - [FileResponse](docs/Model/FileResponse.md) - [FileResponseDataUri](docs/Model/FileResponseDataUri.md) - [ListInfoResponse](docs/Model/ListInfoResponse.md) diff --git a/sdks/php/docs/Api/FaxLineApi.md b/sdks/php/docs/Api/FaxLineApi.md new file mode 100644 index 000000000..225f50800 --- /dev/null +++ b/sdks/php/docs/Api/FaxLineApi.md @@ -0,0 +1,293 @@ +# Dropbox\Sign\FaxLineApi + +All URIs are relative to https://api.hellosign.com/v3. + +| Method | HTTP request | Description | +| ------------- | ------------- | ------------- | +| [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User | +| [**faxLineAreaCodeGet()**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | +| [**faxLineCreate()**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line | +| [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line | +| [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line | +| [**faxLineList()**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines | +| [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access | + + +## `faxLineAddUser()` + +```php +faxLineAddUser($fax_line_add_user_request): \Dropbox\Sign\Model\FaxLineResponse +``` + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **fax_line_add_user_request** | [**\Dropbox\Sign\Model\FaxLineAddUserRequest**](../Model/FaxLineAddUserRequest.md)| | | + +### Return type + +[**\Dropbox\Sign\Model\FaxLineResponse**](../Model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineAreaCodeGet()` + +```php +faxLineAreaCodeGet($country, $state, $province, $city): \Dropbox\Sign\Model\FaxLineAreaCodeGetResponse +``` + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **country** | [**\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum**](../Model/.md)| Filter area codes by country. | | +| **state** | [**\Dropbox\Sign\Model\FaxLineAreaCodeGetStateEnum**](../Model/.md)| Filter area codes by state. | [optional] | +| **province** | [**\Dropbox\Sign\Model\FaxLineAreaCodeGetProvinceEnum**](../Model/.md)| Filter area codes by province. | [optional] | +| **city** | **string**| Filter area codes by city. | [optional] | + +### Return type + +[**\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse**](../Model/FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineCreate()` + +```php +faxLineCreate($fax_line_create_request): \Dropbox\Sign\Model\FaxLineResponse +``` + +Purchase Fax Line + +Purchases a new Fax Line. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **fax_line_create_request** | [**\Dropbox\Sign\Model\FaxLineCreateRequest**](../Model/FaxLineCreateRequest.md)| | | + +### Return type + +[**\Dropbox\Sign\Model\FaxLineResponse**](../Model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineDelete()` + +```php +faxLineDelete($fax_line_delete_request) +``` + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **fax_line_delete_request** | [**\Dropbox\Sign\Model\FaxLineDeleteRequest**](../Model/FaxLineDeleteRequest.md)| | | + +### Return type + +void (empty response body) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineGet()` + +```php +faxLineGet($number): \Dropbox\Sign\Model\FaxLineResponse +``` + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **number** | **string**| The Fax Line number. | | + +### Return type + +[**\Dropbox\Sign\Model\FaxLineResponse**](../Model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineList()` + +```php +faxLineList($account_id, $page, $page_size, $show_team_lines): \Dropbox\Sign\Model\FaxLineListResponse +``` + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **account_id** | **string**| Account ID | [optional] | +| **page** | **int**| Page | [optional] | +| **page_size** | **int**| Page size | [optional] | +| **show_team_lines** | **bool**| Show team lines | [optional] | + +### Return type + +[**\Dropbox\Sign\Model\FaxLineListResponse**](../Model/FaxLineListResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + +## `faxLineRemoveUser()` + +```php +faxLineRemoveUser($fax_line_remove_user_request): \Dropbox\Sign\Model\FaxLineResponse +``` + +Remove Fax Line Access + +Removes a user's access to the specified Fax Line. + +### Example + +```php + +``` + +### Parameters + +|Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **fax_line_remove_user_request** | [**\Dropbox\Sign\Model\FaxLineRemoveUserRequest**](../Model/FaxLineRemoveUserRequest.md)| | | + +### Return type + +[**\Dropbox\Sign\Model\FaxLineResponse**](../Model/FaxLineResponse.md) + +### Authorization + +[api_key](../../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: `application/json` +- **Accept**: `application/json` + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineAddUserRequest.md b/sdks/php/docs/Model/FaxLineAddUserRequest.md new file mode 100644 index 000000000..aef875b22 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineAddUserRequest.md @@ -0,0 +1,13 @@ +# # FaxLineAddUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```string``` | The Fax Line number. | | +| `account_id` | ```string``` | Account ID | | +| `email_address` | ```string``` | Email address | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineAreaCodeGetCountryEnum.md b/sdks/php/docs/Model/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..91b758d8f --- /dev/null +++ b/sdks/php/docs/Model/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,10 @@ +# # FaxLineAreaCodeGetCountryEnum + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineAreaCodeGetProvinceEnum.md b/sdks/php/docs/Model/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..369a34359 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,10 @@ +# # FaxLineAreaCodeGetProvinceEnum + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md b/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..343e96799 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,11 @@ +# # FaxLineAreaCodeGetResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `area_codes` | ```string[]``` | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineAreaCodeGetStateEnum.md b/sdks/php/docs/Model/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..f978b75a2 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,10 @@ +# # FaxLineAreaCodeGetStateEnum + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineCreateRequest.md b/sdks/php/docs/Model/FaxLineCreateRequest.md new file mode 100644 index 000000000..23465ef7e --- /dev/null +++ b/sdks/php/docs/Model/FaxLineCreateRequest.md @@ -0,0 +1,14 @@ +# # FaxLineCreateRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `area_code`*_required_ | ```string``` | Area code | | +| `country`*_required_ | [```\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `city`*_required_ | ```string``` | City | | +| `account_id` | ```string``` | Account ID | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineDeleteRequest.md b/sdks/php/docs/Model/FaxLineDeleteRequest.md new file mode 100644 index 000000000..a2112ed33 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineDeleteRequest.md @@ -0,0 +1,11 @@ +# # FaxLineDeleteRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```string``` | The Fax Line number. | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineListResponse.md b/sdks/php/docs/Model/FaxLineListResponse.md new file mode 100644 index 000000000..9833a7c5d --- /dev/null +++ b/sdks/php/docs/Model/FaxLineListResponse.md @@ -0,0 +1,13 @@ +# # FaxLineListResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `list_info` | [```\Dropbox\Sign\Model\ListInfoResponse```](ListInfoResponse.md) | | | +| `fax_lines` | [```\Dropbox\Sign\Model\FaxLineResponse[]```](FaxLineResponse.md) | | | +| `warnings` | [```\Dropbox\Sign\Model\WarningResponse```](WarningResponse.md) | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineRemoveUserRequest.md b/sdks/php/docs/Model/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..6def01071 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineRemoveUserRequest.md @@ -0,0 +1,13 @@ +# # FaxLineRemoveUserRequest + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number`*_required_ | ```string``` | The Fax Line number. | | +| `account_id` | ```string``` | Account ID | | +| `email_address` | ```string``` | Email address | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineResponse.md b/sdks/php/docs/Model/FaxLineResponse.md new file mode 100644 index 000000000..803ba6891 --- /dev/null +++ b/sdks/php/docs/Model/FaxLineResponse.md @@ -0,0 +1,12 @@ +# # FaxLineResponse + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `fax_line` | [```\Dropbox\Sign\Model\FaxLineResponse```](FaxLineResponse.md) | | | +| `warnings` | [```\Dropbox\Sign\Model\WarningResponse```](WarningResponse.md) | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/src/Api/FaxLineApi.php b/sdks/php/src/Api/FaxLineApi.php new file mode 100644 index 000000000..807641c7e --- /dev/null +++ b/sdks/php/src/Api/FaxLineApi.php @@ -0,0 +1,2359 @@ +client = $client ?: new Client(); + $this->config = $config ?: new Configuration(); + $this->headerSelector = $selector ?: new HeaderSelector(); + $this->hostIndex = $hostIndex; + } + + /** + * Set the host index + * + * @param int $hostIndex Host index (required) + */ + public function setHostIndex(int $hostIndex): void + { + $this->hostIndex = $hostIndex; + } + + /** + * Get the host index + * + * @return int Host index + */ + public function getHostIndex() + { + return $this->hostIndex; + } + + /** + * @return Configuration + */ + public function getConfig() + { + return $this->config; + } + + /** + * @return ResponseInterface|null + */ + public function getResponse() + { + return $this->response; + } + + /** + * Operation faxLineAddUser + * + * Add Fax Line User + * + * @param Model\FaxLineAddUserRequest $fax_line_add_user_request fax_line_add_user_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return Model\FaxLineResponse + */ + public function faxLineAddUser(Model\FaxLineAddUserRequest $fax_line_add_user_request) + { + list($response) = $this->faxLineAddUserWithHttpInfo($fax_line_add_user_request); + + return $response; + } + + /** + * Operation faxLineAddUserWithHttpInfo + * + * Add Fax Line User + * + * @param Model\FaxLineAddUserRequest $fax_line_add_user_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of Model\FaxLineResponse, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineAddUserWithHttpInfo(Model\FaxLineAddUserRequest $fax_line_add_user_request) + { + $request = $this->faxLineAddUserRequest($fax_line_add_user_request); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode === 200) { + if ('\Dropbox\Sign\Model\FaxLineResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\FaxLineResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + if ('\Dropbox\Sign\Model\ErrorResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\ErrorResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + if ($statusCode === 200) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\FaxLineResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineAddUserAsync + * + * Add Fax Line User + * + * @param Model\FaxLineAddUserRequest $fax_line_add_user_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineAddUserAsync(Model\FaxLineAddUserRequest $fax_line_add_user_request) + { + return $this->faxLineAddUserAsyncWithHttpInfo($fax_line_add_user_request) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineAddUserAsyncWithHttpInfo + * + * Add Fax Line User + * + * @param Model\FaxLineAddUserRequest $fax_line_add_user_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineAddUserAsyncWithHttpInfo(Model\FaxLineAddUserRequest $fax_line_add_user_request) + { + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + $request = $this->faxLineAddUserRequest($fax_line_add_user_request); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineAddUser' + * + * @param Model\FaxLineAddUserRequest $fax_line_add_user_request (required) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineAddUserRequest(Model\FaxLineAddUserRequest $fax_line_add_user_request) + { + // verify the required parameter 'fax_line_add_user_request' is set + if ($fax_line_add_user_request === null || (is_array($fax_line_add_user_request) && count($fax_line_add_user_request) === 0)) { + throw new InvalidArgumentException( + 'Missing the required parameter $fax_line_add_user_request when calling faxLineAddUser' + ); + } + + $resourcePath = '/fax_line/add_user'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = ObjectSerializer::getFormParams( + $fax_line_add_user_request + ); + + $multipart = !empty($formParams); + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + ['application/json'] + ); + } + + // for model (json/xml) + if (count($formParams) === 0) { + if ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode(ObjectSerializer::sanitizeForSerialization($fax_line_add_user_request)); + } else { + $httpBody = $fax_line_add_user_request; + } + } elseif (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + if ($payloadHook = $this->config->getPayloadHook()) { + $payloadHook('multipart', $multipartContents, $fax_line_add_user_request); + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'POST', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Operation faxLineAreaCodeGet + * + * Get Available Fax Line Area Codes + * + * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) + * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) + * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $city Filter area codes by city. (optional) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return Model\FaxLineAreaCodeGetResponse + */ + public function faxLineAreaCodeGet(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + { + list($response) = $this->faxLineAreaCodeGetWithHttpInfo($country, $state, $province, $city); + + return $response; + } + + /** + * Operation faxLineAreaCodeGetWithHttpInfo + * + * Get Available Fax Line Area Codes + * + * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) + * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) + * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $city Filter area codes by city. (optional) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of Model\FaxLineAreaCodeGetResponse, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineAreaCodeGetWithHttpInfo(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + { + $request = $this->faxLineAreaCodeGetRequest($country, $state, $province, $city); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode === 200) { + if ('\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + if ('\Dropbox\Sign\Model\ErrorResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\ErrorResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $returnType = '\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse'; + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + if ($statusCode === 200) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineAreaCodeGetAsync + * + * Get Available Fax Line Area Codes + * + * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) + * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) + * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $city Filter area codes by city. (optional) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineAreaCodeGetAsync(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + { + return $this->faxLineAreaCodeGetAsyncWithHttpInfo($country, $state, $province, $city) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineAreaCodeGetAsyncWithHttpInfo + * + * Get Available Fax Line Area Codes + * + * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) + * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) + * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $city Filter area codes by city. (optional) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineAreaCodeGetAsyncWithHttpInfo(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + { + $returnType = '\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse'; + $request = $this->faxLineAreaCodeGetRequest($country, $state, $province, $city); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineAreaCodeGet' + * + * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) + * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) + * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $city Filter area codes by city. (optional) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineAreaCodeGetRequest(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + { + // verify the required parameter 'country' is set + if ($country === null || (is_array($country) && count($country) === 0)) { + throw new InvalidArgumentException( + 'Missing the required parameter $country when calling faxLineAreaCodeGet' + ); + } + + $resourcePath = '/fax_line/area_codes'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = []; + $multipart = false; + + // query params + if ($country !== null) { + if ('form' === 'form' && is_array($country)) { + foreach ($country as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['country'] = $country; + } + } + // query params + if ($state !== null) { + if ('form' === 'form' && is_array($state)) { + foreach ($state as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['state'] = $state; + } + } + // query params + if ($province !== null) { + if ('form' === 'form' && is_array($province)) { + foreach ($province as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['province'] = $province; + } + } + // query params + if ($city !== null) { + if ('form' === 'form' && is_array($city)) { + foreach ($city as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['city'] = $city; + } + } + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + [] + ); + } + + // for model (json/xml) + if (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'GET', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Operation faxLineCreate + * + * Purchase Fax Line + * + * @param Model\FaxLineCreateRequest $fax_line_create_request fax_line_create_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return Model\FaxLineResponse + */ + public function faxLineCreate(Model\FaxLineCreateRequest $fax_line_create_request) + { + list($response) = $this->faxLineCreateWithHttpInfo($fax_line_create_request); + + return $response; + } + + /** + * Operation faxLineCreateWithHttpInfo + * + * Purchase Fax Line + * + * @param Model\FaxLineCreateRequest $fax_line_create_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of Model\FaxLineResponse, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineCreateWithHttpInfo(Model\FaxLineCreateRequest $fax_line_create_request) + { + $request = $this->faxLineCreateRequest($fax_line_create_request); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode === 200) { + if ('\Dropbox\Sign\Model\FaxLineResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\FaxLineResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + if ('\Dropbox\Sign\Model\ErrorResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\ErrorResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + if ($statusCode === 200) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\FaxLineResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineCreateAsync + * + * Purchase Fax Line + * + * @param Model\FaxLineCreateRequest $fax_line_create_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineCreateAsync(Model\FaxLineCreateRequest $fax_line_create_request) + { + return $this->faxLineCreateAsyncWithHttpInfo($fax_line_create_request) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineCreateAsyncWithHttpInfo + * + * Purchase Fax Line + * + * @param Model\FaxLineCreateRequest $fax_line_create_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineCreateAsyncWithHttpInfo(Model\FaxLineCreateRequest $fax_line_create_request) + { + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + $request = $this->faxLineCreateRequest($fax_line_create_request); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineCreate' + * + * @param Model\FaxLineCreateRequest $fax_line_create_request (required) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineCreateRequest(Model\FaxLineCreateRequest $fax_line_create_request) + { + // verify the required parameter 'fax_line_create_request' is set + if ($fax_line_create_request === null || (is_array($fax_line_create_request) && count($fax_line_create_request) === 0)) { + throw new InvalidArgumentException( + 'Missing the required parameter $fax_line_create_request when calling faxLineCreate' + ); + } + + $resourcePath = '/fax_line/create'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = ObjectSerializer::getFormParams( + $fax_line_create_request + ); + + $multipart = !empty($formParams); + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + ['application/json'] + ); + } + + // for model (json/xml) + if (count($formParams) === 0) { + if ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode(ObjectSerializer::sanitizeForSerialization($fax_line_create_request)); + } else { + $httpBody = $fax_line_create_request; + } + } elseif (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + if ($payloadHook = $this->config->getPayloadHook()) { + $payloadHook('multipart', $multipartContents, $fax_line_create_request); + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'POST', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Operation faxLineDelete + * + * Delete Fax Line + * + * @param Model\FaxLineDeleteRequest $fax_line_delete_request fax_line_delete_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return void + */ + public function faxLineDelete(Model\FaxLineDeleteRequest $fax_line_delete_request) + { + $this->faxLineDeleteWithHttpInfo($fax_line_delete_request); + } + + /** + * Operation faxLineDeleteWithHttpInfo + * + * Delete Fax Line + * + * @param Model\FaxLineDeleteRequest $fax_line_delete_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of null, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineDeleteWithHttpInfo(Model\FaxLineDeleteRequest $fax_line_delete_request) + { + $request = $this->faxLineDeleteRequest($fax_line_delete_request); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + return [null, $statusCode, $response->getHeaders()]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineDeleteAsync + * + * Delete Fax Line + * + * @param Model\FaxLineDeleteRequest $fax_line_delete_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineDeleteAsync(Model\FaxLineDeleteRequest $fax_line_delete_request) + { + return $this->faxLineDeleteAsyncWithHttpInfo($fax_line_delete_request) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineDeleteAsyncWithHttpInfo + * + * Delete Fax Line + * + * @param Model\FaxLineDeleteRequest $fax_line_delete_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineDeleteAsyncWithHttpInfo(Model\FaxLineDeleteRequest $fax_line_delete_request) + { + $returnType = ''; + $request = $this->faxLineDeleteRequest($fax_line_delete_request); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) { + return [null, $response->getStatusCode(), $response->getHeaders()]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineDelete' + * + * @param Model\FaxLineDeleteRequest $fax_line_delete_request (required) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineDeleteRequest(Model\FaxLineDeleteRequest $fax_line_delete_request) + { + // verify the required parameter 'fax_line_delete_request' is set + if ($fax_line_delete_request === null || (is_array($fax_line_delete_request) && count($fax_line_delete_request) === 0)) { + throw new InvalidArgumentException( + 'Missing the required parameter $fax_line_delete_request when calling faxLineDelete' + ); + } + + $resourcePath = '/fax_line/delete'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = ObjectSerializer::getFormParams( + $fax_line_delete_request + ); + + $multipart = !empty($formParams); + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + ['application/json'] + ); + } + + // for model (json/xml) + if (count($formParams) === 0) { + if ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode(ObjectSerializer::sanitizeForSerialization($fax_line_delete_request)); + } else { + $httpBody = $fax_line_delete_request; + } + } elseif (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + if ($payloadHook = $this->config->getPayloadHook()) { + $payloadHook('multipart', $multipartContents, $fax_line_delete_request); + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'DELETE', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Operation faxLineGet + * + * Get Fax Line + * + * @param string $number The Fax Line number. (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return Model\FaxLineResponse + */ + public function faxLineGet(string $number) + { + list($response) = $this->faxLineGetWithHttpInfo($number); + + return $response; + } + + /** + * Operation faxLineGetWithHttpInfo + * + * Get Fax Line + * + * @param string $number The Fax Line number. (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of Model\FaxLineResponse, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineGetWithHttpInfo(string $number) + { + $request = $this->faxLineGetRequest($number); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode === 200) { + if ('\Dropbox\Sign\Model\FaxLineResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\FaxLineResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + if ('\Dropbox\Sign\Model\ErrorResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\ErrorResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + if ($statusCode === 200) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\FaxLineResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineGetAsync + * + * Get Fax Line + * + * @param string $number The Fax Line number. (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineGetAsync(string $number) + { + return $this->faxLineGetAsyncWithHttpInfo($number) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineGetAsyncWithHttpInfo + * + * Get Fax Line + * + * @param string $number The Fax Line number. (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineGetAsyncWithHttpInfo(string $number) + { + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + $request = $this->faxLineGetRequest($number); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineGet' + * + * @param string $number The Fax Line number. (required) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineGetRequest(string $number) + { + // verify the required parameter 'number' is set + if ($number === null || (is_array($number) && count($number) === 0)) { + throw new InvalidArgumentException( + 'Missing the required parameter $number when calling faxLineGet' + ); + } + + $resourcePath = '/fax_line/{number}'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = []; + $multipart = false; + + // path params + if ($number !== null) { + $resourcePath = str_replace( + '{' . 'number' . '}', + ObjectSerializer::toPathValue($number), + $resourcePath + ); + } + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + [] + ); + } + + // for model (json/xml) + if (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'GET', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Operation faxLineList + * + * List Fax Lines + * + * @param string $account_id Account ID (optional) + * @param int $page Page (optional) + * @param int $page_size Page size (optional) + * @param bool $show_team_lines Show team lines (optional) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return Model\FaxLineListResponse + */ + public function faxLineList(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + { + list($response) = $this->faxLineListWithHttpInfo($account_id, $page, $page_size, $show_team_lines); + + return $response; + } + + /** + * Operation faxLineListWithHttpInfo + * + * List Fax Lines + * + * @param string $account_id Account ID (optional) + * @param int $page Page (optional) + * @param int $page_size Page size (optional) + * @param bool $show_team_lines Show team lines (optional) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of Model\FaxLineListResponse, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineListWithHttpInfo(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + { + $request = $this->faxLineListRequest($account_id, $page, $page_size, $show_team_lines); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode === 200) { + if ('\Dropbox\Sign\Model\FaxLineListResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\FaxLineListResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + if ('\Dropbox\Sign\Model\ErrorResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\ErrorResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $returnType = '\Dropbox\Sign\Model\FaxLineListResponse'; + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + if ($statusCode === 200) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\FaxLineListResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineListAsync + * + * List Fax Lines + * + * @param string $account_id Account ID (optional) + * @param int $page Page (optional) + * @param int $page_size Page size (optional) + * @param bool $show_team_lines Show team lines (optional) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineListAsync(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + { + return $this->faxLineListAsyncWithHttpInfo($account_id, $page, $page_size, $show_team_lines) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineListAsyncWithHttpInfo + * + * List Fax Lines + * + * @param string $account_id Account ID (optional) + * @param int $page Page (optional) + * @param int $page_size Page size (optional) + * @param bool $show_team_lines Show team lines (optional) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineListAsyncWithHttpInfo(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + { + $returnType = '\Dropbox\Sign\Model\FaxLineListResponse'; + $request = $this->faxLineListRequest($account_id, $page, $page_size, $show_team_lines); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineList' + * + * @param string $account_id Account ID (optional) + * @param int $page Page (optional) + * @param int $page_size Page size (optional) + * @param bool $show_team_lines Show team lines (optional) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineListRequest(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + { + $resourcePath = '/fax_line/list'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = []; + $multipart = false; + + // query params + if ($account_id !== null) { + if ('form' === 'form' && is_array($account_id)) { + foreach ($account_id as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['account_id'] = $account_id; + } + } + // query params + if ($page !== null) { + if ('form' === 'form' && is_array($page)) { + foreach ($page as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['page'] = $page; + } + } + // query params + if ($page_size !== null) { + if ('form' === 'form' && is_array($page_size)) { + foreach ($page_size as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['page_size'] = $page_size; + } + } + // query params + if ($show_team_lines !== null) { + if ('form' === 'form' && is_array($show_team_lines)) { + foreach ($show_team_lines as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['show_team_lines'] = $show_team_lines; + } + } + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + [] + ); + } + + // for model (json/xml) + if (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'GET', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Operation faxLineRemoveUser + * + * Remove Fax Line Access + * + * @param Model\FaxLineRemoveUserRequest $fax_line_remove_user_request fax_line_remove_user_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return Model\FaxLineResponse + */ + public function faxLineRemoveUser(Model\FaxLineRemoveUserRequest $fax_line_remove_user_request) + { + list($response) = $this->faxLineRemoveUserWithHttpInfo($fax_line_remove_user_request); + + return $response; + } + + /** + * Operation faxLineRemoveUserWithHttpInfo + * + * Remove Fax Line Access + * + * @param Model\FaxLineRemoveUserRequest $fax_line_remove_user_request (required) + * + * @throws ApiException on non-2xx response + * @throws InvalidArgumentException + * @return array of Model\FaxLineResponse, HTTP status code, HTTP response headers (array of strings) + */ + public function faxLineRemoveUserWithHttpInfo(Model\FaxLineRemoveUserRequest $fax_line_remove_user_request) + { + $request = $this->faxLineRemoveUserRequest($fax_line_remove_user_request); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + $this->response = $response; + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode === 200) { + if ('\Dropbox\Sign\Model\FaxLineResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\FaxLineResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + if ('\Dropbox\Sign\Model\ErrorResponse' === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, '\Dropbox\Sign\Model\ErrorResponse', []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } + + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + } catch (ApiException $e) { + $statusCode = $e->getCode(); + + if ($statusCode === 200) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\FaxLineResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + $rangeCodeLeft = (int) (substr('4XX', 0, 1) . '00'); + $rangeCodeRight = (int) (substr('4XX', 0, 1) . '99'); + if ($statusCode >= $rangeCodeLeft && $statusCode <= $rangeCodeRight) { + $data = ObjectSerializer::deserialize( + $e->getResponseBody(), + '\Dropbox\Sign\Model\ErrorResponse', + $e->getResponseHeaders() + ); + $e->setResponseObject($data); + } + + throw $e; + } + } + + /** + * Operation faxLineRemoveUserAsync + * + * Remove Fax Line Access + * + * @param Model\FaxLineRemoveUserRequest $fax_line_remove_user_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineRemoveUserAsync(Model\FaxLineRemoveUserRequest $fax_line_remove_user_request) + { + return $this->faxLineRemoveUserAsyncWithHttpInfo($fax_line_remove_user_request) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation faxLineRemoveUserAsyncWithHttpInfo + * + * Remove Fax Line Access + * + * @param Model\FaxLineRemoveUserRequest $fax_line_remove_user_request (required) + * + * @throws InvalidArgumentException + * @return Promise\PromiseInterface + */ + public function faxLineRemoveUserAsyncWithHttpInfo(Model\FaxLineRemoveUserRequest $fax_line_remove_user_request) + { + $returnType = '\Dropbox\Sign\Model\FaxLineResponse'; + $request = $this->faxLineRemoveUserRequest($fax_line_remove_user_request); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + if ($returnType === '\SplFileObject') { + $content = $response->getBody(); //stream goes to serializer + } else { + $content = (string) $response->getBody(); + } + + return [ + ObjectSerializer::deserialize($content, $returnType, []), + $response->getStatusCode(), + $response->getHeaders(), + ]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'faxLineRemoveUser' + * + * @param Model\FaxLineRemoveUserRequest $fax_line_remove_user_request (required) + * + * @throws InvalidArgumentException + * @return Psr7\Request + */ + public function faxLineRemoveUserRequest(Model\FaxLineRemoveUserRequest $fax_line_remove_user_request) + { + // verify the required parameter 'fax_line_remove_user_request' is set + if ($fax_line_remove_user_request === null || (is_array($fax_line_remove_user_request) && count($fax_line_remove_user_request) === 0)) { + throw new InvalidArgumentException( + 'Missing the required parameter $fax_line_remove_user_request when calling faxLineRemoveUser' + ); + } + + $resourcePath = '/fax_line/remove_user'; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + + $formParams = ObjectSerializer::getFormParams( + $fax_line_remove_user_request + ); + + $multipart = !empty($formParams); + + if ($multipart) { + $headers = $this->headerSelector->selectHeadersForMultipart( + ['multipart/form-data'] + ); + } else { + $headers = $this->headerSelector->selectHeaders( + ['application/json'], + ['application/json'] + ); + } + + // for model (json/xml) + if (count($formParams) === 0) { + if ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode(ObjectSerializer::sanitizeForSerialization($fax_line_remove_user_request)); + } else { + $httpBody = $fax_line_remove_user_request; + } + } elseif (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem, + ]; + } + } + // for HTTP post (form) + if (!empty($body)) { + $multipartContents[] = [ + 'name' => 'body', + 'contents' => $body, + 'headers' => ['Content-Type' => 'application/json'], + ]; + } + + if ($payloadHook = $this->config->getPayloadHook()) { + $payloadHook('multipart', $multipartContents, $fax_line_remove_user_request); + } + + $httpBody = new Psr7\MultipartStream($multipartContents); + } elseif ($headers['Content-Type'] === 'application/json') { + $httpBody = Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = Psr7\Query::build($formParams); + } + } + + // this endpoint requires HTTP basic authentication + if (!empty($this->config->getUsername())) { + $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ':'); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $query = Psr7\Query::build($queryParams); + + return new Psr7\Request( + 'POST', + $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + + /** + * Create http client option + * + * @throws RuntimeException on file opening failure + * @return array of http client options + */ + protected function createHttpClientOption() + { + $options = $this->config->getOptions(); + if ($this->config->getDebug()) { + $options[RequestOptions::DEBUG] = fopen($this->config->getDebugFile(), 'a'); + if (!$options[RequestOptions::DEBUG]) { + throw new RuntimeException('Failed to open the debug file: ' . $this->config->getDebugFile()); + } + } + + return $options; + } +} diff --git a/sdks/php/src/Model/FaxLineAddUserRequest.php b/sdks/php/src/Model/FaxLineAddUserRequest.php new file mode 100644 index 000000000..02c975ca4 --- /dev/null +++ b/sdks/php/src/Model/FaxLineAddUserRequest.php @@ -0,0 +1,405 @@ + + * @template TKey int|null + * @template TValue mixed|null + */ +class FaxLineAddUserRequest implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineAddUserRequest'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'number' => 'string', + 'account_id' => 'string', + 'email_address' => 'string', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'number' => null, + 'account_id' => null, + 'email_address' => 'email', + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'number' => 'number', + 'account_id' => 'account_id', + 'email_address' => 'email_address', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'number' => 'setNumber', + 'account_id' => 'setAccountId', + 'email_address' => 'setEmailAddress', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'number' => 'getNumber', + 'account_id' => 'getAccountId', + 'email_address' => 'getEmailAddress', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['number'] = $data['number'] ?? null; + $this->container['account_id'] = $data['account_id'] ?? null; + $this->container['email_address'] = $data['email_address'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineAddUserRequest + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineAddUserRequest + { + /** @var FaxLineAddUserRequest $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineAddUserRequest::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + if ($this->container['number'] === null) { + $invalidProperties[] = "'number' can't be null"; + } + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets number + * + * @return string + */ + public function getNumber() + { + return $this->container['number']; + } + + /** + * Sets number + * + * @param string $number the Fax Line number + * + * @return self + */ + public function setNumber(string $number) + { + $this->container['number'] = $number; + + return $this; + } + + /** + * Gets account_id + * + * @return string|null + */ + public function getAccountId() + { + return $this->container['account_id']; + } + + /** + * Sets account_id + * + * @param string|null $account_id Account ID + * + * @return self + */ + public function setAccountId(?string $account_id) + { + $this->container['account_id'] = $account_id; + + return $this; + } + + /** + * Gets email_address + * + * @return string|null + */ + public function getEmailAddress() + { + return $this->container['email_address']; + } + + /** + * Sets email_address + * + * @param string|null $email_address Email address + * + * @return self + */ + public function setEmailAddress(?string $email_address) + { + $this->container['email_address'] = $email_address; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineAreaCodeGetCountryEnum.php b/sdks/php/src/Model/FaxLineAreaCodeGetCountryEnum.php new file mode 100644 index 000000000..d310fb693 --- /dev/null +++ b/sdks/php/src/Model/FaxLineAreaCodeGetCountryEnum.php @@ -0,0 +1,61 @@ + + * @template TKey int|null + * @template TValue mixed|null + * @internal This class should not be instantiated directly + */ +class FaxLineAreaCodeGetResponse implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineAreaCodeGetResponse'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'area_codes' => 'string[]', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'area_codes' => null, + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'area_codes' => 'area_codes', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'area_codes' => 'setAreaCodes', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'area_codes' => 'getAreaCodes', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['area_codes'] = $data['area_codes'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineAreaCodeGetResponse + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineAreaCodeGetResponse + { + /** @var FaxLineAreaCodeGetResponse $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineAreaCodeGetResponse::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets area_codes + * + * @return string[]|null + */ + public function getAreaCodes() + { + return $this->container['area_codes']; + } + + /** + * Sets area_codes + * + * @param string[]|null $area_codes area_codes + * + * @return self + */ + public function setAreaCodes(?array $area_codes) + { + $this->container['area_codes'] = $area_codes; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineAreaCodeGetStateEnum.php b/sdks/php/src/Model/FaxLineAreaCodeGetStateEnum.php new file mode 100644 index 000000000..14e49fe85 --- /dev/null +++ b/sdks/php/src/Model/FaxLineAreaCodeGetStateEnum.php @@ -0,0 +1,205 @@ + + * @template TKey int|null + * @template TValue mixed|null + */ +class FaxLineCreateRequest implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineCreateRequest'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'area_code' => 'string', + 'country' => '\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum', + 'city' => 'string', + 'account_id' => 'string', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'area_code' => null, + 'country' => null, + 'city' => null, + 'account_id' => null, + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'area_code' => 'area_code', + 'country' => 'country', + 'city' => 'city', + 'account_id' => 'account_id', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'area_code' => 'setAreaCode', + 'country' => 'setCountry', + 'city' => 'setCity', + 'account_id' => 'setAccountId', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'area_code' => 'getAreaCode', + 'country' => 'getCountry', + 'city' => 'getCity', + 'account_id' => 'getAccountId', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['area_code'] = $data['area_code'] ?? null; + $this->container['country'] = $data['country'] ?? null; + $this->container['city'] = $data['city'] ?? null; + $this->container['account_id'] = $data['account_id'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineCreateRequest + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineCreateRequest + { + /** @var FaxLineCreateRequest $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineCreateRequest::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + if ($this->container['area_code'] === null) { + $invalidProperties[] = "'area_code' can't be null"; + } + if ($this->container['country'] === null) { + $invalidProperties[] = "'country' can't be null"; + } + if ($this->container['city'] === null) { + $invalidProperties[] = "'city' can't be null"; + } + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets area_code + * + * @return string + */ + public function getAreaCode() + { + return $this->container['area_code']; + } + + /** + * Sets area_code + * + * @param string $area_code Area code + * + * @return self + */ + public function setAreaCode(string $area_code) + { + $this->container['area_code'] = $area_code; + + return $this; + } + + /** + * Gets country + * + * @return FaxLineAreaCodeGetCountryEnum + */ + public function getCountry() + { + return $this->container['country']; + } + + /** + * Sets country + * + * @param FaxLineAreaCodeGetCountryEnum $country country + * + * @return self + */ + public function setCountry(FaxLineAreaCodeGetCountryEnum $country) + { + $this->container['country'] = $country; + + return $this; + } + + /** + * Gets city + * + * @return string + */ + public function getCity() + { + return $this->container['city']; + } + + /** + * Sets city + * + * @param string $city City + * + * @return self + */ + public function setCity(string $city) + { + $this->container['city'] = $city; + + return $this; + } + + /** + * Gets account_id + * + * @return string|null + */ + public function getAccountId() + { + return $this->container['account_id']; + } + + /** + * Sets account_id + * + * @param string|null $account_id Account ID + * + * @return self + */ + public function setAccountId(?string $account_id) + { + $this->container['account_id'] = $account_id; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineDeleteRequest.php b/sdks/php/src/Model/FaxLineDeleteRequest.php new file mode 100644 index 000000000..cb3152aa8 --- /dev/null +++ b/sdks/php/src/Model/FaxLineDeleteRequest.php @@ -0,0 +1,345 @@ + + * @template TKey int|null + * @template TValue mixed|null + */ +class FaxLineDeleteRequest implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineDeleteRequest'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'number' => 'string', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'number' => null, + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'number' => 'number', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'number' => 'setNumber', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'number' => 'getNumber', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['number'] = $data['number'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineDeleteRequest + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineDeleteRequest + { + /** @var FaxLineDeleteRequest $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineDeleteRequest::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + if ($this->container['number'] === null) { + $invalidProperties[] = "'number' can't be null"; + } + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets number + * + * @return string + */ + public function getNumber() + { + return $this->container['number']; + } + + /** + * Sets number + * + * @param string $number the Fax Line number + * + * @return self + */ + public function setNumber(string $number) + { + $this->container['number'] = $number; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineListResponse.php b/sdks/php/src/Model/FaxLineListResponse.php new file mode 100644 index 000000000..cc12477ae --- /dev/null +++ b/sdks/php/src/Model/FaxLineListResponse.php @@ -0,0 +1,402 @@ + + * @template TKey int|null + * @template TValue mixed|null + * @internal This class should not be instantiated directly + */ +class FaxLineListResponse implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineListResponse'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'list_info' => '\Dropbox\Sign\Model\ListInfoResponse', + 'fax_lines' => '\Dropbox\Sign\Model\FaxLineResponse[]', + 'warnings' => '\Dropbox\Sign\Model\WarningResponse', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'list_info' => null, + 'fax_lines' => null, + 'warnings' => null, + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'list_info' => 'list_info', + 'fax_lines' => 'fax_lines', + 'warnings' => 'warnings', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'list_info' => 'setListInfo', + 'fax_lines' => 'setFaxLines', + 'warnings' => 'setWarnings', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'list_info' => 'getListInfo', + 'fax_lines' => 'getFaxLines', + 'warnings' => 'getWarnings', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['list_info'] = $data['list_info'] ?? null; + $this->container['fax_lines'] = $data['fax_lines'] ?? null; + $this->container['warnings'] = $data['warnings'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineListResponse + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineListResponse + { + /** @var FaxLineListResponse $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineListResponse::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets list_info + * + * @return ListInfoResponse|null + */ + public function getListInfo() + { + return $this->container['list_info']; + } + + /** + * Sets list_info + * + * @param ListInfoResponse|null $list_info list_info + * + * @return self + */ + public function setListInfo(?ListInfoResponse $list_info) + { + $this->container['list_info'] = $list_info; + + return $this; + } + + /** + * Gets fax_lines + * + * @return FaxLineResponse[]|null + */ + public function getFaxLines() + { + return $this->container['fax_lines']; + } + + /** + * Sets fax_lines + * + * @param FaxLineResponse[]|null $fax_lines fax_lines + * + * @return self + */ + public function setFaxLines(?array $fax_lines) + { + $this->container['fax_lines'] = $fax_lines; + + return $this; + } + + /** + * Gets warnings + * + * @return WarningResponse|null + */ + public function getWarnings() + { + return $this->container['warnings']; + } + + /** + * Sets warnings + * + * @param WarningResponse|null $warnings warnings + * + * @return self + */ + public function setWarnings(?WarningResponse $warnings) + { + $this->container['warnings'] = $warnings; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineRemoveUserRequest.php b/sdks/php/src/Model/FaxLineRemoveUserRequest.php new file mode 100644 index 000000000..fcc2b1f97 --- /dev/null +++ b/sdks/php/src/Model/FaxLineRemoveUserRequest.php @@ -0,0 +1,405 @@ + + * @template TKey int|null + * @template TValue mixed|null + */ +class FaxLineRemoveUserRequest implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineRemoveUserRequest'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'number' => 'string', + 'account_id' => 'string', + 'email_address' => 'string', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'number' => null, + 'account_id' => null, + 'email_address' => 'email', + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'number' => 'number', + 'account_id' => 'account_id', + 'email_address' => 'email_address', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'number' => 'setNumber', + 'account_id' => 'setAccountId', + 'email_address' => 'setEmailAddress', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'number' => 'getNumber', + 'account_id' => 'getAccountId', + 'email_address' => 'getEmailAddress', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['number'] = $data['number'] ?? null; + $this->container['account_id'] = $data['account_id'] ?? null; + $this->container['email_address'] = $data['email_address'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineRemoveUserRequest + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineRemoveUserRequest + { + /** @var FaxLineRemoveUserRequest $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineRemoveUserRequest::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + if ($this->container['number'] === null) { + $invalidProperties[] = "'number' can't be null"; + } + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets number + * + * @return string + */ + public function getNumber() + { + return $this->container['number']; + } + + /** + * Sets number + * + * @param string $number the Fax Line number + * + * @return self + */ + public function setNumber(string $number) + { + $this->container['number'] = $number; + + return $this; + } + + /** + * Gets account_id + * + * @return string|null + */ + public function getAccountId() + { + return $this->container['account_id']; + } + + /** + * Sets account_id + * + * @param string|null $account_id Account ID + * + * @return self + */ + public function setAccountId(?string $account_id) + { + $this->container['account_id'] = $account_id; + + return $this; + } + + /** + * Gets email_address + * + * @return string|null + */ + public function getEmailAddress() + { + return $this->container['email_address']; + } + + /** + * Sets email_address + * + * @param string|null $email_address Email address + * + * @return self + */ + public function setEmailAddress(?string $email_address) + { + $this->container['email_address'] = $email_address; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineResponse.php b/sdks/php/src/Model/FaxLineResponse.php new file mode 100644 index 000000000..b3a567c4a --- /dev/null +++ b/sdks/php/src/Model/FaxLineResponse.php @@ -0,0 +1,372 @@ + + * @template TKey int|null + * @template TValue mixed|null + * @internal This class should not be instantiated directly + */ +class FaxLineResponse implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLineResponse'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'fax_line' => '\Dropbox\Sign\Model\FaxLineResponse', + 'warnings' => '\Dropbox\Sign\Model\WarningResponse', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'fax_line' => null, + 'warnings' => null, + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'fax_line' => 'fax_line', + 'warnings' => 'warnings', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'fax_line' => 'setFaxLine', + 'warnings' => 'setWarnings', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'fax_line' => 'getFaxLine', + 'warnings' => 'getWarnings', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['fax_line'] = $data['fax_line'] ?? null; + $this->container['warnings'] = $data['warnings'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLineResponse + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLineResponse + { + /** @var FaxLineResponse $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLineResponse::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets fax_line + * + * @return FaxLineResponse|null + */ + public function getFaxLine() + { + return $this->container['fax_line']; + } + + /** + * Sets fax_line + * + * @param FaxLineResponse|null $fax_line fax_line + * + * @return self + */ + public function setFaxLine(?FaxLineResponse $fax_line) + { + $this->container['fax_line'] = $fax_line; + + return $this; + } + + /** + * Gets warnings + * + * @return WarningResponse|null + */ + public function getWarnings() + { + return $this->container['warnings']; + } + + /** + * Sets warnings + * + * @param WarningResponse|null $warnings warnings + * + * @return self + */ + public function setWarnings(?WarningResponse $warnings) + { + $this->container['warnings'] = $warnings; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/python/.openapi-generator/FILES b/sdks/python/.openapi-generator/FILES index 22b647339..f51adff33 100644 --- a/sdks/python/.openapi-generator/FILES +++ b/sdks/python/.openapi-generator/FILES @@ -41,6 +41,17 @@ docs/ErrorResponseError.md docs/EventCallbackRequest.md docs/EventCallbackRequestEvent.md docs/EventCallbackRequestEventMetadata.md +docs/FaxLineAddUserRequest.md +docs/FaxLineApi.md +docs/FaxLineAreaCodeGetCountryEnum.md +docs/FaxLineAreaCodeGetProvinceEnum.md +docs/FaxLineAreaCodeGetResponse.md +docs/FaxLineAreaCodeGetStateEnum.md +docs/FaxLineCreateRequest.md +docs/FaxLineDeleteRequest.md +docs/FaxLineListResponse.md +docs/FaxLineRemoveUserRequest.md +docs/FaxLineResponse.md docs/FileResponse.md docs/FileResponseDataUri.md docs/ListInfoResponse.md @@ -191,6 +202,7 @@ dropbox_sign/api/account_api.py dropbox_sign/api/api_app_api.py dropbox_sign/api/bulk_send_job_api.py dropbox_sign/api/embedded_api.py +dropbox_sign/api/fax_line_api.py dropbox_sign/api/o_auth_api.py dropbox_sign/api/report_api.py dropbox_sign/api/signature_request_api.py @@ -237,6 +249,16 @@ dropbox_sign/model/error_response_error.py dropbox_sign/model/event_callback_request.py dropbox_sign/model/event_callback_request_event.py dropbox_sign/model/event_callback_request_event_metadata.py +dropbox_sign/model/fax_line_add_user_request.py +dropbox_sign/model/fax_line_area_code_get_country_enum.py +dropbox_sign/model/fax_line_area_code_get_province_enum.py +dropbox_sign/model/fax_line_area_code_get_response.py +dropbox_sign/model/fax_line_area_code_get_state_enum.py +dropbox_sign/model/fax_line_create_request.py +dropbox_sign/model/fax_line_delete_request.py +dropbox_sign/model/fax_line_list_response.py +dropbox_sign/model/fax_line_remove_user_request.py +dropbox_sign/model/fax_line_response.py dropbox_sign/model/file_response.py dropbox_sign/model/file_response_data_uri.py dropbox_sign/model/list_info_response.py diff --git a/sdks/python/README.md b/sdks/python/README.md index b2233372c..5c1ad75b7 100644 --- a/sdks/python/README.md +++ b/sdks/python/README.md @@ -118,6 +118,13 @@ All URIs are relative to *https://api.hellosign.com/v3* ```BulkSendJobApi``` | [```bulk_send_job_list```](docs/BulkSendJobApi.md#bulk_send_job_list) | ```GET /bulk_send_job/list``` | List Bulk Send Jobs| |```EmbeddedApi``` | [```embedded_edit_url```](docs/EmbeddedApi.md#embedded_edit_url) | ```POST /embedded/edit_url/{template_id}``` | Get Embedded Template Edit URL| ```EmbeddedApi``` | [```embedded_sign_url```](docs/EmbeddedApi.md#embedded_sign_url) | ```GET /embedded/sign_url/{signature_id}``` | Get Embedded Sign URL| +|```FaxLineApi``` | [```fax_line_add_user```](docs/FaxLineApi.md#fax_line_add_user) | ```POST /fax_line/add_user``` | Add Fax Line User| +```FaxLineApi``` | [```fax_line_area_code_get```](docs/FaxLineApi.md#fax_line_area_code_get) | ```GET /fax_line/area_codes``` | Get Available Fax Line Area Codes| +```FaxLineApi``` | [```fax_line_create```](docs/FaxLineApi.md#fax_line_create) | ```POST /fax_line/create``` | Purchase Fax Line| +```FaxLineApi``` | [```fax_line_delete```](docs/FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line/delete``` | Delete Fax Line| +```FaxLineApi``` | [```fax_line_get```](docs/FaxLineApi.md#fax_line_get) | ```GET /fax_line/{number}``` | Get Fax Line| +```FaxLineApi``` | [```fax_line_list```](docs/FaxLineApi.md#fax_line_list) | ```GET /fax_line/list``` | List Fax Lines| +```FaxLineApi``` | [```fax_line_remove_user```](docs/FaxLineApi.md#fax_line_remove_user) | ```POST /fax_line/remove_user``` | Remove Fax Line Access| |```OAuthApi``` | [```oauth_token_generate```](docs/OAuthApi.md#oauth_token_generate) | ```POST /oauth/token``` | OAuth Token Generate| ```OAuthApi``` | [```oauth_token_refresh```](docs/OAuthApi.md#oauth_token_refresh) | ```POST /oauth/token?refresh``` | OAuth Token Refresh| |```ReportApi``` | [```report_create```](docs/ReportApi.md#report_create) | ```POST /report/create``` | Create Report| @@ -200,6 +207,16 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) + - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) + - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) + - [FaxLineAreaCodeGetResponse](docs/FaxLineAreaCodeGetResponse.md) + - [FaxLineAreaCodeGetStateEnum](docs/FaxLineAreaCodeGetStateEnum.md) + - [FaxLineCreateRequest](docs/FaxLineCreateRequest.md) + - [FaxLineDeleteRequest](docs/FaxLineDeleteRequest.md) + - [FaxLineListResponse](docs/FaxLineListResponse.md) + - [FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) + - [FaxLineResponse](docs/FaxLineResponse.md) - [FileResponse](docs/FileResponse.md) - [FileResponseDataUri](docs/FileResponseDataUri.md) - [ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/python/docs/FaxLineAddUserRequest.md b/sdks/python/docs/FaxLineAddUserRequest.md new file mode 100644 index 000000000..9ad0485b7 --- /dev/null +++ b/sdks/python/docs/FaxLineAddUserRequest.md @@ -0,0 +1,16 @@ +# FaxLineAddUserRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number`*_required_ | ```str``` | The Fax Line number. | | +| `account_id` | ```str``` | Account ID | | +| `email_address` | ```str``` | Email address | | + + +[[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/sdks/python/docs/FaxLineApi.md b/sdks/python/docs/FaxLineApi.md new file mode 100644 index 000000000..40c7d9fb3 --- /dev/null +++ b/sdks/python/docs/FaxLineApi.md @@ -0,0 +1,336 @@ +# ```dropbox_sign.FaxLineApi``` + +All URIs are relative to *https://api.hellosign.com/v3* + +|Method | HTTP request | Description| +|------------- | ------------- | -------------| +|[```fax_line_add_user```](FaxLineApi.md#fax_line_add_user) | ```POST /fax_line/add_user``` | Add Fax Line User| +|[```fax_line_area_code_get```](FaxLineApi.md#fax_line_area_code_get) | ```GET /fax_line/area_codes``` | Get Available Fax Line Area Codes| +|[```fax_line_create```](FaxLineApi.md#fax_line_create) | ```POST /fax_line/create``` | Purchase Fax Line| +|[```fax_line_delete```](FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line/delete``` | Delete Fax Line| +|[```fax_line_get```](FaxLineApi.md#fax_line_get) | ```GET /fax_line/{number}``` | Get Fax Line| +|[```fax_line_list```](FaxLineApi.md#fax_line_list) | ```GET /fax_line/list``` | List Fax Lines| +|[```fax_line_remove_user```](FaxLineApi.md#fax_line_remove_user) | ```POST /fax_line/remove_user``` | Remove Fax Line Access| + + +# ```fax_line_add_user``` +> ```FaxLineResponse fax_line_add_user(fax_line_add_user_request)``` + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_add_user_request` | [**FaxLineAddUserRequest**](FaxLineAddUserRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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) + +# ```fax_line_area_code_get``` +> ```FaxLineAreaCodeGetResponse fax_line_area_code_get(country)``` + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `country` | [**FaxLineAreaCodeGetCountryEnum**](.md) | Filter area codes by country. | | +| `state` | [**FaxLineAreaCodeGetStateEnum**](.md) | Filter area codes by state. | [optional] | +| `province` | [**FaxLineAreaCodeGetProvinceEnum**](.md) | Filter area codes by province. | [optional] | +| `city` | **str** | Filter area codes by city. | [optional] | + +### Return type + +[**FaxLineAreaCodeGetResponse**](FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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) + +# ```fax_line_create``` +> ```FaxLineResponse fax_line_create(fax_line_create_request)``` + +Purchase Fax Line + +Purchases a new Fax Line. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_create_request` | [**FaxLineCreateRequest**](FaxLineCreateRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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) + +# ```fax_line_delete``` +> ```fax_line_delete(fax_line_delete_request)``` + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_delete_request` | [**FaxLineDeleteRequest**](FaxLineDeleteRequest.md) | | | + +### Return type + +void (empty response body) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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) + +# ```fax_line_get``` +> ```FaxLineResponse fax_line_get(number)``` + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number` | **str** | The Fax Line number. | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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) + +# ```fax_line_list``` +> ```FaxLineListResponse fax_line_list()``` + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `account_id` | **str** | Account ID | [optional] | +| `page` | **int** | Page | [optional] | +| `page_size` | **int** | Page size | [optional] | +| `show_team_lines` | **bool** | Show team lines | [optional] | + +### Return type + +[**FaxLineListResponse**](FaxLineListResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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) + +# ```fax_line_remove_user``` +> ```FaxLineResponse fax_line_remove_user(fax_line_remove_user_request)``` + +Remove Fax Line Access + +Removes a user's access to the specified Fax Line. + +### Example + +* Basic Authentication (api_key): + +```python + +``` + + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_remove_user_request` | [**FaxLineRemoveUserRequest**](FaxLineRemoveUserRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | successful operation | * X-RateLimit-Limit -
* X-RateLimit-Remaining -
* X-Ratelimit-Reset -
| +**4XX** | failed_operation | - | + +[[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/sdks/python/docs/FaxLineAreaCodeGetCountryEnum.md b/sdks/python/docs/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..2df64fe3d --- /dev/null +++ b/sdks/python/docs/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,13 @@ +# FaxLineAreaCodeGetCountryEnum + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + + +[[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/sdks/python/docs/FaxLineAreaCodeGetProvinceEnum.md b/sdks/python/docs/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..46be71327 --- /dev/null +++ b/sdks/python/docs/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,13 @@ +# FaxLineAreaCodeGetProvinceEnum + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + + +[[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/sdks/python/docs/FaxLineAreaCodeGetResponse.md b/sdks/python/docs/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..6b5b3dde7 --- /dev/null +++ b/sdks/python/docs/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,14 @@ +# FaxLineAreaCodeGetResponse + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `area_codes` | ```[str]``` | | | + + +[[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/sdks/python/docs/FaxLineAreaCodeGetStateEnum.md b/sdks/python/docs/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..9557a82b5 --- /dev/null +++ b/sdks/python/docs/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,13 @@ +# FaxLineAreaCodeGetStateEnum + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + + +[[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/sdks/python/docs/FaxLineCreateRequest.md b/sdks/python/docs/FaxLineCreateRequest.md new file mode 100644 index 000000000..ea7453221 --- /dev/null +++ b/sdks/python/docs/FaxLineCreateRequest.md @@ -0,0 +1,17 @@ +# FaxLineCreateRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `area_code`*_required_ | ```str``` | Area code | | +| `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `city`*_required_ | ```str``` | City | | +| `account_id` | ```str``` | Account ID | | + + +[[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/sdks/python/docs/FaxLineDeleteRequest.md b/sdks/python/docs/FaxLineDeleteRequest.md new file mode 100644 index 000000000..8e803d32c --- /dev/null +++ b/sdks/python/docs/FaxLineDeleteRequest.md @@ -0,0 +1,14 @@ +# FaxLineDeleteRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number`*_required_ | ```str``` | The Fax Line number. | | + + +[[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/sdks/python/docs/FaxLineListResponse.md b/sdks/python/docs/FaxLineListResponse.md new file mode 100644 index 000000000..741c381d1 --- /dev/null +++ b/sdks/python/docs/FaxLineListResponse.md @@ -0,0 +1,16 @@ +# FaxLineListResponse + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `list_info` | [```ListInfoResponse```](ListInfoResponse.md) | | | +| `fax_lines` | [```[FaxLineResponse]```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + + +[[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/sdks/python/docs/FaxLineRemoveUserRequest.md b/sdks/python/docs/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..934ff186a --- /dev/null +++ b/sdks/python/docs/FaxLineRemoveUserRequest.md @@ -0,0 +1,16 @@ +# FaxLineRemoveUserRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number`*_required_ | ```str``` | The Fax Line number. | | +| `account_id` | ```str``` | Account ID | | +| `email_address` | ```str``` | Email address | | + + +[[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/sdks/python/docs/FaxLineResponse.md b/sdks/python/docs/FaxLineResponse.md new file mode 100644 index 000000000..3c8fb305e --- /dev/null +++ b/sdks/python/docs/FaxLineResponse.md @@ -0,0 +1,15 @@ +# FaxLineResponse + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + + +[[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/sdks/python/dropbox_sign/api/fax_line_api.py b/sdks/python/dropbox_sign/api/fax_line_api.py new file mode 100644 index 000000000..ba67ed5a8 --- /dev/null +++ b/sdks/python/dropbox_sign/api/fax_line_api.py @@ -0,0 +1,1119 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign.api_client import ApiClient, ApiException, Endpoint as _Endpoint +from dropbox_sign.model_utils import ( # noqa: F401 + check_allowed_values, + check_validations, + date, + datetime, + file_type, + none_type, + validate_and_convert_types +) +from dropbox_sign.model.error_response import ErrorResponse +from dropbox_sign.model.fax_line_add_user_request import FaxLineAddUserRequest +from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum +from dropbox_sign.model.fax_line_area_code_get_province_enum import FaxLineAreaCodeGetProvinceEnum +from dropbox_sign.model.fax_line_area_code_get_response import FaxLineAreaCodeGetResponse +from dropbox_sign.model.fax_line_area_code_get_state_enum import FaxLineAreaCodeGetStateEnum +from dropbox_sign.model.fax_line_create_request import FaxLineCreateRequest +from dropbox_sign.model.fax_line_delete_request import FaxLineDeleteRequest +from dropbox_sign.model.fax_line_list_response import FaxLineListResponse +from dropbox_sign.model.fax_line_remove_user_request import FaxLineRemoveUserRequest +from dropbox_sign.model.fax_line_response import FaxLineResponse + + +class FaxLineApi(object): + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None): + if api_client is None: + api_client = ApiClient() + self.api_client = api_client + self.fax_line_add_user_endpoint = _Endpoint( + settings={ + 'response_type': (FaxLineResponse,), + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/add_user', + 'operation_id': 'fax_line_add_user', + 'http_method': 'POST', + 'servers': None, + }, + params_map={ + 'all': [ + 'fax_line_add_user_request', + ], + 'required': [ + 'fax_line_add_user_request', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'fax_line_add_user_request': + (FaxLineAddUserRequest,), + }, + 'attribute_map': { + }, + 'location_map': { + 'fax_line_add_user_request': 'body', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [ + 'application/json' + ] + }, + api_client=api_client + ) + self.fax_line_area_code_get_endpoint = _Endpoint( + settings={ + 'response_type': (FaxLineAreaCodeGetResponse,), + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/area_codes', + 'operation_id': 'fax_line_area_code_get', + 'http_method': 'GET', + 'servers': None, + }, + params_map={ + 'all': [ + 'country', + 'state', + 'province', + 'city', + ], + 'required': [ + 'country', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'country': + (FaxLineAreaCodeGetCountryEnum,), + 'state': + (FaxLineAreaCodeGetStateEnum,), + 'province': + (FaxLineAreaCodeGetProvinceEnum,), + 'city': + (str,), + }, + 'attribute_map': { + 'country': 'country', + 'state': 'state', + 'province': 'province', + 'city': 'city', + }, + 'location_map': { + 'country': 'query', + 'state': 'query', + 'province': 'query', + 'city': 'query', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [], + }, + api_client=api_client + ) + self.fax_line_create_endpoint = _Endpoint( + settings={ + 'response_type': (FaxLineResponse,), + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/create', + 'operation_id': 'fax_line_create', + 'http_method': 'POST', + 'servers': None, + }, + params_map={ + 'all': [ + 'fax_line_create_request', + ], + 'required': [ + 'fax_line_create_request', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'fax_line_create_request': + (FaxLineCreateRequest,), + }, + 'attribute_map': { + }, + 'location_map': { + 'fax_line_create_request': 'body', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [ + 'application/json' + ] + }, + api_client=api_client + ) + self.fax_line_delete_endpoint = _Endpoint( + settings={ + 'response_type': None, + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/delete', + 'operation_id': 'fax_line_delete', + 'http_method': 'DELETE', + 'servers': None, + }, + params_map={ + 'all': [ + 'fax_line_delete_request', + ], + 'required': [ + 'fax_line_delete_request', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'fax_line_delete_request': + (FaxLineDeleteRequest,), + }, + 'attribute_map': { + }, + 'location_map': { + 'fax_line_delete_request': 'body', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [ + 'application/json' + ] + }, + api_client=api_client + ) + self.fax_line_get_endpoint = _Endpoint( + settings={ + 'response_type': (FaxLineResponse,), + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/{number}', + 'operation_id': 'fax_line_get', + 'http_method': 'GET', + 'servers': None, + }, + params_map={ + 'all': [ + 'number', + ], + 'required': [ + 'number', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'number': + (str,), + }, + 'attribute_map': { + 'number': 'number', + }, + 'location_map': { + 'number': 'path', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [], + }, + api_client=api_client + ) + self.fax_line_list_endpoint = _Endpoint( + settings={ + 'response_type': (FaxLineListResponse,), + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/list', + 'operation_id': 'fax_line_list', + 'http_method': 'GET', + 'servers': None, + }, + params_map={ + 'all': [ + 'account_id', + 'page', + 'page_size', + 'show_team_lines', + ], + 'required': [], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'account_id': + (str,), + 'page': + (int,), + 'page_size': + (int,), + 'show_team_lines': + (bool,), + }, + 'attribute_map': { + 'account_id': 'account_id', + 'page': 'page', + 'page_size': 'page_size', + 'show_team_lines': 'show_team_lines', + }, + 'location_map': { + 'account_id': 'query', + 'page': 'query', + 'page_size': 'query', + 'show_team_lines': 'query', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [], + }, + api_client=api_client + ) + self.fax_line_remove_user_endpoint = _Endpoint( + settings={ + 'response_type': (FaxLineResponse,), + 'auth': [ + 'api_key' + ], + 'endpoint_path': '/fax_line/remove_user', + 'operation_id': 'fax_line_remove_user', + 'http_method': 'POST', + 'servers': None, + }, + params_map={ + 'all': [ + 'fax_line_remove_user_request', + ], + 'required': [ + 'fax_line_remove_user_request', + ], + 'nullable': [ + ], + 'enum': [ + ], + 'validation': [ + ] + }, + root_map={ + 'validations': { + }, + 'allowed_values': { + }, + 'openapi_types': { + 'fax_line_remove_user_request': + (FaxLineRemoveUserRequest,), + }, + 'attribute_map': { + }, + 'location_map': { + 'fax_line_remove_user_request': 'body', + }, + 'collection_format_map': { + } + }, + headers_map={ + 'accept': [ + 'application/json' + ], + 'content_type': [ + 'application/json' + ] + }, + api_client=api_client + ) + + def fax_line_add_user( + self, + fax_line_add_user_request, + **kwargs + ) -> FaxLineResponse: + """Add Fax Line User # noqa: E501 + + Grants a user access to the specified Fax Line. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_add_user(fax_line_add_user_request, async_req=True) + >>> result = thread.get() + + Args: + fax_line_add_user_request (FaxLineAddUserRequest): + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FaxLineResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['fax_line_add_user_request'] = \ + fax_line_add_user_request + try: + return self.fax_line_add_user_endpoint.call_with_http_info(**kwargs) + except ApiException as e: + if e.status == 200: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[FaxLineResponse], + _check_type=True, + ) + + raise e + range_code = "4XX"[0] + range_code_left = int(f"{range_code}00") + range_code_right = int(f"{range_code}99") + + if range_code_left <= e.status <= range_code_right: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[ErrorResponse], + _check_type=True, + ) + + raise e + + def fax_line_area_code_get( + self, + country, + **kwargs + ) -> FaxLineAreaCodeGetResponse: + """Get Available Fax Line Area Codes # noqa: E501 + + Returns a response with the area codes available for a given state/provice and city. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_area_code_get(country, async_req=True) + >>> result = thread.get() + + Args: + country (FaxLineAreaCodeGetCountryEnum): Filter area codes by country. + + Keyword Args: + state (FaxLineAreaCodeGetStateEnum): Filter area codes by state.. [optional] + province (FaxLineAreaCodeGetProvinceEnum): Filter area codes by province.. [optional] + city (str): Filter area codes by city.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FaxLineAreaCodeGetResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['country'] = \ + country + try: + return self.fax_line_area_code_get_endpoint.call_with_http_info(**kwargs) + except ApiException as e: + if e.status == 200: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[FaxLineAreaCodeGetResponse], + _check_type=True, + ) + + raise e + range_code = "4XX"[0] + range_code_left = int(f"{range_code}00") + range_code_right = int(f"{range_code}99") + + if range_code_left <= e.status <= range_code_right: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[ErrorResponse], + _check_type=True, + ) + + raise e + + def fax_line_create( + self, + fax_line_create_request, + **kwargs + ) -> FaxLineResponse: + """Purchase Fax Line # noqa: E501 + + Purchases a new Fax Line. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_create(fax_line_create_request, async_req=True) + >>> result = thread.get() + + Args: + fax_line_create_request (FaxLineCreateRequest): + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FaxLineResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['fax_line_create_request'] = \ + fax_line_create_request + try: + return self.fax_line_create_endpoint.call_with_http_info(**kwargs) + except ApiException as e: + if e.status == 200: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[FaxLineResponse], + _check_type=True, + ) + + raise e + range_code = "4XX"[0] + range_code_left = int(f"{range_code}00") + range_code_right = int(f"{range_code}99") + + if range_code_left <= e.status <= range_code_right: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[ErrorResponse], + _check_type=True, + ) + + raise e + + def fax_line_delete( + self, + fax_line_delete_request, + **kwargs + ) -> None: + """Delete Fax Line # noqa: E501 + + Deletes the specified Fax Line from the subscription. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_delete(fax_line_delete_request, async_req=True) + >>> result = thread.get() + + Args: + fax_line_delete_request (FaxLineDeleteRequest): + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['fax_line_delete_request'] = \ + fax_line_delete_request + return self.fax_line_delete_endpoint.call_with_http_info(**kwargs) + + def fax_line_get( + self, + number, + **kwargs + ) -> FaxLineResponse: + """Get Fax Line # noqa: E501 + + Returns the properties and settings of a Fax Line. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_get(number, async_req=True) + >>> result = thread.get() + + Args: + number (str): The Fax Line number. + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FaxLineResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['number'] = \ + number + try: + return self.fax_line_get_endpoint.call_with_http_info(**kwargs) + except ApiException as e: + if e.status == 200: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[FaxLineResponse], + _check_type=True, + ) + + raise e + range_code = "4XX"[0] + range_code_left = int(f"{range_code}00") + range_code_right = int(f"{range_code}99") + + if range_code_left <= e.status <= range_code_right: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[ErrorResponse], + _check_type=True, + ) + + raise e + + def fax_line_list( + self, + **kwargs + ) -> FaxLineListResponse: + """List Fax Lines # noqa: E501 + + Returns the properties and settings of multiple Fax Lines. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_list(async_req=True) + >>> result = thread.get() + + + Keyword Args: + account_id (str): Account ID. [optional] + page (int): Page. [optional] + page_size (int): Page size. [optional] + show_team_lines (bool): Show team lines. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FaxLineListResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + try: + return self.fax_line_list_endpoint.call_with_http_info(**kwargs) + except ApiException as e: + if e.status == 200: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[FaxLineListResponse], + _check_type=True, + ) + + raise e + range_code = "4XX"[0] + range_code_left = int(f"{range_code}00") + range_code_right = int(f"{range_code}99") + + if range_code_left <= e.status <= range_code_right: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[ErrorResponse], + _check_type=True, + ) + + raise e + + def fax_line_remove_user( + self, + fax_line_remove_user_request, + **kwargs + ) -> FaxLineResponse: + """Remove Fax Line Access # noqa: E501 + + Removes a user's access to the specified Fax Line. # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.fax_line_remove_user(fax_line_remove_user_request, async_req=True) + >>> result = thread.get() + + Args: + fax_line_remove_user_request (FaxLineRemoveUserRequest): + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): timeout setting for this request. If + one number provided, it will be total request timeout. It can also + be a pair (tuple) of (connection, read) timeouts. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FaxLineResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['fax_line_remove_user_request'] = \ + fax_line_remove_user_request + try: + return self.fax_line_remove_user_endpoint.call_with_http_info(**kwargs) + except ApiException as e: + if e.status == 200: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[FaxLineResponse], + _check_type=True, + ) + + raise e + range_code = "4XX"[0] + range_code_left = int(f"{range_code}00") + range_code_right = int(f"{range_code}99") + + if range_code_left <= e.status <= range_code_right: + e.body = self.api_client.deserialize( + response=type('obj_dict', (object,), {'data': e.body}), + response_type=[ErrorResponse], + _check_type=True, + ) + + raise e + diff --git a/sdks/python/dropbox_sign/apis/__init__.py b/sdks/python/dropbox_sign/apis/__init__.py index dca24c92e..413c12aa2 100644 --- a/sdks/python/dropbox_sign/apis/__init__.py +++ b/sdks/python/dropbox_sign/apis/__init__.py @@ -18,6 +18,7 @@ from dropbox_sign.api.api_app_api import ApiAppApi from dropbox_sign.api.bulk_send_job_api import BulkSendJobApi from dropbox_sign.api.embedded_api import EmbeddedApi +from dropbox_sign.api.fax_line_api import FaxLineApi from dropbox_sign.api.o_auth_api import OAuthApi from dropbox_sign.api.report_api import ReportApi from dropbox_sign.api.signature_request_api import SignatureRequestApi diff --git a/sdks/python/dropbox_sign/model/fax_line_add_user_request.py b/sdks/python/dropbox_sign/model/fax_line_add_user_request.py new file mode 100644 index 000000000..234fdbafa --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_add_user_request.py @@ -0,0 +1,313 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineAddUserRequest(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'number': (str,), # noqa: E501 + 'account_id': (str,), # noqa: E501 + 'email_address': (str,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineAddUserRequest: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineAddUserRequest], + _check_type=True, + ) + + attribute_map = { + 'number': 'number', # noqa: E501 + 'account_id': 'account_id', # noqa: E501 + 'email_address': 'email_address', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def number(self) -> str: + return self.get("number") + + @number.setter + def number(self, value: str): + setattr(self, "number", value) + + @property + def account_id(self) -> str: + return self.get("account_id") + + @account_id.setter + def account_id(self, value: str): + setattr(self, "account_id", value) + + @property + def email_address(self) -> str: + return self.get("email_address") + + @email_address.setter + def email_address(self, value: str): + setattr(self, "email_address", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, number, *args, **kwargs): # noqa: E501 + """FaxLineAddUserRequest - a model defined in OpenAPI + + Args: + number (str): The Fax Line number. + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + account_id (str): Account ID. [optional] # noqa: E501 + email_address (str): Email address. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.number = number + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, number, *args, **kwargs): # noqa: E501 + """FaxLineAddUserRequest - a model defined in OpenAPI + + Args: + number (str): The Fax Line number. + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + account_id (str): Account ID. [optional] # noqa: E501 + email_address (str): Email address. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.number = number + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_area_code_get_country_enum.py b/sdks/python/dropbox_sign/model/fax_line_area_code_get_country_enum.py new file mode 100644 index 000000000..cbd0d8ce4 --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_area_code_get_country_enum.py @@ -0,0 +1,304 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineAreaCodeGetCountryEnum(ModelSimple): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + ('value',): { + 'CA': "CA", + 'US': "US", + 'UK': "UK", + }, + } + + validations = { + } + + additional_properties_type = None + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'value': (str,), + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineAreaCodeGetCountryEnum: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineAreaCodeGetCountryEnum], + _check_type=True, + ) + + + attribute_map = {} + + read_only_vars = set() + + _composed_schemas = None + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): + """FaxLineAreaCodeGetCountryEnum - a model defined in OpenAPI + + Note that value can be passed either in args or in kwargs, but not in both. + + Args: + args[0] (str):, must be one of ["CA", "US", "UK", ] # noqa: E501 + + Keyword Args: + value (str):, must be one of ["CA", "US", "UK", ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + # required up here when default value is not given + _path_to_item = kwargs.pop('_path_to_item', ()) + + if 'value' in kwargs: + value = kwargs.pop('value') + elif args: + args = list(args) + value = args.pop(0) + else: + raise ApiTypeError( + "value is required, but not passed in args or kwargs and doesn't have default", + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + self.value = value + if kwargs: + raise ApiTypeError( + "Invalid named arguments=%s passed to %s. Remove those invalid named arguments." % ( + kwargs, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): + """FaxLineAreaCodeGetCountryEnum - a model defined in OpenAPI + + Note that value can be passed either in args or in kwargs, but not in both. + + Args: + args[0] (str):, must be one of ["CA", "US", "UK", ] # noqa: E501 + + Keyword Args: + value (str):, must be one of ["CA", "US", "UK", ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + # required up here when default value is not given + _path_to_item = kwargs.pop('_path_to_item', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if 'value' in kwargs: + value = kwargs.pop('value') + elif args: + args = list(args) + value = args.pop(0) + else: + raise ApiTypeError( + "value is required, but not passed in args or kwargs and doesn't have default", + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + self.value = value + if kwargs: + raise ApiTypeError( + "Invalid named arguments=%s passed to %s. Remove those invalid named arguments." % ( + kwargs, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + return self diff --git a/sdks/python/dropbox_sign/model/fax_line_area_code_get_province_enum.py b/sdks/python/dropbox_sign/model/fax_line_area_code_get_province_enum.py new file mode 100644 index 000000000..a9e640a58 --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_area_code_get_province_enum.py @@ -0,0 +1,314 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineAreaCodeGetProvinceEnum(ModelSimple): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + ('value',): { + 'AB': "AB", + 'BC': "BC", + 'MB': "MB", + 'NB': "NB", + 'NL': "NL", + 'NT': "NT", + 'NS': "NS", + 'NU': "NU", + 'ON': "ON", + 'PE': "PE", + 'QC': "QC", + 'SK': "SK", + 'YT': "YT", + }, + } + + validations = { + } + + additional_properties_type = None + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'value': (str,), + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineAreaCodeGetProvinceEnum: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineAreaCodeGetProvinceEnum], + _check_type=True, + ) + + + attribute_map = {} + + read_only_vars = set() + + _composed_schemas = None + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): + """FaxLineAreaCodeGetProvinceEnum - a model defined in OpenAPI + + Note that value can be passed either in args or in kwargs, but not in both. + + Args: + args[0] (str):, must be one of ["AB", "BC", "MB", "NB", "NL", "NT", "NS", "NU", "ON", "PE", "QC", "SK", "YT", ] # noqa: E501 + + Keyword Args: + value (str):, must be one of ["AB", "BC", "MB", "NB", "NL", "NT", "NS", "NU", "ON", "PE", "QC", "SK", "YT", ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + # required up here when default value is not given + _path_to_item = kwargs.pop('_path_to_item', ()) + + if 'value' in kwargs: + value = kwargs.pop('value') + elif args: + args = list(args) + value = args.pop(0) + else: + raise ApiTypeError( + "value is required, but not passed in args or kwargs and doesn't have default", + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + self.value = value + if kwargs: + raise ApiTypeError( + "Invalid named arguments=%s passed to %s. Remove those invalid named arguments." % ( + kwargs, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): + """FaxLineAreaCodeGetProvinceEnum - a model defined in OpenAPI + + Note that value can be passed either in args or in kwargs, but not in both. + + Args: + args[0] (str):, must be one of ["AB", "BC", "MB", "NB", "NL", "NT", "NS", "NU", "ON", "PE", "QC", "SK", "YT", ] # noqa: E501 + + Keyword Args: + value (str):, must be one of ["AB", "BC", "MB", "NB", "NL", "NT", "NS", "NU", "ON", "PE", "QC", "SK", "YT", ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + # required up here when default value is not given + _path_to_item = kwargs.pop('_path_to_item', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if 'value' in kwargs: + value = kwargs.pop('value') + elif args: + args = list(args) + value = args.pop(0) + else: + raise ApiTypeError( + "value is required, but not passed in args or kwargs and doesn't have default", + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + self.value = value + if kwargs: + raise ApiTypeError( + "Invalid named arguments=%s passed to %s. Remove those invalid named arguments." % ( + kwargs, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + return self diff --git a/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py b/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py new file mode 100644 index 000000000..4756b6580 --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py @@ -0,0 +1,283 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineAreaCodeGetResponse(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'area_codes': ([str],), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineAreaCodeGetResponse: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineAreaCodeGetResponse], + _check_type=True, + ) + + attribute_map = { + 'area_codes': 'area_codes', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def area_codes(self) -> List[str]: + return self.get("area_codes") + + @area_codes.setter + def area_codes(self, value: List[str]): + setattr(self, "area_codes", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """FaxLineAreaCodeGetResponse - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + area_codes ([str]): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): # noqa: E501 + """FaxLineAreaCodeGetResponse - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + area_codes ([str]): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_area_code_get_state_enum.py b/sdks/python/dropbox_sign/model/fax_line_area_code_get_state_enum.py new file mode 100644 index 000000000..e070603d3 --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_area_code_get_state_enum.py @@ -0,0 +1,352 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineAreaCodeGetStateEnum(ModelSimple): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + ('value',): { + 'AK': "AK", + 'AL': "AL", + 'AR': "AR", + 'AZ': "AZ", + 'CA': "CA", + 'CO': "CO", + 'CT': "CT", + 'DC': "DC", + 'DE': "DE", + 'FL': "FL", + 'GA': "GA", + 'HI': "HI", + 'IA': "IA", + 'ID': "ID", + 'IL': "IL", + 'IN': "IN", + 'KS': "KS", + 'KY': "KY", + 'LA': "LA", + 'MA': "MA", + 'MD': "MD", + 'ME': "ME", + 'MI': "MI", + 'MN': "MN", + 'MO': "MO", + 'MS': "MS", + 'MT': "MT", + 'NC': "NC", + 'ND': "ND", + 'NE': "NE", + 'NH': "NH", + 'NJ': "NJ", + 'NM': "NM", + 'NV': "NV", + 'NY': "NY", + 'OH': "OH", + 'OK': "OK", + 'OR': "OR", + 'PA': "PA", + 'RI': "RI", + 'SC': "SC", + 'SD': "SD", + 'TN': "TN", + 'TX': "TX", + 'UT': "UT", + 'VA': "VA", + 'VT': "VT", + 'WA': "WA", + 'WI': "WI", + 'WV': "WV", + 'WY': "WY", + }, + } + + validations = { + } + + additional_properties_type = None + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'value': (str,), + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineAreaCodeGetStateEnum: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineAreaCodeGetStateEnum], + _check_type=True, + ) + + + attribute_map = {} + + read_only_vars = set() + + _composed_schemas = None + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): + """FaxLineAreaCodeGetStateEnum - a model defined in OpenAPI + + Note that value can be passed either in args or in kwargs, but not in both. + + Args: + args[0] (str):, must be one of ["AK", "AL", "AR", "AZ", "CA", "CO", "CT", "DC", "DE", "FL", "GA", "HI", "IA", "ID", "IL", "IN", "KS", "KY", "LA", "MA", "MD", "ME", "MI", "MN", "MO", "MS", "MT", "NC", "ND", "NE", "NH", "NJ", "NM", "NV", "NY", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VA", "VT", "WA", "WI", "WV", "WY", ] # noqa: E501 + + Keyword Args: + value (str):, must be one of ["AK", "AL", "AR", "AZ", "CA", "CO", "CT", "DC", "DE", "FL", "GA", "HI", "IA", "ID", "IL", "IN", "KS", "KY", "LA", "MA", "MD", "ME", "MI", "MN", "MO", "MS", "MT", "NC", "ND", "NE", "NH", "NJ", "NM", "NV", "NY", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VA", "VT", "WA", "WI", "WV", "WY", ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + # required up here when default value is not given + _path_to_item = kwargs.pop('_path_to_item', ()) + + if 'value' in kwargs: + value = kwargs.pop('value') + elif args: + args = list(args) + value = args.pop(0) + else: + raise ApiTypeError( + "value is required, but not passed in args or kwargs and doesn't have default", + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + self.value = value + if kwargs: + raise ApiTypeError( + "Invalid named arguments=%s passed to %s. Remove those invalid named arguments." % ( + kwargs, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): + """FaxLineAreaCodeGetStateEnum - a model defined in OpenAPI + + Note that value can be passed either in args or in kwargs, but not in both. + + Args: + args[0] (str):, must be one of ["AK", "AL", "AR", "AZ", "CA", "CO", "CT", "DC", "DE", "FL", "GA", "HI", "IA", "ID", "IL", "IN", "KS", "KY", "LA", "MA", "MD", "ME", "MI", "MN", "MO", "MS", "MT", "NC", "ND", "NE", "NH", "NJ", "NM", "NV", "NY", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VA", "VT", "WA", "WI", "WV", "WY", ] # noqa: E501 + + Keyword Args: + value (str):, must be one of ["AK", "AL", "AR", "AZ", "CA", "CO", "CT", "DC", "DE", "FL", "GA", "HI", "IA", "ID", "IL", "IN", "KS", "KY", "LA", "MA", "MD", "ME", "MI", "MN", "MO", "MS", "MT", "NC", "ND", "NE", "NH", "NJ", "NM", "NV", "NY", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VA", "VT", "WA", "WI", "WV", "WY", ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + # required up here when default value is not given + _path_to_item = kwargs.pop('_path_to_item', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if 'value' in kwargs: + value = kwargs.pop('value') + elif args: + args = list(args) + value = args.pop(0) + else: + raise ApiTypeError( + "value is required, but not passed in args or kwargs and doesn't have default", + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + self.value = value + if kwargs: + raise ApiTypeError( + "Invalid named arguments=%s passed to %s. Remove those invalid named arguments." % ( + kwargs, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + return self diff --git a/sdks/python/dropbox_sign/model/fax_line_create_request.py b/sdks/python/dropbox_sign/model/fax_line_create_request.py new file mode 100644 index 000000000..46d9c8b3a --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_create_request.py @@ -0,0 +1,337 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError +if TYPE_CHECKING: + from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum + + +def lazy_import(): + from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum + globals()['FaxLineAreaCodeGetCountryEnum'] = FaxLineAreaCodeGetCountryEnum + + +class FaxLineCreateRequest(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + lazy_import() + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + lazy_import() + return { + 'area_code': (str,), # noqa: E501 + 'country': (FaxLineAreaCodeGetCountryEnum,), # noqa: E501 + 'city': (str,), # noqa: E501 + 'account_id': (str,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineCreateRequest: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineCreateRequest], + _check_type=True, + ) + + attribute_map = { + 'area_code': 'area_code', # noqa: E501 + 'country': 'country', # noqa: E501 + 'city': 'city', # noqa: E501 + 'account_id': 'account_id', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def area_code(self) -> str: + return self.get("area_code") + + @area_code.setter + def area_code(self, value: str): + setattr(self, "area_code", value) + + @property + def country(self) -> FaxLineAreaCodeGetCountryEnum: + return self.get("country") + + @country.setter + def country(self, value: FaxLineAreaCodeGetCountryEnum): + setattr(self, "country", value) + + @property + def city(self) -> str: + return self.get("city") + + @city.setter + def city(self, value: str): + setattr(self, "city", value) + + @property + def account_id(self) -> str: + return self.get("account_id") + + @account_id.setter + def account_id(self, value: str): + setattr(self, "account_id", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, area_code, country, city, *args, **kwargs): # noqa: E501 + """FaxLineCreateRequest - a model defined in OpenAPI + + Args: + area_code (str): Area code + country (FaxLineAreaCodeGetCountryEnum): + city (str): City + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + account_id (str): Account ID. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.area_code = area_code + self.country = country + self.city = city + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, area_code, country, city, *args, **kwargs): # noqa: E501 + """FaxLineCreateRequest - a model defined in OpenAPI + + Args: + area_code (str): Area code + country (FaxLineAreaCodeGetCountryEnum): + city (str): City + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + account_id (str): Account ID. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.area_code = area_code + self.country = country + self.city = city + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_delete_request.py b/sdks/python/dropbox_sign/model/fax_line_delete_request.py new file mode 100644 index 000000000..68605d0ce --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_delete_request.py @@ -0,0 +1,289 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineDeleteRequest(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'number': (str,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineDeleteRequest: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineDeleteRequest], + _check_type=True, + ) + + attribute_map = { + 'number': 'number', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def number(self) -> str: + return self.get("number") + + @number.setter + def number(self, value: str): + setattr(self, "number", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, number, *args, **kwargs): # noqa: E501 + """FaxLineDeleteRequest - a model defined in OpenAPI + + Args: + number (str): The Fax Line number. + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.number = number + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, number, *args, **kwargs): # noqa: E501 + """FaxLineDeleteRequest - a model defined in OpenAPI + + Args: + number (str): The Fax Line number. + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.number = number + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_list_response.py b/sdks/python/dropbox_sign/model/fax_line_list_response.py new file mode 100644 index 000000000..1cdfd68af --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_list_response.py @@ -0,0 +1,321 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError +if TYPE_CHECKING: + from dropbox_sign.model.fax_line_response import FaxLineResponse + from dropbox_sign.model.list_info_response import ListInfoResponse + from dropbox_sign.model.warning_response import WarningResponse + + +def lazy_import(): + from dropbox_sign.model.fax_line_response import FaxLineResponse + from dropbox_sign.model.list_info_response import ListInfoResponse + from dropbox_sign.model.warning_response import WarningResponse + globals()['FaxLineResponse'] = FaxLineResponse + globals()['ListInfoResponse'] = ListInfoResponse + globals()['WarningResponse'] = WarningResponse + + +class FaxLineListResponse(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + lazy_import() + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + lazy_import() + return { + 'list_info': (ListInfoResponse,), # noqa: E501 + 'fax_lines': ([FaxLineResponse],), # noqa: E501 + 'warnings': (WarningResponse,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineListResponse: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineListResponse], + _check_type=True, + ) + + attribute_map = { + 'list_info': 'list_info', # noqa: E501 + 'fax_lines': 'fax_lines', # noqa: E501 + 'warnings': 'warnings', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def list_info(self) -> ListInfoResponse: + return self.get("list_info") + + @list_info.setter + def list_info(self, value: ListInfoResponse): + setattr(self, "list_info", value) + + @property + def fax_lines(self) -> List[FaxLineResponse]: + return self.get("fax_lines") + + @fax_lines.setter + def fax_lines(self, value: List[FaxLineResponse]): + setattr(self, "fax_lines", value) + + @property + def warnings(self) -> WarningResponse: + return self.get("warnings") + + @warnings.setter + def warnings(self, value: WarningResponse): + setattr(self, "warnings", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """FaxLineListResponse - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + list_info (ListInfoResponse): [optional] # noqa: E501 + fax_lines ([FaxLineResponse]): [optional] # noqa: E501 + warnings (WarningResponse): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): # noqa: E501 + """FaxLineListResponse - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + list_info (ListInfoResponse): [optional] # noqa: E501 + fax_lines ([FaxLineResponse]): [optional] # noqa: E501 + warnings (WarningResponse): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_remove_user_request.py b/sdks/python/dropbox_sign/model/fax_line_remove_user_request.py new file mode 100644 index 000000000..7867fa69a --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_remove_user_request.py @@ -0,0 +1,313 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError + + + +class FaxLineRemoveUserRequest(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'number': (str,), # noqa: E501 + 'account_id': (str,), # noqa: E501 + 'email_address': (str,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineRemoveUserRequest: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineRemoveUserRequest], + _check_type=True, + ) + + attribute_map = { + 'number': 'number', # noqa: E501 + 'account_id': 'account_id', # noqa: E501 + 'email_address': 'email_address', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def number(self) -> str: + return self.get("number") + + @number.setter + def number(self, value: str): + setattr(self, "number", value) + + @property + def account_id(self) -> str: + return self.get("account_id") + + @account_id.setter + def account_id(self, value: str): + setattr(self, "account_id", value) + + @property + def email_address(self) -> str: + return self.get("email_address") + + @email_address.setter + def email_address(self, value: str): + setattr(self, "email_address", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, number, *args, **kwargs): # noqa: E501 + """FaxLineRemoveUserRequest - a model defined in OpenAPI + + Args: + number (str): The Fax Line number. + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + account_id (str): Account ID. [optional] # noqa: E501 + email_address (str): Email address. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.number = number + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, number, *args, **kwargs): # noqa: E501 + """FaxLineRemoveUserRequest - a model defined in OpenAPI + + Args: + number (str): The Fax Line number. + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + account_id (str): Account ID. [optional] # noqa: E501 + email_address (str): Email address. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.number = number + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_response.py b/sdks/python/dropbox_sign/model/fax_line_response.py new file mode 100644 index 000000000..d6519a1ba --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_response.py @@ -0,0 +1,303 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError +if TYPE_CHECKING: + from dropbox_sign.model.warning_response import WarningResponse + + +def lazy_import(): + from dropbox_sign.model.warning_response import WarningResponse + globals()['WarningResponse'] = WarningResponse + + +class FaxLineResponse(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + lazy_import() + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + lazy_import() + return { + 'fax_line': (FaxLineResponse,), # noqa: E501 + 'warnings': (WarningResponse,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineResponse: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineResponse], + _check_type=True, + ) + + attribute_map = { + 'fax_line': 'fax_line', # noqa: E501 + 'warnings': 'warnings', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def fax_line(self) -> FaxLineResponse: + return self.get("fax_line") + + @fax_line.setter + def fax_line(self, value: FaxLineResponse): + setattr(self, "fax_line", value) + + @property + def warnings(self) -> WarningResponse: + return self.get("warnings") + + @warnings.setter + def warnings(self, value: WarningResponse): + setattr(self, "warnings", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """FaxLineResponse - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + fax_line (FaxLineResponse): [optional] # noqa: E501 + warnings (WarningResponse): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): # noqa: E501 + """FaxLineResponse - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + fax_line (FaxLineResponse): [optional] # noqa: E501 + warnings (WarningResponse): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/models/__init__.py b/sdks/python/dropbox_sign/models/__init__.py index 81a97b084..939e5a2f2 100644 --- a/sdks/python/dropbox_sign/models/__init__.py +++ b/sdks/python/dropbox_sign/models/__init__.py @@ -43,6 +43,16 @@ from dropbox_sign.model.event_callback_request import EventCallbackRequest from dropbox_sign.model.event_callback_request_event import EventCallbackRequestEvent from dropbox_sign.model.event_callback_request_event_metadata import EventCallbackRequestEventMetadata +from dropbox_sign.model.fax_line_add_user_request import FaxLineAddUserRequest +from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum +from dropbox_sign.model.fax_line_area_code_get_province_enum import FaxLineAreaCodeGetProvinceEnum +from dropbox_sign.model.fax_line_area_code_get_response import FaxLineAreaCodeGetResponse +from dropbox_sign.model.fax_line_area_code_get_state_enum import FaxLineAreaCodeGetStateEnum +from dropbox_sign.model.fax_line_create_request import FaxLineCreateRequest +from dropbox_sign.model.fax_line_delete_request import FaxLineDeleteRequest +from dropbox_sign.model.fax_line_list_response import FaxLineListResponse +from dropbox_sign.model.fax_line_remove_user_request import FaxLineRemoveUserRequest +from dropbox_sign.model.fax_line_response import FaxLineResponse from dropbox_sign.model.file_response import FileResponse from dropbox_sign.model.file_response_data_uri import FileResponseDataUri from dropbox_sign.model.list_info_response import ListInfoResponse diff --git a/sdks/ruby/.openapi-generator/FILES b/sdks/ruby/.openapi-generator/FILES index f02adf49e..2e8de743e 100644 --- a/sdks/ruby/.openapi-generator/FILES +++ b/sdks/ruby/.openapi-generator/FILES @@ -45,6 +45,17 @@ docs/ErrorResponseError.md docs/EventCallbackRequest.md docs/EventCallbackRequestEvent.md docs/EventCallbackRequestEventMetadata.md +docs/FaxLineAddUserRequest.md +docs/FaxLineApi.md +docs/FaxLineAreaCodeGetCountryEnum.md +docs/FaxLineAreaCodeGetProvinceEnum.md +docs/FaxLineAreaCodeGetResponse.md +docs/FaxLineAreaCodeGetStateEnum.md +docs/FaxLineCreateRequest.md +docs/FaxLineDeleteRequest.md +docs/FaxLineListResponse.md +docs/FaxLineRemoveUserRequest.md +docs/FaxLineResponse.md docs/FileResponse.md docs/FileResponseDataUri.md docs/ListInfoResponse.md @@ -195,6 +206,7 @@ lib/dropbox-sign/api/account_api.rb lib/dropbox-sign/api/api_app_api.rb lib/dropbox-sign/api/bulk_send_job_api.rb lib/dropbox-sign/api/embedded_api.rb +lib/dropbox-sign/api/fax_line_api.rb lib/dropbox-sign/api/o_auth_api.rb lib/dropbox-sign/api/report_api.rb lib/dropbox-sign/api/signature_request_api.rb @@ -239,6 +251,16 @@ lib/dropbox-sign/models/error_response_error.rb lib/dropbox-sign/models/event_callback_request.rb lib/dropbox-sign/models/event_callback_request_event.rb lib/dropbox-sign/models/event_callback_request_event_metadata.rb +lib/dropbox-sign/models/fax_line_add_user_request.rb +lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb +lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb +lib/dropbox-sign/models/fax_line_area_code_get_response.rb +lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb +lib/dropbox-sign/models/fax_line_create_request.rb +lib/dropbox-sign/models/fax_line_delete_request.rb +lib/dropbox-sign/models/fax_line_list_response.rb +lib/dropbox-sign/models/fax_line_remove_user_request.rb +lib/dropbox-sign/models/fax_line_response.rb lib/dropbox-sign/models/file_response.rb lib/dropbox-sign/models/file_response_data_uri.rb lib/dropbox-sign/models/list_info_response.rb diff --git a/sdks/ruby/README.md b/sdks/ruby/README.md index 784af10dc..34e6972f7 100644 --- a/sdks/ruby/README.md +++ b/sdks/ruby/README.md @@ -120,6 +120,13 @@ All URIs are relative to *https://api.hellosign.com/v3* |*Dropbox::Sign::BulkSendJobApi* | [**bulk_send_job_list**](docs/BulkSendJobApi.md#bulk_send_job_list) | **GET** /bulk_send_job/list | List Bulk Send Jobs | |*Dropbox::Sign::EmbeddedApi* | [**embedded_edit_url**](docs/EmbeddedApi.md#embedded_edit_url) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL | |*Dropbox::Sign::EmbeddedApi* | [**embedded_sign_url**](docs/EmbeddedApi.md#embedded_sign_url) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_add_user**](docs/FaxLineApi.md#fax_line_add_user) | **POST** /fax_line/add_user | Add Fax Line User | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_area_code_get**](docs/FaxLineApi.md#fax_line_area_code_get) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_create**](docs/FaxLineApi.md#fax_line_create) | **POST** /fax_line/create | Purchase Fax Line | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_delete**](docs/FaxLineApi.md#fax_line_delete) | **DELETE** /fax_line/delete | Delete Fax Line | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_get**](docs/FaxLineApi.md#fax_line_get) | **GET** /fax_line/{number} | Get Fax Line | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_list**](docs/FaxLineApi.md#fax_line_list) | **GET** /fax_line/list | List Fax Lines | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_remove_user**](docs/FaxLineApi.md#fax_line_remove_user) | **POST** /fax_line/remove_user | Remove Fax Line Access | |*Dropbox::Sign::OAuthApi* | [**oauth_token_generate**](docs/OAuthApi.md#oauth_token_generate) | **POST** /oauth/token | OAuth Token Generate | |*Dropbox::Sign::OAuthApi* | [**oauth_token_refresh**](docs/OAuthApi.md#oauth_token_refresh) | **POST** /oauth/token?refresh | OAuth Token Refresh | |*Dropbox::Sign::ReportApi* | [**report_create**](docs/ReportApi.md#report_create) | **POST** /report/create | Create Report | @@ -202,6 +209,16 @@ All URIs are relative to *https://api.hellosign.com/v3* - [Dropbox::Sign::EventCallbackRequest](docs/EventCallbackRequest.md) - [Dropbox::Sign::EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [Dropbox::Sign::EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [Dropbox::Sign::FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) + - [Dropbox::Sign::FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) + - [Dropbox::Sign::FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) + - [Dropbox::Sign::FaxLineAreaCodeGetResponse](docs/FaxLineAreaCodeGetResponse.md) + - [Dropbox::Sign::FaxLineAreaCodeGetStateEnum](docs/FaxLineAreaCodeGetStateEnum.md) + - [Dropbox::Sign::FaxLineCreateRequest](docs/FaxLineCreateRequest.md) + - [Dropbox::Sign::FaxLineDeleteRequest](docs/FaxLineDeleteRequest.md) + - [Dropbox::Sign::FaxLineListResponse](docs/FaxLineListResponse.md) + - [Dropbox::Sign::FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) + - [Dropbox::Sign::FaxLineResponse](docs/FaxLineResponse.md) - [Dropbox::Sign::FileResponse](docs/FileResponse.md) - [Dropbox::Sign::FileResponseDataUri](docs/FileResponseDataUri.md) - [Dropbox::Sign::ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/ruby/docs/FaxLineAddUserRequest.md b/sdks/ruby/docs/FaxLineAddUserRequest.md new file mode 100644 index 000000000..272d38367 --- /dev/null +++ b/sdks/ruby/docs/FaxLineAddUserRequest.md @@ -0,0 +1,12 @@ +# Dropbox::Sign::FaxLineAddUserRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number`*_required_ | ```String``` | The Fax Line number. | | +| `account_id` | ```String``` | Account ID | | +| `email_address` | ```String``` | Email address | | + diff --git a/sdks/ruby/docs/FaxLineApi.md b/sdks/ruby/docs/FaxLineApi.md new file mode 100644 index 000000000..186d7fbc8 --- /dev/null +++ b/sdks/ruby/docs/FaxLineApi.md @@ -0,0 +1,384 @@ +# Dropbox::Sign::FaxLineApi + +All URIs are relative to *https://api.hellosign.com/v3* + +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [`fax_line_add_user`](FaxLineApi.md#fax_line_add_user) | **POST** `/fax_line/add_user` | Add Fax Line User | +| [`fax_line_area_code_get`](FaxLineApi.md#fax_line_area_code_get) | **GET** `/fax_line/area_codes` | Get Available Fax Line Area Codes | +| [`fax_line_create`](FaxLineApi.md#fax_line_create) | **POST** `/fax_line/create` | Purchase Fax Line | +| [`fax_line_delete`](FaxLineApi.md#fax_line_delete) | **DELETE** `/fax_line/delete` | Delete Fax Line | +| [`fax_line_get`](FaxLineApi.md#fax_line_get) | **GET** `/fax_line/{number}` | Get Fax Line | +| [`fax_line_list`](FaxLineApi.md#fax_line_list) | **GET** `/fax_line/list` | List Fax Lines | +| [`fax_line_remove_user`](FaxLineApi.md#fax_line_remove_user) | **POST** `/fax_line/remove_user` | Remove Fax Line Access | + + +## `fax_line_add_user` + +> ` fax_line_add_user(fax_line_add_user_request)` + +Add Fax Line User + +Grants a user access to the specified Fax Line. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_add_user_with_http_info` variant + +This returns an Array which contains the response data, status code and headers. + +> `, Integer, Hash)> fax_line_add_user_with_http_info(fax_line_add_user_request)` + +```ruby +begin + # Add Fax Line User + data, status_code, headers = api_instance.fax_line_add_user_with_http_info(fax_line_add_user_request) + p status_code # => 2xx + p headers # => { ... } + p data # => +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_add_user_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_add_user_request` | [**FaxLineAddUserRequest**](FaxLineAddUserRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +## `fax_line_area_code_get` + +> ` fax_line_area_code_get(country, opts)` + +Get Available Fax Line Area Codes + +Returns a response with the area codes available for a given state/provice and city. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_area_code_get_with_http_info` variant + +This returns an Array which contains the response data, status code and headers. + +> `, Integer, Hash)> fax_line_area_code_get_with_http_info(country, opts)` + +```ruby +begin + # Get Available Fax Line Area Codes + data, status_code, headers = api_instance.fax_line_area_code_get_with_http_info(country, opts) + p status_code # => 2xx + p headers # => { ... } + p data # => +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_area_code_get_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `country` | [**FaxLineAreaCodeGetCountryEnum**](.md) | Filter area codes by country. | | +| `state` | [**FaxLineAreaCodeGetStateEnum**](.md) | Filter area codes by state. | [optional] | +| `province` | [**FaxLineAreaCodeGetProvinceEnum**](.md) | Filter area codes by province. | [optional] | +| `city` | **String** | Filter area codes by city. | [optional] | + +### Return type + +[**FaxLineAreaCodeGetResponse**](FaxLineAreaCodeGetResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +## `fax_line_create` + +> ` fax_line_create(fax_line_create_request)` + +Purchase Fax Line + +Purchases a new Fax Line. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_create_with_http_info` variant + +This returns an Array which contains the response data, status code and headers. + +> `, Integer, Hash)> fax_line_create_with_http_info(fax_line_create_request)` + +```ruby +begin + # Purchase Fax Line + data, status_code, headers = api_instance.fax_line_create_with_http_info(fax_line_create_request) + p status_code # => 2xx + p headers # => { ... } + p data # => +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_create_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_create_request` | [**FaxLineCreateRequest**](FaxLineCreateRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +## `fax_line_delete` + +> `fax_line_delete(fax_line_delete_request)` + +Delete Fax Line + +Deletes the specified Fax Line from the subscription. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_delete_with_http_info` variant + +This returns an Array which contains the response data (`nil` in this case), status code and headers. + +> ` fax_line_delete_with_http_info(fax_line_delete_request)` + +```ruby +begin + # Delete Fax Line + data, status_code, headers = api_instance.fax_line_delete_with_http_info(fax_line_delete_request) + p status_code # => 2xx + p headers # => { ... } + p data # => nil +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_delete_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_delete_request` | [**FaxLineDeleteRequest**](FaxLineDeleteRequest.md) | | | + +### Return type + +nil (empty response body) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + + +## `fax_line_get` + +> ` fax_line_get(number)` + +Get Fax Line + +Returns the properties and settings of a Fax Line. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_get_with_http_info` variant + +This returns an Array which contains the response data, status code and headers. + +> `, Integer, Hash)> fax_line_get_with_http_info(number)` + +```ruby +begin + # Get Fax Line + data, status_code, headers = api_instance.fax_line_get_with_http_info(number) + p status_code # => 2xx + p headers # => { ... } + p data # => +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_get_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number` | **String** | The Fax Line number. | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +## `fax_line_list` + +> ` fax_line_list(opts)` + +List Fax Lines + +Returns the properties and settings of multiple Fax Lines. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_list_with_http_info` variant + +This returns an Array which contains the response data, status code and headers. + +> `, Integer, Hash)> fax_line_list_with_http_info(opts)` + +```ruby +begin + # List Fax Lines + data, status_code, headers = api_instance.fax_line_list_with_http_info(opts) + p status_code # => 2xx + p headers # => { ... } + p data # => +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_list_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `account_id` | **String** | Account ID | [optional] | +| `page` | **Integer** | Page | [optional] | +| `page_size` | **Integer** | Page size | [optional] | +| `show_team_lines` | **Boolean** | Show team lines | [optional] | + +### Return type + +[**FaxLineListResponse**](FaxLineListResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + +## `fax_line_remove_user` + +> ` fax_line_remove_user(fax_line_remove_user_request)` + +Remove Fax Line Access + +Removes a user's access to the specified Fax Line. + +### Examples + +```ruby + +``` + +#### Using the `fax_line_remove_user_with_http_info` variant + +This returns an Array which contains the response data, status code and headers. + +> `, Integer, Hash)> fax_line_remove_user_with_http_info(fax_line_remove_user_request)` + +```ruby +begin + # Remove Fax Line Access + data, status_code, headers = api_instance.fax_line_remove_user_with_http_info(fax_line_remove_user_request) + p status_code # => 2xx + p headers # => { ... } + p data # => +rescue Dropbox::Sign::ApiError => e + puts "Error when calling FaxLineApi->fax_line_remove_user_with_http_info: #{e}" +end +``` + +### Parameters + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line_remove_user_request` | [**FaxLineRemoveUserRequest**](FaxLineRemoveUserRequest.md) | | | + +### Return type + +[**FaxLineResponse**](FaxLineResponse.md) + +### Authorization + +[api_key](../README.md#api_key) + +### HTTP request headers + +- **Content-Type**: application/json +- **Accept**: application/json + diff --git a/sdks/ruby/docs/FaxLineAreaCodeGetCountryEnum.md b/sdks/ruby/docs/FaxLineAreaCodeGetCountryEnum.md new file mode 100644 index 000000000..1b6b5aaa5 --- /dev/null +++ b/sdks/ruby/docs/FaxLineAreaCodeGetCountryEnum.md @@ -0,0 +1,9 @@ +# Dropbox::Sign::FaxLineAreaCodeGetCountryEnum + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + diff --git a/sdks/ruby/docs/FaxLineAreaCodeGetProvinceEnum.md b/sdks/ruby/docs/FaxLineAreaCodeGetProvinceEnum.md new file mode 100644 index 000000000..26d51f7c1 --- /dev/null +++ b/sdks/ruby/docs/FaxLineAreaCodeGetProvinceEnum.md @@ -0,0 +1,9 @@ +# Dropbox::Sign::FaxLineAreaCodeGetProvinceEnum + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + diff --git a/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md b/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md new file mode 100644 index 000000000..aeef0a852 --- /dev/null +++ b/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md @@ -0,0 +1,10 @@ +# Dropbox::Sign::FaxLineAreaCodeGetResponse + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `area_codes` | ```Array``` | | | + diff --git a/sdks/ruby/docs/FaxLineAreaCodeGetStateEnum.md b/sdks/ruby/docs/FaxLineAreaCodeGetStateEnum.md new file mode 100644 index 000000000..92f903f1c --- /dev/null +++ b/sdks/ruby/docs/FaxLineAreaCodeGetStateEnum.md @@ -0,0 +1,9 @@ +# Dropbox::Sign::FaxLineAreaCodeGetStateEnum + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + diff --git a/sdks/ruby/docs/FaxLineCreateRequest.md b/sdks/ruby/docs/FaxLineCreateRequest.md new file mode 100644 index 000000000..ef5d25f6a --- /dev/null +++ b/sdks/ruby/docs/FaxLineCreateRequest.md @@ -0,0 +1,13 @@ +# Dropbox::Sign::FaxLineCreateRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `area_code`*_required_ | ```String``` | Area code | | +| `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `city`*_required_ | ```String``` | City | | +| `account_id` | ```String``` | Account ID | | + diff --git a/sdks/ruby/docs/FaxLineDeleteRequest.md b/sdks/ruby/docs/FaxLineDeleteRequest.md new file mode 100644 index 000000000..5c781f3b4 --- /dev/null +++ b/sdks/ruby/docs/FaxLineDeleteRequest.md @@ -0,0 +1,10 @@ +# Dropbox::Sign::FaxLineDeleteRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number`*_required_ | ```String``` | The Fax Line number. | | + diff --git a/sdks/ruby/docs/FaxLineListResponse.md b/sdks/ruby/docs/FaxLineListResponse.md new file mode 100644 index 000000000..66926434b --- /dev/null +++ b/sdks/ruby/docs/FaxLineListResponse.md @@ -0,0 +1,12 @@ +# Dropbox::Sign::FaxLineListResponse + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `list_info` | [```ListInfoResponse```](ListInfoResponse.md) | | | +| `fax_lines` | [```Array```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + diff --git a/sdks/ruby/docs/FaxLineRemoveUserRequest.md b/sdks/ruby/docs/FaxLineRemoveUserRequest.md new file mode 100644 index 000000000..98388f6f4 --- /dev/null +++ b/sdks/ruby/docs/FaxLineRemoveUserRequest.md @@ -0,0 +1,12 @@ +# Dropbox::Sign::FaxLineRemoveUserRequest + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number`*_required_ | ```String``` | The Fax Line number. | | +| `account_id` | ```String``` | Account ID | | +| `email_address` | ```String``` | Email address | | + diff --git a/sdks/ruby/docs/FaxLineResponse.md b/sdks/ruby/docs/FaxLineResponse.md new file mode 100644 index 000000000..4e0a70149 --- /dev/null +++ b/sdks/ruby/docs/FaxLineResponse.md @@ -0,0 +1,11 @@ +# Dropbox::Sign::FaxLineResponse + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `fax_line` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `warnings` | [```WarningResponse```](WarningResponse.md) | | | + diff --git a/sdks/ruby/lib/dropbox-sign.rb b/sdks/ruby/lib/dropbox-sign.rb index 9e790e34b..9514e0cf3 100644 --- a/sdks/ruby/lib/dropbox-sign.rb +++ b/sdks/ruby/lib/dropbox-sign.rb @@ -51,6 +51,16 @@ require 'dropbox-sign/models/event_callback_request' require 'dropbox-sign/models/event_callback_request_event' require 'dropbox-sign/models/event_callback_request_event_metadata' +require 'dropbox-sign/models/fax_line_add_user_request' +require 'dropbox-sign/models/fax_line_area_code_get_country_enum' +require 'dropbox-sign/models/fax_line_area_code_get_province_enum' +require 'dropbox-sign/models/fax_line_area_code_get_response' +require 'dropbox-sign/models/fax_line_area_code_get_state_enum' +require 'dropbox-sign/models/fax_line_create_request' +require 'dropbox-sign/models/fax_line_delete_request' +require 'dropbox-sign/models/fax_line_list_response' +require 'dropbox-sign/models/fax_line_remove_user_request' +require 'dropbox-sign/models/fax_line_response' require 'dropbox-sign/models/file_response' require 'dropbox-sign/models/file_response_data_uri' require 'dropbox-sign/models/list_info_response' @@ -195,6 +205,7 @@ require 'dropbox-sign/api/api_app_api' require 'dropbox-sign/api/bulk_send_job_api' require 'dropbox-sign/api/embedded_api' +require 'dropbox-sign/api/fax_line_api' require 'dropbox-sign/api/o_auth_api' require 'dropbox-sign/api/report_api' require 'dropbox-sign/api/signature_request_api' diff --git a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb new file mode 100644 index 000000000..8d1863eab --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb @@ -0,0 +1,732 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'cgi' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineApi + attr_accessor :api_client + + def initialize(api_client = ApiClient.default) + @api_client = api_client + end + # Add Fax Line User + # Grants a user access to the specified Fax Line. + # @param fax_line_add_user_request [FaxLineAddUserRequest] + # @param [Hash] opts the optional parameters + # @return [FaxLineResponse] + def fax_line_add_user(fax_line_add_user_request, opts = {}) + data, _status_code, _headers = fax_line_add_user_with_http_info(fax_line_add_user_request, opts) + data + end + + # Add Fax Line User + # Grants a user access to the specified Fax Line. + # @param fax_line_add_user_request [FaxLineAddUserRequest] + # @param [Hash] opts the optional parameters + # @return [Array<(FaxLineResponse, Integer, Hash)>] FaxLineResponse data, response status code and response headers + def fax_line_add_user_with_http_info(fax_line_add_user_request, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_add_user ...' + end + # verify the required parameter 'fax_line_add_user_request' is set + if @api_client.config.client_side_validation && fax_line_add_user_request.nil? + fail ArgumentError, "Missing the required parameter 'fax_line_add_user_request' when calling FaxLineApi.fax_line_add_user" + end + # resource path + local_var_path = '/fax_line/add_user' + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end + + post_body = {} + form_params = opts[:form_params] || {} + result = @api_client.generate_form_data( + fax_line_add_user_request, + Dropbox::Sign::FaxLineAddUserRequest.openapi_types + ) + + # form parameters + if result[:has_file] + form_params = opts[:form_params] || result[:params] + header_params['Content-Type'] = 'multipart/form-data' + else + # http body (model) + post_body = opts[:debug_body] || result[:params] + end + + # return_type + return_type = opts[:debug_return_type] || 'FaxLineResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_add_user", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + if e.code === 200 + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::FaxLineResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + range_code = "4XX".split('').first + range_code_left = "#{range_code}00".to_i + range_code_right = "#{range_code}99".to_i + if e.code >= range_code_left && e.code <= range_code_right + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::ErrorResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_add_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Get Available Fax Line Area Codes + # Returns a response with the area codes available for a given state/provice and city. + # @param country [FaxLineAreaCodeGetCountryEnum] Filter area codes by country. + # @param [Hash] opts the optional parameters + # @option opts [FaxLineAreaCodeGetStateEnum] :state Filter area codes by state. + # @option opts [FaxLineAreaCodeGetProvinceEnum] :province Filter area codes by province. + # @option opts [String] :city Filter area codes by city. + # @return [FaxLineAreaCodeGetResponse] + def fax_line_area_code_get(country, opts = {}) + data, _status_code, _headers = fax_line_area_code_get_with_http_info(country, opts) + data + end + + # Get Available Fax Line Area Codes + # Returns a response with the area codes available for a given state/provice and city. + # @param country [FaxLineAreaCodeGetCountryEnum] Filter area codes by country. + # @param [Hash] opts the optional parameters + # @option opts [FaxLineAreaCodeGetStateEnum] :state Filter area codes by state. + # @option opts [FaxLineAreaCodeGetProvinceEnum] :province Filter area codes by province. + # @option opts [String] :city Filter area codes by city. + # @return [Array<(FaxLineAreaCodeGetResponse, Integer, Hash)>] FaxLineAreaCodeGetResponse data, response status code and response headers + def fax_line_area_code_get_with_http_info(country, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_area_code_get ...' + end + # verify the required parameter 'country' is set + if @api_client.config.client_side_validation && country.nil? + fail ArgumentError, "Missing the required parameter 'country' when calling FaxLineApi.fax_line_area_code_get" + end + # resource path + local_var_path = '/fax_line/area_codes' + + # query parameters + query_params = opts[:query_params] || {} + query_params[:'country'] = country + query_params[:'state'] = opts[:'state'] if !opts[:'state'].nil? + query_params[:'province'] = opts[:'province'] if !opts[:'province'].nil? + query_params[:'city'] = opts[:'city'] if !opts[:'city'].nil? + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + + post_body = {} + form_params = opts[:form_params] || {} + + # http body (model) + post_body = opts[:debug_body] + + # return_type + return_type = opts[:debug_return_type] || 'FaxLineAreaCodeGetResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_area_code_get", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + if e.code === 200 + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::FaxLineAreaCodeGetResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + range_code = "4XX".split('').first + range_code_left = "#{range_code}00".to_i + range_code_right = "#{range_code}99".to_i + if e.code >= range_code_left && e.code <= range_code_right + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::ErrorResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_area_code_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Purchase Fax Line + # Purchases a new Fax Line. + # @param fax_line_create_request [FaxLineCreateRequest] + # @param [Hash] opts the optional parameters + # @return [FaxLineResponse] + def fax_line_create(fax_line_create_request, opts = {}) + data, _status_code, _headers = fax_line_create_with_http_info(fax_line_create_request, opts) + data + end + + # Purchase Fax Line + # Purchases a new Fax Line. + # @param fax_line_create_request [FaxLineCreateRequest] + # @param [Hash] opts the optional parameters + # @return [Array<(FaxLineResponse, Integer, Hash)>] FaxLineResponse data, response status code and response headers + def fax_line_create_with_http_info(fax_line_create_request, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_create ...' + end + # verify the required parameter 'fax_line_create_request' is set + if @api_client.config.client_side_validation && fax_line_create_request.nil? + fail ArgumentError, "Missing the required parameter 'fax_line_create_request' when calling FaxLineApi.fax_line_create" + end + # resource path + local_var_path = '/fax_line/create' + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end + + post_body = {} + form_params = opts[:form_params] || {} + result = @api_client.generate_form_data( + fax_line_create_request, + Dropbox::Sign::FaxLineCreateRequest.openapi_types + ) + + # form parameters + if result[:has_file] + form_params = opts[:form_params] || result[:params] + header_params['Content-Type'] = 'multipart/form-data' + else + # http body (model) + post_body = opts[:debug_body] || result[:params] + end + + # return_type + return_type = opts[:debug_return_type] || 'FaxLineResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_create", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + if e.code === 200 + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::FaxLineResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + range_code = "4XX".split('').first + range_code_left = "#{range_code}00".to_i + range_code_right = "#{range_code}99".to_i + if e.code >= range_code_left && e.code <= range_code_right + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::ErrorResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Delete Fax Line + # Deletes the specified Fax Line from the subscription. + # @param fax_line_delete_request [FaxLineDeleteRequest] + # @param [Hash] opts the optional parameters + # @return [nil] + def fax_line_delete(fax_line_delete_request, opts = {}) + fax_line_delete_with_http_info(fax_line_delete_request, opts) + nil + end + + # Delete Fax Line + # Deletes the specified Fax Line from the subscription. + # @param fax_line_delete_request [FaxLineDeleteRequest] + # @param [Hash] opts the optional parameters + # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers + def fax_line_delete_with_http_info(fax_line_delete_request, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_delete ...' + end + # verify the required parameter 'fax_line_delete_request' is set + if @api_client.config.client_side_validation && fax_line_delete_request.nil? + fail ArgumentError, "Missing the required parameter 'fax_line_delete_request' when calling FaxLineApi.fax_line_delete" + end + # resource path + local_var_path = '/fax_line/delete' + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end + + post_body = {} + form_params = opts[:form_params] || {} + result = @api_client.generate_form_data( + fax_line_delete_request, + Dropbox::Sign::FaxLineDeleteRequest.openapi_types + ) + + # form parameters + if result[:has_file] + form_params = opts[:form_params] || result[:params] + header_params['Content-Type'] = 'multipart/form-data' + else + # http body (model) + post_body = opts[:debug_body] || result[:params] + end + + # return_type + return_type = opts[:debug_return_type] + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_delete", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Get Fax Line + # Returns the properties and settings of a Fax Line. + # @param number [String] The Fax Line number. + # @param [Hash] opts the optional parameters + # @return [FaxLineResponse] + def fax_line_get(number, opts = {}) + data, _status_code, _headers = fax_line_get_with_http_info(number, opts) + data + end + + # Get Fax Line + # Returns the properties and settings of a Fax Line. + # @param number [String] The Fax Line number. + # @param [Hash] opts the optional parameters + # @return [Array<(FaxLineResponse, Integer, Hash)>] FaxLineResponse data, response status code and response headers + def fax_line_get_with_http_info(number, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_get ...' + end + # verify the required parameter 'number' is set + if @api_client.config.client_side_validation && number.nil? + fail ArgumentError, "Missing the required parameter 'number' when calling FaxLineApi.fax_line_get" + end + # resource path + local_var_path = '/fax_line/{number}'.sub('{' + 'number' + '}', CGI.escape(number.to_s)) + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + + post_body = {} + form_params = opts[:form_params] || {} + + # http body (model) + post_body = opts[:debug_body] + + # return_type + return_type = opts[:debug_return_type] || 'FaxLineResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_get", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + if e.code === 200 + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::FaxLineResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + range_code = "4XX".split('').first + range_code_left = "#{range_code}00".to_i + range_code_right = "#{range_code}99".to_i + if e.code >= range_code_left && e.code <= range_code_right + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::ErrorResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # List Fax Lines + # Returns the properties and settings of multiple Fax Lines. + # @param [Hash] opts the optional parameters + # @option opts [String] :account_id Account ID + # @option opts [Integer] :page Page + # @option opts [Integer] :page_size Page size + # @option opts [Boolean] :show_team_lines Show team lines + # @return [FaxLineListResponse] + def fax_line_list(opts = {}) + data, _status_code, _headers = fax_line_list_with_http_info(opts) + data + end + + # List Fax Lines + # Returns the properties and settings of multiple Fax Lines. + # @param [Hash] opts the optional parameters + # @option opts [String] :account_id Account ID + # @option opts [Integer] :page Page + # @option opts [Integer] :page_size Page size + # @option opts [Boolean] :show_team_lines Show team lines + # @return [Array<(FaxLineListResponse, Integer, Hash)>] FaxLineListResponse data, response status code and response headers + def fax_line_list_with_http_info(opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_list ...' + end + # resource path + local_var_path = '/fax_line/list' + + # query parameters + query_params = opts[:query_params] || {} + query_params[:'account_id'] = opts[:'account_id'] if !opts[:'account_id'].nil? + query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? + query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? + query_params[:'show_team_lines'] = opts[:'show_team_lines'] if !opts[:'show_team_lines'].nil? + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + + post_body = {} + form_params = opts[:form_params] || {} + + # http body (model) + post_body = opts[:debug_body] + + # return_type + return_type = opts[:debug_return_type] || 'FaxLineListResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_list", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + if e.code === 200 + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::FaxLineListResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + range_code = "4XX".split('').first + range_code_left = "#{range_code}00".to_i + range_code_right = "#{range_code}99".to_i + if e.code >= range_code_left && e.code <= range_code_right + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::ErrorResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Remove Fax Line Access + # Removes a user's access to the specified Fax Line. + # @param fax_line_remove_user_request [FaxLineRemoveUserRequest] + # @param [Hash] opts the optional parameters + # @return [FaxLineResponse] + def fax_line_remove_user(fax_line_remove_user_request, opts = {}) + data, _status_code, _headers = fax_line_remove_user_with_http_info(fax_line_remove_user_request, opts) + data + end + + # Remove Fax Line Access + # Removes a user's access to the specified Fax Line. + # @param fax_line_remove_user_request [FaxLineRemoveUserRequest] + # @param [Hash] opts the optional parameters + # @return [Array<(FaxLineResponse, Integer, Hash)>] FaxLineResponse data, response status code and response headers + def fax_line_remove_user_with_http_info(fax_line_remove_user_request, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug 'Calling API: FaxLineApi.fax_line_remove_user ...' + end + # verify the required parameter 'fax_line_remove_user_request' is set + if @api_client.config.client_side_validation && fax_line_remove_user_request.nil? + fail ArgumentError, "Missing the required parameter 'fax_line_remove_user_request' when calling FaxLineApi.fax_line_remove_user" + end + # resource path + local_var_path = '/fax_line/remove_user' + + # query parameters + query_params = opts[:query_params] || {} + + # header parameters + header_params = opts[:header_params] || {} + # HTTP header 'Accept' (if needed) + header_params['Accept'] = @api_client.select_header_accept(['application/json']) + # HTTP header 'Content-Type' + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end + + post_body = {} + form_params = opts[:form_params] || {} + result = @api_client.generate_form_data( + fax_line_remove_user_request, + Dropbox::Sign::FaxLineRemoveUserRequest.openapi_types + ) + + # form parameters + if result[:has_file] + form_params = opts[:form_params] || result[:params] + header_params['Content-Type'] = 'multipart/form-data' + else + # http body (model) + post_body = opts[:debug_body] || result[:params] + end + + # return_type + return_type = opts[:debug_return_type] || 'FaxLineResponse' + + # auth_names + auth_names = opts[:debug_auth_names] || ['api_key'] + + new_options = opts.merge( + :operation => :"FaxLineApi.fax_line_remove_user", + :header_params => header_params, + :query_params => query_params, + :form_params => form_params, + :body => post_body, + :auth_names => auth_names, + :return_type => return_type + ) + + begin + data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options) + rescue Dropbox::Sign::ApiError => e + if e.code === 200 + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::FaxLineResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + range_code = "4XX".split('').first + range_code_left = "#{range_code}00".to_i + range_code_right = "#{range_code}99".to_i + if e.code >= range_code_left && e.code <= range_code_right + body = @api_client.convert_to_type( + JSON.parse("[#{e.response_body}]", :symbolize_names => true)[0], + "Dropbox::Sign::ErrorResponse" + ) + + fail ApiError.new(:code => e.code, + :response_headers => e.response_headers, + :response_body => body), + e.message + end + + end + + if @api_client.config.debugging + @api_client.config.logger.debug "API called: FaxLineApi#fax_line_remove_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + end +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb new file mode 100644 index 000000000..f8b80710e --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb @@ -0,0 +1,278 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineAddUserRequest + # The Fax Line number. + # @return [String] + attr_accessor :number + + # Account ID + # @return [String] + attr_accessor :account_id + + # Email address + # @return [String] + attr_accessor :email_address + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'number' => :'number', + :'account_id' => :'account_id', + :'email_address' => :'email_address' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'number' => :'String', + :'account_id' => :'String', + :'email_address' => :'String' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineAddUserRequest] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineAddUserRequest" + ) || FaxLineAddUserRequest.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineAddUserRequest` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineAddUserRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'number') + self.number = attributes[:'number'] + end + + if attributes.key?(:'account_id') + self.account_id = attributes[:'account_id'] + end + + if attributes.key?(:'email_address') + self.email_address = attributes[:'email_address'] + 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 @number.nil? + invalid_properties.push('invalid value for "number", number 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 @number.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 && + number == o.number && + account_id == o.account_id && + email_address == o.email_address + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [number, account_id, email_address].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb new file mode 100644 index 000000000..b50643325 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb @@ -0,0 +1,41 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineAreaCodeGetCountryEnum + CA = "CA".freeze + US = "US".freeze + UK = "UK".freeze + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def self.build_from_hash(value) + new.build_from_hash(value) + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def build_from_hash(value) + constantValues = FaxLineAreaCodeGetCountryEnum.constants.select { |c| FaxLineAreaCodeGetCountryEnum::const_get(c) == value } + raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetCountryEnum" if constantValues.empty? + value + end + end +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb new file mode 100644 index 000000000..4f9bbc725 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb @@ -0,0 +1,51 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineAreaCodeGetProvinceEnum + AB = "AB".freeze + BC = "BC".freeze + MB = "MB".freeze + NB = "NB".freeze + NL = "NL".freeze + NT = "NT".freeze + NS = "NS".freeze + NU = "NU".freeze + ON = "ON".freeze + PE = "PE".freeze + QC = "QC".freeze + SK = "SK".freeze + YT = "YT".freeze + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def self.build_from_hash(value) + new.build_from_hash(value) + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def build_from_hash(value) + constantValues = FaxLineAreaCodeGetProvinceEnum.constants.select { |c| FaxLineAreaCodeGetProvinceEnum::const_get(c) == value } + raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetProvinceEnum" if constantValues.empty? + value + end + end +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb new file mode 100644 index 000000000..d591832ae --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb @@ -0,0 +1,252 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineAreaCodeGetResponse + # @return [Array] + attr_accessor :area_codes + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'area_codes' => :'area_codes' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'area_codes' => :'Array' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineAreaCodeGetResponse] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineAreaCodeGetResponse" + ) || FaxLineAreaCodeGetResponse.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineAreaCodeGetResponse` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineAreaCodeGetResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'area_codes') + if (value = attributes[:'area_codes']).is_a?(Array) + self.area_codes = value + end + 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? + 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 && + area_codes == o.area_codes + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [area_codes].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb new file mode 100644 index 000000000..4f39fa531 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb @@ -0,0 +1,89 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineAreaCodeGetStateEnum + AK = "AK".freeze + AL = "AL".freeze + AR = "AR".freeze + AZ = "AZ".freeze + CA = "CA".freeze + CO = "CO".freeze + CT = "CT".freeze + DC = "DC".freeze + DE = "DE".freeze + FL = "FL".freeze + GA = "GA".freeze + HI = "HI".freeze + IA = "IA".freeze + ID = "ID".freeze + IL = "IL".freeze + IN = "IN".freeze + KS = "KS".freeze + KY = "KY".freeze + LA = "LA".freeze + MA = "MA".freeze + MD = "MD".freeze + ME = "ME".freeze + MI = "MI".freeze + MN = "MN".freeze + MO = "MO".freeze + MS = "MS".freeze + MT = "MT".freeze + NC = "NC".freeze + ND = "ND".freeze + NE = "NE".freeze + NH = "NH".freeze + NJ = "NJ".freeze + NM = "NM".freeze + NV = "NV".freeze + NY = "NY".freeze + OH = "OH".freeze + OK = "OK".freeze + OR = "OR".freeze + PA = "PA".freeze + RI = "RI".freeze + SC = "SC".freeze + SD = "SD".freeze + TN = "TN".freeze + TX = "TX".freeze + UT = "UT".freeze + VA = "VA".freeze + VT = "VT".freeze + WA = "WA".freeze + WI = "WI".freeze + WV = "WV".freeze + WY = "WY".freeze + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def self.build_from_hash(value) + new.build_from_hash(value) + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def build_from_hash(value) + constantValues = FaxLineAreaCodeGetStateEnum.constants.select { |c| FaxLineAreaCodeGetStateEnum::const_get(c) == value } + raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetStateEnum" if constantValues.empty? + value + end + end +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb new file mode 100644 index 000000000..fd9b9535b --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb @@ -0,0 +1,298 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineCreateRequest + # Area code + # @return [String] + attr_accessor :area_code + + # @return [FaxLineAreaCodeGetCountryEnum] + attr_accessor :country + + # City + # @return [String] + attr_accessor :city + + # Account ID + # @return [String] + attr_accessor :account_id + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'area_code' => :'area_code', + :'country' => :'country', + :'city' => :'city', + :'account_id' => :'account_id' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'area_code' => :'String', + :'country' => :'FaxLineAreaCodeGetCountryEnum', + :'city' => :'String', + :'account_id' => :'String' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineCreateRequest] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineCreateRequest" + ) || FaxLineCreateRequest.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineCreateRequest` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineCreateRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'area_code') + self.area_code = attributes[:'area_code'] + end + + if attributes.key?(:'country') + self.country = attributes[:'country'] + end + + if attributes.key?(:'city') + self.city = attributes[:'city'] + end + + if attributes.key?(:'account_id') + self.account_id = attributes[:'account_id'] + 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 @area_code.nil? + invalid_properties.push('invalid value for "area_code", area_code cannot be nil.') + end + + if @country.nil? + invalid_properties.push('invalid value for "country", country cannot be nil.') + end + + if @city.nil? + invalid_properties.push('invalid value for "city", city 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 @area_code.nil? + return false if @country.nil? + return false if @city.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 && + area_code == o.area_code && + country == o.country && + city == o.city && + account_id == o.account_id + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [area_code, country, city, account_id].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb new file mode 100644 index 000000000..765fc13b3 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb @@ -0,0 +1,256 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineDeleteRequest + # The Fax Line number. + # @return [String] + attr_accessor :number + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'number' => :'number' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'number' => :'String' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineDeleteRequest] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineDeleteRequest" + ) || FaxLineDeleteRequest.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineDeleteRequest` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineDeleteRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'number') + self.number = attributes[:'number'] + 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 @number.nil? + invalid_properties.push('invalid value for "number", number 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 @number.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 && + number == o.number + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [number].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb new file mode 100644 index 000000000..6e0d5bed5 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb @@ -0,0 +1,272 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineListResponse + # @return [ListInfoResponse] + attr_accessor :list_info + + # @return [Array] + attr_accessor :fax_lines + + # @return [WarningResponse] + attr_accessor :warnings + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'list_info' => :'list_info', + :'fax_lines' => :'fax_lines', + :'warnings' => :'warnings' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'list_info' => :'ListInfoResponse', + :'fax_lines' => :'Array', + :'warnings' => :'WarningResponse' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineListResponse] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineListResponse" + ) || FaxLineListResponse.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineListResponse` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineListResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'list_info') + self.list_info = attributes[:'list_info'] + end + + if attributes.key?(:'fax_lines') + if (value = attributes[:'fax_lines']).is_a?(Array) + self.fax_lines = value + end + end + + if attributes.key?(:'warnings') + self.warnings = attributes[:'warnings'] + 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? + 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 && + list_info == o.list_info && + fax_lines == o.fax_lines && + warnings == o.warnings + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [list_info, fax_lines, warnings].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb new file mode 100644 index 000000000..7a16181a8 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb @@ -0,0 +1,278 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineRemoveUserRequest + # The Fax Line number. + # @return [String] + attr_accessor :number + + # Account ID + # @return [String] + attr_accessor :account_id + + # Email address + # @return [String] + attr_accessor :email_address + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'number' => :'number', + :'account_id' => :'account_id', + :'email_address' => :'email_address' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'number' => :'String', + :'account_id' => :'String', + :'email_address' => :'String' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineRemoveUserRequest] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineRemoveUserRequest" + ) || FaxLineRemoveUserRequest.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineRemoveUserRequest` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineRemoveUserRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'number') + self.number = attributes[:'number'] + end + + if attributes.key?(:'account_id') + self.account_id = attributes[:'account_id'] + end + + if attributes.key?(:'email_address') + self.email_address = attributes[:'email_address'] + 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 @number.nil? + invalid_properties.push('invalid value for "number", number 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 @number.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 && + number == o.number && + account_id == o.account_id && + email_address == o.email_address + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [number, account_id, email_address].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb new file mode 100644 index 000000000..797a01cd2 --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb @@ -0,0 +1,260 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLineResponse + # @return [FaxLineResponse] + attr_accessor :fax_line + + # @return [WarningResponse] + attr_accessor :warnings + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'fax_line' => :'fax_line', + :'warnings' => :'warnings' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'fax_line' => :'FaxLineResponse', + :'warnings' => :'WarningResponse' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLineResponse] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLineResponse" + ) || FaxLineResponse.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineResponse` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'fax_line') + self.fax_line = attributes[:'fax_line'] + end + + if attributes.key?(:'warnings') + self.warnings = attributes[:'warnings'] + 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? + 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 && + fax_line == o.fax_line && + warnings == o.warnings + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [fax_line, warnings].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/translations/en.yaml b/translations/en.yaml index 2e8cd816a..cb5662e71 100644 --- a/translations/en.yaml +++ b/translations/en.yaml @@ -129,6 +129,41 @@ "EmbeddedSignUrl::DESCRIPTION": Retrieves an embedded object containing a signature url that can be opened in an iFrame. Note that templates created via the embedded template process will only be accessible through the API. "EmbeddedSignUrl::SIGNATURE_ID": The id of the signature to get a signature url for. +"FaxLineAddUser::SUMMARY": Add Fax Line User +"FaxLineAddUser::DESCRIPTION": Grants a user access to the specified Fax Line. +"FaxLineAreaCodeGet::SUMMARY": Get Available Fax Line Area Codes +"FaxLineAreaCodeGet::DESCRIPTION": Returns a response with the area codes available for a given state/provice and city. +"FaxLineAreaCodeGet::CITY": Filter area codes by city. +"FaxLineAreaCodeGet::STATE": Filter area codes by state. +"FaxLineAreaCodeGet::PROVINCE": Filter area codes by province. +"FaxLineAreaCodeGet::COUNTRY": Filter area codes by country. +"FaxLineCreate::SUMMARY": Purchase Fax Line +"FaxLineCreate::DESCRIPTION": Purchases a new Fax Line. +"FaxLineDelete::SUMMARY": Delete Fax Line +"FaxLineDelete::DESCRIPTION": Deletes the specified Fax Line from the subscription. +"FaxLineGet::SUMMARY": Get Fax Line +"FaxLineGet::DESCRIPTION": Returns the properties and settings of a Fax Line. +"FaxLineGet::NUMBER": The Fax Line number. +"FaxLineList::SUMMARY": List Fax Lines +"FaxLineList::DESCRIPTION": Returns the properties and settings of multiple Fax Lines. +"FaxLineList::ACCOUNT_ID": Account ID +"FaxLineList::PAGE": Page +"FaxLineList::PAGE_SIZE": Page size +"FaxLineList::SHOW_TEAM_LINES": Show team lines +"FaxLineRemoveUser::SUMMARY": Remove Fax Line Access +"FaxLineRemoveUser::DESCRIPTION": Removes a user's access to the specified Fax Line. +"FaxLineAddUser::NUMBER": The Fax Line number. +"FaxLineAddUser::ACCOUNT_ID": Account ID +"FaxLineCreate::EMAIL_ADDRESS": Email address +"FaxLineCreate::AREA_CODE": Area code +"FaxLineCreate::CITY": City +"FaxLineCreate::COUNTRY": Country +"FaxLineCreate::ACCOUNT_ID": Account ID +"FaxLineDelete::NUMBER": The Fax Line number. +"FaxLineResponseExample::SUMMARY": Sample Fax Line Response +"FaxLineAreaCodeGetResponseExample::SUMMARY": Sample Area Code Response +"FaxLineListResponseExample::SUMMARY": Sample Fax Line List Response + "OAuthTokenGenerate::SUMMARY": OAuth Token Generate "OAuthTokenGenerate::DESCRIPTION": Once you have retrieved the code from the user callback, you will need to exchange it for an access token via a backend call. "OAuthTokenGenerate::CLIENT_ID": The client id of the app requesting authorization. @@ -1617,6 +1652,20 @@ "EmbeddedEditUrl::SEO::DESCRIPTION": "The Dropbox Sign API allows you to build custom integrations. To find out how to retrieve an embedded iFrame object containing a template url, click here." "EmbeddedSignUrl::SEO::TITLE": "Get Embedded Sign URL | iFrame | Dropbox Sign for Developers" "EmbeddedSignUrl::SEO::DESCRIPTION": "The Dropbox Sign API allows you to build custom integrations. To find out how to retrieve an embedded iFrame object containing a signature url, click here." +"FaxLineAddUser::SEO::TITLE": "Fax Line Add User | API Documentation | Dropbox Fax for Developers" +"FaxLineAddUser::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to add a user to an existing fax line, click here." +"FaxLineAreaCodeGet::SEO::TITLE": "Fax Line Get Area Codes | API Documentation | Dropbox Fax for Developers" +"FaxLineAreaCodeGet::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here." +"FaxLineCreate::SEO::TITLE": "Purchase Fax Line | API Documentation | Dropbox Fax for Developers" +"FaxLineCreate::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here." +"FaxLineDelete::SEO::TITLE": "Delete Fax Line | API Documentation | Dropbox Fax for Developers" +"FaxLineDelete::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here." +"FaxLineGet::SEO::TITLE": "Get Fax Line | API Documentation | Dropbox Fax for Developers" +"FaxLineGet::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here." +"FaxLineList::SEO::TITLE": "List Fax Lines | API Documentation | Dropbox Fax for Developers" +"FaxLineList::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to list your fax lines, click here." +"FaxLineRemoveUser::SEO::TITLE": "Fax Line Remove User | API Documentation | Dropbox Fax for Developers" +"FaxLineRemoveUser::SEO::DESCRIPTION": "The Dropbox Fax API allows you to build custom integrations. To find out how to remove a user from an existing fax line, click here." "OAuthTokenGenerate::SEO::TITLE": "Generate OAuth Token | Documentation | Dropbox Sign for Developers" "OAuthTokenGenerate::SEO::DESCRIPTION": "The RESTful Dropbox Sign API easily allows you to build custom eSign integrations. To find out how to generate a new OAuth token with the API, click here." "OAuthTokenRefresh::SEO::TITLE": "OAuth Token Refresh | Documentation | Dropbox Sign for Developers" From e2996368943663cacb065d7798d9d51903cb4f41 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Tue, 13 Aug 2024 11:09:55 -0400 Subject: [PATCH 02/12] request and response examples --- .../json/FaxLineAddUserRequestExample.json | 4 +++ .../FaxLineAreaCodeGetResponseExample.json | 34 +++++++++++++++++++ .../json/FaxLineCreateRequestExample.json | 4 +++ .../json/FaxLineDeleteRequestExample.json | 3 ++ examples/json/FaxLineListResponseExample.json | 24 +++++++++++++ .../json/FaxLineRemoveUserRequestExample.json | 4 +++ examples/json/FaxLineResponseExample.json | 16 +++++++++ openapi-raw.yaml | 1 - openapi-sdk.yaml | 1 - openapi.yaml | 1 - 10 files changed, 89 insertions(+), 3 deletions(-) create mode 100644 examples/json/FaxLineAddUserRequestExample.json create mode 100644 examples/json/FaxLineAreaCodeGetResponseExample.json create mode 100644 examples/json/FaxLineCreateRequestExample.json create mode 100644 examples/json/FaxLineDeleteRequestExample.json create mode 100644 examples/json/FaxLineListResponseExample.json create mode 100644 examples/json/FaxLineRemoveUserRequestExample.json create mode 100644 examples/json/FaxLineResponseExample.json diff --git a/examples/json/FaxLineAddUserRequestExample.json b/examples/json/FaxLineAddUserRequestExample.json new file mode 100644 index 000000000..6c10a0a5f --- /dev/null +++ b/examples/json/FaxLineAddUserRequestExample.json @@ -0,0 +1,4 @@ +{ + "number": "[FAX_NUMBER]", + "email_address": "member@dropboxsign.com" +} \ No newline at end of file diff --git a/examples/json/FaxLineAreaCodeGetResponseExample.json b/examples/json/FaxLineAreaCodeGetResponseExample.json new file mode 100644 index 000000000..244cc210b --- /dev/null +++ b/examples/json/FaxLineAreaCodeGetResponseExample.json @@ -0,0 +1,34 @@ +{ + "area_codes": [ + "209", + "213", + "310", + "323", + "408", + "415", + "424", + "510", + "530", + "559", + "562", + "619", + "626", + "650", + "657", + "661", + "669", + "707", + "714", + "747", + "760", + "805", + "818", + "831", + "858", + "909", + "916", + "925", + "949", + "951" + ] +} \ No newline at end of file diff --git a/examples/json/FaxLineCreateRequestExample.json b/examples/json/FaxLineCreateRequestExample.json new file mode 100644 index 000000000..54641a7cb --- /dev/null +++ b/examples/json/FaxLineCreateRequestExample.json @@ -0,0 +1,4 @@ +{ + "area_code": "209", + "country": "US" +} \ No newline at end of file diff --git a/examples/json/FaxLineDeleteRequestExample.json b/examples/json/FaxLineDeleteRequestExample.json new file mode 100644 index 000000000..ef20a9cd2 --- /dev/null +++ b/examples/json/FaxLineDeleteRequestExample.json @@ -0,0 +1,3 @@ +{ + "number": "[FAX_NUMBER]", +} \ No newline at end of file diff --git a/examples/json/FaxLineListResponseExample.json b/examples/json/FaxLineListResponseExample.json new file mode 100644 index 000000000..da1ec2cbb --- /dev/null +++ b/examples/json/FaxLineListResponseExample.json @@ -0,0 +1,24 @@ +{ + "list_info": { + "num_pages": 1, + "num_results": 1, + "page": 1, + "page_size": 1 + }, + "fax_lines": [ + { + "number": "[FAX_NUMBER]", + "created_at": 1723231831, + "updated_at": 1723231831, + "accounts": [ + { + "account_id": "c2e9691c85d9d6fa6ae773842e3680b2b8650f1d", + "email_address": "me@dropboxsign.com", + "is_locked": false, + "is_paid_hs": false, + "is_paid_hf": true + } + ] + } + ] +} \ No newline at end of file diff --git a/examples/json/FaxLineRemoveUserRequestExample.json b/examples/json/FaxLineRemoveUserRequestExample.json new file mode 100644 index 000000000..6c10a0a5f --- /dev/null +++ b/examples/json/FaxLineRemoveUserRequestExample.json @@ -0,0 +1,4 @@ +{ + "number": "[FAX_NUMBER]", + "email_address": "member@dropboxsign.com" +} \ No newline at end of file diff --git a/examples/json/FaxLineResponseExample.json b/examples/json/FaxLineResponseExample.json new file mode 100644 index 000000000..8ba2454b8 --- /dev/null +++ b/examples/json/FaxLineResponseExample.json @@ -0,0 +1,16 @@ +{ + "fax_line": { + "number": "[FAX_NUMBER]", + "created_at": 1723231831, + "updated_at": 1723231831, + "accounts": [ + { + "account_id": "c2e9691c85d9d6fa6ae773842e3680b2b8650f1d", + "email_address": "me@dropboxsign.com", + "is_locked": false, + "is_paid_hs": false, + "is_paid_hf": true + } + ] + } +} \ No newline at end of file diff --git a/openapi-raw.yaml b/openapi-raw.yaml index 1b7cb300f..8d09e05e8 100644 --- a/openapi-raw.yaml +++ b/openapi-raw.yaml @@ -7137,7 +7137,6 @@ components: required: - area_code - country - - city properties: area_code: description: '_t__FaxLineCreate::AREA_CODE' diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index 0c6798e27..d013b2fb1 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -7231,7 +7231,6 @@ components: required: - area_code - country - - city properties: area_code: description: 'Area code' diff --git a/openapi.yaml b/openapi.yaml index 5bb23ff13..94a9b40aa 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -7231,7 +7231,6 @@ components: required: - area_code - country - - city properties: area_code: description: 'Area code' From ef84347e80ceca9fd88a817bafed0086c4c5e6e7 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Tue, 13 Aug 2024 13:08:22 -0400 Subject: [PATCH 03/12] sdk snippets --- examples/FaxLineAddUser.cs | 34 ++++++++++++++++++++++++++++++++ examples/FaxLineAddUser.java | 30 ++++++++++++++++++++++++++++ examples/FaxLineAddUser.js | 19 ++++++++++++++++++ examples/FaxLineAddUser.php | 23 +++++++++++++++++++++ examples/FaxLineAddUser.py | 23 +++++++++++++++++++++ examples/FaxLineAddUser.rb | 19 ++++++++++++++++++ examples/FaxLineAddUser.sh | 4 ++++ examples/FaxLineAddUser.ts | 19 ++++++++++++++++++ examples/FaxLineAreaCodeGet.cs | 29 +++++++++++++++++++++++++++ examples/FaxLineAreaCodeGet.java | 26 ++++++++++++++++++++++++ examples/FaxLineAreaCodeGet.js | 14 +++++++++++++ examples/FaxLineAreaCodeGet.php | 23 +++++++++++++++++++++ examples/FaxLineAreaCodeGet.py | 18 +++++++++++++++++ examples/FaxLineAreaCodeGet.rb | 15 ++++++++++++++ examples/FaxLineAreaCodeGet.sh | 4 ++++ examples/FaxLineAreaCodeGet.ts | 14 +++++++++++++ examples/FaxLineCreate.cs | 34 ++++++++++++++++++++++++++++++++ examples/FaxLineCreate.java | 30 ++++++++++++++++++++++++++++ examples/FaxLineCreate.js | 19 ++++++++++++++++++ examples/FaxLineCreate.php | 23 +++++++++++++++++++++ examples/FaxLineCreate.py | 23 +++++++++++++++++++++ examples/FaxLineCreate.rb | 19 ++++++++++++++++++ examples/FaxLineCreate.sh | 4 ++++ examples/FaxLineCreate.ts | 19 ++++++++++++++++++ examples/FaxLineDelete.cs | 33 +++++++++++++++++++++++++++++++ examples/FaxLineDelete.java | 28 ++++++++++++++++++++++++++ examples/FaxLineDelete.js | 18 +++++++++++++++++ examples/FaxLineDelete.php | 22 +++++++++++++++++++++ examples/FaxLineDelete.py | 22 +++++++++++++++++++++ examples/FaxLineDelete.rb | 18 +++++++++++++++++ examples/FaxLineDelete.sh | 3 +++ examples/FaxLineDelete.ts | 18 +++++++++++++++++ examples/FaxLineGet.cs | 29 +++++++++++++++++++++++++++ examples/FaxLineGet.java | 26 ++++++++++++++++++++++++ examples/FaxLineGet.js | 14 +++++++++++++ examples/FaxLineGet.php | 19 ++++++++++++++++++ examples/FaxLineGet.py | 18 +++++++++++++++++ examples/FaxLineGet.rb | 15 ++++++++++++++ examples/FaxLineGet.sh | 2 ++ examples/FaxLineGet.ts | 14 +++++++++++++ examples/FaxLineList.cs | 29 +++++++++++++++++++++++++++ examples/FaxLineList.java | 26 ++++++++++++++++++++++++ examples/FaxLineList.js | 14 +++++++++++++ examples/FaxLineList.php | 19 ++++++++++++++++++ examples/FaxLineList.py | 18 +++++++++++++++++ examples/FaxLineList.rb | 15 ++++++++++++++ examples/FaxLineList.sh | 2 ++ examples/FaxLineList.ts | 14 +++++++++++++ examples/FaxLineRemoveUser.cs | 34 ++++++++++++++++++++++++++++++++ examples/FaxLineRemoveUser.java | 30 ++++++++++++++++++++++++++++ examples/FaxLineRemoveUser.js | 19 ++++++++++++++++++ examples/FaxLineRemoveUser.php | 23 +++++++++++++++++++++ examples/FaxLineRemoveUser.py | 23 +++++++++++++++++++++ examples/FaxLineRemoveUser.rb | 19 ++++++++++++++++++ examples/FaxLineRemoveUser.sh | 4 ++++ examples/FaxLineRemoveUser.ts | 19 ++++++++++++++++++ 56 files changed, 1092 insertions(+) diff --git a/examples/FaxLineAddUser.cs b/examples/FaxLineAddUser.cs index e69de29bb..de22f454f 100644 --- a/examples/FaxLineAddUser.cs +++ b/examples/FaxLineAddUser.cs @@ -0,0 +1,34 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineAddUserRequest( + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com" + ); + + try + { + var result = faxLineApi.FaxLineAddUser(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineAddUser.java b/examples/FaxLineAddUser.java index e69de29bb..34e455d5a 100644 --- a/examples/FaxLineAddUser.java +++ b/examples/FaxLineAddUser.java @@ -0,0 +1,30 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineAddUserRequest() + .number("[FAX_NUMBER]") + .emailAddress("member@dropboxsign.com"); + + try { + FaxLineResponse result = faxLineApi.faxLineAddUser(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineAddUser.js b/examples/FaxLineAddUser.js index e69de29bb..84e1e2c0e 100644 --- a/examples/FaxLineAddUser.js +++ b/examples/FaxLineAddUser.js @@ -0,0 +1,19 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineAddUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineAddUser.php b/examples/FaxLineAddUser.php index e69de29bb..8fb6c0fef 100644 --- a/examples/FaxLineAddUser.php +++ b/examples/FaxLineAddUser.php @@ -0,0 +1,23 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineAddUserRequest(); +$data->setNumber("[FAX_NUMBER]") + ->setEmailAddress("member@dropboxsign.com"); + +try { + $result = $faxLineApi->faxLineAddUser($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineAddUser.py b/examples/FaxLineAddUser.py index e69de29bb..49d362ccb 100644 --- a/examples/FaxLineAddUser.py +++ b/examples/FaxLineAddUser.py @@ -0,0 +1,23 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineAddUserRequest( + number="[FAX_NUMBER]", + email_address="member@dropboxsign.com", + ) + + try: + response = fax_line_api.fax_line_add_user(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineAddUser.rb b/examples/FaxLineAddUser.rb index e69de29bb..1ad855373 100644 --- a/examples/FaxLineAddUser.rb +++ b/examples/FaxLineAddUser.rb @@ -0,0 +1,19 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineAddUserRequest.new +data.number = "[FAX_NUMBER]" +data.email_address = "member@dropboxsign.com" + +begin + result = fax_line_api.fax_line_add_user(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineAddUser.sh b/examples/FaxLineAddUser.sh index e69de29bb..d0d223f90 100644 --- a/examples/FaxLineAddUser.sh +++ b/examples/FaxLineAddUser.sh @@ -0,0 +1,4 @@ +curl -X POST 'https://api.hellosign.com/v3/fax_line/add_user' \ + -u 'YOUR_API_KEY:' \ + -F 'number=[FAX_NUMBER]' \ + -F 'email_address=member@dropboxsign.com' diff --git a/examples/FaxLineAddUser.ts b/examples/FaxLineAddUser.ts index e69de29bb..e5d705e94 100644 --- a/examples/FaxLineAddUser.ts +++ b/examples/FaxLineAddUser.ts @@ -0,0 +1,19 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineAddUserRequest = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineAddUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineAreaCodeGet.cs b/examples/FaxLineAreaCodeGet.cs index e69de29bb..cbcbc1cc8 100644 --- a/examples/FaxLineAreaCodeGet.cs +++ b/examples/FaxLineAreaCodeGet.cs @@ -0,0 +1,29 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + try + { + var result = faxLineApi.FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineAreaCodeGet.java b/examples/FaxLineAreaCodeGet.java index e69de29bb..4e31521b9 100644 --- a/examples/FaxLineAreaCodeGet.java +++ b/examples/FaxLineAreaCodeGet.java @@ -0,0 +1,26 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineAreaCodeGet.js b/examples/FaxLineAreaCodeGet.js index e69de29bb..bfc908f18 100644 --- a/examples/FaxLineAreaCodeGet.js +++ b/examples/FaxLineAreaCodeGet.js @@ -0,0 +1,14 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineAreaCodeGet("US", "CA"); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineAreaCodeGet.php b/examples/FaxLineAreaCodeGet.php index e69de29bb..cefd7159c 100644 --- a/examples/FaxLineAreaCodeGet.php +++ b/examples/FaxLineAreaCodeGet.php @@ -0,0 +1,23 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +try { + $result = $faxLineApi->faxLineAreaCodeGet( + Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum::US, + Dropbox\Sign\Model\FaxLineAreaCodeGetStateEnum::CA, + ); + + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineAreaCodeGet.py b/examples/FaxLineAreaCodeGet.py index e69de29bb..9e5225849 100644 --- a/examples/FaxLineAreaCodeGet.py +++ b/examples/FaxLineAreaCodeGet.py @@ -0,0 +1,18 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + try: + response = fax_line_api.fax_line_area_code_get(models.FaxLineAreaCodeGetCountryEnum("US"), models.FaxLineAreaCodeGetStateEnum("CA")) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineAreaCodeGet.rb b/examples/FaxLineAreaCodeGet.rb index e69de29bb..6b39d770b 100644 --- a/examples/FaxLineAreaCodeGet.rb +++ b/examples/FaxLineAreaCodeGet.rb @@ -0,0 +1,15 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +begin + result = fax_line_api.fax_line_area_code_get(Dropbox::Sign::FaxLineAreaCodeGetCountryEnum::US, Dropbox::Sign::FaxLineAreaCodeGetStateEnum::CA) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineAreaCodeGet.sh b/examples/FaxLineAreaCodeGet.sh index e69de29bb..8664c650e 100644 --- a/examples/FaxLineAreaCodeGet.sh +++ b/examples/FaxLineAreaCodeGet.sh @@ -0,0 +1,4 @@ +curl -X GET 'https://api.hellosign.com/v3/fax_line/area_codes' \ + -u 'YOUR_API_KEY:' \ + -F 'country=US' \ + -F 'state=CA' diff --git a/examples/FaxLineAreaCodeGet.ts b/examples/FaxLineAreaCodeGet.ts index e69de29bb..6984df6ea 100644 --- a/examples/FaxLineAreaCodeGet.ts +++ b/examples/FaxLineAreaCodeGet.ts @@ -0,0 +1,14 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineAreaCodeGet(DropboxSign.FaxLineAreaCodeGetCountryEnum.Us, DropboxSign.FaxLineAreaCodeGetStateEnum.Ca); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineCreate.cs b/examples/FaxLineCreate.cs index e69de29bb..4d919f366 100644 --- a/examples/FaxLineCreate.cs +++ b/examples/FaxLineCreate.cs @@ -0,0 +1,34 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineCreateRequest( + areaCode: "209", + country: "US" + ); + + try + { + var result = faxLineApi.FaxLineCreate(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineCreate.java b/examples/FaxLineCreate.java index e69de29bb..769b36a3a 100644 --- a/examples/FaxLineCreate.java +++ b/examples/FaxLineCreate.java @@ -0,0 +1,30 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineCreateRequest() + .areaCode("209") + .country("US"); + + try { + FaxLineResponse result = faxLineApi.faxLineCreate(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineCreate.js b/examples/FaxLineCreate.js index e69de29bb..4c17f057c 100644 --- a/examples/FaxLineCreate.js +++ b/examples/FaxLineCreate.js @@ -0,0 +1,19 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + areaCode: "209", + country: "US", +}; + +const result = faxLineApi.faxLineCreate(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineCreate.php b/examples/FaxLineCreate.php index e69de29bb..ad81ac508 100644 --- a/examples/FaxLineCreate.php +++ b/examples/FaxLineCreate.php @@ -0,0 +1,23 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineCreateRequest(); +$data->setAreaCode("209") + ->setCountry("US"); + +try { + $result = $faxLineApi->faxLineCreate($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineCreate.py b/examples/FaxLineCreate.py index e69de29bb..6bdca76ea 100644 --- a/examples/FaxLineCreate.py +++ b/examples/FaxLineCreate.py @@ -0,0 +1,23 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineCreateRequest( + area_code="209", + country="US", + ) + + try: + response = fax_line_api.fax_line_create(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineCreate.rb b/examples/FaxLineCreate.rb index e69de29bb..b57ac5570 100644 --- a/examples/FaxLineCreate.rb +++ b/examples/FaxLineCreate.rb @@ -0,0 +1,19 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineCreateRequest.new +data.area_code = "209" +data.country = "US" + +begin + result = fax_line_api.fax_line_create(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineCreate.sh b/examples/FaxLineCreate.sh index e69de29bb..054011b2e 100644 --- a/examples/FaxLineCreate.sh +++ b/examples/FaxLineCreate.sh @@ -0,0 +1,4 @@ +curl -X POST 'https://api.hellosign.com/v3/fax_line/create' \ + -u 'YOUR_API_KEY:' \ + -F 'area_code=209' \ + -F 'country=US' diff --git a/examples/FaxLineCreate.ts b/examples/FaxLineCreate.ts index e69de29bb..8671bb70c 100644 --- a/examples/FaxLineCreate.ts +++ b/examples/FaxLineCreate.ts @@ -0,0 +1,19 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineCreateRequest = { + areaCode: "209", + country: "US", +}; + +const result = faxLineApi.faxLineCreate(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineDelete.cs b/examples/FaxLineDelete.cs index e69de29bb..8eac85115 100644 --- a/examples/FaxLineDelete.cs +++ b/examples/FaxLineDelete.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineDeleteRequest( + number: "[FAX_NUMBER]", + ); + + try + { + var result = faxLineApi.FaxLineDelete(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineDelete.java b/examples/FaxLineDelete.java index e69de29bb..6b989d287 100644 --- a/examples/FaxLineDelete.java +++ b/examples/FaxLineDelete.java @@ -0,0 +1,28 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineDeleteRequest() + .number("[FAX_NUMBER]"); + + try { + faxLineApi.faxLineDelete(data); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineDelete.js b/examples/FaxLineDelete.js index e69de29bb..63c7f0c2d 100644 --- a/examples/FaxLineDelete.js +++ b/examples/FaxLineDelete.js @@ -0,0 +1,18 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + number: "[FAX_NUMBER]", +}; + +const result = faxLineApi.faxLineDelete(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineDelete.php b/examples/FaxLineDelete.php index e69de29bb..b60e3d1af 100644 --- a/examples/FaxLineDelete.php +++ b/examples/FaxLineDelete.php @@ -0,0 +1,22 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineDeleteRequest(); +$data->setNumber("[FAX_NUMBER]"); + +try { + $result = $faxLineApi->faxLineDelete($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineDelete.py b/examples/FaxLineDelete.py index e69de29bb..f11e20de3 100644 --- a/examples/FaxLineDelete.py +++ b/examples/FaxLineDelete.py @@ -0,0 +1,22 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineDeleteRequest( + number="[FAX_NUMBER]", + ) + + try: + response = fax_line_api.fax_line_delete(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineDelete.rb b/examples/FaxLineDelete.rb index e69de29bb..3461a229a 100644 --- a/examples/FaxLineDelete.rb +++ b/examples/FaxLineDelete.rb @@ -0,0 +1,18 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineDeleteRequest.new +data.number = "[FAX_NUMBER]" + +begin + result = fax_line_api.fax_line_delete(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineDelete.sh b/examples/FaxLineDelete.sh index e69de29bb..d732b3db8 100644 --- a/examples/FaxLineDelete.sh +++ b/examples/FaxLineDelete.sh @@ -0,0 +1,3 @@ +curl -X DELETE 'https://api.hellosign.com/v3/fax_line' \ + -u 'YOUR_API_KEY:' \ + -F 'number=[FAX_NUMBER]' diff --git a/examples/FaxLineDelete.ts b/examples/FaxLineDelete.ts index e69de29bb..dbb035216 100644 --- a/examples/FaxLineDelete.ts +++ b/examples/FaxLineDelete.ts @@ -0,0 +1,18 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineDeleteRequest = { + number: "[FAX_NUMBER]", +}; + +const result = faxLineApi.faxLineDelete(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineGet.cs b/examples/FaxLineGet.cs index e69de29bb..d18c82fab 100644 --- a/examples/FaxLineGet.cs +++ b/examples/FaxLineGet.cs @@ -0,0 +1,29 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + try + { + var result = faxLineApi.FaxLineGet("[FAX_NUMBER]"); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineGet.java b/examples/FaxLineGet.java index e69de29bb..69281b342 100644 --- a/examples/FaxLineGet.java +++ b/examples/FaxLineGet.java @@ -0,0 +1,26 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineResponse result = faxLineApi.faxLineGet("[FAX_NUMBER]"); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineGet.js b/examples/FaxLineGet.js index e69de29bb..e9643abe9 100644 --- a/examples/FaxLineGet.js +++ b/examples/FaxLineGet.js @@ -0,0 +1,14 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineGet("[FAX_NUMBER]"); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineGet.php b/examples/FaxLineGet.php index e69de29bb..75dd77b5c 100644 --- a/examples/FaxLineGet.php +++ b/examples/FaxLineGet.php @@ -0,0 +1,19 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +try { + $result = $faxLineApi->faxLineGet("[FAX_NUMBER]"); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineGet.py b/examples/FaxLineGet.py index e69de29bb..3f66de9e7 100644 --- a/examples/FaxLineGet.py +++ b/examples/FaxLineGet.py @@ -0,0 +1,18 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + try: + response = fax_line_api.fax_line_get("[FAX_NUMBER]") + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineGet.rb b/examples/FaxLineGet.rb index e69de29bb..090c2bdd8 100644 --- a/examples/FaxLineGet.rb +++ b/examples/FaxLineGet.rb @@ -0,0 +1,15 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +begin + result = fax_line_api.fax_line_get("[NUMBER]") + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineGet.sh b/examples/FaxLineGet.sh index e69de29bb..513522062 100644 --- a/examples/FaxLineGet.sh +++ b/examples/FaxLineGet.sh @@ -0,0 +1,2 @@ +curl -X GET 'https://api.hellosign.com/v3/fax_line?number=[FAX_NUMBER]' \ + -u 'YOUR_API_KEY:' diff --git a/examples/FaxLineGet.ts b/examples/FaxLineGet.ts index e69de29bb..e9643abe9 100644 --- a/examples/FaxLineGet.ts +++ b/examples/FaxLineGet.ts @@ -0,0 +1,14 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineGet("[FAX_NUMBER]"); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineList.cs b/examples/FaxLineList.cs index e69de29bb..96d7f0c28 100644 --- a/examples/FaxLineList.cs +++ b/examples/FaxLineList.cs @@ -0,0 +1,29 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + try + { + var result = faxLineApi.FaxLineList(); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineList.java b/examples/FaxLineList.java index e69de29bb..df1d0bd13 100644 --- a/examples/FaxLineList.java +++ b/examples/FaxLineList.java @@ -0,0 +1,26 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineListResponse result = faxLineApi.faxLineList(); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineList.js b/examples/FaxLineList.js index e69de29bb..f40c60dfa 100644 --- a/examples/FaxLineList.js +++ b/examples/FaxLineList.js @@ -0,0 +1,14 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineList(); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineList.php b/examples/FaxLineList.php index e69de29bb..6056a2427 100644 --- a/examples/FaxLineList.php +++ b/examples/FaxLineList.php @@ -0,0 +1,19 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +try { + $result = $faxLineApi->faxLineList(); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineList.py b/examples/FaxLineList.py index e69de29bb..49cf69a59 100644 --- a/examples/FaxLineList.py +++ b/examples/FaxLineList.py @@ -0,0 +1,18 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + try: + response = fax_line_api.fax_line_list() + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineList.rb b/examples/FaxLineList.rb index e69de29bb..23a0ec845 100644 --- a/examples/FaxLineList.rb +++ b/examples/FaxLineList.rb @@ -0,0 +1,15 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +begin + result = fax_line_api.fax_line_list() + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineList.sh b/examples/FaxLineList.sh index e69de29bb..d5b4ea4df 100644 --- a/examples/FaxLineList.sh +++ b/examples/FaxLineList.sh @@ -0,0 +1,2 @@ +curl -X GET 'https://api.hellosign.com/v3/fax_line/list' \ + -u 'YOUR_API_KEY:' diff --git a/examples/FaxLineList.ts b/examples/FaxLineList.ts index e69de29bb..f40c60dfa 100644 --- a/examples/FaxLineList.ts +++ b/examples/FaxLineList.ts @@ -0,0 +1,14 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineList(); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineRemoveUser.cs b/examples/FaxLineRemoveUser.cs index e69de29bb..1dd562ed6 100644 --- a/examples/FaxLineRemoveUser.cs +++ b/examples/FaxLineRemoveUser.cs @@ -0,0 +1,34 @@ +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineRemoveUserRequest( + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com" + ); + + try + { + var result = faxLineApi.FaxLineRemoveUser(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} diff --git a/examples/FaxLineRemoveUser.java b/examples/FaxLineRemoveUser.java index e69de29bb..7864b05ab 100644 --- a/examples/FaxLineRemoveUser.java +++ b/examples/FaxLineRemoveUser.java @@ -0,0 +1,30 @@ +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineRemoveUserRequest() + .number("[FAX_NUMBER]") + .emailAddress("member@dropboxsign.com"); + + try { + FaxLineResponse result = faxLineApi.faxLineRemoveUser(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/FaxLineRemoveUser.js b/examples/FaxLineRemoveUser.js index e69de29bb..64f247924 100644 --- a/examples/FaxLineRemoveUser.js +++ b/examples/FaxLineRemoveUser.js @@ -0,0 +1,19 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineRemoveUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); diff --git a/examples/FaxLineRemoveUser.php b/examples/FaxLineRemoveUser.php index e69de29bb..60132fedc 100644 --- a/examples/FaxLineRemoveUser.php +++ b/examples/FaxLineRemoveUser.php @@ -0,0 +1,23 @@ +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineRemoveUserRequest(); +$data->setNumber("[FAX_NUMBER]") + ->setEmailAddress("member@dropboxsign.com"); + +try { + $result = $faxLineApi->faxLineRemoveUser($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} diff --git a/examples/FaxLineRemoveUser.py b/examples/FaxLineRemoveUser.py index e69de29bb..4d8c19668 100644 --- a/examples/FaxLineRemoveUser.py +++ b/examples/FaxLineRemoveUser.py @@ -0,0 +1,23 @@ +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineRemoveUserRequest( + number="[FAX_NUMBER]", + email_address="member@dropboxsign.com", + ) + + try: + response = fax_line_api.fax_line_remove_user(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineRemoveUser.rb b/examples/FaxLineRemoveUser.rb index e69de29bb..98bb7a047 100644 --- a/examples/FaxLineRemoveUser.rb +++ b/examples/FaxLineRemoveUser.rb @@ -0,0 +1,19 @@ +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineRemoveUserRequest.new +data.number = "[FAX_NUMBER]" +data.email_address = "member@dropboxsign.com" + +begin + result = fax_line_api.fax_line_remove_user(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end diff --git a/examples/FaxLineRemoveUser.sh b/examples/FaxLineRemoveUser.sh index e69de29bb..7c7a1580a 100644 --- a/examples/FaxLineRemoveUser.sh +++ b/examples/FaxLineRemoveUser.sh @@ -0,0 +1,4 @@ +curl -X POST 'https://api.hellosign.com/v3/fax_line/remove_user' \ + -u 'YOUR_API_KEY:' \ + -F 'number=[FAX_NUMBER]' \ + -F 'email_address=member@dropboxsign.com' diff --git a/examples/FaxLineRemoveUser.ts b/examples/FaxLineRemoveUser.ts index e69de29bb..91dc3066b 100644 --- a/examples/FaxLineRemoveUser.ts +++ b/examples/FaxLineRemoveUser.ts @@ -0,0 +1,19 @@ +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineRemoveUserRequest = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineRemoveUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); From 30e08658973d54d04ada1db4dfd7182c37a37eb3 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Tue, 13 Aug 2024 13:23:10 -0400 Subject: [PATCH 04/12] regen sdks --- sdks/dotnet/docs/FaxLineApi.md | 222 +++++++++++++++++ sdks/dotnet/docs/FaxLineCreateRequest.md | 2 +- .../Model/FaxLineCreateRequest.cs | 9 +- sdks/java-v1/docs/FaxLineApi.md | 196 +++++++++++++++ sdks/java-v1/docs/FaxLineCreateRequest.md | 2 +- .../sign/model/FaxLineCreateRequest.java | 8 +- sdks/java-v2/docs/FaxLineApi.md | 196 +++++++++++++++ sdks/java-v2/docs/FaxLineCreateRequest.md | 2 +- .../sign/model/FaxLineCreateRequest.java | 8 +- sdks/node/docs/api/FaxLineApi.md | 234 ++++++++++++++++++ sdks/node/docs/model/FaxLineCreateRequest.md | 2 +- sdks/node/model/faxLineCreateRequest.ts | 2 +- .../types/model/faxLineCreateRequest.d.ts | 2 +- sdks/php/docs/Api/FaxLineApi.md | 152 ++++++++++++ sdks/php/docs/Model/FaxLineCreateRequest.md | 2 +- sdks/php/src/Model/FaxLineCreateRequest.php | 9 +- sdks/python/docs/FaxLineApi.md | 145 +++++++++++ sdks/python/docs/FaxLineCreateRequest.md | 2 +- .../model/fax_line_create_request.py | 10 +- sdks/ruby/docs/FaxLineApi.md | 120 +++++++++ sdks/ruby/docs/FaxLineCreateRequest.md | 2 +- .../models/fax_line_create_request.rb | 5 - 22 files changed, 1291 insertions(+), 41 deletions(-) diff --git a/sdks/dotnet/docs/FaxLineApi.md b/sdks/dotnet/docs/FaxLineApi.md index c97e9d57f..cb3e649e6 100644 --- a/sdks/dotnet/docs/FaxLineApi.md +++ b/sdks/dotnet/docs/FaxLineApi.md @@ -22,6 +22,40 @@ Grants a user access to the specified Fax Line. ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineAddUserRequest( + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com" + ); + + try + { + var result = faxLineApi.FaxLineAddUser(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` @@ -83,6 +117,35 @@ Returns a response with the area codes available for a given state/provice and c ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + try + { + var result = faxLineApi.FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` @@ -147,6 +210,40 @@ Purchases a new Fax Line. ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineCreateRequest( + areaCode: "209", + country: "US" + ); + + try + { + var result = faxLineApi.FaxLineCreate(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` @@ -208,6 +305,39 @@ Deletes the specified Fax Line from the subscription. ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineDeleteRequest( + number: "[FAX_NUMBER]", + ); + + try + { + var result = faxLineApi.FaxLineDelete(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` @@ -266,6 +396,35 @@ Returns the properties and settings of a Fax Line. ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + try + { + var result = faxLineApi.FaxLineGet("[FAX_NUMBER]"); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` @@ -327,6 +486,35 @@ Returns the properties and settings of multiple Fax Lines. ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + try + { + var result = faxLineApi.FaxLineList(); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` @@ -391,6 +579,40 @@ Removes a user's access to the specified Fax Line. ### Example ```csharp +using System; +using System.Collections.Generic; +using System.IO; +using Dropbox.Sign.Api; +using Dropbox.Sign.Client; +using Dropbox.Sign.Model; + +public class Example +{ + public static void Main() + { + var config = new Configuration(); + config.Username = "YOUR_API_KEY"; + + var faxLineApi = new FaxLineApi(config); + + var data = new FaxLineRemoveUserRequest( + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com" + ); + + try + { + var result = faxLineApi.FaxLineRemoveUser(data); + Console.WriteLine(result); + } + catch (ApiException e) + { + Console.WriteLine("Exception when calling Dropbox Sign API: " + e.Message); + Console.WriteLine("Status Code: " + e.ErrorCode); + Console.WriteLine(e.StackTrace); + } + } +} ``` diff --git a/sdks/dotnet/docs/FaxLineCreateRequest.md b/sdks/dotnet/docs/FaxLineCreateRequest.md index d2789845b..d0aa274d3 100644 --- a/sdks/dotnet/docs/FaxLineCreateRequest.md +++ b/sdks/dotnet/docs/FaxLineCreateRequest.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AreaCode** | **string** | Area code | **Country** | **FaxLineAreaCodeGetCountryEnum** | | -**City** | **string** | City | +**City** | **string** | City | [optional] **AccountId** | **string** | Account ID | [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/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs index ae20ad586..ac38bc300 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs @@ -49,7 +49,7 @@ protected FaxLineCreateRequest() { } /// /// Area code (required). /// country (required). - /// City (required). + /// City. /// Account ID. public FaxLineCreateRequest(string areaCode = default(string), FaxLineAreaCodeGetCountryEnum country = default(FaxLineAreaCodeGetCountryEnum), string city = default(string), string accountId = default(string)) { @@ -61,11 +61,6 @@ protected FaxLineCreateRequest() { } } this.AreaCode = areaCode; this.Country = country; - // to ensure "city" is required (not null) - if (city == null) - { - throw new ArgumentNullException("city is a required property for FaxLineCreateRequest and cannot be null"); - } this.City = city; this.AccountId = accountId; } @@ -97,7 +92,7 @@ public static FaxLineCreateRequest Init(string jsonData) /// City /// /// City - [DataMember(Name = "city", IsRequired = true, EmitDefaultValue = true)] + [DataMember(Name = "city", EmitDefaultValue = true)] public string City { get; set; } /// diff --git a/sdks/java-v1/docs/FaxLineApi.md b/sdks/java-v1/docs/FaxLineApi.md index 3ab18f277..c880cf75a 100644 --- a/sdks/java-v1/docs/FaxLineApi.md +++ b/sdks/java-v1/docs/FaxLineApi.md @@ -25,6 +25,36 @@ Grants a user access to the specified Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineAddUserRequest() + .number("[FAX_NUMBER]") + .emailAddress("member@dropboxsign.com"); + + try { + FaxLineResponse result = faxLineApi.faxLineAddUser(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -66,6 +96,32 @@ Returns a response with the area codes available for a given state/provice and c ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -110,6 +166,36 @@ Purchases a new Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineCreateRequest() + .areaCode("209") + .country("US"); + + try { + FaxLineResponse result = faxLineApi.faxLineCreate(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -151,6 +237,34 @@ Deletes the specified Fax Line from the subscription. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineDeleteRequest() + .number("[FAX_NUMBER]"); + + try { + faxLineApi.faxLineDelete(data); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -192,6 +306,32 @@ Returns the properties and settings of a Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineResponse result = faxLineApi.faxLineGet("[FAX_NUMBER]"); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -233,6 +373,32 @@ Returns the properties and settings of multiple Fax Lines. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineListResponse result = faxLineApi.faxLineList(); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -277,6 +443,36 @@ Removes a user's access to the specified Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineRemoveUserRequest() + .number("[FAX_NUMBER]") + .emailAddress("member@dropboxsign.com"); + + try { + FaxLineResponse result = faxLineApi.faxLineRemoveUser(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` diff --git a/sdks/java-v1/docs/FaxLineCreateRequest.md b/sdks/java-v1/docs/FaxLineCreateRequest.md index 6c4bf7d18..eb52f48b9 100644 --- a/sdks/java-v1/docs/FaxLineCreateRequest.md +++ b/sdks/java-v1/docs/FaxLineCreateRequest.md @@ -10,7 +10,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `areaCode`*_required_ | ```String``` | Area code | | | `country`*_required_ | ```FaxLineAreaCodeGetCountryEnum``` | | | -| `city`*_required_ | ```String``` | City | | +| `city` | ```String``` | City | | | `accountId` | ```String``` | Account ID | | diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java index 65460137d..57ea9672e 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -135,10 +135,10 @@ public FaxLineCreateRequest city(String city) { * City * @return city **/ - @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "City") + @javax.annotation.Nullable + @ApiModelProperty(value = "City") @JsonProperty(JSON_PROPERTY_CITY) - @JsonInclude(value = JsonInclude.Include.ALWAYS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public String getCity() { return city; @@ -146,7 +146,7 @@ public String getCity() { @JsonProperty(JSON_PROPERTY_CITY) - @JsonInclude(value = JsonInclude.Include.ALWAYS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public void setCity(String city) { this.city = city; } diff --git a/sdks/java-v2/docs/FaxLineApi.md b/sdks/java-v2/docs/FaxLineApi.md index 3ab18f277..c880cf75a 100644 --- a/sdks/java-v2/docs/FaxLineApi.md +++ b/sdks/java-v2/docs/FaxLineApi.md @@ -25,6 +25,36 @@ Grants a user access to the specified Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineAddUserRequest() + .number("[FAX_NUMBER]") + .emailAddress("member@dropboxsign.com"); + + try { + FaxLineResponse result = faxLineApi.faxLineAddUser(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -66,6 +96,32 @@ Returns a response with the area codes available for a given state/provice and c ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -110,6 +166,36 @@ Purchases a new Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineCreateRequest() + .areaCode("209") + .country("US"); + + try { + FaxLineResponse result = faxLineApi.faxLineCreate(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -151,6 +237,34 @@ Deletes the specified Fax Line from the subscription. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineDeleteRequest() + .number("[FAX_NUMBER]"); + + try { + faxLineApi.faxLineDelete(data); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -192,6 +306,32 @@ Returns the properties and settings of a Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineResponse result = faxLineApi.faxLineGet("[FAX_NUMBER]"); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -233,6 +373,32 @@ Returns the properties and settings of multiple Fax Lines. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + try { + FaxLineListResponse result = faxLineApi.faxLineList(); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` @@ -277,6 +443,36 @@ Removes a user's access to the specified Fax Line. ### Example ```java +import com.dropbox.sign.ApiException; +import com.dropbox.sign.Configuration; +import com.dropbox.sign.api.*; +import com.dropbox.sign.auth.*; +import com.dropbox.sign.model.*; + +import java.util.List; + +public class Example { + public static void main(String[] args) { + var apiClient = Configuration.getDefaultApiClient() + .setApiKey("YOUR_API_KEY"); + + var faxLineApi = new FaxLineApi(apiClient); + + var data = new FaxLineRemoveUserRequest() + .number("[FAX_NUMBER]") + .emailAddress("member@dropboxsign.com"); + + try { + FaxLineResponse result = faxLineApi.faxLineRemoveUser(data); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} ``` diff --git a/sdks/java-v2/docs/FaxLineCreateRequest.md b/sdks/java-v2/docs/FaxLineCreateRequest.md index 6c4bf7d18..eb52f48b9 100644 --- a/sdks/java-v2/docs/FaxLineCreateRequest.md +++ b/sdks/java-v2/docs/FaxLineCreateRequest.md @@ -10,7 +10,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `areaCode`*_required_ | ```String``` | Area code | | | `country`*_required_ | ```FaxLineAreaCodeGetCountryEnum``` | | | -| `city`*_required_ | ```String``` | City | | +| `city` | ```String``` | City | | | `accountId` | ```String``` | Account ID | | diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java index 3288b6bb6..a15345ec1 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -135,10 +135,10 @@ public FaxLineCreateRequest city(String city) { * City * @return city **/ - @jakarta.annotation.Nonnull - @ApiModelProperty(required = true, value = "City") + @jakarta.annotation.Nullable + @ApiModelProperty(value = "City") @JsonProperty(JSON_PROPERTY_CITY) - @JsonInclude(value = JsonInclude.Include.ALWAYS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public String getCity() { return city; @@ -146,7 +146,7 @@ public String getCity() { @JsonProperty(JSON_PROPERTY_CITY) - @JsonInclude(value = JsonInclude.Include.ALWAYS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public void setCity(String city) { this.city = city; } diff --git a/sdks/node/docs/api/FaxLineApi.md b/sdks/node/docs/api/FaxLineApi.md index 70db7f60b..b2774aa09 100644 --- a/sdks/node/docs/api/FaxLineApi.md +++ b/sdks/node/docs/api/FaxLineApi.md @@ -26,12 +26,50 @@ Grants a user access to the specified Fax Line. ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineAddUserRequest = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineAddUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineAddUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` @@ -71,12 +109,40 @@ Returns a response with the area codes available for a given state/provice and c ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineAreaCodeGet(DropboxSign.FaxLineAreaCodeGetCountryEnum.Us, DropboxSign.FaxLineAreaCodeGetStateEnum.Ca); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineAreaCodeGet("US", "CA"); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` @@ -119,12 +185,50 @@ Purchases a new Fax Line. ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineCreateRequest = { + areaCode: "209", + country: "US", +}; + +const result = faxLineApi.faxLineCreate(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + areaCode: "209", + country: "US", +}; + +const result = faxLineApi.faxLineCreate(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` @@ -164,12 +268,48 @@ Deletes the specified Fax Line from the subscription. ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineDeleteRequest = { + number: "[FAX_NUMBER]", +}; + +const result = faxLineApi.faxLineDelete(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + number: "[FAX_NUMBER]", +}; + +const result = faxLineApi.faxLineDelete(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` @@ -209,12 +349,40 @@ Returns the properties and settings of a Fax Line. ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineGet("[FAX_NUMBER]"); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineGet("[FAX_NUMBER]"); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` @@ -254,12 +422,40 @@ Returns the properties and settings of multiple Fax Lines. ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineList(); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const result = faxLineApi.faxLineList(); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` @@ -302,12 +498,50 @@ Removes a user\'s access to the specified Fax Line. ### TypeScript Example ```typescript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data: DropboxSign.FaxLineRemoveUserRequest = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineRemoveUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` ### JavaScript Example ```javascript +import * as DropboxSign from "@dropbox/sign"; + +const faxLineApi = new DropboxSign.FaxLineApi(); + +// Configure HTTP basic authorization: api_key +faxLineApi.username = "YOUR_API_KEY"; + +const data = { + number: "[FAX_NUMBER]", + emailAddress: "member@dropboxsign.com", +}; + +const result = faxLineApi.faxLineRemoveUser(data); +result.then(response => { + console.log(response.body); +}).catch(error => { + console.log("Exception when calling Dropbox Sign API:"); + console.log(error.body); +}); ``` diff --git a/sdks/node/docs/model/FaxLineCreateRequest.md b/sdks/node/docs/model/FaxLineCreateRequest.md index 0df864824..d42665f7b 100644 --- a/sdks/node/docs/model/FaxLineCreateRequest.md +++ b/sdks/node/docs/model/FaxLineCreateRequest.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `areaCode`*_required_ | ```string``` | Area code | | | `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | -| `city`*_required_ | ```string``` | City | | +| `city` | ```string``` | City | | | `accountId` | ```string``` | Account ID | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/model/faxLineCreateRequest.ts b/sdks/node/model/faxLineCreateRequest.ts index 8f7d03a2a..267315195 100644 --- a/sdks/node/model/faxLineCreateRequest.ts +++ b/sdks/node/model/faxLineCreateRequest.ts @@ -34,7 +34,7 @@ export class FaxLineCreateRequest { /** * City */ - "city": string; + "city"?: string; /** * Account ID */ diff --git a/sdks/node/types/model/faxLineCreateRequest.d.ts b/sdks/node/types/model/faxLineCreateRequest.d.ts index a8333bcee..16b4eb245 100644 --- a/sdks/node/types/model/faxLineCreateRequest.d.ts +++ b/sdks/node/types/model/faxLineCreateRequest.d.ts @@ -3,7 +3,7 @@ import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; export declare class FaxLineCreateRequest { "areaCode": string; "country": FaxLineAreaCodeGetCountryEnum; - "city": string; + "city"?: string; "accountId"?: string; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; diff --git a/sdks/php/docs/Api/FaxLineApi.md b/sdks/php/docs/Api/FaxLineApi.md index 225f50800..4f4e9a82b 100644 --- a/sdks/php/docs/Api/FaxLineApi.md +++ b/sdks/php/docs/Api/FaxLineApi.md @@ -26,6 +26,29 @@ Grants a user access to the specified Fax Line. ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineAddUserRequest(); +$data->setNumber("[FAX_NUMBER]") + ->setEmailAddress("member@dropboxsign.com"); + +try { + $result = $faxLineApi->faxLineAddUser($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` @@ -65,6 +88,29 @@ Returns a response with the area codes available for a given state/provice and c ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +try { + $result = $faxLineApi->faxLineAreaCodeGet( + Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum::US, + Dropbox\Sign\Model\FaxLineAreaCodeGetStateEnum::CA, + ); + + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` @@ -107,6 +153,29 @@ Purchases a new Fax Line. ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineCreateRequest(); +$data->setAreaCode("209") + ->setCountry("US"); + +try { + $result = $faxLineApi->faxLineCreate($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` @@ -146,6 +215,28 @@ Deletes the specified Fax Line from the subscription. ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineDeleteRequest(); +$data->setNumber("[FAX_NUMBER]"); + +try { + $result = $faxLineApi->faxLineDelete($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` @@ -185,6 +276,25 @@ Returns the properties and settings of a Fax Line. ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +try { + $result = $faxLineApi->faxLineGet("[FAX_NUMBER]"); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` @@ -224,6 +334,25 @@ Returns the properties and settings of multiple Fax Lines. ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +try { + $result = $faxLineApi->faxLineList(); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` @@ -266,6 +395,29 @@ Removes a user's access to the specified Fax Line. ### Example ```php +setUsername("YOUR_API_KEY"); + +$faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); + +$data = new Dropbox\Sign\Model\FaxLineRemoveUserRequest(); +$data->setNumber("[FAX_NUMBER]") + ->setEmailAddress("member@dropboxsign.com"); + +try { + $result = $faxLineApi->faxLineRemoveUser($data); + print_r($result); +} catch (Dropbox\Sign\ApiException $e) { + $error = $e->getResponseObject(); + echo "Exception when calling Dropbox Sign API: " + . print_r($error->getError()); +} ``` diff --git a/sdks/php/docs/Model/FaxLineCreateRequest.md b/sdks/php/docs/Model/FaxLineCreateRequest.md index 23465ef7e..036097fb9 100644 --- a/sdks/php/docs/Model/FaxLineCreateRequest.md +++ b/sdks/php/docs/Model/FaxLineCreateRequest.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `area_code`*_required_ | ```string``` | Area code | | | `country`*_required_ | [```\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | -| `city`*_required_ | ```string``` | City | | +| `city` | ```string``` | City | | | `account_id` | ```string``` | Account ID | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/src/Model/FaxLineCreateRequest.php b/sdks/php/src/Model/FaxLineCreateRequest.php index 811ff69a2..534876b6d 100644 --- a/sdks/php/src/Model/FaxLineCreateRequest.php +++ b/sdks/php/src/Model/FaxLineCreateRequest.php @@ -232,9 +232,6 @@ public function listInvalidProperties() if ($this->container['country'] === null) { $invalidProperties[] = "'country' can't be null"; } - if ($this->container['city'] === null) { - $invalidProperties[] = "'city' can't be null"; - } return $invalidProperties; } @@ -301,7 +298,7 @@ public function setCountry(FaxLineAreaCodeGetCountryEnum $country) /** * Gets city * - * @return string + * @return string|null */ public function getCity() { @@ -311,11 +308,11 @@ public function getCity() /** * Sets city * - * @param string $city City + * @param string|null $city City * * @return self */ - public function setCity(string $city) + public function setCity(?string $city) { $this->container['city'] = $city; diff --git a/sdks/python/docs/FaxLineApi.md b/sdks/python/docs/FaxLineApi.md index 40c7d9fb3..abfedb435 100644 --- a/sdks/python/docs/FaxLineApi.md +++ b/sdks/python/docs/FaxLineApi.md @@ -25,6 +25,29 @@ Grants a user access to the specified Fax Line. * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineAddUserRequest( + number="[FAX_NUMBER]", + email_address="member@dropboxsign.com", + ) + + try: + response = fax_line_api.fax_line_add_user(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` @@ -70,6 +93,24 @@ Returns a response with the area codes available for a given state/provice and c * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + try: + response = fax_line_api.fax_line_area_code_get(models.FaxLineAreaCodeGetCountryEnum("US"), models.FaxLineAreaCodeGetStateEnum("CA")) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` @@ -118,6 +159,29 @@ Purchases a new Fax Line. * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineCreateRequest( + area_code="209", + country="US", + ) + + try: + response = fax_line_api.fax_line_create(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` @@ -163,6 +227,28 @@ Deletes the specified Fax Line from the subscription. * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineDeleteRequest( + number="[FAX_NUMBER]", + ) + + try: + response = fax_line_api.fax_line_delete(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` @@ -208,6 +294,24 @@ Returns the properties and settings of a Fax Line. * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + try: + response = fax_line_api.fax_line_get("[FAX_NUMBER]") + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` @@ -253,6 +357,24 @@ Returns the properties and settings of multiple Fax Lines. * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + try: + response = fax_line_api.fax_line_list() + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` @@ -301,6 +423,29 @@ Removes a user's access to the specified Fax Line. * Basic Authentication (api_key): ```python +from pprint import pprint + +from dropbox_sign import \ + ApiClient, ApiException, Configuration, apis, models + +configuration = Configuration( + # Configure HTTP basic authorization: api_key + username="YOUR_API_KEY", +) + +with ApiClient(configuration) as api_client: + fax_line_api = apis.FaxLineApi(api_client) + + data = models.FaxLineRemoveUserRequest( + number="[FAX_NUMBER]", + email_address="member@dropboxsign.com", + ) + + try: + response = fax_line_api.fax_line_remove_user(data) + pprint(response) + except ApiException as e: + print("Exception when calling Dropbox Sign API: %s\n" % e) ``` diff --git a/sdks/python/docs/FaxLineCreateRequest.md b/sdks/python/docs/FaxLineCreateRequest.md index ea7453221..bd8cbb85d 100644 --- a/sdks/python/docs/FaxLineCreateRequest.md +++ b/sdks/python/docs/FaxLineCreateRequest.md @@ -8,7 +8,7 @@ | ---- | ---- | ----------- | ----- | | `area_code`*_required_ | ```str``` | Area code | | | `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | -| `city`*_required_ | ```str``` | City | | +| `city` | ```str``` | City | | | `account_id` | ```str``` | Account ID | | diff --git a/sdks/python/dropbox_sign/model/fax_line_create_request.py b/sdks/python/dropbox_sign/model/fax_line_create_request.py index 46d9c8b3a..cdcc5df64 100644 --- a/sdks/python/dropbox_sign/model/fax_line_create_request.py +++ b/sdks/python/dropbox_sign/model/fax_line_create_request.py @@ -166,13 +166,12 @@ def account_id(self, value: str): @classmethod @convert_js_args_to_python_args - def _from_openapi_data(cls, area_code, country, city, *args, **kwargs): # noqa: E501 + def _from_openapi_data(cls, area_code, country, *args, **kwargs): # noqa: E501 """FaxLineCreateRequest - a model defined in OpenAPI Args: area_code (str): Area code country (FaxLineAreaCodeGetCountryEnum): - city (str): City Keyword Args: _check_type (bool): if True, values for parameters in openapi_types @@ -205,6 +204,7 @@ def _from_openapi_data(cls, area_code, country, city, *args, **kwargs): # noqa: Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + city (str): City. [optional] # noqa: E501 account_id (str): Account ID. [optional] # noqa: E501 """ @@ -235,7 +235,6 @@ def _from_openapi_data(cls, area_code, country, city, *args, **kwargs): # noqa: self.area_code = area_code self.country = country - self.city = city for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ @@ -256,13 +255,12 @@ def _from_openapi_data(cls, area_code, country, city, *args, **kwargs): # noqa: ]) @convert_js_args_to_python_args - def __init__(self, area_code, country, city, *args, **kwargs): # noqa: E501 + def __init__(self, area_code, country, *args, **kwargs): # noqa: E501 """FaxLineCreateRequest - a model defined in OpenAPI Args: area_code (str): Area code country (FaxLineAreaCodeGetCountryEnum): - city (str): City Keyword Args: _check_type (bool): if True, values for parameters in openapi_types @@ -295,6 +293,7 @@ def __init__(self, area_code, country, city, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + city (str): City. [optional] # noqa: E501 account_id (str): Account ID. [optional] # noqa: E501 """ @@ -323,7 +322,6 @@ def __init__(self, area_code, country, city, *args, **kwargs): # noqa: E501 self.area_code = area_code self.country = country - self.city = city for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ diff --git a/sdks/ruby/docs/FaxLineApi.md b/sdks/ruby/docs/FaxLineApi.md index 186d7fbc8..d76f28245 100644 --- a/sdks/ruby/docs/FaxLineApi.md +++ b/sdks/ruby/docs/FaxLineApi.md @@ -24,6 +24,25 @@ Grants a user access to the specified Fax Line. ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineAddUserRequest.new +data.number = "[FAX_NUMBER]" +data.email_address = "member@dropboxsign.com" + +begin + result = fax_line_api.fax_line_add_user(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` @@ -76,6 +95,21 @@ Returns a response with the area codes available for a given state/provice and c ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +begin + result = fax_line_api.fax_line_area_code_get(Dropbox::Sign::FaxLineAreaCodeGetCountryEnum::US, Dropbox::Sign::FaxLineAreaCodeGetStateEnum::CA) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` @@ -131,6 +165,25 @@ Purchases a new Fax Line. ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineCreateRequest.new +data.area_code = "209" +data.country = "US" + +begin + result = fax_line_api.fax_line_create(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` @@ -183,6 +236,24 @@ Deletes the specified Fax Line from the subscription. ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineDeleteRequest.new +data.number = "[FAX_NUMBER]" + +begin + result = fax_line_api.fax_line_delete(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` @@ -235,6 +306,21 @@ Returns the properties and settings of a Fax Line. ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +begin + result = fax_line_api.fax_line_get("[NUMBER]") + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` @@ -287,6 +373,21 @@ Returns the properties and settings of multiple Fax Lines. ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +begin + result = fax_line_api.fax_line_list() + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` @@ -342,6 +443,25 @@ Removes a user's access to the specified Fax Line. ### Examples ```ruby +require "dropbox-sign" + +Dropbox::Sign.configure do |config| + # Configure HTTP basic authorization: api_key + config.username = "YOUR_API_KEY" +end + +fax_line_api = Dropbox::Sign::FaxLineApi.new + +data = Dropbox::Sign::FaxLineRemoveUserRequest.new +data.number = "[FAX_NUMBER]" +data.email_address = "member@dropboxsign.com" + +begin + result = fax_line_api.fax_line_remove_user(data) + p result +rescue Dropbox::Sign::ApiError => e + puts "Exception when calling Dropbox Sign API: #{e}" +end ``` diff --git a/sdks/ruby/docs/FaxLineCreateRequest.md b/sdks/ruby/docs/FaxLineCreateRequest.md index ef5d25f6a..35a09609e 100644 --- a/sdks/ruby/docs/FaxLineCreateRequest.md +++ b/sdks/ruby/docs/FaxLineCreateRequest.md @@ -8,6 +8,6 @@ | ---- | ---- | ----------- | ----- | | `area_code`*_required_ | ```String``` | Area code | | | `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | -| `city`*_required_ | ```String``` | City | | +| `city` | ```String``` | City | | | `account_id` | ```String``` | Account ID | | diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb index fd9b9535b..33f4c7f55 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb @@ -133,10 +133,6 @@ def list_invalid_properties invalid_properties.push('invalid value for "country", country cannot be nil.') end - if @city.nil? - invalid_properties.push('invalid value for "city", city cannot be nil.') - end - invalid_properties end @@ -145,7 +141,6 @@ def list_invalid_properties def valid? return false if @area_code.nil? return false if @country.nil? - return false if @city.nil? true end From c0b806c59d9f3e953da98080937846353bd9dfb9 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Tue, 13 Aug 2024 15:35:55 -0400 Subject: [PATCH 05/12] new line --- examples/json/FaxLineAddUserRequestExample.json | 2 +- examples/json/FaxLineAreaCodeGetResponseExample.json | 2 +- examples/json/FaxLineCreateRequestExample.json | 2 +- examples/json/FaxLineDeleteRequestExample.json | 2 +- examples/json/FaxLineListResponseExample.json | 2 +- examples/json/FaxLineRemoveUserRequestExample.json | 2 +- examples/json/FaxLineResponseExample.json | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/examples/json/FaxLineAddUserRequestExample.json b/examples/json/FaxLineAddUserRequestExample.json index 6c10a0a5f..405f23102 100644 --- a/examples/json/FaxLineAddUserRequestExample.json +++ b/examples/json/FaxLineAddUserRequestExample.json @@ -1,4 +1,4 @@ { "number": "[FAX_NUMBER]", "email_address": "member@dropboxsign.com" -} \ No newline at end of file +} diff --git a/examples/json/FaxLineAreaCodeGetResponseExample.json b/examples/json/FaxLineAreaCodeGetResponseExample.json index 244cc210b..d31da0dc5 100644 --- a/examples/json/FaxLineAreaCodeGetResponseExample.json +++ b/examples/json/FaxLineAreaCodeGetResponseExample.json @@ -31,4 +31,4 @@ "949", "951" ] -} \ No newline at end of file +} diff --git a/examples/json/FaxLineCreateRequestExample.json b/examples/json/FaxLineCreateRequestExample.json index 54641a7cb..b7496d600 100644 --- a/examples/json/FaxLineCreateRequestExample.json +++ b/examples/json/FaxLineCreateRequestExample.json @@ -1,4 +1,4 @@ { "area_code": "209", "country": "US" -} \ No newline at end of file +} diff --git a/examples/json/FaxLineDeleteRequestExample.json b/examples/json/FaxLineDeleteRequestExample.json index ef20a9cd2..4bc5f0b67 100644 --- a/examples/json/FaxLineDeleteRequestExample.json +++ b/examples/json/FaxLineDeleteRequestExample.json @@ -1,3 +1,3 @@ { "number": "[FAX_NUMBER]", -} \ No newline at end of file +} diff --git a/examples/json/FaxLineListResponseExample.json b/examples/json/FaxLineListResponseExample.json index da1ec2cbb..39ec60ac3 100644 --- a/examples/json/FaxLineListResponseExample.json +++ b/examples/json/FaxLineListResponseExample.json @@ -21,4 +21,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/examples/json/FaxLineRemoveUserRequestExample.json b/examples/json/FaxLineRemoveUserRequestExample.json index 6c10a0a5f..405f23102 100644 --- a/examples/json/FaxLineRemoveUserRequestExample.json +++ b/examples/json/FaxLineRemoveUserRequestExample.json @@ -1,4 +1,4 @@ { "number": "[FAX_NUMBER]", "email_address": "member@dropboxsign.com" -} \ No newline at end of file +} diff --git a/examples/json/FaxLineResponseExample.json b/examples/json/FaxLineResponseExample.json index 8ba2454b8..9e4656f7c 100644 --- a/examples/json/FaxLineResponseExample.json +++ b/examples/json/FaxLineResponseExample.json @@ -13,4 +13,4 @@ } ] } -} \ No newline at end of file +} From fb837ca1b2b66a8ca4110f516e26021f8f2e8cad Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Tue, 20 Aug 2024 14:52:46 -0400 Subject: [PATCH 06/12] F recursive schema reference and update SDK usage examples --- examples/FaxLineAreaCodeGet.cs | 2 +- examples/FaxLineAreaCodeGet.java | 2 +- examples/FaxLineAreaCodeGet.php | 6 +- examples/FaxLineAreaCodeGet.py | 4 +- examples/FaxLineAreaCodeGet.rb | 2 +- examples/FaxLineAreaCodeGet.ts | 2 +- openapi-raw.yaml | 103 +++++++++++++++++++++++++++++-- openapi-sdk.yaml | 103 +++++++++++++++++++++++++++++-- openapi.yaml | 103 +++++++++++++++++++++++++++++-- translations/en.yaml | 3 + 10 files changed, 301 insertions(+), 29 deletions(-) diff --git a/examples/FaxLineAreaCodeGet.cs b/examples/FaxLineAreaCodeGet.cs index cbcbc1cc8..3beedfef1 100644 --- a/examples/FaxLineAreaCodeGet.cs +++ b/examples/FaxLineAreaCodeGet.cs @@ -16,7 +16,7 @@ public static void Main() try { - var result = faxLineApi.FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + var result = faxLineApi.FaxLineAreaCodeGet("US", "CA"); Console.WriteLine(result); } catch (ApiException e) diff --git a/examples/FaxLineAreaCodeGet.java b/examples/FaxLineAreaCodeGet.java index 4e31521b9..1df071ab9 100644 --- a/examples/FaxLineAreaCodeGet.java +++ b/examples/FaxLineAreaCodeGet.java @@ -14,7 +14,7 @@ public static void main(String[] args) { var faxLineApi = new FaxLineApi(apiClient); try { - FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet("US", "CA"); System.out.println(result); } catch (ApiException e) { System.err.println("Status code: " + e.getCode()); diff --git a/examples/FaxLineAreaCodeGet.php b/examples/FaxLineAreaCodeGet.php index cefd7159c..c19f9e187 100644 --- a/examples/FaxLineAreaCodeGet.php +++ b/examples/FaxLineAreaCodeGet.php @@ -10,11 +10,7 @@ $faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); try { - $result = $faxLineApi->faxLineAreaCodeGet( - Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum::US, - Dropbox\Sign\Model\FaxLineAreaCodeGetStateEnum::CA, - ); - + $result = $faxLineApi->faxLineAreaCodeGet("US", "CA"); print_r($result); } catch (Dropbox\Sign\ApiException $e) { $error = $e->getResponseObject(); diff --git a/examples/FaxLineAreaCodeGet.py b/examples/FaxLineAreaCodeGet.py index 9e5225849..8a4637352 100644 --- a/examples/FaxLineAreaCodeGet.py +++ b/examples/FaxLineAreaCodeGet.py @@ -1,7 +1,7 @@ from pprint import pprint from dropbox_sign import \ - ApiClient, ApiException, Configuration, apis, models + ApiClient, ApiException, Configuration, apis configuration = Configuration( # Configure HTTP basic authorization: api_key @@ -12,7 +12,7 @@ fax_line_api = apis.FaxLineApi(api_client) try: - response = fax_line_api.fax_line_area_code_get(models.FaxLineAreaCodeGetCountryEnum("US"), models.FaxLineAreaCodeGetStateEnum("CA")) + response = fax_line_api.fax_line_area_code_get("US", "CA") pprint(response) except ApiException as e: print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineAreaCodeGet.rb b/examples/FaxLineAreaCodeGet.rb index 6b39d770b..571fb4f58 100644 --- a/examples/FaxLineAreaCodeGet.rb +++ b/examples/FaxLineAreaCodeGet.rb @@ -8,7 +8,7 @@ fax_line_api = Dropbox::Sign::FaxLineApi.new begin - result = fax_line_api.fax_line_area_code_get(Dropbox::Sign::FaxLineAreaCodeGetCountryEnum::US, Dropbox::Sign::FaxLineAreaCodeGetStateEnum::CA) + result = fax_line_api.fax_line_area_code_get("US", "CA") p result rescue Dropbox::Sign::ApiError => e puts "Exception when calling Dropbox Sign API: #{e}" diff --git a/examples/FaxLineAreaCodeGet.ts b/examples/FaxLineAreaCodeGet.ts index 6984df6ea..bfc908f18 100644 --- a/examples/FaxLineAreaCodeGet.ts +++ b/examples/FaxLineAreaCodeGet.ts @@ -5,7 +5,7 @@ const faxLineApi = new DropboxSign.FaxLineApi(); // Configure HTTP basic authorization: api_key faxLineApi.username = "YOUR_API_KEY"; -const result = faxLineApi.faxLineAreaCodeGet(DropboxSign.FaxLineAreaCodeGetCountryEnum.Us, DropboxSign.FaxLineAreaCodeGetStateEnum.Ca); +const result = faxLineApi.faxLineAreaCodeGet("US", "CA"); result.then(response => { console.log(response.body); }).catch(error => { diff --git a/openapi-raw.yaml b/openapi-raw.yaml index 8d09e05e8..71c03f169 100644 --- a/openapi-raw.yaml +++ b/openapi-raw.yaml @@ -1517,19 +1517,89 @@ paths: description: '_t__FaxLineAreaCodeGet::COUNTRY' required: true schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + type: string + enum: + - CA + - US + - UK - name: state in: query description: '_t__FaxLineAreaCodeGet::STATE' schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetStateEnum' + type: string + enum: + - AK + - AL + - AR + - AZ + - CA + - CO + - CT + - DC + - DE + - FL + - GA + - HI + - IA + - ID + - IL + - IN + - KS + - KY + - LA + - MA + - MD + - ME + - MI + - MN + - MO + - MS + - MT + - NC + - ND + - NE + - NH + - NJ + - NM + - NV + - NY + - OH + - OK + - OR + - PA + - RI + - SC + - SD + - TN + - TX + - UT + - VA + - VT + - WA + - WI + - WV + - WY - name: province in: query description: '_t__FaxLineAreaCodeGet::PROVINCE' schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetProvinceEnum' + type: string + enum: + - AB + - BC + - MB + - NB + - NL + - NT + - NS + - NU + - 'ON' + - PE + - QC + - SK + - YT - name: city in: query @@ -7142,7 +7212,12 @@ components: description: '_t__FaxLineCreate::AREA_CODE' type: string country: - $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + description: '_t__FaxLineCreate::COUNTRY' + type: string + enum: + - CA + - US + - UK city: description: '_t__FaxLineCreate::CITY' type: string @@ -9508,7 +9583,7 @@ components: FaxLineResponse: properties: fax_line: - $ref: '#/components/schemas/FaxLineResponse' + $ref: '#/components/schemas/FaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object @@ -9528,7 +9603,7 @@ components: fax_lines: type: array items: - $ref: '#/components/schemas/FaxLineResponse' + $ref: '#/components/schemas/FaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object @@ -9864,6 +9939,22 @@ components: description: '_t__ErrorResponseError::ERROR_NAME' type: string type: object + FaxLine: + properties: + number: + description: '_t__FaxLine::NUMBER' + type: string + created_at: + description: '_t__FaxLine::CREATED_AT' + type: string + updated_at: + description: '_t__FaxLine::UPDATED_AT' + type: string + accounts: + type: array + items: + $ref: '#/components/schemas/AccountResponse' + type: object ListInfoResponse: description: '_t__ListInfoResponse::DESCRIPTION' properties: diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index d013b2fb1..d1175f106 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -1523,19 +1523,89 @@ paths: description: 'Filter area codes by country.' required: true schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + type: string + enum: + - CA + - US + - UK - name: state in: query description: 'Filter area codes by state.' schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetStateEnum' + type: string + enum: + - AK + - AL + - AR + - AZ + - CA + - CO + - CT + - DC + - DE + - FL + - GA + - HI + - IA + - ID + - IL + - IN + - KS + - KY + - LA + - MA + - MD + - ME + - MI + - MN + - MO + - MS + - MT + - NC + - ND + - NE + - NH + - NJ + - NM + - NV + - NY + - OH + - OK + - OR + - PA + - RI + - SC + - SD + - TN + - TX + - UT + - VA + - VT + - WA + - WI + - WV + - WY - name: province in: query description: 'Filter area codes by province.' schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetProvinceEnum' + type: string + enum: + - AB + - BC + - MB + - NB + - NL + - NT + - NS + - NU + - 'ON' + - PE + - QC + - SK + - YT - name: city in: query @@ -7236,7 +7306,12 @@ components: description: 'Area code' type: string country: - $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + description: Country + type: string + enum: + - CA + - US + - UK city: description: City type: string @@ -10116,7 +10191,7 @@ components: FaxLineResponse: properties: fax_line: - $ref: '#/components/schemas/FaxLineResponse' + $ref: '#/components/schemas/FaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object @@ -10136,7 +10211,7 @@ components: fax_lines: type: array items: - $ref: '#/components/schemas/FaxLineResponse' + $ref: '#/components/schemas/FaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object @@ -10472,6 +10547,22 @@ components: description: 'Name of the error.' type: string type: object + FaxLine: + properties: + number: + description: Number + type: string + created_at: + description: 'Created at' + type: string + updated_at: + description: 'Updated at' + type: string + accounts: + type: array + items: + $ref: '#/components/schemas/AccountResponse' + type: object ListInfoResponse: description: 'Contains pagination information about the data returned.' properties: diff --git a/openapi.yaml b/openapi.yaml index 94a9b40aa..9fd92b9b7 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1523,19 +1523,89 @@ paths: description: 'Filter area codes by country.' required: true schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + type: string + enum: + - CA + - US + - UK - name: state in: query description: 'Filter area codes by state.' schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetStateEnum' + type: string + enum: + - AK + - AL + - AR + - AZ + - CA + - CO + - CT + - DC + - DE + - FL + - GA + - HI + - IA + - ID + - IL + - IN + - KS + - KY + - LA + - MA + - MD + - ME + - MI + - MN + - MO + - MS + - MT + - NC + - ND + - NE + - NH + - NJ + - NM + - NV + - NY + - OH + - OK + - OR + - PA + - RI + - SC + - SD + - TN + - TX + - UT + - VA + - VT + - WA + - WI + - WV + - WY - name: province in: query description: 'Filter area codes by province.' schema: - $ref: '#/components/schemas/FaxLineAreaCodeGetProvinceEnum' + type: string + enum: + - AB + - BC + - MB + - NB + - NL + - NT + - NS + - NU + - 'ON' + - PE + - QC + - SK + - YT - name: city in: query @@ -7236,7 +7306,12 @@ components: description: 'Area code' type: string country: - $ref: '#/components/schemas/FaxLineAreaCodeGetCountryEnum' + description: Country + type: string + enum: + - CA + - US + - UK city: description: City type: string @@ -10094,7 +10169,7 @@ components: FaxLineResponse: properties: fax_line: - $ref: '#/components/schemas/FaxLineResponse' + $ref: '#/components/schemas/FaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object @@ -10114,7 +10189,7 @@ components: fax_lines: type: array items: - $ref: '#/components/schemas/FaxLineResponse' + $ref: '#/components/schemas/FaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object @@ -10450,6 +10525,22 @@ components: description: 'Name of the error.' type: string type: object + FaxLine: + properties: + number: + description: Number + type: string + created_at: + description: 'Created at' + type: string + updated_at: + description: 'Updated at' + type: string + accounts: + type: array + items: + $ref: '#/components/schemas/AccountResponse' + type: object ListInfoResponse: description: 'Contains pagination information about the data returned.' properties: diff --git a/translations/en.yaml b/translations/en.yaml index cb5662e71..10d6c251c 100644 --- a/translations/en.yaml +++ b/translations/en.yaml @@ -163,6 +163,9 @@ "FaxLineResponseExample::SUMMARY": Sample Fax Line Response "FaxLineAreaCodeGetResponseExample::SUMMARY": Sample Area Code Response "FaxLineListResponseExample::SUMMARY": Sample Fax Line List Response +"FaxLine::NUMBER": Number +"FaxLine::CREATED_AT": Created at +"FaxLine::UPDATED_AT": Updated at "OAuthTokenGenerate::SUMMARY": OAuth Token Generate "OAuthTokenGenerate::DESCRIPTION": Once you have retrieved the code from the user callback, you will need to exchange it for an access token via a backend call. From 456e2a17a532a1a93c7a51c6707609caa9698c9e Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Wed, 21 Aug 2024 16:06:01 -0400 Subject: [PATCH 07/12] regenerate sdks --- sdks/dotnet/README.md | 1 + sdks/dotnet/docs/FaxLine.md | 13 + sdks/dotnet/docs/FaxLineApi.md | 10 +- sdks/dotnet/docs/FaxLineCreateRequest.md | 2 +- sdks/dotnet/docs/FaxLineListResponse.md | 2 +- sdks/dotnet/docs/FaxLineResponse.md | 2 +- .../dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs | 28 +- sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs | 241 ++++++++++ .../Model/FaxLineCreateRequest.cs | 38 +- .../Dropbox.Sign/Model/FaxLineListResponse.cs | 6 +- .../src/Dropbox.Sign/Model/FaxLineResponse.cs | 6 +- sdks/java-v1/README.md | 1 + sdks/java-v1/docs/FaxLine.md | 17 + sdks/java-v1/docs/FaxLineApi.md | 8 +- sdks/java-v1/docs/FaxLineCreateRequest.md | 12 +- sdks/java-v1/docs/FaxLineListResponse.md | 2 +- sdks/java-v1/docs/FaxLineResponse.md | 2 +- .../java/com/dropbox/sign/api/FaxLineApi.java | 43 +- .../java/com/dropbox/sign/model/FaxLine.java | 345 ++++++++++++++ .../sign/model/FaxLineCreateRequest.java | 50 +- .../sign/model/FaxLineListResponse.java | 12 +- .../dropbox/sign/model/FaxLineResponse.java | 9 +- sdks/java-v2/README.md | 1 + sdks/java-v2/docs/FaxLine.md | 17 + sdks/java-v2/docs/FaxLineApi.md | 8 +- sdks/java-v2/docs/FaxLineCreateRequest.md | 12 +- sdks/java-v2/docs/FaxLineListResponse.md | 2 +- sdks/java-v2/docs/FaxLineResponse.md | 2 +- .../java/com/dropbox/sign/api/FaxLineApi.java | 43 +- .../java/com/dropbox/sign/model/FaxLine.java | 345 ++++++++++++++ .../sign/model/FaxLineCreateRequest.java | 50 +- .../sign/model/FaxLineListResponse.java | 12 +- .../dropbox/sign/model/FaxLineResponse.java | 9 +- sdks/node/README.md | 1 + sdks/node/api/faxLineApi.ts | 79 +++- sdks/node/dist/api.js | 204 +++++---- sdks/node/docs/api/FaxLineApi.md | 10 +- sdks/node/docs/model/FaxLine.md | 14 + sdks/node/docs/model/FaxLineCreateRequest.md | 2 +- sdks/node/docs/model/FaxLineListResponse.md | 2 +- sdks/node/docs/model/FaxLineResponse.md | 2 +- sdks/node/model/faxLine.ts | 76 +++ sdks/node/model/faxLineCreateRequest.ts | 16 +- sdks/node/model/faxLineListResponse.ts | 6 +- sdks/node/model/faxLineResponse.ts | 5 +- sdks/node/model/index.ts | 4 + sdks/node/types/api/faxLineApi.d.ts | 4 +- sdks/node/types/model/faxLine.d.ts | 12 + .../types/model/faxLineCreateRequest.d.ts | 10 +- .../node/types/model/faxLineListResponse.d.ts | 4 +- sdks/node/types/model/faxLineResponse.d.ts | 3 +- sdks/node/types/model/index.d.ts | 3 +- sdks/php/README.md | 1 + sdks/php/docs/Api/FaxLineApi.md | 12 +- sdks/php/docs/Model/FaxLine.md | 14 + sdks/php/docs/Model/FaxLineCreateRequest.md | 2 +- sdks/php/docs/Model/FaxLineListResponse.md | 2 +- sdks/php/docs/Model/FaxLineResponse.md | 2 +- sdks/php/src/Api/FaxLineApi.php | 40 +- sdks/php/src/Model/FaxLine.php | 431 ++++++++++++++++++ sdks/php/src/Model/FaxLineCreateRequest.php | 45 +- sdks/php/src/Model/FaxLineListResponse.php | 6 +- sdks/php/src/Model/FaxLineResponse.php | 8 +- sdks/python/.openapi-generator/FILES | 2 + sdks/python/README.md | 1 + sdks/python/docs/FaxLine.md | 17 + sdks/python/docs/FaxLineApi.md | 10 +- sdks/python/docs/FaxLineCreateRequest.md | 2 +- sdks/python/docs/FaxLineListResponse.md | 2 +- sdks/python/docs/FaxLineResponse.md | 2 +- sdks/python/dropbox_sign/api/fax_line_api.py | 94 +++- sdks/python/dropbox_sign/model/fax_line.py | 327 +++++++++++++ .../model/fax_line_create_request.py | 23 +- .../model/fax_line_list_response.py | 16 +- .../dropbox_sign/model/fax_line_response.py | 13 +- sdks/python/dropbox_sign/models/__init__.py | 1 + sdks/ruby/.openapi-generator/FILES | 2 + sdks/ruby/README.md | 1 + sdks/ruby/docs/FaxLine.md | 13 + sdks/ruby/docs/FaxLineApi.md | 8 +- sdks/ruby/docs/FaxLineCreateRequest.md | 2 +- sdks/ruby/docs/FaxLineListResponse.md | 2 +- sdks/ruby/docs/FaxLineResponse.md | 2 +- sdks/ruby/lib/dropbox-sign.rb | 1 + .../ruby/lib/dropbox-sign/api/fax_line_api.rb | 25 +- sdks/ruby/lib/dropbox-sign/models/fax_line.rb | 285 ++++++++++++ .../models/fax_line_create_request.rb | 39 +- .../models/fax_line_list_response.rb | 4 +- .../dropbox-sign/models/fax_line_response.rb | 4 +- 89 files changed, 2932 insertions(+), 337 deletions(-) create mode 100644 sdks/dotnet/docs/FaxLine.md create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs create mode 100644 sdks/java-v1/docs/FaxLine.md create mode 100644 sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java create mode 100644 sdks/java-v2/docs/FaxLine.md create mode 100644 sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java create mode 100644 sdks/node/docs/model/FaxLine.md create mode 100644 sdks/node/model/faxLine.ts create mode 100644 sdks/node/types/model/faxLine.d.ts create mode 100644 sdks/php/docs/Model/FaxLine.md create mode 100644 sdks/php/src/Model/FaxLine.php create mode 100644 sdks/python/docs/FaxLine.md create mode 100644 sdks/python/dropbox_sign/model/fax_line.py create mode 100644 sdks/ruby/docs/FaxLine.md create mode 100644 sdks/ruby/lib/dropbox-sign/models/fax_line.rb diff --git a/sdks/dotnet/README.md b/sdks/dotnet/README.md index f9358f79a..45490c5fc 100644 --- a/sdks/dotnet/README.md +++ b/sdks/dotnet/README.md @@ -227,6 +227,7 @@ Class | Method | HTTP request | Description - [Model.EventCallbackRequest](docs/EventCallbackRequest.md) - [Model.EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [Model.EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [Model.FaxLine](docs/FaxLine.md) - [Model.FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [Model.FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [Model.FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/dotnet/docs/FaxLine.md b/sdks/dotnet/docs/FaxLine.md new file mode 100644 index 000000000..203c125fc --- /dev/null +++ b/sdks/dotnet/docs/FaxLine.md @@ -0,0 +1,13 @@ +# Dropbox.Sign.Model.FaxLine + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Number** | **string** | Number | [optional] +**CreatedAt** | **string** | Created at | [optional] +**UpdatedAt** | **string** | Updated at | [optional] +**Accounts** | [**List<AccountResponse>**](AccountResponse.md) | | [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/sdks/dotnet/docs/FaxLineApi.md b/sdks/dotnet/docs/FaxLineApi.md index cb3e649e6..7a3a4aa3a 100644 --- a/sdks/dotnet/docs/FaxLineApi.md +++ b/sdks/dotnet/docs/FaxLineApi.md @@ -109,7 +109,7 @@ catch (ApiException e) # **FaxLineAreaCodeGet** -> FaxLineAreaCodeGetResponse FaxLineAreaCodeGet (FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = null, FaxLineAreaCodeGetProvinceEnum? province = null, string? city = null) +> FaxLineAreaCodeGetResponse FaxLineAreaCodeGet (string country, string? state = null, string? province = null, string? city = null) Get Available Fax Line Area Codes @@ -135,7 +135,7 @@ public class Example try { - var result = faxLineApi.FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + var result = faxLineApi.FaxLineAreaCodeGet("US", "CA"); Console.WriteLine(result); } catch (ApiException e) @@ -173,9 +173,9 @@ catch (ApiException e) | Name | Type | Description | Notes | |------|------|-------------|-------| -| **country** | **FaxLineAreaCodeGetCountryEnum** | Filter area codes by country. | | -| **state** | [**FaxLineAreaCodeGetStateEnum?**](FaxLineAreaCodeGetStateEnum?.md) | Filter area codes by state. | [optional] | -| **province** | [**FaxLineAreaCodeGetProvinceEnum?**](FaxLineAreaCodeGetProvinceEnum?.md) | Filter area codes by province. | [optional] | +| **country** | **string** | Filter area codes by country. | | +| **state** | **string?** | Filter area codes by state. | [optional] | +| **province** | **string?** | Filter area codes by province. | [optional] | | **city** | **string?** | Filter area codes by city. | [optional] | ### Return type diff --git a/sdks/dotnet/docs/FaxLineCreateRequest.md b/sdks/dotnet/docs/FaxLineCreateRequest.md index d0aa274d3..b5515e964 100644 --- a/sdks/dotnet/docs/FaxLineCreateRequest.md +++ b/sdks/dotnet/docs/FaxLineCreateRequest.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AreaCode** | **string** | Area code | -**Country** | **FaxLineAreaCodeGetCountryEnum** | | +**Country** | **string** | Country | **City** | **string** | City | [optional] **AccountId** | **string** | Account ID | [optional] diff --git a/sdks/dotnet/docs/FaxLineListResponse.md b/sdks/dotnet/docs/FaxLineListResponse.md index a8e55b5d1..bfa7103cf 100644 --- a/sdks/dotnet/docs/FaxLineListResponse.md +++ b/sdks/dotnet/docs/FaxLineListResponse.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **ListInfo** | [**ListInfoResponse**](ListInfoResponse.md) | | [optional] -**FaxLines** | [**List<FaxLineResponse>**](FaxLineResponse.md) | | [optional] +**FaxLines** | [**List<FaxLine>**](FaxLine.md) | | [optional] **Warnings** | [**WarningResponse**](WarningResponse.md) | | [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/sdks/dotnet/docs/FaxLineResponse.md b/sdks/dotnet/docs/FaxLineResponse.md index 2be5447e6..2fbf2c11d 100644 --- a/sdks/dotnet/docs/FaxLineResponse.md +++ b/sdks/dotnet/docs/FaxLineResponse.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**FaxLine** | [**FaxLineResponse**](FaxLineResponse.md) | | [optional] +**FaxLine** | [**FaxLine**](FaxLine.md) | | [optional] **Warnings** | [**WarningResponse**](WarningResponse.md) | | [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/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs index d5770080f..1b1ac8a0b 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs @@ -63,7 +63,7 @@ public interface IFaxLineApiSync : IApiAccessor /// Filter area codes by city. (optional) /// Index associated with the operation. /// FaxLineAreaCodeGetResponse - FaxLineAreaCodeGetResponse FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0); + FaxLineAreaCodeGetResponse FaxLineAreaCodeGet(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0); /// /// Get Available Fax Line Area Codes @@ -78,7 +78,7 @@ public interface IFaxLineApiSync : IApiAccessor /// Filter area codes by city. (optional) /// Index associated with the operation. /// ApiResponse of FaxLineAreaCodeGetResponse - ApiResponse FaxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0); + ApiResponse FaxLineAreaCodeGetWithHttpInfo(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0); /// /// Purchase Fax Line /// @@ -248,7 +248,7 @@ public interface IFaxLineApiAsync : IApiAccessor /// Index associated with the operation. /// Cancellation Token to cancel the request. /// Task of FaxLineAreaCodeGetResponse - System.Threading.Tasks.Task FaxLineAreaCodeGetAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + System.Threading.Tasks.Task FaxLineAreaCodeGetAsync(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); /// /// Get Available Fax Line Area Codes @@ -264,7 +264,7 @@ public interface IFaxLineApiAsync : IApiAccessor /// Index associated with the operation. /// Cancellation Token to cancel the request. /// Task of ApiResponse (FaxLineAreaCodeGetResponse) - System.Threading.Tasks.Task> FaxLineAreaCodeGetWithHttpInfoAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); + System.Threading.Tasks.Task> FaxLineAreaCodeGetWithHttpInfoAsync(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); /// /// Purchase Fax Line /// @@ -696,7 +696,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpIn /// Filter area codes by city. (optional) /// Index associated with the operation. /// FaxLineAreaCodeGetResponse - public FaxLineAreaCodeGetResponse FaxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0) + public FaxLineAreaCodeGetResponse FaxLineAreaCodeGet(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0) { Dropbox.Sign.Client.ApiResponse localVarResponse = FaxLineAreaCodeGetWithHttpInfo(country, state, province, city); return localVarResponse.Data; @@ -712,8 +712,14 @@ public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpIn /// Filter area codes by city. (optional) /// Index associated with the operation. /// ApiResponse of FaxLineAreaCodeGetResponse - public Dropbox.Sign.Client.ApiResponse FaxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0) + public Dropbox.Sign.Client.ApiResponse FaxLineAreaCodeGetWithHttpInfo(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0) { + // verify the required parameter 'country' is set + if (country == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'country' when calling FaxLineApi->FaxLineAreaCodeGet"); + } + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); string[] _contentTypes = new string[] { @@ -784,7 +790,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpIn /// Index associated with the operation. /// Cancellation Token to cancel the request. /// Task of FaxLineAreaCodeGetResponse - public async System.Threading.Tasks.Task FaxLineAreaCodeGetAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + public async System.Threading.Tasks.Task FaxLineAreaCodeGetAsync(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { Dropbox.Sign.Client.ApiResponse localVarResponse = await FaxLineAreaCodeGetWithHttpInfoAsync(country, state, province, city, operationIndex, cancellationToken).ConfigureAwait(false); return localVarResponse.Data; @@ -801,8 +807,14 @@ public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpIn /// Index associated with the operation. /// Cancellation Token to cancel the request. /// Task of ApiResponse (FaxLineAreaCodeGetResponse) - public async System.Threading.Tasks.Task> FaxLineAreaCodeGetWithHttpInfoAsync(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum? state = default(FaxLineAreaCodeGetStateEnum?), FaxLineAreaCodeGetProvinceEnum? province = default(FaxLineAreaCodeGetProvinceEnum?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) + public async System.Threading.Tasks.Task> FaxLineAreaCodeGetWithHttpInfoAsync(string country, string? state = default(string?), string? province = default(string?), string? city = default(string?), int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { + // verify the required parameter 'country' is set + if (country == null) + { + throw new Dropbox.Sign.Client.ApiException(400, "Missing required parameter 'country' when calling FaxLineApi->FaxLineAreaCodeGet"); + } + Dropbox.Sign.Client.RequestOptions localVarRequestOptions = new Dropbox.Sign.Client.RequestOptions(); diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs new file mode 100644 index 000000000..8ded1b15c --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs @@ -0,0 +1,241 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLine + /// + [DataContract(Name = "FaxLine")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLine : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLine() { } + /// + /// Initializes a new instance of the class. + /// + /// Number. + /// Created at. + /// Updated at. + /// accounts. + public FaxLine(string number = default(string), string createdAt = default(string), string updatedAt = default(string), List accounts = default(List)) + { + + this.Number = number; + this.CreatedAt = createdAt; + this.UpdatedAt = updatedAt; + this.Accounts = accounts; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLine Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLine"); + } + + return obj; + } + + /// + /// Number + /// + /// Number + [DataMember(Name = "number", EmitDefaultValue = true)] + public string Number { get; set; } + + /// + /// Created at + /// + /// Created at + [DataMember(Name = "created_at", EmitDefaultValue = true)] + public string CreatedAt { get; set; } + + /// + /// Updated at + /// + /// Updated at + [DataMember(Name = "updated_at", EmitDefaultValue = true)] + public string UpdatedAt { get; set; } + + /// + /// Gets or Sets Accounts + /// + [DataMember(Name = "accounts", EmitDefaultValue = true)] + public List Accounts { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLine {\n"); + sb.Append(" Number: ").Append(Number).Append("\n"); + sb.Append(" CreatedAt: ").Append(CreatedAt).Append("\n"); + sb.Append(" UpdatedAt: ").Append(UpdatedAt).Append("\n"); + sb.Append(" Accounts: ").Append(Accounts).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLine); + } + + /// + /// Returns true if FaxLine instances are equal + /// + /// Instance of FaxLine to be compared + /// Boolean + public bool Equals(FaxLine input) + { + if (input == null) + { + return false; + } + return + ( + this.Number == input.Number || + (this.Number != null && + this.Number.Equals(input.Number)) + ) && + ( + this.CreatedAt == input.CreatedAt || + (this.CreatedAt != null && + this.CreatedAt.Equals(input.CreatedAt)) + ) && + ( + this.UpdatedAt == input.UpdatedAt || + (this.UpdatedAt != null && + this.UpdatedAt.Equals(input.UpdatedAt)) + ) && + ( + this.Accounts == input.Accounts || + this.Accounts != null && + input.Accounts != null && + this.Accounts.SequenceEqual(input.Accounts) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Number != null) + { + hashCode = (hashCode * 59) + this.Number.GetHashCode(); + } + if (this.CreatedAt != null) + { + hashCode = (hashCode * 59) + this.CreatedAt.GetHashCode(); + } + if (this.UpdatedAt != null) + { + hashCode = (hashCode * 59) + this.UpdatedAt.GetHashCode(); + } + if (this.Accounts != null) + { + hashCode = (hashCode * 59) + this.Accounts.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "number", + Property = "Number", + Type = "string", + Value = Number, + }); + types.Add(new OpenApiType(){ + Name = "created_at", + Property = "CreatedAt", + Type = "string", + Value = CreatedAt, + }); + types.Add(new OpenApiType(){ + Name = "updated_at", + Property = "UpdatedAt", + Type = "string", + Value = UpdatedAt, + }); + types.Add(new OpenApiType(){ + Name = "accounts", + Property = "Accounts", + Type = "List", + Value = Accounts, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs index ac38bc300..781121388 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs @@ -33,12 +33,40 @@ namespace Dropbox.Sign.Model [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] public partial class FaxLineCreateRequest : IOpenApiTyped, IEquatable, IValidatableObject { + /// + /// Country + /// + /// Country + [JsonConverter(typeof(StringEnumConverter))] + public enum CountryEnum + { + /// + /// Enum CA for value: CA + /// + [EnumMember(Value = "CA")] + CA = 1, + + /// + /// Enum US for value: US + /// + [EnumMember(Value = "US")] + US = 2, + + /// + /// Enum UK for value: UK + /// + [EnumMember(Value = "UK")] + UK = 3 + + } + /// - /// Gets or Sets Country + /// Country /// + /// Country [DataMember(Name = "country", IsRequired = true, EmitDefaultValue = true)] - public FaxLineAreaCodeGetCountryEnum Country { get; set; } + public CountryEnum Country { get; set; } /// /// Initializes a new instance of the class. /// @@ -48,10 +76,10 @@ protected FaxLineCreateRequest() { } /// Initializes a new instance of the class. /// /// Area code (required). - /// country (required). + /// Country (required). /// City. /// Account ID. - public FaxLineCreateRequest(string areaCode = default(string), FaxLineAreaCodeGetCountryEnum country = default(FaxLineAreaCodeGetCountryEnum), string city = default(string), string accountId = default(string)) + public FaxLineCreateRequest(string areaCode = default(string), CountryEnum country = default(CountryEnum), string city = default(string), string accountId = default(string)) { // to ensure "areaCode" is required (not null) @@ -208,7 +236,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "country", Property = "Country", - Type = "FaxLineAreaCodeGetCountryEnum", + Type = "string", Value = Country, }); types.Add(new OpenApiType(){ diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs index 19367d5d1..139ef24a3 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs @@ -44,7 +44,7 @@ protected FaxLineListResponse() { } /// listInfo. /// faxLines. /// warnings. - public FaxLineListResponse(ListInfoResponse listInfo = default(ListInfoResponse), List faxLines = default(List), WarningResponse warnings = default(WarningResponse)) + public FaxLineListResponse(ListInfoResponse listInfo = default(ListInfoResponse), List faxLines = default(List), WarningResponse warnings = default(WarningResponse)) { this.ListInfo = listInfo; @@ -78,7 +78,7 @@ public static FaxLineListResponse Init(string jsonData) /// Gets or Sets FaxLines /// [DataMember(Name = "fax_lines", EmitDefaultValue = true)] - public List FaxLines { get; set; } + public List FaxLines { get; set; } /// /// Gets or Sets Warnings @@ -187,7 +187,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "fax_lines", Property = "FaxLines", - Type = "List", + Type = "List", Value = FaxLines, }); types.Add(new OpenApiType(){ diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs index d74b37b78..71157cdbe 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs @@ -43,7 +43,7 @@ protected FaxLineResponse() { } /// /// faxLine. /// warnings. - public FaxLineResponse(FaxLineResponse faxLine = default(FaxLineResponse), WarningResponse warnings = default(WarningResponse)) + public FaxLineResponse(FaxLine faxLine = default(FaxLine), WarningResponse warnings = default(WarningResponse)) { this.FaxLine = faxLine; @@ -70,7 +70,7 @@ public static FaxLineResponse Init(string jsonData) /// Gets or Sets FaxLine /// [DataMember(Name = "fax_line", EmitDefaultValue = true)] - public FaxLineResponse FaxLine { get; set; } + public FaxLine FaxLine { get; set; } /// /// Gets or Sets Warnings @@ -162,7 +162,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "fax_line", Property = "FaxLine", - Type = "FaxLineResponse", + Type = "FaxLine", Value = FaxLine, }); types.Add(new OpenApiType(){ diff --git a/sdks/java-v1/README.md b/sdks/java-v1/README.md index 023657591..76930afee 100644 --- a/sdks/java-v1/README.md +++ b/sdks/java-v1/README.md @@ -267,6 +267,7 @@ Class | Method | HTTP request | Description - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [FaxLine](docs/FaxLine.md) - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/java-v1/docs/FaxLine.md b/sdks/java-v1/docs/FaxLine.md new file mode 100644 index 000000000..5809f6353 --- /dev/null +++ b/sdks/java-v1/docs/FaxLine.md @@ -0,0 +1,17 @@ + + +# FaxLine + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number` | ```String``` | Number | | +| `createdAt` | ```String``` | Created at | | +| `updatedAt` | ```String``` | Updated at | | +| `accounts` | [```List```](AccountResponse.md) | | | + + + diff --git a/sdks/java-v1/docs/FaxLineApi.md b/sdks/java-v1/docs/FaxLineApi.md index c880cf75a..914ade392 100644 --- a/sdks/java-v1/docs/FaxLineApi.md +++ b/sdks/java-v1/docs/FaxLineApi.md @@ -112,7 +112,7 @@ public class Example { var faxLineApi = new FaxLineApi(apiClient); try { - FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet("US", "CA"); System.out.println(result); } catch (ApiException e) { System.err.println("Status code: " + e.getCode()); @@ -130,9 +130,9 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **country** | **FaxLineAreaCodeGetCountryEnum**| Filter area codes by country. | [enum: CA, US, UK] - **state** | **FaxLineAreaCodeGetStateEnum**| Filter area codes by state. | [optional] [enum: AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY] - **province** | **FaxLineAreaCodeGetProvinceEnum**| Filter area codes by province. | [optional] [enum: AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT] + **country** | **String**| Filter area codes by country. | [enum: CA, US, UK] + **state** | **String**| Filter area codes by state. | [optional] [enum: AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY] + **province** | **String**| Filter area codes by province. | [optional] [enum: AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT] **city** | **String**| Filter area codes by city. | [optional] ### Return type diff --git a/sdks/java-v1/docs/FaxLineCreateRequest.md b/sdks/java-v1/docs/FaxLineCreateRequest.md index eb52f48b9..e09db630f 100644 --- a/sdks/java-v1/docs/FaxLineCreateRequest.md +++ b/sdks/java-v1/docs/FaxLineCreateRequest.md @@ -9,9 +9,19 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `areaCode`*_required_ | ```String``` | Area code | | -| `country`*_required_ | ```FaxLineAreaCodeGetCountryEnum``` | | | +| `country`*_required_ | [```CountryEnum```](#CountryEnum) | Country | | | `city` | ```String``` | City | | | `accountId` | ```String``` | Account ID | | +## Enum: CountryEnum + +Name | Value +---- | ----- +| CA | "CA" | +| US | "US" | +| UK | "UK" | + + + diff --git a/sdks/java-v1/docs/FaxLineListResponse.md b/sdks/java-v1/docs/FaxLineListResponse.md index f4724aaae..6e01b30a1 100644 --- a/sdks/java-v1/docs/FaxLineListResponse.md +++ b/sdks/java-v1/docs/FaxLineListResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `faxLines` | [```List```](FaxLineResponse.md) | | | +| `faxLines` | [```List```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v1/docs/FaxLineResponse.md b/sdks/java-v1/docs/FaxLineResponse.md index 4e373231e..44a845b3c 100644 --- a/sdks/java-v1/docs/FaxLineResponse.md +++ b/sdks/java-v1/docs/FaxLineResponse.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `faxLine` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `faxLine` | [```FaxLine```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java index eb9dd8dc3..68181e632 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -10,10 +10,7 @@ import com.dropbox.sign.model.ErrorResponse; import com.dropbox.sign.model.FaxLineAddUserRequest; -import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; -import com.dropbox.sign.model.FaxLineAreaCodeGetProvinceEnum; import com.dropbox.sign.model.FaxLineAreaCodeGetResponse; -import com.dropbox.sign.model.FaxLineAreaCodeGetStateEnum; import com.dropbox.sign.model.FaxLineCreateRequest; import com.dropbox.sign.model.FaxLineDeleteRequest; import com.dropbox.sign.model.FaxLineListResponse; @@ -146,66 +143,66 @@ public ApiResponse faxLineAddUserWithHttpInfo(FaxLineAddUserReq 4XX failed_operation - */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country, String state, String province, String city) throws ApiException { return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGet(String, String, String, String) */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country) throws ApiException { - FaxLineAreaCodeGetStateEnum state = null; - FaxLineAreaCodeGetProvinceEnum province = null; + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country) throws ApiException { + String state = null; + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(String, String, String, String) */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country) throws ApiException { - FaxLineAreaCodeGetStateEnum state = null; - FaxLineAreaCodeGetProvinceEnum province = null; + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country) throws ApiException { + String state = null; + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); } /** - * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGet(String, String, String, String) */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { - FaxLineAreaCodeGetProvinceEnum province = null; + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country, String state) throws ApiException { + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(String, String, String, String) */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { - FaxLineAreaCodeGetProvinceEnum province = null; + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country, String state) throws ApiException { + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); } /** - * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGet(String, String, String, String) */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country, String state, String province) throws ApiException { String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(String, String, String, String) */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country, String state, String province) throws ApiException { String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); @@ -228,7 +225,7 @@ public ApiResponse faxLineAreaCodeGetWithHttpInfo(Fa 4XX failed_operation - */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country, String state, String province, String city) throws ApiException { Object localVarPostBody = null; diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java new file mode 100644 index 000000000..a29015958 --- /dev/null +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java @@ -0,0 +1,345 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Arrays; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.AccountResponse; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.util.ArrayList; +import java.util.List; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLine + */ +@JsonPropertyOrder({ + FaxLine.JSON_PROPERTY_NUMBER, + FaxLine.JSON_PROPERTY_CREATED_AT, + FaxLine.JSON_PROPERTY_UPDATED_AT, + FaxLine.JSON_PROPERTY_ACCOUNTS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLine { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public static final String JSON_PROPERTY_CREATED_AT = "created_at"; + private String createdAt; + + public static final String JSON_PROPERTY_UPDATED_AT = "updated_at"; + private String updatedAt; + + public static final String JSON_PROPERTY_ACCOUNTS = "accounts"; + private List accounts = null; + + public FaxLine() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLine init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLine.class); + } + + static public FaxLine init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLine.class + ); + } + + public FaxLine number(String number) { + this.number = number; + return this; + } + + /** + * Number + * @return number + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Number") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setNumber(String number) { + this.number = number; + } + + + public FaxLine createdAt(String createdAt) { + this.createdAt = createdAt; + return this; + } + + /** + * Created at + * @return createdAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Created at") + @JsonProperty(JSON_PROPERTY_CREATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getCreatedAt() { + return createdAt; + } + + + @JsonProperty(JSON_PROPERTY_CREATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setCreatedAt(String createdAt) { + this.createdAt = createdAt; + } + + + public FaxLine updatedAt(String updatedAt) { + this.updatedAt = updatedAt; + return this; + } + + /** + * Updated at + * @return updatedAt + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "Updated at") + @JsonProperty(JSON_PROPERTY_UPDATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getUpdatedAt() { + return updatedAt; + } + + + @JsonProperty(JSON_PROPERTY_UPDATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setUpdatedAt(String updatedAt) { + this.updatedAt = updatedAt; + } + + + public FaxLine accounts(List accounts) { + this.accounts = accounts; + return this; + } + + public FaxLine addAccountsItem(AccountResponse accountsItem) { + if (this.accounts == null) { + this.accounts = new ArrayList<>(); + } + this.accounts.add(accountsItem); + return this; + } + + /** + * Get accounts + * @return accounts + **/ + @javax.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_ACCOUNTS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public List getAccounts() { + return accounts; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNTS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccounts(List accounts) { + this.accounts = accounts; + } + + + /** + * Return true if this FaxLine object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLine faxLine = (FaxLine) o; + return Objects.equals(this.number, faxLine.number) && + Objects.equals(this.createdAt, faxLine.createdAt) && + Objects.equals(this.updatedAt, faxLine.updatedAt) && + Objects.equals(this.accounts, faxLine.accounts); + } + + @Override + public int hashCode() { + return Objects.hash(number, createdAt, updatedAt, accounts); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLine {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append(" accounts: ").append(toIndentedString(accounts)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + if (createdAt != null) { + if (isFileTypeOrListOfFiles(createdAt)) { + fileTypeFound = true; + } + + if (createdAt.getClass().equals(java.io.File.class) || + createdAt.getClass().equals(Integer.class) || + createdAt.getClass().equals(String.class) || + createdAt.getClass().isEnum()) { + map.put("created_at", createdAt); + } else if (isListOfFile(createdAt)) { + for(int i = 0; i< getListSize(createdAt); i++) { + map.put("created_at[" + i + "]", getFromList(createdAt, i)); + } + } + else { + map.put("created_at", JSON.getDefault().getMapper().writeValueAsString(createdAt)); + } + } + if (updatedAt != null) { + if (isFileTypeOrListOfFiles(updatedAt)) { + fileTypeFound = true; + } + + if (updatedAt.getClass().equals(java.io.File.class) || + updatedAt.getClass().equals(Integer.class) || + updatedAt.getClass().equals(String.class) || + updatedAt.getClass().isEnum()) { + map.put("updated_at", updatedAt); + } else if (isListOfFile(updatedAt)) { + for(int i = 0; i< getListSize(updatedAt); i++) { + map.put("updated_at[" + i + "]", getFromList(updatedAt, i)); + } + } + else { + map.put("updated_at", JSON.getDefault().getMapper().writeValueAsString(updatedAt)); + } + } + if (accounts != null) { + if (isFileTypeOrListOfFiles(accounts)) { + fileTypeFound = true; + } + + if (accounts.getClass().equals(java.io.File.class) || + accounts.getClass().equals(Integer.class) || + accounts.getClass().equals(String.class) || + accounts.getClass().isEnum()) { + map.put("accounts", accounts); + } else if (isListOfFile(accounts)) { + for(int i = 0; i< getListSize(accounts); i++) { + map.put("accounts[" + i + "]", getFromList(accounts, i)); + } + } + else { + map.put("accounts", JSON.getDefault().getMapper().writeValueAsString(accounts)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java index 57ea9672e..b7b5dacb3 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -17,7 +17,6 @@ import java.util.Arrays; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonCreator; @@ -47,8 +46,45 @@ public class FaxLineCreateRequest { public static final String JSON_PROPERTY_AREA_CODE = "area_code"; private String areaCode; + /** + * Country + */ + public enum CountryEnum { + CA("CA"), + + US("US"), + + UK("UK"); + + private String value; + + CountryEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static CountryEnum fromValue(String value) { + for (CountryEnum b : CountryEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + } + public static final String JSON_PROPERTY_COUNTRY = "country"; - private FaxLineAreaCodeGetCountryEnum country; + private CountryEnum country; public static final String JSON_PROPERTY_CITY = "city"; private String city; @@ -100,28 +136,28 @@ public void setAreaCode(String areaCode) { } - public FaxLineCreateRequest country(FaxLineAreaCodeGetCountryEnum country) { + public FaxLineCreateRequest country(CountryEnum country) { this.country = country; return this; } /** - * Get country + * Country * @return country **/ @javax.annotation.Nonnull - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(required = true, value = "Country") @JsonProperty(JSON_PROPERTY_COUNTRY) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public FaxLineAreaCodeGetCountryEnum getCountry() { + public CountryEnum getCountry() { return country; } @JsonProperty(JSON_PROPERTY_COUNTRY) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public void setCountry(FaxLineAreaCodeGetCountryEnum country) { + public void setCountry(CountryEnum country) { this.country = country; } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java index b744c0bde..87cf63eab 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java @@ -17,7 +17,7 @@ import java.util.Arrays; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLineResponse; +import com.dropbox.sign.model.FaxLine; import com.dropbox.sign.model.ListInfoResponse; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; @@ -51,7 +51,7 @@ public class FaxLineListResponse { private ListInfoResponse listInfo; public static final String JSON_PROPERTY_FAX_LINES = "fax_lines"; - private List faxLines = null; + private List faxLines = null; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -100,12 +100,12 @@ public void setListInfo(ListInfoResponse listInfo) { } - public FaxLineListResponse faxLines(List faxLines) { + public FaxLineListResponse faxLines(List faxLines) { this.faxLines = faxLines; return this; } - public FaxLineListResponse addFaxLinesItem(FaxLineResponse faxLinesItem) { + public FaxLineListResponse addFaxLinesItem(FaxLine faxLinesItem) { if (this.faxLines == null) { this.faxLines = new ArrayList<>(); } @@ -122,14 +122,14 @@ public FaxLineListResponse addFaxLinesItem(FaxLineResponse faxLinesItem) { @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public List getFaxLines() { + public List getFaxLines() { return faxLines; } @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLines(List faxLines) { + public void setFaxLines(List faxLines) { this.faxLines = faxLines; } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java index 62e1b7c64..77cb58fb1 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java @@ -17,6 +17,7 @@ import java.util.Arrays; import java.util.Map; import java.util.HashMap; +import com.dropbox.sign.model.FaxLine; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -43,7 +44,7 @@ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineResponse { public static final String JSON_PROPERTY_FAX_LINE = "fax_line"; - private FaxLineResponse faxLine; + private FaxLine faxLine; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -66,7 +67,7 @@ static public FaxLineResponse init(HashMap data) throws Exception { ); } - public FaxLineResponse faxLine(FaxLineResponse faxLine) { + public FaxLineResponse faxLine(FaxLine faxLine) { this.faxLine = faxLine; return this; } @@ -80,14 +81,14 @@ public FaxLineResponse faxLine(FaxLineResponse faxLine) { @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public FaxLineResponse getFaxLine() { + public FaxLine getFaxLine() { return faxLine; } @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLine(FaxLineResponse faxLine) { + public void setFaxLine(FaxLine faxLine) { this.faxLine = faxLine; } diff --git a/sdks/java-v2/README.md b/sdks/java-v2/README.md index ad91ca574..159e18eda 100644 --- a/sdks/java-v2/README.md +++ b/sdks/java-v2/README.md @@ -268,6 +268,7 @@ Class | Method | HTTP request | Description - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [FaxLine](docs/FaxLine.md) - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/java-v2/docs/FaxLine.md b/sdks/java-v2/docs/FaxLine.md new file mode 100644 index 000000000..5809f6353 --- /dev/null +++ b/sdks/java-v2/docs/FaxLine.md @@ -0,0 +1,17 @@ + + +# FaxLine + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number` | ```String``` | Number | | +| `createdAt` | ```String``` | Created at | | +| `updatedAt` | ```String``` | Updated at | | +| `accounts` | [```List```](AccountResponse.md) | | | + + + diff --git a/sdks/java-v2/docs/FaxLineApi.md b/sdks/java-v2/docs/FaxLineApi.md index c880cf75a..914ade392 100644 --- a/sdks/java-v2/docs/FaxLineApi.md +++ b/sdks/java-v2/docs/FaxLineApi.md @@ -112,7 +112,7 @@ public class Example { var faxLineApi = new FaxLineApi(apiClient); try { - FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum.US, FaxLineAreaCodeGetStateEnum.CA); + FaxLineAreaCodeGetResponse result = faxLineApi.faxLineAreaCodeGet("US", "CA"); System.out.println(result); } catch (ApiException e) { System.err.println("Status code: " + e.getCode()); @@ -130,9 +130,9 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **country** | **FaxLineAreaCodeGetCountryEnum**| Filter area codes by country. | [enum: CA, US, UK] - **state** | **FaxLineAreaCodeGetStateEnum**| Filter area codes by state. | [optional] [enum: AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY] - **province** | **FaxLineAreaCodeGetProvinceEnum**| Filter area codes by province. | [optional] [enum: AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT] + **country** | **String**| Filter area codes by country. | [enum: CA, US, UK] + **state** | **String**| Filter area codes by state. | [optional] [enum: AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY] + **province** | **String**| Filter area codes by province. | [optional] [enum: AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT] **city** | **String**| Filter area codes by city. | [optional] ### Return type diff --git a/sdks/java-v2/docs/FaxLineCreateRequest.md b/sdks/java-v2/docs/FaxLineCreateRequest.md index eb52f48b9..e09db630f 100644 --- a/sdks/java-v2/docs/FaxLineCreateRequest.md +++ b/sdks/java-v2/docs/FaxLineCreateRequest.md @@ -9,9 +9,19 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `areaCode`*_required_ | ```String``` | Area code | | -| `country`*_required_ | ```FaxLineAreaCodeGetCountryEnum``` | | | +| `country`*_required_ | [```CountryEnum```](#CountryEnum) | Country | | | `city` | ```String``` | City | | | `accountId` | ```String``` | Account ID | | +## Enum: CountryEnum + +Name | Value +---- | ----- +| CA | "CA" | +| US | "US" | +| UK | "UK" | + + + diff --git a/sdks/java-v2/docs/FaxLineListResponse.md b/sdks/java-v2/docs/FaxLineListResponse.md index f4724aaae..6e01b30a1 100644 --- a/sdks/java-v2/docs/FaxLineListResponse.md +++ b/sdks/java-v2/docs/FaxLineListResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `faxLines` | [```List```](FaxLineResponse.md) | | | +| `faxLines` | [```List```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v2/docs/FaxLineResponse.md b/sdks/java-v2/docs/FaxLineResponse.md index 4e373231e..44a845b3c 100644 --- a/sdks/java-v2/docs/FaxLineResponse.md +++ b/sdks/java-v2/docs/FaxLineResponse.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `faxLine` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `faxLine` | [```FaxLine```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java index 65c5da4b9..76bb887d1 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -10,10 +10,7 @@ import com.dropbox.sign.model.ErrorResponse; import com.dropbox.sign.model.FaxLineAddUserRequest; -import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; -import com.dropbox.sign.model.FaxLineAreaCodeGetProvinceEnum; import com.dropbox.sign.model.FaxLineAreaCodeGetResponse; -import com.dropbox.sign.model.FaxLineAreaCodeGetStateEnum; import com.dropbox.sign.model.FaxLineCreateRequest; import com.dropbox.sign.model.FaxLineDeleteRequest; import com.dropbox.sign.model.FaxLineListResponse; @@ -147,66 +144,66 @@ public ApiResponse faxLineAddUserWithHttpInfo(FaxLineAddUserReq 4XX failed_operation - */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country, String state, String province, String city) throws ApiException { return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGet(String, String, String, String) */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country) throws ApiException { - FaxLineAreaCodeGetStateEnum state = null; - FaxLineAreaCodeGetProvinceEnum province = null; + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country) throws ApiException { + String state = null; + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(String, String, String, String) */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country) throws ApiException { - FaxLineAreaCodeGetStateEnum state = null; - FaxLineAreaCodeGetProvinceEnum province = null; + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country) throws ApiException { + String state = null; + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); } /** - * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGet(String, String, String, String) */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { - FaxLineAreaCodeGetProvinceEnum province = null; + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country, String state) throws ApiException { + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(String, String, String, String) */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state) throws ApiException { - FaxLineAreaCodeGetProvinceEnum province = null; + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country, String state) throws ApiException { + String province = null; String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); } /** - * @see FaxLineApi#faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGet(String, String, String, String) */ - public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + public FaxLineAreaCodeGetResponse faxLineAreaCodeGet(String country, String state, String province) throws ApiException { String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city).getData(); } /** - * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetStateEnum, FaxLineAreaCodeGetProvinceEnum, String) + * @see FaxLineApi#faxLineAreaCodeGetWithHttpInfo(String, String, String, String) */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province) throws ApiException { + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country, String state, String province) throws ApiException { String city = null; return faxLineAreaCodeGetWithHttpInfo(country, state, province, city); @@ -229,7 +226,7 @@ public ApiResponse faxLineAreaCodeGetWithHttpInfo(Fa 4XX failed_operation - */ - public ApiResponse faxLineAreaCodeGetWithHttpInfo(FaxLineAreaCodeGetCountryEnum country, FaxLineAreaCodeGetStateEnum state, FaxLineAreaCodeGetProvinceEnum province, String city) throws ApiException { + public ApiResponse faxLineAreaCodeGetWithHttpInfo(String country, String state, String province, String city) throws ApiException { Object localVarPostBody = null; diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java new file mode 100644 index 000000000..083efc9df --- /dev/null +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java @@ -0,0 +1,345 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package com.dropbox.sign.model; + +import java.util.Objects; +import java.util.Map; +import java.util.HashMap; +import com.dropbox.sign.model.AccountResponse; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonTypeName; +import com.fasterxml.jackson.annotation.JsonValue; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.dropbox.sign.JSON; + + +import com.dropbox.sign.ApiException; +/** + * FaxLine + */ +@JsonPropertyOrder({ + FaxLine.JSON_PROPERTY_NUMBER, + FaxLine.JSON_PROPERTY_CREATED_AT, + FaxLine.JSON_PROPERTY_UPDATED_AT, + FaxLine.JSON_PROPERTY_ACCOUNTS +}) +@JsonIgnoreProperties(ignoreUnknown=true) +@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") +public class FaxLine { + public static final String JSON_PROPERTY_NUMBER = "number"; + private String number; + + public static final String JSON_PROPERTY_CREATED_AT = "created_at"; + private String createdAt; + + public static final String JSON_PROPERTY_UPDATED_AT = "updated_at"; + private String updatedAt; + + public static final String JSON_PROPERTY_ACCOUNTS = "accounts"; + private List accounts; + + public FaxLine() { + } + + /** + * Attempt to instantiate and hydrate a new instance of this class + * @param jsonData String of JSON data representing target object + */ + static public FaxLine init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLine.class); + } + + static public FaxLine init(HashMap data) throws Exception { + return new ObjectMapper().readValue( + new ObjectMapper().writeValueAsString(data), + FaxLine.class + ); + } + + public FaxLine number(String number) { + this.number = number; + return this; + } + + /** + * Number + * @return number + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "Number") + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getNumber() { + return number; + } + + + @JsonProperty(JSON_PROPERTY_NUMBER) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setNumber(String number) { + this.number = number; + } + + + public FaxLine createdAt(String createdAt) { + this.createdAt = createdAt; + return this; + } + + /** + * Created at + * @return createdAt + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "Created at") + @JsonProperty(JSON_PROPERTY_CREATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getCreatedAt() { + return createdAt; + } + + + @JsonProperty(JSON_PROPERTY_CREATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setCreatedAt(String createdAt) { + this.createdAt = createdAt; + } + + + public FaxLine updatedAt(String updatedAt) { + this.updatedAt = updatedAt; + return this; + } + + /** + * Updated at + * @return updatedAt + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "Updated at") + @JsonProperty(JSON_PROPERTY_UPDATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public String getUpdatedAt() { + return updatedAt; + } + + + @JsonProperty(JSON_PROPERTY_UPDATED_AT) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setUpdatedAt(String updatedAt) { + this.updatedAt = updatedAt; + } + + + public FaxLine accounts(List accounts) { + this.accounts = accounts; + return this; + } + + public FaxLine addAccountsItem(AccountResponse accountsItem) { + if (this.accounts == null) { + this.accounts = new ArrayList<>(); + } + this.accounts.add(accountsItem); + return this; + } + + /** + * Get accounts + * @return accounts + **/ + @jakarta.annotation.Nullable + @ApiModelProperty(value = "") + @JsonProperty(JSON_PROPERTY_ACCOUNTS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + + public List getAccounts() { + return accounts; + } + + + @JsonProperty(JSON_PROPERTY_ACCOUNTS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setAccounts(List accounts) { + this.accounts = accounts; + } + + + /** + * Return true if this FaxLine object is equal to o. + */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + FaxLine faxLine = (FaxLine) o; + return Objects.equals(this.number, faxLine.number) && + Objects.equals(this.createdAt, faxLine.createdAt) && + Objects.equals(this.updatedAt, faxLine.updatedAt) && + Objects.equals(this.accounts, faxLine.accounts); + } + + @Override + public int hashCode() { + return Objects.hash(number, createdAt, updatedAt, accounts); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class FaxLine {\n"); + sb.append(" number: ").append(toIndentedString(number)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append(" accounts: ").append(toIndentedString(accounts)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (number != null) { + if (isFileTypeOrListOfFiles(number)) { + fileTypeFound = true; + } + + if (number.getClass().equals(java.io.File.class) || + number.getClass().equals(Integer.class) || + number.getClass().equals(String.class) || + number.getClass().isEnum()) { + map.put("number", number); + } else if (isListOfFile(number)) { + for(int i = 0; i< getListSize(number); i++) { + map.put("number[" + i + "]", getFromList(number, i)); + } + } + else { + map.put("number", JSON.getDefault().getMapper().writeValueAsString(number)); + } + } + if (createdAt != null) { + if (isFileTypeOrListOfFiles(createdAt)) { + fileTypeFound = true; + } + + if (createdAt.getClass().equals(java.io.File.class) || + createdAt.getClass().equals(Integer.class) || + createdAt.getClass().equals(String.class) || + createdAt.getClass().isEnum()) { + map.put("created_at", createdAt); + } else if (isListOfFile(createdAt)) { + for(int i = 0; i< getListSize(createdAt); i++) { + map.put("created_at[" + i + "]", getFromList(createdAt, i)); + } + } + else { + map.put("created_at", JSON.getDefault().getMapper().writeValueAsString(createdAt)); + } + } + if (updatedAt != null) { + if (isFileTypeOrListOfFiles(updatedAt)) { + fileTypeFound = true; + } + + if (updatedAt.getClass().equals(java.io.File.class) || + updatedAt.getClass().equals(Integer.class) || + updatedAt.getClass().equals(String.class) || + updatedAt.getClass().isEnum()) { + map.put("updated_at", updatedAt); + } else if (isListOfFile(updatedAt)) { + for(int i = 0; i< getListSize(updatedAt); i++) { + map.put("updated_at[" + i + "]", getFromList(updatedAt, i)); + } + } + else { + map.put("updated_at", JSON.getDefault().getMapper().writeValueAsString(updatedAt)); + } + } + if (accounts != null) { + if (isFileTypeOrListOfFiles(accounts)) { + fileTypeFound = true; + } + + if (accounts.getClass().equals(java.io.File.class) || + accounts.getClass().equals(Integer.class) || + accounts.getClass().equals(String.class) || + accounts.getClass().isEnum()) { + map.put("accounts", accounts); + } else if (isListOfFile(accounts)) { + for(int i = 0; i< getListSize(accounts); i++) { + map.put("accounts[" + i + "]", getFromList(accounts, i)); + } + } + else { + map.put("accounts", JSON.getDefault().getMapper().writeValueAsString(accounts)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List && !isListEmpty(obj) && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()).getMethod("get", int.class).invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java index a15345ec1..2b93f5557 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -16,7 +16,6 @@ import java.util.Objects; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLineAreaCodeGetCountryEnum; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonCreator; @@ -47,8 +46,45 @@ public class FaxLineCreateRequest { public static final String JSON_PROPERTY_AREA_CODE = "area_code"; private String areaCode; + /** + * Country + */ + public enum CountryEnum { + CA("CA"), + + US("US"), + + UK("UK"); + + private String value; + + CountryEnum(String value) { + this.value = value; + } + + @JsonValue + public String getValue() { + return value; + } + + @Override + public String toString() { + return String.valueOf(value); + } + + @JsonCreator + public static CountryEnum fromValue(String value) { + for (CountryEnum b : CountryEnum.values()) { + if (b.value.equals(value)) { + return b; + } + } + throw new IllegalArgumentException("Unexpected value '" + value + "'"); + } + } + public static final String JSON_PROPERTY_COUNTRY = "country"; - private FaxLineAreaCodeGetCountryEnum country; + private CountryEnum country; public static final String JSON_PROPERTY_CITY = "city"; private String city; @@ -100,28 +136,28 @@ public void setAreaCode(String areaCode) { } - public FaxLineCreateRequest country(FaxLineAreaCodeGetCountryEnum country) { + public FaxLineCreateRequest country(CountryEnum country) { this.country = country; return this; } /** - * Get country + * Country * @return country **/ @jakarta.annotation.Nonnull - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(required = true, value = "Country") @JsonProperty(JSON_PROPERTY_COUNTRY) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public FaxLineAreaCodeGetCountryEnum getCountry() { + public CountryEnum getCountry() { return country; } @JsonProperty(JSON_PROPERTY_COUNTRY) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public void setCountry(FaxLineAreaCodeGetCountryEnum country) { + public void setCountry(CountryEnum country) { this.country = country; } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java index d3324410f..2af43d2a5 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java @@ -16,7 +16,7 @@ import java.util.Objects; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLineResponse; +import com.dropbox.sign.model.FaxLine; import com.dropbox.sign.model.ListInfoResponse; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; @@ -51,7 +51,7 @@ public class FaxLineListResponse { private ListInfoResponse listInfo; public static final String JSON_PROPERTY_FAX_LINES = "fax_lines"; - private List faxLines; + private List faxLines; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -100,12 +100,12 @@ public void setListInfo(ListInfoResponse listInfo) { } - public FaxLineListResponse faxLines(List faxLines) { + public FaxLineListResponse faxLines(List faxLines) { this.faxLines = faxLines; return this; } - public FaxLineListResponse addFaxLinesItem(FaxLineResponse faxLinesItem) { + public FaxLineListResponse addFaxLinesItem(FaxLine faxLinesItem) { if (this.faxLines == null) { this.faxLines = new ArrayList<>(); } @@ -122,14 +122,14 @@ public FaxLineListResponse addFaxLinesItem(FaxLineResponse faxLinesItem) { @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public List getFaxLines() { + public List getFaxLines() { return faxLines; } @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLines(List faxLines) { + public void setFaxLines(List faxLines) { this.faxLines = faxLines; } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java index d9fe0bc0c..987e41060 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java @@ -16,6 +16,7 @@ import java.util.Objects; import java.util.Map; import java.util.HashMap; +import com.dropbox.sign.model.FaxLine; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -43,7 +44,7 @@ @jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineResponse { public static final String JSON_PROPERTY_FAX_LINE = "fax_line"; - private FaxLineResponse faxLine; + private FaxLine faxLine; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -66,7 +67,7 @@ static public FaxLineResponse init(HashMap data) throws Exception { ); } - public FaxLineResponse faxLine(FaxLineResponse faxLine) { + public FaxLineResponse faxLine(FaxLine faxLine) { this.faxLine = faxLine; return this; } @@ -80,14 +81,14 @@ public FaxLineResponse faxLine(FaxLineResponse faxLine) { @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public FaxLineResponse getFaxLine() { + public FaxLine getFaxLine() { return faxLine; } @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLine(FaxLineResponse faxLine) { + public void setFaxLine(FaxLine faxLine) { this.faxLine = faxLine; } diff --git a/sdks/node/README.md b/sdks/node/README.md index 999b7fc46..0f661d54f 100644 --- a/sdks/node/README.md +++ b/sdks/node/README.md @@ -208,6 +208,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](./docs/model/EventCallbackRequest.md) - [EventCallbackRequestEvent](./docs/model/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](./docs/model/EventCallbackRequestEventMetadata.md) +- [FaxLine](./docs/model/FaxLine.md) - [FaxLineAddUserRequest](./docs/model/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](./docs/model/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](./docs/model/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/node/api/faxLineApi.ts b/sdks/node/api/faxLineApi.ts index d4cbbec6b..d19cfbb10 100644 --- a/sdks/node/api/faxLineApi.ts +++ b/sdks/node/api/faxLineApi.ts @@ -36,10 +36,7 @@ import { OAuth, ErrorResponse, FaxLineAddUserRequest, - FaxLineAreaCodeGetCountryEnum, - FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetResponse, - FaxLineAreaCodeGetStateEnum, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, @@ -299,9 +296,73 @@ export class FaxLineApi { * @param options */ public async faxLineAreaCodeGet( - country: FaxLineAreaCodeGetCountryEnum, - state?: FaxLineAreaCodeGetStateEnum, - province?: FaxLineAreaCodeGetProvinceEnum, + country: "CA" | "US" | "UK", + state?: + | "AK" + | "AL" + | "AR" + | "AZ" + | "CA" + | "CO" + | "CT" + | "DC" + | "DE" + | "FL" + | "GA" + | "HI" + | "IA" + | "ID" + | "IL" + | "IN" + | "KS" + | "KY" + | "LA" + | "MA" + | "MD" + | "ME" + | "MI" + | "MN" + | "MO" + | "MS" + | "MT" + | "NC" + | "ND" + | "NE" + | "NH" + | "NJ" + | "NM" + | "NV" + | "NY" + | "OH" + | "OK" + | "OR" + | "PA" + | "RI" + | "SC" + | "SD" + | "TN" + | "TX" + | "UT" + | "VA" + | "VT" + | "WA" + | "WI" + | "WV" + | "WY", + province?: + | "AB" + | "BC" + | "MB" + | "NB" + | "NL" + | "NT" + | "NS" + | "NU" + | "ON" + | "PE" + | "QC" + | "SK" + | "YT", city?: string, options: optionsI = { headers: {} } ): Promise> { @@ -331,21 +392,21 @@ export class FaxLineApi { if (country !== undefined) { localVarQueryParameters["country"] = ObjectSerializer.serialize( country, - "FaxLineAreaCodeGetCountryEnum" + "'CA' | 'US' | 'UK'" ); } if (state !== undefined) { localVarQueryParameters["state"] = ObjectSerializer.serialize( state, - "FaxLineAreaCodeGetStateEnum" + "'AK' | 'AL' | 'AR' | 'AZ' | 'CA' | 'CO' | 'CT' | 'DC' | 'DE' | 'FL' | 'GA' | 'HI' | 'IA' | 'ID' | 'IL' | 'IN' | 'KS' | 'KY' | 'LA' | 'MA' | 'MD' | 'ME' | 'MI' | 'MN' | 'MO' | 'MS' | 'MT' | 'NC' | 'ND' | 'NE' | 'NH' | 'NJ' | 'NM' | 'NV' | 'NY' | 'OH' | 'OK' | 'OR' | 'PA' | 'RI' | 'SC' | 'SD' | 'TN' | 'TX' | 'UT' | 'VA' | 'VT' | 'WA' | 'WI' | 'WV' | 'WY'" ); } if (province !== undefined) { localVarQueryParameters["province"] = ObjectSerializer.serialize( province, - "FaxLineAreaCodeGetProvinceEnum" + "'AB' | 'BC' | 'MB' | 'NB' | 'NL' | 'NT' | 'NS' | 'NU' | 'ON' | 'PE' | 'QC' | 'SK' | 'YT'" ); } diff --git a/sdks/node/dist/api.js b/sdks/node/dist/api.js index 58428135e..3222ff320 100644 --- a/sdks/node/dist/api.js +++ b/sdks/node/dist/api.js @@ -12973,6 +12973,7 @@ __export(api_exports, { EventCallbackRequest: () => EventCallbackRequest, EventCallbackRequestEvent: () => EventCallbackRequestEvent, EventCallbackRequestEventMetadata: () => EventCallbackRequestEventMetadata, + FaxLine: () => FaxLine, FaxLineAddUserRequest: () => FaxLineAddUserRequest, FaxLineApi: () => FaxLineApi, FaxLineAreaCodeGetCountryEnum: () => FaxLineAreaCodeGetCountryEnum, @@ -17663,6 +17664,40 @@ EventCallbackRequestEventMetadata.attributeTypeMap = [ } ]; +// model/faxLine.ts +var _FaxLine = class { + static getAttributeTypeMap() { + return _FaxLine.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLine"); + } +}; +var FaxLine = _FaxLine; +FaxLine.discriminator = void 0; +FaxLine.attributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string" + }, + { + name: "createdAt", + baseName: "created_at", + type: "string" + }, + { + name: "updatedAt", + baseName: "updated_at", + type: "string" + }, + { + name: "accounts", + baseName: "accounts", + type: "Array" + } +]; + // model/faxLineAddUserRequest.ts var _FaxLineAddUserRequest = class { static getAttributeTypeMap() { @@ -17693,29 +17728,29 @@ FaxLineAddUserRequest.attributeTypeMap = [ ]; // model/faxLineAreaCodeGetCountryEnum.ts -var FaxLineAreaCodeGetCountryEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetCountryEnum3) => { - FaxLineAreaCodeGetCountryEnum3["Ca"] = "CA"; - FaxLineAreaCodeGetCountryEnum3["Us"] = "US"; - FaxLineAreaCodeGetCountryEnum3["Uk"] = "UK"; - return FaxLineAreaCodeGetCountryEnum3; +var FaxLineAreaCodeGetCountryEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetCountryEnum2) => { + FaxLineAreaCodeGetCountryEnum2["Ca"] = "CA"; + FaxLineAreaCodeGetCountryEnum2["Us"] = "US"; + FaxLineAreaCodeGetCountryEnum2["Uk"] = "UK"; + return FaxLineAreaCodeGetCountryEnum2; })(FaxLineAreaCodeGetCountryEnum || {}); // model/faxLineAreaCodeGetProvinceEnum.ts -var FaxLineAreaCodeGetProvinceEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetProvinceEnum3) => { - FaxLineAreaCodeGetProvinceEnum3["Ab"] = "AB"; - FaxLineAreaCodeGetProvinceEnum3["Bc"] = "BC"; - FaxLineAreaCodeGetProvinceEnum3["Mb"] = "MB"; - FaxLineAreaCodeGetProvinceEnum3["Nb"] = "NB"; - FaxLineAreaCodeGetProvinceEnum3["Nl"] = "NL"; - FaxLineAreaCodeGetProvinceEnum3["Nt"] = "NT"; - FaxLineAreaCodeGetProvinceEnum3["Ns"] = "NS"; - FaxLineAreaCodeGetProvinceEnum3["Nu"] = "NU"; - FaxLineAreaCodeGetProvinceEnum3["On"] = "ON"; - FaxLineAreaCodeGetProvinceEnum3["Pe"] = "PE"; - FaxLineAreaCodeGetProvinceEnum3["Qc"] = "QC"; - FaxLineAreaCodeGetProvinceEnum3["Sk"] = "SK"; - FaxLineAreaCodeGetProvinceEnum3["Yt"] = "YT"; - return FaxLineAreaCodeGetProvinceEnum3; +var FaxLineAreaCodeGetProvinceEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetProvinceEnum2) => { + FaxLineAreaCodeGetProvinceEnum2["Ab"] = "AB"; + FaxLineAreaCodeGetProvinceEnum2["Bc"] = "BC"; + FaxLineAreaCodeGetProvinceEnum2["Mb"] = "MB"; + FaxLineAreaCodeGetProvinceEnum2["Nb"] = "NB"; + FaxLineAreaCodeGetProvinceEnum2["Nl"] = "NL"; + FaxLineAreaCodeGetProvinceEnum2["Nt"] = "NT"; + FaxLineAreaCodeGetProvinceEnum2["Ns"] = "NS"; + FaxLineAreaCodeGetProvinceEnum2["Nu"] = "NU"; + FaxLineAreaCodeGetProvinceEnum2["On"] = "ON"; + FaxLineAreaCodeGetProvinceEnum2["Pe"] = "PE"; + FaxLineAreaCodeGetProvinceEnum2["Qc"] = "QC"; + FaxLineAreaCodeGetProvinceEnum2["Sk"] = "SK"; + FaxLineAreaCodeGetProvinceEnum2["Yt"] = "YT"; + return FaxLineAreaCodeGetProvinceEnum2; })(FaxLineAreaCodeGetProvinceEnum || {}); // model/faxLineAreaCodeGetResponse.ts @@ -17738,59 +17773,59 @@ FaxLineAreaCodeGetResponse.attributeTypeMap = [ ]; // model/faxLineAreaCodeGetStateEnum.ts -var FaxLineAreaCodeGetStateEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetStateEnum3) => { - FaxLineAreaCodeGetStateEnum3["Ak"] = "AK"; - FaxLineAreaCodeGetStateEnum3["Al"] = "AL"; - FaxLineAreaCodeGetStateEnum3["Ar"] = "AR"; - FaxLineAreaCodeGetStateEnum3["Az"] = "AZ"; - FaxLineAreaCodeGetStateEnum3["Ca"] = "CA"; - FaxLineAreaCodeGetStateEnum3["Co"] = "CO"; - FaxLineAreaCodeGetStateEnum3["Ct"] = "CT"; - FaxLineAreaCodeGetStateEnum3["Dc"] = "DC"; - FaxLineAreaCodeGetStateEnum3["De"] = "DE"; - FaxLineAreaCodeGetStateEnum3["Fl"] = "FL"; - FaxLineAreaCodeGetStateEnum3["Ga"] = "GA"; - FaxLineAreaCodeGetStateEnum3["Hi"] = "HI"; - FaxLineAreaCodeGetStateEnum3["Ia"] = "IA"; - FaxLineAreaCodeGetStateEnum3["Id"] = "ID"; - FaxLineAreaCodeGetStateEnum3["Il"] = "IL"; - FaxLineAreaCodeGetStateEnum3["In"] = "IN"; - FaxLineAreaCodeGetStateEnum3["Ks"] = "KS"; - FaxLineAreaCodeGetStateEnum3["Ky"] = "KY"; - FaxLineAreaCodeGetStateEnum3["La"] = "LA"; - FaxLineAreaCodeGetStateEnum3["Ma"] = "MA"; - FaxLineAreaCodeGetStateEnum3["Md"] = "MD"; - FaxLineAreaCodeGetStateEnum3["Me"] = "ME"; - FaxLineAreaCodeGetStateEnum3["Mi"] = "MI"; - FaxLineAreaCodeGetStateEnum3["Mn"] = "MN"; - FaxLineAreaCodeGetStateEnum3["Mo"] = "MO"; - FaxLineAreaCodeGetStateEnum3["Ms"] = "MS"; - FaxLineAreaCodeGetStateEnum3["Mt"] = "MT"; - FaxLineAreaCodeGetStateEnum3["Nc"] = "NC"; - FaxLineAreaCodeGetStateEnum3["Nd"] = "ND"; - FaxLineAreaCodeGetStateEnum3["Ne"] = "NE"; - FaxLineAreaCodeGetStateEnum3["Nh"] = "NH"; - FaxLineAreaCodeGetStateEnum3["Nj"] = "NJ"; - FaxLineAreaCodeGetStateEnum3["Nm"] = "NM"; - FaxLineAreaCodeGetStateEnum3["Nv"] = "NV"; - FaxLineAreaCodeGetStateEnum3["Ny"] = "NY"; - FaxLineAreaCodeGetStateEnum3["Oh"] = "OH"; - FaxLineAreaCodeGetStateEnum3["Ok"] = "OK"; - FaxLineAreaCodeGetStateEnum3["Or"] = "OR"; - FaxLineAreaCodeGetStateEnum3["Pa"] = "PA"; - FaxLineAreaCodeGetStateEnum3["Ri"] = "RI"; - FaxLineAreaCodeGetStateEnum3["Sc"] = "SC"; - FaxLineAreaCodeGetStateEnum3["Sd"] = "SD"; - FaxLineAreaCodeGetStateEnum3["Tn"] = "TN"; - FaxLineAreaCodeGetStateEnum3["Tx"] = "TX"; - FaxLineAreaCodeGetStateEnum3["Ut"] = "UT"; - FaxLineAreaCodeGetStateEnum3["Va"] = "VA"; - FaxLineAreaCodeGetStateEnum3["Vt"] = "VT"; - FaxLineAreaCodeGetStateEnum3["Wa"] = "WA"; - FaxLineAreaCodeGetStateEnum3["Wi"] = "WI"; - FaxLineAreaCodeGetStateEnum3["Wv"] = "WV"; - FaxLineAreaCodeGetStateEnum3["Wy"] = "WY"; - return FaxLineAreaCodeGetStateEnum3; +var FaxLineAreaCodeGetStateEnum = /* @__PURE__ */ ((FaxLineAreaCodeGetStateEnum2) => { + FaxLineAreaCodeGetStateEnum2["Ak"] = "AK"; + FaxLineAreaCodeGetStateEnum2["Al"] = "AL"; + FaxLineAreaCodeGetStateEnum2["Ar"] = "AR"; + FaxLineAreaCodeGetStateEnum2["Az"] = "AZ"; + FaxLineAreaCodeGetStateEnum2["Ca"] = "CA"; + FaxLineAreaCodeGetStateEnum2["Co"] = "CO"; + FaxLineAreaCodeGetStateEnum2["Ct"] = "CT"; + FaxLineAreaCodeGetStateEnum2["Dc"] = "DC"; + FaxLineAreaCodeGetStateEnum2["De"] = "DE"; + FaxLineAreaCodeGetStateEnum2["Fl"] = "FL"; + FaxLineAreaCodeGetStateEnum2["Ga"] = "GA"; + FaxLineAreaCodeGetStateEnum2["Hi"] = "HI"; + FaxLineAreaCodeGetStateEnum2["Ia"] = "IA"; + FaxLineAreaCodeGetStateEnum2["Id"] = "ID"; + FaxLineAreaCodeGetStateEnum2["Il"] = "IL"; + FaxLineAreaCodeGetStateEnum2["In"] = "IN"; + FaxLineAreaCodeGetStateEnum2["Ks"] = "KS"; + FaxLineAreaCodeGetStateEnum2["Ky"] = "KY"; + FaxLineAreaCodeGetStateEnum2["La"] = "LA"; + FaxLineAreaCodeGetStateEnum2["Ma"] = "MA"; + FaxLineAreaCodeGetStateEnum2["Md"] = "MD"; + FaxLineAreaCodeGetStateEnum2["Me"] = "ME"; + FaxLineAreaCodeGetStateEnum2["Mi"] = "MI"; + FaxLineAreaCodeGetStateEnum2["Mn"] = "MN"; + FaxLineAreaCodeGetStateEnum2["Mo"] = "MO"; + FaxLineAreaCodeGetStateEnum2["Ms"] = "MS"; + FaxLineAreaCodeGetStateEnum2["Mt"] = "MT"; + FaxLineAreaCodeGetStateEnum2["Nc"] = "NC"; + FaxLineAreaCodeGetStateEnum2["Nd"] = "ND"; + FaxLineAreaCodeGetStateEnum2["Ne"] = "NE"; + FaxLineAreaCodeGetStateEnum2["Nh"] = "NH"; + FaxLineAreaCodeGetStateEnum2["Nj"] = "NJ"; + FaxLineAreaCodeGetStateEnum2["Nm"] = "NM"; + FaxLineAreaCodeGetStateEnum2["Nv"] = "NV"; + FaxLineAreaCodeGetStateEnum2["Ny"] = "NY"; + FaxLineAreaCodeGetStateEnum2["Oh"] = "OH"; + FaxLineAreaCodeGetStateEnum2["Ok"] = "OK"; + FaxLineAreaCodeGetStateEnum2["Or"] = "OR"; + FaxLineAreaCodeGetStateEnum2["Pa"] = "PA"; + FaxLineAreaCodeGetStateEnum2["Ri"] = "RI"; + FaxLineAreaCodeGetStateEnum2["Sc"] = "SC"; + FaxLineAreaCodeGetStateEnum2["Sd"] = "SD"; + FaxLineAreaCodeGetStateEnum2["Tn"] = "TN"; + FaxLineAreaCodeGetStateEnum2["Tx"] = "TX"; + FaxLineAreaCodeGetStateEnum2["Ut"] = "UT"; + FaxLineAreaCodeGetStateEnum2["Va"] = "VA"; + FaxLineAreaCodeGetStateEnum2["Vt"] = "VT"; + FaxLineAreaCodeGetStateEnum2["Wa"] = "WA"; + FaxLineAreaCodeGetStateEnum2["Wi"] = "WI"; + FaxLineAreaCodeGetStateEnum2["Wv"] = "WV"; + FaxLineAreaCodeGetStateEnum2["Wy"] = "WY"; + return FaxLineAreaCodeGetStateEnum2; })(FaxLineAreaCodeGetStateEnum || {}); // model/faxLineCreateRequest.ts @@ -17813,7 +17848,7 @@ FaxLineCreateRequest.attributeTypeMap = [ { name: "country", baseName: "country", - type: "FaxLineAreaCodeGetCountryEnum" + type: "FaxLineCreateRequest.CountryEnum" }, { name: "city", @@ -17826,6 +17861,14 @@ FaxLineCreateRequest.attributeTypeMap = [ type: "string" } ]; +((FaxLineCreateRequest2) => { + let CountryEnum; + ((CountryEnum2) => { + CountryEnum2["Ca"] = "CA"; + CountryEnum2["Us"] = "US"; + CountryEnum2["Uk"] = "UK"; + })(CountryEnum = FaxLineCreateRequest2.CountryEnum || (FaxLineCreateRequest2.CountryEnum = {})); +})(FaxLineCreateRequest || (FaxLineCreateRequest = {})); // model/faxLineDeleteRequest.ts var _FaxLineDeleteRequest = class { @@ -17866,7 +17909,7 @@ FaxLineListResponse.attributeTypeMap = [ { name: "faxLines", baseName: "fax_lines", - type: "Array" + type: "Array" }, { name: "warnings", @@ -17919,7 +17962,7 @@ FaxLineResponse.attributeTypeMap = [ { name: "faxLine", baseName: "fax_line", - type: "FaxLineResponse" + type: "FaxLine" }, { name: "warnings", @@ -24361,6 +24404,7 @@ var enumsMap = { FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetStateEnum, + "FaxLineCreateRequest.CountryEnum": FaxLineCreateRequest.CountryEnum, "ReportCreateRequest.ReportTypeEnum": ReportCreateRequest.ReportTypeEnum, "ReportResponse.ReportTypeEnum": ReportResponse.ReportTypeEnum, SignatureRequestResponseCustomFieldTypeEnum, @@ -24423,6 +24467,7 @@ var typeMap = { EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, + FaxLine, FaxLineAddUserRequest, FaxLineAreaCodeGetResponse, FaxLineCreateRequest, @@ -26454,19 +26499,19 @@ var FaxLineApi = class { if (country !== void 0) { localVarQueryParameters["country"] = ObjectSerializer.serialize( country, - "FaxLineAreaCodeGetCountryEnum" + "'CA' | 'US' | 'UK'" ); } if (state !== void 0) { localVarQueryParameters["state"] = ObjectSerializer.serialize( state, - "FaxLineAreaCodeGetStateEnum" + "'AK' | 'AL' | 'AR' | 'AZ' | 'CA' | 'CO' | 'CT' | 'DC' | 'DE' | 'FL' | 'GA' | 'HI' | 'IA' | 'ID' | 'IL' | 'IN' | 'KS' | 'KY' | 'LA' | 'MA' | 'MD' | 'ME' | 'MI' | 'MN' | 'MO' | 'MS' | 'MT' | 'NC' | 'ND' | 'NE' | 'NH' | 'NJ' | 'NM' | 'NV' | 'NY' | 'OH' | 'OK' | 'OR' | 'PA' | 'RI' | 'SC' | 'SD' | 'TN' | 'TX' | 'UT' | 'VA' | 'VT' | 'WA' | 'WI' | 'WV' | 'WY'" ); } if (province !== void 0) { localVarQueryParameters["province"] = ObjectSerializer.serialize( province, - "FaxLineAreaCodeGetProvinceEnum" + "'AB' | 'BC' | 'MB' | 'NB' | 'NL' | 'NT' | 'NS' | 'NU' | 'ON' | 'PE' | 'QC' | 'SK' | 'YT'" ); } if (city !== void 0) { @@ -32590,6 +32635,7 @@ var APIS = [ EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, + FaxLine, FaxLineAddUserRequest, FaxLineApi, FaxLineAreaCodeGetCountryEnum, diff --git a/sdks/node/docs/api/FaxLineApi.md b/sdks/node/docs/api/FaxLineApi.md index b2774aa09..88cf53b31 100644 --- a/sdks/node/docs/api/FaxLineApi.md +++ b/sdks/node/docs/api/FaxLineApi.md @@ -99,7 +99,7 @@ result.then(response => { ## `faxLineAreaCodeGet()` ```typescript -faxLineAreaCodeGet(country: FaxLineAreaCodeGetCountryEnum, state: FaxLineAreaCodeGetStateEnum, province: FaxLineAreaCodeGetProvinceEnum, city: string): FaxLineAreaCodeGetResponse +faxLineAreaCodeGet(country: 'CA' | 'US' | 'UK', state: 'AK' | 'AL' | 'AR' | 'AZ' | 'CA' | 'CO' | 'CT' | 'DC' | 'DE' | 'FL' | 'GA' | 'HI' | 'IA' | 'ID' | 'IL' | 'IN' | 'KS' | 'KY' | 'LA' | 'MA' | 'MD' | 'ME' | 'MI' | 'MN' | 'MO' | 'MS' | 'MT' | 'NC' | 'ND' | 'NE' | 'NH' | 'NJ' | 'NM' | 'NV' | 'NY' | 'OH' | 'OK' | 'OR' | 'PA' | 'RI' | 'SC' | 'SD' | 'TN' | 'TX' | 'UT' | 'VA' | 'VT' | 'WA' | 'WI' | 'WV' | 'WY', province: 'AB' | 'BC' | 'MB' | 'NB' | 'NL' | 'NT' | 'NS' | 'NU' | 'ON' | 'PE' | 'QC' | 'SK' | 'YT', city: string): FaxLineAreaCodeGetResponse ``` Get Available Fax Line Area Codes @@ -116,7 +116,7 @@ const faxLineApi = new DropboxSign.FaxLineApi(); // Configure HTTP basic authorization: api_key faxLineApi.username = "YOUR_API_KEY"; -const result = faxLineApi.faxLineAreaCodeGet(DropboxSign.FaxLineAreaCodeGetCountryEnum.Us, DropboxSign.FaxLineAreaCodeGetStateEnum.Ca); +const result = faxLineApi.faxLineAreaCodeGet("US", "CA"); result.then(response => { console.log(response.body); }).catch(error => { @@ -150,9 +150,9 @@ result.then(response => { |Name | Type | Description | Notes | | ------------- | ------------- | ------------- | ------------- | -| **country** | [**FaxLineAreaCodeGetCountryEnum**](../model/.md)| Filter area codes by country. | | -| **state** | [**FaxLineAreaCodeGetStateEnum**](../model/.md)| Filter area codes by state. | [optional] | -| **province** | [**FaxLineAreaCodeGetProvinceEnum**](../model/.md)| Filter area codes by province. | [optional] | +| **country** | **'CA' | 'US' | 'UK'**| Filter area codes by country. | | +| **state** | **'AK' | 'AL' | 'AR' | 'AZ' | 'CA' | 'CO' | 'CT' | 'DC' | 'DE' | 'FL' | 'GA' | 'HI' | 'IA' | 'ID' | 'IL' | 'IN' | 'KS' | 'KY' | 'LA' | 'MA' | 'MD' | 'ME' | 'MI' | 'MN' | 'MO' | 'MS' | 'MT' | 'NC' | 'ND' | 'NE' | 'NH' | 'NJ' | 'NM' | 'NV' | 'NY' | 'OH' | 'OK' | 'OR' | 'PA' | 'RI' | 'SC' | 'SD' | 'TN' | 'TX' | 'UT' | 'VA' | 'VT' | 'WA' | 'WI' | 'WV' | 'WY'**| Filter area codes by state. | [optional] | +| **province** | **'AB' | 'BC' | 'MB' | 'NB' | 'NL' | 'NT' | 'NS' | 'NU' | 'ON' | 'PE' | 'QC' | 'SK' | 'YT'**| Filter area codes by province. | [optional] | | **city** | **string**| Filter area codes by city. | [optional] | ### Return type diff --git a/sdks/node/docs/model/FaxLine.md b/sdks/node/docs/model/FaxLine.md new file mode 100644 index 000000000..11793305e --- /dev/null +++ b/sdks/node/docs/model/FaxLine.md @@ -0,0 +1,14 @@ +# # FaxLine + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number` | ```string``` | Number | | +| `createdAt` | ```string``` | Created at | | +| `updatedAt` | ```string``` | Updated at | | +| `accounts` | [```Array```](AccountResponse.md) | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineCreateRequest.md b/sdks/node/docs/model/FaxLineCreateRequest.md index d42665f7b..d4cdf41fe 100644 --- a/sdks/node/docs/model/FaxLineCreateRequest.md +++ b/sdks/node/docs/model/FaxLineCreateRequest.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `areaCode`*_required_ | ```string``` | Area code | | -| `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `country`*_required_ | ```string``` | Country | | | `city` | ```string``` | City | | | `accountId` | ```string``` | Account ID | | diff --git a/sdks/node/docs/model/FaxLineListResponse.md b/sdks/node/docs/model/FaxLineListResponse.md index e2841f04e..0fba42b1a 100644 --- a/sdks/node/docs/model/FaxLineListResponse.md +++ b/sdks/node/docs/model/FaxLineListResponse.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `faxLines` | [```Array```](FaxLineResponse.md) | | | +| `faxLines` | [```Array```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineResponse.md b/sdks/node/docs/model/FaxLineResponse.md index 7145365aa..433ae47e4 100644 --- a/sdks/node/docs/model/FaxLineResponse.md +++ b/sdks/node/docs/model/FaxLineResponse.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `faxLine` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `faxLine` | [```FaxLine```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/model/faxLine.ts b/sdks/node/model/faxLine.ts new file mode 100644 index 000000000..a0fb7ecda --- /dev/null +++ b/sdks/node/model/faxLine.ts @@ -0,0 +1,76 @@ +/** + * The MIT License (MIT) + * + * Copyright (C) 2023 dropbox.com + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; +import { AccountResponse } from "./accountResponse"; + +export class FaxLine { + /** + * Number + */ + "number"?: string; + /** + * Created at + */ + "createdAt"?: string; + /** + * Updated at + */ + "updatedAt"?: string; + "accounts"?: Array; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: AttributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string", + }, + { + name: "createdAt", + baseName: "created_at", + type: "string", + }, + { + name: "updatedAt", + baseName: "updated_at", + type: "string", + }, + { + name: "accounts", + baseName: "accounts", + type: "Array", + }, + ]; + + static getAttributeTypeMap(): AttributeTypeMap { + return FaxLine.attributeTypeMap; + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + static init(data: any): FaxLine { + return ObjectSerializer.deserialize(data, "FaxLine"); + } +} diff --git a/sdks/node/model/faxLineCreateRequest.ts b/sdks/node/model/faxLineCreateRequest.ts index 267315195..7d468ac82 100644 --- a/sdks/node/model/faxLineCreateRequest.ts +++ b/sdks/node/model/faxLineCreateRequest.ts @@ -23,14 +23,16 @@ */ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; -import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; export class FaxLineCreateRequest { /** * Area code */ "areaCode": string; - "country": FaxLineAreaCodeGetCountryEnum; + /** + * Country + */ + "country": FaxLineCreateRequest.CountryEnum; /** * City */ @@ -51,7 +53,7 @@ export class FaxLineCreateRequest { { name: "country", baseName: "country", - type: "FaxLineAreaCodeGetCountryEnum", + type: "FaxLineCreateRequest.CountryEnum", }, { name: "city", @@ -74,3 +76,11 @@ export class FaxLineCreateRequest { return ObjectSerializer.deserialize(data, "FaxLineCreateRequest"); } } + +export namespace FaxLineCreateRequest { + export enum CountryEnum { + Ca = "CA", + Us = "US", + Uk = "UK", + } +} diff --git a/sdks/node/model/faxLineListResponse.ts b/sdks/node/model/faxLineListResponse.ts index b67942a1e..a36302a3d 100644 --- a/sdks/node/model/faxLineListResponse.ts +++ b/sdks/node/model/faxLineListResponse.ts @@ -23,13 +23,13 @@ */ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; -import { FaxLineResponse } from "./faxLineResponse"; +import { FaxLine } from "./faxLine"; import { ListInfoResponse } from "./listInfoResponse"; import { WarningResponse } from "./warningResponse"; export class FaxLineListResponse { "listInfo"?: ListInfoResponse; - "faxLines"?: Array; + "faxLines"?: Array; "warnings"?: WarningResponse; static discriminator: string | undefined = undefined; @@ -43,7 +43,7 @@ export class FaxLineListResponse { { name: "faxLines", baseName: "fax_lines", - type: "Array", + type: "Array", }, { name: "warnings", diff --git a/sdks/node/model/faxLineResponse.ts b/sdks/node/model/faxLineResponse.ts index b682f51fa..18a88b7e5 100644 --- a/sdks/node/model/faxLineResponse.ts +++ b/sdks/node/model/faxLineResponse.ts @@ -23,10 +23,11 @@ */ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; +import { FaxLine } from "./faxLine"; import { WarningResponse } from "./warningResponse"; export class FaxLineResponse { - "faxLine"?: FaxLineResponse; + "faxLine"?: FaxLine; "warnings"?: WarningResponse; static discriminator: string | undefined = undefined; @@ -35,7 +36,7 @@ export class FaxLineResponse { { name: "faxLine", baseName: "fax_line", - type: "FaxLineResponse", + type: "FaxLine", }, { name: "warnings", diff --git a/sdks/node/model/index.ts b/sdks/node/model/index.ts index c771f9709..3cf73bafc 100644 --- a/sdks/node/model/index.ts +++ b/sdks/node/model/index.ts @@ -32,6 +32,7 @@ import { ErrorResponseError } from "./errorResponseError"; import { EventCallbackRequest } from "./eventCallbackRequest"; import { EventCallbackRequestEvent } from "./eventCallbackRequestEvent"; import { EventCallbackRequestEventMetadata } from "./eventCallbackRequestEventMetadata"; +import { FaxLine } from "./faxLine"; import { FaxLineAddUserRequest } from "./faxLineAddUserRequest"; import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; import { FaxLineAreaCodeGetProvinceEnum } from "./faxLineAreaCodeGetProvinceEnum"; @@ -201,6 +202,7 @@ export let enumsMap: { [index: string]: any } = { FaxLineAreaCodeGetCountryEnum: FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum: FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetStateEnum: FaxLineAreaCodeGetStateEnum, + "FaxLineCreateRequest.CountryEnum": FaxLineCreateRequest.CountryEnum, "ReportCreateRequest.ReportTypeEnum": ReportCreateRequest.ReportTypeEnum, "ReportResponse.ReportTypeEnum": ReportResponse.ReportTypeEnum, SignatureRequestResponseCustomFieldTypeEnum: @@ -277,6 +279,7 @@ export let typeMap: { [index: string]: any } = { EventCallbackRequest: EventCallbackRequest, EventCallbackRequestEvent: EventCallbackRequestEvent, EventCallbackRequestEventMetadata: EventCallbackRequestEventMetadata, + FaxLine: FaxLine, FaxLineAddUserRequest: FaxLineAddUserRequest, FaxLineAreaCodeGetResponse: FaxLineAreaCodeGetResponse, FaxLineCreateRequest: FaxLineCreateRequest, @@ -492,6 +495,7 @@ export { EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, + FaxLine, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, diff --git a/sdks/node/types/api/faxLineApi.d.ts b/sdks/node/types/api/faxLineApi.d.ts index c6e55927d..7326eaceb 100644 --- a/sdks/node/types/api/faxLineApi.d.ts +++ b/sdks/node/types/api/faxLineApi.d.ts @@ -1,4 +1,4 @@ -import { Authentication, Interceptor, HttpBasicAuth, HttpBearerAuth, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetResponse, FaxLineAreaCodeGetStateEnum, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse } from "../model"; +import { Authentication, Interceptor, HttpBasicAuth, HttpBearerAuth, FaxLineAddUserRequest, FaxLineAreaCodeGetResponse, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse } from "../model"; import { optionsI, returnTypeT, returnTypeI } from "./"; export declare enum FaxLineApiApiKeys { } @@ -25,7 +25,7 @@ export declare class FaxLineApi { set accessToken(accessToken: string | (() => string)); addInterceptor(interceptor: Interceptor): void; faxLineAddUser(faxLineAddUserRequest: FaxLineAddUserRequest, options?: optionsI): Promise>; - faxLineAreaCodeGet(country: FaxLineAreaCodeGetCountryEnum, state?: FaxLineAreaCodeGetStateEnum, province?: FaxLineAreaCodeGetProvinceEnum, city?: string, options?: optionsI): Promise>; + faxLineAreaCodeGet(country: "CA" | "US" | "UK", state?: "AK" | "AL" | "AR" | "AZ" | "CA" | "CO" | "CT" | "DC" | "DE" | "FL" | "GA" | "HI" | "IA" | "ID" | "IL" | "IN" | "KS" | "KY" | "LA" | "MA" | "MD" | "ME" | "MI" | "MN" | "MO" | "MS" | "MT" | "NC" | "ND" | "NE" | "NH" | "NJ" | "NM" | "NV" | "NY" | "OH" | "OK" | "OR" | "PA" | "RI" | "SC" | "SD" | "TN" | "TX" | "UT" | "VA" | "VT" | "WA" | "WI" | "WV" | "WY", province?: "AB" | "BC" | "MB" | "NB" | "NL" | "NT" | "NS" | "NU" | "ON" | "PE" | "QC" | "SK" | "YT", city?: string, options?: optionsI): Promise>; faxLineCreate(faxLineCreateRequest: FaxLineCreateRequest, options?: optionsI): Promise>; faxLineDelete(faxLineDeleteRequest: FaxLineDeleteRequest, options?: optionsI): Promise; faxLineGet(number: string, options?: optionsI): Promise>; diff --git a/sdks/node/types/model/faxLine.d.ts b/sdks/node/types/model/faxLine.d.ts new file mode 100644 index 000000000..3356ed36d --- /dev/null +++ b/sdks/node/types/model/faxLine.d.ts @@ -0,0 +1,12 @@ +import { AttributeTypeMap } from "./"; +import { AccountResponse } from "./accountResponse"; +export declare class FaxLine { + "number"?: string; + "createdAt"?: string; + "updatedAt"?: string; + "accounts"?: Array; + static discriminator: string | undefined; + static attributeTypeMap: AttributeTypeMap; + static getAttributeTypeMap(): AttributeTypeMap; + static init(data: any): FaxLine; +} diff --git a/sdks/node/types/model/faxLineCreateRequest.d.ts b/sdks/node/types/model/faxLineCreateRequest.d.ts index 16b4eb245..258ac918e 100644 --- a/sdks/node/types/model/faxLineCreateRequest.d.ts +++ b/sdks/node/types/model/faxLineCreateRequest.d.ts @@ -1,8 +1,7 @@ import { AttributeTypeMap } from "./"; -import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; export declare class FaxLineCreateRequest { "areaCode": string; - "country": FaxLineAreaCodeGetCountryEnum; + "country": FaxLineCreateRequest.CountryEnum; "city"?: string; "accountId"?: string; static discriminator: string | undefined; @@ -10,3 +9,10 @@ export declare class FaxLineCreateRequest { static getAttributeTypeMap(): AttributeTypeMap; static init(data: any): FaxLineCreateRequest; } +export declare namespace FaxLineCreateRequest { + enum CountryEnum { + Ca = "CA", + Us = "US", + Uk = "UK" + } +} diff --git a/sdks/node/types/model/faxLineListResponse.d.ts b/sdks/node/types/model/faxLineListResponse.d.ts index 3cdc48693..10d882d4d 100644 --- a/sdks/node/types/model/faxLineListResponse.d.ts +++ b/sdks/node/types/model/faxLineListResponse.d.ts @@ -1,10 +1,10 @@ import { AttributeTypeMap } from "./"; -import { FaxLineResponse } from "./faxLineResponse"; +import { FaxLine } from "./faxLine"; import { ListInfoResponse } from "./listInfoResponse"; import { WarningResponse } from "./warningResponse"; export declare class FaxLineListResponse { "listInfo"?: ListInfoResponse; - "faxLines"?: Array; + "faxLines"?: Array; "warnings"?: WarningResponse; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; diff --git a/sdks/node/types/model/faxLineResponse.d.ts b/sdks/node/types/model/faxLineResponse.d.ts index f8e5eb3fb..b316b355a 100644 --- a/sdks/node/types/model/faxLineResponse.d.ts +++ b/sdks/node/types/model/faxLineResponse.d.ts @@ -1,7 +1,8 @@ import { AttributeTypeMap } from "./"; +import { FaxLine } from "./faxLine"; import { WarningResponse } from "./warningResponse"; export declare class FaxLineResponse { - "faxLine"?: FaxLineResponse; + "faxLine"?: FaxLine; "warnings"?: WarningResponse; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; diff --git a/sdks/node/types/model/index.d.ts b/sdks/node/types/model/index.d.ts index 645124b51..7ef102f0e 100644 --- a/sdks/node/types/model/index.d.ts +++ b/sdks/node/types/model/index.d.ts @@ -32,6 +32,7 @@ import { ErrorResponseError } from "./errorResponseError"; import { EventCallbackRequest } from "./eventCallbackRequest"; import { EventCallbackRequestEvent } from "./eventCallbackRequestEvent"; import { EventCallbackRequestEventMetadata } from "./eventCallbackRequestEventMetadata"; +import { FaxLine } from "./faxLine"; import { FaxLineAddUserRequest } from "./faxLineAddUserRequest"; import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; import { FaxLineAreaCodeGetProvinceEnum } from "./faxLineAreaCodeGetProvinceEnum"; @@ -188,4 +189,4 @@ export declare let enumsMap: { export declare let typeMap: { [index: string]: any; }; -export { AccountCreateRequest, AccountCreateResponse, AccountGetResponse, AccountResponse, AccountResponseQuotas, AccountResponseUsage, AccountUpdateRequest, AccountVerifyRequest, AccountVerifyResponse, AccountVerifyResponseAccount, ApiAppCreateRequest, ApiAppGetResponse, ApiAppListResponse, ApiAppResponse, ApiAppResponseOAuth, ApiAppResponseOptions, ApiAppResponseOwnerAccount, ApiAppResponseWhiteLabelingOptions, ApiAppUpdateRequest, BulkSendJobGetResponse, BulkSendJobGetResponseSignatureRequests, BulkSendJobListResponse, BulkSendJobResponse, BulkSendJobSendResponse, EmbeddedEditUrlRequest, EmbeddedEditUrlResponse, EmbeddedEditUrlResponseEmbedded, EmbeddedSignUrlResponse, EmbeddedSignUrlResponseEmbedded, ErrorResponse, ErrorResponseError, EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, FileResponse, FileResponseDataUri, ListInfoResponse, OAuthTokenGenerateRequest, OAuthTokenRefreshRequest, OAuthTokenResponse, ReportCreateRequest, ReportCreateResponse, ReportResponse, SignatureRequestBulkCreateEmbeddedWithTemplateRequest, SignatureRequestBulkSendWithTemplateRequest, SignatureRequestCreateEmbeddedRequest, SignatureRequestCreateEmbeddedWithTemplateRequest, SignatureRequestGetResponse, SignatureRequestListResponse, SignatureRequestRemindRequest, SignatureRequestResponse, SignatureRequestResponseAttachment, SignatureRequestResponseCustomFieldBase, SignatureRequestResponseCustomFieldCheckbox, SignatureRequestResponseCustomFieldText, SignatureRequestResponseCustomFieldTypeEnum, SignatureRequestResponseDataBase, SignatureRequestResponseDataTypeEnum, SignatureRequestResponseDataValueCheckbox, SignatureRequestResponseDataValueCheckboxMerge, SignatureRequestResponseDataValueDateSigned, SignatureRequestResponseDataValueDropdown, SignatureRequestResponseDataValueInitials, SignatureRequestResponseDataValueRadio, SignatureRequestResponseDataValueSignature, SignatureRequestResponseDataValueText, SignatureRequestResponseDataValueTextMerge, SignatureRequestResponseSignatures, SignatureRequestSendRequest, SignatureRequestSendWithTemplateRequest, SignatureRequestUpdateRequest, SubAttachment, SubBulkSignerList, SubBulkSignerListCustomField, SubCC, SubCustomField, SubEditorOptions, SubFieldOptions, SubFormFieldGroup, SubFormFieldRule, SubFormFieldRuleAction, SubFormFieldRuleTrigger, SubFormFieldsPerDocumentBase, SubFormFieldsPerDocumentCheckbox, SubFormFieldsPerDocumentCheckboxMerge, SubFormFieldsPerDocumentDateSigned, SubFormFieldsPerDocumentDropdown, SubFormFieldsPerDocumentFontEnum, SubFormFieldsPerDocumentHyperlink, SubFormFieldsPerDocumentInitials, SubFormFieldsPerDocumentRadio, SubFormFieldsPerDocumentSignature, SubFormFieldsPerDocumentText, SubFormFieldsPerDocumentTextMerge, SubFormFieldsPerDocumentTypeEnum, SubMergeField, SubOAuth, SubOptions, SubSignatureRequestGroupedSigners, SubSignatureRequestSigner, SubSignatureRequestTemplateSigner, SubSigningOptions, SubTeamResponse, SubTemplateRole, SubUnclaimedDraftSigner, SubUnclaimedDraftTemplateSigner, SubWhiteLabelingOptions, TeamAddMemberRequest, TeamCreateRequest, TeamGetInfoResponse, TeamGetResponse, TeamInfoResponse, TeamInviteResponse, TeamInvitesResponse, TeamMemberResponse, TeamMembersResponse, TeamParentResponse, TeamRemoveMemberRequest, TeamResponse, TeamSubTeamsResponse, TeamUpdateRequest, TemplateAddUserRequest, TemplateCreateEmbeddedDraftRequest, TemplateCreateEmbeddedDraftResponse, TemplateCreateEmbeddedDraftResponseTemplate, TemplateCreateRequest, TemplateCreateResponse, TemplateCreateResponseTemplate, TemplateEditResponse, TemplateGetResponse, TemplateListResponse, TemplateRemoveUserRequest, TemplateResponse, TemplateResponseAccount, TemplateResponseAccountQuota, TemplateResponseCCRole, TemplateResponseDocument, TemplateResponseDocumentCustomFieldBase, TemplateResponseDocumentCustomFieldCheckbox, TemplateResponseDocumentCustomFieldText, TemplateResponseDocumentFieldGroup, TemplateResponseDocumentFieldGroupRule, TemplateResponseDocumentFormFieldBase, TemplateResponseDocumentFormFieldCheckbox, TemplateResponseDocumentFormFieldDateSigned, TemplateResponseDocumentFormFieldDropdown, TemplateResponseDocumentFormFieldHyperlink, TemplateResponseDocumentFormFieldInitials, TemplateResponseDocumentFormFieldRadio, TemplateResponseDocumentFormFieldSignature, TemplateResponseDocumentFormFieldText, TemplateResponseDocumentStaticFieldBase, TemplateResponseDocumentStaticFieldCheckbox, TemplateResponseDocumentStaticFieldDateSigned, TemplateResponseDocumentStaticFieldDropdown, TemplateResponseDocumentStaticFieldHyperlink, TemplateResponseDocumentStaticFieldInitials, TemplateResponseDocumentStaticFieldRadio, TemplateResponseDocumentStaticFieldSignature, TemplateResponseDocumentStaticFieldText, TemplateResponseFieldAvgTextLength, TemplateResponseSignerRole, TemplateUpdateFilesRequest, TemplateUpdateFilesResponse, TemplateUpdateFilesResponseTemplate, UnclaimedDraftCreateEmbeddedRequest, UnclaimedDraftCreateEmbeddedWithTemplateRequest, UnclaimedDraftCreateRequest, UnclaimedDraftCreateResponse, UnclaimedDraftEditAndResendRequest, UnclaimedDraftResponse, WarningResponse, EventCallbackHelper, RequestDetailedFile, RequestFile, AttributeTypeMap, ObjectSerializer, Authentication, HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, VoidAuth, Interceptor, }; +export { AccountCreateRequest, AccountCreateResponse, AccountGetResponse, AccountResponse, AccountResponseQuotas, AccountResponseUsage, AccountUpdateRequest, AccountVerifyRequest, AccountVerifyResponse, AccountVerifyResponseAccount, ApiAppCreateRequest, ApiAppGetResponse, ApiAppListResponse, ApiAppResponse, ApiAppResponseOAuth, ApiAppResponseOptions, ApiAppResponseOwnerAccount, ApiAppResponseWhiteLabelingOptions, ApiAppUpdateRequest, BulkSendJobGetResponse, BulkSendJobGetResponseSignatureRequests, BulkSendJobListResponse, BulkSendJobResponse, BulkSendJobSendResponse, EmbeddedEditUrlRequest, EmbeddedEditUrlResponse, EmbeddedEditUrlResponseEmbedded, EmbeddedSignUrlResponse, EmbeddedSignUrlResponseEmbedded, ErrorResponse, ErrorResponseError, EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, FaxLine, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetResponse, FaxLineAreaCodeGetStateEnum, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse, FileResponse, FileResponseDataUri, ListInfoResponse, OAuthTokenGenerateRequest, OAuthTokenRefreshRequest, OAuthTokenResponse, ReportCreateRequest, ReportCreateResponse, ReportResponse, SignatureRequestBulkCreateEmbeddedWithTemplateRequest, SignatureRequestBulkSendWithTemplateRequest, SignatureRequestCreateEmbeddedRequest, SignatureRequestCreateEmbeddedWithTemplateRequest, SignatureRequestGetResponse, SignatureRequestListResponse, SignatureRequestRemindRequest, SignatureRequestResponse, SignatureRequestResponseAttachment, SignatureRequestResponseCustomFieldBase, SignatureRequestResponseCustomFieldCheckbox, SignatureRequestResponseCustomFieldText, SignatureRequestResponseCustomFieldTypeEnum, SignatureRequestResponseDataBase, SignatureRequestResponseDataTypeEnum, SignatureRequestResponseDataValueCheckbox, SignatureRequestResponseDataValueCheckboxMerge, SignatureRequestResponseDataValueDateSigned, SignatureRequestResponseDataValueDropdown, SignatureRequestResponseDataValueInitials, SignatureRequestResponseDataValueRadio, SignatureRequestResponseDataValueSignature, SignatureRequestResponseDataValueText, SignatureRequestResponseDataValueTextMerge, SignatureRequestResponseSignatures, SignatureRequestSendRequest, SignatureRequestSendWithTemplateRequest, SignatureRequestUpdateRequest, SubAttachment, SubBulkSignerList, SubBulkSignerListCustomField, SubCC, SubCustomField, SubEditorOptions, SubFieldOptions, SubFormFieldGroup, SubFormFieldRule, SubFormFieldRuleAction, SubFormFieldRuleTrigger, SubFormFieldsPerDocumentBase, SubFormFieldsPerDocumentCheckbox, SubFormFieldsPerDocumentCheckboxMerge, SubFormFieldsPerDocumentDateSigned, SubFormFieldsPerDocumentDropdown, SubFormFieldsPerDocumentFontEnum, SubFormFieldsPerDocumentHyperlink, SubFormFieldsPerDocumentInitials, SubFormFieldsPerDocumentRadio, SubFormFieldsPerDocumentSignature, SubFormFieldsPerDocumentText, SubFormFieldsPerDocumentTextMerge, SubFormFieldsPerDocumentTypeEnum, SubMergeField, SubOAuth, SubOptions, SubSignatureRequestGroupedSigners, SubSignatureRequestSigner, SubSignatureRequestTemplateSigner, SubSigningOptions, SubTeamResponse, SubTemplateRole, SubUnclaimedDraftSigner, SubUnclaimedDraftTemplateSigner, SubWhiteLabelingOptions, TeamAddMemberRequest, TeamCreateRequest, TeamGetInfoResponse, TeamGetResponse, TeamInfoResponse, TeamInviteResponse, TeamInvitesResponse, TeamMemberResponse, TeamMembersResponse, TeamParentResponse, TeamRemoveMemberRequest, TeamResponse, TeamSubTeamsResponse, TeamUpdateRequest, TemplateAddUserRequest, TemplateCreateEmbeddedDraftRequest, TemplateCreateEmbeddedDraftResponse, TemplateCreateEmbeddedDraftResponseTemplate, TemplateCreateRequest, TemplateCreateResponse, TemplateCreateResponseTemplate, TemplateEditResponse, TemplateGetResponse, TemplateListResponse, TemplateRemoveUserRequest, TemplateResponse, TemplateResponseAccount, TemplateResponseAccountQuota, TemplateResponseCCRole, TemplateResponseDocument, TemplateResponseDocumentCustomFieldBase, TemplateResponseDocumentCustomFieldCheckbox, TemplateResponseDocumentCustomFieldText, TemplateResponseDocumentFieldGroup, TemplateResponseDocumentFieldGroupRule, TemplateResponseDocumentFormFieldBase, TemplateResponseDocumentFormFieldCheckbox, TemplateResponseDocumentFormFieldDateSigned, TemplateResponseDocumentFormFieldDropdown, TemplateResponseDocumentFormFieldHyperlink, TemplateResponseDocumentFormFieldInitials, TemplateResponseDocumentFormFieldRadio, TemplateResponseDocumentFormFieldSignature, TemplateResponseDocumentFormFieldText, TemplateResponseDocumentStaticFieldBase, TemplateResponseDocumentStaticFieldCheckbox, TemplateResponseDocumentStaticFieldDateSigned, TemplateResponseDocumentStaticFieldDropdown, TemplateResponseDocumentStaticFieldHyperlink, TemplateResponseDocumentStaticFieldInitials, TemplateResponseDocumentStaticFieldRadio, TemplateResponseDocumentStaticFieldSignature, TemplateResponseDocumentStaticFieldText, TemplateResponseFieldAvgTextLength, TemplateResponseSignerRole, TemplateUpdateFilesRequest, TemplateUpdateFilesResponse, TemplateUpdateFilesResponseTemplate, UnclaimedDraftCreateEmbeddedRequest, UnclaimedDraftCreateEmbeddedWithTemplateRequest, UnclaimedDraftCreateRequest, UnclaimedDraftCreateResponse, UnclaimedDraftEditAndResendRequest, UnclaimedDraftResponse, WarningResponse, EventCallbackHelper, RequestDetailedFile, RequestFile, AttributeTypeMap, ObjectSerializer, Authentication, HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, VoidAuth, Interceptor, }; diff --git a/sdks/php/README.md b/sdks/php/README.md index 346a5de2d..025b02cca 100644 --- a/sdks/php/README.md +++ b/sdks/php/README.md @@ -248,6 +248,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](docs/Model/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/Model/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/Model/EventCallbackRequestEventMetadata.md) +- [FaxLine](docs/Model/FaxLine.md) - [FaxLineAddUserRequest](docs/Model/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/Model/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/Model/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/php/docs/Api/FaxLineApi.md b/sdks/php/docs/Api/FaxLineApi.md index 4f4e9a82b..1130a2d2b 100644 --- a/sdks/php/docs/Api/FaxLineApi.md +++ b/sdks/php/docs/Api/FaxLineApi.md @@ -100,11 +100,7 @@ $config->setUsername("YOUR_API_KEY"); $faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); try { - $result = $faxLineApi->faxLineAreaCodeGet( - Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum::US, - Dropbox\Sign\Model\FaxLineAreaCodeGetStateEnum::CA, - ); - + $result = $faxLineApi->faxLineAreaCodeGet("US", "CA"); print_r($result); } catch (Dropbox\Sign\ApiException $e) { $error = $e->getResponseObject(); @@ -118,9 +114,9 @@ try { |Name | Type | Description | Notes | | ------------- | ------------- | ------------- | ------------- | -| **country** | [**\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum**](../Model/.md)| Filter area codes by country. | | -| **state** | [**\Dropbox\Sign\Model\FaxLineAreaCodeGetStateEnum**](../Model/.md)| Filter area codes by state. | [optional] | -| **province** | [**\Dropbox\Sign\Model\FaxLineAreaCodeGetProvinceEnum**](../Model/.md)| Filter area codes by province. | [optional] | +| **country** | **string**| Filter area codes by country. | | +| **state** | **string**| Filter area codes by state. | [optional] | +| **province** | **string**| Filter area codes by province. | [optional] | | **city** | **string**| Filter area codes by city. | [optional] | ### Return type diff --git a/sdks/php/docs/Model/FaxLine.md b/sdks/php/docs/Model/FaxLine.md new file mode 100644 index 000000000..222fdd4cf --- /dev/null +++ b/sdks/php/docs/Model/FaxLine.md @@ -0,0 +1,14 @@ +# # FaxLine + + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +| `number` | ```string``` | Number | | +| `created_at` | ```string``` | Created at | | +| `updated_at` | ```string``` | Updated at | | +| `accounts` | [```\Dropbox\Sign\Model\AccountResponse[]```](AccountResponse.md) | | | + +[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineCreateRequest.md b/sdks/php/docs/Model/FaxLineCreateRequest.md index 036097fb9..cf77cab4b 100644 --- a/sdks/php/docs/Model/FaxLineCreateRequest.md +++ b/sdks/php/docs/Model/FaxLineCreateRequest.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `area_code`*_required_ | ```string``` | Area code | | -| `country`*_required_ | [```\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `country`*_required_ | ```string``` | Country | | | `city` | ```string``` | City | | | `account_id` | ```string``` | Account ID | | diff --git a/sdks/php/docs/Model/FaxLineListResponse.md b/sdks/php/docs/Model/FaxLineListResponse.md index 9833a7c5d..64fa947cd 100644 --- a/sdks/php/docs/Model/FaxLineListResponse.md +++ b/sdks/php/docs/Model/FaxLineListResponse.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `list_info` | [```\Dropbox\Sign\Model\ListInfoResponse```](ListInfoResponse.md) | | | -| `fax_lines` | [```\Dropbox\Sign\Model\FaxLineResponse[]```](FaxLineResponse.md) | | | +| `fax_lines` | [```\Dropbox\Sign\Model\FaxLine[]```](FaxLine.md) | | | | `warnings` | [```\Dropbox\Sign\Model\WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineResponse.md b/sdks/php/docs/Model/FaxLineResponse.md index 803ba6891..f459c42e7 100644 --- a/sdks/php/docs/Model/FaxLineResponse.md +++ b/sdks/php/docs/Model/FaxLineResponse.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `fax_line` | [```\Dropbox\Sign\Model\FaxLineResponse```](FaxLineResponse.md) | | | +| `fax_line` | [```\Dropbox\Sign\Model\FaxLine```](FaxLine.md) | | | | `warnings` | [```\Dropbox\Sign\Model\WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/src/Api/FaxLineApi.php b/sdks/php/src/Api/FaxLineApi.php index 807641c7e..d2be6d60f 100644 --- a/sdks/php/src/Api/FaxLineApi.php +++ b/sdks/php/src/Api/FaxLineApi.php @@ -448,16 +448,16 @@ public function faxLineAddUserRequest(Model\FaxLineAddUserRequest $fax_line_add_ * * Get Available Fax Line Area Codes * - * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) - * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) - * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $country Filter area codes by country. (required) + * @param string $state Filter area codes by state. (optional) + * @param string $province Filter area codes by province. (optional) * @param string $city Filter area codes by city. (optional) * * @throws ApiException on non-2xx response * @throws InvalidArgumentException * @return Model\FaxLineAreaCodeGetResponse */ - public function faxLineAreaCodeGet(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + public function faxLineAreaCodeGet(string $country, string $state = null, string $province = null, string $city = null) { list($response) = $this->faxLineAreaCodeGetWithHttpInfo($country, $state, $province, $city); @@ -469,16 +469,16 @@ public function faxLineAreaCodeGet(Model\FaxLineAreaCodeGetCountryEnum $country, * * Get Available Fax Line Area Codes * - * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) - * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) - * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $country Filter area codes by country. (required) + * @param string $state Filter area codes by state. (optional) + * @param string $province Filter area codes by province. (optional) * @param string $city Filter area codes by city. (optional) * * @throws ApiException on non-2xx response * @throws InvalidArgumentException * @return array of Model\FaxLineAreaCodeGetResponse, HTTP status code, HTTP response headers (array of strings) */ - public function faxLineAreaCodeGetWithHttpInfo(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + public function faxLineAreaCodeGetWithHttpInfo(string $country, string $state = null, string $province = null, string $city = null) { $request = $this->faxLineAreaCodeGetRequest($country, $state, $province, $city); @@ -594,15 +594,15 @@ public function faxLineAreaCodeGetWithHttpInfo(Model\FaxLineAreaCodeGetCountryEn * * Get Available Fax Line Area Codes * - * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) - * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) - * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $country Filter area codes by country. (required) + * @param string $state Filter area codes by state. (optional) + * @param string $province Filter area codes by province. (optional) * @param string $city Filter area codes by city. (optional) * * @throws InvalidArgumentException * @return Promise\PromiseInterface */ - public function faxLineAreaCodeGetAsync(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + public function faxLineAreaCodeGetAsync(string $country, string $state = null, string $province = null, string $city = null) { return $this->faxLineAreaCodeGetAsyncWithHttpInfo($country, $state, $province, $city) ->then( @@ -617,15 +617,15 @@ function ($response) { * * Get Available Fax Line Area Codes * - * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) - * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) - * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $country Filter area codes by country. (required) + * @param string $state Filter area codes by state. (optional) + * @param string $province Filter area codes by province. (optional) * @param string $city Filter area codes by city. (optional) * * @throws InvalidArgumentException * @return Promise\PromiseInterface */ - public function faxLineAreaCodeGetAsyncWithHttpInfo(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + public function faxLineAreaCodeGetAsyncWithHttpInfo(string $country, string $state = null, string $province = null, string $city = null) { $returnType = '\Dropbox\Sign\Model\FaxLineAreaCodeGetResponse'; $request = $this->faxLineAreaCodeGetRequest($country, $state, $province, $city); @@ -666,15 +666,15 @@ function ($exception) { /** * Create request for operation 'faxLineAreaCodeGet' * - * @param Model\FaxLineAreaCodeGetCountryEnum $country Filter area codes by country. (required) - * @param Model\FaxLineAreaCodeGetStateEnum $state Filter area codes by state. (optional) - * @param Model\FaxLineAreaCodeGetProvinceEnum $province Filter area codes by province. (optional) + * @param string $country Filter area codes by country. (required) + * @param string $state Filter area codes by state. (optional) + * @param string $province Filter area codes by province. (optional) * @param string $city Filter area codes by city. (optional) * * @throws InvalidArgumentException * @return Psr7\Request */ - public function faxLineAreaCodeGetRequest(Model\FaxLineAreaCodeGetCountryEnum $country, Model\FaxLineAreaCodeGetStateEnum $state = null, Model\FaxLineAreaCodeGetProvinceEnum $province = null, string $city = null) + public function faxLineAreaCodeGetRequest(string $country, string $state = null, string $province = null, string $city = null) { // verify the required parameter 'country' is set if ($country === null || (is_array($country) && count($country) === 0)) { diff --git a/sdks/php/src/Model/FaxLine.php b/sdks/php/src/Model/FaxLine.php new file mode 100644 index 000000000..af17884c2 --- /dev/null +++ b/sdks/php/src/Model/FaxLine.php @@ -0,0 +1,431 @@ + + * @template TKey int|null + * @template TValue mixed|null + */ +class FaxLine implements ModelInterface, ArrayAccess, JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'FaxLine'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'number' => 'string', + 'created_at' => 'string', + 'updated_at' => 'string', + 'accounts' => '\Dropbox\Sign\Model\AccountResponse[]', + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'number' => null, + 'created_at' => null, + 'updated_at' => null, + 'accounts' => null, + ]; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'number' => 'number', + 'created_at' => 'created_at', + 'updated_at' => 'updated_at', + 'accounts' => 'accounts', + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'number' => 'setNumber', + 'created_at' => 'setCreatedAt', + 'updated_at' => 'setUpdatedAt', + 'accounts' => 'setAccounts', + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'number' => 'getNumber', + 'created_at' => 'getCreatedAt', + 'updated_at' => 'getUpdatedAt', + 'accounts' => 'getAccounts', + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + /** + * Associative array for storing property values + * + * @var array + */ + protected $container = []; + + /** + * Constructor + * + * @param array|null $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->container['number'] = $data['number'] ?? null; + $this->container['created_at'] = $data['created_at'] ?? null; + $this->container['updated_at'] = $data['updated_at'] ?? null; + $this->container['accounts'] = $data['accounts'] ?? null; + } + + /** @deprecated use ::init() */ + public static function fromArray(array $data): FaxLine + { + return self::init($data); + } + + /** Attempt to instantiate and hydrate a new instance of this class */ + public static function init(array $data): FaxLine + { + /** @var FaxLine $obj */ + $obj = ObjectSerializer::deserialize( + $data, + FaxLine::class, + ); + + return $obj; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + /** + * Gets number + * + * @return string|null + */ + public function getNumber() + { + return $this->container['number']; + } + + /** + * Sets number + * + * @param string|null $number Number + * + * @return self + */ + public function setNumber(?string $number) + { + $this->container['number'] = $number; + + return $this; + } + + /** + * Gets created_at + * + * @return string|null + */ + public function getCreatedAt() + { + return $this->container['created_at']; + } + + /** + * Sets created_at + * + * @param string|null $created_at Created at + * + * @return self + */ + public function setCreatedAt(?string $created_at) + { + $this->container['created_at'] = $created_at; + + return $this; + } + + /** + * Gets updated_at + * + * @return string|null + */ + public function getUpdatedAt() + { + return $this->container['updated_at']; + } + + /** + * Sets updated_at + * + * @param string|null $updated_at Updated at + * + * @return self + */ + public function setUpdatedAt(?string $updated_at) + { + $this->container['updated_at'] = $updated_at; + + return $this; + } + + /** + * Gets accounts + * + * @return AccountResponse[]|null + */ + public function getAccounts() + { + return $this->container['accounts']; + } + + /** + * Sets accounts + * + * @param AccountResponse[]|null $accounts accounts + * + * @return self + */ + public function setAccounts(?array $accounts) + { + $this->container['accounts'] = $accounts; + + return $this; + } + + /** + * Returns true if offset exists. False otherwise. + * + * @param mixed $offset Offset + * + * @return bool + */ + #[ReturnTypeWillChange] + public function offsetExists($offset) + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param mixed $offset Offset + * + * @return mixed|null + */ + #[ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param mixed $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetSet($offset, $value) + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param mixed $offset Offset + * + * @return void + */ + #[ReturnTypeWillChange] + public function offsetUnset($offset) + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @see https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return scalar|object|array|null returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource + */ + #[ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_UNESCAPED_SLASHES + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} diff --git a/sdks/php/src/Model/FaxLineCreateRequest.php b/sdks/php/src/Model/FaxLineCreateRequest.php index 534876b6d..610690560 100644 --- a/sdks/php/src/Model/FaxLineCreateRequest.php +++ b/sdks/php/src/Model/FaxLineCreateRequest.php @@ -30,6 +30,7 @@ use ArrayAccess; use Dropbox\Sign\ObjectSerializer; +use InvalidArgumentException; use JsonSerializable; use ReturnTypeWillChange; @@ -61,7 +62,7 @@ class FaxLineCreateRequest implements ModelInterface, ArrayAccess, JsonSerializa */ protected static $openAPITypes = [ 'area_code' => 'string', - 'country' => '\Dropbox\Sign\Model\FaxLineAreaCodeGetCountryEnum', + 'country' => 'string', 'city' => 'string', 'account_id' => 'string', ]; @@ -178,6 +179,24 @@ public function getModelName() return self::$openAPIModelName; } + public const COUNTRY_CA = 'CA'; + public const COUNTRY_US = 'US'; + public const COUNTRY_UK = 'UK'; + + /** + * Gets allowable values of the enum + * + * @return string[] + */ + public function getCountryAllowableValues() + { + return [ + self::COUNTRY_CA, + self::COUNTRY_US, + self::COUNTRY_UK, + ]; + } + /** * Associative array for storing property values * @@ -232,6 +251,14 @@ public function listInvalidProperties() if ($this->container['country'] === null) { $invalidProperties[] = "'country' can't be null"; } + $allowedValues = $this->getCountryAllowableValues(); + if (!is_null($this->container['country']) && !in_array($this->container['country'], $allowedValues, true)) { + $invalidProperties[] = sprintf( + "invalid value '%s' for 'country', must be one of '%s'", + $this->container['country'], + implode("', '", $allowedValues) + ); + } return $invalidProperties; } @@ -274,7 +301,7 @@ public function setAreaCode(string $area_code) /** * Gets country * - * @return FaxLineAreaCodeGetCountryEnum + * @return string */ public function getCountry() { @@ -284,12 +311,22 @@ public function getCountry() /** * Sets country * - * @param FaxLineAreaCodeGetCountryEnum $country country + * @param string $country Country * * @return self */ - public function setCountry(FaxLineAreaCodeGetCountryEnum $country) + public function setCountry(string $country) { + $allowedValues = $this->getCountryAllowableValues(); + if (!in_array($country, $allowedValues, true)) { + throw new InvalidArgumentException( + sprintf( + "Invalid value '%s' for 'country', must be one of '%s'", + $country, + implode("', '", $allowedValues) + ) + ); + } $this->container['country'] = $country; return $this; diff --git a/sdks/php/src/Model/FaxLineListResponse.php b/sdks/php/src/Model/FaxLineListResponse.php index cc12477ae..cfd50e5d1 100644 --- a/sdks/php/src/Model/FaxLineListResponse.php +++ b/sdks/php/src/Model/FaxLineListResponse.php @@ -62,7 +62,7 @@ class FaxLineListResponse implements ModelInterface, ArrayAccess, JsonSerializab */ protected static $openAPITypes = [ 'list_info' => '\Dropbox\Sign\Model\ListInfoResponse', - 'fax_lines' => '\Dropbox\Sign\Model\FaxLineResponse[]', + 'fax_lines' => '\Dropbox\Sign\Model\FaxLine[]', 'warnings' => '\Dropbox\Sign\Model\WarningResponse', ]; @@ -262,7 +262,7 @@ public function setListInfo(?ListInfoResponse $list_info) /** * Gets fax_lines * - * @return FaxLineResponse[]|null + * @return FaxLine[]|null */ public function getFaxLines() { @@ -272,7 +272,7 @@ public function getFaxLines() /** * Sets fax_lines * - * @param FaxLineResponse[]|null $fax_lines fax_lines + * @param FaxLine[]|null $fax_lines fax_lines * * @return self */ diff --git a/sdks/php/src/Model/FaxLineResponse.php b/sdks/php/src/Model/FaxLineResponse.php index b3a567c4a..f86a2f239 100644 --- a/sdks/php/src/Model/FaxLineResponse.php +++ b/sdks/php/src/Model/FaxLineResponse.php @@ -61,7 +61,7 @@ class FaxLineResponse implements ModelInterface, ArrayAccess, JsonSerializable * @var string[] */ protected static $openAPITypes = [ - 'fax_line' => '\Dropbox\Sign\Model\FaxLineResponse', + 'fax_line' => '\Dropbox\Sign\Model\FaxLine', 'warnings' => '\Dropbox\Sign\Model\WarningResponse', ]; @@ -232,7 +232,7 @@ public function valid() /** * Gets fax_line * - * @return FaxLineResponse|null + * @return FaxLine|null */ public function getFaxLine() { @@ -242,11 +242,11 @@ public function getFaxLine() /** * Sets fax_line * - * @param FaxLineResponse|null $fax_line fax_line + * @param FaxLine|null $fax_line fax_line * * @return self */ - public function setFaxLine(?FaxLineResponse $fax_line) + public function setFaxLine(?FaxLine $fax_line) { $this->container['fax_line'] = $fax_line; diff --git a/sdks/python/.openapi-generator/FILES b/sdks/python/.openapi-generator/FILES index f51adff33..d54146f59 100644 --- a/sdks/python/.openapi-generator/FILES +++ b/sdks/python/.openapi-generator/FILES @@ -41,6 +41,7 @@ docs/ErrorResponseError.md docs/EventCallbackRequest.md docs/EventCallbackRequestEvent.md docs/EventCallbackRequestEventMetadata.md +docs/FaxLine.md docs/FaxLineAddUserRequest.md docs/FaxLineApi.md docs/FaxLineAreaCodeGetCountryEnum.md @@ -249,6 +250,7 @@ dropbox_sign/model/error_response_error.py dropbox_sign/model/event_callback_request.py dropbox_sign/model/event_callback_request_event.py dropbox_sign/model/event_callback_request_event_metadata.py +dropbox_sign/model/fax_line.py dropbox_sign/model/fax_line_add_user_request.py dropbox_sign/model/fax_line_area_code_get_country_enum.py dropbox_sign/model/fax_line_area_code_get_province_enum.py diff --git a/sdks/python/README.md b/sdks/python/README.md index 5c1ad75b7..318d051eb 100644 --- a/sdks/python/README.md +++ b/sdks/python/README.md @@ -207,6 +207,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [FaxLine](docs/FaxLine.md) - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/python/docs/FaxLine.md b/sdks/python/docs/FaxLine.md new file mode 100644 index 000000000..dca4bb594 --- /dev/null +++ b/sdks/python/docs/FaxLine.md @@ -0,0 +1,17 @@ +# FaxLine + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number` | ```str``` | Number | | +| `created_at` | ```str``` | Created at | | +| `updated_at` | ```str``` | Updated at | | +| `accounts` | [```[AccountResponse]```](AccountResponse.md) | | | + + +[[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/sdks/python/docs/FaxLineApi.md b/sdks/python/docs/FaxLineApi.md index abfedb435..e0dda44a4 100644 --- a/sdks/python/docs/FaxLineApi.md +++ b/sdks/python/docs/FaxLineApi.md @@ -96,7 +96,7 @@ Returns a response with the area codes available for a given state/provice and c from pprint import pprint from dropbox_sign import \ - ApiClient, ApiException, Configuration, apis, models + ApiClient, ApiException, Configuration, apis configuration = Configuration( # Configure HTTP basic authorization: api_key @@ -107,7 +107,7 @@ with ApiClient(configuration) as api_client: fax_line_api = apis.FaxLineApi(api_client) try: - response = fax_line_api.fax_line_area_code_get(models.FaxLineAreaCodeGetCountryEnum("US"), models.FaxLineAreaCodeGetStateEnum("CA")) + response = fax_line_api.fax_line_area_code_get("US", "CA") pprint(response) except ApiException as e: print("Exception when calling Dropbox Sign API: %s\n" % e) @@ -119,9 +119,9 @@ with ApiClient(configuration) as api_client: | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `country` | [**FaxLineAreaCodeGetCountryEnum**](.md) | Filter area codes by country. | | -| `state` | [**FaxLineAreaCodeGetStateEnum**](.md) | Filter area codes by state. | [optional] | -| `province` | [**FaxLineAreaCodeGetProvinceEnum**](.md) | Filter area codes by province. | [optional] | +| `country` | **str** | Filter area codes by country. | | +| `state` | **str** | Filter area codes by state. | [optional] | +| `province` | **str** | Filter area codes by province. | [optional] | | `city` | **str** | Filter area codes by city. | [optional] | ### Return type diff --git a/sdks/python/docs/FaxLineCreateRequest.md b/sdks/python/docs/FaxLineCreateRequest.md index bd8cbb85d..8a44fbf70 100644 --- a/sdks/python/docs/FaxLineCreateRequest.md +++ b/sdks/python/docs/FaxLineCreateRequest.md @@ -7,7 +7,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `area_code`*_required_ | ```str``` | Area code | | -| `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `country`*_required_ | ```str``` | Country | | | `city` | ```str``` | City | | | `account_id` | ```str``` | Account ID | | diff --git a/sdks/python/docs/FaxLineListResponse.md b/sdks/python/docs/FaxLineListResponse.md index 741c381d1..644f8073f 100644 --- a/sdks/python/docs/FaxLineListResponse.md +++ b/sdks/python/docs/FaxLineListResponse.md @@ -7,7 +7,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `list_info` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `fax_lines` | [```[FaxLineResponse]```](FaxLineResponse.md) | | | +| `fax_lines` | [```[FaxLine]```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/python/docs/FaxLineResponse.md b/sdks/python/docs/FaxLineResponse.md index 3c8fb305e..07dc2589e 100644 --- a/sdks/python/docs/FaxLineResponse.md +++ b/sdks/python/docs/FaxLineResponse.md @@ -6,7 +6,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `fax_line` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `fax_line` | [```FaxLine```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/python/dropbox_sign/api/fax_line_api.py b/sdks/python/dropbox_sign/api/fax_line_api.py index ba67ed5a8..26750bb50 100644 --- a/sdks/python/dropbox_sign/api/fax_line_api.py +++ b/sdks/python/dropbox_sign/api/fax_line_api.py @@ -25,10 +25,7 @@ ) from dropbox_sign.model.error_response import ErrorResponse from dropbox_sign.model.fax_line_add_user_request import FaxLineAddUserRequest -from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum -from dropbox_sign.model.fax_line_area_code_get_province_enum import FaxLineAreaCodeGetProvinceEnum from dropbox_sign.model.fax_line_area_code_get_response import FaxLineAreaCodeGetResponse -from dropbox_sign.model.fax_line_area_code_get_state_enum import FaxLineAreaCodeGetStateEnum from dropbox_sign.model.fax_line_create_request import FaxLineCreateRequest from dropbox_sign.model.fax_line_delete_request import FaxLineDeleteRequest from dropbox_sign.model.fax_line_list_response import FaxLineListResponse @@ -123,6 +120,9 @@ def __init__(self, api_client=None): 'nullable': [ ], 'enum': [ + 'country', + 'state', + 'province', ], 'validation': [ ] @@ -131,14 +131,90 @@ def __init__(self, api_client=None): 'validations': { }, 'allowed_values': { + ('country',): { + + "CA": "CA", + "US": "US", + "UK": "UK" + }, + ('state',): { + + "AK": "AK", + "AL": "AL", + "AR": "AR", + "AZ": "AZ", + "CA": "CA", + "CO": "CO", + "CT": "CT", + "DC": "DC", + "DE": "DE", + "FL": "FL", + "GA": "GA", + "HI": "HI", + "IA": "IA", + "ID": "ID", + "IL": "IL", + "IN": "IN", + "KS": "KS", + "KY": "KY", + "LA": "LA", + "MA": "MA", + "MD": "MD", + "ME": "ME", + "MI": "MI", + "MN": "MN", + "MO": "MO", + "MS": "MS", + "MT": "MT", + "NC": "NC", + "ND": "ND", + "NE": "NE", + "NH": "NH", + "NJ": "NJ", + "NM": "NM", + "NV": "NV", + "NY": "NY", + "OH": "OH", + "OK": "OK", + "OR": "OR", + "PA": "PA", + "RI": "RI", + "SC": "SC", + "SD": "SD", + "TN": "TN", + "TX": "TX", + "UT": "UT", + "VA": "VA", + "VT": "VT", + "WA": "WA", + "WI": "WI", + "WV": "WV", + "WY": "WY" + }, + ('province',): { + + "AB": "AB", + "BC": "BC", + "MB": "MB", + "NB": "NB", + "NL": "NL", + "NT": "NT", + "NS": "NS", + "NU": "NU", + "ON": "ON", + "PE": "PE", + "QC": "QC", + "SK": "SK", + "YT": "YT" + }, }, 'openapi_types': { 'country': - (FaxLineAreaCodeGetCountryEnum,), + (str,), 'state': - (FaxLineAreaCodeGetStateEnum,), + (str,), 'province': - (FaxLineAreaCodeGetProvinceEnum,), + (str,), 'city': (str,), }, @@ -552,11 +628,11 @@ def fax_line_area_code_get( >>> result = thread.get() Args: - country (FaxLineAreaCodeGetCountryEnum): Filter area codes by country. + country (str): Filter area codes by country. Keyword Args: - state (FaxLineAreaCodeGetStateEnum): Filter area codes by state.. [optional] - province (FaxLineAreaCodeGetProvinceEnum): Filter area codes by province.. [optional] + state (str): Filter area codes by state.. [optional] + province (str): Filter area codes by province.. [optional] city (str): Filter area codes by city.. [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. diff --git a/sdks/python/dropbox_sign/model/fax_line.py b/sdks/python/dropbox_sign/model/fax_line.py new file mode 100644 index 000000000..5c0da8910 --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line.py @@ -0,0 +1,327 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError +if TYPE_CHECKING: + from dropbox_sign.model.account_response import AccountResponse + + +def lazy_import(): + from dropbox_sign.model.account_response import AccountResponse + globals()['AccountResponse'] = AccountResponse + + +class FaxLine(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + lazy_import() + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + lazy_import() + return { + 'number': (str,), # noqa: E501 + 'created_at': (str,), # noqa: E501 + 'updated_at': (str,), # noqa: E501 + 'accounts': ([AccountResponse],), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLine: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLine], + _check_type=True, + ) + + attribute_map = { + 'number': 'number', # noqa: E501 + 'created_at': 'created_at', # noqa: E501 + 'updated_at': 'updated_at', # noqa: E501 + 'accounts': 'accounts', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def number(self) -> str: + return self.get("number") + + @number.setter + def number(self, value: str): + setattr(self, "number", value) + + @property + def created_at(self) -> str: + return self.get("created_at") + + @created_at.setter + def created_at(self, value: str): + setattr(self, "created_at", value) + + @property + def updated_at(self) -> str: + return self.get("updated_at") + + @updated_at.setter + def updated_at(self, value: str): + setattr(self, "updated_at", value) + + @property + def accounts(self) -> List[AccountResponse]: + return self.get("accounts") + + @accounts.setter + def accounts(self, value: List[AccountResponse]): + setattr(self, "accounts", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """FaxLine - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + number (str): Number. [optional] # noqa: E501 + created_at (str): Created at. [optional] # noqa: E501 + updated_at (str): Updated at. [optional] # noqa: E501 + accounts ([AccountResponse]): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): # noqa: E501 + """FaxLine - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + number (str): Number. [optional] # noqa: E501 + created_at (str): Created at. [optional] # noqa: E501 + updated_at (str): Updated at. [optional] # noqa: E501 + accounts ([AccountResponse]): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/model/fax_line_create_request.py b/sdks/python/dropbox_sign/model/fax_line_create_request.py index cdcc5df64..0a8927996 100644 --- a/sdks/python/dropbox_sign/model/fax_line_create_request.py +++ b/sdks/python/dropbox_sign/model/fax_line_create_request.py @@ -32,14 +32,8 @@ OpenApiModel ) from dropbox_sign.exceptions import ApiAttributeError -if TYPE_CHECKING: - from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum -def lazy_import(): - from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum - globals()['FaxLineAreaCodeGetCountryEnum'] = FaxLineAreaCodeGetCountryEnum - class FaxLineCreateRequest(ModelNormal): """NOTE: This class is auto generated by OpenAPI Generator. @@ -66,6 +60,11 @@ class FaxLineCreateRequest(ModelNormal): """ allowed_values = { + ('country',): { + 'CA': "CA", + 'US': "US", + 'UK': "UK", + }, } validations = { @@ -77,7 +76,6 @@ def additional_properties_type(): This must be a method because a model may have properties that are of type self, this must run after the class is loaded """ - lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 _nullable = False @@ -92,10 +90,9 @@ def openapi_types(): openapi_types (dict): The key is attribute name and the value is attribute type. """ - lazy_import() return { 'area_code': (str,), # noqa: E501 - 'country': (FaxLineAreaCodeGetCountryEnum,), # noqa: E501 + 'country': (str,), # noqa: E501 'city': (str,), # noqa: E501 'account_id': (str,), # noqa: E501 } @@ -141,11 +138,11 @@ def area_code(self, value: str): setattr(self, "area_code", value) @property - def country(self) -> FaxLineAreaCodeGetCountryEnum: + def country(self) -> str: return self.get("country") @country.setter - def country(self, value: FaxLineAreaCodeGetCountryEnum): + def country(self, value: str): setattr(self, "country", value) @property @@ -171,7 +168,7 @@ def _from_openapi_data(cls, area_code, country, *args, **kwargs): # noqa: E501 Args: area_code (str): Area code - country (FaxLineAreaCodeGetCountryEnum): + country (str): Country Keyword Args: _check_type (bool): if True, values for parameters in openapi_types @@ -260,7 +257,7 @@ def __init__(self, area_code, country, *args, **kwargs): # noqa: E501 Args: area_code (str): Area code - country (FaxLineAreaCodeGetCountryEnum): + country (str): Country Keyword Args: _check_type (bool): if True, values for parameters in openapi_types diff --git a/sdks/python/dropbox_sign/model/fax_line_list_response.py b/sdks/python/dropbox_sign/model/fax_line_list_response.py index 1cdfd68af..9b28060aa 100644 --- a/sdks/python/dropbox_sign/model/fax_line_list_response.py +++ b/sdks/python/dropbox_sign/model/fax_line_list_response.py @@ -33,16 +33,16 @@ ) from dropbox_sign.exceptions import ApiAttributeError if TYPE_CHECKING: - from dropbox_sign.model.fax_line_response import FaxLineResponse + from dropbox_sign.model.fax_line import FaxLine from dropbox_sign.model.list_info_response import ListInfoResponse from dropbox_sign.model.warning_response import WarningResponse def lazy_import(): - from dropbox_sign.model.fax_line_response import FaxLineResponse + from dropbox_sign.model.fax_line import FaxLine from dropbox_sign.model.list_info_response import ListInfoResponse from dropbox_sign.model.warning_response import WarningResponse - globals()['FaxLineResponse'] = FaxLineResponse + globals()['FaxLine'] = FaxLine globals()['ListInfoResponse'] = ListInfoResponse globals()['WarningResponse'] = WarningResponse @@ -101,7 +101,7 @@ def openapi_types(): lazy_import() return { 'list_info': (ListInfoResponse,), # noqa: E501 - 'fax_lines': ([FaxLineResponse],), # noqa: E501 + 'fax_lines': ([FaxLine],), # noqa: E501 'warnings': (WarningResponse,), # noqa: E501 } @@ -145,11 +145,11 @@ def list_info(self, value: ListInfoResponse): setattr(self, "list_info", value) @property - def fax_lines(self) -> List[FaxLineResponse]: + def fax_lines(self) -> List[FaxLine]: return self.get("fax_lines") @fax_lines.setter - def fax_lines(self, value: List[FaxLineResponse]): + def fax_lines(self, value: List[FaxLine]): setattr(self, "fax_lines", value) @property @@ -197,7 +197,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) list_info (ListInfoResponse): [optional] # noqa: E501 - fax_lines ([FaxLineResponse]): [optional] # noqa: E501 + fax_lines ([FaxLine]): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ @@ -281,7 +281,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) list_info (ListInfoResponse): [optional] # noqa: E501 - fax_lines ([FaxLineResponse]): [optional] # noqa: E501 + fax_lines ([FaxLine]): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ diff --git a/sdks/python/dropbox_sign/model/fax_line_response.py b/sdks/python/dropbox_sign/model/fax_line_response.py index d6519a1ba..8beff0a91 100644 --- a/sdks/python/dropbox_sign/model/fax_line_response.py +++ b/sdks/python/dropbox_sign/model/fax_line_response.py @@ -33,11 +33,14 @@ ) from dropbox_sign.exceptions import ApiAttributeError if TYPE_CHECKING: + from dropbox_sign.model.fax_line import FaxLine from dropbox_sign.model.warning_response import WarningResponse def lazy_import(): + from dropbox_sign.model.fax_line import FaxLine from dropbox_sign.model.warning_response import WarningResponse + globals()['FaxLine'] = FaxLine globals()['WarningResponse'] = WarningResponse @@ -94,7 +97,7 @@ def openapi_types(): """ lazy_import() return { - 'fax_line': (FaxLineResponse,), # noqa: E501 + 'fax_line': (FaxLine,), # noqa: E501 'warnings': (WarningResponse,), # noqa: E501 } @@ -129,11 +132,11 @@ def init(data: any) -> FaxLineResponse: _composed_schemas = {} @property - def fax_line(self) -> FaxLineResponse: + def fax_line(self) -> FaxLine: return self.get("fax_line") @fax_line.setter - def fax_line(self, value: FaxLineResponse): + def fax_line(self, value: FaxLine): setattr(self, "fax_line", value) @property @@ -180,7 +183,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) - fax_line (FaxLineResponse): [optional] # noqa: E501 + fax_line (FaxLine): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ @@ -263,7 +266,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) - fax_line (FaxLineResponse): [optional] # noqa: E501 + fax_line (FaxLine): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ diff --git a/sdks/python/dropbox_sign/models/__init__.py b/sdks/python/dropbox_sign/models/__init__.py index 939e5a2f2..b773dfd88 100644 --- a/sdks/python/dropbox_sign/models/__init__.py +++ b/sdks/python/dropbox_sign/models/__init__.py @@ -43,6 +43,7 @@ from dropbox_sign.model.event_callback_request import EventCallbackRequest from dropbox_sign.model.event_callback_request_event import EventCallbackRequestEvent from dropbox_sign.model.event_callback_request_event_metadata import EventCallbackRequestEventMetadata +from dropbox_sign.model.fax_line import FaxLine from dropbox_sign.model.fax_line_add_user_request import FaxLineAddUserRequest from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum from dropbox_sign.model.fax_line_area_code_get_province_enum import FaxLineAreaCodeGetProvinceEnum diff --git a/sdks/ruby/.openapi-generator/FILES b/sdks/ruby/.openapi-generator/FILES index 2e8de743e..263dd816f 100644 --- a/sdks/ruby/.openapi-generator/FILES +++ b/sdks/ruby/.openapi-generator/FILES @@ -45,6 +45,7 @@ docs/ErrorResponseError.md docs/EventCallbackRequest.md docs/EventCallbackRequestEvent.md docs/EventCallbackRequestEventMetadata.md +docs/FaxLine.md docs/FaxLineAddUserRequest.md docs/FaxLineApi.md docs/FaxLineAreaCodeGetCountryEnum.md @@ -251,6 +252,7 @@ lib/dropbox-sign/models/error_response_error.rb lib/dropbox-sign/models/event_callback_request.rb lib/dropbox-sign/models/event_callback_request_event.rb lib/dropbox-sign/models/event_callback_request_event_metadata.rb +lib/dropbox-sign/models/fax_line.rb lib/dropbox-sign/models/fax_line_add_user_request.rb lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb diff --git a/sdks/ruby/README.md b/sdks/ruby/README.md index 34e6972f7..f87b7489c 100644 --- a/sdks/ruby/README.md +++ b/sdks/ruby/README.md @@ -209,6 +209,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [Dropbox::Sign::EventCallbackRequest](docs/EventCallbackRequest.md) - [Dropbox::Sign::EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [Dropbox::Sign::EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) + - [Dropbox::Sign::FaxLine](docs/FaxLine.md) - [Dropbox::Sign::FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [Dropbox::Sign::FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [Dropbox::Sign::FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) diff --git a/sdks/ruby/docs/FaxLine.md b/sdks/ruby/docs/FaxLine.md new file mode 100644 index 000000000..ba136383f --- /dev/null +++ b/sdks/ruby/docs/FaxLine.md @@ -0,0 +1,13 @@ +# Dropbox::Sign::FaxLine + + + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `number` | ```String``` | Number | | +| `created_at` | ```String``` | Created at | | +| `updated_at` | ```String``` | Updated at | | +| `accounts` | [```Array```](AccountResponse.md) | | | + diff --git a/sdks/ruby/docs/FaxLineApi.md b/sdks/ruby/docs/FaxLineApi.md index d76f28245..b291bd43b 100644 --- a/sdks/ruby/docs/FaxLineApi.md +++ b/sdks/ruby/docs/FaxLineApi.md @@ -105,7 +105,7 @@ end fax_line_api = Dropbox::Sign::FaxLineApi.new begin - result = fax_line_api.fax_line_area_code_get(Dropbox::Sign::FaxLineAreaCodeGetCountryEnum::US, Dropbox::Sign::FaxLineAreaCodeGetStateEnum::CA) + result = fax_line_api.fax_line_area_code_get("US", "CA") p result rescue Dropbox::Sign::ApiError => e puts "Exception when calling Dropbox Sign API: #{e}" @@ -135,9 +135,9 @@ end | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `country` | [**FaxLineAreaCodeGetCountryEnum**](.md) | Filter area codes by country. | | -| `state` | [**FaxLineAreaCodeGetStateEnum**](.md) | Filter area codes by state. | [optional] | -| `province` | [**FaxLineAreaCodeGetProvinceEnum**](.md) | Filter area codes by province. | [optional] | +| `country` | **String** | Filter area codes by country. | | +| `state` | **String** | Filter area codes by state. | [optional] | +| `province` | **String** | Filter area codes by province. | [optional] | | `city` | **String** | Filter area codes by city. | [optional] | ### Return type diff --git a/sdks/ruby/docs/FaxLineCreateRequest.md b/sdks/ruby/docs/FaxLineCreateRequest.md index 35a09609e..740f3c437 100644 --- a/sdks/ruby/docs/FaxLineCreateRequest.md +++ b/sdks/ruby/docs/FaxLineCreateRequest.md @@ -7,7 +7,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `area_code`*_required_ | ```String``` | Area code | | -| `country`*_required_ | [```FaxLineAreaCodeGetCountryEnum```](FaxLineAreaCodeGetCountryEnum.md) | | | +| `country`*_required_ | ```String``` | Country | | | `city` | ```String``` | City | | | `account_id` | ```String``` | Account ID | | diff --git a/sdks/ruby/docs/FaxLineListResponse.md b/sdks/ruby/docs/FaxLineListResponse.md index 66926434b..79c2c564d 100644 --- a/sdks/ruby/docs/FaxLineListResponse.md +++ b/sdks/ruby/docs/FaxLineListResponse.md @@ -7,6 +7,6 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `list_info` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `fax_lines` | [```Array```](FaxLineResponse.md) | | | +| `fax_lines` | [```Array```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/ruby/docs/FaxLineResponse.md b/sdks/ruby/docs/FaxLineResponse.md index 4e0a70149..85423b6e2 100644 --- a/sdks/ruby/docs/FaxLineResponse.md +++ b/sdks/ruby/docs/FaxLineResponse.md @@ -6,6 +6,6 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `fax_line` | [```FaxLineResponse```](FaxLineResponse.md) | | | +| `fax_line` | [```FaxLine```](FaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/ruby/lib/dropbox-sign.rb b/sdks/ruby/lib/dropbox-sign.rb index 9514e0cf3..54ae095fa 100644 --- a/sdks/ruby/lib/dropbox-sign.rb +++ b/sdks/ruby/lib/dropbox-sign.rb @@ -51,6 +51,7 @@ require 'dropbox-sign/models/event_callback_request' require 'dropbox-sign/models/event_callback_request_event' require 'dropbox-sign/models/event_callback_request_event_metadata' +require 'dropbox-sign/models/fax_line' require 'dropbox-sign/models/fax_line_add_user_request' require 'dropbox-sign/models/fax_line_area_code_get_country_enum' require 'dropbox-sign/models/fax_line_area_code_get_province_enum' diff --git a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb index 8d1863eab..b97ef61b9 100644 --- a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb +++ b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb @@ -133,10 +133,10 @@ def fax_line_add_user_with_http_info(fax_line_add_user_request, opts = {}) # Get Available Fax Line Area Codes # Returns a response with the area codes available for a given state/provice and city. - # @param country [FaxLineAreaCodeGetCountryEnum] Filter area codes by country. + # @param country [String] Filter area codes by country. # @param [Hash] opts the optional parameters - # @option opts [FaxLineAreaCodeGetStateEnum] :state Filter area codes by state. - # @option opts [FaxLineAreaCodeGetProvinceEnum] :province Filter area codes by province. + # @option opts [String] :state Filter area codes by state. + # @option opts [String] :province Filter area codes by province. # @option opts [String] :city Filter area codes by city. # @return [FaxLineAreaCodeGetResponse] def fax_line_area_code_get(country, opts = {}) @@ -146,10 +146,10 @@ def fax_line_area_code_get(country, opts = {}) # Get Available Fax Line Area Codes # Returns a response with the area codes available for a given state/provice and city. - # @param country [FaxLineAreaCodeGetCountryEnum] Filter area codes by country. + # @param country [String] Filter area codes by country. # @param [Hash] opts the optional parameters - # @option opts [FaxLineAreaCodeGetStateEnum] :state Filter area codes by state. - # @option opts [FaxLineAreaCodeGetProvinceEnum] :province Filter area codes by province. + # @option opts [String] :state Filter area codes by state. + # @option opts [String] :province Filter area codes by province. # @option opts [String] :city Filter area codes by city. # @return [Array<(FaxLineAreaCodeGetResponse, Integer, Hash)>] FaxLineAreaCodeGetResponse data, response status code and response headers def fax_line_area_code_get_with_http_info(country, opts = {}) @@ -160,6 +160,19 @@ def fax_line_area_code_get_with_http_info(country, opts = {}) if @api_client.config.client_side_validation && country.nil? fail ArgumentError, "Missing the required parameter 'country' when calling FaxLineApi.fax_line_area_code_get" end + # verify enum value + allowable_values = ["CA", "US", "UK"] + if @api_client.config.client_side_validation && !allowable_values.include?(country) + fail ArgumentError, "invalid value for \"country\", must be one of #{allowable_values}" + end + allowable_values = ["AK", "AL", "AR", "AZ", "CA", "CO", "CT", "DC", "DE", "FL", "GA", "HI", "IA", "ID", "IL", "IN", "KS", "KY", "LA", "MA", "MD", "ME", "MI", "MN", "MO", "MS", "MT", "NC", "ND", "NE", "NH", "NJ", "NM", "NV", "NY", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VA", "VT", "WA", "WI", "WV", "WY"] + if @api_client.config.client_side_validation && opts[:'state'] && !allowable_values.include?(opts[:'state']) + fail ArgumentError, "invalid value for \"state\", must be one of #{allowable_values}" + end + allowable_values = ["AB", "BC", "MB", "NB", "NL", "NT", "NS", "NU", "ON", "PE", "QC", "SK", "YT"] + if @api_client.config.client_side_validation && opts[:'province'] && !allowable_values.include?(opts[:'province']) + fail ArgumentError, "invalid value for \"province\", must be one of #{allowable_values}" + end # resource path local_var_path = '/fax_line/area_codes' diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line.rb new file mode 100644 index 000000000..f6d2babcf --- /dev/null +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line.rb @@ -0,0 +1,285 @@ +=begin +#Dropbox Sign API + +#Dropbox Sign v3 API + +The version of the OpenAPI document: 3.0.0 +Contact: apisupport@hellosign.com +Generated by: https://openapi-generator.tech +OpenAPI Generator version: 5.3.0 + +=end + +require 'date' +require 'time' + +module Dropbox +end + +module Dropbox::Sign + class FaxLine + # Number + # @return [String] + attr_accessor :number + + # Created at + # @return [String] + attr_accessor :created_at + + # Updated at + # @return [String] + attr_accessor :updated_at + + # @return [Array] + attr_accessor :accounts + + # Attribute mapping from ruby-style variable name to JSON key. + def self.attribute_map + { + :'number' => :'number', + :'created_at' => :'created_at', + :'updated_at' => :'updated_at', + :'accounts' => :'accounts' + } + end + + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + + # Returns attribute map of this model + parent + def self.merged_attributes + self.attribute_map + end + + # Attribute type mapping. + def self.openapi_types + { + :'number' => :'String', + :'created_at' => :'String', + :'updated_at' => :'String', + :'accounts' => :'Array' + } + end + + # Attribute type mapping of this model + parent + def self.merged_types + self.openapi_types + end + + # List of attributes with nullable: true + def self.openapi_nullable + Set.new([ + ]) + end + + # Returns list of attributes with nullable: true of this model + parent + def self.merged_nullable + self.openapi_nullable + end + + # Attempt to instantiate and hydrate a new instance of this class + # @param [Object] data Data to be converted + # @return [FaxLine] + def self.init(data) + return ApiClient.default.convert_to_type( + data, + "FaxLine" + ) || FaxLine.new + end + + # Initializes the object + # @param [Hash] attributes Model attributes in the form of hash + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLine` initialize method" + end + + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.merged_attributes.key?(k.to_sym)) + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLine`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + end + h[k.to_sym] = v + } + + if attributes.key?(:'number') + self.number = attributes[:'number'] + end + + if attributes.key?(:'created_at') + self.created_at = attributes[:'created_at'] + end + + if attributes.key?(:'updated_at') + self.updated_at = attributes[:'updated_at'] + end + + if attributes.key?(:'accounts') + if (value = attributes[:'accounts']).is_a?(Array) + self.accounts = value + end + 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? + 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 && + number == o.number && + created_at == o.created_at && + updated_at == o.updated_at && + accounts == o.accounts + end + + # @see the `==` method + # @param [Object] Object to be compared + def eql?(o) + self == o + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + def hash + [number, created_at, updated_at, accounts].hash + end + + # Builds the object from hash + # @param [Hash] attributes Model attributes in the form of hash + # @return [Object] Returns the model itself + def self.build_from_hash(attributes) + new.build_from_hash(attributes) + 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) + attribute_map = self.class.merged_attributes + + self.class.merged_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[attribute_map[key]].is_a?(Array) + self.send("#{key}=", attributes[attribute_map[key]].map { |v| _deserialize($1, v) }) + end + elsif !attributes[attribute_map[key]].nil? + self.send("#{key}=", _deserialize(type, attributes[attribute_map[key]])) + end + 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 :Time + Time.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 :File + value + 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 + # models (e.g. Pet) + klass = Dropbox::Sign.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.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(include_nil = true) + hash = {} + self.class.merged_attributes.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + next unless include_nil + is_nullable = self.class.merged_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value, include_nil) + 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, include_nil = true) + if value.is_a?(Array) + value.compact.map { |v| _to_hash(v, include_nil) } + elsif value.is_a?(Hash) + {}.tap do |hash| + value.each { |k, v| hash[k] = _to_hash(v, include_nil) } + end + elsif value.respond_to? :to_hash + value.to_hash(include_nil) + else + value + end + end + + end + +end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb index 33f4c7f55..28622494a 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb @@ -22,7 +22,8 @@ class FaxLineCreateRequest # @return [String] attr_accessor :area_code - # @return [FaxLineAreaCodeGetCountryEnum] + # Country + # @return [String] attr_accessor :country # City @@ -33,6 +34,28 @@ class FaxLineCreateRequest # @return [String] attr_accessor :account_id + 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 { @@ -57,7 +80,7 @@ def self.merged_attributes def self.openapi_types { :'area_code' => :'String', - :'country' => :'FaxLineAreaCodeGetCountryEnum', + :'country' => :'String', :'city' => :'String', :'account_id' => :'String' } @@ -141,9 +164,21 @@ def list_invalid_properties def valid? return false if @area_code.nil? return false if @country.nil? + country_validator = EnumAttributeValidator.new('String', ["CA", "US", "UK"]) + return false unless country_validator.valid?(@country) true end + # Custom attribute writer method checking allowed values (enum). + # @param [Object] country Object to be assigned + def country=(country) + validator = EnumAttributeValidator.new('String', ["CA", "US", "UK"]) + unless validator.valid?(country) + fail ArgumentError, "invalid value for \"country\", must be one of #{validator.allowable_values}." + end + @country = country + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb index 6e0d5bed5..cefe1b60f 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb @@ -21,7 +21,7 @@ class FaxLineListResponse # @return [ListInfoResponse] attr_accessor :list_info - # @return [Array] + # @return [Array] attr_accessor :fax_lines # @return [WarningResponse] @@ -50,7 +50,7 @@ def self.merged_attributes def self.openapi_types { :'list_info' => :'ListInfoResponse', - :'fax_lines' => :'Array', + :'fax_lines' => :'Array', :'warnings' => :'WarningResponse' } end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb index 797a01cd2..bec82400a 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb @@ -18,7 +18,7 @@ module Dropbox module Dropbox::Sign class FaxLineResponse - # @return [FaxLineResponse] + # @return [FaxLine] attr_accessor :fax_line # @return [WarningResponse] @@ -45,7 +45,7 @@ def self.merged_attributes # Attribute type mapping. def self.openapi_types { - :'fax_line' => :'FaxLineResponse', + :'fax_line' => :'FaxLine', :'warnings' => :'WarningResponse' } end From 16e20cb5bd8c77ec54dd2afac4cebe9f6c7ec137 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Thu, 22 Aug 2024 12:49:46 -0400 Subject: [PATCH 08/12] minor bug fixes --- openapi-raw.yaml | 107 +++++++++--------- openapi-sdk.yaml | 107 +++++++++--------- openapi.yaml | 107 +++++++++--------- sdks/dotnet/README.md | 4 +- sdks/dotnet/docs/FaxLineApi.md | 4 +- .../dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs | 12 +- sdks/java-v1/README.md | 4 +- sdks/java-v1/docs/FaxLineApi.md | 4 +- .../java/com/dropbox/sign/api/FaxLineApi.java | 6 +- sdks/java-v2/README.md | 4 +- sdks/java-v2/docs/FaxLineApi.md | 4 +- .../java/com/dropbox/sign/api/FaxLineApi.java | 6 +- sdks/node/README.md | 4 +- sdks/node/api/faxLineApi.ts | 16 +-- sdks/node/dist/api.js | 13 ++- sdks/node/docs/api/FaxLineApi.md | 4 +- sdks/php/README.md | 4 +- sdks/php/docs/Api/FaxLineApi.md | 4 +- sdks/php/src/Api/FaxLineApi.php | 18 +-- sdks/python/README.md | 4 +- sdks/python/docs/FaxLineApi.md | 4 +- sdks/python/dropbox_sign/api/fax_line_api.py | 6 +- sdks/ruby/README.md | 4 +- sdks/ruby/docs/FaxLineApi.md | 4 +- .../ruby/lib/dropbox-sign/api/fax_line_api.rb | 5 +- 25 files changed, 232 insertions(+), 227 deletions(-) diff --git a/openapi-raw.yaml b/openapi-raw.yaml index 71c03f169..c774e6259 100644 --- a/openapi-raw.yaml +++ b/openapi-raw.yaml @@ -1788,22 +1788,21 @@ paths: seo: title: '_t__FaxLineCreate::SEO::TITLE' description: '_t__FaxLineCreate::SEO::DESCRIPTION' - /fax_line/delete: - delete: + /fax_line: + get: tags: - 'Fax Line' - summary: '_t__FaxLineDelete::SUMMARY' - description: '_t__FaxLineDelete::DESCRIPTION' - operationId: faxLineDelete - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/FaxLineDeleteRequest' - examples: - default_example: - $ref: '#/components/examples/FaxLineDeleteRequestExample' + summary: '_t__FaxLineGet::SUMMARY' + description: '_t__FaxLineGet::DESCRIPTION' + operationId: faxLineGet + parameters: + - + name: number + in: query + description: '_t__FaxLineGet::NUMBER' + required: true + schema: + type: string responses: '200': description: 'successful operation' @@ -1815,7 +1814,12 @@ paths: X-Ratelimit-Reset: $ref: '#/components/headers/X-Ratelimit-Reset' content: - application/json: { } + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' 4XX: description: failed_operation content: @@ -1843,61 +1847,61 @@ paths: lang: PHP label: PHP source: - $ref: examples/FaxLineDelete.php + $ref: examples/FaxLineGet.php - lang: 'C#' label: 'C#' source: - $ref: examples/FaxLineDelete.cs + $ref: examples/FaxLineGet.cs - lang: JavaScript label: JavaScript source: - $ref: examples/FaxLineDelete.js + $ref: examples/FaxLineGet.js - lang: TypeScript label: TypeScript source: - $ref: examples/FaxLineDelete.ts + $ref: examples/FaxLineGet.ts - lang: Java label: Java source: - $ref: examples/FaxLineDelete.java + $ref: examples/FaxLineGet.java - lang: Ruby label: Ruby source: - $ref: examples/FaxLineDelete.rb + $ref: examples/FaxLineGet.rb - lang: Python label: Python source: - $ref: examples/FaxLineDelete.py + $ref: examples/FaxLineGet.py - lang: cURL label: cURL source: - $ref: examples/FaxLineDelete.sh + $ref: examples/FaxLineGet.sh x-meta: seo: - title: '_t__FaxLineDelete::SEO::TITLE' - description: '_t__FaxLineDelete::SEO::DESCRIPTION' - '/fax_line/{number}': - get: + title: '_t__FaxLineGet::SEO::TITLE' + description: '_t__FaxLineGet::SEO::DESCRIPTION' + delete: tags: - 'Fax Line' - summary: '_t__FaxLineGet::SUMMARY' - description: '_t__FaxLineGet::DESCRIPTION' - operationId: faxLineGet - parameters: - - - name: number - in: path - description: '_t__FaxLineGet::NUMBER' - required: true - schema: - type: string + summary: '_t__FaxLineDelete::SUMMARY' + description: '_t__FaxLineDelete::DESCRIPTION' + operationId: faxLineDelete + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineDeleteRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineDeleteRequestExample' responses: '200': description: 'successful operation' @@ -1909,12 +1913,7 @@ paths: X-Ratelimit-Reset: $ref: '#/components/headers/X-Ratelimit-Reset' content: - application/json: - schema: - $ref: '#/components/schemas/FaxLineResponse' - examples: - default_example: - $ref: '#/components/examples/FaxLineResponseExample' + application/json: { } 4XX: description: failed_operation content: @@ -1942,46 +1941,46 @@ paths: lang: PHP label: PHP source: - $ref: examples/FaxLineGet.php + $ref: examples/FaxLineDelete.php - lang: 'C#' label: 'C#' source: - $ref: examples/FaxLineGet.cs + $ref: examples/FaxLineDelete.cs - lang: JavaScript label: JavaScript source: - $ref: examples/FaxLineGet.js + $ref: examples/FaxLineDelete.js - lang: TypeScript label: TypeScript source: - $ref: examples/FaxLineGet.ts + $ref: examples/FaxLineDelete.ts - lang: Java label: Java source: - $ref: examples/FaxLineGet.java + $ref: examples/FaxLineDelete.java - lang: Ruby label: Ruby source: - $ref: examples/FaxLineGet.rb + $ref: examples/FaxLineDelete.rb - lang: Python label: Python source: - $ref: examples/FaxLineGet.py + $ref: examples/FaxLineDelete.py - lang: cURL label: cURL source: - $ref: examples/FaxLineGet.sh + $ref: examples/FaxLineDelete.sh x-meta: seo: - title: '_t__FaxLineGet::SEO::TITLE' - description: '_t__FaxLineGet::SEO::DESCRIPTION' + title: '_t__FaxLineDelete::SEO::TITLE' + description: '_t__FaxLineDelete::SEO::DESCRIPTION' /fax_line/list: get: tags: diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index d1175f106..4bdb59d70 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -1794,22 +1794,21 @@ paths: seo: title: 'Purchase Fax Line | API Documentation | Dropbox Fax for Developers' description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here.' - /fax_line/delete: - delete: + /fax_line: + get: tags: - 'Fax Line' - summary: 'Delete Fax Line' - description: 'Deletes the specified Fax Line from the subscription.' - operationId: faxLineDelete - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/FaxLineDeleteRequest' - examples: - default_example: - $ref: '#/components/examples/FaxLineDeleteRequestExample' + summary: 'Get Fax Line' + description: 'Returns the properties and settings of a Fax Line.' + operationId: faxLineGet + parameters: + - + name: number + in: query + description: 'The Fax Line number.' + required: true + schema: + type: string responses: 200: description: 'successful operation' @@ -1821,7 +1820,12 @@ paths: X-Ratelimit-Reset: $ref: '#/components/headers/X-Ratelimit-Reset' content: - application/json: {} + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' 4XX: description: failed_operation content: @@ -1849,61 +1853,61 @@ paths: lang: PHP label: PHP source: - $ref: examples/FaxLineDelete.php + $ref: examples/FaxLineGet.php - lang: 'C#' label: 'C#' source: - $ref: examples/FaxLineDelete.cs + $ref: examples/FaxLineGet.cs - lang: JavaScript label: JavaScript source: - $ref: examples/FaxLineDelete.js + $ref: examples/FaxLineGet.js - lang: TypeScript label: TypeScript source: - $ref: examples/FaxLineDelete.ts + $ref: examples/FaxLineGet.ts - lang: Java label: Java source: - $ref: examples/FaxLineDelete.java + $ref: examples/FaxLineGet.java - lang: Ruby label: Ruby source: - $ref: examples/FaxLineDelete.rb + $ref: examples/FaxLineGet.rb - lang: Python label: Python source: - $ref: examples/FaxLineDelete.py + $ref: examples/FaxLineGet.py - lang: cURL label: cURL source: - $ref: examples/FaxLineDelete.sh + $ref: examples/FaxLineGet.sh x-meta: seo: - title: 'Delete Fax Line | API Documentation | Dropbox Fax for Developers' - description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here.' - '/fax_line/{number}': - get: + title: 'Get Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here.' + delete: tags: - 'Fax Line' - summary: 'Get Fax Line' - description: 'Returns the properties and settings of a Fax Line.' - operationId: faxLineGet - parameters: - - - name: number - in: path - description: 'The Fax Line number.' - required: true - schema: - type: string + summary: 'Delete Fax Line' + description: 'Deletes the specified Fax Line from the subscription.' + operationId: faxLineDelete + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineDeleteRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineDeleteRequestExample' responses: 200: description: 'successful operation' @@ -1915,12 +1919,7 @@ paths: X-Ratelimit-Reset: $ref: '#/components/headers/X-Ratelimit-Reset' content: - application/json: - schema: - $ref: '#/components/schemas/FaxLineResponse' - examples: - default_example: - $ref: '#/components/examples/FaxLineResponseExample' + application/json: {} 4XX: description: failed_operation content: @@ -1948,46 +1947,46 @@ paths: lang: PHP label: PHP source: - $ref: examples/FaxLineGet.php + $ref: examples/FaxLineDelete.php - lang: 'C#' label: 'C#' source: - $ref: examples/FaxLineGet.cs + $ref: examples/FaxLineDelete.cs - lang: JavaScript label: JavaScript source: - $ref: examples/FaxLineGet.js + $ref: examples/FaxLineDelete.js - lang: TypeScript label: TypeScript source: - $ref: examples/FaxLineGet.ts + $ref: examples/FaxLineDelete.ts - lang: Java label: Java source: - $ref: examples/FaxLineGet.java + $ref: examples/FaxLineDelete.java - lang: Ruby label: Ruby source: - $ref: examples/FaxLineGet.rb + $ref: examples/FaxLineDelete.rb - lang: Python label: Python source: - $ref: examples/FaxLineGet.py + $ref: examples/FaxLineDelete.py - lang: cURL label: cURL source: - $ref: examples/FaxLineGet.sh + $ref: examples/FaxLineDelete.sh x-meta: seo: - title: 'Get Fax Line | API Documentation | Dropbox Fax for Developers' - description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here.' + title: 'Delete Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here.' /fax_line/list: get: tags: diff --git a/openapi.yaml b/openapi.yaml index 9fd92b9b7..8c4ee5b43 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1794,22 +1794,21 @@ paths: seo: title: 'Purchase Fax Line | API Documentation | Dropbox Fax for Developers' description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to purchase a new fax line, click here.' - /fax_line/delete: - delete: + /fax_line: + get: tags: - 'Fax Line' - summary: 'Delete Fax Line' - description: 'Deletes the specified Fax Line from the subscription.' - operationId: faxLineDelete - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/FaxLineDeleteRequest' - examples: - default_example: - $ref: '#/components/examples/FaxLineDeleteRequestExample' + summary: 'Get Fax Line' + description: 'Returns the properties and settings of a Fax Line.' + operationId: faxLineGet + parameters: + - + name: number + in: query + description: 'The Fax Line number.' + required: true + schema: + type: string responses: 200: description: 'successful operation' @@ -1821,7 +1820,12 @@ paths: X-Ratelimit-Reset: $ref: '#/components/headers/X-Ratelimit-Reset' content: - application/json: {} + application/json: + schema: + $ref: '#/components/schemas/FaxLineResponse' + examples: + default_example: + $ref: '#/components/examples/FaxLineResponseExample' 4XX: description: failed_operation content: @@ -1849,61 +1853,61 @@ paths: lang: PHP label: PHP source: - $ref: examples/FaxLineDelete.php + $ref: examples/FaxLineGet.php - lang: 'C#' label: 'C#' source: - $ref: examples/FaxLineDelete.cs + $ref: examples/FaxLineGet.cs - lang: JavaScript label: JavaScript source: - $ref: examples/FaxLineDelete.js + $ref: examples/FaxLineGet.js - lang: TypeScript label: TypeScript source: - $ref: examples/FaxLineDelete.ts + $ref: examples/FaxLineGet.ts - lang: Java label: Java source: - $ref: examples/FaxLineDelete.java + $ref: examples/FaxLineGet.java - lang: Ruby label: Ruby source: - $ref: examples/FaxLineDelete.rb + $ref: examples/FaxLineGet.rb - lang: Python label: Python source: - $ref: examples/FaxLineDelete.py + $ref: examples/FaxLineGet.py - lang: cURL label: cURL source: - $ref: examples/FaxLineDelete.sh + $ref: examples/FaxLineGet.sh x-meta: seo: - title: 'Delete Fax Line | API Documentation | Dropbox Fax for Developers' - description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here.' - '/fax_line/{number}': - get: + title: 'Get Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here.' + delete: tags: - 'Fax Line' - summary: 'Get Fax Line' - description: 'Returns the properties and settings of a Fax Line.' - operationId: faxLineGet - parameters: - - - name: number - in: path - description: 'The Fax Line number.' - required: true - schema: - type: string + summary: 'Delete Fax Line' + description: 'Deletes the specified Fax Line from the subscription.' + operationId: faxLineDelete + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/FaxLineDeleteRequest' + examples: + default_example: + $ref: '#/components/examples/FaxLineDeleteRequestExample' responses: 200: description: 'successful operation' @@ -1915,12 +1919,7 @@ paths: X-Ratelimit-Reset: $ref: '#/components/headers/X-Ratelimit-Reset' content: - application/json: - schema: - $ref: '#/components/schemas/FaxLineResponse' - examples: - default_example: - $ref: '#/components/examples/FaxLineResponseExample' + application/json: {} 4XX: description: failed_operation content: @@ -1948,46 +1947,46 @@ paths: lang: PHP label: PHP source: - $ref: examples/FaxLineGet.php + $ref: examples/FaxLineDelete.php - lang: 'C#' label: 'C#' source: - $ref: examples/FaxLineGet.cs + $ref: examples/FaxLineDelete.cs - lang: JavaScript label: JavaScript source: - $ref: examples/FaxLineGet.js + $ref: examples/FaxLineDelete.js - lang: TypeScript label: TypeScript source: - $ref: examples/FaxLineGet.ts + $ref: examples/FaxLineDelete.ts - lang: Java label: Java source: - $ref: examples/FaxLineGet.java + $ref: examples/FaxLineDelete.java - lang: Ruby label: Ruby source: - $ref: examples/FaxLineGet.rb + $ref: examples/FaxLineDelete.rb - lang: Python label: Python source: - $ref: examples/FaxLineGet.py + $ref: examples/FaxLineDelete.py - lang: cURL label: cURL source: - $ref: examples/FaxLineGet.sh + $ref: examples/FaxLineDelete.sh x-meta: seo: - title: 'Get Fax Line | API Documentation | Dropbox Fax for Developers' - description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to retrieve a fax line, click here.' + title: 'Delete Fax Line | API Documentation | Dropbox Fax for Developers' + description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to delete a fax line, click here.' /fax_line/list: get: tags: diff --git a/sdks/dotnet/README.md b/sdks/dotnet/README.md index 45490c5fc..00a1be063 100644 --- a/sdks/dotnet/README.md +++ b/sdks/dotnet/README.md @@ -140,8 +140,8 @@ Class | Method | HTTP request | Description *FaxLineApi* | [**FaxLineAddUser**](docs/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User *FaxLineApi* | [**FaxLineAreaCodeGet**](docs/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes *FaxLineApi* | [**FaxLineCreate**](docs/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line -*FaxLineApi* | [**FaxLineDelete**](docs/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line -*FaxLineApi* | [**FaxLineGet**](docs/FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line +*FaxLineApi* | [**FaxLineDelete**](docs/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line +*FaxLineApi* | [**FaxLineGet**](docs/FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line *FaxLineApi* | [**FaxLineList**](docs/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines *FaxLineApi* | [**FaxLineRemoveUser**](docs/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**OauthTokenGenerate**](docs/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate diff --git a/sdks/dotnet/docs/FaxLineApi.md b/sdks/dotnet/docs/FaxLineApi.md index 7a3a4aa3a..4a3572242 100644 --- a/sdks/dotnet/docs/FaxLineApi.md +++ b/sdks/dotnet/docs/FaxLineApi.md @@ -7,8 +7,8 @@ All URIs are relative to *https://api.hellosign.com/v3* | [**FaxLineAddUser**](FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | | [**FaxLineAreaCodeGet**](FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | [**FaxLineCreate**](FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | -| [**FaxLineDelete**](FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line | -| [**FaxLineGet**](FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line | +| [**FaxLineDelete**](FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line | +| [**FaxLineGet**](FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line | | [**FaxLineList**](FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | | [**FaxLineRemoveUser**](FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | diff --git a/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs index 1b1ac8a0b..67058aadd 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs @@ -1116,7 +1116,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineDeleteWithHttpInfo(FaxLine } // make the HTTP request - var localVarResponse = this.Client.Delete("/fax_line/delete", localVarRequestOptions, this.Configuration); + var localVarResponse = this.Client.Delete("/fax_line", localVarRequestOptions, this.Configuration); if (this.ExceptionFactory != null) { Exception _exception = this.ExceptionFactory("FaxLineDelete", localVarResponse); @@ -1201,7 +1201,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineDeleteWithHttpInfo(FaxLine } // make the HTTP request - var localVarResponse = await this.AsynchronousClient.DeleteAsync("/fax_line/delete", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + var localVarResponse = await this.AsynchronousClient.DeleteAsync("/fax_line", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); if (this.ExceptionFactory != null) { @@ -1265,7 +1265,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.PathParameters.Add("number", Dropbox.Sign.Client.ClientUtils.ParameterToString(number)); // path parameter + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "number", number)); localVarRequestOptions.Operation = "FaxLineApi.FaxLineGet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1277,7 +1277,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s } // make the HTTP request - var localVarResponse = this.Client.Get("/fax_line/{number}", localVarRequestOptions, this.Configuration); + var localVarResponse = this.Client.Get("/fax_line", localVarRequestOptions, this.Configuration); if (this.ExceptionFactory != null) { Exception _exception = this.ExceptionFactory("FaxLineGet", localVarResponse); @@ -1344,7 +1344,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.PathParameters.Add("number", Dropbox.Sign.Client.ClientUtils.ParameterToString(number)); // path parameter + localVarRequestOptions.QueryParameters.Add(Dropbox.Sign.Client.ClientUtils.ParameterToMultiMap("", "number", number)); localVarRequestOptions.Operation = "FaxLineApi.FaxLineGet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1356,7 +1356,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s } // make the HTTP request - var localVarResponse = await this.AsynchronousClient.GetAsync("/fax_line/{number}", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + var localVarResponse = await this.AsynchronousClient.GetAsync("/fax_line", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); if (this.ExceptionFactory != null) { diff --git a/sdks/java-v1/README.md b/sdks/java-v1/README.md index 76930afee..8eb2ddd96 100644 --- a/sdks/java-v1/README.md +++ b/sdks/java-v1/README.md @@ -181,8 +181,8 @@ Class | Method | HTTP request | Description *FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User *FaxLineApi* | [**faxLineAreaCodeGet**](docs/FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes *FaxLineApi* | [**faxLineCreate**](docs/FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line -*FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line -*FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +*FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line +*FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line *FaxLineApi* | [**faxLineList**](docs/FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines *FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**oauthTokenGenerate**](docs/OAuthApi.md#oauthTokenGenerate) | **POST** /oauth/token | OAuth Token Generate diff --git a/sdks/java-v1/docs/FaxLineApi.md b/sdks/java-v1/docs/FaxLineApi.md index 914ade392..f5e63be6e 100644 --- a/sdks/java-v1/docs/FaxLineApi.md +++ b/sdks/java-v1/docs/FaxLineApi.md @@ -7,8 +7,8 @@ Method | HTTP request | Description [**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User [**faxLineAreaCodeGet**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes [**faxLineCreate**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line -[**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line -[**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +[**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line +[**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line [**faxLineList**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines [**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java index 68181e632..fc2b08f6e 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -388,7 +388,7 @@ public ApiResponse faxLineDeleteWithHttpInfo(FaxLineDeleteRequest faxLineD } // create path and map variables - String localVarPath = "/fax_line/delete"; + String localVarPath = "/fax_line"; // query params List localVarQueryParams = new ArrayList(); @@ -461,8 +461,7 @@ public ApiResponse faxLineGetWithHttpInfo(String number) throws } // create path and map variables - String localVarPath = "/fax_line/{number}" - .replaceAll("\\{" + "number" + "\\}", apiClient.escapeString(number.toString())); + String localVarPath = "/fax_line"; // query params List localVarQueryParams = new ArrayList(); @@ -470,6 +469,7 @@ public ApiResponse faxLineGetWithHttpInfo(String number) throws Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "number", number)); diff --git a/sdks/java-v2/README.md b/sdks/java-v2/README.md index 159e18eda..1b3812463 100644 --- a/sdks/java-v2/README.md +++ b/sdks/java-v2/README.md @@ -182,8 +182,8 @@ Class | Method | HTTP request | Description *FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User *FaxLineApi* | [**faxLineAreaCodeGet**](docs/FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes *FaxLineApi* | [**faxLineCreate**](docs/FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line -*FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line -*FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +*FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line +*FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line *FaxLineApi* | [**faxLineList**](docs/FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines *FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**oauthTokenGenerate**](docs/OAuthApi.md#oauthTokenGenerate) | **POST** /oauth/token | OAuth Token Generate diff --git a/sdks/java-v2/docs/FaxLineApi.md b/sdks/java-v2/docs/FaxLineApi.md index 914ade392..f5e63be6e 100644 --- a/sdks/java-v2/docs/FaxLineApi.md +++ b/sdks/java-v2/docs/FaxLineApi.md @@ -7,8 +7,8 @@ Method | HTTP request | Description [**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User [**faxLineAreaCodeGet**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes [**faxLineCreate**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line -[**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line -[**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line +[**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line +[**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line [**faxLineList**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines [**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java index 76bb887d1..4fcc3be43 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -389,7 +389,7 @@ public ApiResponse faxLineDeleteWithHttpInfo(FaxLineDeleteRequest faxLineD } // create path and map variables - String localVarPath = "/fax_line/delete"; + String localVarPath = "/fax_line"; // query params List localVarQueryParams = new ArrayList(); @@ -462,8 +462,7 @@ public ApiResponse faxLineGetWithHttpInfo(String number) throws } // create path and map variables - String localVarPath = "/fax_line/{number}" - .replaceAll("\\{" + "number" + "\\}", apiClient.escapeString(number.toString())); + String localVarPath = "/fax_line"; // query params List localVarQueryParams = new ArrayList(); @@ -471,6 +470,7 @@ public ApiResponse faxLineGetWithHttpInfo(String number) throws Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + localVarQueryParams.addAll(apiClient.parameterToPairs("", "number", number)); diff --git a/sdks/node/README.md b/sdks/node/README.md index 0f661d54f..57dfd427e 100644 --- a/sdks/node/README.md +++ b/sdks/node/README.md @@ -123,8 +123,8 @@ All URIs are relative to *https://api.hellosign.com/v3* | *FaxLineApi* | [**faxLineAddUser**](./docs/api/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | | *FaxLineApi* | [**faxLineAreaCodeGet**](./docs/api/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | *FaxLineApi* | [**faxLineCreate**](./docs/api/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | -| *FaxLineApi* | [**faxLineDelete**](./docs/api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line | -| *FaxLineApi* | [**faxLineGet**](./docs/api/FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line | +| *FaxLineApi* | [**faxLineDelete**](./docs/api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line | +| *FaxLineApi* | [**faxLineGet**](./docs/api/FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line | | *FaxLineApi* | [**faxLineList**](./docs/api/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | | *FaxLineApi* | [**faxLineRemoveUser**](./docs/api/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | | *OAuthApi* | [**oauthTokenGenerate**](./docs/api/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate | diff --git a/sdks/node/api/faxLineApi.ts b/sdks/node/api/faxLineApi.ts index d19cfbb10..afaac4e3e 100644 --- a/sdks/node/api/faxLineApi.ts +++ b/sdks/node/api/faxLineApi.ts @@ -693,7 +693,7 @@ export class FaxLineApi { ); } - const localVarPath = this.basePath + "/fax_line/delete"; + const localVarPath = this.basePath + "/fax_line"; let localVarQueryParameters: any = {}; let localVarHeaderParams: any = (Object).assign( {}, @@ -829,12 +829,7 @@ export class FaxLineApi { number: string, options: optionsI = { headers: {} } ): Promise> { - const localVarPath = - this.basePath + - "/fax_line/{number}".replace( - "{" + "number" + "}", - encodeURIComponent(String(number)) - ); + const localVarPath = this.basePath + "/fax_line"; let localVarQueryParameters: any = {}; let localVarHeaderParams: any = (Object).assign( {}, @@ -857,6 +852,13 @@ export class FaxLineApi { ); } + if (number !== undefined) { + localVarQueryParameters["number"] = ObjectSerializer.serialize( + number, + "string" + ); + } + (Object).assign(localVarHeaderParams, options.headers); let localVarUseFormData = false; diff --git a/sdks/node/dist/api.js b/sdks/node/dist/api.js index 3222ff320..2206bd9c5 100644 --- a/sdks/node/dist/api.js +++ b/sdks/node/dist/api.js @@ -26719,7 +26719,7 @@ var FaxLineApi = class { "FaxLineDeleteRequest" ); } - const localVarPath = this.basePath + "/fax_line/delete"; + const localVarPath = this.basePath + "/fax_line"; let localVarQueryParameters = {}; let localVarHeaderParams = Object.assign( {}, @@ -26819,10 +26819,7 @@ var FaxLineApi = class { } faxLineGet(_0) { return __async(this, arguments, function* (number, options = { headers: {} }) { - const localVarPath = this.basePath + "/fax_line/{number}".replace( - "{number}", - encodeURIComponent(String(number)) - ); + const localVarPath = this.basePath + "/fax_line"; let localVarQueryParameters = {}; let localVarHeaderParams = Object.assign( {}, @@ -26841,6 +26838,12 @@ var FaxLineApi = class { "Required parameter number was null or undefined when calling faxLineGet." ); } + if (number !== void 0) { + localVarQueryParameters["number"] = ObjectSerializer.serialize( + number, + "string" + ); + } Object.assign(localVarHeaderParams, options.headers); let localVarUseFormData = false; let localVarRequestOptions = { diff --git a/sdks/node/docs/api/FaxLineApi.md b/sdks/node/docs/api/FaxLineApi.md index 88cf53b31..2e9cd33bb 100644 --- a/sdks/node/docs/api/FaxLineApi.md +++ b/sdks/node/docs/api/FaxLineApi.md @@ -7,8 +7,8 @@ All URIs are relative to https://api.hellosign.com/v3. | [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User | | [**faxLineAreaCodeGet()**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | [**faxLineCreate()**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line | -| [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line | -| [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line | +| [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line | +| [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line | | [**faxLineList()**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines | | [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access | diff --git a/sdks/php/README.md b/sdks/php/README.md index 025b02cca..906197b6b 100644 --- a/sdks/php/README.md +++ b/sdks/php/README.md @@ -163,8 +163,8 @@ All URIs are relative to *https://api.hellosign.com/v3* | *FaxLineApi* | [**faxLineAddUser**](docs/Api/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | | *FaxLineApi* | [**faxLineAreaCodeGet**](docs/Api/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | *FaxLineApi* | [**faxLineCreate**](docs/Api/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | -| *FaxLineApi* | [**faxLineDelete**](docs/Api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line/delete | Delete Fax Line | -| *FaxLineApi* | [**faxLineGet**](docs/Api/FaxLineApi.md#faxlineget) | **GET** /fax_line/{number} | Get Fax Line | +| *FaxLineApi* | [**faxLineDelete**](docs/Api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line | +| *FaxLineApi* | [**faxLineGet**](docs/Api/FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line | | *FaxLineApi* | [**faxLineList**](docs/Api/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | | *FaxLineApi* | [**faxLineRemoveUser**](docs/Api/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | | *OAuthApi* | [**oauthTokenGenerate**](docs/Api/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate | diff --git a/sdks/php/docs/Api/FaxLineApi.md b/sdks/php/docs/Api/FaxLineApi.md index 1130a2d2b..b6c4e85e5 100644 --- a/sdks/php/docs/Api/FaxLineApi.md +++ b/sdks/php/docs/Api/FaxLineApi.md @@ -7,8 +7,8 @@ All URIs are relative to https://api.hellosign.com/v3. | [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User | | [**faxLineAreaCodeGet()**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | [**faxLineCreate()**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line | -| [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line/delete | Delete Fax Line | -| [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line/{number} | Get Fax Line | +| [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line | +| [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line | | [**faxLineList()**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines | | [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access | diff --git a/sdks/php/src/Api/FaxLineApi.php b/sdks/php/src/Api/FaxLineApi.php index d2be6d60f..f94e189a5 100644 --- a/sdks/php/src/Api/FaxLineApi.php +++ b/sdks/php/src/Api/FaxLineApi.php @@ -1275,7 +1275,7 @@ public function faxLineDeleteRequest(Model\FaxLineDeleteRequest $fax_line_delete ); } - $resourcePath = '/fax_line/delete'; + $resourcePath = '/fax_line'; $queryParams = []; $headerParams = []; $httpBody = ''; @@ -1589,7 +1589,7 @@ public function faxLineGetRequest(string $number) ); } - $resourcePath = '/fax_line/{number}'; + $resourcePath = '/fax_line'; $queryParams = []; $headerParams = []; $httpBody = ''; @@ -1597,13 +1597,15 @@ public function faxLineGetRequest(string $number) $formParams = []; $multipart = false; - // path params + // query params if ($number !== null) { - $resourcePath = str_replace( - '{' . 'number' . '}', - ObjectSerializer::toPathValue($number), - $resourcePath - ); + if ('form' === 'form' && is_array($number)) { + foreach ($number as $key => $value) { + $queryParams[$key] = $value; + } + } else { + $queryParams['number'] = $number; + } } if ($multipart) { diff --git a/sdks/python/README.md b/sdks/python/README.md index 318d051eb..ebdc211ac 100644 --- a/sdks/python/README.md +++ b/sdks/python/README.md @@ -121,8 +121,8 @@ All URIs are relative to *https://api.hellosign.com/v3* |```FaxLineApi``` | [```fax_line_add_user```](docs/FaxLineApi.md#fax_line_add_user) | ```POST /fax_line/add_user``` | Add Fax Line User| ```FaxLineApi``` | [```fax_line_area_code_get```](docs/FaxLineApi.md#fax_line_area_code_get) | ```GET /fax_line/area_codes``` | Get Available Fax Line Area Codes| ```FaxLineApi``` | [```fax_line_create```](docs/FaxLineApi.md#fax_line_create) | ```POST /fax_line/create``` | Purchase Fax Line| -```FaxLineApi``` | [```fax_line_delete```](docs/FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line/delete``` | Delete Fax Line| -```FaxLineApi``` | [```fax_line_get```](docs/FaxLineApi.md#fax_line_get) | ```GET /fax_line/{number}``` | Get Fax Line| +```FaxLineApi``` | [```fax_line_delete```](docs/FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line``` | Delete Fax Line| +```FaxLineApi``` | [```fax_line_get```](docs/FaxLineApi.md#fax_line_get) | ```GET /fax_line``` | Get Fax Line| ```FaxLineApi``` | [```fax_line_list```](docs/FaxLineApi.md#fax_line_list) | ```GET /fax_line/list``` | List Fax Lines| ```FaxLineApi``` | [```fax_line_remove_user```](docs/FaxLineApi.md#fax_line_remove_user) | ```POST /fax_line/remove_user``` | Remove Fax Line Access| |```OAuthApi``` | [```oauth_token_generate```](docs/OAuthApi.md#oauth_token_generate) | ```POST /oauth/token``` | OAuth Token Generate| diff --git a/sdks/python/docs/FaxLineApi.md b/sdks/python/docs/FaxLineApi.md index e0dda44a4..5481a04e3 100644 --- a/sdks/python/docs/FaxLineApi.md +++ b/sdks/python/docs/FaxLineApi.md @@ -7,8 +7,8 @@ All URIs are relative to *https://api.hellosign.com/v3* |[```fax_line_add_user```](FaxLineApi.md#fax_line_add_user) | ```POST /fax_line/add_user``` | Add Fax Line User| |[```fax_line_area_code_get```](FaxLineApi.md#fax_line_area_code_get) | ```GET /fax_line/area_codes``` | Get Available Fax Line Area Codes| |[```fax_line_create```](FaxLineApi.md#fax_line_create) | ```POST /fax_line/create``` | Purchase Fax Line| -|[```fax_line_delete```](FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line/delete``` | Delete Fax Line| -|[```fax_line_get```](FaxLineApi.md#fax_line_get) | ```GET /fax_line/{number}``` | Get Fax Line| +|[```fax_line_delete```](FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line``` | Delete Fax Line| +|[```fax_line_get```](FaxLineApi.md#fax_line_get) | ```GET /fax_line``` | Get Fax Line| |[```fax_line_list```](FaxLineApi.md#fax_line_list) | ```GET /fax_line/list``` | List Fax Lines| |[```fax_line_remove_user```](FaxLineApi.md#fax_line_remove_user) | ```POST /fax_line/remove_user``` | Remove Fax Line Access| diff --git a/sdks/python/dropbox_sign/api/fax_line_api.py b/sdks/python/dropbox_sign/api/fax_line_api.py index 26750bb50..b53ca7111 100644 --- a/sdks/python/dropbox_sign/api/fax_line_api.py +++ b/sdks/python/dropbox_sign/api/fax_line_api.py @@ -299,7 +299,7 @@ def __init__(self, api_client=None): 'auth': [ 'api_key' ], - 'endpoint_path': '/fax_line/delete', + 'endpoint_path': '/fax_line', 'operation_id': 'fax_line_delete', 'http_method': 'DELETE', 'servers': None, @@ -351,7 +351,7 @@ def __init__(self, api_client=None): 'auth': [ 'api_key' ], - 'endpoint_path': '/fax_line/{number}', + 'endpoint_path': '/fax_line', 'operation_id': 'fax_line_get', 'http_method': 'GET', 'servers': None, @@ -383,7 +383,7 @@ def __init__(self, api_client=None): 'number': 'number', }, 'location_map': { - 'number': 'path', + 'number': 'query', }, 'collection_format_map': { } diff --git a/sdks/ruby/README.md b/sdks/ruby/README.md index f87b7489c..68700fd52 100644 --- a/sdks/ruby/README.md +++ b/sdks/ruby/README.md @@ -123,8 +123,8 @@ All URIs are relative to *https://api.hellosign.com/v3* |*Dropbox::Sign::FaxLineApi* | [**fax_line_add_user**](docs/FaxLineApi.md#fax_line_add_user) | **POST** /fax_line/add_user | Add Fax Line User | |*Dropbox::Sign::FaxLineApi* | [**fax_line_area_code_get**](docs/FaxLineApi.md#fax_line_area_code_get) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | |*Dropbox::Sign::FaxLineApi* | [**fax_line_create**](docs/FaxLineApi.md#fax_line_create) | **POST** /fax_line/create | Purchase Fax Line | -|*Dropbox::Sign::FaxLineApi* | [**fax_line_delete**](docs/FaxLineApi.md#fax_line_delete) | **DELETE** /fax_line/delete | Delete Fax Line | -|*Dropbox::Sign::FaxLineApi* | [**fax_line_get**](docs/FaxLineApi.md#fax_line_get) | **GET** /fax_line/{number} | Get Fax Line | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_delete**](docs/FaxLineApi.md#fax_line_delete) | **DELETE** /fax_line | Delete Fax Line | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_get**](docs/FaxLineApi.md#fax_line_get) | **GET** /fax_line | Get Fax Line | |*Dropbox::Sign::FaxLineApi* | [**fax_line_list**](docs/FaxLineApi.md#fax_line_list) | **GET** /fax_line/list | List Fax Lines | |*Dropbox::Sign::FaxLineApi* | [**fax_line_remove_user**](docs/FaxLineApi.md#fax_line_remove_user) | **POST** /fax_line/remove_user | Remove Fax Line Access | |*Dropbox::Sign::OAuthApi* | [**oauth_token_generate**](docs/OAuthApi.md#oauth_token_generate) | **POST** /oauth/token | OAuth Token Generate | diff --git a/sdks/ruby/docs/FaxLineApi.md b/sdks/ruby/docs/FaxLineApi.md index b291bd43b..d9807f6b7 100644 --- a/sdks/ruby/docs/FaxLineApi.md +++ b/sdks/ruby/docs/FaxLineApi.md @@ -7,8 +7,8 @@ All URIs are relative to *https://api.hellosign.com/v3* | [`fax_line_add_user`](FaxLineApi.md#fax_line_add_user) | **POST** `/fax_line/add_user` | Add Fax Line User | | [`fax_line_area_code_get`](FaxLineApi.md#fax_line_area_code_get) | **GET** `/fax_line/area_codes` | Get Available Fax Line Area Codes | | [`fax_line_create`](FaxLineApi.md#fax_line_create) | **POST** `/fax_line/create` | Purchase Fax Line | -| [`fax_line_delete`](FaxLineApi.md#fax_line_delete) | **DELETE** `/fax_line/delete` | Delete Fax Line | -| [`fax_line_get`](FaxLineApi.md#fax_line_get) | **GET** `/fax_line/{number}` | Get Fax Line | +| [`fax_line_delete`](FaxLineApi.md#fax_line_delete) | **DELETE** `/fax_line` | Delete Fax Line | +| [`fax_line_get`](FaxLineApi.md#fax_line_get) | **GET** `/fax_line` | Get Fax Line | | [`fax_line_list`](FaxLineApi.md#fax_line_list) | **GET** `/fax_line/list` | List Fax Lines | | [`fax_line_remove_user`](FaxLineApi.md#fax_line_remove_user) | **POST** `/fax_line/remove_user` | Remove Fax Line Access | diff --git a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb index b97ef61b9..0e8a0d205 100644 --- a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb +++ b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb @@ -381,7 +381,7 @@ def fax_line_delete_with_http_info(fax_line_delete_request, opts = {}) fail ArgumentError, "Missing the required parameter 'fax_line_delete_request' when calling FaxLineApi.fax_line_delete" end # resource path - local_var_path = '/fax_line/delete' + local_var_path = '/fax_line' # query parameters query_params = opts[:query_params] || {} @@ -463,10 +463,11 @@ def fax_line_get_with_http_info(number, opts = {}) fail ArgumentError, "Missing the required parameter 'number' when calling FaxLineApi.fax_line_get" end # resource path - local_var_path = '/fax_line/{number}'.sub('{' + 'number' + '}', CGI.escape(number.to_s)) + local_var_path = '/fax_line' # query parameters query_params = opts[:query_params] || {} + query_params[:'number'] = number # header parameters header_params = opts[:header_params] || {} From 3d9e9b48c55df928a64860ca5c4a7e858dd491d3 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Thu, 22 Aug 2024 15:53:19 -0400 Subject: [PATCH 09/12] update translations --- translations/en.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/translations/en.yaml b/translations/en.yaml index 10d6c251c..4efcf7935 100644 --- a/translations/en.yaml +++ b/translations/en.yaml @@ -163,9 +163,9 @@ "FaxLineResponseExample::SUMMARY": Sample Fax Line Response "FaxLineAreaCodeGetResponseExample::SUMMARY": Sample Area Code Response "FaxLineListResponseExample::SUMMARY": Sample Fax Line List Response -"FaxLine::NUMBER": Number -"FaxLine::CREATED_AT": Created at -"FaxLine::UPDATED_AT": Updated at +"FaxLineResponseFaxLine::NUMBER": Number +"FaxLineResponseFaxLine::CREATED_AT": Created at +"FaxLineResponseFaxLine::UPDATED_AT": Updated at "OAuthTokenGenerate::SUMMARY": OAuth Token Generate "OAuthTokenGenerate::DESCRIPTION": Once you have retrieved the code from the user callback, you will need to exchange it for an access token via a backend call. From 2ad3d1d38c791b02e69c82cd67d30f46d44c917d Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Thu, 22 Aug 2024 16:02:47 -0400 Subject: [PATCH 10/12] Update translations --- translations/en.yaml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/translations/en.yaml b/translations/en.yaml index 4efcf7935..d77ac6bdb 100644 --- a/translations/en.yaml +++ b/translations/en.yaml @@ -131,6 +131,9 @@ "FaxLineAddUser::SUMMARY": Add Fax Line User "FaxLineAddUser::DESCRIPTION": Grants a user access to the specified Fax Line. +"FaxLineAddUser::NUMBER": The Fax Line number. +"FaxLineAddUser::ACCOUNT_ID": Account ID +"FaxLineAddUser::EMAIL_ADDRESS": Email address "FaxLineAreaCodeGet::SUMMARY": Get Available Fax Line Area Codes "FaxLineAreaCodeGet::DESCRIPTION": Returns a response with the area codes available for a given state/provice and city. "FaxLineAreaCodeGet::CITY": Filter area codes by city. @@ -152,9 +155,9 @@ "FaxLineList::SHOW_TEAM_LINES": Show team lines "FaxLineRemoveUser::SUMMARY": Remove Fax Line Access "FaxLineRemoveUser::DESCRIPTION": Removes a user's access to the specified Fax Line. -"FaxLineAddUser::NUMBER": The Fax Line number. -"FaxLineAddUser::ACCOUNT_ID": Account ID -"FaxLineCreate::EMAIL_ADDRESS": Email address +"FaxLineRemoveUser::NUMBER": The Fax Line number. +"FaxLineRemoveUser::ACCOUNT_ID": Account ID +"FaxLineRemoveUser::EMAIL_ADDRESS": Email address "FaxLineCreate::AREA_CODE": Area code "FaxLineCreate::CITY": City "FaxLineCreate::COUNTRY": Country From 44689f172a482f879b401e987b8598c10cd9776b Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Fri, 23 Aug 2024 11:17:25 -0400 Subject: [PATCH 11/12] pr revisions and regenerate sdks --- examples/FaxLineCreate.cs | 2 +- examples/FaxLineCreate.java | 2 +- examples/FaxLineCreate.js | 2 +- examples/FaxLineCreate.php | 2 +- examples/FaxLineCreate.py | 2 +- examples/FaxLineCreate.rb | 2 +- examples/FaxLineCreate.ts | 2 +- examples/FaxLineDelete.cs | 3 +- examples/FaxLineDelete.js | 5 +- examples/FaxLineDelete.php | 3 +- examples/FaxLineDelete.py | 3 +- examples/FaxLineDelete.rb | 3 +- examples/FaxLineDelete.ts | 5 +- .../FaxLineAreaCodeGetResponseExample.json | 60 ++-- .../json/FaxLineCreateRequestExample.json | 2 +- markdown/en/tags/fax-lines-tag-description.md | 1 + openapi-raw.yaml | 45 ++- openapi-sdk.yaml | 28 +- openapi.yaml | 32 +- sdks/dotnet/README.md | 6 +- sdks/dotnet/docs/FaxLineApi.md | 13 +- .../dotnet/docs/FaxLineAreaCodeGetResponse.md | 2 +- sdks/dotnet/docs/FaxLineCreateRequest.md | 2 +- sdks/dotnet/docs/FaxLineListResponse.md | 2 +- sdks/dotnet/docs/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- .../dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs | 40 +-- .../Model/FaxLineAreaCodeGetResponse.cs | 6 +- .../Model/FaxLineCreateRequest.cs | 19 +- .../Dropbox.Sign/Model/FaxLineListResponse.cs | 6 +- .../src/Dropbox.Sign/Model/FaxLineResponse.cs | 6 +- .../Model/FaxLineResponseFaxLine.cs | 233 +++++++++++++ sdks/java-v1/README.md | 6 +- sdks/java-v1/docs/FaxLineApi.md | 10 +- .../docs/FaxLineAreaCodeGetResponse.md | 2 +- sdks/java-v1/docs/FaxLineCreateRequest.md | 2 +- sdks/java-v1/docs/FaxLineListResponse.md | 2 +- sdks/java-v1/docs/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- .../java/com/dropbox/sign/api/FaxLineApi.java | 38 +- .../model/FaxLineAreaCodeGetResponse.java | 10 +- .../sign/model/FaxLineCreateRequest.java | 8 +- .../sign/model/FaxLineListResponse.java | 12 +- .../dropbox/sign/model/FaxLineResponse.java | 10 +- ...xLine.java => FaxLineResponseFaxLine.java} | 58 ++-- sdks/java-v2/README.md | 6 +- sdks/java-v2/docs/FaxLineApi.md | 10 +- .../docs/FaxLineAreaCodeGetResponse.md | 2 +- sdks/java-v2/docs/FaxLineCreateRequest.md | 2 +- sdks/java-v2/docs/FaxLineListResponse.md | 2 +- sdks/java-v2/docs/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- .../java/com/dropbox/sign/api/FaxLineApi.java | 38 +- .../model/FaxLineAreaCodeGetResponse.java | 10 +- .../sign/model/FaxLineCreateRequest.java | 8 +- .../sign/model/FaxLineListResponse.java | 12 +- .../dropbox/sign/model/FaxLineResponse.java | 10 +- ...xLine.java => FaxLineResponseFaxLine.java} | 58 ++-- sdks/node/README.md | 6 +- sdks/node/api/faxLineApi.ts | 4 +- sdks/node/dist/api.js | 86 ++--- sdks/node/docs/api/FaxLineApi.md | 22 +- .../docs/model/FaxLineAreaCodeGetResponse.md | 2 +- sdks/node/docs/model/FaxLineCreateRequest.md | 2 +- sdks/node/docs/model/FaxLineListResponse.md | 2 +- sdks/node/docs/model/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- sdks/node/model/faxLineAreaCodeGetResponse.ts | 4 +- sdks/node/model/faxLineCreateRequest.ts | 4 +- sdks/node/model/faxLineListResponse.ts | 6 +- sdks/node/model/faxLineResponse.ts | 6 +- .../{faxLine.ts => faxLineResponseFaxLine.ts} | 16 +- sdks/node/model/index.ts | 6 +- .../model/faxLineAreaCodeGetResponse.d.ts | 2 +- .../types/model/faxLineCreateRequest.d.ts | 2 +- .../node/types/model/faxLineListResponse.d.ts | 4 +- sdks/node/types/model/faxLineResponse.d.ts | 4 +- ...xLine.d.ts => faxLineResponseFaxLine.d.ts} | 8 +- sdks/node/types/model/index.d.ts | 4 +- sdks/php/README.md | 6 +- sdks/php/docs/Api/FaxLineApi.md | 13 +- .../docs/Model/FaxLineAreaCodeGetResponse.md | 2 +- sdks/php/docs/Model/FaxLineCreateRequest.md | 2 +- sdks/php/docs/Model/FaxLineListResponse.md | 2 +- sdks/php/docs/Model/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- sdks/php/src/Api/FaxLineApi.php | 34 +- .../src/Model/FaxLineAreaCodeGetResponse.php | 6 +- sdks/php/src/Model/FaxLineCreateRequest.php | 8 +- sdks/php/src/Model/FaxLineListResponse.php | 6 +- sdks/php/src/Model/FaxLineResponse.php | 8 +- ...FaxLine.php => FaxLineResponseFaxLine.php} | 33 +- sdks/python/.openapi-generator/FILES | 4 +- sdks/python/README.md | 6 +- sdks/python/docs/FaxLineApi.md | 13 +- .../python/docs/FaxLineAreaCodeGetResponse.md | 2 +- sdks/python/docs/FaxLineCreateRequest.md | 2 +- sdks/python/docs/FaxLineListResponse.md | 2 +- sdks/python/docs/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- sdks/python/dropbox_sign/api/fax_line_api.py | 8 +- .../model/fax_line_area_code_get_response.py | 10 +- .../model/fax_line_create_request.py | 10 +- .../model/fax_line_list_response.py | 16 +- .../dropbox_sign/model/fax_line_response.py | 16 +- .../model/fax_line_response_fax_line.py | 327 ++++++++++++++++++ sdks/python/dropbox_sign/models/__init__.py | 2 +- sdks/ruby/.openapi-generator/FILES | 4 +- sdks/ruby/README.md | 6 +- sdks/ruby/docs/FaxLineApi.md | 13 +- sdks/ruby/docs/FaxLineAreaCodeGetResponse.md | 2 +- sdks/ruby/docs/FaxLineCreateRequest.md | 2 +- sdks/ruby/docs/FaxLineListResponse.md | 2 +- sdks/ruby/docs/FaxLineResponse.md | 2 +- .../{FaxLine.md => FaxLineResponseFaxLine.md} | 6 +- sdks/ruby/lib/dropbox-sign.rb | 2 +- .../ruby/lib/dropbox-sign/api/fax_line_api.rb | 14 +- .../models/fax_line_add_user_request.rb | 6 +- .../fax_line_area_code_get_country_enum.rb | 12 +- .../fax_line_area_code_get_province_enum.rb | 12 +- .../models/fax_line_area_code_get_response.rb | 10 +- .../fax_line_area_code_get_state_enum.rb | 12 +- .../models/fax_line_create_request.rb | 10 +- .../models/fax_line_delete_request.rb | 6 +- .../models/fax_line_list_response.rb | 10 +- .../models/fax_line_remove_user_request.rb | 6 +- .../dropbox-sign/models/fax_line_response.rb | 10 +- ..._line.rb => fax_line_response_fax_line.rb} | 26 +- translations/en.yaml | 1 + 129 files changed, 1187 insertions(+), 618 deletions(-) create mode 100644 markdown/en/tags/fax-lines-tag-description.md rename sdks/dotnet/docs/{FaxLine.md => FaxLineResponseFaxLine.md} (73%) create mode 100644 sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponseFaxLine.cs rename sdks/java-v1/docs/{FaxLine.md => FaxLineResponseFaxLine.md} (65%) rename sdks/java-v1/src/main/java/com/dropbox/sign/model/{FaxLine.java => FaxLineResponseFaxLine.java} (84%) rename sdks/java-v2/docs/{FaxLine.md => FaxLineResponseFaxLine.md} (65%) rename sdks/java-v2/src/main/java/com/dropbox/sign/model/{FaxLine.java => FaxLineResponseFaxLine.java} (84%) rename sdks/node/docs/model/{FaxLine.md => FaxLineResponseFaxLine.md} (74%) rename sdks/node/model/{faxLine.ts => faxLineResponseFaxLine.ts} (86%) rename sdks/node/types/model/{faxLine.d.ts => faxLineResponseFaxLine.d.ts} (66%) rename sdks/php/docs/Model/{FaxLine.md => FaxLineResponseFaxLine.md} (75%) rename sdks/php/src/Model/{FaxLine.php => FaxLineResponseFaxLine.php} (91%) rename sdks/python/docs/{FaxLine.md => FaxLineResponseFaxLine.md} (75%) create mode 100644 sdks/python/dropbox_sign/model/fax_line_response_fax_line.py rename sdks/ruby/docs/{FaxLine.md => FaxLineResponseFaxLine.md} (60%) rename sdks/ruby/lib/dropbox-sign/models/{fax_line.rb => fax_line_response_fax_line.rb} (92%) diff --git a/examples/FaxLineCreate.cs b/examples/FaxLineCreate.cs index 4d919f366..4d96ae5b0 100644 --- a/examples/FaxLineCreate.cs +++ b/examples/FaxLineCreate.cs @@ -15,7 +15,7 @@ public static void Main() var faxLineApi = new FaxLineApi(config); var data = new FaxLineCreateRequest( - areaCode: "209", + areaCode: 209, country: "US" ); diff --git a/examples/FaxLineCreate.java b/examples/FaxLineCreate.java index 769b36a3a..fca101895 100644 --- a/examples/FaxLineCreate.java +++ b/examples/FaxLineCreate.java @@ -14,7 +14,7 @@ public static void main(String[] args) { var faxLineApi = new FaxLineApi(apiClient); var data = new FaxLineCreateRequest() - .areaCode("209") + .areaCode(209) .country("US"); try { diff --git a/examples/FaxLineCreate.js b/examples/FaxLineCreate.js index 4c17f057c..c4ee72c59 100644 --- a/examples/FaxLineCreate.js +++ b/examples/FaxLineCreate.js @@ -6,7 +6,7 @@ const faxLineApi = new DropboxSign.FaxLineApi(); faxLineApi.username = "YOUR_API_KEY"; const data = { - areaCode: "209", + areaCode: 209, country: "US", }; diff --git a/examples/FaxLineCreate.php b/examples/FaxLineCreate.php index ad81ac508..27a0d2b8a 100644 --- a/examples/FaxLineCreate.php +++ b/examples/FaxLineCreate.php @@ -10,7 +10,7 @@ $faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); $data = new Dropbox\Sign\Model\FaxLineCreateRequest(); -$data->setAreaCode("209") +$data->setAreaCode(209) ->setCountry("US"); try { diff --git a/examples/FaxLineCreate.py b/examples/FaxLineCreate.py index 6bdca76ea..14ef9c97c 100644 --- a/examples/FaxLineCreate.py +++ b/examples/FaxLineCreate.py @@ -12,7 +12,7 @@ fax_line_api = apis.FaxLineApi(api_client) data = models.FaxLineCreateRequest( - area_code="209", + area_code=209, country="US", ) diff --git a/examples/FaxLineCreate.rb b/examples/FaxLineCreate.rb index b57ac5570..2619678ae 100644 --- a/examples/FaxLineCreate.rb +++ b/examples/FaxLineCreate.rb @@ -8,7 +8,7 @@ fax_line_api = Dropbox::Sign::FaxLineApi.new data = Dropbox::Sign::FaxLineCreateRequest.new -data.area_code = "209" +data.area_code = 209 data.country = "US" begin diff --git a/examples/FaxLineCreate.ts b/examples/FaxLineCreate.ts index 8671bb70c..6ceeb71da 100644 --- a/examples/FaxLineCreate.ts +++ b/examples/FaxLineCreate.ts @@ -6,7 +6,7 @@ const faxLineApi = new DropboxSign.FaxLineApi(); faxLineApi.username = "YOUR_API_KEY"; const data: DropboxSign.FaxLineCreateRequest = { - areaCode: "209", + areaCode: 209, country: "US", }; diff --git a/examples/FaxLineDelete.cs b/examples/FaxLineDelete.cs index 8eac85115..a2cf8a9f1 100644 --- a/examples/FaxLineDelete.cs +++ b/examples/FaxLineDelete.cs @@ -20,8 +20,7 @@ public static void Main() try { - var result = faxLineApi.FaxLineDelete(data); - Console.WriteLine(result); + faxLineApi.FaxLineDelete(data); } catch (ApiException e) { diff --git a/examples/FaxLineDelete.js b/examples/FaxLineDelete.js index 63c7f0c2d..1e8bdda7c 100644 --- a/examples/FaxLineDelete.js +++ b/examples/FaxLineDelete.js @@ -10,9 +10,8 @@ const data = { }; const result = faxLineApi.faxLineDelete(data); -result.then(response => { - console.log(response.body); -}).catch(error => { + +result.catch(error => { console.log("Exception when calling Dropbox Sign API:"); console.log(error.body); }); diff --git a/examples/FaxLineDelete.php b/examples/FaxLineDelete.php index b60e3d1af..8cc4ee01f 100644 --- a/examples/FaxLineDelete.php +++ b/examples/FaxLineDelete.php @@ -13,8 +13,7 @@ $data->setNumber("[FAX_NUMBER]"); try { - $result = $faxLineApi->faxLineDelete($data); - print_r($result); + $faxLineApi->faxLineDelete($data); } catch (Dropbox\Sign\ApiException $e) { $error = $e->getResponseObject(); echo "Exception when calling Dropbox Sign API: " diff --git a/examples/FaxLineDelete.py b/examples/FaxLineDelete.py index f11e20de3..7b828b01f 100644 --- a/examples/FaxLineDelete.py +++ b/examples/FaxLineDelete.py @@ -16,7 +16,6 @@ ) try: - response = fax_line_api.fax_line_delete(data) - pprint(response) + fax_line_api.fax_line_delete(data) except ApiException as e: print("Exception when calling Dropbox Sign API: %s\n" % e) diff --git a/examples/FaxLineDelete.rb b/examples/FaxLineDelete.rb index 3461a229a..001cf6275 100644 --- a/examples/FaxLineDelete.rb +++ b/examples/FaxLineDelete.rb @@ -11,8 +11,7 @@ data.number = "[FAX_NUMBER]" begin - result = fax_line_api.fax_line_delete(data) - p result + fax_line_api.fax_line_delete(data) rescue Dropbox::Sign::ApiError => e puts "Exception when calling Dropbox Sign API: #{e}" end diff --git a/examples/FaxLineDelete.ts b/examples/FaxLineDelete.ts index dbb035216..14efef4dc 100644 --- a/examples/FaxLineDelete.ts +++ b/examples/FaxLineDelete.ts @@ -10,9 +10,8 @@ const data: DropboxSign.FaxLineDeleteRequest = { }; const result = faxLineApi.faxLineDelete(data); -result.then(response => { - console.log(response.body); -}).catch(error => { + +result.catch(error => { console.log("Exception when calling Dropbox Sign API:"); console.log(error.body); }); diff --git a/examples/json/FaxLineAreaCodeGetResponseExample.json b/examples/json/FaxLineAreaCodeGetResponseExample.json index d31da0dc5..b83e80cc2 100644 --- a/examples/json/FaxLineAreaCodeGetResponseExample.json +++ b/examples/json/FaxLineAreaCodeGetResponseExample.json @@ -1,34 +1,34 @@ { "area_codes": [ - "209", - "213", - "310", - "323", - "408", - "415", - "424", - "510", - "530", - "559", - "562", - "619", - "626", - "650", - "657", - "661", - "669", - "707", - "714", - "747", - "760", - "805", - "818", - "831", - "858", - "909", - "916", - "925", - "949", - "951" + 209, + 213, + 310, + 323, + 408, + 415, + 424, + 510, + 530, + 559, + 562, + 619, + 626, + 650, + 657, + 661, + 669, + 707, + 714, + 747, + 760, + 805, + 818, + 831, + 858, + 909, + 916, + 925, + 949, + 951 ] } diff --git a/examples/json/FaxLineCreateRequestExample.json b/examples/json/FaxLineCreateRequestExample.json index b7496d600..f80f6e421 100644 --- a/examples/json/FaxLineCreateRequestExample.json +++ b/examples/json/FaxLineCreateRequestExample.json @@ -1,4 +1,4 @@ { - "area_code": "209", + "area_code": 209, "country": "US" } diff --git a/markdown/en/tags/fax-lines-tag-description.md b/markdown/en/tags/fax-lines-tag-description.md new file mode 100644 index 000000000..9adc1f687 --- /dev/null +++ b/markdown/en/tags/fax-lines-tag-description.md @@ -0,0 +1 @@ +Contains information about the fax lines you and your team have created \ No newline at end of file diff --git a/openapi-raw.yaml b/openapi-raw.yaml index c774e6259..e2493a03e 100644 --- a/openapi-raw.yaml +++ b/openapi-raw.yaml @@ -1404,7 +1404,7 @@ paths: title: '_t__EmbeddedSignUrl::SEO::TITLE' description: '_t__EmbeddedSignUrl::SEO::DESCRIPTION' /fax_line/add_user: - post: + put: tags: - 'Fax Line' summary: '_t__FaxLineAddUser::SUMMARY' @@ -2002,6 +2002,7 @@ paths: description: '_t__FaxLineList::PAGE' schema: type: integer + default: 1 example: 1 - name: page_size @@ -2009,6 +2010,7 @@ paths: description: '_t__FaxLineList::PAGE_SIZE' schema: type: integer + default: 20 example: 20 - name: show_team_lines @@ -2016,6 +2018,7 @@ paths: description: '_t__FaxLineList::SHOW_TEAM_LINES' schema: type: boolean + default: 0 responses: '200': description: 'successful operation' @@ -2099,7 +2102,7 @@ paths: title: '_t__FaxLineList::SEO::TITLE' description: '_t__FaxLineList::SEO::DESCRIPTION' /fax_line/remove_user: - post: + put: tags: - 'Fax Line' summary: '_t__FaxLineRemoveUser::SUMMARY' @@ -7122,7 +7125,7 @@ components: type: string example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 email_address: - description: '_t__FaxLineCreate::EMAIL_ADDRESS' + description: '_t__FaxLineAddUser::EMAIL_ADDRESS' type: string format: email type: object @@ -7209,7 +7212,7 @@ components: properties: area_code: description: '_t__FaxLineCreate::AREA_CODE' - type: string + type: integer country: description: '_t__FaxLineCreate::COUNTRY' type: string @@ -7238,14 +7241,14 @@ components: - number properties: number: - description: '_t__FaxLineDelete::NUMBER' + description: '_t__FaxLineRemoveUser::NUMBER' type: string account_id: - description: '_t__FaxLineCreate::ACCOUNT_ID' + description: '_t__FaxLineRemoveUser::ACCOUNT_ID' type: string example: ab55cd14a97219e36b5ff5fe23f2f9329b0c1e97 email_address: - description: '_t__FaxLineCreate::EMAIL_ADDRESS' + description: '_t__FaxLineRemoveUser::EMAIL_ADDRESS' type: string format: email type: object @@ -9582,19 +9585,19 @@ components: FaxLineResponse: properties: fax_line: - $ref: '#/components/schemas/FaxLine' + $ref: '#/components/schemas/FaxLineResponseFaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object - x-internal: true + x-internal-class: true FaxLineAreaCodeGetResponse: properties: area_codes: type: array items: - type: string + type: integer type: object - x-internal: true + x-internal-class: true FaxLineListResponse: properties: list_info: @@ -9602,11 +9605,11 @@ components: fax_lines: type: array items: - $ref: '#/components/schemas/FaxLine' + $ref: '#/components/schemas/FaxLineResponseFaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object - x-internal: true + x-internal-class: true FileResponse: properties: file_url: @@ -9938,22 +9941,23 @@ components: description: '_t__ErrorResponseError::ERROR_NAME' type: string type: object - FaxLine: + FaxLineResponseFaxLine: properties: number: - description: '_t__FaxLine::NUMBER' + description: '_t__FaxLineResponseFaxLine::NUMBER' type: string created_at: - description: '_t__FaxLine::CREATED_AT' - type: string + description: '_t__FaxLineResponseFaxLine::CREATED_AT' + type: integer updated_at: - description: '_t__FaxLine::UPDATED_AT' - type: string + description: '_t__FaxLineResponseFaxLine::UPDATED_AT' + type: integer accounts: type: array items: $ref: '#/components/schemas/AccountResponse' type: object + x-internal-class: true ListInfoResponse: description: '_t__ListInfoResponse::DESCRIPTION' properties: @@ -12087,6 +12091,9 @@ tags: - name: 'Callbacks and Events' description: '_md__OpenApi::TAG::CALLBACKS_AND_EVENTS::DESCRIPTION' + - + name: 'Fax Line' + description: '_md__OpenApi::TAG::TAG_FAX_LINE::DESCRIPTION' externalDocs: description: 'Legacy API Reference' url: 'https://app.hellosign.com/api/reference' diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index 4bdb59d70..9c6055e17 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -1410,7 +1410,7 @@ paths: title: 'Get Embedded Sign URL | iFrame | Dropbox Sign for Developers' description: 'The Dropbox Sign API allows you to build custom integrations. To find out how to retrieve an embedded iFrame object containing a signature url, click here.' /fax_line/add_user: - post: + put: tags: - 'Fax Line' summary: 'Add Fax Line User' @@ -2008,6 +2008,7 @@ paths: description: Page schema: type: integer + default: 1 example: 1 - name: page_size @@ -2015,6 +2016,7 @@ paths: description: 'Page size' schema: type: integer + default: 20 example: 20 - name: show_team_lines @@ -2022,6 +2024,7 @@ paths: description: 'Show team lines' schema: type: boolean + default: 0 responses: 200: description: 'successful operation' @@ -2105,7 +2108,7 @@ paths: title: 'List Fax Lines | API Documentation | Dropbox Fax for Developers' description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to list your fax lines, click here.' /fax_line/remove_user: - post: + put: tags: - 'Fax Line' summary: 'Remove Fax Line Access' @@ -7303,7 +7306,7 @@ components: properties: area_code: description: 'Area code' - type: string + type: integer country: description: Country type: string @@ -10190,19 +10193,19 @@ components: FaxLineResponse: properties: fax_line: - $ref: '#/components/schemas/FaxLine' + $ref: '#/components/schemas/FaxLineResponseFaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object - x-internal: true + x-internal-class: true FaxLineAreaCodeGetResponse: properties: area_codes: type: array items: - type: string + type: integer type: object - x-internal: true + x-internal-class: true FaxLineListResponse: properties: list_info: @@ -10210,11 +10213,11 @@ components: fax_lines: type: array items: - $ref: '#/components/schemas/FaxLine' + $ref: '#/components/schemas/FaxLineResponseFaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object - x-internal: true + x-internal-class: true FileResponse: properties: file_url: @@ -10546,22 +10549,23 @@ components: description: 'Name of the error.' type: string type: object - FaxLine: + FaxLineResponseFaxLine: properties: number: description: Number type: string created_at: description: 'Created at' - type: string + type: integer updated_at: description: 'Updated at' - type: string + type: integer accounts: type: array items: $ref: '#/components/schemas/AccountResponse' type: object + x-internal-class: true ListInfoResponse: description: 'Contains pagination information about the data returned.' properties: diff --git a/openapi.yaml b/openapi.yaml index 8c4ee5b43..35edae083 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1410,7 +1410,7 @@ paths: title: 'Get Embedded Sign URL | iFrame | Dropbox Sign for Developers' description: 'The Dropbox Sign API allows you to build custom integrations. To find out how to retrieve an embedded iFrame object containing a signature url, click here.' /fax_line/add_user: - post: + put: tags: - 'Fax Line' summary: 'Add Fax Line User' @@ -2008,6 +2008,7 @@ paths: description: Page schema: type: integer + default: 1 example: 1 - name: page_size @@ -2015,6 +2016,7 @@ paths: description: 'Page size' schema: type: integer + default: 20 example: 20 - name: show_team_lines @@ -2022,6 +2024,7 @@ paths: description: 'Show team lines' schema: type: boolean + default: 0 responses: 200: description: 'successful operation' @@ -2105,7 +2108,7 @@ paths: title: 'List Fax Lines | API Documentation | Dropbox Fax for Developers' description: 'The Dropbox Fax API allows you to build custom integrations. To find out how to list your fax lines, click here.' /fax_line/remove_user: - post: + put: tags: - 'Fax Line' summary: 'Remove Fax Line Access' @@ -7303,7 +7306,7 @@ components: properties: area_code: description: 'Area code' - type: string + type: integer country: description: Country type: string @@ -10168,19 +10171,19 @@ components: FaxLineResponse: properties: fax_line: - $ref: '#/components/schemas/FaxLine' + $ref: '#/components/schemas/FaxLineResponseFaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object - x-internal: true + x-internal-class: true FaxLineAreaCodeGetResponse: properties: area_codes: type: array items: - type: string + type: integer type: object - x-internal: true + x-internal-class: true FaxLineListResponse: properties: list_info: @@ -10188,11 +10191,11 @@ components: fax_lines: type: array items: - $ref: '#/components/schemas/FaxLine' + $ref: '#/components/schemas/FaxLineResponseFaxLine' warnings: $ref: '#/components/schemas/WarningResponse' type: object - x-internal: true + x-internal-class: true FileResponse: properties: file_url: @@ -10524,22 +10527,23 @@ components: description: 'Name of the error.' type: string type: object - FaxLine: + FaxLineResponseFaxLine: properties: number: description: Number type: string created_at: description: 'Created at' - type: string + type: integer updated_at: description: 'Updated at' - type: string + type: integer accounts: type: array items: $ref: '#/components/schemas/AccountResponse' type: object + x-internal-class: true ListInfoResponse: description: 'Contains pagination information about the data returned.' properties: @@ -12876,6 +12880,10 @@ tags: name: 'Callbacks and Events' description: $ref: ./markdown/en/tags/callbacks-tag-description.md + - + name: 'Fax Line' + description: + $ref: ./markdown/en/tags/fax-lines-tag-description.md externalDocs: description: 'Legacy API Reference' url: 'https://app.hellosign.com/api/reference' diff --git a/sdks/dotnet/README.md b/sdks/dotnet/README.md index 00a1be063..0146a5bcd 100644 --- a/sdks/dotnet/README.md +++ b/sdks/dotnet/README.md @@ -137,13 +137,13 @@ Class | Method | HTTP request | Description *BulkSendJobApi* | [**BulkSendJobList**](docs/BulkSendJobApi.md#bulksendjoblist) | **GET** /bulk_send_job/list | List Bulk Send Jobs *EmbeddedApi* | [**EmbeddedEditUrl**](docs/EmbeddedApi.md#embeddedediturl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL *EmbeddedApi* | [**EmbeddedSignUrl**](docs/EmbeddedApi.md#embeddedsignurl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL -*FaxLineApi* | [**FaxLineAddUser**](docs/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User +*FaxLineApi* | [**FaxLineAddUser**](docs/FaxLineApi.md#faxlineadduser) | **PUT** /fax_line/add_user | Add Fax Line User *FaxLineApi* | [**FaxLineAreaCodeGet**](docs/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes *FaxLineApi* | [**FaxLineCreate**](docs/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line *FaxLineApi* | [**FaxLineDelete**](docs/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line *FaxLineApi* | [**FaxLineGet**](docs/FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line *FaxLineApi* | [**FaxLineList**](docs/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines -*FaxLineApi* | [**FaxLineRemoveUser**](docs/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access +*FaxLineApi* | [**FaxLineRemoveUser**](docs/FaxLineApi.md#faxlineremoveuser) | **PUT** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**OauthTokenGenerate**](docs/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate *OAuthApi* | [**OauthTokenRefresh**](docs/OAuthApi.md#oauthtokenrefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh *ReportApi* | [**ReportCreate**](docs/ReportApi.md#reportcreate) | **POST** /report/create | Create Report @@ -227,7 +227,6 @@ Class | Method | HTTP request | Description - [Model.EventCallbackRequest](docs/EventCallbackRequest.md) - [Model.EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [Model.EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) - - [Model.FaxLine](docs/FaxLine.md) - [Model.FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [Model.FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [Model.FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) @@ -238,6 +237,7 @@ Class | Method | HTTP request | Description - [Model.FaxLineListResponse](docs/FaxLineListResponse.md) - [Model.FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) - [Model.FaxLineResponse](docs/FaxLineResponse.md) + - [Model.FaxLineResponseFaxLine](docs/FaxLineResponseFaxLine.md) - [Model.FileResponse](docs/FileResponse.md) - [Model.FileResponseDataUri](docs/FileResponseDataUri.md) - [Model.ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/dotnet/docs/FaxLineApi.md b/sdks/dotnet/docs/FaxLineApi.md index 4a3572242..851341354 100644 --- a/sdks/dotnet/docs/FaxLineApi.md +++ b/sdks/dotnet/docs/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to *https://api.hellosign.com/v3* | Method | HTTP request | Description | |--------|--------------|-------------| -| [**FaxLineAddUser**](FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | +| [**FaxLineAddUser**](FaxLineApi.md#faxlineadduser) | **PUT** /fax_line/add_user | Add Fax Line User | | [**FaxLineAreaCodeGet**](FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | [**FaxLineCreate**](FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | | [**FaxLineDelete**](FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line | | [**FaxLineGet**](FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line | | [**FaxLineList**](FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | -| [**FaxLineRemoveUser**](FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | +| [**FaxLineRemoveUser**](FaxLineApi.md#faxlineremoveuser) | **PUT** /fax_line/remove_user | Remove Fax Line Access | # **FaxLineAddUser** @@ -227,7 +227,7 @@ public class Example var faxLineApi = new FaxLineApi(config); var data = new FaxLineCreateRequest( - areaCode: "209", + areaCode: 209, country: "US" ); @@ -327,8 +327,7 @@ public class Example try { - var result = faxLineApi.FaxLineDelete(data); - Console.WriteLine(result); + faxLineApi.FaxLineDelete(data); } catch (ApiException e) { @@ -543,8 +542,8 @@ catch (ApiException e) | Name | Type | Description | Notes | |------|------|-------------|-------| | **accountId** | **string?** | Account ID | [optional] | -| **page** | **int?** | Page | [optional] | -| **pageSize** | **int?** | Page size | [optional] | +| **page** | **int?** | Page | [optional] [default to 1] | +| **pageSize** | **int?** | Page size | [optional] [default to 20] | | **showTeamLines** | **bool?** | Show team lines | [optional] | ### Return type diff --git a/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md b/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md index acd41c460..297d51efd 100644 --- a/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md +++ b/sdks/dotnet/docs/FaxLineAreaCodeGetResponse.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**AreaCodes** | **List<string>** | | [optional] +**AreaCodes** | **List<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/sdks/dotnet/docs/FaxLineCreateRequest.md b/sdks/dotnet/docs/FaxLineCreateRequest.md index b5515e964..7c6b9b165 100644 --- a/sdks/dotnet/docs/FaxLineCreateRequest.md +++ b/sdks/dotnet/docs/FaxLineCreateRequest.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**AreaCode** | **string** | Area code | +**AreaCode** | **int** | Area code | **Country** | **string** | Country | **City** | **string** | City | [optional] **AccountId** | **string** | Account ID | [optional] diff --git a/sdks/dotnet/docs/FaxLineListResponse.md b/sdks/dotnet/docs/FaxLineListResponse.md index bfa7103cf..12550dc0b 100644 --- a/sdks/dotnet/docs/FaxLineListResponse.md +++ b/sdks/dotnet/docs/FaxLineListResponse.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **ListInfo** | [**ListInfoResponse**](ListInfoResponse.md) | | [optional] -**FaxLines** | [**List<FaxLine>**](FaxLine.md) | | [optional] +**FaxLines** | [**List<FaxLineResponseFaxLine>**](FaxLineResponseFaxLine.md) | | [optional] **Warnings** | [**WarningResponse**](WarningResponse.md) | | [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/sdks/dotnet/docs/FaxLineResponse.md b/sdks/dotnet/docs/FaxLineResponse.md index 2fbf2c11d..e19ae76cf 100644 --- a/sdks/dotnet/docs/FaxLineResponse.md +++ b/sdks/dotnet/docs/FaxLineResponse.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**FaxLine** | [**FaxLine**](FaxLine.md) | | [optional] +**FaxLine** | [**FaxLineResponseFaxLine**](FaxLineResponseFaxLine.md) | | [optional] **Warnings** | [**WarningResponse**](WarningResponse.md) | | [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/sdks/dotnet/docs/FaxLine.md b/sdks/dotnet/docs/FaxLineResponseFaxLine.md similarity index 73% rename from sdks/dotnet/docs/FaxLine.md rename to sdks/dotnet/docs/FaxLineResponseFaxLine.md index 203c125fc..66651431d 100644 --- a/sdks/dotnet/docs/FaxLine.md +++ b/sdks/dotnet/docs/FaxLineResponseFaxLine.md @@ -1,12 +1,12 @@ -# Dropbox.Sign.Model.FaxLine +# Dropbox.Sign.Model.FaxLineResponseFaxLine ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Number** | **string** | Number | [optional] -**CreatedAt** | **string** | Created at | [optional] -**UpdatedAt** | **string** | Updated at | [optional] +**CreatedAt** | **int** | Created at | [optional] +**UpdatedAt** | **int** | Updated at | [optional] **Accounts** | [**List<AccountResponse>**](AccountResponse.md) | | [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/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs index 67058aadd..a391c6257 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Api/FaxLineApi.cs @@ -156,8 +156,8 @@ public interface IFaxLineApiSync : IApiAccessor /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// FaxLineListResponse @@ -171,8 +171,8 @@ public interface IFaxLineApiSync : IApiAccessor /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// ApiResponse of FaxLineListResponse @@ -348,8 +348,8 @@ public interface IFaxLineApiAsync : IApiAccessor /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// Cancellation Token to cancel the request. @@ -364,8 +364,8 @@ public interface IFaxLineApiAsync : IApiAccessor /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// Cancellation Token to cancel the request. @@ -586,7 +586,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpIn } // make the HTTP request - var localVarResponse = this.Client.Post("/fax_line/add_user", localVarRequestOptions, this.Configuration); + var localVarResponse = this.Client.Put("/fax_line/add_user", localVarRequestOptions, this.Configuration); if (this.ExceptionFactory != null) { Exception _exception = this.ExceptionFactory("FaxLineAddUser", localVarResponse); @@ -672,7 +672,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineAddUserWithHttpIn } // make the HTTP request - var localVarResponse = await this.AsynchronousClient.PostAsync("/fax_line/add_user", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + var localVarResponse = await this.AsynchronousClient.PutAsync("/fax_line/add_user", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); if (this.ExceptionFactory != null) { @@ -1375,8 +1375,8 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// FaxLineListResponse @@ -1391,8 +1391,8 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// ApiResponse of FaxLineListResponse @@ -1465,8 +1465,8 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// Cancellation Token to cancel the request. @@ -1482,8 +1482,8 @@ public Dropbox.Sign.Client.ApiResponse FaxLineGetWithHttpInfo(s /// /// Thrown when fails to make API call /// Account ID (optional) - /// Page (optional) - /// Page size (optional) + /// Page (optional, default to 1) + /// Page size (optional, default to 20) /// Show team lines (optional) /// Index associated with the operation. /// Cancellation Token to cancel the request. @@ -1625,7 +1625,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineRemoveUserWithHtt } // make the HTTP request - var localVarResponse = this.Client.Post("/fax_line/remove_user", localVarRequestOptions, this.Configuration); + var localVarResponse = this.Client.Put("/fax_line/remove_user", localVarRequestOptions, this.Configuration); if (this.ExceptionFactory != null) { Exception _exception = this.ExceptionFactory("FaxLineRemoveUser", localVarResponse); @@ -1711,7 +1711,7 @@ public Dropbox.Sign.Client.ApiResponse FaxLineRemoveUserWithHtt } // make the HTTP request - var localVarResponse = await this.AsynchronousClient.PostAsync("/fax_line/remove_user", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); + var localVarResponse = await this.AsynchronousClient.PutAsync("/fax_line/remove_user", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false); if (this.ExceptionFactory != null) { diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs index 55942f18a..a00ff7e21 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineAreaCodeGetResponse.cs @@ -42,7 +42,7 @@ protected FaxLineAreaCodeGetResponse() { } /// Initializes a new instance of the class. /// /// areaCodes. - public FaxLineAreaCodeGetResponse(List areaCodes = default(List)) + public FaxLineAreaCodeGetResponse(List areaCodes = default(List)) { this.AreaCodes = areaCodes; @@ -68,7 +68,7 @@ public static FaxLineAreaCodeGetResponse Init(string jsonData) /// Gets or Sets AreaCodes /// [DataMember(Name = "area_codes", EmitDefaultValue = true)] - public List AreaCodes { get; set; } + public List AreaCodes { get; set; } /// /// Returns the string presentation of the object @@ -145,7 +145,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "area_codes", Property = "AreaCodes", - Type = "List", + Type = "List", Value = AreaCodes, }); diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs index 781121388..db1aaf944 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineCreateRequest.cs @@ -79,14 +79,9 @@ protected FaxLineCreateRequest() { } /// Country (required). /// City. /// Account ID. - public FaxLineCreateRequest(string areaCode = default(string), CountryEnum country = default(CountryEnum), string city = default(string), string accountId = default(string)) + public FaxLineCreateRequest(int areaCode = default(int), CountryEnum country = default(CountryEnum), string city = default(string), string accountId = default(string)) { - // to ensure "areaCode" is required (not null) - if (areaCode == null) - { - throw new ArgumentNullException("areaCode is a required property for FaxLineCreateRequest and cannot be null"); - } this.AreaCode = areaCode; this.Country = country; this.City = city; @@ -114,7 +109,7 @@ public static FaxLineCreateRequest Init(string jsonData) /// /// Area code [DataMember(Name = "area_code", IsRequired = true, EmitDefaultValue = true)] - public string AreaCode { get; set; } + public int AreaCode { get; set; } /// /// City @@ -179,8 +174,7 @@ public bool Equals(FaxLineCreateRequest input) return ( this.AreaCode == input.AreaCode || - (this.AreaCode != null && - this.AreaCode.Equals(input.AreaCode)) + this.AreaCode.Equals(input.AreaCode) ) && ( this.Country == input.Country || @@ -207,10 +201,7 @@ public override int GetHashCode() unchecked // Overflow is fine, just wrap { int hashCode = 41; - if (this.AreaCode != null) - { - hashCode = (hashCode * 59) + this.AreaCode.GetHashCode(); - } + hashCode = (hashCode * 59) + this.AreaCode.GetHashCode(); hashCode = (hashCode * 59) + this.Country.GetHashCode(); if (this.City != null) { @@ -230,7 +221,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "area_code", Property = "AreaCode", - Type = "string", + Type = "int", Value = AreaCode, }); types.Add(new OpenApiType(){ diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs index 139ef24a3..d4ea8bab0 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineListResponse.cs @@ -44,7 +44,7 @@ protected FaxLineListResponse() { } /// listInfo. /// faxLines. /// warnings. - public FaxLineListResponse(ListInfoResponse listInfo = default(ListInfoResponse), List faxLines = default(List), WarningResponse warnings = default(WarningResponse)) + public FaxLineListResponse(ListInfoResponse listInfo = default(ListInfoResponse), List faxLines = default(List), WarningResponse warnings = default(WarningResponse)) { this.ListInfo = listInfo; @@ -78,7 +78,7 @@ public static FaxLineListResponse Init(string jsonData) /// Gets or Sets FaxLines /// [DataMember(Name = "fax_lines", EmitDefaultValue = true)] - public List FaxLines { get; set; } + public List FaxLines { get; set; } /// /// Gets or Sets Warnings @@ -187,7 +187,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "fax_lines", Property = "FaxLines", - Type = "List", + Type = "List", Value = FaxLines, }); types.Add(new OpenApiType(){ diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs index 71157cdbe..f40fa3a10 100644 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponse.cs @@ -43,7 +43,7 @@ protected FaxLineResponse() { } /// /// faxLine. /// warnings. - public FaxLineResponse(FaxLine faxLine = default(FaxLine), WarningResponse warnings = default(WarningResponse)) + public FaxLineResponse(FaxLineResponseFaxLine faxLine = default(FaxLineResponseFaxLine), WarningResponse warnings = default(WarningResponse)) { this.FaxLine = faxLine; @@ -70,7 +70,7 @@ public static FaxLineResponse Init(string jsonData) /// Gets or Sets FaxLine /// [DataMember(Name = "fax_line", EmitDefaultValue = true)] - public FaxLine FaxLine { get; set; } + public FaxLineResponseFaxLine FaxLine { get; set; } /// /// Gets or Sets Warnings @@ -162,7 +162,7 @@ public List GetOpenApiTypes() types.Add(new OpenApiType(){ Name = "fax_line", Property = "FaxLine", - Type = "FaxLine", + Type = "FaxLineResponseFaxLine", Value = FaxLine, }); types.Add(new OpenApiType(){ diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponseFaxLine.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponseFaxLine.cs new file mode 100644 index 000000000..e2367660b --- /dev/null +++ b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLineResponseFaxLine.cs @@ -0,0 +1,233 @@ +/* + * Dropbox Sign API + * + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; + +namespace Dropbox.Sign.Model +{ + /// + /// FaxLineResponseFaxLine + /// + [DataContract(Name = "FaxLineResponseFaxLine")] + [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] + public partial class FaxLineResponseFaxLine : IOpenApiTyped, IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FaxLineResponseFaxLine() { } + /// + /// Initializes a new instance of the class. + /// + /// Number. + /// Created at. + /// Updated at. + /// accounts. + public FaxLineResponseFaxLine(string number = default(string), int createdAt = default(int), int updatedAt = default(int), List accounts = default(List)) + { + + this.Number = number; + this.CreatedAt = createdAt; + this.UpdatedAt = updatedAt; + this.Accounts = accounts; + } + + /// + /// Attempt to instantiate and hydrate a new instance of this class + /// + /// String of JSON data representing target object + public static FaxLineResponseFaxLine Init(string jsonData) + { + var obj = JsonConvert.DeserializeObject(jsonData); + + if (obj == null) + { + throw new Exception("Unable to deserialize JSON to instance of FaxLineResponseFaxLine"); + } + + return obj; + } + + /// + /// Number + /// + /// Number + [DataMember(Name = "number", EmitDefaultValue = true)] + public string Number { get; set; } + + /// + /// Created at + /// + /// Created at + [DataMember(Name = "created_at", EmitDefaultValue = true)] + public int CreatedAt { get; set; } + + /// + /// Updated at + /// + /// Updated at + [DataMember(Name = "updated_at", EmitDefaultValue = true)] + public int UpdatedAt { get; set; } + + /// + /// Gets or Sets Accounts + /// + [DataMember(Name = "accounts", EmitDefaultValue = true)] + public List Accounts { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FaxLineResponseFaxLine {\n"); + sb.Append(" Number: ").Append(Number).Append("\n"); + sb.Append(" CreatedAt: ").Append(CreatedAt).Append("\n"); + sb.Append(" UpdatedAt: ").Append(UpdatedAt).Append("\n"); + sb.Append(" Accounts: ").Append(Accounts).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FaxLineResponseFaxLine); + } + + /// + /// Returns true if FaxLineResponseFaxLine instances are equal + /// + /// Instance of FaxLineResponseFaxLine to be compared + /// Boolean + public bool Equals(FaxLineResponseFaxLine input) + { + if (input == null) + { + return false; + } + return + ( + this.Number == input.Number || + (this.Number != null && + this.Number.Equals(input.Number)) + ) && + ( + this.CreatedAt == input.CreatedAt || + this.CreatedAt.Equals(input.CreatedAt) + ) && + ( + this.UpdatedAt == input.UpdatedAt || + this.UpdatedAt.Equals(input.UpdatedAt) + ) && + ( + this.Accounts == input.Accounts || + this.Accounts != null && + input.Accounts != null && + this.Accounts.SequenceEqual(input.Accounts) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Number != null) + { + hashCode = (hashCode * 59) + this.Number.GetHashCode(); + } + hashCode = (hashCode * 59) + this.CreatedAt.GetHashCode(); + hashCode = (hashCode * 59) + this.UpdatedAt.GetHashCode(); + if (this.Accounts != null) + { + hashCode = (hashCode * 59) + this.Accounts.GetHashCode(); + } + return hashCode; + } + } + + public List GetOpenApiTypes() + { + var types = new List(); + types.Add(new OpenApiType(){ + Name = "number", + Property = "Number", + Type = "string", + Value = Number, + }); + types.Add(new OpenApiType(){ + Name = "created_at", + Property = "CreatedAt", + Type = "int", + Value = CreatedAt, + }); + types.Add(new OpenApiType(){ + Name = "updated_at", + Property = "UpdatedAt", + Type = "int", + Value = UpdatedAt, + }); + types.Add(new OpenApiType(){ + Name = "accounts", + Property = "Accounts", + Type = "List", + Value = Accounts, + }); + + return types; + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/sdks/java-v1/README.md b/sdks/java-v1/README.md index 8eb2ddd96..931df72c5 100644 --- a/sdks/java-v1/README.md +++ b/sdks/java-v1/README.md @@ -178,13 +178,13 @@ Class | Method | HTTP request | Description *BulkSendJobApi* | [**bulkSendJobList**](docs/BulkSendJobApi.md#bulkSendJobList) | **GET** /bulk_send_job/list | List Bulk Send Jobs *EmbeddedApi* | [**embeddedEditUrl**](docs/EmbeddedApi.md#embeddedEditUrl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL *EmbeddedApi* | [**embeddedSignUrl**](docs/EmbeddedApi.md#embeddedSignUrl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL -*FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +*FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **PUT** /fax_line/add_user | Add Fax Line User *FaxLineApi* | [**faxLineAreaCodeGet**](docs/FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes *FaxLineApi* | [**faxLineCreate**](docs/FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line *FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line *FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line *FaxLineApi* | [**faxLineList**](docs/FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines -*FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access +*FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **PUT** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**oauthTokenGenerate**](docs/OAuthApi.md#oauthTokenGenerate) | **POST** /oauth/token | OAuth Token Generate *OAuthApi* | [**oauthTokenRefresh**](docs/OAuthApi.md#oauthTokenRefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh *ReportApi* | [**reportCreate**](docs/ReportApi.md#reportCreate) | **POST** /report/create | Create Report @@ -267,7 +267,6 @@ Class | Method | HTTP request | Description - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) - - [FaxLine](docs/FaxLine.md) - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) @@ -278,6 +277,7 @@ Class | Method | HTTP request | Description - [FaxLineListResponse](docs/FaxLineListResponse.md) - [FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) - [FaxLineResponse](docs/FaxLineResponse.md) + - [FaxLineResponseFaxLine](docs/FaxLineResponseFaxLine.md) - [FileResponse](docs/FileResponse.md) - [FileResponseDataUri](docs/FileResponseDataUri.md) - [ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/java-v1/docs/FaxLineApi.md b/sdks/java-v1/docs/FaxLineApi.md index f5e63be6e..7f1202cf5 100644 --- a/sdks/java-v1/docs/FaxLineApi.md +++ b/sdks/java-v1/docs/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to *https://api.hellosign.com/v3* Method | HTTP request | Description ------------- | ------------- | ------------- -[**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +[**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **PUT** /fax_line/add_user | Add Fax Line User [**faxLineAreaCodeGet**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes [**faxLineCreate**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line [**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line [**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line [**faxLineList**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines -[**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access +[**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **PUT** /fax_line/remove_user | Remove Fax Line Access @@ -182,7 +182,7 @@ public class Example { var faxLineApi = new FaxLineApi(apiClient); var data = new FaxLineCreateRequest() - .areaCode("209") + .areaCode(209) .country("US"); try { @@ -408,8 +408,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **accountId** | **String**| Account ID | [optional] - **page** | **Integer**| Page | [optional] - **pageSize** | **Integer**| Page size | [optional] + **page** | **Integer**| Page | [optional] [default to 1] + **pageSize** | **Integer**| Page size | [optional] [default to 20] **showTeamLines** | **Boolean**| Show team lines | [optional] ### Return type diff --git a/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md b/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md index 0b231dcf9..c77456fec 100644 --- a/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md +++ b/sdks/java-v1/docs/FaxLineAreaCodeGetResponse.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `areaCodes` | ```List``` | | | +| `areaCodes` | ```List``` | | | diff --git a/sdks/java-v1/docs/FaxLineCreateRequest.md b/sdks/java-v1/docs/FaxLineCreateRequest.md index e09db630f..d0be5225c 100644 --- a/sdks/java-v1/docs/FaxLineCreateRequest.md +++ b/sdks/java-v1/docs/FaxLineCreateRequest.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `areaCode`*_required_ | ```String``` | Area code | | +| `areaCode`*_required_ | ```Integer``` | Area code | | | `country`*_required_ | [```CountryEnum```](#CountryEnum) | Country | | | `city` | ```String``` | City | | | `accountId` | ```String``` | Account ID | | diff --git a/sdks/java-v1/docs/FaxLineListResponse.md b/sdks/java-v1/docs/FaxLineListResponse.md index 6e01b30a1..4f01f2fd3 100644 --- a/sdks/java-v1/docs/FaxLineListResponse.md +++ b/sdks/java-v1/docs/FaxLineListResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `faxLines` | [```List```](FaxLine.md) | | | +| `faxLines` | [```List```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v1/docs/FaxLineResponse.md b/sdks/java-v1/docs/FaxLineResponse.md index 44a845b3c..d9a67d41f 100644 --- a/sdks/java-v1/docs/FaxLineResponse.md +++ b/sdks/java-v1/docs/FaxLineResponse.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `faxLine` | [```FaxLine```](FaxLine.md) | | | +| `faxLine` | [```FaxLineResponseFaxLine```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v1/docs/FaxLine.md b/sdks/java-v1/docs/FaxLineResponseFaxLine.md similarity index 65% rename from sdks/java-v1/docs/FaxLine.md rename to sdks/java-v1/docs/FaxLineResponseFaxLine.md index 5809f6353..caa5e07e2 100644 --- a/sdks/java-v1/docs/FaxLine.md +++ b/sdks/java-v1/docs/FaxLineResponseFaxLine.md @@ -1,6 +1,6 @@ -# FaxLine +# FaxLineResponseFaxLine @@ -9,8 +9,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `number` | ```String``` | Number | | -| `createdAt` | ```String``` | Created at | | -| `updatedAt` | ```String``` | Updated at | | +| `createdAt` | ```Integer``` | Created at | | +| `updatedAt` | ```Integer``` | Updated at | | | `accounts` | [```List```](AccountResponse.md) | | | diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java index fc2b08f6e..ed7a821cc 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -123,7 +123,7 @@ public ApiResponse faxLineAddUserWithHttpInfo(FaxLineAddUserReq GenericType localVarReturnType = new GenericType() {}; - return apiClient.invokeAPI("FaxLineApi.faxLineAddUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + return apiClient.invokeAPI("FaxLineApi.faxLineAddUser", localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType, false); } @@ -500,8 +500,8 @@ public ApiResponse faxLineGetWithHttpInfo(String number) throws * List Fax Lines * Returns the properties and settings of multiple Fax Lines. * @param accountId Account ID (optional) - * @param page Page (optional) - * @param pageSize Page size (optional) + * @param page Page (optional, default to 1) + * @param pageSize Page size (optional, default to 20) * @param showTeamLines Show team lines (optional) * @return FaxLineListResponse * @throws ApiException if fails to make API call @@ -522,8 +522,8 @@ public FaxLineListResponse faxLineList(String accountId, Integer page, Integer p */ public FaxLineListResponse faxLineList() throws ApiException { String accountId = null; - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); @@ -534,8 +534,8 @@ public FaxLineListResponse faxLineList() throws ApiException { */ public ApiResponse faxLineListWithHttpInfo() throws ApiException { String accountId = null; - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); @@ -545,8 +545,8 @@ public ApiResponse faxLineListWithHttpInfo() throws ApiExce * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) */ public FaxLineListResponse faxLineList(String accountId) throws ApiException { - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); @@ -556,8 +556,8 @@ public FaxLineListResponse faxLineList(String accountId) throws ApiException { * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) */ public ApiResponse faxLineListWithHttpInfo(String accountId) throws ApiException { - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); @@ -567,7 +567,7 @@ public ApiResponse faxLineListWithHttpInfo(String accountId * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) */ public FaxLineListResponse faxLineList(String accountId, Integer page) throws ApiException { - Integer pageSize = null; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); @@ -577,7 +577,7 @@ public FaxLineListResponse faxLineList(String accountId, Integer page) throws Ap * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) */ public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page) throws ApiException { - Integer pageSize = null; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); @@ -606,8 +606,8 @@ public ApiResponse faxLineListWithHttpInfo(String accountId * List Fax Lines * Returns the properties and settings of multiple Fax Lines. * @param accountId Account ID (optional) - * @param page Page (optional) - * @param pageSize Page size (optional) + * @param page Page (optional, default to 1) + * @param pageSize Page size (optional, default to 20) * @param showTeamLines Show team lines (optional) * @return ApiResponse<FaxLineListResponse> * @throws ApiException if fails to make API call @@ -620,6 +620,12 @@ public ApiResponse faxLineListWithHttpInfo(String accountId */ public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page, Integer pageSize, Boolean showTeamLines) throws ApiException { + if (page == null) { + page = 1; + } + if (pageSize == null) { + pageSize = 20; + } Object localVarPostBody = null; // create path and map variables @@ -732,7 +738,7 @@ public ApiResponse faxLineRemoveUserWithHttpInfo(FaxLineRemoveU GenericType localVarReturnType = new GenericType() {}; - return apiClient.invokeAPI("FaxLineApi.faxLineRemoveUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + return apiClient.invokeAPI("FaxLineApi.faxLineRemoveUser", localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType, false); } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java index b218d8f4e..ff2b26a9c 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java @@ -43,7 +43,7 @@ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineAreaCodeGetResponse { public static final String JSON_PROPERTY_AREA_CODES = "area_codes"; - private List areaCodes = null; + private List areaCodes = null; public FaxLineAreaCodeGetResponse() { } @@ -63,12 +63,12 @@ static public FaxLineAreaCodeGetResponse init(HashMap data) throws Exception { ); } - public FaxLineAreaCodeGetResponse areaCodes(List areaCodes) { + public FaxLineAreaCodeGetResponse areaCodes(List areaCodes) { this.areaCodes = areaCodes; return this; } - public FaxLineAreaCodeGetResponse addAreaCodesItem(String areaCodesItem) { + public FaxLineAreaCodeGetResponse addAreaCodesItem(Integer areaCodesItem) { if (this.areaCodes == null) { this.areaCodes = new ArrayList<>(); } @@ -85,14 +85,14 @@ public FaxLineAreaCodeGetResponse addAreaCodesItem(String areaCodesItem) { @JsonProperty(JSON_PROPERTY_AREA_CODES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public List getAreaCodes() { + public List getAreaCodes() { return areaCodes; } @JsonProperty(JSON_PROPERTY_AREA_CODES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setAreaCodes(List areaCodes) { + public void setAreaCodes(List areaCodes) { this.areaCodes = areaCodes; } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java index b7b5dacb3..213857339 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -44,7 +44,7 @@ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineCreateRequest { public static final String JSON_PROPERTY_AREA_CODE = "area_code"; - private String areaCode; + private Integer areaCode; /** * Country @@ -110,7 +110,7 @@ static public FaxLineCreateRequest init(HashMap data) throws Exception { ); } - public FaxLineCreateRequest areaCode(String areaCode) { + public FaxLineCreateRequest areaCode(Integer areaCode) { this.areaCode = areaCode; return this; } @@ -124,14 +124,14 @@ public FaxLineCreateRequest areaCode(String areaCode) { @JsonProperty(JSON_PROPERTY_AREA_CODE) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public String getAreaCode() { + public Integer getAreaCode() { return areaCode; } @JsonProperty(JSON_PROPERTY_AREA_CODE) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public void setAreaCode(String areaCode) { + public void setAreaCode(Integer areaCode) { this.areaCode = areaCode; } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java index 87cf63eab..ede959b57 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java @@ -17,7 +17,7 @@ import java.util.Arrays; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLine; +import com.dropbox.sign.model.FaxLineResponseFaxLine; import com.dropbox.sign.model.ListInfoResponse; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; @@ -51,7 +51,7 @@ public class FaxLineListResponse { private ListInfoResponse listInfo; public static final String JSON_PROPERTY_FAX_LINES = "fax_lines"; - private List faxLines = null; + private List faxLines = null; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -100,12 +100,12 @@ public void setListInfo(ListInfoResponse listInfo) { } - public FaxLineListResponse faxLines(List faxLines) { + public FaxLineListResponse faxLines(List faxLines) { this.faxLines = faxLines; return this; } - public FaxLineListResponse addFaxLinesItem(FaxLine faxLinesItem) { + public FaxLineListResponse addFaxLinesItem(FaxLineResponseFaxLine faxLinesItem) { if (this.faxLines == null) { this.faxLines = new ArrayList<>(); } @@ -122,14 +122,14 @@ public FaxLineListResponse addFaxLinesItem(FaxLine faxLinesItem) { @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public List getFaxLines() { + public List getFaxLines() { return faxLines; } @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLines(List faxLines) { + public void setFaxLines(List faxLines) { this.faxLines = faxLines; } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java index 77cb58fb1..85e720f7c 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponse.java @@ -17,7 +17,7 @@ import java.util.Arrays; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLine; +import com.dropbox.sign.model.FaxLineResponseFaxLine; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -44,7 +44,7 @@ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineResponse { public static final String JSON_PROPERTY_FAX_LINE = "fax_line"; - private FaxLine faxLine; + private FaxLineResponseFaxLine faxLine; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -67,7 +67,7 @@ static public FaxLineResponse init(HashMap data) throws Exception { ); } - public FaxLineResponse faxLine(FaxLine faxLine) { + public FaxLineResponse faxLine(FaxLineResponseFaxLine faxLine) { this.faxLine = faxLine; return this; } @@ -81,14 +81,14 @@ public FaxLineResponse faxLine(FaxLine faxLine) { @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public FaxLine getFaxLine() { + public FaxLineResponseFaxLine getFaxLine() { return faxLine; } @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLine(FaxLine faxLine) { + public void setFaxLine(FaxLineResponseFaxLine faxLine) { this.faxLine = faxLine; } diff --git a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponseFaxLine.java similarity index 84% rename from sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java rename to sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponseFaxLine.java index a29015958..4e1967155 100644 --- a/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLine.java +++ b/sdks/java-v1/src/main/java/com/dropbox/sign/model/FaxLineResponseFaxLine.java @@ -35,48 +35,48 @@ import com.dropbox.sign.ApiException; /** - * FaxLine + * FaxLineResponseFaxLine */ @JsonPropertyOrder({ - FaxLine.JSON_PROPERTY_NUMBER, - FaxLine.JSON_PROPERTY_CREATED_AT, - FaxLine.JSON_PROPERTY_UPDATED_AT, - FaxLine.JSON_PROPERTY_ACCOUNTS + FaxLineResponseFaxLine.JSON_PROPERTY_NUMBER, + FaxLineResponseFaxLine.JSON_PROPERTY_CREATED_AT, + FaxLineResponseFaxLine.JSON_PROPERTY_UPDATED_AT, + FaxLineResponseFaxLine.JSON_PROPERTY_ACCOUNTS }) @JsonIgnoreProperties(ignoreUnknown=true) @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") -public class FaxLine { +public class FaxLineResponseFaxLine { public static final String JSON_PROPERTY_NUMBER = "number"; private String number; public static final String JSON_PROPERTY_CREATED_AT = "created_at"; - private String createdAt; + private Integer createdAt; public static final String JSON_PROPERTY_UPDATED_AT = "updated_at"; - private String updatedAt; + private Integer updatedAt; public static final String JSON_PROPERTY_ACCOUNTS = "accounts"; private List accounts = null; - public FaxLine() { + public FaxLineResponseFaxLine() { } /** * Attempt to instantiate and hydrate a new instance of this class * @param jsonData String of JSON data representing target object */ - static public FaxLine init(String jsonData) throws Exception { - return new ObjectMapper().readValue(jsonData, FaxLine.class); + static public FaxLineResponseFaxLine init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineResponseFaxLine.class); } - static public FaxLine init(HashMap data) throws Exception { + static public FaxLineResponseFaxLine init(HashMap data) throws Exception { return new ObjectMapper().readValue( new ObjectMapper().writeValueAsString(data), - FaxLine.class + FaxLineResponseFaxLine.class ); } - public FaxLine number(String number) { + public FaxLineResponseFaxLine number(String number) { this.number = number; return this; } @@ -102,7 +102,7 @@ public void setNumber(String number) { } - public FaxLine createdAt(String createdAt) { + public FaxLineResponseFaxLine createdAt(Integer createdAt) { this.createdAt = createdAt; return this; } @@ -116,19 +116,19 @@ public FaxLine createdAt(String createdAt) { @JsonProperty(JSON_PROPERTY_CREATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public String getCreatedAt() { + public Integer getCreatedAt() { return createdAt; } @JsonProperty(JSON_PROPERTY_CREATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setCreatedAt(String createdAt) { + public void setCreatedAt(Integer createdAt) { this.createdAt = createdAt; } - public FaxLine updatedAt(String updatedAt) { + public FaxLineResponseFaxLine updatedAt(Integer updatedAt) { this.updatedAt = updatedAt; return this; } @@ -142,24 +142,24 @@ public FaxLine updatedAt(String updatedAt) { @JsonProperty(JSON_PROPERTY_UPDATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public String getUpdatedAt() { + public Integer getUpdatedAt() { return updatedAt; } @JsonProperty(JSON_PROPERTY_UPDATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setUpdatedAt(String updatedAt) { + public void setUpdatedAt(Integer updatedAt) { this.updatedAt = updatedAt; } - public FaxLine accounts(List accounts) { + public FaxLineResponseFaxLine accounts(List accounts) { this.accounts = accounts; return this; } - public FaxLine addAccountsItem(AccountResponse accountsItem) { + public FaxLineResponseFaxLine addAccountsItem(AccountResponse accountsItem) { if (this.accounts == null) { this.accounts = new ArrayList<>(); } @@ -189,7 +189,7 @@ public void setAccounts(List accounts) { /** - * Return true if this FaxLine object is equal to o. + * Return true if this FaxLineResponseFaxLine object is equal to o. */ @Override public boolean equals(Object o) { @@ -199,11 +199,11 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) { return false; } - FaxLine faxLine = (FaxLine) o; - return Objects.equals(this.number, faxLine.number) && - Objects.equals(this.createdAt, faxLine.createdAt) && - Objects.equals(this.updatedAt, faxLine.updatedAt) && - Objects.equals(this.accounts, faxLine.accounts); + FaxLineResponseFaxLine faxLineResponseFaxLine = (FaxLineResponseFaxLine) o; + return Objects.equals(this.number, faxLineResponseFaxLine.number) && + Objects.equals(this.createdAt, faxLineResponseFaxLine.createdAt) && + Objects.equals(this.updatedAt, faxLineResponseFaxLine.updatedAt) && + Objects.equals(this.accounts, faxLineResponseFaxLine.accounts); } @Override @@ -214,7 +214,7 @@ public int hashCode() { @Override public String toString() { StringBuilder sb = new StringBuilder(); - sb.append("class FaxLine {\n"); + sb.append("class FaxLineResponseFaxLine {\n"); sb.append(" number: ").append(toIndentedString(number)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); diff --git a/sdks/java-v2/README.md b/sdks/java-v2/README.md index 1b3812463..08cf1f9c0 100644 --- a/sdks/java-v2/README.md +++ b/sdks/java-v2/README.md @@ -179,13 +179,13 @@ Class | Method | HTTP request | Description *BulkSendJobApi* | [**bulkSendJobList**](docs/BulkSendJobApi.md#bulkSendJobList) | **GET** /bulk_send_job/list | List Bulk Send Jobs *EmbeddedApi* | [**embeddedEditUrl**](docs/EmbeddedApi.md#embeddedEditUrl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL *EmbeddedApi* | [**embeddedSignUrl**](docs/EmbeddedApi.md#embeddedSignUrl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL -*FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +*FaxLineApi* | [**faxLineAddUser**](docs/FaxLineApi.md#faxLineAddUser) | **PUT** /fax_line/add_user | Add Fax Line User *FaxLineApi* | [**faxLineAreaCodeGet**](docs/FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes *FaxLineApi* | [**faxLineCreate**](docs/FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line *FaxLineApi* | [**faxLineDelete**](docs/FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line *FaxLineApi* | [**faxLineGet**](docs/FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line *FaxLineApi* | [**faxLineList**](docs/FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines -*FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access +*FaxLineApi* | [**faxLineRemoveUser**](docs/FaxLineApi.md#faxLineRemoveUser) | **PUT** /fax_line/remove_user | Remove Fax Line Access *OAuthApi* | [**oauthTokenGenerate**](docs/OAuthApi.md#oauthTokenGenerate) | **POST** /oauth/token | OAuth Token Generate *OAuthApi* | [**oauthTokenRefresh**](docs/OAuthApi.md#oauthTokenRefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh *ReportApi* | [**reportCreate**](docs/ReportApi.md#reportCreate) | **POST** /report/create | Create Report @@ -268,7 +268,6 @@ Class | Method | HTTP request | Description - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) - - [FaxLine](docs/FaxLine.md) - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) @@ -279,6 +278,7 @@ Class | Method | HTTP request | Description - [FaxLineListResponse](docs/FaxLineListResponse.md) - [FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) - [FaxLineResponse](docs/FaxLineResponse.md) + - [FaxLineResponseFaxLine](docs/FaxLineResponseFaxLine.md) - [FileResponse](docs/FileResponse.md) - [FileResponseDataUri](docs/FileResponseDataUri.md) - [ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/java-v2/docs/FaxLineApi.md b/sdks/java-v2/docs/FaxLineApi.md index f5e63be6e..7f1202cf5 100644 --- a/sdks/java-v2/docs/FaxLineApi.md +++ b/sdks/java-v2/docs/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to *https://api.hellosign.com/v3* Method | HTTP request | Description ------------- | ------------- | ------------- -[**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User +[**faxLineAddUser**](FaxLineApi.md#faxLineAddUser) | **PUT** /fax_line/add_user | Add Fax Line User [**faxLineAreaCodeGet**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes [**faxLineCreate**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line [**faxLineDelete**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line [**faxLineGet**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line [**faxLineList**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines -[**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access +[**faxLineRemoveUser**](FaxLineApi.md#faxLineRemoveUser) | **PUT** /fax_line/remove_user | Remove Fax Line Access @@ -182,7 +182,7 @@ public class Example { var faxLineApi = new FaxLineApi(apiClient); var data = new FaxLineCreateRequest() - .areaCode("209") + .areaCode(209) .country("US"); try { @@ -408,8 +408,8 @@ public class Example { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **accountId** | **String**| Account ID | [optional] - **page** | **Integer**| Page | [optional] - **pageSize** | **Integer**| Page size | [optional] + **page** | **Integer**| Page | [optional] [default to 1] + **pageSize** | **Integer**| Page size | [optional] [default to 20] **showTeamLines** | **Boolean**| Show team lines | [optional] ### Return type diff --git a/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md b/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md index 0b231dcf9..c77456fec 100644 --- a/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md +++ b/sdks/java-v2/docs/FaxLineAreaCodeGetResponse.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `areaCodes` | ```List``` | | | +| `areaCodes` | ```List``` | | | diff --git a/sdks/java-v2/docs/FaxLineCreateRequest.md b/sdks/java-v2/docs/FaxLineCreateRequest.md index e09db630f..d0be5225c 100644 --- a/sdks/java-v2/docs/FaxLineCreateRequest.md +++ b/sdks/java-v2/docs/FaxLineCreateRequest.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `areaCode`*_required_ | ```String``` | Area code | | +| `areaCode`*_required_ | ```Integer``` | Area code | | | `country`*_required_ | [```CountryEnum```](#CountryEnum) | Country | | | `city` | ```String``` | City | | | `accountId` | ```String``` | Account ID | | diff --git a/sdks/java-v2/docs/FaxLineListResponse.md b/sdks/java-v2/docs/FaxLineListResponse.md index 6e01b30a1..4f01f2fd3 100644 --- a/sdks/java-v2/docs/FaxLineListResponse.md +++ b/sdks/java-v2/docs/FaxLineListResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `faxLines` | [```List```](FaxLine.md) | | | +| `faxLines` | [```List```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v2/docs/FaxLineResponse.md b/sdks/java-v2/docs/FaxLineResponse.md index 44a845b3c..d9a67d41f 100644 --- a/sdks/java-v2/docs/FaxLineResponse.md +++ b/sdks/java-v2/docs/FaxLineResponse.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `faxLine` | [```FaxLine```](FaxLine.md) | | | +| `faxLine` | [```FaxLineResponseFaxLine```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/java-v2/docs/FaxLine.md b/sdks/java-v2/docs/FaxLineResponseFaxLine.md similarity index 65% rename from sdks/java-v2/docs/FaxLine.md rename to sdks/java-v2/docs/FaxLineResponseFaxLine.md index 5809f6353..caa5e07e2 100644 --- a/sdks/java-v2/docs/FaxLine.md +++ b/sdks/java-v2/docs/FaxLineResponseFaxLine.md @@ -1,6 +1,6 @@ -# FaxLine +# FaxLineResponseFaxLine @@ -9,8 +9,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `number` | ```String``` | Number | | -| `createdAt` | ```String``` | Created at | | -| `updatedAt` | ```String``` | Updated at | | +| `createdAt` | ```Integer``` | Created at | | +| `updatedAt` | ```Integer``` | Updated at | | | `accounts` | [```List```](AccountResponse.md) | | | diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java index 4fcc3be43..d2cd582ed 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/api/FaxLineApi.java @@ -124,7 +124,7 @@ public ApiResponse faxLineAddUserWithHttpInfo(FaxLineAddUserReq GenericType localVarReturnType = new GenericType() {}; - return apiClient.invokeAPI("FaxLineApi.faxLineAddUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + return apiClient.invokeAPI("FaxLineApi.faxLineAddUser", localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType, false); } @@ -501,8 +501,8 @@ public ApiResponse faxLineGetWithHttpInfo(String number) throws * List Fax Lines * Returns the properties and settings of multiple Fax Lines. * @param accountId Account ID (optional) - * @param page Page (optional) - * @param pageSize Page size (optional) + * @param page Page (optional, default to 1) + * @param pageSize Page size (optional, default to 20) * @param showTeamLines Show team lines (optional) * @return FaxLineListResponse * @throws ApiException if fails to make API call @@ -523,8 +523,8 @@ public FaxLineListResponse faxLineList(String accountId, Integer page, Integer p */ public FaxLineListResponse faxLineList() throws ApiException { String accountId = null; - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); @@ -535,8 +535,8 @@ public FaxLineListResponse faxLineList() throws ApiException { */ public ApiResponse faxLineListWithHttpInfo() throws ApiException { String accountId = null; - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); @@ -546,8 +546,8 @@ public ApiResponse faxLineListWithHttpInfo() throws ApiExce * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) */ public FaxLineListResponse faxLineList(String accountId) throws ApiException { - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); @@ -557,8 +557,8 @@ public FaxLineListResponse faxLineList(String accountId) throws ApiException { * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) */ public ApiResponse faxLineListWithHttpInfo(String accountId) throws ApiException { - Integer page = null; - Integer pageSize = null; + Integer page = 1; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); @@ -568,7 +568,7 @@ public ApiResponse faxLineListWithHttpInfo(String accountId * @see FaxLineApi#faxLineList(String, Integer, Integer, Boolean) */ public FaxLineListResponse faxLineList(String accountId, Integer page) throws ApiException { - Integer pageSize = null; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines).getData(); @@ -578,7 +578,7 @@ public FaxLineListResponse faxLineList(String accountId, Integer page) throws Ap * @see FaxLineApi#faxLineListWithHttpInfo(String, Integer, Integer, Boolean) */ public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page) throws ApiException { - Integer pageSize = null; + Integer pageSize = 20; Boolean showTeamLines = null; return faxLineListWithHttpInfo(accountId, page, pageSize, showTeamLines); @@ -607,8 +607,8 @@ public ApiResponse faxLineListWithHttpInfo(String accountId * List Fax Lines * Returns the properties and settings of multiple Fax Lines. * @param accountId Account ID (optional) - * @param page Page (optional) - * @param pageSize Page size (optional) + * @param page Page (optional, default to 1) + * @param pageSize Page size (optional, default to 20) * @param showTeamLines Show team lines (optional) * @return ApiResponse<FaxLineListResponse> * @throws ApiException if fails to make API call @@ -621,6 +621,12 @@ public ApiResponse faxLineListWithHttpInfo(String accountId */ public ApiResponse faxLineListWithHttpInfo(String accountId, Integer page, Integer pageSize, Boolean showTeamLines) throws ApiException { + if (page == null) { + page = 1; + } + if (pageSize == null) { + pageSize = 20; + } Object localVarPostBody = null; // create path and map variables @@ -733,7 +739,7 @@ public ApiResponse faxLineRemoveUserWithHttpInfo(FaxLineRemoveU GenericType localVarReturnType = new GenericType() {}; - return apiClient.invokeAPI("FaxLineApi.faxLineRemoveUser", localVarPath, "POST", localVarQueryParams, localVarPostBody, + return apiClient.invokeAPI("FaxLineApi.faxLineRemoveUser", localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType, false); } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java index b8dfac3e1..f07b04cb7 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineAreaCodeGetResponse.java @@ -43,7 +43,7 @@ @jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineAreaCodeGetResponse { public static final String JSON_PROPERTY_AREA_CODES = "area_codes"; - private List areaCodes; + private List areaCodes; public FaxLineAreaCodeGetResponse() { } @@ -63,12 +63,12 @@ static public FaxLineAreaCodeGetResponse init(HashMap data) throws Exception { ); } - public FaxLineAreaCodeGetResponse areaCodes(List areaCodes) { + public FaxLineAreaCodeGetResponse areaCodes(List areaCodes) { this.areaCodes = areaCodes; return this; } - public FaxLineAreaCodeGetResponse addAreaCodesItem(String areaCodesItem) { + public FaxLineAreaCodeGetResponse addAreaCodesItem(Integer areaCodesItem) { if (this.areaCodes == null) { this.areaCodes = new ArrayList<>(); } @@ -85,14 +85,14 @@ public FaxLineAreaCodeGetResponse addAreaCodesItem(String areaCodesItem) { @JsonProperty(JSON_PROPERTY_AREA_CODES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public List getAreaCodes() { + public List getAreaCodes() { return areaCodes; } @JsonProperty(JSON_PROPERTY_AREA_CODES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setAreaCodes(List areaCodes) { + public void setAreaCodes(List areaCodes) { this.areaCodes = areaCodes; } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java index 2b93f5557..01c5d5101 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineCreateRequest.java @@ -44,7 +44,7 @@ @jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineCreateRequest { public static final String JSON_PROPERTY_AREA_CODE = "area_code"; - private String areaCode; + private Integer areaCode; /** * Country @@ -110,7 +110,7 @@ static public FaxLineCreateRequest init(HashMap data) throws Exception { ); } - public FaxLineCreateRequest areaCode(String areaCode) { + public FaxLineCreateRequest areaCode(Integer areaCode) { this.areaCode = areaCode; return this; } @@ -124,14 +124,14 @@ public FaxLineCreateRequest areaCode(String areaCode) { @JsonProperty(JSON_PROPERTY_AREA_CODE) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public String getAreaCode() { + public Integer getAreaCode() { return areaCode; } @JsonProperty(JSON_PROPERTY_AREA_CODE) @JsonInclude(value = JsonInclude.Include.ALWAYS) - public void setAreaCode(String areaCode) { + public void setAreaCode(Integer areaCode) { this.areaCode = areaCode; } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java index 2af43d2a5..43f625a0c 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineListResponse.java @@ -16,7 +16,7 @@ import java.util.Objects; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLine; +import com.dropbox.sign.model.FaxLineResponseFaxLine; import com.dropbox.sign.model.ListInfoResponse; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; @@ -51,7 +51,7 @@ public class FaxLineListResponse { private ListInfoResponse listInfo; public static final String JSON_PROPERTY_FAX_LINES = "fax_lines"; - private List faxLines; + private List faxLines; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -100,12 +100,12 @@ public void setListInfo(ListInfoResponse listInfo) { } - public FaxLineListResponse faxLines(List faxLines) { + public FaxLineListResponse faxLines(List faxLines) { this.faxLines = faxLines; return this; } - public FaxLineListResponse addFaxLinesItem(FaxLine faxLinesItem) { + public FaxLineListResponse addFaxLinesItem(FaxLineResponseFaxLine faxLinesItem) { if (this.faxLines == null) { this.faxLines = new ArrayList<>(); } @@ -122,14 +122,14 @@ public FaxLineListResponse addFaxLinesItem(FaxLine faxLinesItem) { @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public List getFaxLines() { + public List getFaxLines() { return faxLines; } @JsonProperty(JSON_PROPERTY_FAX_LINES) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLines(List faxLines) { + public void setFaxLines(List faxLines) { this.faxLines = faxLines; } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java index 987e41060..06b7527f9 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponse.java @@ -16,7 +16,7 @@ import java.util.Objects; import java.util.Map; import java.util.HashMap; -import com.dropbox.sign.model.FaxLine; +import com.dropbox.sign.model.FaxLineResponseFaxLine; import com.dropbox.sign.model.WarningResponse; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -44,7 +44,7 @@ @jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class FaxLineResponse { public static final String JSON_PROPERTY_FAX_LINE = "fax_line"; - private FaxLine faxLine; + private FaxLineResponseFaxLine faxLine; public static final String JSON_PROPERTY_WARNINGS = "warnings"; private WarningResponse warnings; @@ -67,7 +67,7 @@ static public FaxLineResponse init(HashMap data) throws Exception { ); } - public FaxLineResponse faxLine(FaxLine faxLine) { + public FaxLineResponse faxLine(FaxLineResponseFaxLine faxLine) { this.faxLine = faxLine; return this; } @@ -81,14 +81,14 @@ public FaxLineResponse faxLine(FaxLine faxLine) { @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public FaxLine getFaxLine() { + public FaxLineResponseFaxLine getFaxLine() { return faxLine; } @JsonProperty(JSON_PROPERTY_FAX_LINE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setFaxLine(FaxLine faxLine) { + public void setFaxLine(FaxLineResponseFaxLine faxLine) { this.faxLine = faxLine; } diff --git a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponseFaxLine.java similarity index 84% rename from sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java rename to sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponseFaxLine.java index 083efc9df..b9253e223 100644 --- a/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLine.java +++ b/sdks/java-v2/src/main/java/com/dropbox/sign/model/FaxLineResponseFaxLine.java @@ -35,48 +35,48 @@ import com.dropbox.sign.ApiException; /** - * FaxLine + * FaxLineResponseFaxLine */ @JsonPropertyOrder({ - FaxLine.JSON_PROPERTY_NUMBER, - FaxLine.JSON_PROPERTY_CREATED_AT, - FaxLine.JSON_PROPERTY_UPDATED_AT, - FaxLine.JSON_PROPERTY_ACCOUNTS + FaxLineResponseFaxLine.JSON_PROPERTY_NUMBER, + FaxLineResponseFaxLine.JSON_PROPERTY_CREATED_AT, + FaxLineResponseFaxLine.JSON_PROPERTY_UPDATED_AT, + FaxLineResponseFaxLine.JSON_PROPERTY_ACCOUNTS }) @JsonIgnoreProperties(ignoreUnknown=true) @jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") -public class FaxLine { +public class FaxLineResponseFaxLine { public static final String JSON_PROPERTY_NUMBER = "number"; private String number; public static final String JSON_PROPERTY_CREATED_AT = "created_at"; - private String createdAt; + private Integer createdAt; public static final String JSON_PROPERTY_UPDATED_AT = "updated_at"; - private String updatedAt; + private Integer updatedAt; public static final String JSON_PROPERTY_ACCOUNTS = "accounts"; private List accounts; - public FaxLine() { + public FaxLineResponseFaxLine() { } /** * Attempt to instantiate and hydrate a new instance of this class * @param jsonData String of JSON data representing target object */ - static public FaxLine init(String jsonData) throws Exception { - return new ObjectMapper().readValue(jsonData, FaxLine.class); + static public FaxLineResponseFaxLine init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, FaxLineResponseFaxLine.class); } - static public FaxLine init(HashMap data) throws Exception { + static public FaxLineResponseFaxLine init(HashMap data) throws Exception { return new ObjectMapper().readValue( new ObjectMapper().writeValueAsString(data), - FaxLine.class + FaxLineResponseFaxLine.class ); } - public FaxLine number(String number) { + public FaxLineResponseFaxLine number(String number) { this.number = number; return this; } @@ -102,7 +102,7 @@ public void setNumber(String number) { } - public FaxLine createdAt(String createdAt) { + public FaxLineResponseFaxLine createdAt(Integer createdAt) { this.createdAt = createdAt; return this; } @@ -116,19 +116,19 @@ public FaxLine createdAt(String createdAt) { @JsonProperty(JSON_PROPERTY_CREATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public String getCreatedAt() { + public Integer getCreatedAt() { return createdAt; } @JsonProperty(JSON_PROPERTY_CREATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setCreatedAt(String createdAt) { + public void setCreatedAt(Integer createdAt) { this.createdAt = createdAt; } - public FaxLine updatedAt(String updatedAt) { + public FaxLineResponseFaxLine updatedAt(Integer updatedAt) { this.updatedAt = updatedAt; return this; } @@ -142,24 +142,24 @@ public FaxLine updatedAt(String updatedAt) { @JsonProperty(JSON_PROPERTY_UPDATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public String getUpdatedAt() { + public Integer getUpdatedAt() { return updatedAt; } @JsonProperty(JSON_PROPERTY_UPDATED_AT) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public void setUpdatedAt(String updatedAt) { + public void setUpdatedAt(Integer updatedAt) { this.updatedAt = updatedAt; } - public FaxLine accounts(List accounts) { + public FaxLineResponseFaxLine accounts(List accounts) { this.accounts = accounts; return this; } - public FaxLine addAccountsItem(AccountResponse accountsItem) { + public FaxLineResponseFaxLine addAccountsItem(AccountResponse accountsItem) { if (this.accounts == null) { this.accounts = new ArrayList<>(); } @@ -189,7 +189,7 @@ public void setAccounts(List accounts) { /** - * Return true if this FaxLine object is equal to o. + * Return true if this FaxLineResponseFaxLine object is equal to o. */ @Override public boolean equals(Object o) { @@ -199,11 +199,11 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) { return false; } - FaxLine faxLine = (FaxLine) o; - return Objects.equals(this.number, faxLine.number) && - Objects.equals(this.createdAt, faxLine.createdAt) && - Objects.equals(this.updatedAt, faxLine.updatedAt) && - Objects.equals(this.accounts, faxLine.accounts); + FaxLineResponseFaxLine faxLineResponseFaxLine = (FaxLineResponseFaxLine) o; + return Objects.equals(this.number, faxLineResponseFaxLine.number) && + Objects.equals(this.createdAt, faxLineResponseFaxLine.createdAt) && + Objects.equals(this.updatedAt, faxLineResponseFaxLine.updatedAt) && + Objects.equals(this.accounts, faxLineResponseFaxLine.accounts); } @Override @@ -214,7 +214,7 @@ public int hashCode() { @Override public String toString() { StringBuilder sb = new StringBuilder(); - sb.append("class FaxLine {\n"); + sb.append("class FaxLineResponseFaxLine {\n"); sb.append(" number: ").append(toIndentedString(number)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); diff --git a/sdks/node/README.md b/sdks/node/README.md index 57dfd427e..4aca5d208 100644 --- a/sdks/node/README.md +++ b/sdks/node/README.md @@ -120,13 +120,13 @@ All URIs are relative to *https://api.hellosign.com/v3* | *BulkSendJobApi* | [**bulkSendJobList**](./docs/api/BulkSendJobApi.md#bulksendjoblist) | **GET** /bulk_send_job/list | List Bulk Send Jobs | | *EmbeddedApi* | [**embeddedEditUrl**](./docs/api/EmbeddedApi.md#embeddedediturl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL | | *EmbeddedApi* | [**embeddedSignUrl**](./docs/api/EmbeddedApi.md#embeddedsignurl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL | -| *FaxLineApi* | [**faxLineAddUser**](./docs/api/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | +| *FaxLineApi* | [**faxLineAddUser**](./docs/api/FaxLineApi.md#faxlineadduser) | **PUT** /fax_line/add_user | Add Fax Line User | | *FaxLineApi* | [**faxLineAreaCodeGet**](./docs/api/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | *FaxLineApi* | [**faxLineCreate**](./docs/api/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | | *FaxLineApi* | [**faxLineDelete**](./docs/api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line | | *FaxLineApi* | [**faxLineGet**](./docs/api/FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line | | *FaxLineApi* | [**faxLineList**](./docs/api/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | -| *FaxLineApi* | [**faxLineRemoveUser**](./docs/api/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | +| *FaxLineApi* | [**faxLineRemoveUser**](./docs/api/FaxLineApi.md#faxlineremoveuser) | **PUT** /fax_line/remove_user | Remove Fax Line Access | | *OAuthApi* | [**oauthTokenGenerate**](./docs/api/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate | | *OAuthApi* | [**oauthTokenRefresh**](./docs/api/OAuthApi.md#oauthtokenrefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh | | *ReportApi* | [**reportCreate**](./docs/api/ReportApi.md#reportcreate) | **POST** /report/create | Create Report | @@ -208,7 +208,6 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](./docs/model/EventCallbackRequest.md) - [EventCallbackRequestEvent](./docs/model/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](./docs/model/EventCallbackRequestEventMetadata.md) -- [FaxLine](./docs/model/FaxLine.md) - [FaxLineAddUserRequest](./docs/model/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](./docs/model/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](./docs/model/FaxLineAreaCodeGetProvinceEnum.md) @@ -219,6 +218,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [FaxLineListResponse](./docs/model/FaxLineListResponse.md) - [FaxLineRemoveUserRequest](./docs/model/FaxLineRemoveUserRequest.md) - [FaxLineResponse](./docs/model/FaxLineResponse.md) +- [FaxLineResponseFaxLine](./docs/model/FaxLineResponseFaxLine.md) - [FileResponse](./docs/model/FileResponse.md) - [FileResponseDataUri](./docs/model/FileResponseDataUri.md) - [ListInfoResponse](./docs/model/ListInfoResponse.md) diff --git a/sdks/node/api/faxLineApi.ts b/sdks/node/api/faxLineApi.ts index afaac4e3e..9d035a633 100644 --- a/sdks/node/api/faxLineApi.ts +++ b/sdks/node/api/faxLineApi.ts @@ -198,7 +198,7 @@ export class FaxLineApi { } let localVarRequestOptions: AxiosRequestConfig = { - method: "POST", + method: "PUT", params: localVarQueryParameters, headers: localVarHeaderParams, url: localVarPath, @@ -1181,7 +1181,7 @@ export class FaxLineApi { } let localVarRequestOptions: AxiosRequestConfig = { - method: "POST", + method: "PUT", params: localVarQueryParameters, headers: localVarHeaderParams, url: localVarPath, diff --git a/sdks/node/dist/api.js b/sdks/node/dist/api.js index 2206bd9c5..a8ea077e2 100644 --- a/sdks/node/dist/api.js +++ b/sdks/node/dist/api.js @@ -12973,7 +12973,6 @@ __export(api_exports, { EventCallbackRequest: () => EventCallbackRequest, EventCallbackRequestEvent: () => EventCallbackRequestEvent, EventCallbackRequestEventMetadata: () => EventCallbackRequestEventMetadata, - FaxLine: () => FaxLine, FaxLineAddUserRequest: () => FaxLineAddUserRequest, FaxLineApi: () => FaxLineApi, FaxLineAreaCodeGetCountryEnum: () => FaxLineAreaCodeGetCountryEnum, @@ -12985,6 +12984,7 @@ __export(api_exports, { FaxLineListResponse: () => FaxLineListResponse, FaxLineRemoveUserRequest: () => FaxLineRemoveUserRequest, FaxLineResponse: () => FaxLineResponse, + FaxLineResponseFaxLine: () => FaxLineResponseFaxLine, FileResponse: () => FileResponse, FileResponseDataUri: () => FileResponseDataUri, HttpBasicAuth: () => HttpBasicAuth, @@ -17664,40 +17664,6 @@ EventCallbackRequestEventMetadata.attributeTypeMap = [ } ]; -// model/faxLine.ts -var _FaxLine = class { - static getAttributeTypeMap() { - return _FaxLine.attributeTypeMap; - } - static init(data) { - return ObjectSerializer.deserialize(data, "FaxLine"); - } -}; -var FaxLine = _FaxLine; -FaxLine.discriminator = void 0; -FaxLine.attributeTypeMap = [ - { - name: "number", - baseName: "number", - type: "string" - }, - { - name: "createdAt", - baseName: "created_at", - type: "string" - }, - { - name: "updatedAt", - baseName: "updated_at", - type: "string" - }, - { - name: "accounts", - baseName: "accounts", - type: "Array" - } -]; - // model/faxLineAddUserRequest.ts var _FaxLineAddUserRequest = class { static getAttributeTypeMap() { @@ -17768,7 +17734,7 @@ FaxLineAreaCodeGetResponse.attributeTypeMap = [ { name: "areaCodes", baseName: "area_codes", - type: "Array" + type: "Array" } ]; @@ -17843,7 +17809,7 @@ FaxLineCreateRequest.attributeTypeMap = [ { name: "areaCode", baseName: "area_code", - type: "string" + type: "number" }, { name: "country", @@ -17909,7 +17875,7 @@ FaxLineListResponse.attributeTypeMap = [ { name: "faxLines", baseName: "fax_lines", - type: "Array" + type: "Array" }, { name: "warnings", @@ -17962,7 +17928,7 @@ FaxLineResponse.attributeTypeMap = [ { name: "faxLine", baseName: "fax_line", - type: "FaxLine" + type: "FaxLineResponseFaxLine" }, { name: "warnings", @@ -17971,6 +17937,40 @@ FaxLineResponse.attributeTypeMap = [ } ]; +// model/faxLineResponseFaxLine.ts +var _FaxLineResponseFaxLine = class { + static getAttributeTypeMap() { + return _FaxLineResponseFaxLine.attributeTypeMap; + } + static init(data) { + return ObjectSerializer.deserialize(data, "FaxLineResponseFaxLine"); + } +}; +var FaxLineResponseFaxLine = _FaxLineResponseFaxLine; +FaxLineResponseFaxLine.discriminator = void 0; +FaxLineResponseFaxLine.attributeTypeMap = [ + { + name: "number", + baseName: "number", + type: "string" + }, + { + name: "createdAt", + baseName: "created_at", + type: "number" + }, + { + name: "updatedAt", + baseName: "updated_at", + type: "number" + }, + { + name: "accounts", + baseName: "accounts", + type: "Array" + } +]; + // model/fileResponse.ts var _FileResponse = class { static getAttributeTypeMap() { @@ -24467,7 +24467,6 @@ var typeMap = { EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, - FaxLine, FaxLineAddUserRequest, FaxLineAreaCodeGetResponse, FaxLineCreateRequest, @@ -24475,6 +24474,7 @@ var typeMap = { FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse, + FaxLineResponseFaxLine, FileResponse, FileResponseDataUri, ListInfoResponse, @@ -26406,7 +26406,7 @@ var FaxLineApi = class { ); } let localVarRequestOptions = { - method: "POST", + method: "PUT", params: localVarQueryParameters, headers: localVarHeaderParams, url: localVarPath, @@ -27077,7 +27077,7 @@ var FaxLineApi = class { ); } let localVarRequestOptions = { - method: "POST", + method: "PUT", params: localVarQueryParameters, headers: localVarHeaderParams, url: localVarPath, @@ -32638,7 +32638,6 @@ var APIS = [ EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, - FaxLine, FaxLineAddUserRequest, FaxLineApi, FaxLineAreaCodeGetCountryEnum, @@ -32650,6 +32649,7 @@ var APIS = [ FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse, + FaxLineResponseFaxLine, FileResponse, FileResponseDataUri, HttpBasicAuth, diff --git a/sdks/node/docs/api/FaxLineApi.md b/sdks/node/docs/api/FaxLineApi.md index 2e9cd33bb..4d9f6208b 100644 --- a/sdks/node/docs/api/FaxLineApi.md +++ b/sdks/node/docs/api/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to https://api.hellosign.com/v3. | Method | HTTP request | Description | | ------------- | ------------- | ------------- | -| [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User | +| [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **PUT** /fax_line/add_user | Add Fax Line User | | [**faxLineAreaCodeGet()**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | [**faxLineCreate()**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line | | [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line | | [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line | | [**faxLineList()**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines | -| [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access | +| [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **PUT** /fax_line/remove_user | Remove Fax Line Access | ## `faxLineAddUser()` @@ -193,7 +193,7 @@ const faxLineApi = new DropboxSign.FaxLineApi(); faxLineApi.username = "YOUR_API_KEY"; const data: DropboxSign.FaxLineCreateRequest = { - areaCode: "209", + areaCode: 209, country: "US", }; @@ -218,7 +218,7 @@ const faxLineApi = new DropboxSign.FaxLineApi(); faxLineApi.username = "YOUR_API_KEY"; const data = { - areaCode: "209", + areaCode: 209, country: "US", }; @@ -280,9 +280,8 @@ const data: DropboxSign.FaxLineDeleteRequest = { }; const result = faxLineApi.faxLineDelete(data); -result.then(response => { - console.log(response.body); -}).catch(error => { + +result.catch(error => { console.log("Exception when calling Dropbox Sign API:"); console.log(error.body); }); @@ -304,9 +303,8 @@ const data = { }; const result = faxLineApi.faxLineDelete(data); -result.then(response => { - console.log(response.body); -}).catch(error => { + +result.catch(error => { console.log("Exception when calling Dropbox Sign API:"); console.log(error.body); }); @@ -464,8 +462,8 @@ result.then(response => { |Name | Type | Description | Notes | | ------------- | ------------- | ------------- | ------------- | | **accountId** | **string**| Account ID | [optional] | -| **page** | **number**| Page | [optional] | -| **pageSize** | **number**| Page size | [optional] | +| **page** | **number**| Page | [optional] [default to 1] | +| **pageSize** | **number**| Page size | [optional] [default to 20] | | **showTeamLines** | **boolean**| Show team lines | [optional] | ### Return type diff --git a/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md b/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md index c348038bc..c35e56042 100644 --- a/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md +++ b/sdks/node/docs/model/FaxLineAreaCodeGetResponse.md @@ -6,6 +6,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `areaCodes` | ```Array``` | | | +| `areaCodes` | ```Array``` | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineCreateRequest.md b/sdks/node/docs/model/FaxLineCreateRequest.md index d4cdf41fe..ae70b5cb9 100644 --- a/sdks/node/docs/model/FaxLineCreateRequest.md +++ b/sdks/node/docs/model/FaxLineCreateRequest.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `areaCode`*_required_ | ```string``` | Area code | | +| `areaCode`*_required_ | ```number``` | Area code | | | `country`*_required_ | ```string``` | Country | | | `city` | ```string``` | City | | | `accountId` | ```string``` | Account ID | | diff --git a/sdks/node/docs/model/FaxLineListResponse.md b/sdks/node/docs/model/FaxLineListResponse.md index 0fba42b1a..68ff414e0 100644 --- a/sdks/node/docs/model/FaxLineListResponse.md +++ b/sdks/node/docs/model/FaxLineListResponse.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `listInfo` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `faxLines` | [```Array```](FaxLine.md) | | | +| `faxLines` | [```Array```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLineResponse.md b/sdks/node/docs/model/FaxLineResponse.md index 433ae47e4..e146e6b15 100644 --- a/sdks/node/docs/model/FaxLineResponse.md +++ b/sdks/node/docs/model/FaxLineResponse.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `faxLine` | [```FaxLine```](FaxLine.md) | | | +| `faxLine` | [```FaxLineResponseFaxLine```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/docs/model/FaxLine.md b/sdks/node/docs/model/FaxLineResponseFaxLine.md similarity index 74% rename from sdks/node/docs/model/FaxLine.md rename to sdks/node/docs/model/FaxLineResponseFaxLine.md index 11793305e..aaf5b0f21 100644 --- a/sdks/node/docs/model/FaxLine.md +++ b/sdks/node/docs/model/FaxLineResponseFaxLine.md @@ -1,4 +1,4 @@ -# # FaxLine +# # FaxLineResponseFaxLine @@ -7,8 +7,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `number` | ```string``` | Number | | -| `createdAt` | ```string``` | Created at | | -| `updatedAt` | ```string``` | Updated at | | +| `createdAt` | ```number``` | Created at | | +| `updatedAt` | ```number``` | Updated at | | | `accounts` | [```Array```](AccountResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/node/model/faxLineAreaCodeGetResponse.ts b/sdks/node/model/faxLineAreaCodeGetResponse.ts index ffffcc2a1..174a0e200 100644 --- a/sdks/node/model/faxLineAreaCodeGetResponse.ts +++ b/sdks/node/model/faxLineAreaCodeGetResponse.ts @@ -25,7 +25,7 @@ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; export class FaxLineAreaCodeGetResponse { - "areaCodes"?: Array; + "areaCodes"?: Array; static discriminator: string | undefined = undefined; @@ -33,7 +33,7 @@ export class FaxLineAreaCodeGetResponse { { name: "areaCodes", baseName: "area_codes", - type: "Array", + type: "Array", }, ]; diff --git a/sdks/node/model/faxLineCreateRequest.ts b/sdks/node/model/faxLineCreateRequest.ts index 7d468ac82..57d956676 100644 --- a/sdks/node/model/faxLineCreateRequest.ts +++ b/sdks/node/model/faxLineCreateRequest.ts @@ -28,7 +28,7 @@ export class FaxLineCreateRequest { /** * Area code */ - "areaCode": string; + "areaCode": number; /** * Country */ @@ -48,7 +48,7 @@ export class FaxLineCreateRequest { { name: "areaCode", baseName: "area_code", - type: "string", + type: "number", }, { name: "country", diff --git a/sdks/node/model/faxLineListResponse.ts b/sdks/node/model/faxLineListResponse.ts index a36302a3d..22fd72ecf 100644 --- a/sdks/node/model/faxLineListResponse.ts +++ b/sdks/node/model/faxLineListResponse.ts @@ -23,13 +23,13 @@ */ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; -import { FaxLine } from "./faxLine"; +import { FaxLineResponseFaxLine } from "./faxLineResponseFaxLine"; import { ListInfoResponse } from "./listInfoResponse"; import { WarningResponse } from "./warningResponse"; export class FaxLineListResponse { "listInfo"?: ListInfoResponse; - "faxLines"?: Array; + "faxLines"?: Array; "warnings"?: WarningResponse; static discriminator: string | undefined = undefined; @@ -43,7 +43,7 @@ export class FaxLineListResponse { { name: "faxLines", baseName: "fax_lines", - type: "Array", + type: "Array", }, { name: "warnings", diff --git a/sdks/node/model/faxLineResponse.ts b/sdks/node/model/faxLineResponse.ts index 18a88b7e5..edbd397fd 100644 --- a/sdks/node/model/faxLineResponse.ts +++ b/sdks/node/model/faxLineResponse.ts @@ -23,11 +23,11 @@ */ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; -import { FaxLine } from "./faxLine"; +import { FaxLineResponseFaxLine } from "./faxLineResponseFaxLine"; import { WarningResponse } from "./warningResponse"; export class FaxLineResponse { - "faxLine"?: FaxLine; + "faxLine"?: FaxLineResponseFaxLine; "warnings"?: WarningResponse; static discriminator: string | undefined = undefined; @@ -36,7 +36,7 @@ export class FaxLineResponse { { name: "faxLine", baseName: "fax_line", - type: "FaxLine", + type: "FaxLineResponseFaxLine", }, { name: "warnings", diff --git a/sdks/node/model/faxLine.ts b/sdks/node/model/faxLineResponseFaxLine.ts similarity index 86% rename from sdks/node/model/faxLine.ts rename to sdks/node/model/faxLineResponseFaxLine.ts index a0fb7ecda..da6e919ff 100644 --- a/sdks/node/model/faxLine.ts +++ b/sdks/node/model/faxLineResponseFaxLine.ts @@ -25,7 +25,7 @@ import { RequestFile, AttributeTypeMap, ObjectSerializer } from "./"; import { AccountResponse } from "./accountResponse"; -export class FaxLine { +export class FaxLineResponseFaxLine { /** * Number */ @@ -33,11 +33,11 @@ export class FaxLine { /** * Created at */ - "createdAt"?: string; + "createdAt"?: number; /** * Updated at */ - "updatedAt"?: string; + "updatedAt"?: number; "accounts"?: Array; static discriminator: string | undefined = undefined; @@ -51,12 +51,12 @@ export class FaxLine { { name: "createdAt", baseName: "created_at", - type: "string", + type: "number", }, { name: "updatedAt", baseName: "updated_at", - type: "string", + type: "number", }, { name: "accounts", @@ -66,11 +66,11 @@ export class FaxLine { ]; static getAttributeTypeMap(): AttributeTypeMap { - return FaxLine.attributeTypeMap; + return FaxLineResponseFaxLine.attributeTypeMap; } /** Attempt to instantiate and hydrate a new instance of this class */ - static init(data: any): FaxLine { - return ObjectSerializer.deserialize(data, "FaxLine"); + static init(data: any): FaxLineResponseFaxLine { + return ObjectSerializer.deserialize(data, "FaxLineResponseFaxLine"); } } diff --git a/sdks/node/model/index.ts b/sdks/node/model/index.ts index 3cf73bafc..719921cba 100644 --- a/sdks/node/model/index.ts +++ b/sdks/node/model/index.ts @@ -32,7 +32,6 @@ import { ErrorResponseError } from "./errorResponseError"; import { EventCallbackRequest } from "./eventCallbackRequest"; import { EventCallbackRequestEvent } from "./eventCallbackRequestEvent"; import { EventCallbackRequestEventMetadata } from "./eventCallbackRequestEventMetadata"; -import { FaxLine } from "./faxLine"; import { FaxLineAddUserRequest } from "./faxLineAddUserRequest"; import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; import { FaxLineAreaCodeGetProvinceEnum } from "./faxLineAreaCodeGetProvinceEnum"; @@ -43,6 +42,7 @@ import { FaxLineDeleteRequest } from "./faxLineDeleteRequest"; import { FaxLineListResponse } from "./faxLineListResponse"; import { FaxLineRemoveUserRequest } from "./faxLineRemoveUserRequest"; import { FaxLineResponse } from "./faxLineResponse"; +import { FaxLineResponseFaxLine } from "./faxLineResponseFaxLine"; import { FileResponse } from "./fileResponse"; import { FileResponseDataUri } from "./fileResponseDataUri"; import { ListInfoResponse } from "./listInfoResponse"; @@ -279,7 +279,6 @@ export let typeMap: { [index: string]: any } = { EventCallbackRequest: EventCallbackRequest, EventCallbackRequestEvent: EventCallbackRequestEvent, EventCallbackRequestEventMetadata: EventCallbackRequestEventMetadata, - FaxLine: FaxLine, FaxLineAddUserRequest: FaxLineAddUserRequest, FaxLineAreaCodeGetResponse: FaxLineAreaCodeGetResponse, FaxLineCreateRequest: FaxLineCreateRequest, @@ -287,6 +286,7 @@ export let typeMap: { [index: string]: any } = { FaxLineListResponse: FaxLineListResponse, FaxLineRemoveUserRequest: FaxLineRemoveUserRequest, FaxLineResponse: FaxLineResponse, + FaxLineResponseFaxLine: FaxLineResponseFaxLine, FileResponse: FileResponse, FileResponseDataUri: FileResponseDataUri, ListInfoResponse: ListInfoResponse, @@ -495,7 +495,6 @@ export { EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, - FaxLine, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, @@ -506,6 +505,7 @@ export { FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse, + FaxLineResponseFaxLine, FileResponse, FileResponseDataUri, ListInfoResponse, diff --git a/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts b/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts index 407a8b125..30486165b 100644 --- a/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts +++ b/sdks/node/types/model/faxLineAreaCodeGetResponse.d.ts @@ -1,6 +1,6 @@ import { AttributeTypeMap } from "./"; export declare class FaxLineAreaCodeGetResponse { - "areaCodes"?: Array; + "areaCodes"?: Array; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; static getAttributeTypeMap(): AttributeTypeMap; diff --git a/sdks/node/types/model/faxLineCreateRequest.d.ts b/sdks/node/types/model/faxLineCreateRequest.d.ts index 258ac918e..a91bcda4d 100644 --- a/sdks/node/types/model/faxLineCreateRequest.d.ts +++ b/sdks/node/types/model/faxLineCreateRequest.d.ts @@ -1,6 +1,6 @@ import { AttributeTypeMap } from "./"; export declare class FaxLineCreateRequest { - "areaCode": string; + "areaCode": number; "country": FaxLineCreateRequest.CountryEnum; "city"?: string; "accountId"?: string; diff --git a/sdks/node/types/model/faxLineListResponse.d.ts b/sdks/node/types/model/faxLineListResponse.d.ts index 10d882d4d..e1e098d4a 100644 --- a/sdks/node/types/model/faxLineListResponse.d.ts +++ b/sdks/node/types/model/faxLineListResponse.d.ts @@ -1,10 +1,10 @@ import { AttributeTypeMap } from "./"; -import { FaxLine } from "./faxLine"; +import { FaxLineResponseFaxLine } from "./faxLineResponseFaxLine"; import { ListInfoResponse } from "./listInfoResponse"; import { WarningResponse } from "./warningResponse"; export declare class FaxLineListResponse { "listInfo"?: ListInfoResponse; - "faxLines"?: Array; + "faxLines"?: Array; "warnings"?: WarningResponse; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; diff --git a/sdks/node/types/model/faxLineResponse.d.ts b/sdks/node/types/model/faxLineResponse.d.ts index b316b355a..38bbc1a1c 100644 --- a/sdks/node/types/model/faxLineResponse.d.ts +++ b/sdks/node/types/model/faxLineResponse.d.ts @@ -1,8 +1,8 @@ import { AttributeTypeMap } from "./"; -import { FaxLine } from "./faxLine"; +import { FaxLineResponseFaxLine } from "./faxLineResponseFaxLine"; import { WarningResponse } from "./warningResponse"; export declare class FaxLineResponse { - "faxLine"?: FaxLine; + "faxLine"?: FaxLineResponseFaxLine; "warnings"?: WarningResponse; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; diff --git a/sdks/node/types/model/faxLine.d.ts b/sdks/node/types/model/faxLineResponseFaxLine.d.ts similarity index 66% rename from sdks/node/types/model/faxLine.d.ts rename to sdks/node/types/model/faxLineResponseFaxLine.d.ts index 3356ed36d..d5f8c4aa7 100644 --- a/sdks/node/types/model/faxLine.d.ts +++ b/sdks/node/types/model/faxLineResponseFaxLine.d.ts @@ -1,12 +1,12 @@ import { AttributeTypeMap } from "./"; import { AccountResponse } from "./accountResponse"; -export declare class FaxLine { +export declare class FaxLineResponseFaxLine { "number"?: string; - "createdAt"?: string; - "updatedAt"?: string; + "createdAt"?: number; + "updatedAt"?: number; "accounts"?: Array; static discriminator: string | undefined; static attributeTypeMap: AttributeTypeMap; static getAttributeTypeMap(): AttributeTypeMap; - static init(data: any): FaxLine; + static init(data: any): FaxLineResponseFaxLine; } diff --git a/sdks/node/types/model/index.d.ts b/sdks/node/types/model/index.d.ts index 7ef102f0e..f8a7cde2c 100644 --- a/sdks/node/types/model/index.d.ts +++ b/sdks/node/types/model/index.d.ts @@ -32,7 +32,6 @@ import { ErrorResponseError } from "./errorResponseError"; import { EventCallbackRequest } from "./eventCallbackRequest"; import { EventCallbackRequestEvent } from "./eventCallbackRequestEvent"; import { EventCallbackRequestEventMetadata } from "./eventCallbackRequestEventMetadata"; -import { FaxLine } from "./faxLine"; import { FaxLineAddUserRequest } from "./faxLineAddUserRequest"; import { FaxLineAreaCodeGetCountryEnum } from "./faxLineAreaCodeGetCountryEnum"; import { FaxLineAreaCodeGetProvinceEnum } from "./faxLineAreaCodeGetProvinceEnum"; @@ -43,6 +42,7 @@ import { FaxLineDeleteRequest } from "./faxLineDeleteRequest"; import { FaxLineListResponse } from "./faxLineListResponse"; import { FaxLineRemoveUserRequest } from "./faxLineRemoveUserRequest"; import { FaxLineResponse } from "./faxLineResponse"; +import { FaxLineResponseFaxLine } from "./faxLineResponseFaxLine"; import { FileResponse } from "./fileResponse"; import { FileResponseDataUri } from "./fileResponseDataUri"; import { ListInfoResponse } from "./listInfoResponse"; @@ -189,4 +189,4 @@ export declare let enumsMap: { export declare let typeMap: { [index: string]: any; }; -export { AccountCreateRequest, AccountCreateResponse, AccountGetResponse, AccountResponse, AccountResponseQuotas, AccountResponseUsage, AccountUpdateRequest, AccountVerifyRequest, AccountVerifyResponse, AccountVerifyResponseAccount, ApiAppCreateRequest, ApiAppGetResponse, ApiAppListResponse, ApiAppResponse, ApiAppResponseOAuth, ApiAppResponseOptions, ApiAppResponseOwnerAccount, ApiAppResponseWhiteLabelingOptions, ApiAppUpdateRequest, BulkSendJobGetResponse, BulkSendJobGetResponseSignatureRequests, BulkSendJobListResponse, BulkSendJobResponse, BulkSendJobSendResponse, EmbeddedEditUrlRequest, EmbeddedEditUrlResponse, EmbeddedEditUrlResponseEmbedded, EmbeddedSignUrlResponse, EmbeddedSignUrlResponseEmbedded, ErrorResponse, ErrorResponseError, EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, FaxLine, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetResponse, FaxLineAreaCodeGetStateEnum, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse, FileResponse, FileResponseDataUri, ListInfoResponse, OAuthTokenGenerateRequest, OAuthTokenRefreshRequest, OAuthTokenResponse, ReportCreateRequest, ReportCreateResponse, ReportResponse, SignatureRequestBulkCreateEmbeddedWithTemplateRequest, SignatureRequestBulkSendWithTemplateRequest, SignatureRequestCreateEmbeddedRequest, SignatureRequestCreateEmbeddedWithTemplateRequest, SignatureRequestGetResponse, SignatureRequestListResponse, SignatureRequestRemindRequest, SignatureRequestResponse, SignatureRequestResponseAttachment, SignatureRequestResponseCustomFieldBase, SignatureRequestResponseCustomFieldCheckbox, SignatureRequestResponseCustomFieldText, SignatureRequestResponseCustomFieldTypeEnum, SignatureRequestResponseDataBase, SignatureRequestResponseDataTypeEnum, SignatureRequestResponseDataValueCheckbox, SignatureRequestResponseDataValueCheckboxMerge, SignatureRequestResponseDataValueDateSigned, SignatureRequestResponseDataValueDropdown, SignatureRequestResponseDataValueInitials, SignatureRequestResponseDataValueRadio, SignatureRequestResponseDataValueSignature, SignatureRequestResponseDataValueText, SignatureRequestResponseDataValueTextMerge, SignatureRequestResponseSignatures, SignatureRequestSendRequest, SignatureRequestSendWithTemplateRequest, SignatureRequestUpdateRequest, SubAttachment, SubBulkSignerList, SubBulkSignerListCustomField, SubCC, SubCustomField, SubEditorOptions, SubFieldOptions, SubFormFieldGroup, SubFormFieldRule, SubFormFieldRuleAction, SubFormFieldRuleTrigger, SubFormFieldsPerDocumentBase, SubFormFieldsPerDocumentCheckbox, SubFormFieldsPerDocumentCheckboxMerge, SubFormFieldsPerDocumentDateSigned, SubFormFieldsPerDocumentDropdown, SubFormFieldsPerDocumentFontEnum, SubFormFieldsPerDocumentHyperlink, SubFormFieldsPerDocumentInitials, SubFormFieldsPerDocumentRadio, SubFormFieldsPerDocumentSignature, SubFormFieldsPerDocumentText, SubFormFieldsPerDocumentTextMerge, SubFormFieldsPerDocumentTypeEnum, SubMergeField, SubOAuth, SubOptions, SubSignatureRequestGroupedSigners, SubSignatureRequestSigner, SubSignatureRequestTemplateSigner, SubSigningOptions, SubTeamResponse, SubTemplateRole, SubUnclaimedDraftSigner, SubUnclaimedDraftTemplateSigner, SubWhiteLabelingOptions, TeamAddMemberRequest, TeamCreateRequest, TeamGetInfoResponse, TeamGetResponse, TeamInfoResponse, TeamInviteResponse, TeamInvitesResponse, TeamMemberResponse, TeamMembersResponse, TeamParentResponse, TeamRemoveMemberRequest, TeamResponse, TeamSubTeamsResponse, TeamUpdateRequest, TemplateAddUserRequest, TemplateCreateEmbeddedDraftRequest, TemplateCreateEmbeddedDraftResponse, TemplateCreateEmbeddedDraftResponseTemplate, TemplateCreateRequest, TemplateCreateResponse, TemplateCreateResponseTemplate, TemplateEditResponse, TemplateGetResponse, TemplateListResponse, TemplateRemoveUserRequest, TemplateResponse, TemplateResponseAccount, TemplateResponseAccountQuota, TemplateResponseCCRole, TemplateResponseDocument, TemplateResponseDocumentCustomFieldBase, TemplateResponseDocumentCustomFieldCheckbox, TemplateResponseDocumentCustomFieldText, TemplateResponseDocumentFieldGroup, TemplateResponseDocumentFieldGroupRule, TemplateResponseDocumentFormFieldBase, TemplateResponseDocumentFormFieldCheckbox, TemplateResponseDocumentFormFieldDateSigned, TemplateResponseDocumentFormFieldDropdown, TemplateResponseDocumentFormFieldHyperlink, TemplateResponseDocumentFormFieldInitials, TemplateResponseDocumentFormFieldRadio, TemplateResponseDocumentFormFieldSignature, TemplateResponseDocumentFormFieldText, TemplateResponseDocumentStaticFieldBase, TemplateResponseDocumentStaticFieldCheckbox, TemplateResponseDocumentStaticFieldDateSigned, TemplateResponseDocumentStaticFieldDropdown, TemplateResponseDocumentStaticFieldHyperlink, TemplateResponseDocumentStaticFieldInitials, TemplateResponseDocumentStaticFieldRadio, TemplateResponseDocumentStaticFieldSignature, TemplateResponseDocumentStaticFieldText, TemplateResponseFieldAvgTextLength, TemplateResponseSignerRole, TemplateUpdateFilesRequest, TemplateUpdateFilesResponse, TemplateUpdateFilesResponseTemplate, UnclaimedDraftCreateEmbeddedRequest, UnclaimedDraftCreateEmbeddedWithTemplateRequest, UnclaimedDraftCreateRequest, UnclaimedDraftCreateResponse, UnclaimedDraftEditAndResendRequest, UnclaimedDraftResponse, WarningResponse, EventCallbackHelper, RequestDetailedFile, RequestFile, AttributeTypeMap, ObjectSerializer, Authentication, HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, VoidAuth, Interceptor, }; +export { AccountCreateRequest, AccountCreateResponse, AccountGetResponse, AccountResponse, AccountResponseQuotas, AccountResponseUsage, AccountUpdateRequest, AccountVerifyRequest, AccountVerifyResponse, AccountVerifyResponseAccount, ApiAppCreateRequest, ApiAppGetResponse, ApiAppListResponse, ApiAppResponse, ApiAppResponseOAuth, ApiAppResponseOptions, ApiAppResponseOwnerAccount, ApiAppResponseWhiteLabelingOptions, ApiAppUpdateRequest, BulkSendJobGetResponse, BulkSendJobGetResponseSignatureRequests, BulkSendJobListResponse, BulkSendJobResponse, BulkSendJobSendResponse, EmbeddedEditUrlRequest, EmbeddedEditUrlResponse, EmbeddedEditUrlResponseEmbedded, EmbeddedSignUrlResponse, EmbeddedSignUrlResponseEmbedded, ErrorResponse, ErrorResponseError, EventCallbackRequest, EventCallbackRequestEvent, EventCallbackRequestEventMetadata, FaxLineAddUserRequest, FaxLineAreaCodeGetCountryEnum, FaxLineAreaCodeGetProvinceEnum, FaxLineAreaCodeGetResponse, FaxLineAreaCodeGetStateEnum, FaxLineCreateRequest, FaxLineDeleteRequest, FaxLineListResponse, FaxLineRemoveUserRequest, FaxLineResponse, FaxLineResponseFaxLine, FileResponse, FileResponseDataUri, ListInfoResponse, OAuthTokenGenerateRequest, OAuthTokenRefreshRequest, OAuthTokenResponse, ReportCreateRequest, ReportCreateResponse, ReportResponse, SignatureRequestBulkCreateEmbeddedWithTemplateRequest, SignatureRequestBulkSendWithTemplateRequest, SignatureRequestCreateEmbeddedRequest, SignatureRequestCreateEmbeddedWithTemplateRequest, SignatureRequestGetResponse, SignatureRequestListResponse, SignatureRequestRemindRequest, SignatureRequestResponse, SignatureRequestResponseAttachment, SignatureRequestResponseCustomFieldBase, SignatureRequestResponseCustomFieldCheckbox, SignatureRequestResponseCustomFieldText, SignatureRequestResponseCustomFieldTypeEnum, SignatureRequestResponseDataBase, SignatureRequestResponseDataTypeEnum, SignatureRequestResponseDataValueCheckbox, SignatureRequestResponseDataValueCheckboxMerge, SignatureRequestResponseDataValueDateSigned, SignatureRequestResponseDataValueDropdown, SignatureRequestResponseDataValueInitials, SignatureRequestResponseDataValueRadio, SignatureRequestResponseDataValueSignature, SignatureRequestResponseDataValueText, SignatureRequestResponseDataValueTextMerge, SignatureRequestResponseSignatures, SignatureRequestSendRequest, SignatureRequestSendWithTemplateRequest, SignatureRequestUpdateRequest, SubAttachment, SubBulkSignerList, SubBulkSignerListCustomField, SubCC, SubCustomField, SubEditorOptions, SubFieldOptions, SubFormFieldGroup, SubFormFieldRule, SubFormFieldRuleAction, SubFormFieldRuleTrigger, SubFormFieldsPerDocumentBase, SubFormFieldsPerDocumentCheckbox, SubFormFieldsPerDocumentCheckboxMerge, SubFormFieldsPerDocumentDateSigned, SubFormFieldsPerDocumentDropdown, SubFormFieldsPerDocumentFontEnum, SubFormFieldsPerDocumentHyperlink, SubFormFieldsPerDocumentInitials, SubFormFieldsPerDocumentRadio, SubFormFieldsPerDocumentSignature, SubFormFieldsPerDocumentText, SubFormFieldsPerDocumentTextMerge, SubFormFieldsPerDocumentTypeEnum, SubMergeField, SubOAuth, SubOptions, SubSignatureRequestGroupedSigners, SubSignatureRequestSigner, SubSignatureRequestTemplateSigner, SubSigningOptions, SubTeamResponse, SubTemplateRole, SubUnclaimedDraftSigner, SubUnclaimedDraftTemplateSigner, SubWhiteLabelingOptions, TeamAddMemberRequest, TeamCreateRequest, TeamGetInfoResponse, TeamGetResponse, TeamInfoResponse, TeamInviteResponse, TeamInvitesResponse, TeamMemberResponse, TeamMembersResponse, TeamParentResponse, TeamRemoveMemberRequest, TeamResponse, TeamSubTeamsResponse, TeamUpdateRequest, TemplateAddUserRequest, TemplateCreateEmbeddedDraftRequest, TemplateCreateEmbeddedDraftResponse, TemplateCreateEmbeddedDraftResponseTemplate, TemplateCreateRequest, TemplateCreateResponse, TemplateCreateResponseTemplate, TemplateEditResponse, TemplateGetResponse, TemplateListResponse, TemplateRemoveUserRequest, TemplateResponse, TemplateResponseAccount, TemplateResponseAccountQuota, TemplateResponseCCRole, TemplateResponseDocument, TemplateResponseDocumentCustomFieldBase, TemplateResponseDocumentCustomFieldCheckbox, TemplateResponseDocumentCustomFieldText, TemplateResponseDocumentFieldGroup, TemplateResponseDocumentFieldGroupRule, TemplateResponseDocumentFormFieldBase, TemplateResponseDocumentFormFieldCheckbox, TemplateResponseDocumentFormFieldDateSigned, TemplateResponseDocumentFormFieldDropdown, TemplateResponseDocumentFormFieldHyperlink, TemplateResponseDocumentFormFieldInitials, TemplateResponseDocumentFormFieldRadio, TemplateResponseDocumentFormFieldSignature, TemplateResponseDocumentFormFieldText, TemplateResponseDocumentStaticFieldBase, TemplateResponseDocumentStaticFieldCheckbox, TemplateResponseDocumentStaticFieldDateSigned, TemplateResponseDocumentStaticFieldDropdown, TemplateResponseDocumentStaticFieldHyperlink, TemplateResponseDocumentStaticFieldInitials, TemplateResponseDocumentStaticFieldRadio, TemplateResponseDocumentStaticFieldSignature, TemplateResponseDocumentStaticFieldText, TemplateResponseFieldAvgTextLength, TemplateResponseSignerRole, TemplateUpdateFilesRequest, TemplateUpdateFilesResponse, TemplateUpdateFilesResponseTemplate, UnclaimedDraftCreateEmbeddedRequest, UnclaimedDraftCreateEmbeddedWithTemplateRequest, UnclaimedDraftCreateRequest, UnclaimedDraftCreateResponse, UnclaimedDraftEditAndResendRequest, UnclaimedDraftResponse, WarningResponse, EventCallbackHelper, RequestDetailedFile, RequestFile, AttributeTypeMap, ObjectSerializer, Authentication, HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, VoidAuth, Interceptor, }; diff --git a/sdks/php/README.md b/sdks/php/README.md index 906197b6b..f694462fa 100644 --- a/sdks/php/README.md +++ b/sdks/php/README.md @@ -160,13 +160,13 @@ All URIs are relative to *https://api.hellosign.com/v3* | *BulkSendJobApi* | [**bulkSendJobList**](docs/Api/BulkSendJobApi.md#bulksendjoblist) | **GET** /bulk_send_job/list | List Bulk Send Jobs | | *EmbeddedApi* | [**embeddedEditUrl**](docs/Api/EmbeddedApi.md#embeddedediturl) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL | | *EmbeddedApi* | [**embeddedSignUrl**](docs/Api/EmbeddedApi.md#embeddedsignurl) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL | -| *FaxLineApi* | [**faxLineAddUser**](docs/Api/FaxLineApi.md#faxlineadduser) | **POST** /fax_line/add_user | Add Fax Line User | +| *FaxLineApi* | [**faxLineAddUser**](docs/Api/FaxLineApi.md#faxlineadduser) | **PUT** /fax_line/add_user | Add Fax Line User | | *FaxLineApi* | [**faxLineAreaCodeGet**](docs/Api/FaxLineApi.md#faxlineareacodeget) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | *FaxLineApi* | [**faxLineCreate**](docs/Api/FaxLineApi.md#faxlinecreate) | **POST** /fax_line/create | Purchase Fax Line | | *FaxLineApi* | [**faxLineDelete**](docs/Api/FaxLineApi.md#faxlinedelete) | **DELETE** /fax_line | Delete Fax Line | | *FaxLineApi* | [**faxLineGet**](docs/Api/FaxLineApi.md#faxlineget) | **GET** /fax_line | Get Fax Line | | *FaxLineApi* | [**faxLineList**](docs/Api/FaxLineApi.md#faxlinelist) | **GET** /fax_line/list | List Fax Lines | -| *FaxLineApi* | [**faxLineRemoveUser**](docs/Api/FaxLineApi.md#faxlineremoveuser) | **POST** /fax_line/remove_user | Remove Fax Line Access | +| *FaxLineApi* | [**faxLineRemoveUser**](docs/Api/FaxLineApi.md#faxlineremoveuser) | **PUT** /fax_line/remove_user | Remove Fax Line Access | | *OAuthApi* | [**oauthTokenGenerate**](docs/Api/OAuthApi.md#oauthtokengenerate) | **POST** /oauth/token | OAuth Token Generate | | *OAuthApi* | [**oauthTokenRefresh**](docs/Api/OAuthApi.md#oauthtokenrefresh) | **POST** /oauth/token?refresh | OAuth Token Refresh | | *ReportApi* | [**reportCreate**](docs/Api/ReportApi.md#reportcreate) | **POST** /report/create | Create Report | @@ -248,7 +248,6 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](docs/Model/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/Model/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/Model/EventCallbackRequestEventMetadata.md) -- [FaxLine](docs/Model/FaxLine.md) - [FaxLineAddUserRequest](docs/Model/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/Model/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/Model/FaxLineAreaCodeGetProvinceEnum.md) @@ -259,6 +258,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [FaxLineListResponse](docs/Model/FaxLineListResponse.md) - [FaxLineRemoveUserRequest](docs/Model/FaxLineRemoveUserRequest.md) - [FaxLineResponse](docs/Model/FaxLineResponse.md) +- [FaxLineResponseFaxLine](docs/Model/FaxLineResponseFaxLine.md) - [FileResponse](docs/Model/FileResponse.md) - [FileResponseDataUri](docs/Model/FileResponseDataUri.md) - [ListInfoResponse](docs/Model/ListInfoResponse.md) diff --git a/sdks/php/docs/Api/FaxLineApi.md b/sdks/php/docs/Api/FaxLineApi.md index b6c4e85e5..677d605e9 100644 --- a/sdks/php/docs/Api/FaxLineApi.md +++ b/sdks/php/docs/Api/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to https://api.hellosign.com/v3. | Method | HTTP request | Description | | ------------- | ------------- | ------------- | -| [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **POST** /fax_line/add_user | Add Fax Line User | +| [**faxLineAddUser()**](FaxLineApi.md#faxLineAddUser) | **PUT** /fax_line/add_user | Add Fax Line User | | [**faxLineAreaCodeGet()**](FaxLineApi.md#faxLineAreaCodeGet) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | | [**faxLineCreate()**](FaxLineApi.md#faxLineCreate) | **POST** /fax_line/create | Purchase Fax Line | | [**faxLineDelete()**](FaxLineApi.md#faxLineDelete) | **DELETE** /fax_line | Delete Fax Line | | [**faxLineGet()**](FaxLineApi.md#faxLineGet) | **GET** /fax_line | Get Fax Line | | [**faxLineList()**](FaxLineApi.md#faxLineList) | **GET** /fax_line/list | List Fax Lines | -| [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **POST** /fax_line/remove_user | Remove Fax Line Access | +| [**faxLineRemoveUser()**](FaxLineApi.md#faxLineRemoveUser) | **PUT** /fax_line/remove_user | Remove Fax Line Access | ## `faxLineAddUser()` @@ -161,7 +161,7 @@ $config->setUsername("YOUR_API_KEY"); $faxLineApi = new Dropbox\Sign\Api\FaxLineApi($config); $data = new Dropbox\Sign\Model\FaxLineCreateRequest(); -$data->setAreaCode("209") +$data->setAreaCode(209) ->setCountry("US"); try { @@ -226,8 +226,7 @@ $data = new Dropbox\Sign\Model\FaxLineDeleteRequest(); $data->setNumber("[FAX_NUMBER]"); try { - $result = $faxLineApi->faxLineDelete($data); - print_r($result); + $faxLineApi->faxLineDelete($data); } catch (Dropbox\Sign\ApiException $e) { $error = $e->getResponseObject(); echo "Exception when calling Dropbox Sign API: " @@ -357,8 +356,8 @@ try { |Name | Type | Description | Notes | | ------------- | ------------- | ------------- | ------------- | | **account_id** | **string**| Account ID | [optional] | -| **page** | **int**| Page | [optional] | -| **page_size** | **int**| Page size | [optional] | +| **page** | **int**| Page | [optional] [default to 1] | +| **page_size** | **int**| Page size | [optional] [default to 20] | | **show_team_lines** | **bool**| Show team lines | [optional] | ### Return type diff --git a/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md b/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md index 343e96799..2275a4f8e 100644 --- a/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md +++ b/sdks/php/docs/Model/FaxLineAreaCodeGetResponse.md @@ -6,6 +6,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `area_codes` | ```string[]``` | | | +| `area_codes` | ```int[]``` | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineCreateRequest.md b/sdks/php/docs/Model/FaxLineCreateRequest.md index cf77cab4b..6b599a339 100644 --- a/sdks/php/docs/Model/FaxLineCreateRequest.md +++ b/sdks/php/docs/Model/FaxLineCreateRequest.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `area_code`*_required_ | ```string``` | Area code | | +| `area_code`*_required_ | ```int``` | Area code | | | `country`*_required_ | ```string``` | Country | | | `city` | ```string``` | City | | | `account_id` | ```string``` | Account ID | | diff --git a/sdks/php/docs/Model/FaxLineListResponse.md b/sdks/php/docs/Model/FaxLineListResponse.md index 64fa947cd..c9aef89c1 100644 --- a/sdks/php/docs/Model/FaxLineListResponse.md +++ b/sdks/php/docs/Model/FaxLineListResponse.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `list_info` | [```\Dropbox\Sign\Model\ListInfoResponse```](ListInfoResponse.md) | | | -| `fax_lines` | [```\Dropbox\Sign\Model\FaxLine[]```](FaxLine.md) | | | +| `fax_lines` | [```\Dropbox\Sign\Model\FaxLineResponseFaxLine[]```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```\Dropbox\Sign\Model\WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLineResponse.md b/sdks/php/docs/Model/FaxLineResponse.md index f459c42e7..8a62eefff 100644 --- a/sdks/php/docs/Model/FaxLineResponse.md +++ b/sdks/php/docs/Model/FaxLineResponse.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -| `fax_line` | [```\Dropbox\Sign\Model\FaxLine```](FaxLine.md) | | | +| `fax_line` | [```\Dropbox\Sign\Model\FaxLineResponseFaxLine```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```\Dropbox\Sign\Model\WarningResponse```](WarningResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/docs/Model/FaxLine.md b/sdks/php/docs/Model/FaxLineResponseFaxLine.md similarity index 75% rename from sdks/php/docs/Model/FaxLine.md rename to sdks/php/docs/Model/FaxLineResponseFaxLine.md index 222fdd4cf..51f479adc 100644 --- a/sdks/php/docs/Model/FaxLine.md +++ b/sdks/php/docs/Model/FaxLineResponseFaxLine.md @@ -1,4 +1,4 @@ -# # FaxLine +# # FaxLineResponseFaxLine @@ -7,8 +7,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- | `number` | ```string``` | Number | | -| `created_at` | ```string``` | Created at | | -| `updated_at` | ```string``` | Updated at | | +| `created_at` | ```int``` | Created at | | +| `updated_at` | ```int``` | Updated at | | | `accounts` | [```\Dropbox\Sign\Model\AccountResponse[]```](AccountResponse.md) | | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/sdks/php/src/Api/FaxLineApi.php b/sdks/php/src/Api/FaxLineApi.php index f94e189a5..11a334e0e 100644 --- a/sdks/php/src/Api/FaxLineApi.php +++ b/sdks/php/src/Api/FaxLineApi.php @@ -436,7 +436,7 @@ public function faxLineAddUserRequest(Model\FaxLineAddUserRequest $fax_line_add_ $query = Psr7\Query::build($queryParams); return new Psr7\Request( - 'POST', + 'PUT', $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), $headers, $httpBody @@ -1682,15 +1682,15 @@ public function faxLineGetRequest(string $number) * List Fax Lines * * @param string $account_id Account ID (optional) - * @param int $page Page (optional) - * @param int $page_size Page size (optional) + * @param int $page Page (optional, default to 1) + * @param int $page_size Page size (optional, default to 20) * @param bool $show_team_lines Show team lines (optional) * * @throws ApiException on non-2xx response * @throws InvalidArgumentException * @return Model\FaxLineListResponse */ - public function faxLineList(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + public function faxLineList(string $account_id = null, int $page = 1, int $page_size = 20, bool $show_team_lines = null) { list($response) = $this->faxLineListWithHttpInfo($account_id, $page, $page_size, $show_team_lines); @@ -1703,15 +1703,15 @@ public function faxLineList(string $account_id = null, int $page = null, int $pa * List Fax Lines * * @param string $account_id Account ID (optional) - * @param int $page Page (optional) - * @param int $page_size Page size (optional) + * @param int $page Page (optional, default to 1) + * @param int $page_size Page size (optional, default to 20) * @param bool $show_team_lines Show team lines (optional) * * @throws ApiException on non-2xx response * @throws InvalidArgumentException * @return array of Model\FaxLineListResponse, HTTP status code, HTTP response headers (array of strings) */ - public function faxLineListWithHttpInfo(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + public function faxLineListWithHttpInfo(string $account_id = null, int $page = 1, int $page_size = 20, bool $show_team_lines = null) { $request = $this->faxLineListRequest($account_id, $page, $page_size, $show_team_lines); @@ -1828,14 +1828,14 @@ public function faxLineListWithHttpInfo(string $account_id = null, int $page = n * List Fax Lines * * @param string $account_id Account ID (optional) - * @param int $page Page (optional) - * @param int $page_size Page size (optional) + * @param int $page Page (optional, default to 1) + * @param int $page_size Page size (optional, default to 20) * @param bool $show_team_lines Show team lines (optional) * * @throws InvalidArgumentException * @return Promise\PromiseInterface */ - public function faxLineListAsync(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + public function faxLineListAsync(string $account_id = null, int $page = 1, int $page_size = 20, bool $show_team_lines = null) { return $this->faxLineListAsyncWithHttpInfo($account_id, $page, $page_size, $show_team_lines) ->then( @@ -1851,14 +1851,14 @@ function ($response) { * List Fax Lines * * @param string $account_id Account ID (optional) - * @param int $page Page (optional) - * @param int $page_size Page size (optional) + * @param int $page Page (optional, default to 1) + * @param int $page_size Page size (optional, default to 20) * @param bool $show_team_lines Show team lines (optional) * * @throws InvalidArgumentException * @return Promise\PromiseInterface */ - public function faxLineListAsyncWithHttpInfo(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + public function faxLineListAsyncWithHttpInfo(string $account_id = null, int $page = 1, int $page_size = 20, bool $show_team_lines = null) { $returnType = '\Dropbox\Sign\Model\FaxLineListResponse'; $request = $this->faxLineListRequest($account_id, $page, $page_size, $show_team_lines); @@ -1900,14 +1900,14 @@ function ($exception) { * Create request for operation 'faxLineList' * * @param string $account_id Account ID (optional) - * @param int $page Page (optional) - * @param int $page_size Page size (optional) + * @param int $page Page (optional, default to 1) + * @param int $page_size Page size (optional, default to 20) * @param bool $show_team_lines Show team lines (optional) * * @throws InvalidArgumentException * @return Psr7\Request */ - public function faxLineListRequest(string $account_id = null, int $page = null, int $page_size = null, bool $show_team_lines = null) + public function faxLineListRequest(string $account_id = null, int $page = 1, int $page_size = 20, bool $show_team_lines = null) { $resourcePath = '/fax_line/list'; $queryParams = []; @@ -2333,7 +2333,7 @@ public function faxLineRemoveUserRequest(Model\FaxLineRemoveUserRequest $fax_lin $query = Psr7\Query::build($queryParams); return new Psr7\Request( - 'POST', + 'PUT', $this->config->getHost() . $resourcePath . ($query ? "?{$query}" : ''), $headers, $httpBody diff --git a/sdks/php/src/Model/FaxLineAreaCodeGetResponse.php b/sdks/php/src/Model/FaxLineAreaCodeGetResponse.php index 256a6e0ff..502d55db5 100644 --- a/sdks/php/src/Model/FaxLineAreaCodeGetResponse.php +++ b/sdks/php/src/Model/FaxLineAreaCodeGetResponse.php @@ -61,7 +61,7 @@ class FaxLineAreaCodeGetResponse implements ModelInterface, ArrayAccess, JsonSer * @var string[] */ protected static $openAPITypes = [ - 'area_codes' => 'string[]', + 'area_codes' => 'int[]', ]; /** @@ -226,7 +226,7 @@ public function valid() /** * Gets area_codes * - * @return string[]|null + * @return int[]|null */ public function getAreaCodes() { @@ -236,7 +236,7 @@ public function getAreaCodes() /** * Sets area_codes * - * @param string[]|null $area_codes area_codes + * @param int[]|null $area_codes area_codes * * @return self */ diff --git a/sdks/php/src/Model/FaxLineCreateRequest.php b/sdks/php/src/Model/FaxLineCreateRequest.php index 610690560..cda0fe017 100644 --- a/sdks/php/src/Model/FaxLineCreateRequest.php +++ b/sdks/php/src/Model/FaxLineCreateRequest.php @@ -61,7 +61,7 @@ class FaxLineCreateRequest implements ModelInterface, ArrayAccess, JsonSerializa * @var string[] */ protected static $openAPITypes = [ - 'area_code' => 'string', + 'area_code' => 'int', 'country' => 'string', 'city' => 'string', 'account_id' => 'string', @@ -277,7 +277,7 @@ public function valid() /** * Gets area_code * - * @return string + * @return int */ public function getAreaCode() { @@ -287,11 +287,11 @@ public function getAreaCode() /** * Sets area_code * - * @param string $area_code Area code + * @param int $area_code Area code * * @return self */ - public function setAreaCode(string $area_code) + public function setAreaCode(int $area_code) { $this->container['area_code'] = $area_code; diff --git a/sdks/php/src/Model/FaxLineListResponse.php b/sdks/php/src/Model/FaxLineListResponse.php index cfd50e5d1..18c13f69c 100644 --- a/sdks/php/src/Model/FaxLineListResponse.php +++ b/sdks/php/src/Model/FaxLineListResponse.php @@ -62,7 +62,7 @@ class FaxLineListResponse implements ModelInterface, ArrayAccess, JsonSerializab */ protected static $openAPITypes = [ 'list_info' => '\Dropbox\Sign\Model\ListInfoResponse', - 'fax_lines' => '\Dropbox\Sign\Model\FaxLine[]', + 'fax_lines' => '\Dropbox\Sign\Model\FaxLineResponseFaxLine[]', 'warnings' => '\Dropbox\Sign\Model\WarningResponse', ]; @@ -262,7 +262,7 @@ public function setListInfo(?ListInfoResponse $list_info) /** * Gets fax_lines * - * @return FaxLine[]|null + * @return FaxLineResponseFaxLine[]|null */ public function getFaxLines() { @@ -272,7 +272,7 @@ public function getFaxLines() /** * Sets fax_lines * - * @param FaxLine[]|null $fax_lines fax_lines + * @param FaxLineResponseFaxLine[]|null $fax_lines fax_lines * * @return self */ diff --git a/sdks/php/src/Model/FaxLineResponse.php b/sdks/php/src/Model/FaxLineResponse.php index f86a2f239..f8676d7b0 100644 --- a/sdks/php/src/Model/FaxLineResponse.php +++ b/sdks/php/src/Model/FaxLineResponse.php @@ -61,7 +61,7 @@ class FaxLineResponse implements ModelInterface, ArrayAccess, JsonSerializable * @var string[] */ protected static $openAPITypes = [ - 'fax_line' => '\Dropbox\Sign\Model\FaxLine', + 'fax_line' => '\Dropbox\Sign\Model\FaxLineResponseFaxLine', 'warnings' => '\Dropbox\Sign\Model\WarningResponse', ]; @@ -232,7 +232,7 @@ public function valid() /** * Gets fax_line * - * @return FaxLine|null + * @return FaxLineResponseFaxLine|null */ public function getFaxLine() { @@ -242,11 +242,11 @@ public function getFaxLine() /** * Sets fax_line * - * @param FaxLine|null $fax_line fax_line + * @param FaxLineResponseFaxLine|null $fax_line fax_line * * @return self */ - public function setFaxLine(?FaxLine $fax_line) + public function setFaxLine(?FaxLineResponseFaxLine $fax_line) { $this->container['fax_line'] = $fax_line; diff --git a/sdks/php/src/Model/FaxLine.php b/sdks/php/src/Model/FaxLineResponseFaxLine.php similarity index 91% rename from sdks/php/src/Model/FaxLine.php rename to sdks/php/src/Model/FaxLineResponseFaxLine.php index af17884c2..6ccc2ddf5 100644 --- a/sdks/php/src/Model/FaxLine.php +++ b/sdks/php/src/Model/FaxLineResponseFaxLine.php @@ -1,6 +1,6 @@ * @template TKey int|null * @template TValue mixed|null + * @internal This class should not be instantiated directly */ -class FaxLine implements ModelInterface, ArrayAccess, JsonSerializable +class FaxLineResponseFaxLine implements ModelInterface, ArrayAccess, JsonSerializable { public const DISCRIMINATOR = null; @@ -52,7 +53,7 @@ class FaxLine implements ModelInterface, ArrayAccess, JsonSerializable * * @var string */ - protected static $openAPIModelName = 'FaxLine'; + protected static $openAPIModelName = 'FaxLineResponseFaxLine'; /** * Array of property to type mappings. Used for (de)serialization @@ -61,8 +62,8 @@ class FaxLine implements ModelInterface, ArrayAccess, JsonSerializable */ protected static $openAPITypes = [ 'number' => 'string', - 'created_at' => 'string', - 'updated_at' => 'string', + 'created_at' => 'int', + 'updated_at' => 'int', 'accounts' => '\Dropbox\Sign\Model\AccountResponse[]', ]; @@ -200,18 +201,18 @@ public function __construct(array $data = null) } /** @deprecated use ::init() */ - public static function fromArray(array $data): FaxLine + public static function fromArray(array $data): FaxLineResponseFaxLine { return self::init($data); } /** Attempt to instantiate and hydrate a new instance of this class */ - public static function init(array $data): FaxLine + public static function init(array $data): FaxLineResponseFaxLine { - /** @var FaxLine $obj */ + /** @var FaxLineResponseFaxLine $obj */ $obj = ObjectSerializer::deserialize( $data, - FaxLine::class, + FaxLineResponseFaxLine::class, ); return $obj; @@ -267,7 +268,7 @@ public function setNumber(?string $number) /** * Gets created_at * - * @return string|null + * @return int|null */ public function getCreatedAt() { @@ -277,11 +278,11 @@ public function getCreatedAt() /** * Sets created_at * - * @param string|null $created_at Created at + * @param int|null $created_at Created at * * @return self */ - public function setCreatedAt(?string $created_at) + public function setCreatedAt(?int $created_at) { $this->container['created_at'] = $created_at; @@ -291,7 +292,7 @@ public function setCreatedAt(?string $created_at) /** * Gets updated_at * - * @return string|null + * @return int|null */ public function getUpdatedAt() { @@ -301,11 +302,11 @@ public function getUpdatedAt() /** * Sets updated_at * - * @param string|null $updated_at Updated at + * @param int|null $updated_at Updated at * * @return self */ - public function setUpdatedAt(?string $updated_at) + public function setUpdatedAt(?int $updated_at) { $this->container['updated_at'] = $updated_at; diff --git a/sdks/python/.openapi-generator/FILES b/sdks/python/.openapi-generator/FILES index d54146f59..8dc4861d9 100644 --- a/sdks/python/.openapi-generator/FILES +++ b/sdks/python/.openapi-generator/FILES @@ -41,7 +41,6 @@ docs/ErrorResponseError.md docs/EventCallbackRequest.md docs/EventCallbackRequestEvent.md docs/EventCallbackRequestEventMetadata.md -docs/FaxLine.md docs/FaxLineAddUserRequest.md docs/FaxLineApi.md docs/FaxLineAreaCodeGetCountryEnum.md @@ -53,6 +52,7 @@ docs/FaxLineDeleteRequest.md docs/FaxLineListResponse.md docs/FaxLineRemoveUserRequest.md docs/FaxLineResponse.md +docs/FaxLineResponseFaxLine.md docs/FileResponse.md docs/FileResponseDataUri.md docs/ListInfoResponse.md @@ -250,7 +250,6 @@ dropbox_sign/model/error_response_error.py dropbox_sign/model/event_callback_request.py dropbox_sign/model/event_callback_request_event.py dropbox_sign/model/event_callback_request_event_metadata.py -dropbox_sign/model/fax_line.py dropbox_sign/model/fax_line_add_user_request.py dropbox_sign/model/fax_line_area_code_get_country_enum.py dropbox_sign/model/fax_line_area_code_get_province_enum.py @@ -261,6 +260,7 @@ dropbox_sign/model/fax_line_delete_request.py dropbox_sign/model/fax_line_list_response.py dropbox_sign/model/fax_line_remove_user_request.py dropbox_sign/model/fax_line_response.py +dropbox_sign/model/fax_line_response_fax_line.py dropbox_sign/model/file_response.py dropbox_sign/model/file_response_data_uri.py dropbox_sign/model/list_info_response.py diff --git a/sdks/python/README.md b/sdks/python/README.md index ebdc211ac..8897d3033 100644 --- a/sdks/python/README.md +++ b/sdks/python/README.md @@ -118,13 +118,13 @@ All URIs are relative to *https://api.hellosign.com/v3* ```BulkSendJobApi``` | [```bulk_send_job_list```](docs/BulkSendJobApi.md#bulk_send_job_list) | ```GET /bulk_send_job/list``` | List Bulk Send Jobs| |```EmbeddedApi``` | [```embedded_edit_url```](docs/EmbeddedApi.md#embedded_edit_url) | ```POST /embedded/edit_url/{template_id}``` | Get Embedded Template Edit URL| ```EmbeddedApi``` | [```embedded_sign_url```](docs/EmbeddedApi.md#embedded_sign_url) | ```GET /embedded/sign_url/{signature_id}``` | Get Embedded Sign URL| -|```FaxLineApi``` | [```fax_line_add_user```](docs/FaxLineApi.md#fax_line_add_user) | ```POST /fax_line/add_user``` | Add Fax Line User| +|```FaxLineApi``` | [```fax_line_add_user```](docs/FaxLineApi.md#fax_line_add_user) | ```PUT /fax_line/add_user``` | Add Fax Line User| ```FaxLineApi``` | [```fax_line_area_code_get```](docs/FaxLineApi.md#fax_line_area_code_get) | ```GET /fax_line/area_codes``` | Get Available Fax Line Area Codes| ```FaxLineApi``` | [```fax_line_create```](docs/FaxLineApi.md#fax_line_create) | ```POST /fax_line/create``` | Purchase Fax Line| ```FaxLineApi``` | [```fax_line_delete```](docs/FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line``` | Delete Fax Line| ```FaxLineApi``` | [```fax_line_get```](docs/FaxLineApi.md#fax_line_get) | ```GET /fax_line``` | Get Fax Line| ```FaxLineApi``` | [```fax_line_list```](docs/FaxLineApi.md#fax_line_list) | ```GET /fax_line/list``` | List Fax Lines| -```FaxLineApi``` | [```fax_line_remove_user```](docs/FaxLineApi.md#fax_line_remove_user) | ```POST /fax_line/remove_user``` | Remove Fax Line Access| +```FaxLineApi``` | [```fax_line_remove_user```](docs/FaxLineApi.md#fax_line_remove_user) | ```PUT /fax_line/remove_user``` | Remove Fax Line Access| |```OAuthApi``` | [```oauth_token_generate```](docs/OAuthApi.md#oauth_token_generate) | ```POST /oauth/token``` | OAuth Token Generate| ```OAuthApi``` | [```oauth_token_refresh```](docs/OAuthApi.md#oauth_token_refresh) | ```POST /oauth/token?refresh``` | OAuth Token Refresh| |```ReportApi``` | [```report_create```](docs/ReportApi.md#report_create) | ```POST /report/create``` | Create Report| @@ -207,7 +207,6 @@ All URIs are relative to *https://api.hellosign.com/v3* - [EventCallbackRequest](docs/EventCallbackRequest.md) - [EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) - - [FaxLine](docs/FaxLine.md) - [FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) @@ -218,6 +217,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [FaxLineListResponse](docs/FaxLineListResponse.md) - [FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) - [FaxLineResponse](docs/FaxLineResponse.md) + - [FaxLineResponseFaxLine](docs/FaxLineResponseFaxLine.md) - [FileResponse](docs/FileResponse.md) - [FileResponseDataUri](docs/FileResponseDataUri.md) - [ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/python/docs/FaxLineApi.md b/sdks/python/docs/FaxLineApi.md index 5481a04e3..028d5fe83 100644 --- a/sdks/python/docs/FaxLineApi.md +++ b/sdks/python/docs/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to *https://api.hellosign.com/v3* |Method | HTTP request | Description| |------------- | ------------- | -------------| -|[```fax_line_add_user```](FaxLineApi.md#fax_line_add_user) | ```POST /fax_line/add_user``` | Add Fax Line User| +|[```fax_line_add_user```](FaxLineApi.md#fax_line_add_user) | ```PUT /fax_line/add_user``` | Add Fax Line User| |[```fax_line_area_code_get```](FaxLineApi.md#fax_line_area_code_get) | ```GET /fax_line/area_codes``` | Get Available Fax Line Area Codes| |[```fax_line_create```](FaxLineApi.md#fax_line_create) | ```POST /fax_line/create``` | Purchase Fax Line| |[```fax_line_delete```](FaxLineApi.md#fax_line_delete) | ```DELETE /fax_line``` | Delete Fax Line| |[```fax_line_get```](FaxLineApi.md#fax_line_get) | ```GET /fax_line``` | Get Fax Line| |[```fax_line_list```](FaxLineApi.md#fax_line_list) | ```GET /fax_line/list``` | List Fax Lines| -|[```fax_line_remove_user```](FaxLineApi.md#fax_line_remove_user) | ```POST /fax_line/remove_user``` | Remove Fax Line Access| +|[```fax_line_remove_user```](FaxLineApi.md#fax_line_remove_user) | ```PUT /fax_line/remove_user``` | Remove Fax Line Access| # ```fax_line_add_user``` @@ -173,7 +173,7 @@ with ApiClient(configuration) as api_client: fax_line_api = apis.FaxLineApi(api_client) data = models.FaxLineCreateRequest( - area_code="209", + area_code=209, country="US", ) @@ -245,8 +245,7 @@ with ApiClient(configuration) as api_client: ) try: - response = fax_line_api.fax_line_delete(data) - pprint(response) + fax_line_api.fax_line_delete(data) except ApiException as e: print("Exception when calling Dropbox Sign API: %s\n" % e) @@ -384,8 +383,8 @@ with ApiClient(configuration) as api_client: | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `account_id` | **str** | Account ID | [optional] | -| `page` | **int** | Page | [optional] | -| `page_size` | **int** | Page size | [optional] | +| `page` | **int** | Page | [optional][default to 1] | +| `page_size` | **int** | Page size | [optional][default to 20] | | `show_team_lines` | **bool** | Show team lines | [optional] | ### Return type diff --git a/sdks/python/docs/FaxLineAreaCodeGetResponse.md b/sdks/python/docs/FaxLineAreaCodeGetResponse.md index 6b5b3dde7..f05c3ec36 100644 --- a/sdks/python/docs/FaxLineAreaCodeGetResponse.md +++ b/sdks/python/docs/FaxLineAreaCodeGetResponse.md @@ -6,7 +6,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `area_codes` | ```[str]``` | | | +| `area_codes` | ```[int]``` | | | [[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/sdks/python/docs/FaxLineCreateRequest.md b/sdks/python/docs/FaxLineCreateRequest.md index 8a44fbf70..75eda463d 100644 --- a/sdks/python/docs/FaxLineCreateRequest.md +++ b/sdks/python/docs/FaxLineCreateRequest.md @@ -6,7 +6,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `area_code`*_required_ | ```str``` | Area code | | +| `area_code`*_required_ | ```int``` | Area code | | | `country`*_required_ | ```str``` | Country | | | `city` | ```str``` | City | | | `account_id` | ```str``` | Account ID | | diff --git a/sdks/python/docs/FaxLineListResponse.md b/sdks/python/docs/FaxLineListResponse.md index 644f8073f..a4fecd5e1 100644 --- a/sdks/python/docs/FaxLineListResponse.md +++ b/sdks/python/docs/FaxLineListResponse.md @@ -7,7 +7,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `list_info` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `fax_lines` | [```[FaxLine]```](FaxLine.md) | | | +| `fax_lines` | [```[FaxLineResponseFaxLine]```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/python/docs/FaxLineResponse.md b/sdks/python/docs/FaxLineResponse.md index 07dc2589e..71128088c 100644 --- a/sdks/python/docs/FaxLineResponse.md +++ b/sdks/python/docs/FaxLineResponse.md @@ -6,7 +6,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `fax_line` | [```FaxLine```](FaxLine.md) | | | +| `fax_line` | [```FaxLineResponseFaxLine```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/python/docs/FaxLine.md b/sdks/python/docs/FaxLineResponseFaxLine.md similarity index 75% rename from sdks/python/docs/FaxLine.md rename to sdks/python/docs/FaxLineResponseFaxLine.md index dca4bb594..1eea506f9 100644 --- a/sdks/python/docs/FaxLine.md +++ b/sdks/python/docs/FaxLineResponseFaxLine.md @@ -1,4 +1,4 @@ -# FaxLine +# FaxLineResponseFaxLine @@ -7,8 +7,8 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `number` | ```str``` | Number | | -| `created_at` | ```str``` | Created at | | -| `updated_at` | ```str``` | Updated at | | +| `created_at` | ```int``` | Created at | | +| `updated_at` | ```int``` | Updated at | | | `accounts` | [```[AccountResponse]```](AccountResponse.md) | | | diff --git a/sdks/python/dropbox_sign/api/fax_line_api.py b/sdks/python/dropbox_sign/api/fax_line_api.py index b53ca7111..84e0d1b40 100644 --- a/sdks/python/dropbox_sign/api/fax_line_api.py +++ b/sdks/python/dropbox_sign/api/fax_line_api.py @@ -52,7 +52,7 @@ def __init__(self, api_client=None): ], 'endpoint_path': '/fax_line/add_user', 'operation_id': 'fax_line_add_user', - 'http_method': 'POST', + 'http_method': 'PUT', 'servers': None, }, params_map={ @@ -468,7 +468,7 @@ def __init__(self, api_client=None): ], 'endpoint_path': '/fax_line/remove_user', 'operation_id': 'fax_line_remove_user', - 'http_method': 'POST', + 'http_method': 'PUT', 'servers': None, }, params_map={ @@ -1010,8 +1010,8 @@ def fax_line_list( Keyword Args: account_id (str): Account ID. [optional] - page (int): Page. [optional] - page_size (int): Page size. [optional] + page (int): Page. [optional] if omitted the server will use the default value of 1 + page_size (int): Page size. [optional] if omitted the server will use the default value of 20 show_team_lines (bool): Show team lines. [optional] _return_http_data_only (bool): response data without head status code and headers. Default is True. diff --git a/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py b/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py index 4756b6580..d856d9e2c 100644 --- a/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py +++ b/sdks/python/dropbox_sign/model/fax_line_area_code_get_response.py @@ -86,7 +86,7 @@ def openapi_types(): and the value is attribute type. """ return { - 'area_codes': ([str],), # noqa: E501 + 'area_codes': ([int],), # noqa: E501 } @cached_property @@ -119,11 +119,11 @@ def init(data: any) -> FaxLineAreaCodeGetResponse: _composed_schemas = {} @property - def area_codes(self) -> List[str]: + def area_codes(self) -> List[int]: return self.get("area_codes") @area_codes.setter - def area_codes(self, value: List[str]): + def area_codes(self, value: List[int]): setattr(self, "area_codes", value) @classmethod @@ -162,7 +162,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) - area_codes ([str]): [optional] # noqa: E501 + area_codes ([int]): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -244,7 +244,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) - area_codes ([str]): [optional] # noqa: E501 + area_codes ([int]): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/sdks/python/dropbox_sign/model/fax_line_create_request.py b/sdks/python/dropbox_sign/model/fax_line_create_request.py index 0a8927996..6a0789680 100644 --- a/sdks/python/dropbox_sign/model/fax_line_create_request.py +++ b/sdks/python/dropbox_sign/model/fax_line_create_request.py @@ -91,7 +91,7 @@ def openapi_types(): and the value is attribute type. """ return { - 'area_code': (str,), # noqa: E501 + 'area_code': (int,), # noqa: E501 'country': (str,), # noqa: E501 'city': (str,), # noqa: E501 'account_id': (str,), # noqa: E501 @@ -130,11 +130,11 @@ def init(data: any) -> FaxLineCreateRequest: _composed_schemas = {} @property - def area_code(self) -> str: + def area_code(self) -> int: return self.get("area_code") @area_code.setter - def area_code(self, value: str): + def area_code(self, value: int): setattr(self, "area_code", value) @property @@ -167,7 +167,7 @@ def _from_openapi_data(cls, area_code, country, *args, **kwargs): # noqa: E501 """FaxLineCreateRequest - a model defined in OpenAPI Args: - area_code (str): Area code + area_code (int): Area code country (str): Country Keyword Args: @@ -256,7 +256,7 @@ def __init__(self, area_code, country, *args, **kwargs): # noqa: E501 """FaxLineCreateRequest - a model defined in OpenAPI Args: - area_code (str): Area code + area_code (int): Area code country (str): Country Keyword Args: diff --git a/sdks/python/dropbox_sign/model/fax_line_list_response.py b/sdks/python/dropbox_sign/model/fax_line_list_response.py index 9b28060aa..1bcac65d0 100644 --- a/sdks/python/dropbox_sign/model/fax_line_list_response.py +++ b/sdks/python/dropbox_sign/model/fax_line_list_response.py @@ -33,16 +33,16 @@ ) from dropbox_sign.exceptions import ApiAttributeError if TYPE_CHECKING: - from dropbox_sign.model.fax_line import FaxLine + from dropbox_sign.model.fax_line_response_fax_line import FaxLineResponseFaxLine from dropbox_sign.model.list_info_response import ListInfoResponse from dropbox_sign.model.warning_response import WarningResponse def lazy_import(): - from dropbox_sign.model.fax_line import FaxLine + from dropbox_sign.model.fax_line_response_fax_line import FaxLineResponseFaxLine from dropbox_sign.model.list_info_response import ListInfoResponse from dropbox_sign.model.warning_response import WarningResponse - globals()['FaxLine'] = FaxLine + globals()['FaxLineResponseFaxLine'] = FaxLineResponseFaxLine globals()['ListInfoResponse'] = ListInfoResponse globals()['WarningResponse'] = WarningResponse @@ -101,7 +101,7 @@ def openapi_types(): lazy_import() return { 'list_info': (ListInfoResponse,), # noqa: E501 - 'fax_lines': ([FaxLine],), # noqa: E501 + 'fax_lines': ([FaxLineResponseFaxLine],), # noqa: E501 'warnings': (WarningResponse,), # noqa: E501 } @@ -145,11 +145,11 @@ def list_info(self, value: ListInfoResponse): setattr(self, "list_info", value) @property - def fax_lines(self) -> List[FaxLine]: + def fax_lines(self) -> List[FaxLineResponseFaxLine]: return self.get("fax_lines") @fax_lines.setter - def fax_lines(self, value: List[FaxLine]): + def fax_lines(self, value: List[FaxLineResponseFaxLine]): setattr(self, "fax_lines", value) @property @@ -197,7 +197,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) list_info (ListInfoResponse): [optional] # noqa: E501 - fax_lines ([FaxLine]): [optional] # noqa: E501 + fax_lines ([FaxLineResponseFaxLine]): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ @@ -281,7 +281,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) list_info (ListInfoResponse): [optional] # noqa: E501 - fax_lines ([FaxLine]): [optional] # noqa: E501 + fax_lines ([FaxLineResponseFaxLine]): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ diff --git a/sdks/python/dropbox_sign/model/fax_line_response.py b/sdks/python/dropbox_sign/model/fax_line_response.py index 8beff0a91..7de499c2b 100644 --- a/sdks/python/dropbox_sign/model/fax_line_response.py +++ b/sdks/python/dropbox_sign/model/fax_line_response.py @@ -33,14 +33,14 @@ ) from dropbox_sign.exceptions import ApiAttributeError if TYPE_CHECKING: - from dropbox_sign.model.fax_line import FaxLine + from dropbox_sign.model.fax_line_response_fax_line import FaxLineResponseFaxLine from dropbox_sign.model.warning_response import WarningResponse def lazy_import(): - from dropbox_sign.model.fax_line import FaxLine + from dropbox_sign.model.fax_line_response_fax_line import FaxLineResponseFaxLine from dropbox_sign.model.warning_response import WarningResponse - globals()['FaxLine'] = FaxLine + globals()['FaxLineResponseFaxLine'] = FaxLineResponseFaxLine globals()['WarningResponse'] = WarningResponse @@ -97,7 +97,7 @@ def openapi_types(): """ lazy_import() return { - 'fax_line': (FaxLine,), # noqa: E501 + 'fax_line': (FaxLineResponseFaxLine,), # noqa: E501 'warnings': (WarningResponse,), # noqa: E501 } @@ -132,11 +132,11 @@ def init(data: any) -> FaxLineResponse: _composed_schemas = {} @property - def fax_line(self) -> FaxLine: + def fax_line(self) -> FaxLineResponseFaxLine: return self.get("fax_line") @fax_line.setter - def fax_line(self, value: FaxLine): + def fax_line(self, value: FaxLineResponseFaxLine): setattr(self, "fax_line", value) @property @@ -183,7 +183,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) - fax_line (FaxLine): [optional] # noqa: E501 + fax_line (FaxLineResponseFaxLine): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ @@ -266,7 +266,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) - fax_line (FaxLine): [optional] # noqa: E501 + fax_line (FaxLineResponseFaxLine): [optional] # noqa: E501 warnings (WarningResponse): [optional] # noqa: E501 """ diff --git a/sdks/python/dropbox_sign/model/fax_line_response_fax_line.py b/sdks/python/dropbox_sign/model/fax_line_response_fax_line.py new file mode 100644 index 000000000..844b7d771 --- /dev/null +++ b/sdks/python/dropbox_sign/model/fax_line_response_fax_line.py @@ -0,0 +1,327 @@ +""" + Dropbox Sign API + + Dropbox Sign v3 API # noqa: E501 + + The version of the OpenAPI document: 3.0.0 + Contact: apisupport@hellosign.com + Generated by: https://openapi-generator.tech +""" + + +from __future__ import annotations +from typing import TYPE_CHECKING, Optional, List, Dict, Union +import json # noqa: F401 +import re # noqa: F401 +import sys # noqa: F401 + +from dropbox_sign import ApiClient +from dropbox_sign.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from dropbox_sign.exceptions import ApiAttributeError +if TYPE_CHECKING: + from dropbox_sign.model.account_response import AccountResponse + + +def lazy_import(): + from dropbox_sign.model.account_response import AccountResponse + globals()['AccountResponse'] = AccountResponse + + +class FaxLineResponseFaxLine(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + lazy_import() + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + lazy_import() + return { + 'number': (str,), # noqa: E501 + 'created_at': (int,), # noqa: E501 + 'updated_at': (int,), # noqa: E501 + 'accounts': ([AccountResponse],), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + @staticmethod + def init(data: any) -> FaxLineResponseFaxLine: + """ + Attempt to instantiate and hydrate a new instance of this class + """ + try: + obj_data = json.dumps(data) + except TypeError: + obj_data = data + + return ApiClient().deserialize( + response=type('obj_dict', (object,), {'data': obj_data}), + response_type=[FaxLineResponseFaxLine], + _check_type=True, + ) + + attribute_map = { + 'number': 'number', # noqa: E501 + 'created_at': 'created_at', # noqa: E501 + 'updated_at': 'updated_at', # noqa: E501 + 'accounts': 'accounts', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @property + def number(self) -> str: + return self.get("number") + + @number.setter + def number(self, value: str): + setattr(self, "number", value) + + @property + def created_at(self) -> int: + return self.get("created_at") + + @created_at.setter + def created_at(self, value: int): + setattr(self, "created_at", value) + + @property + def updated_at(self) -> int: + return self.get("updated_at") + + @updated_at.setter + def updated_at(self, value: int): + setattr(self, "updated_at", value) + + @property + def accounts(self) -> List[AccountResponse]: + return self.get("accounts") + + @accounts.setter + def accounts(self, value: List[AccountResponse]): + setattr(self, "accounts", value) + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """FaxLineResponseFaxLine - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + number (str): Number. [optional] # noqa: E501 + created_at (int): Created at. [optional] # noqa: E501 + updated_at (int): Updated at. [optional] # noqa: E501 + accounts ([AccountResponse]): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, *args, **kwargs): # noqa: E501 + """FaxLineResponseFaxLine - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + number (str): Number. [optional] # noqa: E501 + created_at (int): Created at. [optional] # noqa: E501 + updated_at (int): Updated at. [optional] # noqa: E501 + accounts ([AccountResponse]): [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/sdks/python/dropbox_sign/models/__init__.py b/sdks/python/dropbox_sign/models/__init__.py index b773dfd88..e568ef334 100644 --- a/sdks/python/dropbox_sign/models/__init__.py +++ b/sdks/python/dropbox_sign/models/__init__.py @@ -43,7 +43,6 @@ from dropbox_sign.model.event_callback_request import EventCallbackRequest from dropbox_sign.model.event_callback_request_event import EventCallbackRequestEvent from dropbox_sign.model.event_callback_request_event_metadata import EventCallbackRequestEventMetadata -from dropbox_sign.model.fax_line import FaxLine from dropbox_sign.model.fax_line_add_user_request import FaxLineAddUserRequest from dropbox_sign.model.fax_line_area_code_get_country_enum import FaxLineAreaCodeGetCountryEnum from dropbox_sign.model.fax_line_area_code_get_province_enum import FaxLineAreaCodeGetProvinceEnum @@ -54,6 +53,7 @@ from dropbox_sign.model.fax_line_list_response import FaxLineListResponse from dropbox_sign.model.fax_line_remove_user_request import FaxLineRemoveUserRequest from dropbox_sign.model.fax_line_response import FaxLineResponse +from dropbox_sign.model.fax_line_response_fax_line import FaxLineResponseFaxLine from dropbox_sign.model.file_response import FileResponse from dropbox_sign.model.file_response_data_uri import FileResponseDataUri from dropbox_sign.model.list_info_response import ListInfoResponse diff --git a/sdks/ruby/.openapi-generator/FILES b/sdks/ruby/.openapi-generator/FILES index 263dd816f..2ff1424e3 100644 --- a/sdks/ruby/.openapi-generator/FILES +++ b/sdks/ruby/.openapi-generator/FILES @@ -45,7 +45,6 @@ docs/ErrorResponseError.md docs/EventCallbackRequest.md docs/EventCallbackRequestEvent.md docs/EventCallbackRequestEventMetadata.md -docs/FaxLine.md docs/FaxLineAddUserRequest.md docs/FaxLineApi.md docs/FaxLineAreaCodeGetCountryEnum.md @@ -57,6 +56,7 @@ docs/FaxLineDeleteRequest.md docs/FaxLineListResponse.md docs/FaxLineRemoveUserRequest.md docs/FaxLineResponse.md +docs/FaxLineResponseFaxLine.md docs/FileResponse.md docs/FileResponseDataUri.md docs/ListInfoResponse.md @@ -252,7 +252,6 @@ lib/dropbox-sign/models/error_response_error.rb lib/dropbox-sign/models/event_callback_request.rb lib/dropbox-sign/models/event_callback_request_event.rb lib/dropbox-sign/models/event_callback_request_event_metadata.rb -lib/dropbox-sign/models/fax_line.rb lib/dropbox-sign/models/fax_line_add_user_request.rb lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb @@ -263,6 +262,7 @@ lib/dropbox-sign/models/fax_line_delete_request.rb lib/dropbox-sign/models/fax_line_list_response.rb lib/dropbox-sign/models/fax_line_remove_user_request.rb lib/dropbox-sign/models/fax_line_response.rb +lib/dropbox-sign/models/fax_line_response_fax_line.rb lib/dropbox-sign/models/file_response.rb lib/dropbox-sign/models/file_response_data_uri.rb lib/dropbox-sign/models/list_info_response.rb diff --git a/sdks/ruby/README.md b/sdks/ruby/README.md index 68700fd52..5dbddb756 100644 --- a/sdks/ruby/README.md +++ b/sdks/ruby/README.md @@ -120,13 +120,13 @@ All URIs are relative to *https://api.hellosign.com/v3* |*Dropbox::Sign::BulkSendJobApi* | [**bulk_send_job_list**](docs/BulkSendJobApi.md#bulk_send_job_list) | **GET** /bulk_send_job/list | List Bulk Send Jobs | |*Dropbox::Sign::EmbeddedApi* | [**embedded_edit_url**](docs/EmbeddedApi.md#embedded_edit_url) | **POST** /embedded/edit_url/{template_id} | Get Embedded Template Edit URL | |*Dropbox::Sign::EmbeddedApi* | [**embedded_sign_url**](docs/EmbeddedApi.md#embedded_sign_url) | **GET** /embedded/sign_url/{signature_id} | Get Embedded Sign URL | -|*Dropbox::Sign::FaxLineApi* | [**fax_line_add_user**](docs/FaxLineApi.md#fax_line_add_user) | **POST** /fax_line/add_user | Add Fax Line User | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_add_user**](docs/FaxLineApi.md#fax_line_add_user) | **PUT** /fax_line/add_user | Add Fax Line User | |*Dropbox::Sign::FaxLineApi* | [**fax_line_area_code_get**](docs/FaxLineApi.md#fax_line_area_code_get) | **GET** /fax_line/area_codes | Get Available Fax Line Area Codes | |*Dropbox::Sign::FaxLineApi* | [**fax_line_create**](docs/FaxLineApi.md#fax_line_create) | **POST** /fax_line/create | Purchase Fax Line | |*Dropbox::Sign::FaxLineApi* | [**fax_line_delete**](docs/FaxLineApi.md#fax_line_delete) | **DELETE** /fax_line | Delete Fax Line | |*Dropbox::Sign::FaxLineApi* | [**fax_line_get**](docs/FaxLineApi.md#fax_line_get) | **GET** /fax_line | Get Fax Line | |*Dropbox::Sign::FaxLineApi* | [**fax_line_list**](docs/FaxLineApi.md#fax_line_list) | **GET** /fax_line/list | List Fax Lines | -|*Dropbox::Sign::FaxLineApi* | [**fax_line_remove_user**](docs/FaxLineApi.md#fax_line_remove_user) | **POST** /fax_line/remove_user | Remove Fax Line Access | +|*Dropbox::Sign::FaxLineApi* | [**fax_line_remove_user**](docs/FaxLineApi.md#fax_line_remove_user) | **PUT** /fax_line/remove_user | Remove Fax Line Access | |*Dropbox::Sign::OAuthApi* | [**oauth_token_generate**](docs/OAuthApi.md#oauth_token_generate) | **POST** /oauth/token | OAuth Token Generate | |*Dropbox::Sign::OAuthApi* | [**oauth_token_refresh**](docs/OAuthApi.md#oauth_token_refresh) | **POST** /oauth/token?refresh | OAuth Token Refresh | |*Dropbox::Sign::ReportApi* | [**report_create**](docs/ReportApi.md#report_create) | **POST** /report/create | Create Report | @@ -209,7 +209,6 @@ All URIs are relative to *https://api.hellosign.com/v3* - [Dropbox::Sign::EventCallbackRequest](docs/EventCallbackRequest.md) - [Dropbox::Sign::EventCallbackRequestEvent](docs/EventCallbackRequestEvent.md) - [Dropbox::Sign::EventCallbackRequestEventMetadata](docs/EventCallbackRequestEventMetadata.md) - - [Dropbox::Sign::FaxLine](docs/FaxLine.md) - [Dropbox::Sign::FaxLineAddUserRequest](docs/FaxLineAddUserRequest.md) - [Dropbox::Sign::FaxLineAreaCodeGetCountryEnum](docs/FaxLineAreaCodeGetCountryEnum.md) - [Dropbox::Sign::FaxLineAreaCodeGetProvinceEnum](docs/FaxLineAreaCodeGetProvinceEnum.md) @@ -220,6 +219,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [Dropbox::Sign::FaxLineListResponse](docs/FaxLineListResponse.md) - [Dropbox::Sign::FaxLineRemoveUserRequest](docs/FaxLineRemoveUserRequest.md) - [Dropbox::Sign::FaxLineResponse](docs/FaxLineResponse.md) + - [Dropbox::Sign::FaxLineResponseFaxLine](docs/FaxLineResponseFaxLine.md) - [Dropbox::Sign::FileResponse](docs/FileResponse.md) - [Dropbox::Sign::FileResponseDataUri](docs/FileResponseDataUri.md) - [Dropbox::Sign::ListInfoResponse](docs/ListInfoResponse.md) diff --git a/sdks/ruby/docs/FaxLineApi.md b/sdks/ruby/docs/FaxLineApi.md index d9807f6b7..f5b1d3b43 100644 --- a/sdks/ruby/docs/FaxLineApi.md +++ b/sdks/ruby/docs/FaxLineApi.md @@ -4,13 +4,13 @@ All URIs are relative to *https://api.hellosign.com/v3* | Method | HTTP request | Description | | ------ | ------------ | ----------- | -| [`fax_line_add_user`](FaxLineApi.md#fax_line_add_user) | **POST** `/fax_line/add_user` | Add Fax Line User | +| [`fax_line_add_user`](FaxLineApi.md#fax_line_add_user) | **PUT** `/fax_line/add_user` | Add Fax Line User | | [`fax_line_area_code_get`](FaxLineApi.md#fax_line_area_code_get) | **GET** `/fax_line/area_codes` | Get Available Fax Line Area Codes | | [`fax_line_create`](FaxLineApi.md#fax_line_create) | **POST** `/fax_line/create` | Purchase Fax Line | | [`fax_line_delete`](FaxLineApi.md#fax_line_delete) | **DELETE** `/fax_line` | Delete Fax Line | | [`fax_line_get`](FaxLineApi.md#fax_line_get) | **GET** `/fax_line` | Get Fax Line | | [`fax_line_list`](FaxLineApi.md#fax_line_list) | **GET** `/fax_line/list` | List Fax Lines | -| [`fax_line_remove_user`](FaxLineApi.md#fax_line_remove_user) | **POST** `/fax_line/remove_user` | Remove Fax Line Access | +| [`fax_line_remove_user`](FaxLineApi.md#fax_line_remove_user) | **PUT** `/fax_line/remove_user` | Remove Fax Line Access | ## `fax_line_add_user` @@ -175,7 +175,7 @@ end fax_line_api = Dropbox::Sign::FaxLineApi.new data = Dropbox::Sign::FaxLineCreateRequest.new -data.area_code = "209" +data.area_code = 209 data.country = "US" begin @@ -249,8 +249,7 @@ data = Dropbox::Sign::FaxLineDeleteRequest.new data.number = "[FAX_NUMBER]" begin - result = fax_line_api.fax_line_delete(data) - p result + fax_line_api.fax_line_delete(data) rescue Dropbox::Sign::ApiError => e puts "Exception when calling Dropbox Sign API: #{e}" end @@ -414,8 +413,8 @@ end | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `account_id` | **String** | Account ID | [optional] | -| `page` | **Integer** | Page | [optional] | -| `page_size` | **Integer** | Page size | [optional] | +| `page` | **Integer** | Page | [optional][default to 1] | +| `page_size` | **Integer** | Page size | [optional][default to 20] | | `show_team_lines` | **Boolean** | Show team lines | [optional] | ### Return type diff --git a/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md b/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md index aeef0a852..ec20a8793 100644 --- a/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md +++ b/sdks/ruby/docs/FaxLineAreaCodeGetResponse.md @@ -6,5 +6,5 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `area_codes` | ```Array``` | | | +| `area_codes` | ```Array``` | | | diff --git a/sdks/ruby/docs/FaxLineCreateRequest.md b/sdks/ruby/docs/FaxLineCreateRequest.md index 740f3c437..bbe5312c6 100644 --- a/sdks/ruby/docs/FaxLineCreateRequest.md +++ b/sdks/ruby/docs/FaxLineCreateRequest.md @@ -6,7 +6,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `area_code`*_required_ | ```String``` | Area code | | +| `area_code`*_required_ | ```Integer``` | Area code | | | `country`*_required_ | ```String``` | Country | | | `city` | ```String``` | City | | | `account_id` | ```String``` | Account ID | | diff --git a/sdks/ruby/docs/FaxLineListResponse.md b/sdks/ruby/docs/FaxLineListResponse.md index 79c2c564d..ab14849aa 100644 --- a/sdks/ruby/docs/FaxLineListResponse.md +++ b/sdks/ruby/docs/FaxLineListResponse.md @@ -7,6 +7,6 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `list_info` | [```ListInfoResponse```](ListInfoResponse.md) | | | -| `fax_lines` | [```Array```](FaxLine.md) | | | +| `fax_lines` | [```Array```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/ruby/docs/FaxLineResponse.md b/sdks/ruby/docs/FaxLineResponse.md index 85423b6e2..bd3fce74d 100644 --- a/sdks/ruby/docs/FaxLineResponse.md +++ b/sdks/ruby/docs/FaxLineResponse.md @@ -6,6 +6,6 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| `fax_line` | [```FaxLine```](FaxLine.md) | | | +| `fax_line` | [```FaxLineResponseFaxLine```](FaxLineResponseFaxLine.md) | | | | `warnings` | [```WarningResponse```](WarningResponse.md) | | | diff --git a/sdks/ruby/docs/FaxLine.md b/sdks/ruby/docs/FaxLineResponseFaxLine.md similarity index 60% rename from sdks/ruby/docs/FaxLine.md rename to sdks/ruby/docs/FaxLineResponseFaxLine.md index ba136383f..03d2a1d95 100644 --- a/sdks/ruby/docs/FaxLine.md +++ b/sdks/ruby/docs/FaxLineResponseFaxLine.md @@ -1,4 +1,4 @@ -# Dropbox::Sign::FaxLine +# Dropbox::Sign::FaxLineResponseFaxLine @@ -7,7 +7,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | `number` | ```String``` | Number | | -| `created_at` | ```String``` | Created at | | -| `updated_at` | ```String``` | Updated at | | +| `created_at` | ```Integer``` | Created at | | +| `updated_at` | ```Integer``` | Updated at | | | `accounts` | [```Array```](AccountResponse.md) | | | diff --git a/sdks/ruby/lib/dropbox-sign.rb b/sdks/ruby/lib/dropbox-sign.rb index 54ae095fa..91fce4a10 100644 --- a/sdks/ruby/lib/dropbox-sign.rb +++ b/sdks/ruby/lib/dropbox-sign.rb @@ -51,7 +51,6 @@ require 'dropbox-sign/models/event_callback_request' require 'dropbox-sign/models/event_callback_request_event' require 'dropbox-sign/models/event_callback_request_event_metadata' -require 'dropbox-sign/models/fax_line' require 'dropbox-sign/models/fax_line_add_user_request' require 'dropbox-sign/models/fax_line_area_code_get_country_enum' require 'dropbox-sign/models/fax_line_area_code_get_province_enum' @@ -62,6 +61,7 @@ require 'dropbox-sign/models/fax_line_list_response' require 'dropbox-sign/models/fax_line_remove_user_request' require 'dropbox-sign/models/fax_line_response' +require 'dropbox-sign/models/fax_line_response_fax_line' require 'dropbox-sign/models/file_response' require 'dropbox-sign/models/file_response_data_uri' require 'dropbox-sign/models/list_info_response' diff --git a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb index 0e8a0d205..5eac1b2ad 100644 --- a/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb +++ b/sdks/ruby/lib/dropbox-sign/api/fax_line_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -94,7 +94,7 @@ def fax_line_add_user_with_http_info(fax_line_add_user_request, opts = {}) ) begin - data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options) + data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options) rescue Dropbox::Sign::ApiError => e if e.code === 200 body = @api_client.convert_to_type( @@ -538,8 +538,8 @@ def fax_line_get_with_http_info(number, opts = {}) # Returns the properties and settings of multiple Fax Lines. # @param [Hash] opts the optional parameters # @option opts [String] :account_id Account ID - # @option opts [Integer] :page Page - # @option opts [Integer] :page_size Page size + # @option opts [Integer] :page Page (default to 1) + # @option opts [Integer] :page_size Page size (default to 20) # @option opts [Boolean] :show_team_lines Show team lines # @return [FaxLineListResponse] def fax_line_list(opts = {}) @@ -551,8 +551,8 @@ def fax_line_list(opts = {}) # Returns the properties and settings of multiple Fax Lines. # @param [Hash] opts the optional parameters # @option opts [String] :account_id Account ID - # @option opts [Integer] :page Page - # @option opts [Integer] :page_size Page size + # @option opts [Integer] :page Page (default to 1) + # @option opts [Integer] :page_size Page size (default to 20) # @option opts [Boolean] :show_team_lines Show team lines # @return [Array<(FaxLineListResponse, Integer, Hash)>] FaxLineListResponse data, response status code and response headers def fax_line_list_with_http_info(opts = {}) @@ -706,7 +706,7 @@ def fax_line_remove_user_with_http_info(fax_line_remove_user_request, opts = {}) ) begin - data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options) + data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options) rescue Dropbox::Sign::ApiError => e if e.code === 200 body = @api_client.convert_to_type( diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb index f8b80710e..ffbc66ca0 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_add_user_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -203,8 +203,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -222,7 +220,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb index b50643325..cc8194087 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_country_enum.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -22,6 +22,10 @@ class FaxLineAreaCodeGetCountryEnum US = "US".freeze UK = "UK".freeze + def self.all_vars + @all_vars ||= [CA, US, UK].freeze + end + # Builds the enum from string # @param [String] The enum value in the form of the string # @return [String] The enum value @@ -33,9 +37,9 @@ def self.build_from_hash(value) # @param [String] The enum value in the form of the string # @return [String] The enum value def build_from_hash(value) - constantValues = FaxLineAreaCodeGetCountryEnum.constants.select { |c| FaxLineAreaCodeGetCountryEnum::const_get(c) == value } - raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetCountryEnum" if constantValues.empty? - value + return value if FaxLineAreaCodeGetCountryEnum.all_vars.include?(value) + raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetCountryEnum" end end + end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb index 4f9bbc725..c5325e731 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_province_enum.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -32,6 +32,10 @@ class FaxLineAreaCodeGetProvinceEnum SK = "SK".freeze YT = "YT".freeze + def self.all_vars + @all_vars ||= [AB, BC, MB, NB, NL, NT, NS, NU, ON, PE, QC, SK, YT].freeze + end + # Builds the enum from string # @param [String] The enum value in the form of the string # @return [String] The enum value @@ -43,9 +47,9 @@ def self.build_from_hash(value) # @param [String] The enum value in the form of the string # @return [String] The enum value def build_from_hash(value) - constantValues = FaxLineAreaCodeGetProvinceEnum.constants.select { |c| FaxLineAreaCodeGetProvinceEnum::const_get(c) == value } - raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetProvinceEnum" if constantValues.empty? - value + return value if FaxLineAreaCodeGetProvinceEnum.all_vars.include?(value) + raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetProvinceEnum" end end + end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb index d591832ae..ee8304034 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -18,7 +18,7 @@ module Dropbox module Dropbox::Sign class FaxLineAreaCodeGetResponse - # @return [Array] + # @return [Array] attr_accessor :area_codes # Attribute mapping from ruby-style variable name to JSON key. @@ -41,7 +41,7 @@ def self.merged_attributes # Attribute type mapping. def self.openapi_types { - :'area_codes' => :'Array' + :'area_codes' => :'Array' } end @@ -177,8 +177,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -196,7 +194,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb index 4f39fa531..e48a2d074 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_area_code_get_state_enum.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -70,6 +70,10 @@ class FaxLineAreaCodeGetStateEnum WV = "WV".freeze WY = "WY".freeze + def self.all_vars + @all_vars ||= [AK, AL, AR, AZ, CA, CO, CT, DC, DE, FL, GA, HI, IA, ID, IL, IN, KS, KY, LA, MA, MD, ME, MI, MN, MO, MS, MT, NC, ND, NE, NH, NJ, NM, NV, NY, OH, OK, OR, PA, RI, SC, SD, TN, TX, UT, VA, VT, WA, WI, WV, WY].freeze + end + # Builds the enum from string # @param [String] The enum value in the form of the string # @return [String] The enum value @@ -81,9 +85,9 @@ def self.build_from_hash(value) # @param [String] The enum value in the form of the string # @return [String] The enum value def build_from_hash(value) - constantValues = FaxLineAreaCodeGetStateEnum.constants.select { |c| FaxLineAreaCodeGetStateEnum::const_get(c) == value } - raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetStateEnum" if constantValues.empty? - value + return value if FaxLineAreaCodeGetStateEnum.all_vars.include?(value) + raise "Invalid ENUM value #{value} for class #FaxLineAreaCodeGetStateEnum" end end + end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb index 28622494a..e4c200b11 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_create_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -19,7 +19,7 @@ module Dropbox module Dropbox::Sign class FaxLineCreateRequest # Area code - # @return [String] + # @return [Integer] attr_accessor :area_code # Country @@ -79,7 +79,7 @@ def self.merged_attributes # Attribute type mapping. def self.openapi_types { - :'area_code' => :'String', + :'area_code' => :'Integer', :'country' => :'String', :'city' => :'String', :'account_id' => :'String' @@ -253,8 +253,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -272,7 +270,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb index 765fc13b3..9faa9dd97 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_delete_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -181,8 +181,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -200,7 +198,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb index cefe1b60f..096e0eb54 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_list_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -21,7 +21,7 @@ class FaxLineListResponse # @return [ListInfoResponse] attr_accessor :list_info - # @return [Array] + # @return [Array] attr_accessor :fax_lines # @return [WarningResponse] @@ -50,7 +50,7 @@ def self.merged_attributes def self.openapi_types { :'list_info' => :'ListInfoResponse', - :'fax_lines' => :'Array', + :'fax_lines' => :'Array', :'warnings' => :'WarningResponse' } end @@ -197,8 +197,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -216,7 +214,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb index 7a16181a8..99cf104fa 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_remove_user_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -203,8 +203,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -222,7 +220,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb index bec82400a..4406a4e9a 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -18,7 +18,7 @@ module Dropbox module Dropbox::Sign class FaxLineResponse - # @return [FaxLine] + # @return [FaxLineResponseFaxLine] attr_accessor :fax_line # @return [WarningResponse] @@ -45,7 +45,7 @@ def self.merged_attributes # Attribute type mapping. def self.openapi_types { - :'fax_line' => :'FaxLine', + :'fax_line' => :'FaxLineResponseFaxLine', :'warnings' => :'WarningResponse' } end @@ -185,8 +185,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -204,7 +202,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/sdks/ruby/lib/dropbox-sign/models/fax_line.rb b/sdks/ruby/lib/dropbox-sign/models/fax_line_response_fax_line.rb similarity index 92% rename from sdks/ruby/lib/dropbox-sign/models/fax_line.rb rename to sdks/ruby/lib/dropbox-sign/models/fax_line_response_fax_line.rb index f6d2babcf..8860c6b77 100644 --- a/sdks/ruby/lib/dropbox-sign/models/fax_line.rb +++ b/sdks/ruby/lib/dropbox-sign/models/fax_line_response_fax_line.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 3.0.0 Contact: apisupport@hellosign.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.3.0 +Generator version: 7.7.0 =end @@ -17,17 +17,17 @@ module Dropbox end module Dropbox::Sign - class FaxLine + class FaxLineResponseFaxLine # Number # @return [String] attr_accessor :number # Created at - # @return [String] + # @return [Integer] attr_accessor :created_at # Updated at - # @return [String] + # @return [Integer] attr_accessor :updated_at # @return [Array] @@ -57,8 +57,8 @@ def self.merged_attributes def self.openapi_types { :'number' => :'String', - :'created_at' => :'String', - :'updated_at' => :'String', + :'created_at' => :'Integer', + :'updated_at' => :'Integer', :'accounts' => :'Array' } end @@ -81,25 +81,25 @@ def self.merged_nullable # Attempt to instantiate and hydrate a new instance of this class # @param [Object] data Data to be converted - # @return [FaxLine] + # @return [FaxLineResponseFaxLine] def self.init(data) return ApiClient.default.convert_to_type( data, - "FaxLine" - ) || FaxLine.new + "FaxLineResponseFaxLine" + ) || FaxLineResponseFaxLine.new end # Initializes the object # @param [Hash] attributes Model attributes in the form of hash def initialize(attributes = {}) if (!attributes.is_a?(Hash)) - fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLine` initialize method" + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::FaxLineResponseFaxLine` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| if (!self.class.merged_attributes.key?(k.to_sym)) - fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLine`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::FaxLineResponseFaxLine`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect end h[k.to_sym] = v } @@ -210,8 +210,6 @@ def _deserialize(type, value) else false end - when :File - value when :Object # generic object (usually a Hash), return directly value @@ -229,7 +227,7 @@ def _deserialize(type, value) else # model # models (e.g. Pet) klass = Dropbox::Sign.const_get(type) - klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) + klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end diff --git a/translations/en.yaml b/translations/en.yaml index d77ac6bdb..6925e38a4 100644 --- a/translations/en.yaml +++ b/translations/en.yaml @@ -21,6 +21,7 @@ "OpenApi::TAG::UNCLAIMED_DRAFT::DESCRIPTION": ./markdown/en/tags/unclaimed-draft-tag-description.md "OpenApi::TAG::OAUTH::DESCRIPTION": ./markdown/en/tags/oauth-tag-description.md "OpenApi::TAG::CALLBACKS_AND_EVENTS::DESCRIPTION": ./markdown/en/tags/callbacks-tag-description.md +"OpenApi::TAG::TAG_FAX_LINE::DESCRIPTION": ./markdown/en/tags/fax-lines-tag-description.md "OpenApi::ACCOUNT_CALLBACK::SUMMARY": Account Callbacks "OpenApi::ACCOUNT_CALLBACK::DESCRIPTION": ./markdown/en/descriptions/account-callback-description.md From d1e3fdd547407aa403ee257ae03516f15a29d072 Mon Sep 17 00:00:00 2001 From: Jordan Bardsley Date: Mon, 26 Aug 2024 15:23:07 -0400 Subject: [PATCH 12/12] Remove default --- openapi-raw.yaml | 1 - openapi-sdk.yaml | 1 - openapi.yaml | 1 - 3 files changed, 3 deletions(-) diff --git a/openapi-raw.yaml b/openapi-raw.yaml index e2493a03e..340eca1ed 100644 --- a/openapi-raw.yaml +++ b/openapi-raw.yaml @@ -2018,7 +2018,6 @@ paths: description: '_t__FaxLineList::SHOW_TEAM_LINES' schema: type: boolean - default: 0 responses: '200': description: 'successful operation' diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index 9c6055e17..342ab7631 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -2024,7 +2024,6 @@ paths: description: 'Show team lines' schema: type: boolean - default: 0 responses: 200: description: 'successful operation' diff --git a/openapi.yaml b/openapi.yaml index 35edae083..8a8f9f08f 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -2024,7 +2024,6 @@ paths: description: 'Show team lines' schema: type: boolean - default: 0 responses: 200: description: 'successful operation'