dub 0.2.2.pre.alpha.107 → 0.2.2.pre.alpha.109

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7ac60fcb5faed265b25ebd6d258db671cef070d1a2d4cb2b8216c5dec3d87752
4
- data.tar.gz: f4d7998ce9f093630921152f3fd06646e4c0eafb0d0f0201834db7bed641a918
3
+ metadata.gz: 688d94487f4dcf5ce74e05b599e521b0e6b85612b0455df738250dad73cbc50d
4
+ data.tar.gz: c763c05a64d5b5adc226db7a6cb3e6da4815df2860cb8350986ab3b8cc1b3bfa
5
5
  SHA512:
6
- metadata.gz: 269a02b24544963cbc966e87e78848df52b9b4af4e36ea9122f7cd811274566fe1f2513313d655203953619ace0c05ab42d7d9b1fa4f9a71a6e024a3c9b6c1ca
7
- data.tar.gz: 597525754e15aeee7fca5781e2d54c94676b9cdbe59ccfbcdeb803ec28627f6643b3e9e409e1296c37d5a246e48b5cf7296c559ab4a3026530e9daf363c50d48
6
+ metadata.gz: b1f5b8b51b81d2dbf6d1d7aa9fcb5e8a1f61dfa99dfb04f132fa5253d5e009263eccd0fbd0e58bfcd31788a19281e5ccab8186e412a0962f3352022c7a4e9e08
7
+ data.tar.gz: 7b575f1f7676b711f2ec03fa3a0afe212ce59058a36839e1c5224f304a2c16daf92686c0762dc2eee4750ee84fa0faaf6fe7f10d7b20f6091addcdb24a9a757f
@@ -98,7 +98,7 @@ module OpenApiSDK
98
98
  )
99
99
  if r.status == 200
100
100
  if Utils.match_content_type(content_type, 'application/json')
101
- out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), T::Array[::OpenApiSDK::Operations::ResponseBody])
101
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), T::Array[::OpenApiSDK::Operations::GetCustomersResponseBody])
102
102
  res.response_bodies = out
103
103
  end
104
104
  elsif r.status == 400
@@ -566,5 +566,274 @@ module OpenApiSDK
566
566
 
567
567
  res
568
568
  end
569
+
570
+
571
+ sig { params(request: T.nilable(::OpenApiSDK::Operations::RegisterDomainRequestBody), timeout_ms: T.nilable(Integer)).returns(::OpenApiSDK::Operations::RegisterDomainResponse) }
572
+ def register(request, timeout_ms = nil)
573
+ # register - Register a domain
574
+ # Register a domain for the authenticated workspace. Only available for Enterprise Plans.
575
+ url, params = @sdk_configuration.get_server_details
576
+ base_url = Utils.template_url(url, params)
577
+ url = "#{base_url}/domains/register"
578
+ headers = {}
579
+ req_content_type, data, form = Utils.serialize_request_body(request, :request, :json)
580
+ headers['content-type'] = req_content_type
581
+
582
+ if form
583
+ body = Utils.encode_form(form)
584
+ elsif Utils.match_content_type(req_content_type, 'application/x-www-form-urlencoded')
585
+ body = URI.encode_www_form(data)
586
+ else
587
+ body = data
588
+ end
589
+ headers['Accept'] = 'application/json'
590
+ headers['user-agent'] = @sdk_configuration.user_agent
591
+
592
+ security = !@sdk_configuration.nil? && !@sdk_configuration.security_source.nil? ? @sdk_configuration.security_source.call : nil
593
+
594
+ timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
595
+ timeout ||= @sdk_configuration.timeout
596
+
597
+ connection = @sdk_configuration.client
598
+
599
+ hook_ctx = SDKHooks::HookContext.new(
600
+ base_url: base_url,
601
+ oauth2_scopes: nil,
602
+ operation_id: 'registerDomain',
603
+ security_source: @sdk_configuration.security_source
604
+ )
605
+
606
+ error = T.let(nil, T.nilable(StandardError))
607
+ r = T.let(nil, T.nilable(Faraday::Response))
608
+
609
+ begin
610
+ r = connection.post(url) do |req|
611
+ req.body = body
612
+ req.headers.merge!(headers)
613
+ req.options.timeout = timeout unless timeout.nil?
614
+ Utils.configure_request_security(req, security)
615
+
616
+ @sdk_configuration.hooks.before_request(
617
+ hook_ctx: SDKHooks::BeforeRequestHookContext.new(
618
+ hook_ctx: hook_ctx
619
+ ),
620
+ request: req
621
+ )
622
+ end
623
+ rescue StandardError => e
624
+ error = e
625
+ ensure
626
+ if r.nil? || Utils.error_status?(r.status)
627
+ r = @sdk_configuration.hooks.after_error(
628
+ error: error,
629
+ hook_ctx: SDKHooks::AfterErrorHookContext.new(
630
+ hook_ctx: hook_ctx
631
+ ),
632
+ response: r
633
+ )
634
+ else
635
+ r = @sdk_configuration.hooks.after_success(
636
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
637
+ hook_ctx: hook_ctx
638
+ ),
639
+ response: r
640
+ )
641
+ end
642
+
643
+ if r.nil?
644
+ raise error if !error.nil?
645
+ raise 'no response'
646
+ end
647
+ end
648
+
649
+ content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
650
+
651
+ res = ::OpenApiSDK::Operations::RegisterDomainResponse.new(
652
+ status_code: r.status, content_type: content_type, raw_response: r
653
+ )
654
+ if r.status == 201
655
+ if Utils.match_content_type(content_type, 'application/json')
656
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Operations::RegisterDomainResponseBody)
657
+ res.object = out
658
+ end
659
+ elsif r.status == 400
660
+ if Utils.match_content_type(content_type, 'application/json')
661
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::BadRequest)
662
+ res.bad_request = out
663
+ end
664
+ elsif r.status == 401
665
+ if Utils.match_content_type(content_type, 'application/json')
666
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::Unauthorized)
667
+ res.unauthorized = out
668
+ end
669
+ elsif r.status == 403
670
+ if Utils.match_content_type(content_type, 'application/json')
671
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::Forbidden)
672
+ res.forbidden = out
673
+ end
674
+ elsif r.status == 404
675
+ if Utils.match_content_type(content_type, 'application/json')
676
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::NotFound)
677
+ res.not_found = out
678
+ end
679
+ elsif r.status == 409
680
+ if Utils.match_content_type(content_type, 'application/json')
681
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::Conflict)
682
+ res.conflict = out
683
+ end
684
+ elsif r.status == 410
685
+ if Utils.match_content_type(content_type, 'application/json')
686
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::InviteExpired)
687
+ res.invite_expired = out
688
+ end
689
+ elsif r.status == 422
690
+ if Utils.match_content_type(content_type, 'application/json')
691
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::UnprocessableEntity)
692
+ res.unprocessable_entity = out
693
+ end
694
+ elsif r.status == 429
695
+ if Utils.match_content_type(content_type, 'application/json')
696
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::RateLimitExceeded)
697
+ res.rate_limit_exceeded = out
698
+ end
699
+ elsif r.status == 500
700
+ if Utils.match_content_type(content_type, 'application/json')
701
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::InternalServerError)
702
+ res.internal_server_error = out
703
+ end
704
+ end
705
+
706
+ res
707
+ end
708
+
709
+
710
+ sig { params(request: T.nilable(::OpenApiSDK::Operations::CheckDomainStatusRequest), timeout_ms: T.nilable(Integer)).returns(::OpenApiSDK::Operations::CheckDomainStatusResponse) }
711
+ def check_status(request, timeout_ms = nil)
712
+ # check_status - Check the availability of one or more domains
713
+ # Check if a domain name is available for purchase. You can check multiple domains at once.
714
+ url, params = @sdk_configuration.get_server_details
715
+ base_url = Utils.template_url(url, params)
716
+ url = "#{base_url}/domains/status"
717
+ headers = {}
718
+ query_params = Utils.get_query_params(::OpenApiSDK::Operations::CheckDomainStatusRequest, request)
719
+ headers['Accept'] = 'application/json'
720
+ headers['user-agent'] = @sdk_configuration.user_agent
721
+
722
+ security = !@sdk_configuration.nil? && !@sdk_configuration.security_source.nil? ? @sdk_configuration.security_source.call : nil
723
+
724
+ timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
725
+ timeout ||= @sdk_configuration.timeout
726
+
727
+ connection = @sdk_configuration.client
728
+
729
+ hook_ctx = SDKHooks::HookContext.new(
730
+ base_url: base_url,
731
+ oauth2_scopes: nil,
732
+ operation_id: 'checkDomainStatus',
733
+ security_source: @sdk_configuration.security_source
734
+ )
735
+
736
+ error = T.let(nil, T.nilable(StandardError))
737
+ r = T.let(nil, T.nilable(Faraday::Response))
738
+
739
+ begin
740
+ r = connection.get(url) do |req|
741
+ req.headers.merge!(headers)
742
+ req.options.timeout = timeout unless timeout.nil?
743
+ req.params = query_params
744
+ Utils.configure_request_security(req, security)
745
+
746
+ @sdk_configuration.hooks.before_request(
747
+ hook_ctx: SDKHooks::BeforeRequestHookContext.new(
748
+ hook_ctx: hook_ctx
749
+ ),
750
+ request: req
751
+ )
752
+ end
753
+ rescue StandardError => e
754
+ error = e
755
+ ensure
756
+ if r.nil? || Utils.error_status?(r.status)
757
+ r = @sdk_configuration.hooks.after_error(
758
+ error: error,
759
+ hook_ctx: SDKHooks::AfterErrorHookContext.new(
760
+ hook_ctx: hook_ctx
761
+ ),
762
+ response: r
763
+ )
764
+ else
765
+ r = @sdk_configuration.hooks.after_success(
766
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
767
+ hook_ctx: hook_ctx
768
+ ),
769
+ response: r
770
+ )
771
+ end
772
+
773
+ if r.nil?
774
+ raise error if !error.nil?
775
+ raise 'no response'
776
+ end
777
+ end
778
+
779
+ content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
780
+
781
+ res = ::OpenApiSDK::Operations::CheckDomainStatusResponse.new(
782
+ status_code: r.status, content_type: content_type, raw_response: r
783
+ )
784
+ if r.status == 200
785
+ if Utils.match_content_type(content_type, 'application/json')
786
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), T::Array[::OpenApiSDK::Operations::ResponseBody])
787
+ res.response_bodies = out
788
+ end
789
+ elsif r.status == 400
790
+ if Utils.match_content_type(content_type, 'application/json')
791
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::BadRequest)
792
+ res.bad_request = out
793
+ end
794
+ elsif r.status == 401
795
+ if Utils.match_content_type(content_type, 'application/json')
796
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::Unauthorized)
797
+ res.unauthorized = out
798
+ end
799
+ elsif r.status == 403
800
+ if Utils.match_content_type(content_type, 'application/json')
801
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::Forbidden)
802
+ res.forbidden = out
803
+ end
804
+ elsif r.status == 404
805
+ if Utils.match_content_type(content_type, 'application/json')
806
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::NotFound)
807
+ res.not_found = out
808
+ end
809
+ elsif r.status == 409
810
+ if Utils.match_content_type(content_type, 'application/json')
811
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::Conflict)
812
+ res.conflict = out
813
+ end
814
+ elsif r.status == 410
815
+ if Utils.match_content_type(content_type, 'application/json')
816
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::InviteExpired)
817
+ res.invite_expired = out
818
+ end
819
+ elsif r.status == 422
820
+ if Utils.match_content_type(content_type, 'application/json')
821
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::UnprocessableEntity)
822
+ res.unprocessable_entity = out
823
+ end
824
+ elsif r.status == 429
825
+ if Utils.match_content_type(content_type, 'application/json')
826
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::RateLimitExceeded)
827
+ res.rate_limit_exceeded = out
828
+ end
829
+ elsif r.status == 500
830
+ if Utils.match_content_type(content_type, 'application/json')
831
+ out = Crystalline.unmarshal_json(JSON.parse(r.env.response_body), ::OpenApiSDK::Shared::InternalServerError)
832
+ res.internal_server_error = out
833
+ end
834
+ end
835
+
836
+ res
837
+ end
569
838
  end
570
839
  end
@@ -0,0 +1,24 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class CheckDomainStatusRequest < ::Crystalline::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # The domains to search. We only support .link domains for now.
15
+ field :domains, ::Object, { 'query_param': { 'field_name': 'domains', 'style': 'form', 'explode': false } }
16
+
17
+
18
+ sig { params(domains: ::Object).void }
19
+ def initialize(domains: nil)
20
+ @domains = domains
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,60 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class CheckDomainStatusResponse < ::Crystalline::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # HTTP response content type for this operation
15
+ field :content_type, ::String
16
+ # Raw HTTP response; suitable for custom response parsing
17
+ field :raw_response, ::Faraday::Response
18
+ # HTTP response status code for this operation
19
+ field :status_code, ::Integer
20
+ # The server cannot or will not process the request due to something that is perceived to be a client error (e.g., malformed request syntax, invalid request message framing, or deceptive request routing).
21
+ field :bad_request, T.nilable(::OpenApiSDK::Shared::BadRequest)
22
+ # This response is sent when a request conflicts with the current state of the server.
23
+ field :conflict, T.nilable(::OpenApiSDK::Shared::Conflict)
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.
25
+ field :forbidden, T.nilable(::OpenApiSDK::Shared::Forbidden)
26
+ # The server has encountered a situation it does not know how to handle.
27
+ field :internal_server_error, T.nilable(::OpenApiSDK::Shared::InternalServerError)
28
+ # This response is sent when the requested content has been permanently deleted from server, with no forwarding address.
29
+ field :invite_expired, T.nilable(::OpenApiSDK::Shared::InviteExpired)
30
+ # The server cannot find the requested resource.
31
+ field :not_found, T.nilable(::OpenApiSDK::Shared::NotFound)
32
+ # The user has sent too many requests in a given amount of time ("rate limiting")
33
+ field :rate_limit_exceeded, T.nilable(::OpenApiSDK::Shared::RateLimitExceeded)
34
+ # The domain status was retrieved.
35
+ field :response_bodies, T.nilable(T::Array[::OpenApiSDK::Operations::ResponseBody])
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
+ field :unauthorized, T.nilable(::OpenApiSDK::Shared::Unauthorized)
38
+ # The request was well-formed but was unable to be followed due to semantic errors.
39
+ field :unprocessable_entity, T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)
40
+
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), 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), response_bodies: T.nilable(T::Array[::OpenApiSDK::Operations::ResponseBody]), 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, response_bodies: nil, unauthorized: nil, unprocessable_entity: nil)
44
+ @content_type = content_type
45
+ @raw_response = raw_response
46
+ @status_code = status_code
47
+ @bad_request = bad_request
48
+ @conflict = conflict
49
+ @forbidden = forbidden
50
+ @internal_server_error = internal_server_error
51
+ @invite_expired = invite_expired
52
+ @not_found = not_found
53
+ @rate_limit_exceeded = rate_limit_exceeded
54
+ @response_bodies = response_bodies
55
+ @unauthorized = unauthorized
56
+ @unprocessable_entity = unprocessable_entity
57
+ end
58
+ end
59
+ end
60
+ end
@@ -32,14 +32,14 @@ module OpenApiSDK
32
32
  # The user has sent too many requests in a given amount of time ("rate limiting")
33
33
  field :rate_limit_exceeded, T.nilable(::OpenApiSDK::Shared::RateLimitExceeded)
34
34
  # The list of customers.
35
- field :response_bodies, T.nilable(T::Array[::OpenApiSDK::Operations::ResponseBody])
35
+ field :response_bodies, T.nilable(T::Array[::OpenApiSDK::Operations::GetCustomersResponseBody])
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), 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), response_bodies: T.nilable(T::Array[::OpenApiSDK::Operations::ResponseBody]), unauthorized: T.nilable(::OpenApiSDK::Shared::Unauthorized), unprocessable_entity: T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)).void }
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), response_bodies: T.nilable(T::Array[::OpenApiSDK::Operations::GetCustomersResponseBody]), unauthorized: T.nilable(::OpenApiSDK::Shared::Unauthorized), unprocessable_entity: T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)).void }
43
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, response_bodies: nil, unauthorized: nil, unprocessable_entity: nil)
44
44
  @content_type = content_type
45
45
  @raw_response = raw_response
@@ -0,0 +1,60 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class GetCustomersResponseBody < ::Crystalline::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # The date the customer was created.
15
+ field :created_at, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('createdAt') } }
16
+ # Unique identifier for the customer in the client's app.
17
+ field :external_id, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('externalId') } }
18
+ # The unique ID of the customer. You may use either the customer's `id` on Dub (obtained via `/customers` endpoint) or their `externalId` (unique ID within your system, prefixed with `ext_`, e.g. `ext_123`).
19
+ field :id, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('id') } }
20
+ # Name of the customer.
21
+ field :name, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('name') } }
22
+ # Avatar URL of the customer.
23
+ field :avatar, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('avatar') } }
24
+ # Country of the customer.
25
+ field :country, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('country') } }
26
+
27
+ field :discount, T.nilable(::OpenApiSDK::Operations::Discount), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('discount') } }
28
+ # Email of the customer.
29
+ field :email, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('email') } }
30
+
31
+ field :link, T.nilable(::OpenApiSDK::Operations::GetCustomersLink), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('link') } }
32
+
33
+ field :partner, T.nilable(::OpenApiSDK::Operations::GetCustomersPartner), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('partner') } }
34
+
35
+ field :program_id, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('programId') } }
36
+ # Total amount of sales for the customer.
37
+ field :sale_amount, T.nilable(::Float), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('saleAmount') } }
38
+ # Total number of sales for the customer.
39
+ field :sales, T.nilable(::Float), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('sales') } }
40
+
41
+
42
+ sig { params(created_at: ::String, external_id: ::String, id: ::String, name: ::String, avatar: T.nilable(::String), country: T.nilable(::String), discount: T.nilable(::OpenApiSDK::Operations::Discount), email: T.nilable(::String), link: T.nilable(::OpenApiSDK::Operations::GetCustomersLink), partner: T.nilable(::OpenApiSDK::Operations::GetCustomersPartner), program_id: T.nilable(::String), sale_amount: T.nilable(::Float), sales: T.nilable(::Float)).void }
43
+ def initialize(created_at: nil, external_id: nil, id: nil, name: nil, avatar: nil, country: nil, discount: nil, email: nil, link: nil, partner: nil, program_id: nil, sale_amount: nil, sales: nil)
44
+ @created_at = created_at
45
+ @external_id = external_id
46
+ @id = id
47
+ @name = name
48
+ @avatar = avatar
49
+ @country = country
50
+ @discount = discount
51
+ @email = email
52
+ @link = link
53
+ @partner = partner
54
+ @program_id = program_id
55
+ @sale_amount = sale_amount
56
+ @sales = sales
57
+ end
58
+ end
59
+ end
60
+ end
@@ -0,0 +1,24 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class RegisterDomainRequestBody < ::Crystalline::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # The domain to claim. We only support .link domains for now.
15
+ field :domain, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('domain') } }
16
+
17
+
18
+ sig { params(domain: ::String).void }
19
+ def initialize(domain: nil)
20
+ @domain = domain
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,60 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+
11
+ class RegisterDomainResponse < ::Crystalline::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # HTTP response content type for this operation
15
+ field :content_type, ::String
16
+ # Raw HTTP response; suitable for custom response parsing
17
+ field :raw_response, ::Faraday::Response
18
+ # HTTP response status code for this operation
19
+ field :status_code, ::Integer
20
+ # The server cannot or will not process the request due to something that is perceived to be a client error (e.g., malformed request syntax, invalid request message framing, or deceptive request routing).
21
+ field :bad_request, T.nilable(::OpenApiSDK::Shared::BadRequest)
22
+ # This response is sent when a request conflicts with the current state of the server.
23
+ field :conflict, T.nilable(::OpenApiSDK::Shared::Conflict)
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.
25
+ field :forbidden, T.nilable(::OpenApiSDK::Shared::Forbidden)
26
+ # The server has encountered a situation it does not know how to handle.
27
+ field :internal_server_error, T.nilable(::OpenApiSDK::Shared::InternalServerError)
28
+ # This response is sent when the requested content has been permanently deleted from server, with no forwarding address.
29
+ field :invite_expired, T.nilable(::OpenApiSDK::Shared::InviteExpired)
30
+ # The server cannot find the requested resource.
31
+ field :not_found, T.nilable(::OpenApiSDK::Shared::NotFound)
32
+ # The domain was registered.
33
+ field :object, T.nilable(::OpenApiSDK::Operations::RegisterDomainResponseBody)
34
+ # The user has sent too many requests in a given amount of time ("rate limiting")
35
+ field :rate_limit_exceeded, T.nilable(::OpenApiSDK::Shared::RateLimitExceeded)
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
+ field :unauthorized, T.nilable(::OpenApiSDK::Shared::Unauthorized)
38
+ # The request was well-formed but was unable to be followed due to semantic errors.
39
+ field :unprocessable_entity, T.nilable(::OpenApiSDK::Shared::UnprocessableEntity)
40
+
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), 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), object: T.nilable(::OpenApiSDK::Operations::RegisterDomainResponseBody), 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, forbidden: nil, internal_server_error: nil, invite_expired: nil, not_found: nil, object: nil, rate_limit_exceeded: nil, unauthorized: nil, unprocessable_entity: nil)
44
+ @content_type = content_type
45
+ @raw_response = raw_response
46
+ @status_code = status_code
47
+ @bad_request = bad_request
48
+ @conflict = conflict
49
+ @forbidden = forbidden
50
+ @internal_server_error = internal_server_error
51
+ @invite_expired = invite_expired
52
+ @not_found = not_found
53
+ @object = object
54
+ @rate_limit_exceeded = rate_limit_exceeded
55
+ @unauthorized = unauthorized
56
+ @unprocessable_entity = unprocessable_entity
57
+ end
58
+ end
59
+ end
60
+ end
@@ -0,0 +1,30 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+
7
+ module OpenApiSDK
8
+ module Operations
9
+
10
+ # The domain was registered.
11
+ class RegisterDomainResponseBody < ::Crystalline::FieldAugmented
12
+ extend T::Sig
13
+
14
+ # The domain name.
15
+ field :domain, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('domain') } }
16
+ # The expiration timestamp of the domain (Unix timestamp in milliseconds).
17
+ field :expiration, ::Float, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('expiration') } }
18
+ # The status of the domain registration.
19
+ field :status, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('status') } }
20
+
21
+
22
+ sig { params(domain: ::String, expiration: ::Float, status: ::String).void }
23
+ def initialize(domain: nil, expiration: nil, status: nil)
24
+ @domain = domain
25
+ @expiration = expiration
26
+ @status = status
27
+ end
28
+ end
29
+ end
30
+ end
@@ -11,49 +11,22 @@ module OpenApiSDK
11
11
  class ResponseBody < ::Crystalline::FieldAugmented
12
12
  extend T::Sig
13
13
 
14
- # The date the customer was created.
15
- field :created_at, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('createdAt') } }
16
- # Unique identifier for the customer in the client's app.
17
- field :external_id, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('externalId') } }
18
- # The unique ID of the customer. You may use either the customer's `id` on Dub (obtained via `/customers` endpoint) or their `externalId` (unique ID within your system, prefixed with `ext_`, e.g. `ext_123`).
19
- field :id, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('id') } }
20
- # Name of the customer.
21
- field :name, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('name') } }
22
- # Avatar URL of the customer.
23
- field :avatar, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('avatar') } }
24
- # Country of the customer.
25
- field :country, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('country') } }
26
-
27
- field :discount, T.nilable(::OpenApiSDK::Operations::Discount), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('discount') } }
28
- # Email of the customer.
29
- field :email, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('email') } }
30
-
31
- field :link, T.nilable(::OpenApiSDK::Operations::GetCustomersLink), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('link') } }
32
-
33
- field :partner, T.nilable(::OpenApiSDK::Operations::GetCustomersPartner), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('partner') } }
34
-
35
- field :program_id, T.nilable(::String), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('programId') } }
36
- # Total amount of sales for the customer.
37
- field :sale_amount, T.nilable(::Float), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('saleAmount') } }
38
- # Total number of sales for the customer.
39
- field :sales, T.nilable(::Float), { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('sales') } }
40
-
41
-
42
- sig { params(created_at: ::String, external_id: ::String, id: ::String, name: ::String, avatar: T.nilable(::String), country: T.nilable(::String), discount: T.nilable(::OpenApiSDK::Operations::Discount), email: T.nilable(::String), link: T.nilable(::OpenApiSDK::Operations::GetCustomersLink), partner: T.nilable(::OpenApiSDK::Operations::GetCustomersPartner), program_id: T.nilable(::String), sale_amount: T.nilable(::Float), sales: T.nilable(::Float)).void }
43
- def initialize(created_at: nil, external_id: nil, id: nil, name: nil, avatar: nil, country: nil, discount: nil, email: nil, link: nil, partner: nil, program_id: nil, sale_amount: nil, sales: nil)
44
- @created_at = created_at
45
- @external_id = external_id
46
- @id = id
47
- @name = name
48
- @avatar = avatar
49
- @country = country
50
- @discount = discount
51
- @email = email
52
- @link = link
53
- @partner = partner
54
- @program_id = program_id
55
- @sale_amount = sale_amount
56
- @sales = sales
14
+ # Whether the domain is available.
15
+ field :available, T::Boolean, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('available') } }
16
+ # The domain name.
17
+ field :domain, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('domain') } }
18
+ # Whether the domain is a premium domain.
19
+ field :premium, T::Boolean, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('premium') } }
20
+ # The price description.
21
+ field :price, ::String, { 'format_json': { 'letter_case': ::OpenApiSDK::Utils.field_name('price') } }
22
+
23
+
24
+ sig { params(available: T::Boolean, domain: ::String, premium: T::Boolean, price: ::String).void }
25
+ def initialize(available: nil, domain: nil, premium: nil, price: nil)
26
+ @available = available
27
+ @domain = domain
28
+ @premium = premium
29
+ @price = price
57
30
  end
58
31
  end
59
32
  end
@@ -87,6 +87,12 @@ module OpenApiSDK
87
87
  autoload :DeleteDomainRequest, 'open_api_sdk/models/operations/deletedomain_request.rb'
88
88
  autoload :DeleteDomainResponseBody, 'open_api_sdk/models/operations/deletedomain_responsebody.rb'
89
89
  autoload :DeleteDomainResponse, 'open_api_sdk/models/operations/deletedomain_response.rb'
90
+ autoload :RegisterDomainRequestBody, 'open_api_sdk/models/operations/registerdomain_requestbody.rb'
91
+ autoload :RegisterDomainResponseBody, 'open_api_sdk/models/operations/registerdomain_responsebody.rb'
92
+ autoload :RegisterDomainResponse, 'open_api_sdk/models/operations/registerdomain_response.rb'
93
+ autoload :CheckDomainStatusRequest, 'open_api_sdk/models/operations/checkdomainstatus_request.rb'
94
+ autoload :ResponseBody, 'open_api_sdk/models/operations/responsebody.rb'
95
+ autoload :CheckDomainStatusResponse, 'open_api_sdk/models/operations/checkdomainstatus_response.rb'
90
96
  autoload :Mode, 'open_api_sdk/models/operations/mode.rb'
91
97
  autoload :TrackLeadRequestBody, 'open_api_sdk/models/operations/tracklead_requestbody.rb'
92
98
  autoload :Click, 'open_api_sdk/models/operations/click.rb'
@@ -106,7 +112,7 @@ module OpenApiSDK
106
112
  autoload :GetCustomersPartner, 'open_api_sdk/models/operations/getcustomers_partner.rb'
107
113
  autoload :GetCustomersType, 'open_api_sdk/models/operations/getcustomers_type.rb'
108
114
  autoload :Discount, 'open_api_sdk/models/operations/discount.rb'
109
- autoload :ResponseBody, 'open_api_sdk/models/operations/responsebody.rb'
115
+ autoload :GetCustomersResponseBody, 'open_api_sdk/models/operations/getcustomers_responsebody.rb'
110
116
  autoload :GetCustomersResponse, 'open_api_sdk/models/operations/getcustomers_response.rb'
111
117
  autoload :CreateCustomerRequestBody, 'open_api_sdk/models/operations/createcustomer_requestbody.rb'
112
118
  autoload :CreateCustomerLink, 'open_api_sdk/models/operations/createcustomer_link.rb'
@@ -61,9 +61,9 @@ module OpenApiSDK
61
61
  end
62
62
  @language = 'ruby'
63
63
  @openapi_doc_version = '0.0.1'
64
- @sdk_version = '0.2.2-alpha.107'
64
+ @sdk_version = '0.2.2-alpha.109'
65
65
  @gen_version = '2.563.0'
66
- @user_agent = 'speakeasy-sdk/ruby 0.2.2-alpha.107 2.563.0 0.0.1 dub'
66
+ @user_agent = 'speakeasy-sdk/ruby 0.2.2-alpha.109 2.563.0 0.0.1 dub'
67
67
  end
68
68
 
69
69
  sig { returns([String, T::Hash[Symbol, String]]) }
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.2.2.pre.alpha.107
4
+ version: 0.2.2.pre.alpha.109
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dub
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-06-02 00:00:00.000000000 Z
11
+ date: 2025-06-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -208,6 +208,8 @@ files:
208
208
  - lib/open_api_sdk/models/operations/bulkupdatelinks_requestbody.rb
209
209
  - lib/open_api_sdk/models/operations/bulkupdatelinks_response.rb
210
210
  - lib/open_api_sdk/models/operations/bulkupdatelinks_testvariants.rb
211
+ - lib/open_api_sdk/models/operations/checkdomainstatus_request.rb
212
+ - lib/open_api_sdk/models/operations/checkdomainstatus_response.rb
211
213
  - lib/open_api_sdk/models/operations/click.rb
212
214
  - lib/open_api_sdk/models/operations/color.rb
213
215
  - lib/open_api_sdk/models/operations/country.rb
@@ -274,6 +276,7 @@ files:
274
276
  - lib/open_api_sdk/models/operations/getcustomers_queryparam_sortorder.rb
275
277
  - lib/open_api_sdk/models/operations/getcustomers_request.rb
276
278
  - lib/open_api_sdk/models/operations/getcustomers_response.rb
279
+ - lib/open_api_sdk/models/operations/getcustomers_responsebody.rb
277
280
  - lib/open_api_sdk/models/operations/getcustomers_type.rb
278
281
  - lib/open_api_sdk/models/operations/getlinkinfo_request.rb
279
282
  - lib/open_api_sdk/models/operations/getlinkinfo_response.rb
@@ -319,6 +322,9 @@ files:
319
322
  - lib/open_api_sdk/models/operations/queryparam_sortorder.rb
320
323
  - lib/open_api_sdk/models/operations/queryparam_status.rb
321
324
  - lib/open_api_sdk/models/operations/queryparam_trigger.rb
325
+ - lib/open_api_sdk/models/operations/registerdomain_requestbody.rb
326
+ - lib/open_api_sdk/models/operations/registerdomain_response.rb
327
+ - lib/open_api_sdk/models/operations/registerdomain_responsebody.rb
322
328
  - lib/open_api_sdk/models/operations/requestbody.rb
323
329
  - lib/open_api_sdk/models/operations/responsebody.rb
324
330
  - lib/open_api_sdk/models/operations/retrieveanalytics_request.rb