Sha256: 60fd31dfbeb4a5c11dfd89fd81c04bbb272bedbd839dc964a4e7e469f70268dd

Contents?: true

Size: 770 Bytes

Versions: 16

Compression:

Stored size: 770 Bytes

Contents

module EventbriteSDK
  class User < Resource
    # Defines user#verify and user#unverify
    #
    # An user logged using Eventbrite we should generate a verification action
    # NOTE: only selected users can verify/unverify other users.
    # POSTS to users/:id/(verify|unverify)
    define_api_actions :verify, :unverify

    resource_path 'users/:id'

    has_many :organizers, object_class: 'Organizer', key: :organizers
    has_many :owned_event_orders, object_class: 'Order', key: :orders
    has_many :owned_events, object_class: 'Event', key: :events

    schema_definition do
      string 'name'
      string 'first_name'
      string 'last_name'
      string 'emails'
      string 'image_id'
    end

    def self.me
      new('id' => 'me')
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
eventbrite_sdk-3.1.5 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.1.4 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.1.3 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.1.2 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.1.1 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.1.0 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.11 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.10 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.9 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.8 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.7 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.6 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.5 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.4 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.3 lib/eventbrite_sdk/user.rb
eventbrite_sdk-3.0.2 lib/eventbrite_sdk/user.rb