dub 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b19f72869d764b1823e65bc65d8438f9089614eb6918b6593a6eee2152f30acd
4
- data.tar.gz: 3df87fc2c6d28b5e0702a444f5f50aac2eb8c1710390d31dfd34b0ccf0add29d
3
+ metadata.gz: 3f179087d52fe52557cc9d32424bac94b2bc98207ec401f8cb45d5eb96b125fb
4
+ data.tar.gz: fc1cdd3ae34276c09e5182e561623e86edd683c35c97a99e13673ef92d725bab
5
5
  SHA512:
6
- metadata.gz: e191ad895e39020507ee383ae4bbde1d6ded180e5b13297f73416cf9d170e295ecd615f5dcc430b875d8a1a7435bf7b3cb5e34d08aa54e375ca5129742ffc271
7
- data.tar.gz: cda24e133b0ee4a898156dba4b573720fb84324e730a000285fd89db9a235856d0b3d496345862b9ce705b2aad57131e3e7a7186521f0717382a72d0f8f5735a
6
+ metadata.gz: 5046dfa213fd07dabcef7879c3ac82d53c110afd617c190436e456d95e2d57d6108bbda82fadfe3be4011edd649840bbc1f60a1e607bfcbf730e86be3241b957
7
+ data.tar.gz: 4693ef6a5d321180e00ca999cd04b8d60cf8aec94fbda4f5988fc86f602a1d745f3929e656386d88a055deea615ad447cf50edb09cc1ed428987a040c9ec9105
@@ -359,182 +359,5 @@ module OpenApiSDK
359
359
  end
360
360
  res
361
361
  end
362
-
363
-
364
- sig { params(request: T.nilable(::OpenApiSDK::Operations::SetPrimaryDomainRequest)).returns(::OpenApiSDK::Operations::SetPrimaryDomainResponse) }
365
- def set_primary(request)
366
- # set_primary - Set a domain as primary
367
- # Set a domain as primary for the authenticated workspace.
368
- url, params = @sdk_configuration.get_server_details
369
- base_url = Utils.template_url(url, params)
370
- url = Utils.generate_url(
371
- ::OpenApiSDK::Operations::SetPrimaryDomainRequest,
372
- base_url,
373
- '/domains/{slug}/primary',
374
- request,
375
- @sdk_configuration.globals
376
- )
377
- headers = {}
378
- query_params = Utils.get_query_params(::OpenApiSDK::Operations::SetPrimaryDomainRequest, request, @sdk_configuration.globals)
379
- headers['Accept'] = 'application/json'
380
- headers['user-agent'] = @sdk_configuration.user_agent
381
-
382
- r = @sdk_configuration.client.post(url) do |req|
383
- req.headers = headers
384
- req.params = query_params
385
- Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
386
- end
387
-
388
- content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
389
-
390
- res = ::OpenApiSDK::Operations::SetPrimaryDomainResponse.new(
391
- status_code: r.status, content_type: content_type, raw_response: r
392
- )
393
- if r.status == 200
394
- if Utils.match_content_type(content_type, 'application/json')
395
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::DomainSchema)
396
- res.domain_schema = out
397
- end
398
- elsif r.status == 400
399
- if Utils.match_content_type(content_type, 'application/json')
400
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::BadRequest)
401
- res.bad_request = out
402
- end
403
- elsif r.status == 401
404
- if Utils.match_content_type(content_type, 'application/json')
405
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Unauthorized)
406
- res.unauthorized = out
407
- end
408
- elsif r.status == 403
409
- if Utils.match_content_type(content_type, 'application/json')
410
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Forbidden)
411
- res.forbidden = out
412
- end
413
- elsif r.status == 404
414
- if Utils.match_content_type(content_type, 'application/json')
415
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::NotFound)
416
- res.not_found = out
417
- end
418
- elsif r.status == 409
419
- if Utils.match_content_type(content_type, 'application/json')
420
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Conflict)
421
- res.conflict = out
422
- end
423
- elsif r.status == 410
424
- if Utils.match_content_type(content_type, 'application/json')
425
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InviteExpired)
426
- res.invite_expired = out
427
- end
428
- elsif r.status == 422
429
- if Utils.match_content_type(content_type, 'application/json')
430
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::UnprocessableEntity)
431
- res.unprocessable_entity = out
432
- end
433
- elsif r.status == 429
434
- if Utils.match_content_type(content_type, 'application/json')
435
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::RateLimitExceeded)
436
- res.rate_limit_exceeded = out
437
- end
438
- elsif r.status == 500
439
- if Utils.match_content_type(content_type, 'application/json')
440
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InternalServerError)
441
- res.internal_server_error = out
442
- end
443
- end
444
- res
445
- end
446
-
447
-
448
- sig { params(request: T.nilable(::OpenApiSDK::Operations::TransferDomainRequest)).returns(::OpenApiSDK::Operations::TransferDomainResponse) }
449
- def transfer(request)
450
- # transfer - Transfer a domain
451
- # Transfer a domain to another workspace within the authenticated account.
452
- url, params = @sdk_configuration.get_server_details
453
- base_url = Utils.template_url(url, params)
454
- url = Utils.generate_url(
455
- ::OpenApiSDK::Operations::TransferDomainRequest,
456
- base_url,
457
- '/domains/{slug}/transfer',
458
- request,
459
- @sdk_configuration.globals
460
- )
461
- headers = {}
462
- req_content_type, data, form = Utils.serialize_request_body(request, :request_body, :json)
463
- headers['content-type'] = req_content_type
464
- query_params = Utils.get_query_params(::OpenApiSDK::Operations::TransferDomainRequest, request, @sdk_configuration.globals)
465
- headers['Accept'] = 'application/json'
466
- headers['user-agent'] = @sdk_configuration.user_agent
467
-
468
- r = @sdk_configuration.client.post(url) do |req|
469
- req.headers = headers
470
- req.params = query_params
471
- Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
472
- if form
473
- req.body = Utils.encode_form(form)
474
- elsif Utils.match_content_type(req_content_type, 'application/x-www-form-urlencoded')
475
- req.body = URI.encode_www_form(data)
476
- else
477
- req.body = data
478
- end
479
- end
480
-
481
- content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
482
-
483
- res = ::OpenApiSDK::Operations::TransferDomainResponse.new(
484
- status_code: r.status, content_type: content_type, raw_response: r
485
- )
486
- if r.status == 200
487
- if Utils.match_content_type(content_type, 'application/json')
488
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::DomainSchema)
489
- res.domain_schema = out
490
- end
491
- elsif r.status == 400
492
- if Utils.match_content_type(content_type, 'application/json')
493
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::BadRequest)
494
- res.bad_request = out
495
- end
496
- elsif r.status == 401
497
- if Utils.match_content_type(content_type, 'application/json')
498
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Unauthorized)
499
- res.unauthorized = out
500
- end
501
- elsif r.status == 403
502
- if Utils.match_content_type(content_type, 'application/json')
503
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Forbidden)
504
- res.forbidden = out
505
- end
506
- elsif r.status == 404
507
- if Utils.match_content_type(content_type, 'application/json')
508
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::NotFound)
509
- res.not_found = out
510
- end
511
- elsif r.status == 409
512
- if Utils.match_content_type(content_type, 'application/json')
513
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Conflict)
514
- res.conflict = out
515
- end
516
- elsif r.status == 410
517
- if Utils.match_content_type(content_type, 'application/json')
518
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InviteExpired)
519
- res.invite_expired = out
520
- end
521
- elsif r.status == 422
522
- if Utils.match_content_type(content_type, 'application/json')
523
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::UnprocessableEntity)
524
- res.unprocessable_entity = out
525
- end
526
- elsif r.status == 429
527
- if Utils.match_content_type(content_type, 'application/json')
528
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::RateLimitExceeded)
529
- res.rate_limit_exceeded = out
530
- end
531
- elsif r.status == 500
532
- if Utils.match_content_type(content_type, 'application/json')
533
- out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InternalServerError)
534
- res.internal_server_error = out
535
- end
536
- end
537
- res
538
- end
539
362
  end
540
363
  end
@@ -11,16 +11,21 @@ module OpenApiSDK
11
11
  class CreateTagRequestBody < ::OpenApiSDK::Utils::FieldAugmented
12
12
  extend T::Sig
13
13
 
14
- # The name of the tag to create.
15
- field :tag, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('tag') } }
16
14
  # The color of the tag. If not provided, a random color will be used from the list: red, yellow, green, blue, purple, pink, brown.
17
15
  field :color, T.nilable(::OpenApiSDK::Operations::Color), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('color'), 'decoder': Utils.enum_from_string(::OpenApiSDK::Operations::Color, true) } }
16
+ # The name of the tag to create.
17
+ field :name, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('name') } }
18
+ # The name of the tag to create.
19
+ #
20
+ # @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible.
21
+ field :tag, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('tag') } }
18
22
 
19
23
 
20
- sig { params(tag: ::String, color: T.nilable(::OpenApiSDK::Operations::Color)).void }
21
- def initialize(tag: nil, color: nil)
22
- @tag = tag
24
+ sig { params(color: T.nilable(::OpenApiSDK::Operations::Color), name: T.nilable(::String), tag: T.nilable(::String)).void }
25
+ def initialize(color: nil, name: nil, tag: nil)
23
26
  @color = color
27
+ @name = name
28
+ @tag = tag
24
29
  end
25
30
  end
26
31
  end
@@ -0,0 +1,24 @@
1
+ # Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+ # UpdateTagColor - The color of the tag. If not provided, a random color will be used from the list: red, yellow, green, blue, purple, pink, brown.
11
+ class UpdateTagColor < T::Enum
12
+ enums do
13
+ RED = new('red')
14
+ YELLOW = new('yellow')
15
+ GREEN = new('green')
16
+ BLUE = new('blue')
17
+ PURPLE = new('purple')
18
+ PINK = new('pink')
19
+ BROWN = new('brown')
20
+ end
21
+ end
22
+
23
+ end
24
+ end
@@ -8,22 +8,22 @@ module OpenApiSDK
8
8
  module Operations
9
9
 
10
10
 
11
- class TransferDomainRequest < ::OpenApiSDK::Utils::FieldAugmented
11
+ class UpdateTagRequest < ::OpenApiSDK::Utils::FieldAugmented
12
12
  extend T::Sig
13
13
 
14
- # The domain name.
15
- field :slug, ::String, { 'path_param': { 'field_name': 'slug', 'style': 'simple', 'explode': false } }
14
+ # The ID of the tag
15
+ field :id, ::String, { 'path_param': { 'field_name': 'id', 'style': 'simple', 'explode': false } }
16
16
  # The slug of the project. This field is deprecated – use `workspaceId` instead.
17
17
  field :project_slug, T.nilable(::String), { 'query_param': { 'field_name': 'projectSlug', 'style': 'form', 'explode': true } }
18
18
 
19
- field :request_body, T.nilable(::OpenApiSDK::Operations::TransferDomainRequestBody), { 'request': { 'media_type': 'application/json' } }
19
+ field :request_body, T.nilable(::OpenApiSDK::Operations::UpdateTagRequestBody), { 'request': { 'media_type': 'application/json' } }
20
20
  # The ID of the workspace.
21
21
  field :workspace_id, T.nilable(::String), { 'query_param': { 'field_name': 'workspaceId', 'style': 'form', 'explode': true } }
22
22
 
23
23
 
24
- sig { params(slug: ::String, project_slug: T.nilable(::String), request_body: T.nilable(::OpenApiSDK::Operations::TransferDomainRequestBody), workspace_id: T.nilable(::String)).void }
25
- def initialize(slug: nil, project_slug: nil, request_body: nil, workspace_id: nil)
26
- @slug = slug
24
+ sig { params(id: ::String, project_slug: T.nilable(::String), request_body: T.nilable(::OpenApiSDK::Operations::UpdateTagRequestBody), workspace_id: T.nilable(::String)).void }
25
+ def initialize(id: nil, project_slug: nil, request_body: nil, workspace_id: nil)
26
+ @id = id
27
27
  @project_slug = project_slug
28
28
  @request_body = request_body
29
29
  @workspace_id = workspace_id
@@ -0,0 +1,32 @@
1
+ # Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class UpdateTagRequestBody < ::OpenApiSDK::Utils::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # The color of the tag. If not provided, a random color will be used from the list: red, yellow, green, blue, purple, pink, brown.
15
+ field :color, T.nilable(::OpenApiSDK::Operations::UpdateTagColor), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('color'), 'decoder': Utils.enum_from_string(::OpenApiSDK::Operations::UpdateTagColor, true) } }
16
+ # The name of the tag to create.
17
+ field :name, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('name') } }
18
+ # The name of the tag to create.
19
+ #
20
+ # @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible.
21
+ field :tag, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('tag') } }
22
+
23
+
24
+ sig { params(color: T.nilable(::OpenApiSDK::Operations::UpdateTagColor), name: T.nilable(::String), tag: T.nilable(::String)).void }
25
+ def initialize(color: nil, name: nil, tag: nil)
26
+ @color = color
27
+ @name = name
28
+ @tag = tag
29
+ end
30
+ end
31
+ end
32
+ end
@@ -8,7 +8,7 @@ module OpenApiSDK
8
8
  module Operations
9
9
 
10
10
 
11
- class TransferDomainResponse < ::OpenApiSDK::Utils::FieldAugmented
11
+ class UpdateTagResponse < ::OpenApiSDK::Utils::FieldAugmented
12
12
  extend T::Sig
13
13
 
14
14
  # HTTP response content type for this operation
@@ -21,8 +21,6 @@ module OpenApiSDK
21
21
  field :bad_request, T.nilable(::OpenApiSDK::Shared::BadRequest)
22
22
  # This response is sent when a request conflicts with the current state of the server.
23
23
  field :conflict, T.nilable(::OpenApiSDK::Shared::Conflict)
24
- # The domain transfer initiated
25
- field :domain_schema, T.nilable(::OpenApiSDK::Shared::DomainSchema)
26
24
  # The client does not have access rights to the content; that is, it is unauthorized, so the server is refusing to give the requested resource. Unlike 401 Unauthorized, the client's identity is known to the server.
27
25
  field :forbidden, T.nilable(::OpenApiSDK::Shared::Forbidden)
28
26
  # The server has encountered a situation it does not know how to handle.
@@ -33,25 +31,27 @@ module OpenApiSDK
33
31
  field :not_found, T.nilable(::OpenApiSDK::Shared::NotFound)
34
32
  # The user has sent too many requests in a given amount of time ("rate limiting")
35
33
  field :rate_limit_exceeded, T.nilable(::OpenApiSDK::Shared::RateLimitExceeded)
34
+ # The updated tag.
35
+ field :tag_schema, T.nilable(::OpenApiSDK::Shared::TagSchema)
36
36
  # Although the HTTP standard specifies "unauthorized", semantically this response means "unauthenticated". That is, the client must authenticate itself to get the requested response.
37
37
  field :unauthorized, T.nilable(::OpenApiSDK::Shared::Unauthorized)
38
38
  # The request was well-formed but was unable to be followed due to semantic errors.
39
39
  field :unprocessable_entity, T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)
40
40
 
41
41
 
42
- sig { params(content_type: ::String, raw_response: ::Faraday::Response, status_code: ::Integer, bad_request: T.nilable(::OpenApiSDK::Shared::BadRequest), conflict: T.nilable(::OpenApiSDK::Shared::Conflict), domain_schema: T.nilable(::OpenApiSDK::Shared::DomainSchema), forbidden: T.nilable(::OpenApiSDK::Shared::Forbidden), internal_server_error: T.nilable(::OpenApiSDK::Shared::InternalServerError), invite_expired: T.nilable(::OpenApiSDK::Shared::InviteExpired), not_found: T.nilable(::OpenApiSDK::Shared::NotFound), rate_limit_exceeded: T.nilable(::OpenApiSDK::Shared::RateLimitExceeded), unauthorized: T.nilable(::OpenApiSDK::Shared::Unauthorized), unprocessable_entity: T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)).void }
43
- def initialize(content_type: nil, raw_response: nil, status_code: nil, bad_request: nil, conflict: nil, domain_schema: nil, forbidden: nil, internal_server_error: nil, invite_expired: nil, not_found: nil, rate_limit_exceeded: nil, unauthorized: nil, unprocessable_entity: nil)
42
+ sig { params(content_type: ::String, raw_response: ::Faraday::Response, status_code: ::Integer, bad_request: T.nilable(::OpenApiSDK::Shared::BadRequest), conflict: T.nilable(::OpenApiSDK::Shared::Conflict), forbidden: T.nilable(::OpenApiSDK::Shared::Forbidden), internal_server_error: T.nilable(::OpenApiSDK::Shared::InternalServerError), invite_expired: T.nilable(::OpenApiSDK::Shared::InviteExpired), not_found: T.nilable(::OpenApiSDK::Shared::NotFound), rate_limit_exceeded: T.nilable(::OpenApiSDK::Shared::RateLimitExceeded), tag_schema: T.nilable(::OpenApiSDK::Shared::TagSchema), unauthorized: T.nilable(::OpenApiSDK::Shared::Unauthorized), unprocessable_entity: T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)).void }
43
+ def initialize(content_type: nil, raw_response: nil, status_code: nil, bad_request: nil, conflict: nil, forbidden: nil, internal_server_error: nil, invite_expired: nil, not_found: nil, rate_limit_exceeded: nil, tag_schema: nil, unauthorized: nil, unprocessable_entity: nil)
44
44
  @content_type = content_type
45
45
  @raw_response = raw_response
46
46
  @status_code = status_code
47
47
  @bad_request = bad_request
48
48
  @conflict = conflict
49
- @domain_schema = domain_schema
50
49
  @forbidden = forbidden
51
50
  @internal_server_error = internal_server_error
52
51
  @invite_expired = invite_expired
53
52
  @not_found = not_found
54
53
  @rate_limit_exceeded = rate_limit_exceeded
54
+ @tag_schema = tag_schema
55
55
  @unauthorized = unauthorized
56
56
  @unprocessable_entity = unprocessable_entity
57
57
  end
@@ -0,0 +1,24 @@
1
+ # Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class UpdateWorkspaceRequest < ::OpenApiSDK::Utils::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # The ID or slug of the workspace.
15
+ field :id_or_slug, ::String, { 'path_param': { 'field_name': 'idOrSlug', 'style': 'simple', 'explode': false } }
16
+
17
+
18
+ sig { params(id_or_slug: ::String).void }
19
+ def initialize(id_or_slug: nil)
20
+ @id_or_slug = id_or_slug
21
+ end
22
+ end
23
+ end
24
+ end
@@ -8,7 +8,7 @@ module OpenApiSDK
8
8
  module Operations
9
9
 
10
10
 
11
- class SetPrimaryDomainResponse < ::OpenApiSDK::Utils::FieldAugmented
11
+ class UpdateWorkspaceResponse < ::OpenApiSDK::Utils::FieldAugmented
12
12
  extend T::Sig
13
13
 
14
14
  # HTTP response content type for this operation
@@ -21,8 +21,6 @@ module OpenApiSDK
21
21
  field :bad_request, T.nilable(::OpenApiSDK::Shared::BadRequest)
22
22
  # This response is sent when a request conflicts with the current state of the server.
23
23
  field :conflict, T.nilable(::OpenApiSDK::Shared::Conflict)
24
- # The domain was set as primary
25
- field :domain_schema, T.nilable(::OpenApiSDK::Shared::DomainSchema)
26
24
  # The client does not have access rights to the content; that is, it is unauthorized, so the server is refusing to give the requested resource. Unlike 401 Unauthorized, the client's identity is known to the server.
27
25
  field :forbidden, T.nilable(::OpenApiSDK::Shared::Forbidden)
28
26
  # The server has encountered a situation it does not know how to handle.
@@ -37,16 +35,17 @@ module OpenApiSDK
37
35
  field :unauthorized, T.nilable(::OpenApiSDK::Shared::Unauthorized)
38
36
  # The request was well-formed but was unable to be followed due to semantic errors.
39
37
  field :unprocessable_entity, T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)
38
+ # The updated workspace.
39
+ field :workspace_schema, T.nilable(::OpenApiSDK::Shared::WorkspaceSchema)
40
40
 
41
41
 
42
- sig { params(content_type: ::String, raw_response: ::Faraday::Response, status_code: ::Integer, bad_request: T.nilable(::OpenApiSDK::Shared::BadRequest), conflict: T.nilable(::OpenApiSDK::Shared::Conflict), domain_schema: T.nilable(::OpenApiSDK::Shared::DomainSchema), forbidden: T.nilable(::OpenApiSDK::Shared::Forbidden), internal_server_error: T.nilable(::OpenApiSDK::Shared::InternalServerError), invite_expired: T.nilable(::OpenApiSDK::Shared::InviteExpired), not_found: T.nilable(::OpenApiSDK::Shared::NotFound), rate_limit_exceeded: T.nilable(::OpenApiSDK::Shared::RateLimitExceeded), unauthorized: T.nilable(::OpenApiSDK::Shared::Unauthorized), unprocessable_entity: T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)).void }
43
- def initialize(content_type: nil, raw_response: nil, status_code: nil, bad_request: nil, conflict: nil, domain_schema: nil, forbidden: nil, internal_server_error: nil, invite_expired: nil, not_found: nil, rate_limit_exceeded: nil, unauthorized: nil, unprocessable_entity: nil)
42
+ sig { params(content_type: ::String, raw_response: ::Faraday::Response, status_code: ::Integer, bad_request: T.nilable(::OpenApiSDK::Shared::BadRequest), conflict: T.nilable(::OpenApiSDK::Shared::Conflict), forbidden: T.nilable(::OpenApiSDK::Shared::Forbidden), internal_server_error: T.nilable(::OpenApiSDK::Shared::InternalServerError), invite_expired: T.nilable(::OpenApiSDK::Shared::InviteExpired), not_found: T.nilable(::OpenApiSDK::Shared::NotFound), rate_limit_exceeded: T.nilable(::OpenApiSDK::Shared::RateLimitExceeded), unauthorized: T.nilable(::OpenApiSDK::Shared::Unauthorized), unprocessable_entity: T.nilable(::OpenApiSDK::Shared::UnprocessableEntity), workspace_schema: T.nilable(::OpenApiSDK::Shared::WorkspaceSchema)).void }
43
+ def initialize(content_type: nil, raw_response: nil, status_code: nil, bad_request: nil, conflict: nil, forbidden: nil, internal_server_error: nil, invite_expired: nil, not_found: nil, rate_limit_exceeded: nil, unauthorized: nil, unprocessable_entity: nil, workspace_schema: nil)
44
44
  @content_type = content_type
45
45
  @raw_response = raw_response
46
46
  @status_code = status_code
47
47
  @bad_request = bad_request
48
48
  @conflict = conflict
49
- @domain_schema = domain_schema
50
49
  @forbidden = forbidden
51
50
  @internal_server_error = internal_server_error
52
51
  @invite_expired = invite_expired
@@ -54,6 +53,7 @@ module OpenApiSDK
54
53
  @rate_limit_exceeded = rate_limit_exceeded
55
54
  @unauthorized = unauthorized
56
55
  @unprocessable_entity = unprocessable_entity
56
+ @workspace_schema = workspace_schema
57
57
  end
58
58
  end
59
59
  end
@@ -37,12 +37,18 @@ module OpenApiSDK
37
37
  autoload :RetrieveAnalyticsResponse, 'open_api_sdk/models/operations/retrieveanalytics_response.rb'
38
38
  autoload :GetWorkspaceRequest, 'open_api_sdk/models/operations/getworkspace_request.rb'
39
39
  autoload :GetWorkspaceResponse, 'open_api_sdk/models/operations/getworkspace_response.rb'
40
+ autoload :UpdateWorkspaceRequest, 'open_api_sdk/models/operations/updateworkspace_request.rb'
41
+ autoload :UpdateWorkspaceResponse, 'open_api_sdk/models/operations/updateworkspace_response.rb'
40
42
  autoload :GetTagsRequest, 'open_api_sdk/models/operations/gettags_request.rb'
41
43
  autoload :GetTagsResponse, 'open_api_sdk/models/operations/gettags_response.rb'
42
44
  autoload :Color, 'open_api_sdk/models/operations/color.rb'
43
45
  autoload :CreateTagRequestBody, 'open_api_sdk/models/operations/createtag_requestbody.rb'
44
46
  autoload :CreateTagRequest, 'open_api_sdk/models/operations/createtag_request.rb'
45
47
  autoload :CreateTagResponse, 'open_api_sdk/models/operations/createtag_response.rb'
48
+ autoload :UpdateTagColor, 'open_api_sdk/models/operations/updatetag_color.rb'
49
+ autoload :UpdateTagRequestBody, 'open_api_sdk/models/operations/updatetag_requestbody.rb'
50
+ autoload :UpdateTagRequest, 'open_api_sdk/models/operations/updatetag_request.rb'
51
+ autoload :UpdateTagResponse, 'open_api_sdk/models/operations/updatetag_response.rb'
46
52
  autoload :ListDomainsRequest, 'open_api_sdk/models/operations/listdomains_request.rb'
47
53
  autoload :ListDomainsResponse, 'open_api_sdk/models/operations/listdomains_response.rb'
48
54
  autoload :CreateDomainRequestBody, 'open_api_sdk/models/operations/createdomain_requestbody.rb'
@@ -54,11 +60,6 @@ module OpenApiSDK
54
60
  autoload :UpdateDomainRequestBody, 'open_api_sdk/models/operations/updatedomain_requestbody.rb'
55
61
  autoload :UpdateDomainRequest, 'open_api_sdk/models/operations/updatedomain_request.rb'
56
62
  autoload :UpdateDomainResponse, 'open_api_sdk/models/operations/updatedomain_response.rb'
57
- autoload :SetPrimaryDomainRequest, 'open_api_sdk/models/operations/setprimarydomain_request.rb'
58
- autoload :SetPrimaryDomainResponse, 'open_api_sdk/models/operations/setprimarydomain_response.rb'
59
- autoload :TransferDomainRequestBody, 'open_api_sdk/models/operations/transferdomain_requestbody.rb'
60
- autoload :TransferDomainRequest, 'open_api_sdk/models/operations/transferdomain_request.rb'
61
- autoload :TransferDomainResponse, 'open_api_sdk/models/operations/transferdomain_response.rb'
62
63
  autoload :TrackLeadRequestBody, 'open_api_sdk/models/operations/tracklead_requestbody.rb'
63
64
  autoload :TrackLeadRequest, 'open_api_sdk/models/operations/tracklead_request.rb'
64
65
  autoload :TrackLeadResponseBody, 'open_api_sdk/models/operations/tracklead_responsebody.rb'
@@ -40,9 +40,9 @@ module OpenApiSDK
40
40
  @globals = globals.nil? ? {} : globals
41
41
  @language = 'ruby'
42
42
  @openapi_doc_version = '0.0.1'
43
- @sdk_version = '0.1.0'
44
- @gen_version = '2.354.2'
45
- @user_agent = 'speakeasy-sdk/ruby 0.1.0 2.354.2 0.0.1 dub'
43
+ @sdk_version = '0.1.1'
44
+ @gen_version = '2.356.0'
45
+ @user_agent = 'speakeasy-sdk/ruby 0.1.1 2.356.0 0.0.1 dub'
46
46
  end
47
47
 
48
48
  sig { returns([String, T::Hash[Symbol, String]]) }
@@ -182,5 +182,98 @@ module OpenApiSDK
182
182
  end
183
183
  res
184
184
  end
185
+
186
+
187
+ sig { params(request: T.nilable(::OpenApiSDK::Operations::UpdateTagRequest)).returns(::OpenApiSDK::Operations::UpdateTagResponse) }
188
+ def update(request)
189
+ # update - Update a tag
190
+ # Update a tag in the workspace.
191
+ url, params = @sdk_configuration.get_server_details
192
+ base_url = Utils.template_url(url, params)
193
+ url = Utils.generate_url(
194
+ ::OpenApiSDK::Operations::UpdateTagRequest,
195
+ base_url,
196
+ '/tags/{id}',
197
+ request,
198
+ @sdk_configuration.globals
199
+ )
200
+ headers = {}
201
+ req_content_type, data, form = Utils.serialize_request_body(request, :request_body, :json)
202
+ headers['content-type'] = req_content_type
203
+ query_params = Utils.get_query_params(::OpenApiSDK::Operations::UpdateTagRequest, request, @sdk_configuration.globals)
204
+ headers['Accept'] = 'application/json'
205
+ headers['user-agent'] = @sdk_configuration.user_agent
206
+
207
+ r = @sdk_configuration.client.patch(url) do |req|
208
+ req.headers = headers
209
+ req.params = query_params
210
+ Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
211
+ if form
212
+ req.body = Utils.encode_form(form)
213
+ elsif Utils.match_content_type(req_content_type, 'application/x-www-form-urlencoded')
214
+ req.body = URI.encode_www_form(data)
215
+ else
216
+ req.body = data
217
+ end
218
+ end
219
+
220
+ content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
221
+
222
+ res = ::OpenApiSDK::Operations::UpdateTagResponse.new(
223
+ status_code: r.status, content_type: content_type, raw_response: r
224
+ )
225
+ if r.status == 200
226
+ if Utils.match_content_type(content_type, 'application/json')
227
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::TagSchema)
228
+ res.tag_schema = out
229
+ end
230
+ elsif r.status == 400
231
+ if Utils.match_content_type(content_type, 'application/json')
232
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::BadRequest)
233
+ res.bad_request = out
234
+ end
235
+ elsif r.status == 401
236
+ if Utils.match_content_type(content_type, 'application/json')
237
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Unauthorized)
238
+ res.unauthorized = out
239
+ end
240
+ elsif r.status == 403
241
+ if Utils.match_content_type(content_type, 'application/json')
242
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Forbidden)
243
+ res.forbidden = out
244
+ end
245
+ elsif r.status == 404
246
+ if Utils.match_content_type(content_type, 'application/json')
247
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::NotFound)
248
+ res.not_found = out
249
+ end
250
+ elsif r.status == 409
251
+ if Utils.match_content_type(content_type, 'application/json')
252
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Conflict)
253
+ res.conflict = out
254
+ end
255
+ elsif r.status == 410
256
+ if Utils.match_content_type(content_type, 'application/json')
257
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InviteExpired)
258
+ res.invite_expired = out
259
+ end
260
+ elsif r.status == 422
261
+ if Utils.match_content_type(content_type, 'application/json')
262
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::UnprocessableEntity)
263
+ res.unprocessable_entity = out
264
+ end
265
+ elsif r.status == 429
266
+ if Utils.match_content_type(content_type, 'application/json')
267
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::RateLimitExceeded)
268
+ res.rate_limit_exceeded = out
269
+ end
270
+ elsif r.status == 500
271
+ if Utils.match_content_type(content_type, 'application/json')
272
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InternalServerError)
273
+ res.internal_server_error = out
274
+ end
275
+ end
276
+ res
277
+ end
185
278
  end
186
279
  end
@@ -99,5 +99,87 @@ module OpenApiSDK
99
99
  end
100
100
  res
101
101
  end
102
+
103
+
104
+ sig { params(request: T.nilable(::OpenApiSDK::Operations::UpdateWorkspaceRequest)).returns(::OpenApiSDK::Operations::UpdateWorkspaceResponse) }
105
+ def update(request)
106
+ # update - Update a workspace
107
+ # Update a workspace by ID or slug.
108
+ url, params = @sdk_configuration.get_server_details
109
+ base_url = Utils.template_url(url, params)
110
+ url = Utils.generate_url(
111
+ ::OpenApiSDK::Operations::UpdateWorkspaceRequest,
112
+ base_url,
113
+ '/workspaces/{idOrSlug}',
114
+ request,
115
+ @sdk_configuration.globals
116
+ )
117
+ headers = {}
118
+ headers['Accept'] = 'application/json'
119
+ headers['user-agent'] = @sdk_configuration.user_agent
120
+
121
+ r = @sdk_configuration.client.patch(url) do |req|
122
+ req.headers = headers
123
+ Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
124
+ end
125
+
126
+ content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
127
+
128
+ res = ::OpenApiSDK::Operations::UpdateWorkspaceResponse.new(
129
+ status_code: r.status, content_type: content_type, raw_response: r
130
+ )
131
+ if r.status == 200
132
+ if Utils.match_content_type(content_type, 'application/json')
133
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::WorkspaceSchema)
134
+ res.workspace_schema = out
135
+ end
136
+ elsif r.status == 400
137
+ if Utils.match_content_type(content_type, 'application/json')
138
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::BadRequest)
139
+ res.bad_request = out
140
+ end
141
+ elsif r.status == 401
142
+ if Utils.match_content_type(content_type, 'application/json')
143
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Unauthorized)
144
+ res.unauthorized = out
145
+ end
146
+ elsif r.status == 403
147
+ if Utils.match_content_type(content_type, 'application/json')
148
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Forbidden)
149
+ res.forbidden = out
150
+ end
151
+ elsif r.status == 404
152
+ if Utils.match_content_type(content_type, 'application/json')
153
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::NotFound)
154
+ res.not_found = out
155
+ end
156
+ elsif r.status == 409
157
+ if Utils.match_content_type(content_type, 'application/json')
158
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::Conflict)
159
+ res.conflict = out
160
+ end
161
+ elsif r.status == 410
162
+ if Utils.match_content_type(content_type, 'application/json')
163
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InviteExpired)
164
+ res.invite_expired = out
165
+ end
166
+ elsif r.status == 422
167
+ if Utils.match_content_type(content_type, 'application/json')
168
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::UnprocessableEntity)
169
+ res.unprocessable_entity = out
170
+ end
171
+ elsif r.status == 429
172
+ if Utils.match_content_type(content_type, 'application/json')
173
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::RateLimitExceeded)
174
+ res.rate_limit_exceeded = out
175
+ end
176
+ elsif r.status == 500
177
+ if Utils.match_content_type(content_type, 'application/json')
178
+ out = Utils.unmarshal_complex(r.env.response_body, ::OpenApiSDK::Shared::InternalServerError)
179
+ res.internal_server_error = out
180
+ end
181
+ end
182
+ res
183
+ end
102
184
  end
103
185
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dub
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-07-01 00:00:00.000000000 Z
11
+ date: 2024-07-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -192,8 +192,6 @@ files:
192
192
  - lib/open_api_sdk/models/operations/requestbody.rb
193
193
  - lib/open_api_sdk/models/operations/retrieveanalytics_request.rb
194
194
  - lib/open_api_sdk/models/operations/retrieveanalytics_response.rb
195
- - lib/open_api_sdk/models/operations/setprimarydomain_request.rb
196
- - lib/open_api_sdk/models/operations/setprimarydomain_response.rb
197
195
  - lib/open_api_sdk/models/operations/sort.rb
198
196
  - lib/open_api_sdk/models/operations/trackcustomer_request.rb
199
197
  - lib/open_api_sdk/models/operations/trackcustomer_requestbody.rb
@@ -207,15 +205,18 @@ files:
207
205
  - lib/open_api_sdk/models/operations/tracksale_requestbody.rb
208
206
  - lib/open_api_sdk/models/operations/tracksale_response.rb
209
207
  - lib/open_api_sdk/models/operations/tracksale_responsebody.rb
210
- - lib/open_api_sdk/models/operations/transferdomain_request.rb
211
- - lib/open_api_sdk/models/operations/transferdomain_requestbody.rb
212
- - lib/open_api_sdk/models/operations/transferdomain_response.rb
213
208
  - lib/open_api_sdk/models/operations/updatedomain_request.rb
214
209
  - lib/open_api_sdk/models/operations/updatedomain_requestbody.rb
215
210
  - lib/open_api_sdk/models/operations/updatedomain_response.rb
216
211
  - lib/open_api_sdk/models/operations/updatelink_request.rb
217
212
  - lib/open_api_sdk/models/operations/updatelink_requestbody.rb
218
213
  - lib/open_api_sdk/models/operations/updatelink_response.rb
214
+ - lib/open_api_sdk/models/operations/updatetag_color.rb
215
+ - lib/open_api_sdk/models/operations/updatetag_request.rb
216
+ - lib/open_api_sdk/models/operations/updatetag_requestbody.rb
217
+ - lib/open_api_sdk/models/operations/updatetag_response.rb
218
+ - lib/open_api_sdk/models/operations/updateworkspace_request.rb
219
+ - lib/open_api_sdk/models/operations/updateworkspace_response.rb
219
220
  - lib/open_api_sdk/models/operations/upsertlink_request.rb
220
221
  - lib/open_api_sdk/models/operations/upsertlink_requestbody.rb
221
222
  - lib/open_api_sdk/models/operations/upsertlink_response.rb
@@ -1,30 +0,0 @@
1
- # Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
2
-
3
- # typed: true
4
- # frozen_string_literal: true
5
-
6
-
7
- module OpenApiSDK
8
- module Operations
9
-
10
-
11
- class SetPrimaryDomainRequest < ::OpenApiSDK::Utils::FieldAugmented
12
- extend T::Sig
13
-
14
- # The domain name.
15
- field :slug, ::String, { 'path_param': { 'field_name': 'slug', 'style': 'simple', 'explode': false } }
16
- # The slug of the project. This field is deprecated – use `workspaceId` instead.
17
- field :project_slug, T.nilable(::String), { 'query_param': { 'field_name': 'projectSlug', 'style': 'form', 'explode': true } }
18
- # The ID of the workspace.
19
- field :workspace_id, T.nilable(::String), { 'query_param': { 'field_name': 'workspaceId', 'style': 'form', 'explode': true } }
20
-
21
-
22
- sig { params(slug: ::String, project_slug: T.nilable(::String), workspace_id: T.nilable(::String)).void }
23
- def initialize(slug: nil, project_slug: nil, workspace_id: nil)
24
- @slug = slug
25
- @project_slug = project_slug
26
- @workspace_id = workspace_id
27
- end
28
- end
29
- end
30
- end
@@ -1,24 +0,0 @@
1
- # Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
2
-
3
- # typed: true
4
- # frozen_string_literal: true
5
-
6
-
7
- module OpenApiSDK
8
- module Operations
9
-
10
-
11
- class TransferDomainRequestBody < ::OpenApiSDK::Utils::FieldAugmented
12
- extend T::Sig
13
-
14
- # The ID of the new workspace to transfer the domain to.
15
- field :new_workspace_id, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('newWorkspaceId') } }
16
-
17
-
18
- sig { params(new_workspace_id: ::String).void }
19
- def initialize(new_workspace_id: nil)
20
- @new_workspace_id = new_workspace_id
21
- end
22
- end
23
- end
24
- end