Method: Fabricio::Networking::AppRequestModelFactory#oom_count_request_model
- Defined in:
- lib/fabricio/networking/app_request_model_factory.rb
#oom_count_request_model(app_id, days, builds) ⇒ Fabricio::Networking::RequestModel
Returns a request model for obtaining the count of ooms
157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 |
# File 'lib/fabricio/networking/app_request_model_factory.rb', line 157 def oom_count_request_model(app_id, days, builds) headers = { 'Content-Type' => 'application/json' } body = { 'query' => 'query oomCountForDaysForBuild($app_id: String!, $builds: [String!]!, $days: Int!) { project(externalId: $app_id) { crashlytics{ oomCounts(builds: $builds, days: $days){ timeSeries{ allTimeCount } } oomSessionCounts(builds: $builds, days: $days){ timeSeries{ allTimeCount } } } } }', 'variables' => { 'app_id' => app_id, 'days' => days, 'builds' => builds } }.to_json model = Fabricio::Networking::RequestModel.new do |config| config.type = :POST config.base_url = FABRIC_GRAPHQL_API_URL config.headers = headers config.body = body end model end |