Class: PrintfulAPI::Order

Instance Attribute Summary

Attributes inherited from APIResource

#raw_data

Class Method Summary collapse

Instance Method Summary collapse

Methods included from APIOperations::Save

#save

Methods included from APIOperations::Update

included

Methods included from APIOperations::List

included

Methods included from APIOperations::Get

included

Methods included from APIOperations::Delete

#delete, included

Methods included from APIOperations::Create

included

Methods inherited from APIResource

api_attributes, belongs_to, camelize, has_many, #load_data, singularize, #to_h

Class Method Details

.resource_pathObject

[View source]

21
22
23
# File 'lib/printful_api/order.rb', line 21

def self.resource_path
	'/orders'
end

Instance Method Details

#confirm_for_fulfillmentObject

Confirm draft for fulfillment Approves for fulfillment an order that was saved as a draft. Store owner’s credit card is charged when the order is submitted for fulfillment.

[View source]

27
28
29
30
31
32
33
34
35
# File 'lib/printful_api/order.rb', line 27

def confirm_for_fulfillment

	result = PrintfulAPI.request( :POST, "/orders/#{self.id}/confirm", {} )

	self.load_data( result )

	return true

end