Skip to content

Latest commit

 

History

History
76 lines (52 loc) · 1.85 KB

File metadata and controls

76 lines (52 loc) · 1.85 KB

RankVectors::UserApi

All URIs are relative to https://api.rankvectors.com

Method HTTP request Description
get_user_info GET /api/user/me Get authenticated user information

get_user_info

get_user_info

Get authenticated user information

Get information about the authenticated user including credit balance and project count

Examples

require 'time'
require 'rankvectors'
# setup authorization
RankVectors.configure do |config|
  # Configure API key authorization: ApiKeyAuth
  config.api_key['Authorization'] = 'YOUR API KEY'
  # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
  # config.api_key_prefix['Authorization'] = 'Bearer'
end

api_instance = RankVectors::UserApi.new

begin
  # Get authenticated user information
  result = api_instance.get_user_info
  p result
rescue RankVectors::ApiError => e
  puts "Error when calling UserApi->get_user_info: #{e}"
end

Using the get_user_info_with_http_info variant

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

<Array(, Integer, Hash)> get_user_info_with_http_info

begin
  # Get authenticated user information
  data, status_code, headers = api_instance.get_user_info_with_http_info
  p status_code # => 2xx
  p headers # => { ... }
  p data # => <GetUserInfo200Response>
rescue RankVectors::ApiError => e
  puts "Error when calling UserApi->get_user_info_with_http_info: #{e}"
end

Parameters

This endpoint does not need any parameter.

Return type

GetUserInfo200Response

Authorization

ApiKeyAuth

HTTP request headers

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