Class: Backend::Api::Request — Documentation by YARD 0.9.12

# Class: Backend::Api::Request

Inherits:
  Object
  - Object
  - Backend::Api::Request
  show all

Extended by:
  ConnectionHelper

Defined in:
  api/request.rb

## Overview

Class that connect to endpoints related to the Requests

## Class Method Summary collapse

- .info(request_id) ⇒ String

  Returns the request info based on the id provided.

- .last_id ⇒ Integer

  Returns the request id of the last one.

- .list ⇒ String

  Get a list of requests.

## Class Method Details

### .info(request_id) ⇒ `String`

Returns the request info based on the id provided

Returns:

- (`String`)

    15
    16
    17
    # File 'api/request.rb', line 15

    def self.info(request_id)
      http_get(['/request/:id', request_id])
    end

### .last_id ⇒ `Integer`

Returns the request id of the last one

Returns:

- (`Integer`)

    21
    22
    23
    # File 'api/request.rb', line 21

    def self.last_id
      http_get('/request/_lastid').to_i
    end

### .list ⇒ `String`

Get a list of requests

Returns:

- (`String`)

    9
    10
    11
    # File 'api/request.rb', line 9

    def self.list
      http_get('/request')
    end