Class: Mercadolibre::Api
- Inherits:
-
Object
- Object
- Mercadolibre::Api
- Includes:
- Core::Apps, Core::Bookmarks, Core::Categories, Core::Currencies, Core::Deals, Core::Feedbacks, Core::ItemVariations, Core::Items, Core::Listings, Core::Locations, Core::Messaging, Core::Metrics, Core::Money, Core::Oauth, Core::OrderBlacklist, Core::OrderNotes, Core::Orders, Core::PickupStores, Core::Pictures, Core::Projects, Core::QuestionBlacklist, Core::Questions, Core::Searching, Core::Shipping, Core::Users
- Defined in:
- lib/mercadolibre/api.rb
Instance Attribute Summary collapse
-
#access_token ⇒ Object
Returns the value of attribute access_token.
-
#site ⇒ Object
Returns the value of attribute site.
Instance Method Summary collapse
- #get_last_response ⇒ Object
- #get_last_result ⇒ Object
-
#initialize(args = {}) ⇒ Api
constructor
A new instance of Api.
Methods included from Core::Users
#get_my_user, #get_seller, #get_user, #get_user_accepted_payment_methods, #get_user_addresses, #get_user_available_listing_types, #get_user_brand, #get_user_brands, #get_user_items, #get_user_listing_type_availability, #get_user_payment_methods, #get_user_promotion_packs, #get_users, #update_user
Methods included from Core::Shipping
#get_item_free_shipping_options, #get_order_shipments, #get_shipment, #get_shipment_labels, #get_shipping_modes, #get_shipping_options, #get_shipping_services, #get_site_free_shipping_options, #get_site_shipping_costs, #get_user_free_shipping_options, #get_user_shipping_costs, #get_user_shipping_modes, #get_user_shipping_preferences, #update_shipment
Methods included from Core::Searching
#get_featured_items, #get_hot_items, #get_search_url, #search_item_ids, #search_items, #search_my_item_ids
Methods included from Core::Questions
#answer_question, #ask_question, #delete_question, #get_question, #search_my_questions, #search_my_questions_total, #search_questions, #search_questions_total
Methods included from Core::QuestionBlacklist
#add_user_to_questions_blacklist, #get_questions_blacklist, #remove_user_from_questions_blacklist
Methods included from Core::Projects
#add_application_to_project, #create_user_project, #delete_user_project, #get_user_project, #remove_application_from_project, #update_user_project
Methods included from Core::Pictures
#add_item_picture, #create_picture, #delete_picture, #get_pictures, #replace_item_pictures
Methods included from Core::PickupStores
#create_item_pickup_store, #create_item_variation_pickup_store, #create_pickup_store, #delete_item_pickup_store, #delete_item_variation_pickup_store, #delete_pickup_store, #get_item_pickup_stores, #get_pickup, #get_pickup_store, #search_pickup_stores, #update_item_pickup_store, #update_item_variation_pickup_store, #update_pickup_store
Methods included from Core::Orders
#get_order, #get_order_billing_info, #search_archived_orders, #search_orders, #search_pending_orders, #search_recent_orders
Methods included from Core::OrderNotes
#create_order_note, #delete_order_note, #get_order_notes, #update_order_note
Methods included from Core::OrderBlacklist
#add_user_to_orders_blacklist, #get_orders_blacklist, #remove_user_from_orders_blacklist
Methods included from Core::Oauth
#authenticate, #authenticate_url, #update_token
Methods included from Core::Money
#get_collection, #get_payment, #get_user_mercadopago_balance
Methods included from Core::Metrics
#get_item_visits_tw, #get_items_visits, #get_total_items_visits, #get_user_items_see_phone_clicked_quantities_tw, #get_user_question_quantities, #get_user_question_quantities_tw, #get_user_see_phone_clicked_quantities, #get_user_see_phone_clicked_quantities_tw, #get_user_visits, #get_user_visits_tw
Methods included from Core::Messaging
#create_attachment, #create_order_message, #create_pack_message, #get_attachment, #get_order_message, #get_order_messages, #get_pack_messages, #get_unread_order_messages, #mark_order_message_as_read
Methods included from Core::Locations
#get_city, #get_countries, #get_country, #get_state, #get_zip_code, #search_zip_codes
Methods included from Core::Listings
#get_listing_exposures, #get_listing_prices, #get_listing_type, #get_listing_types, #get_site, #get_site_domain, #get_site_payment_method_info, #get_site_payment_methods, #get_sites
Methods included from Core::Items
#create_item, #delete_item_attributes, #get_item, #get_item_available_upgrades, #get_item_description, #get_item_identifiers, #get_items, #relist_item, #update_item, #update_item_attributes, #update_item_description, #update_item_identifiers, #validate_item
Methods included from Core::ItemVariations
#create_item_variation, #delete_item_variation, #get_item_variation, #get_item_variations, #update_item_variation
Methods included from Core::Feedbacks
#change_order_buyer_feedback, #change_order_feedback, #change_order_seller_feedback, #create_order_feedback, #get_order_buyer_feedback, #get_order_feedbacks, #get_order_seller_feedback, #reply_order_feedback
Methods included from Core::Deals
#get_deal_products, #get_deals_invited, #remove_item_from_deal, #suggest_item_for_deal, #update_deal_item
Methods included from Core::Currencies
#currency_convertion_rate, #get_currencies, #get_currency
Methods included from Core::Categories
#get_all_categories, #get_category, #get_category_attributes, #get_category_prediction, #get_category_promotion_packs, #get_multiple_category_prediction, #get_site_categories, #get_site_trends
Methods included from Core::Bookmarks
#create_item_bookmark, #delete_item_bookmark, #get_my_bookmarks
Methods included from Core::Apps
#get_application_feeds, #get_application_info, #revoke_application_permissions
Constructor Details
#initialize(args = {}) ⇒ Api
Returns a new instance of Api.
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/mercadolibre/api.rb', line 5 def initialize(args={}) @app_key = args[:app_key] @app_secret = args[:app_secret] @callback_url = args[:callback_url] @access_token = args[:access_token] if args[:endpoint_url].present? @endpoint_url = args[:endpoint_url] else @endpoint_url = 'https://api.mercadolibre.com' end if args[:auth_url].present? @auth_url = args[:auth_url] else @auth_url = 'https://auth.mercadolibre.com.ar' end @site = args[:site] end |
Instance Attribute Details
#access_token ⇒ Object
Returns the value of attribute access_token.
3 4 5 |
# File 'lib/mercadolibre/api.rb', line 3 def access_token @access_token end |
#site ⇒ Object
Returns the value of attribute site.
3 4 5 |
# File 'lib/mercadolibre/api.rb', line 3 def site @site end |
Instance Method Details
#get_last_response ⇒ Object
52 53 54 |
# File 'lib/mercadolibre/api.rb', line 52 def get_last_response @last_response end |
#get_last_result ⇒ Object
56 57 58 |
# File 'lib/mercadolibre/api.rb', line 56 def get_last_result @last_result end |