Sha256: ce29fafa780cadcd419fc7ed2f141f647e3fea87017fee3d773c6e1fc50d36eb
Contents?: true
Size: 860 Bytes
Versions: 4
Compression:
Stored size: 860 Bytes
Contents
# encoding: utf-8 # https://api.crunchbase.com/v/2/organization/#{permalink}/competitors module Crunchbase class Competitor < CBEntity RESOURCE_LIST = 'competitors' attr_reader :type_name, :name, :last_name, :path, :permalink, :title, :started_on, :ended_on, :created_at, :updated_at def initialize(json) @type_name = json['type'] @name = (json['name'] || (json['first_name'].to_s + ' ' + json['last_name'].to_s)) @path = json['path'] @permalink = (json['permalink'] || (json['path'] && json['path'].gsub('organization/', ''))) @title = json['title'] @started_on = json['started_on'] @ended_on = json['ended_on'] @created_at = Time.at(json['created_at']).utc @updated_at = Time.at(json['updated_at']).utc end end end
Version data entries
4 entries across 4 versions & 1 rubygems