Class: Sink::Resources::QueryParams

Inherits:
Object
  • Object
show all
Defined in:
lib/sink/resources/query_params.rb

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ QueryParams



7
8
9
# File 'lib/sink/resources/query_params.rb', line 7

def initialize(client:)
  @client = client
end

Instance Method Details

#all_of(params = {}, opts = {}) ⇒ nil

Endpoint with allOf query params



19
20
21
22
23
24
25
26
27
# File 'lib/sink/resources/query_params.rb', line 19

def all_of(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/allOf",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#any_of(params = {}, opts = {}) ⇒ nil

Endpoint with anyOf query params



37
38
39
40
41
42
43
44
45
# File 'lib/sink/resources/query_params.rb', line 37

def any_of(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/anyOf",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#any_of_string_or_array(params = {}, opts = {}) ⇒ nil

Endpoint with anyOf query param that’s string or array of strings



55
56
57
58
59
60
61
62
63
# File 'lib/sink/resources/query_params.rb', line 55

def any_of_string_or_array(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/anyOfStringOrArray",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#array(params = {}, opts = {}) ⇒ nil

Endpoint with array query params



74
75
76
77
78
79
80
81
82
# File 'lib/sink/resources/query_params.rb', line 74

def array(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/array",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#enum(params = {}, opts = {}) ⇒ nil

Endpoint with enum query params



97
98
99
100
101
102
103
104
105
# File 'lib/sink/resources/query_params.rb', line 97

def enum(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/enum",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#object(params = {}, opts = {}) ⇒ nil

Endpoint with object query params



116
117
118
119
120
121
122
123
124
# File 'lib/sink/resources/query_params.rb', line 116

def object(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/object",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#one_of(params = {}, opts = {}) ⇒ nil

Endpoint with oneOf query params



134
135
136
137
138
139
140
141
142
# File 'lib/sink/resources/query_params.rb', line 134

def one_of(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/oneOf",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end

#primitives(params = {}, opts = {}) ⇒ nil

Endpoint with a set of primitive type query params



155
156
157
158
159
160
161
162
163
# File 'lib/sink/resources/query_params.rb', line 155

def primitives(params = {}, opts = {})
  req = {
    method: :get,
    path: "/query_params/primitives",
    query: params,
    model: NilClass
  }
  @client.request(req, opts)
end