Skip to content

Latest commit

 

History

History
74 lines (50 loc) · 2 KB

OTAApi.md

File metadata and controls

74 lines (50 loc) · 2 KB

HandyAPI::OTAApi

All URIs are relative to https://www.handyfeeling.com/api/handy/v2

Method HTTP request Description
latest GET /ota/latest Get the latest available firmware available for the provided model and branch.

latest

latest(model, branch)

Get the latest available firmware available for the provided model and branch.

Get the latest available firmware available for the provided model and branch.

Examples

require 'time'
require 'handy_api'

api_instance = HandyAPI::OTAApi.new
model = HandyAPI::Model::H01 # Model | The model to get latest firmware for.
branch = HandyAPI::Branch::MASTER # Branch | The branch to get latest firmware for.

begin
  # Get the latest available firmware available for the provided model and branch.
  result = api_instance.latest(model, branch)
  p result
rescue HandyAPI::ApiError => e
  puts "Error when calling OTAApi->latest: #{e}"
end

Using the latest_with_http_info variant

This returns an Array which contains the response data, status code and headers.

<Array(, Integer, Hash)> latest_with_http_info(model, branch)

begin
  # Get the latest available firmware available for the provided model and branch.
  data, status_code, headers = api_instance.latest_with_http_info(model, branch)
  p status_code # => 2xx
  p headers # => { ... }
  p data # => <OtaLatestResponse>
rescue HandyAPI::ApiError => e
  puts "Error when calling OTAApi->latest_with_http_info: #{e}"
end

Parameters

Name Type Description Notes
model Model The model to get latest firmware for.
branch Branch The branch to get latest firmware for.

Return type

OtaLatestResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json