Class: NftmakerApi::Client::Project

Inherits:
Object
  • Object
show all
Defined in:
lib/nftmaker_api/client/project.rb

Instance Method Summary collapse

Constructor Details

#initialize(client, id) ⇒ Project

Returns a new instance of Project.



3
4
5
6
# File 'lib/nftmaker_api/client/project.rb', line 3

def initialize(client, id)
  @client = client
  @id = id
end

Instance Method Details

#metricsObject



8
9
10
# File 'lib/nftmaker_api/client/project.rb', line 8

def metrics
  @client.get "GetCounts/#{@client.api_key}/#{@id}"
end

#nftsObject



12
13
14
# File 'lib/nftmaker_api/client/project.rb', line 12

def nfts
  NftmakerApi::Client::Nfts.new(@client, project_id: @id)
end

#reservation(address) ⇒ Object



20
21
22
# File 'lib/nftmaker_api/client/project.rb', line 20

def reservation(address)
  NftmakerApi::Client::Reservation.new(@client, project_id: @id, address: address)
end

#reservationsObject



16
17
18
# File 'lib/nftmaker_api/client/project.rb', line 16

def reservations
  NftmakerApi::Client::Reservations.new(@client, project_id: @id)
end