Plugin Directory

Changeset 2679091


Ignore:
Timestamp:
02/15/2022 12:51:14 PM (4 years ago)
Author:
fooevents
Message:

Release 1.6.31

Location:
fooevents-calendar
Files:
65 added
1 deleted
7 edited

Legend:

Unmodified
Added
Removed
  • fooevents-calendar/trunk/class-fooevents-calendar.php

    r2643358 r2679091  
    929929
    930930            // post_events has been modified to new endpoint.
    931             $resp = $client->post_events( $event_params, $organizations['organizations'][0]['id'] );
     931            $resp = $client->post_events( $organizations['organizations'][0]['id'], $event_params );
    932932
    933933        } else {
    934934
    935935            // post_events has been modified to new endpoint.
    936             $resp = $client->post_event( $eventbrite_id, $event_params, $organizations['organizations'][0]['id'] );
     936            $resp = $client->post_event( $eventbrite_id, $organizations['organizations'][0]['id'], $event_params );
    937937
    938938        }
     
    14311431        if ( is_plugin_active( 'fooevents_bookings/fooevents-bookings.php' ) || is_plugin_active_for_network( 'fooevents_bookings/fooevents-bookings.php' ) ) {
    14321432
    1433             $fooevents_bookings = new FooEvents_Bookings();
     1433            $fooevents_bookings = new FooEvents_Bookings( true );
    14341434            $booking_events     = $fooevents_bookings->get_bookings_for_calendar( $include_cats );
    14351435
  • fooevents-calendar/trunk/default.po

    r2643358 r2679091  
    22msgstr ""
    33"Project-Id-Version: FooEvents Calendar\n"
    4 "POT-Creation-Date: 2021-12-13 12:55+0200\n"
    5 "PO-Revision-Date: 2021-12-13 12:55+0200\n"
     4"POT-Creation-Date: 2022-02-15 10:41+0200\n"
     5"PO-Revision-Date: 2022-02-15 10:41+0200\n"
    66"Last-Translator: \n"
    77"Language-Team: \n"
  • fooevents-calendar/trunk/fooevents-calendar.php

    r2643358 r2679091  
    44 * Plugin Name: Events Calendar for FooEvents
    55 * Description: Add event information to any post, page or custom post type and display it in a stylish calendar.
    6  * Version: 1.6.29
     6 * Version: 1.6.31
    77 * Author: FooEvents
    88 * Plugin URI: https://www.fooevents.com/fooevents-calendar/
  • fooevents-calendar/trunk/readme.txt

    r2643358 r2679091  
    33Tags: calendar, events calendar, event, booking, tickets
    44Requires at least: 5
    5 Tested up to: 5.8.1
    6 Stable tag: 1.6.29
     5Tested up to: 5.9
     6Stable tag: 1.6.31
    77License: GPLv2
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    157157
    158158== Changelog ==
     159= 1.6.31 =
     160* FIXED: PHP 8.0 compatibility *
     161* FIXED: Duplicate booking options when using calendar shortcode bug *
     162* FIXED: Various other small bugs *
     163* TESTED ON: WordPress 5.9 and WooCommerce 6.2.0 *
     164
    159165= 1.6.29 =
    160166* FIXED: Various small bugs *
  • fooevents-calendar/trunk/updatelog.txt

    r2643358 r2679091  
    33
    44------------------
     51.6.31
     6FIXED: PHP 8.0 compatibility
     7FIXED: Duplicate booking options when using calendar shortcode bug
     8FIXED: Various other small bugs
     9TESTED ON: WordPress 5.9 and WooCommerce 6.2.0
     10
    5111.6.29
    612FIXED: Various small bugs
  • fooevents-calendar/trunk/vendors/eventbrite/AccessMethods.php

    r2594887 r2679091  
    33// Access methods.  This file could be auto-generated.
    44
    5 class AccessMethods
    6 {
    7 
    8 /**
    9 * get_categories
    10 * GET /categories/
    11 *        Returns a list of :format:`category` as ``categories``, including
    12 *        subcategories nested.
    13 */
    14 public function get_categories($expand=array(), $query_params=array()) {
    15     return $this->get(sprintf("/categories/"), $expand=$expand, $query_params=$query_params);
     5class AccessMethods {
     6
     7
     8    /**
     9     get_categories
     10     GET /categories/
     11            Returns a list of :format:`category` as ``categories``, including
     12            subcategories nested.
     13     */
     14    public function get_categories( $expand = array(), $query_params = array() ) {
     15        return $this->get( sprintf( '/categories/' ), $expand = $expand, $query_params = $query_params );
     16    }
     17
     18
     19    /**
     20     get_category
     21     GET /categories/:id/
     22            Gets a :format:`category` by ID as ``category``.
     23     */
     24    public function get_category( $id, $expand = array(), $query_params = array() ) {
     25        return $this->get( sprintf( '/categories/%s/', $id ), $expand = $expand, $query_params = $query_params );
     26    }
     27
     28
     29    /**
     30     get_subcategories
     31     GET /subcategories/
     32            Returns a list of :format:`subcategory` as ``subcategories``.
     33     */
     34    public function get_subcategories( $expand = array(), $query_params = array() ) {
     35        return $this->get( sprintf( '/subcategories/' ), $expand = $expand, $query_params = $query_params );
     36    }
     37
     38
     39    /**
     40     get_subcategory
     41     GET /subcategories/:id/
     42            Gets a :format:`subcategory` by ID as ``subcategory``.
     43     */
     44    public function get_subcategory( $id, $expand = array(), $query_params = array() ) {
     45        return $this->get( sprintf( '/subcategories/%s/', $id ), $expand = $expand, $query_params = $query_params );
     46    }
     47
     48
     49    /**
     50     get_event_search
     51     GET /events/search/
     52            Allows you to retrieve a paginated response of public :format:`event` objects from across Eventbrite’s directory, regardless of which user owns the event.
     53     */
     54    public function get_event_search( $expand = array(), $query_params = array() ) {
     55        return $this->get( sprintf( '/events/search' ), $expand = $expand, $query_params = $query_params );
     56    }
     57
     58
     59    /**
     60     post_events
     61     POST /events/
     62            Makes a new event, and returns an :format:`event` for the specified event. Does not support the creation of repeating
     63            event series.
     64            field event.venue_id
     65            The ID of a previously-created venue to associate with this event.
     66            You can omit this field or set it to ``null`` if you set ``online_event``.
     67     */
     68    public function post_events( $uid, $data = array() ) {
     69        return $this->post( sprintf( '/organizations/%s/events/', $uid ), $data = $data );
     70    }
     71
     72
     73    /**
     74     get_event
     75     GET /events/:id/
     76            Returns an :format:`event` for the specified event. Many of Eventbrite’s API use cases revolve around pulling details
     77            of a specific event within an Eventbrite account. Does not support fetching a repeating event series parent
     78            (see :ref:`get-series-by-id`).
     79     */
     80    public function get_event( $id, $expand = array(), $query_params = array() ) {
     81        return $this->get( sprintf( '/events/%s/', $id ), $expand = $expand, $query_params = $query_params );
     82    }
     83
     84
     85    /**
     86     post_event
     87     POST /events/:id/
     88            Updates an event. Returns an :format:`event` for the specified event. Does not support updating a repeating event
     89            series parent (see POST /series/:id/).
     90     */
     91    public function post_event( $id, $uid, $data = array() ) {
     92        return $this->post( sprintf( '/events/%s/', $id ), $data = $data );
     93    }
     94
     95
     96    /**
     97     post_event_publish
     98     POST /events/:id/publish/
     99            Publishes an event if it has not already been deleted. In order for publish to be permitted, the event must have all
     100            necessary information, including a name and description, an organizer, at least one ticket, and valid payment options.
     101            This API endpoint will return argument errors for event fields that fail to validate the publish requirements. Returns
     102            a boolean indicating success or failure of the publish.
     103            field_error event.name MISSING
     104            Your event must have a name to be published.
     105            field_error event.start MISSING
     106            Your event must have a start date to be published.
     107            field_error event.end MISSING
     108            Your event must have an end date to be published.
     109            field_error event.start.timezone MISSING
     110            Your event start and end dates must have matching time zones to be published.
     111            field_error event.organizer MISSING
     112            Your event must have an organizer to be published.
     113            field_error event.currency MISSING
     114            Your event must have a currency to be published.
     115            field_error event.currency INVALID
     116            Your event must have a valid currency to be published.
     117            field_error event.tickets MISSING
     118            Your event must have at least one ticket to be published.
     119            field_error event.tickets.N.name MISSING
     120            All tickets must have names in order for your event to be published. The N will be the ticket class ID with the
     121            error.
     122            field_error event.tickets.N.quantity_total MISSING
     123            All non-donation tickets must have an available quantity value in order for your event to be published. The N
     124            will be the ticket class ID with the error.
     125            field_error event.tickets.N.cost MISSING
     126            All non-donation tickets must have a cost (which can be ``0.00`` for free tickets) in order for your event to
     127            be published. The N will be the ticket class ID with the error.
     128     */
     129    public function post_event_publish( $id, $data = array() ) {
     130        return $this->post( sprintf( '/events/%s/publish/', $id ), $data = $data );
     131    }
     132
     133
     134    /**
     135     post_event_unpublish
     136     POST /events/:id/unpublish/
     137            Unpublishes an event. In order for a free event to be unpublished, it must not have any pending or completed orders,
     138            even if the event is in the past. In order for a paid event to be unpublished, it must not have any pending or completed
     139            orders, unless the event has been completed and paid out. Returns a boolean indicating success or failure of the
     140            unpublish.
     141     */
     142    public function post_event_unpublish( $id, $data = array() ) {
     143        return $this->post( sprintf( '/events/%s/unpublish/', $id ), $data = $data );
     144    }
     145
     146
     147    /**
     148     post_event_cancel
     149     POST /events/:id/cancel/
     150            Cancels an event if it has not already been deleted. In order for cancel to be permitted, there must be no pending or
     151            completed orders. Returns a boolean indicating success or failure of the cancel.
     152     */
     153    public function post_event_cancel( $id, $data = array() ) {
     154        return $this->post( sprintf( '/events/%s/cancel/', $id ), $data = $data );
     155    }
     156
     157
     158    /**
     159     delete_event
     160     DELETE /events/:id/
     161            Deletes an event if the delete is permitted. In order for a delete to be permitted, there must be no pending or
     162            completed orders. Returns a boolean indicating success or failure of the delete.
     163     */
     164    public function delete_event( $id, $data = array() ) {
     165        return $this->delete( sprintf( '/events/%s/', $id ), $data = $data );
     166    }
     167
     168
     169    /**
     170     get_event_display_settings
     171     GET /events/:id/display_settings/
     172            Retrieves the display settings for an event.
     173     */
     174    public function get_event_display_settings( $id, $expand = array(), $query_params = array() ) {
     175        return $this->get( sprintf( '/events/%s/display_settings/', $id ), $expand = $expand, $query_params = $query_params );
     176    }
     177
     178
     179    /**
     180     post_event_display_settings
     181     POST /events/:id/display_settings/
     182            Updates the display settings for an event.
     183     */
     184    public function post_event_display_settings( $id, $data = array() ) {
     185        return $this->post( sprintf( '/events/%s/display_settings/', $id ), $data = $data );
     186    }
     187
     188
     189    /**
     190     get_event_ticket_classes
     191     GET /events/:id/ticket_classes/
     192            Returns a :ref:`paginated <pagination>` response with a key of
     193            ``ticket_classes``, containing a list of :format:`ticket_class`.
     194     */
     195    public function get_event_ticket_classes( $id, $expand = array(), $query_params = array() ) {
     196        return $this->get( sprintf( '/events/%s/ticket_classes/', $id ), $expand = $expand, $query_params = $query_params );
     197    }
     198
     199
     200    /**
     201     post_event_ticket_classes
     202     POST /events/:id/ticket_classes/
     203            Creates a new ticket class, returning the result as a :format:`ticket_class`
     204            under the key ``ticket_class``.
     205     */
     206    public function post_event_ticket_classes( $id, $data = array() ) {
     207        return $this->post( sprintf( '/events/%s/ticket_classes/', $id ), $data = $data );
     208    }
     209
     210
     211    /**
     212     get_event_ticket_class
     213     GET /events/:id/ticket_classes/:ticket_class_id/
     214            Gets and returns a single :format:`ticket_class` by ID, as the key
     215            ``ticket_class``.
     216     */
     217    public function get_event_ticket_class( $id, $ticket_class_id, $expand = array(), $query_params = array() ) {
     218        return $this->get( sprintf( '/events/%s/ticket_classes/%s/', $id, $ticket_class_id ), $expand = $expand, $query_params = $query_params );
     219    }
     220
     221
     222    /**
     223     post_event_ticket_class
     224     POST /events/:id/ticket_classes/:ticket_class_id/
     225            Updates an existing ticket class, returning the updated result as a :format:`ticket_class` under the key ``ticket_class``.
     226     */
     227    public function post_event_ticket_class( $id, $ticket_class_id, $data = array() ) {
     228        return $this->post( sprintf( '/events/%s/ticket_classes/%s/', $id, $ticket_class_id ), $data = $data );
     229    }
     230
     231
     232    /**
     233     delete_event_ticket_class
     234     DELETE /events/:id/ticket_classes/:ticket_class_id/
     235            Deletes the ticket class. Returns ``{"deleted": true}``.
     236     */
     237    public function delete_event_ticket_class( $id, $ticket_class_id, $data = array() ) {
     238        return $this->delete( sprintf( '/events/%s/ticket_classes/%s/', $id, $ticket_class_id ), $data = $data );
     239    }
     240
     241
     242    /**
     243     get_event_canned_questions
     244     GET /events/:id/canned_questions/
     245            This endpoint returns canned questions of a single event (examples: first name, last name, company, prefix, etc.). This endpoint will return :format:`question`.
     246     */
     247    public function get_event_canned_questions( $id, $expand = array(), $query_params = array() ) {
     248        return $this->get( sprintf( '/events/%s/canned_questions/', $id ), $expand = $expand, $query_params = $query_params );
     249    }
     250
     251
     252    /**
     253     get_event_questions
     254     GET /events/:id/questions/
     255            Eventbrite allows event organizers to add custom questions that attendees fill
     256            out upon registration. This endpoint can be helpful for determining what
     257            custom information is collected and available per event.
     258            This endpoint will return :format:`question`.
     259     */
     260    public function get_event_questions( $id, $expand = array(), $query_params = array() ) {
     261        return $this->get( sprintf( '/events/%s/questions/', $id ), $expand = $expand, $query_params = $query_params );
     262    }
     263
     264
     265    /**
     266     get_event_question
     267     GET /events/:id/questions/:question_id/
     268            This endpoint will return :format:`question` for a specific question id.
     269     */
     270    public function get_event_question( $id, $question_id, $expand = array(), $query_params = array() ) {
     271        return $this->get( sprintf( '/events/%s/questions/%s/', $id, $question_id ), $expand = $expand, $query_params = $query_params );
     272    }
     273
     274
     275    /**
     276     get_event_attendees
     277     GET /events/:id/attendees/
     278            Returns a :ref:`paginated <pagination>` response with a key of ``attendees``, containing a list of :format:`attendee`.
     279     */
     280    public function get_event_attendees( $id, $expand = array(), $query_params = array() ) {
     281        return $this->get( sprintf( '/events/%s/attendees/', $id ), $expand = $expand, $query_params = $query_params );
     282    }
     283
     284
     285    /**
     286     get_event_attendee
     287     GET /events/:id/attendees/:attendee_id/
     288            Returns a single :format:`attendee` by ID, as the key ``attendee``.
     289     */
     290    public function get_event_attendee( $id, $attendee_id, $expand = array(), $query_params = array() ) {
     291        return $this->get( sprintf( '/events/%s/attendees/%s/', $id, $attendee_id ), $expand = $expand, $query_params = $query_params );
     292    }
     293
     294
     295    /**
     296     get_event_orders
     297     GET /events/:id/orders/
     298            Returns a :ref:`paginated <pagination>` response with a key of ``orders``, containing a list of :format:`order` against this event.
     299     */
     300    public function get_event_orders( $id, $expand = array(), $query_params = array() ) {
     301        return $this->get( sprintf( '/events/%s/orders/', $id ), $expand = $expand, $query_params = $query_params );
     302    }
     303
     304
     305    /**
     306     get_event_discounts
     307     GET /events/:id/discounts/
     308            Returns a :ref:`paginated <pagination>` response with a key of ``discounts``,
     309            containing a list of :format:`discounts <discount>` available on this event.
     310            field_error event_id NOT_FOUND
     311            The event id you are attempting to use does not exist.
     312     */
     313    public function get_event_discounts( $id, $expand = array(), $query_params = array() ) {
     314        return $this->get( sprintf( '/events/%s/discounts/', $id ), $expand = $expand, $query_params = $query_params );
     315    }
     316
     317
     318    /**
     319     post_event_discounts
     320     POST /events/:id/discounts/
     321            Creates a new discount; returns the result as a :format:`discount` as the key ``discount``.
     322     */
     323    public function post_event_discounts( $id, $data = array() ) {
     324        return $this->post( sprintf( '/events/%s/discounts/', $id ), $data = $data );
     325    }
     326
     327
     328    /**
     329     get_event_discount
     330     GET /events/:id/discounts/:discount_id/
     331            Gets a :format:`discount` by ID as the key ``discount``.
     332     */
     333    public function get_event_discount( $id, $discount_id, $expand = array(), $query_params = array() ) {
     334        return $this->get( sprintf( '/events/%s/discounts/%s/', $id, $discount_id ), $expand = $expand, $query_params = $query_params );
     335    }
     336
     337
     338    /**
     339     post_event_discount
     340     POST /events/:id/discounts/:discount_id/
     341            Updates a discount; returns the result as a :format:`discount` as the key ``discount``.
     342     */
     343    public function post_event_discount( $id, $discount_id, $data = array() ) {
     344        return $this->post( sprintf( '/events/%s/discounts/%s/', $id, $discount_id ), $data = $data );
     345    }
     346
     347
     348    /**
     349     get_event_public_discounts
     350     GET /events/:id/public_discounts/
     351            Returns a :ref:`paginated <pagination>` response with a key of ``discounts``, containing a list of public :format:`discounts <discount>` available on this event.
     352            Note that public discounts and discounts have exactly the same form and structure; they're just namespaced separately, and public ones (and the public GET endpoints) are visible to anyone who can see the event.
     353     */
     354    public function get_event_public_discounts( $id, $expand = array(), $query_params = array() ) {
     355        return $this->get( sprintf( '/events/%s/public_discounts/', $id ), $expand = $expand, $query_params = $query_params );
     356    }
     357
     358
     359    /**
     360     post_event_public_discounts
     361     POST /events/:id/public_discounts/
     362            Creates a new public discount; returns the result as a :format:`discount` as the key ``discount``.
     363     */
     364    public function post_event_public_discounts( $id, $data = array() ) {
     365        return $this->post( sprintf( '/events/%s/public_discounts/', $id ), $data = $data );
     366    }
     367
     368
     369    /**
     370     get_event_public_discount
     371     GET /events/:id/public_discounts/:discount_id/
     372            Gets a public :format:`discount` by ID as the key ``discount``.
     373     */
     374    public function get_event_public_discount( $id, $discount_id, $expand = array(), $query_params = array() ) {
     375        return $this->get( sprintf( '/events/%s/public_discounts/%s/', $id, $discount_id ), $expand = $expand, $query_params = $query_params );
     376    }
     377
     378
     379    /**
     380     post_event_public_discount
     381     POST /events/:id/public_discounts/:discount_id/
     382            Updates a public discount; returns the result as a :format:`discount` as the key ``discount``.
     383     */
     384    public function post_event_public_discount( $id, $discount_id, $data = array() ) {
     385        return $this->post( sprintf( '/events/%s/public_discounts/%s/', $id, $discount_id ), $data = $data );
     386    }
     387
     388
     389    /**
     390     delete_event_public_discount
     391     DELETE /events/:id/public_discounts/:discount_id/
     392            Deletes a public discount.
     393     */
     394    public function delete_event_public_discount( $id, $discount_id, $data = array() ) {
     395        return $this->delete( sprintf( '/events/%s/public_discounts/%s/', $id, $discount_id ), $data = $data );
     396    }
     397
     398
     399    /**
     400     get_event_access_codes
     401     GET /events/:id/access_codes/
     402            Returns a :ref:`paginated <pagination>` response with a key of ``access_codes``, containing a list of :format:`access_codes <access_code>` available on this event.
     403     */
     404    public function get_event_access_codes( $id, $expand = array(), $query_params = array() ) {
     405        return $this->get( sprintf( '/events/%s/access_codes/', $id ), $expand = $expand, $query_params = $query_params );
     406    }
     407
     408
     409    /**
     410     post_event_access_codes
     411     POST /events/:id/access_codes/
     412            Creates a new access code; returns the result as a :format:`access_code` as the key ``access_code``.
     413     */
     414    public function post_event_access_codes( $id, $data = array() ) {
     415        return $this->post( sprintf( '/events/%s/access_codes/', $id ), $data = $data );
     416    }
     417
     418
     419    /**
     420     get_event_access_code
     421     GET /events/:id/access_codes/:access_code_id/
     422            Gets a :format:`access_code` by ID as the key ``access_code``.
     423     */
     424    public function get_event_access_code( $id, $access_code_id, $expand = array(), $query_params = array() ) {
     425        return $this->get( sprintf( '/events/%s/access_codes/%s/', $id, $access_code_id ), $expand = $expand, $query_params = $query_params );
     426    }
     427
     428
     429    /**
     430     post_event_access_code
     431     POST /events/:id/access_codes/:access_code_id/
     432            Updates an access code; returns the result as a :format:`access_code` as the
     433            key ``access_code``.
     434     */
     435    public function post_event_access_code( $id, $access_code_id, $data = array() ) {
     436        return $this->post( sprintf( '/events/%s/access_codes/%s/', $id, $access_code_id ), $data = $data );
     437    }
     438
     439
     440    /**
     441     get_event_transfers
     442     GET /events/:id/transfers/
     443            Returns a list of :format:`transfers` for the event.
     444     */
     445    public function get_event_transfers( $id, $expand = array(), $query_params = array() ) {
     446        return $this->get( sprintf( '/events/%s/transfers/', $id ), $expand = $expand, $query_params = $query_params );
     447    }
     448
     449
     450    /**
     451     get_event_teams
     452     GET /events/:id/teams/
     453            Returns a list of :format:`teams` for the event.
     454     */
     455    public function get_event_teams( $id, $expand = array(), $query_params = array() ) {
     456        return $this->get( sprintf( '/events/%s/teams/', $id ), $expand = $expand, $query_params = $query_params );
     457    }
     458
     459
     460    /**
     461     get_event_team
     462     GET /events/:id/teams/:team_id/
     463            Returns information for a single :format:`teams`.
     464     */
     465    public function get_event_team( $id, $team_id, $expand = array(), $query_params = array() ) {
     466        return $this->get( sprintf( '/events/%s/teams/%s/', $id, $team_id ), $expand = $expand, $query_params = $query_params );
     467    }
     468
     469
     470    /**
     471     get_event_teams_attendees
     472     GET /events/:id/teams/:team_id/attendees/
     473            Returns :format:`attendees` for a single :format:`teams`.
     474     */
     475    public function get_event_teams_attendees( $id, $team_id, $expand = array(), $query_params = array() ) {
     476        return $this->get( sprintf( '/events/%s/teams/%s/attendees/', $id, $team_id ), $expand = $expand, $query_params = $query_params );
     477    }
     478
     479
     480    /**
     481     post_series
     482     POST /series/
     483            Creates a new repeating event series. The POST data must include information for at least one event date in the series.
     484            .. _get-series-by-id:
     485     */
     486    public function post_series( $data = array() ) {
     487        return $this->post( sprintf( '/series/' ), $data = $data );
     488    }
     489
     490
     491    /**
     492     get_one_series
     493     GET /series/:id/
     494            Returns a repeating event series parent object for the specified repeating event series.
     495            .. _post-series-by-id:
     496     */
     497    public function get_one_series( $id, $expand = array(), $query_params = array() ) {
     498        return $this->get( sprintf( '/series/%s/', $id ), $expand = $expand, $query_params = $query_params );
     499    }
     500
     501
     502    /**
     503     post_one_series
     504     POST /series/:id/
     505            Updates a repeating event series parent object, and optionally also creates more event dates or updates or deletes
     506            existing event dates in the series. In order for a series date to be deleted or updated, there must be no pending or
     507            completed orders for that date.
     508            .. _publish-series-by-id:
     509     */
     510    public function post_one_series( $id, $data = array() ) {
     511        return $this->post( sprintf( '/series/%s/', $id ), $data = $data );
     512    }
     513
     514
     515    /**
     516     post_series_publish
     517     POST /series/:id/publish/
     518            Publishes a repeating event series and all of its occurrences that are not already canceled or deleted. Once a date is cancelled it can still be uncancelled and can be viewed by the public. A deleted date cannot be undeleted and cannot by viewed by the public. In order for
     519            publish to be permitted, the event must have all necessary information, including a name and description, an organizer,
     520            at least one ticket, and valid payment options. This API endpoint will return argument errors for event fields that
     521            fail to validate the publish requirements. Returns a boolean indicating success or failure of the publish.
     522            field_error event.name MISSING
     523            Your event must have a name to be published.
     524            field_error event.start MISSING
     525            Your event must have a start date to be published.
     526            field_error event.end MISSING
     527            Your event must have an end date to be published.
     528            field_error event.start.timezone MISSING
     529            Your event start and end dates must have matching time zones to be published.
     530            field_error event.organizer MISSING
     531            Your event must have an organizer to be published.
     532            field_error event.currency MISSING
     533            Your event must have a currency to be published.
     534            field_error event.currency INVALID
     535            Your event must have a valid currency to be published.
     536            field_error event.tickets MISSING
     537            Your event must have at least one ticket to be published.
     538            field_error event.tickets.N.name MISSING
     539            All tickets must have names in order for your event to be published. The N will be the ticket class ID with the
     540            error.
     541            field_error event.tickets.N.quantity_total MISSING
     542            All non-donation tickets must have an available quantity value in order for your event to be published. The N
     543            will be the ticket class ID with the error.
     544            field_error event.tickets.N.cost MISSING
     545            All non-donation tickets must have a cost (which can be ``0.00`` for free tickets) in order for your event to
     546            be published. The N will be the ticket class ID with the error.
     547            .. _unpublish-series-by-id:
     548     */
     549    public function post_series_publish( $id, $data = array() ) {
     550        return $this->post( sprintf( '/series/%s/publish/', $id ), $data = $data );
     551    }
     552
     553
     554    /**
     555     post_series_unpublish
     556     POST /series/:id/unpublish/
     557            Unpublishes a repeating event series and all of its occurrences that are not already completed, canceled, or deleted. In
     558            order for a free series to be unpublished, it must not have any pending or completed orders for any dates, even past
     559            dates. In order for a paid series to be unpublished, it must not have any pending or completed orders for any dates,
     560            except that completed orders for past dates that have been completed and paid out do not prevent an unpublish. Returns
     561            a boolean indicating success or failure of the unpublish.
     562            .. _cancel-series-by-id:
     563     */
     564    public function post_series_unpublish( $id, $data = array() ) {
     565        return $this->post( sprintf( '/series/%s/unpublish/', $id ), $data = $data );
     566    }
     567
     568
     569    /**
     570     post_series_cancel
     571     POST /series/:id/cancel/
     572            Cancels a repeating event series and all of its occurrences that are not already canceled or deleted. In order for
     573            cancel to be permitted, there must be no pending or completed orders for any dates in the series. Returns a boolean
     574            indicating success or failure of the cancel.
     575            .. _delete-series-by-id:
     576     */
     577    public function post_series_cancel( $id, $data = array() ) {
     578        return $this->post( sprintf( '/series/%s/cancel/', $id ), $data = $data );
     579    }
     580
     581
     582    /**
     583     delete_one_series
     584     DELETE /series/:id/
     585            Deletes a repeating event series and all of its occurrences if the delete is permitted. In order for a delete to be
     586            permitted, there must be no pending or completed orders for any dates in the series. Returns a boolean indicating
     587            success or failure of the delete.
     588            .. _get-series-events:
     589     */
     590    public function delete_one_series( $id, $data = array() ) {
     591        return $this->delete( sprintf( '/series/%s/', $id ), $data = $data );
     592    }
     593
     594
     595    /**
     596     get_series_events
     597     GET /series/:id/events/
     598            Returns all of the events that belong to this repeating event series.
     599            .. _post-series-dates:
     600     */
     601    public function get_series_events( $id, $expand = array(), $query_params = array() ) {
     602        return $this->get( sprintf( '/series/%s/events/', $id ), $expand = $expand, $query_params = $query_params );
     603    }
     604
     605
     606    /**
     607     post_series_events
     608     POST /series/:id/events/
     609            Creates more event dates or updates or deletes existing event dates in a repeating event series. In order for a series
     610            date to be deleted or updated, there must be no pending or completed orders for that date.
     611     */
     612    public function post_series_events( $id, $data = array() ) {
     613        return $this->post( sprintf( '/series/%s/events/', $id ), $data = $data );
     614    }
     615
     616
     617    /**
     618     get_formatss
     619     GET /formats/
     620            Returns a list of :format:`format` as ``formats``.
     621     */
     622    public function get_formatss( $expand = array(), $query_params = array() ) {
     623        return $this->get( sprintf( '/formats/' ), $expand = $expand, $query_params = $query_params );
     624    }
     625
     626
     627    /**
     628     get_formats
     629     GET /formats/:id/
     630            Gets a :format:`format` by ID as ``format``.*/
     631    public function get_formats( $id, $expand = array(), $query_params = array() ) {
     632        return $this->get( sprintf( '/formats/%s/', $id ), $expand = $expand, $query_params = $query_params );
     633    }
     634
     635
     636    /**
     637     get_media
     638     GET /media/:id/
     639            Return an :format:`image` for a given id.
     640            .. _get-media-upload:
     641     */
     642    public function get_media( $id, $expand = array(), $query_params = array() ) {
     643        return $this->get( sprintf( '/media/%s/', $id ), $expand = $expand, $query_params = $query_params );
     644    }
     645
     646
     647    /**
     648     get_media_upload
     649     GET /media/upload/
     650            See :ref:`media-uploads`.
     651            .. _post-media-upload:
     652     */
     653    public function get_media_upload( $expand = array(), $query_params = array() ) {
     654        return $this->get( sprintf( '/media/upload/' ), $expand = $expand, $query_params = $query_params );
     655    }
     656
     657
     658    /**
     659     post_media_upload
     660     POST /media/upload/
     661            See :ref:`media-uploads`.*/
     662    public function post_media_upload( $data = array() ) {
     663        return $this->post( sprintf( '/media/upload/' ), $data = $data );
     664    }
     665
     666
     667    /**
     668     get_order
     669     GET /orders/:id/
     670            Gets an :format:`order` by ID as the key ``order``.
     671     */
     672    public function get_order( $id, $expand = array(), $query_params = array() ) {
     673        return $this->get( sprintf( '/orders/%s/', $id ), $expand = $expand, $query_params = $query_params );
     674    }
     675
     676
     677    /**
     678     post_organizers
     679     POST /organizers/
     680            Makes a new organizer. Returns an :format:`organizer` as ``organizer``.
     681            field_error organizer.name DUPLICATE
     682            You already have another organizer with this name.
     683            field_error organizer.short_name UNAVAILABLE
     684            There is already another organizer or event with this short name.
     685            field_error organizer.logo_id INVALID
     686            This is not a valid image.
     687            field_error organizer.facebook INVALID
     688            This is not a valid Facebook profile URL.
     689            field_error organizer.facebook NO_GROUP_PAGES
     690            The Facebook URL cannot be a group page.
     691     */
     692    public function post_organizers( $data = array() ) {
     693        return $this->post( sprintf( '/organizers/' ), $data = $data );
     694    }
     695
     696
     697    /**
     698     get_organizer
     699     GET /organizers/:id/
     700            Gets an :format:`organizer` by ID as ``organizer``.
     701     */
     702    public function get_organizer( $id, $expand = array(), $query_params = array() ) {
     703        return $this->get( sprintf( '/organizers/%s/', $id ), $expand = $expand, $query_params = $query_params );
     704    }
     705
     706
     707    /**
     708     post_organizer
     709     POST /organizers/:id/
     710            Updates an :format:`organizer` and returns it as as ``organizer``.
     711            field_error organizer.name DUPLICATE
     712            You already have another organizer with this name.
     713            field_error organizer.short_name UNAVAILABLE
     714            There is already another organizer or event with this short name.
     715            field_error organizer.logo_id INVALID
     716            This is not a valid image.
     717            field_error organizer.facebook INVALID
     718            This is not a valid Facebook profile URL.
     719            field_error organizer.facebook NO_GROUP_PAGES
     720            The Facebook URL cannot be a group page.
     721     */
     722    public function post_organizer( $id, $data = array() ) {
     723        return $this->post( sprintf( '/organizers/%s/', $id ), $data = $data );
     724    }
     725
     726
     727    /**
     728     get_organizers_events
     729     GET /organizers/:id/events/
     730            Gets events of the :format:`organizer`.
     731     */
     732    public function get_organizers_events( $id, $expand = array(), $query_params = array() ) {
     733        return $this->get( sprintf( '/organizers/%s/events/', $id ), $expand = $expand, $query_params = $query_params );
     734    }
     735
     736
     737    /**
     738     get_refund_request
     739     GET /refund_requests/:id/
     740            Gets a :format:`refund-request` for the specified refund request.
     741            error NOT_AUTHORIZED
     742            Only the order's buyer can create a refund request
     743            error FIELD_UNKNOWN
     744            The refund request id provided is unknown
     745     */
     746    public function get_refund_request( $id, $expand = array(), $query_params = array() ) {
     747        return $this->get( sprintf( '/refund_requests/%s/', $id ), $expand = $expand, $query_params = $query_params );
     748    }
     749
     750
     751    /**
     752     post_refund_request
     753     POST /refund_requests/:id/
     754            Update a :format:`refund-request` for a specific order. Each element in items is a :format:`refund-item`
     755            error NOT_AUTHORIZED
     756            Only the order's buyer can create a refund request
     757            error FIELD_UNKNOWN
     758            The refund request id provided is unknown
     759            error INVALID_REFUND_REQUEST_STATUS
     760            The refund request is not the correct status for the change
     761     */
     762    public function post_refund_request( $id, $data = array() ) {
     763        return $this->post( sprintf( '/refund_requests/%s/', $id ), $data = $data );
     764    }
     765
     766
     767    /**
     768     post_refund_requests
     769     POST /refund_requests/
     770            Creates a :format:`refund-request` for a specific order. Each element in items is a :format:`refund-item`
     771            error NOT_AUTHORIZED
     772            Only the order's buyer can create a refund request
     773            error FIELD_UNKNOWN
     774            The order id provided is unknown
     775            error EVENT_DOES_NOT_ALLOW_REFUND_REQUESTS
     776            According to organizer definition, the event does not allow the creation of refund requests.
     777            error EXISTING_REFUND_REQUEST_FOR_ORDER
     778            The order already has a refund request
     779            error INVALID_ORDER_STATE
     780            The order status is not allowed to request a refund. It must be placed.*/
     781    public function post_refund_requests( $data = array() ) {
     782        return $this->post( sprintf( '/refund_requests/' ), $data = $data );
     783    }
     784
     785
     786    /**
     787     get_reports_sales
     788     GET /reports/sales/
     789            Returns a response of the aggregate sales data.
     790     */
     791    public function get_reports_sales( $expand = array(), $query_params = array() ) {
     792        return $this->get( sprintf( '/reports/sales/' ), $expand = $expand, $query_params = $query_params );
     793    }
     794
     795
     796    /**
     797     get_reports_attendees
     798     GET /reports/attendees/
     799            Returns a response of the aggregate attendees data.
     800     */
     801    public function get_reports_attendees( $expand = array(), $query_params = array() ) {
     802        return $this->get( sprintf( '/reports/attendees/' ), $expand = $expand, $query_params = $query_params );
     803    }
     804
     805
     806    /**
     807     get_system_timezones
     808     GET /system/timezones/
     809            Returns a :ref:`paginated <pagination>` response with a key of ``timezones``,
     810            containing a list of :format:`timezones <timezone>`.
     811     */
     812    public function get_system_timezones( $expand = array(), $query_params = array() ) {
     813        return $this->get( sprintf( '/system/timezones/' ), $expand = $expand, $query_params = $query_params );
     814    }
     815
     816
     817    /**
     818     get_system_regions
     819     GET /system/regions/
     820            Returns a single page response with a key of ``regions``,
     821            containing a list of :format:`regions`.
     822     */
     823    public function get_system_regions( $expand = array(), $query_params = array() ) {
     824        return $this->get( sprintf( '/system/regions/' ), $expand = $expand, $query_params = $query_params );
     825    }
     826
     827
     828    /**
     829     get_system_countries
     830     GET /system/countries/
     831            Returns a single page response with a key of ``countries``,
     832            containing a list of :format:`countries`.
     833     */
     834    public function get_system_countries( $expand = array(), $query_params = array() ) {
     835        return $this->get( sprintf( '/system/countries/' ), $expand = $expand, $query_params = $query_params );
     836    }
     837
     838
     839    /**
     840     post_tracking_beacons
     841     POST /tracking_beacons/
     842            Makes a new tracking beacon. Returns an :format:`tracking_beacon` as ``tracking_beacon``. Either ``event_id`` or ``user_id`` is required for each tracking beacon. If the ``event_id`` is provided, the tracking pixel will fire only for that event. If the ``user_id`` is provided, the tracking pixel will fire for all events organized by that user.
     843            field_error tracking_beacon.event_id INVALID
     844            This is not a valid event.
     845            field_error tracking_beacon.user_id INVALID
     846            This is not a valid user.
     847     */
     848    public function post_tracking_beacons( $data = array() ) {
     849        return $this->post( sprintf( '/tracking_beacons/' ), $data = $data );
     850    }
     851
     852
     853    /**
     854     get_tracking_beacon
     855     GET /tracking_beacons/:tracking_beacons_id/
     856            Returns the :format:`tracking_beacon` with the specified :tracking_beacons_id.
     857     */
     858    public function get_tracking_beacon( $tracking_beacons_id, $expand = array(), $query_params = array() ) {
     859        return $this->get( sprintf( '/tracking_beacons/%s/', $tracking_beacons_id ), $expand = $expand, $query_params = $query_params );
     860    }
     861
     862
     863    /**
     864     post_tracking_beacon
     865     POST /tracking_beacons/:tracking_beacons_id/
     866            Updates the :format:`tracking_beacons` with the specified :tracking_beacons_id. Though ``event_id`` and ``user_id`` are not individually required, it is a requirement to have a tracking beacon where either one must exist. Returns an :format:`tracking_beacon` as ``tracking_beacon``.
     867     */
     868    public function post_tracking_beacon( $tracking_beacons_id, $data = array() ) {
     869        return $this->post( sprintf( '/tracking_beacons/%s/', $tracking_beacons_id ), $data = $data );
     870    }
     871
     872
     873    /**
     874     delete_tracking_beacon
     875     DELETE /tracking_beacons/:tracking_beacons_id/
     876            Delete the :format:`tracking_beacons` with the specified :tracking_beacons_id.
     877     */
     878    public function delete_tracking_beacon( $tracking_beacons_id, $data = array() ) {
     879        return $this->delete( sprintf( '/tracking_beacons/%s/', $tracking_beacons_id ), $data = $data );
     880    }
     881
     882
     883    /**
     884     get_event_tracking_beacons
     885     GET /events/:event_id/tracking_beacons/
     886            Returns the list of :format:`tracking_beacon` for the event :event_id
     887     */
     888    public function get_event_tracking_beacons( $event_id, $expand = array(), $query_params = array() ) {
     889        return $this->get( sprintf( '/events/%s/tracking_beacons/', $event_id ), $expand = $expand, $query_params = $query_params );
     890    }
     891
     892
     893    /**
     894     get_user_tracking_beacons
     895     GET /users/:user_id/tracking_beacons/
     896            Returns the list of :format:`tracking_beacon` for the user :user_id
     897     */
     898    public function get_user_tracking_beacons( $user_id, $expand = array(), $query_params = array() ) {
     899        return $this->get( sprintf( '/users/%s/tracking_beacons/', $user_id ), $expand = $expand, $query_params = $query_params );
     900    }
     901
     902
     903    /**
     904     get_user
     905     GET /users/:id/
     906            Returns a :format:`user` for the specified user as ``user``. If you want to get details about the currently authenticated user, use ``/users/me/``.
     907     */
     908    public function get_user( $id, $expand = array(), $query_params = array() ) {
     909        return $this->get( sprintf( '/users/%s/', $id ), $expand = $expand, $query_params = $query_params );
     910    }
     911
     912
     913    /**
     914     get_user_orders
     915     GET /users/:id/orders/
     916            Returns a :ref:`paginated <pagination>` response of :format:`orders <order>`, under the key ``orders``, of all orders the user has placed (i.e. where the user was the person buying the tickets).
     917            :param int id: The id assigned to a user.
     918            :param datetime changed_since: (optional) Only return attendees changed on or after the time given.
     919            .. note:: A datetime represented as a string in ISO8601 combined date and time format, always in UTC.
     920     */
     921    public function get_user_orders( $id, $expand = array(), $query_params = array() ) {
     922        return $this->get( sprintf( '/users/%s/orders/', $id ), $expand = $expand, $query_params = $query_params );
     923    }
     924
     925
     926    /**
     927     get_user_organizers
     928     GET /users/:id/organizers/
     929            Returns a :ref:`paginated <pagination>` response of :format:`organizer` objects that are owned by the user.
     930     */
     931    public function get_user_organizers( $id, $expand = array(), $query_params = array() ) {
     932        return $this->get( sprintf( '/users/%s/organizers/', $id ), $expand = $expand, $query_params = $query_params );
     933    }
     934
     935
     936    /**
     937     get_user_owned_events
     938     GET /users/:id/owned_events/
     939            Returns a :ref:`paginated <pagination>` response of :format:`events <event>`, under
     940            the key ``events``, of all events the user owns (i.e. events they are organising)
     941     */
     942    public function get_user_owned_events( $id, $expand = array(), $query_params = array() ) {
     943        return $this->get( sprintf( '/organizations/%s/events/', $id ), $expand = $expand, $query_params = $query_params );
     944    }
     945
     946    public function get_user_organizations( $id, $expand = array(), $query_params = array() ) {
     947        return $this->get( sprintf( '/users/me/organizations/', $id ), $expand = $expand, $query_params = $query_params );
     948    }
     949
     950    /**
     951     get_user_events
     952     GET /users/:id/events/
     953            Returns a :ref:`paginated <pagination>` response of :format:`events <event>`, under the key ``events``, of all events the user has access to
     954     */
     955    public function get_user_events( $id, $expand = array(), $query_params = array() ) {
     956        return $this->get( sprintf( '/users/%s/events/', $id ), $expand = $expand, $query_params = $query_params );
     957    }
     958
     959
     960    /**
     961     get_user_venues
     962     GET /users/:id/venues/
     963            Returns a paginated response of :format:`venue` objects that are owned by the user.
     964     */
     965    public function get_user_venues( $id, $expand = array(), $query_params = array() ) {
     966        return $this->get( sprintf( '/users/%s/venues/', $id ), $expand = $expand, $query_params = $query_params );
     967    }
     968
     969
     970    /**
     971     get_user_owned_event_attendees
     972     GET /users/:id/owned_event_attendees/
     973            Returns a :ref:`paginated <pagination>` response of :format:`attendees <attendee>`,
     974            under the key ``attendees``, of attendees visiting any of the events the user owns
     975            (events that would be returned from ``/users/:id/owned_events/``)
     976     */
     977    public function get_user_owned_event_attendees( $id, $expand = array(), $query_params = array() ) {
     978        return $this->get( sprintf( '/users/%s/owned_event_attendees/', $id ), $expand = $expand, $query_params = $query_params );
     979    }
     980
     981
     982    /**
     983     get_user_owned_event_orders
     984     GET /users/:id/owned_event_orders/
     985            Returns a :ref:`paginated <pagination>` response of :format:`orders <order>`,
     986            under the key ``orders``, of orders placed against any of the events the user owns
     987            (events that would be returned from ``/users/:id/owned_events/``)
     988     */
     989    public function get_user_owned_event_orders( $id, $expand = array(), $query_params = array() ) {
     990        return $this->get( sprintf( '/users/%s/owned_event_orders/', $id ), $expand = $expand, $query_params = $query_params );
     991    }
     992
     993
     994    /**
     995     get_user_contact_lists
     996     GET /users/:id/contact_lists/
     997            Returns a list of :format:`contact_list` that the user owns as the key
     998            ``contact_lists``.
     999     */
     1000    public function get_user_contact_lists( $id, $expand = array(), $query_params = array() ) {
     1001        return $this->get( sprintf( '/users/%s/contact_lists/', $id ), $expand = $expand, $query_params = $query_params );
     1002    }
     1003
     1004
     1005    /**
     1006     post_user_contact_lists
     1007     POST /users/:id/contact_lists/
     1008            Makes a new :format:`contact_list` for the user and returns it as
     1009            ``contact_list``.
     1010     */
     1011    public function post_user_contact_lists( $id, $data = array() ) {
     1012        return $this->post( sprintf( '/users/%s/contact_lists/', $id ), $data = $data );
     1013    }
     1014
     1015
     1016    /**
     1017     get_user_contact_list
     1018     GET /users/:id/contact_lists/:contact_list_id/
     1019            Gets a user's :format:`contact_list` by ID as ``contact_list``.
     1020     */
     1021    public function get_user_contact_list( $id, $contact_list_id, $expand = array(), $query_params = array() ) {
     1022        return $this->get( sprintf( '/users/%s/contact_lists/%s/', $id, $contact_list_id ), $expand = $expand, $query_params = $query_params );
     1023    }
     1024
     1025
     1026    /**
     1027     post_user_contact_list
     1028     POST /users/:id/contact_lists/:contact_list_id/
     1029            Updates the :format:`contact_list` and returns it as ``contact_list``.
     1030     */
     1031    public function post_user_contact_list( $id, $contact_list_id, $data = array() ) {
     1032        return $this->post( sprintf( '/users/%s/contact_lists/%s/', $id, $contact_list_id ), $data = $data );
     1033    }
     1034
     1035
     1036    /**
     1037     delete_user_contact_list
     1038     DELETE /users/:id/contact_lists/:contact_list_id/
     1039            Deletes the contact list. Returns ``{"deleted": true}``.
     1040     */
     1041    public function delete_user_contact_list( $id, $contact_list_id, $data = array() ) {
     1042        return $this->delete( sprintf( '/users/%s/contact_lists/%s/', $id, $contact_list_id ), $data = $data );
     1043    }
     1044
     1045
     1046    /**
     1047     get_user_contact_lists_contacts
     1048     GET /users/:id/contact_lists/:contact_list_id/contacts/
     1049            Returns the :format:`contacts <contact>` on the contact list
     1050            as ``contacts``.
     1051     */
     1052    public function get_user_contact_lists_contacts( $id, $contact_list_id, $expand = array(), $query_params = array() ) {
     1053        return $this->get( sprintf( '/users/%s/contact_lists/%s/contacts/', $id, $contact_list_id ), $expand = $expand, $query_params = $query_params );
     1054    }
     1055
     1056
     1057    /**
     1058     post_user_contact_lists_contacts
     1059     POST /users/:id/contact_lists/:contact_list_id/contacts/
     1060            Adds a new contact to the contact list. Returns ``{"created": true}``.
     1061            There is no way to update entries in the list; just delete the old one
     1062            and add the updated version.
     1063     */
     1064    public function post_user_contact_lists_contacts( $id, $contact_list_id, $data = array() ) {
     1065        return $this->post( sprintf( '/users/%s/contact_lists/%s/contacts/', $id, $contact_list_id ), $data = $data );
     1066    }
     1067
     1068
     1069    /**
     1070     delete_user_contact_lists_contacts
     1071     DELETE /users/:id/contact_lists/:contact_list_id/contacts/
     1072            Deletes the specified contact from the contact list.
     1073            Returns ``{"deleted": true}``.
     1074     */
     1075    public function delete_user_contact_lists_contacts( $id, $contact_list_id, $data = array() ) {
     1076        return $this->delete( sprintf( '/users/%s/contact_lists/%s/contacts/', $id, $contact_list_id ), $data = $data );
     1077    }
     1078
     1079
     1080    /**
     1081     get_user_bookmarks
     1082     GET /users/:id/bookmarks/
     1083            Gets all the user's saved events.
     1084            In order to update the saved events list, the user must unsave or save each event.
     1085            A user is authorized to only see his/her saved events.
     1086     */
     1087    public function get_user_bookmarks( $id, $expand = array(), $query_params = array() ) {
     1088        return $this->get( sprintf( '/users/%s/bookmarks/', $id ), $expand = $expand, $query_params = $query_params );
     1089    }
     1090
     1091
     1092    /**
     1093     post_user_bookmarks_save
     1094     POST /users/:id/bookmarks/save/
     1095            Adds a new bookmark for the user. Returns ``{"created": true}``.
     1096            A user is only authorized to save his/her own events.
     1097     */
     1098    public function post_user_bookmarks_save( $id, $data = array() ) {
     1099        return $this->post( sprintf( '/users/%s/bookmarks/save/', $id ), $data = $data );
     1100    }
     1101
     1102
     1103    /**
     1104     post_user_bookmarks_unsave
     1105     POST /users/:id/bookmarks/unsave/
     1106            Removes the specified bookmark from the event for the user. Returns ``{"deleted": true}``.
     1107            A user is only authorized to unsave his/her own events.
     1108            error NOT_AUTHORIZED
     1109            You are not authorized to unsave an event for this user.
     1110            error ARGUMENTS_ERROR
     1111            There are errors with your arguments.
     1112     */
     1113    public function post_user_bookmarks_unsave( $id, $data = array() ) {
     1114        return $this->post( sprintf( '/users/%s/bookmarks/unsave/', $id ), $data = $data );
     1115    }
     1116
     1117
     1118    /**
     1119     get_venue
     1120     GET /venues/:id/
     1121            Returns a :format:`venue` object.
     1122     */
     1123    public function get_venue( $id, $expand = array(), $query_params = array() ) {
     1124        return $this->get( sprintf( '/venues/%s/', $id ), $expand = $expand, $query_params = $query_params );
     1125    }
     1126
     1127
     1128    /**
     1129     post_venue
     1130     POST /venues/:id/
     1131            Updates a :format:`venue` and returns it as an object.
     1132     */
     1133    public function post_venue( $id, $data = array() ) {
     1134        return $this->post( sprintf( '/venues/%s/', $id ), $data = $data );
     1135    }
     1136
     1137
     1138    /**
     1139     post_venues
     1140     POST /venues/
     1141            Creates a new :format:`venue` with associated :format:`address`.
     1142            ..start-internal
     1143     */
     1144    public function post_venues( $data = array() ) {
     1145        return $this->post( sprintf( '/venues/' ), $data = $data );
     1146    }
     1147
     1148
     1149    /**
     1150     get_venues_search
     1151     GET /venues/search/
     1152            Search for venues. Returns a list of venue objects.
     1153            ..end-internal
     1154     */
     1155    public function get_venues_search( $expand = array(), $query_params = array() ) {
     1156        return $this->get( sprintf( '/venues/search/' ), $expand = $expand, $query_params = $query_params );
     1157    }
     1158
     1159
     1160    /**
     1161     get_venues_events
     1162     GET /venues/:id/events/
     1163            Returns events of a given :format:`venue`.
     1164     */
     1165    public function get_venues_events( $id, $expand = array(), $query_params = array() ) {
     1166        return $this->get( sprintf( '/venues/%s/events/', $id ), $expand = $expand, $query_params = $query_params );
     1167    }
     1168
     1169
     1170    /**
     1171     get_webhook
     1172     GET /webhooks/:id/
     1173            Returns a :format:`webhook` for the specified webhook as ``webhook``.
     1174     */
     1175    public function get_webhook( $id, $expand = array(), $query_params = array() ) {
     1176        return $this->get( sprintf( '/webhooks/%s/', $id ), $expand = $expand, $query_params = $query_params );
     1177    }
     1178
     1179
     1180    /**
     1181     delete_webhook
     1182     DELETE /webhooks/:id/
     1183            Deletes the specified :format:`webhook` object.
     1184     */
     1185    public function delete_webhook( $id, $data = array() ) {
     1186        return $this->delete( sprintf( '/webhooks/%s/', $id ), $data = $data );
     1187    }
     1188
     1189
     1190    /**
     1191     get_webhooks
     1192     GET /webhooks/
     1193            Returns the list of :format:`webhook` objects that belong to the authenticated user.
     1194     */
     1195    public function get_webhooks( $expand = array(), $query_params = array() ) {
     1196        return $this->get( sprintf( '/webhooks/' ), $expand = $expand, $query_params = $query_params );
     1197    }
     1198
     1199
     1200    /**
     1201     post_webhooks
     1202     POST /webhooks/
     1203            Creates a :format:`webhook` for the authenticated user.
     1204            The ``actions`` parameter accepts a comma-separated value that can include any or all of the following:
     1205     * ``attendee.checked_in`` - Triggered when an attendee's barcode is scanned in.
     1206     * ``attendee.checked_out`` - Triggered when an attendee's barcode is scanned out.
     1207     * ``attendee.updated`` - Triggered when attendee data is updated.
     1208     * ``event.created`` - Triggered when an event is initially created.
     1209     * ``event.published`` - Triggered when an event is published and made live.
     1210     * ``event.updated`` - Triggered when event data is updated.
     1211     * ``event.unpublished`` - Triggered when an event is unpublished.
     1212     * ``order.placed`` - Triggers when an order is placed for an event. Generated Webhook's API endpoint is to the Order endpoint.
     1213     * ``order.refunded`` - Triggers when an order is refunded for an event.
     1214     * ``order.updated`` - Triggers when order data is updated for an event.
     1215     * ``organizer.updated`` - Triggers when organizer data is updated.
     1216     * ``ticket_class.created`` - Triggers when a ticket class is created.
     1217     * ``ticket_class.deleted`` - Triggers when a ticket class is deleted.
     1218     * ``ticket_class.updated`` - Triggers when a ticket class is updated.
     1219     * ``venue.updated`` - Triggers when venue data is updated.*/
     1220    public function post_webhooks( $data = array() ) {
     1221        return $this->post( sprintf( '/webhooks/' ), $data = $data );
     1222    }
     1223
     1224
    161225}
    171226
    18 
    19 /**
    20 * get_category
    21 * GET /categories/:id/
    22 *        Gets a :format:`category` by ID as ``category``.
    23 */
    24 public function get_category($id, $expand=array(), $query_params=array()) {
    25     return $this->get(sprintf("/categories/%s/", $id), $expand=$expand, $query_params=$query_params);
    26 }
    27 
    28 
    29 /**
    30 * get_subcategories
    31 * GET /subcategories/
    32 *        Returns a list of :format:`subcategory` as ``subcategories``.
    33 */
    34 public function get_subcategories($expand=array(), $query_params=array()) {
    35     return $this->get(sprintf("/subcategories/"), $expand=$expand, $query_params=$query_params);
    36 }
    37 
    38 
    39 /**
    40 * get_subcategory
    41 * GET /subcategories/:id/
    42 *        Gets a :format:`subcategory` by ID as ``subcategory``.
    43 */
    44 public function get_subcategory($id, $expand=array(), $query_params=array()) {
    45     return $this->get(sprintf("/subcategories/%s/", $id), $expand=$expand, $query_params=$query_params);
    46 }
    47 
    48 
    49 /**
    50 * get_event_search
    51 * GET /events/search/
    52 *        Allows you to retrieve a paginated response of public :format:`event` objects from across Eventbrite’s directory, regardless of which user owns the event.
    53 */
    54 public function get_event_search($expand=array(), $query_params=array()) {
    55     return $this->get(sprintf("/events/search"), $expand=$expand, $query_params=$query_params);
    56 }
    57 
    58 
    59 /**
    60 * post_events
    61 * POST /events/
    62 *        Makes a new event, and returns an :format:`event` for the specified event. Does not support the creation of repeating
    63 *        event series.
    64 *        field event.venue_id
    65 *        The ID of a previously-created venue to associate with this event.
    66 *        You can omit this field or set it to ``null`` if you set ``online_event``.
    67 */
    68 public function post_events($data=array(), $uid) {
    69     return $this->post(sprintf("/organizations/%s/events/", $uid), $data=$data);
    70 }
    71 
    72 
    73 /**
    74 * get_event
    75 * GET /events/:id/
    76 *        Returns an :format:`event` for the specified event. Many of Eventbrite’s API use cases revolve around pulling details
    77 *        of a specific event within an Eventbrite account. Does not support fetching a repeating event series parent
    78 *        (see :ref:`get-series-by-id`).
    79 */
    80 public function get_event($id, $expand=array(), $query_params=array()) {
    81     return $this->get(sprintf("/events/%s/", $id), $expand=$expand, $query_params=$query_params);
    82 }
    83 
    84 
    85 /**
    86 * post_event
    87 * POST /events/:id/
    88 *        Updates an event. Returns an :format:`event` for the specified event. Does not support updating a repeating event
    89 *        series parent (see POST /series/:id/).
    90 */
    91 public function post_event($id, $data=array(), $uid) {
    92     return $this->post(sprintf("/events/%s/", $id), $data=$data);
    93 }
    94 
    95 
    96 /**
    97 * post_event_publish
    98 * POST /events/:id/publish/
    99 *        Publishes an event if it has not already been deleted. In order for publish to be permitted, the event must have all
    100 *        necessary information, including a name and description, an organizer, at least one ticket, and valid payment options.
    101 *        This API endpoint will return argument errors for event fields that fail to validate the publish requirements. Returns
    102 *        a boolean indicating success or failure of the publish.
    103 *        field_error event.name MISSING
    104 *        Your event must have a name to be published.
    105 *        field_error event.start MISSING
    106 *        Your event must have a start date to be published.
    107 *        field_error event.end MISSING
    108 *        Your event must have an end date to be published.
    109 *        field_error event.start.timezone MISSING
    110 *        Your event start and end dates must have matching time zones to be published.
    111 *        field_error event.organizer MISSING
    112 *        Your event must have an organizer to be published.
    113 *        field_error event.currency MISSING
    114 *        Your event must have a currency to be published.
    115 *        field_error event.currency INVALID
    116 *        Your event must have a valid currency to be published.
    117 *        field_error event.tickets MISSING
    118 *        Your event must have at least one ticket to be published.
    119 *        field_error event.tickets.N.name MISSING
    120 *        All tickets must have names in order for your event to be published. The N will be the ticket class ID with the
    121 *        error.
    122 *        field_error event.tickets.N.quantity_total MISSING
    123 *        All non-donation tickets must have an available quantity value in order for your event to be published. The N
    124 *        will be the ticket class ID with the error.
    125 *        field_error event.tickets.N.cost MISSING
    126 *        All non-donation tickets must have a cost (which can be ``0.00`` for free tickets) in order for your event to
    127 *        be published. The N will be the ticket class ID with the error.
    128 */
    129 public function post_event_publish($id, $data=array()) {
    130     return $this->post(sprintf("/events/%s/publish/", $id), $data=$data);
    131 }
    132 
    133 
    134 /**
    135 * post_event_unpublish
    136 * POST /events/:id/unpublish/
    137 *        Unpublishes an event. In order for a free event to be unpublished, it must not have any pending or completed orders,
    138 *        even if the event is in the past. In order for a paid event to be unpublished, it must not have any pending or completed
    139 *        orders, unless the event has been completed and paid out. Returns a boolean indicating success or failure of the
    140 *        unpublish.
    141 */
    142 public function post_event_unpublish($id, $data=array()) {
    143     return $this->post(sprintf("/events/%s/unpublish/", $id), $data=$data);
    144 }
    145 
    146 
    147 /**
    148 * post_event_cancel
    149 * POST /events/:id/cancel/
    150 *        Cancels an event if it has not already been deleted. In order for cancel to be permitted, there must be no pending or
    151 *        completed orders. Returns a boolean indicating success or failure of the cancel.
    152 */
    153 public function post_event_cancel($id, $data=array()) {
    154     return $this->post(sprintf("/events/%s/cancel/", $id), $data=$data);
    155 }
    156 
    157 
    158 /**
    159 * delete_event
    160 * DELETE /events/:id/
    161 *        Deletes an event if the delete is permitted. In order for a delete to be permitted, there must be no pending or
    162 *        completed orders. Returns a boolean indicating success or failure of the delete.
    163 */
    164 public function delete_event($id, $data=array()) {
    165     return $this->delete(sprintf("/events/%s/", $id), $data=$data);
    166 }
    167 
    168 
    169 /**
    170 * get_event_display_settings
    171 * GET /events/:id/display_settings/
    172 *        Retrieves the display settings for an event.
    173 */
    174 public function get_event_display_settings($id, $expand=array(), $query_params=array()) {
    175     return $this->get(sprintf("/events/%s/display_settings/", $id), $expand=$expand, $query_params=$query_params);
    176 }
    177 
    178 
    179 /**
    180 * post_event_display_settings
    181 * POST /events/:id/display_settings/
    182 *        Updates the display settings for an event.
    183 */
    184 public function post_event_display_settings($id, $data=array()) {
    185     return $this->post(sprintf("/events/%s/display_settings/", $id), $data=$data);
    186 }
    187 
    188 
    189 /**
    190 * get_event_ticket_classes
    191 * GET /events/:id/ticket_classes/
    192 *        Returns a :ref:`paginated <pagination>` response with a key of
    193 *        ``ticket_classes``, containing a list of :format:`ticket_class`.
    194 */
    195 public function get_event_ticket_classes($id, $expand=array(), $query_params=array()) {
    196     return $this->get(sprintf("/events/%s/ticket_classes/", $id), $expand=$expand, $query_params=$query_params);
    197 }
    198 
    199 
    200 /**
    201 * post_event_ticket_classes
    202 * POST /events/:id/ticket_classes/
    203 *        Creates a new ticket class, returning the result as a :format:`ticket_class`
    204 *        under the key ``ticket_class``.
    205 */
    206 public function post_event_ticket_classes($id, $data=array()) {
    207     return $this->post(sprintf("/events/%s/ticket_classes/", $id), $data=$data);
    208 }
    209 
    210 
    211 /**
    212 * get_event_ticket_class
    213 * GET /events/:id/ticket_classes/:ticket_class_id/
    214 *        Gets and returns a single :format:`ticket_class` by ID, as the key
    215 *        ``ticket_class``.
    216 */
    217 public function get_event_ticket_class($id, $ticket_class_id, $expand=array(), $query_params=array()) {
    218     return $this->get(sprintf("/events/%s/ticket_classes/%s/", $id, $ticket_class_id), $expand=$expand, $query_params=$query_params);
    219 }
    220 
    221 
    222 /**
    223 * post_event_ticket_class
    224 * POST /events/:id/ticket_classes/:ticket_class_id/
    225 *        Updates an existing ticket class, returning the updated result as a :format:`ticket_class` under the key ``ticket_class``.
    226 */
    227 public function post_event_ticket_class($id, $ticket_class_id, $data=array()) {
    228     return $this->post(sprintf("/events/%s/ticket_classes/%s/", $id, $ticket_class_id), $data=$data);
    229 }
    230 
    231 
    232 /**
    233 * delete_event_ticket_class
    234 * DELETE /events/:id/ticket_classes/:ticket_class_id/
    235 *        Deletes the ticket class. Returns ``{"deleted": true}``.
    236 */
    237 public function delete_event_ticket_class($id, $ticket_class_id, $data=array()) {
    238     return $this->delete(sprintf("/events/%s/ticket_classes/%s/", $id, $ticket_class_id), $data=$data);
    239 }
    240 
    241 
    242 /**
    243 * get_event_canned_questions
    244 * GET /events/:id/canned_questions/
    245 *        This endpoint returns canned questions of a single event (examples: first name, last name, company, prefix, etc.). This endpoint will return :format:`question`.
    246 */
    247 public function get_event_canned_questions($id, $expand=array(), $query_params=array()) {
    248     return $this->get(sprintf("/events/%s/canned_questions/", $id), $expand=$expand, $query_params=$query_params);
    249 }
    250 
    251 
    252 /**
    253 * get_event_questions
    254 * GET /events/:id/questions/
    255 *        Eventbrite allows event organizers to add custom questions that attendees fill
    256 *        out upon registration. This endpoint can be helpful for determining what
    257 *        custom information is collected and available per event.
    258 *        This endpoint will return :format:`question`.
    259 */
    260 public function get_event_questions($id, $expand=array(), $query_params=array()) {
    261     return $this->get(sprintf("/events/%s/questions/", $id), $expand=$expand, $query_params=$query_params);
    262 }
    263 
    264 
    265 /**
    266 * get_event_question
    267 * GET /events/:id/questions/:question_id/
    268 *        This endpoint will return :format:`question` for a specific question id.
    269 */
    270 public function get_event_question($id, $question_id, $expand=array(), $query_params=array()) {
    271     return $this->get(sprintf("/events/%s/questions/%s/", $id, $question_id), $expand=$expand, $query_params=$query_params);
    272 }
    273 
    274 
    275 /**
    276 * get_event_attendees
    277 * GET /events/:id/attendees/
    278 *        Returns a :ref:`paginated <pagination>` response with a key of ``attendees``, containing a list of :format:`attendee`.
    279 */
    280 public function get_event_attendees($id, $expand=array(), $query_params=array()) {
    281     return $this->get(sprintf("/events/%s/attendees/", $id), $expand=$expand, $query_params=$query_params);
    282 }
    283 
    284 
    285 /**
    286 * get_event_attendee
    287 * GET /events/:id/attendees/:attendee_id/
    288 *        Returns a single :format:`attendee` by ID, as the key ``attendee``.
    289 */
    290 public function get_event_attendee($id, $attendee_id, $expand=array(), $query_params=array()) {
    291     return $this->get(sprintf("/events/%s/attendees/%s/", $id, $attendee_id), $expand=$expand, $query_params=$query_params);
    292 }
    293 
    294 
    295 /**
    296 * get_event_orders
    297 * GET /events/:id/orders/
    298 *        Returns a :ref:`paginated <pagination>` response with a key of ``orders``, containing a list of :format:`order` against this event.
    299 */
    300 public function get_event_orders($id, $expand=array(), $query_params=array()) {
    301     return $this->get(sprintf("/events/%s/orders/", $id), $expand=$expand, $query_params=$query_params);
    302 }
    303 
    304 
    305 /**
    306 * get_event_discounts
    307 * GET /events/:id/discounts/
    308 *        Returns a :ref:`paginated <pagination>` response with a key of ``discounts``,
    309 *        containing a list of :format:`discounts <discount>` available on this event.
    310 *        field_error event_id NOT_FOUND
    311 *        The event id you are attempting to use does not exist.
    312 */
    313 public function get_event_discounts($id, $expand=array(), $query_params=array()) {
    314     return $this->get(sprintf("/events/%s/discounts/", $id), $expand=$expand, $query_params=$query_params);
    315 }
    316 
    317 
    318 /**
    319 * post_event_discounts
    320 * POST /events/:id/discounts/
    321 *        Creates a new discount; returns the result as a :format:`discount` as the key ``discount``.
    322 */
    323 public function post_event_discounts($id, $data=array()) {
    324     return $this->post(sprintf("/events/%s/discounts/", $id), $data=$data);
    325 }
    326 
    327 
    328 /**
    329 * get_event_discount
    330 * GET /events/:id/discounts/:discount_id/
    331 *        Gets a :format:`discount` by ID as the key ``discount``.
    332 */
    333 public function get_event_discount($id, $discount_id, $expand=array(), $query_params=array()) {
    334     return $this->get(sprintf("/events/%s/discounts/%s/", $id, $discount_id), $expand=$expand, $query_params=$query_params);
    335 }
    336 
    337 
    338 /**
    339 * post_event_discount
    340 * POST /events/:id/discounts/:discount_id/
    341 *        Updates a discount; returns the result as a :format:`discount` as the key ``discount``.
    342 */
    343 public function post_event_discount($id, $discount_id, $data=array()) {
    344     return $this->post(sprintf("/events/%s/discounts/%s/", $id, $discount_id), $data=$data);
    345 }
    346 
    347 
    348 /**
    349 * get_event_public_discounts
    350 * GET /events/:id/public_discounts/
    351 *        Returns a :ref:`paginated <pagination>` response with a key of ``discounts``, containing a list of public :format:`discounts <discount>` available on this event.
    352 *        Note that public discounts and discounts have exactly the same form and structure; they're just namespaced separately, and public ones (and the public GET endpoints) are visible to anyone who can see the event.
    353 */
    354 public function get_event_public_discounts($id, $expand=array(), $query_params=array()) {
    355     return $this->get(sprintf("/events/%s/public_discounts/", $id), $expand=$expand, $query_params=$query_params);
    356 }
    357 
    358 
    359 /**
    360 * post_event_public_discounts
    361 * POST /events/:id/public_discounts/
    362 *        Creates a new public discount; returns the result as a :format:`discount` as the key ``discount``.
    363 */
    364 public function post_event_public_discounts($id, $data=array()) {
    365     return $this->post(sprintf("/events/%s/public_discounts/", $id), $data=$data);
    366 }
    367 
    368 
    369 /**
    370 * get_event_public_discount
    371 * GET /events/:id/public_discounts/:discount_id/
    372 *        Gets a public :format:`discount` by ID as the key ``discount``.
    373 */
    374 public function get_event_public_discount($id, $discount_id, $expand=array(), $query_params=array()) {
    375     return $this->get(sprintf("/events/%s/public_discounts/%s/", $id, $discount_id), $expand=$expand, $query_params=$query_params);
    376 }
    377 
    378 
    379 /**
    380 * post_event_public_discount
    381 * POST /events/:id/public_discounts/:discount_id/
    382 *        Updates a public discount; returns the result as a :format:`discount` as the key ``discount``.
    383 */
    384 public function post_event_public_discount($id, $discount_id, $data=array()) {
    385     return $this->post(sprintf("/events/%s/public_discounts/%s/", $id, $discount_id), $data=$data);
    386 }
    387 
    388 
    389 /**
    390 * delete_event_public_discount
    391 * DELETE /events/:id/public_discounts/:discount_id/
    392 *        Deletes a public discount.
    393 */
    394 public function delete_event_public_discount($id, $discount_id, $data=array()) {
    395     return $this->delete(sprintf("/events/%s/public_discounts/%s/", $id, $discount_id), $data=$data);
    396 }
    397 
    398 
    399 /**
    400 * get_event_access_codes
    401 * GET /events/:id/access_codes/
    402 *        Returns a :ref:`paginated <pagination>` response with a key of ``access_codes``, containing a list of :format:`access_codes <access_code>` available on this event.
    403 */
    404 public function get_event_access_codes($id, $expand=array(), $query_params=array()) {
    405     return $this->get(sprintf("/events/%s/access_codes/", $id), $expand=$expand, $query_params=$query_params);
    406 }
    407 
    408 
    409 /**
    410 * post_event_access_codes
    411 * POST /events/:id/access_codes/
    412 *        Creates a new access code; returns the result as a :format:`access_code` as the key ``access_code``.
    413 */
    414 public function post_event_access_codes($id, $data=array()) {
    415     return $this->post(sprintf("/events/%s/access_codes/", $id), $data=$data);
    416 }
    417 
    418 
    419 /**
    420 * get_event_access_code
    421 * GET /events/:id/access_codes/:access_code_id/
    422 *        Gets a :format:`access_code` by ID as the key ``access_code``.
    423 */
    424 public function get_event_access_code($id, $access_code_id, $expand=array(), $query_params=array()) {
    425     return $this->get(sprintf("/events/%s/access_codes/%s/", $id, $access_code_id), $expand=$expand, $query_params=$query_params);
    426 }
    427 
    428 
    429 /**
    430 * post_event_access_code
    431 * POST /events/:id/access_codes/:access_code_id/
    432 *        Updates an access code; returns the result as a :format:`access_code` as the
    433 *        key ``access_code``.
    434 */
    435 public function post_event_access_code($id, $access_code_id, $data=array()) {
    436     return $this->post(sprintf("/events/%s/access_codes/%s/", $id, $access_code_id), $data=$data);
    437 }
    438 
    439 
    440 /**
    441 * get_event_transfers
    442 * GET /events/:id/transfers/
    443 *        Returns a list of :format:`transfers` for the event.
    444 */
    445 public function get_event_transfers($id, $expand=array(), $query_params=array()) {
    446     return $this->get(sprintf("/events/%s/transfers/", $id), $expand=$expand, $query_params=$query_params);
    447 }
    448 
    449 
    450 /**
    451 * get_event_teams
    452 * GET /events/:id/teams/
    453 *        Returns a list of :format:`teams` for the event.
    454 */
    455 public function get_event_teams($id, $expand=array(), $query_params=array()) {
    456     return $this->get(sprintf("/events/%s/teams/", $id), $expand=$expand, $query_params=$query_params);
    457 }
    458 
    459 
    460 /**
    461 * get_event_team
    462 * GET /events/:id/teams/:team_id/
    463 *        Returns information for a single :format:`teams`.
    464 */
    465 public function get_event_team($id, $team_id, $expand=array(), $query_params=array()) {
    466     return $this->get(sprintf("/events/%s/teams/%s/", $id, $team_id), $expand=$expand, $query_params=$query_params);
    467 }
    468 
    469 
    470 /**
    471 * get_event_teams_attendees
    472 * GET /events/:id/teams/:team_id/attendees/
    473 *        Returns :format:`attendees` for a single :format:`teams`.
    474 */
    475 public function get_event_teams_attendees($id, $team_id, $expand=array(), $query_params=array()) {
    476     return $this->get(sprintf("/events/%s/teams/%s/attendees/", $id, $team_id), $expand=$expand, $query_params=$query_params);
    477 }
    478 
    479 
    480 /**
    481 * post_series
    482 * POST /series/
    483 *        Creates a new repeating event series. The POST data must include information for at least one event date in the series.
    484 *        .. _get-series-by-id:
    485 */
    486 public function post_series($data=array()) {
    487     return $this->post(sprintf("/series/"), $data=$data);
    488 }
    489 
    490 
    491 /**
    492 * get_one_series
    493 * GET /series/:id/
    494 *        Returns a repeating event series parent object for the specified repeating event series.
    495 *        .. _post-series-by-id:
    496 */
    497 public function get_one_series($id, $expand=array(), $query_params=array()) {
    498     return $this->get(sprintf("/series/%s/", $id), $expand=$expand, $query_params=$query_params);
    499 }
    500 
    501 
    502 /**
    503 * post_one_series
    504 * POST /series/:id/
    505 *        Updates a repeating event series parent object, and optionally also creates more event dates or updates or deletes
    506 *        existing event dates in the series. In order for a series date to be deleted or updated, there must be no pending or
    507 *        completed orders for that date.
    508 *        .. _publish-series-by-id:
    509 */
    510 public function post_one_series($id, $data=array()) {
    511     return $this->post(sprintf("/series/%s/", $id), $data=$data);
    512 }
    513 
    514 
    515 /**
    516 * post_series_publish
    517 * POST /series/:id/publish/
    518 *        Publishes a repeating event series and all of its occurrences that are not already canceled or deleted. Once a date is cancelled it can still be uncancelled and can be viewed by the public. A deleted date cannot be undeleted and cannot by viewed by the public. In order for
    519 *        publish to be permitted, the event must have all necessary information, including a name and description, an organizer,
    520 *        at least one ticket, and valid payment options. This API endpoint will return argument errors for event fields that
    521 *        fail to validate the publish requirements. Returns a boolean indicating success or failure of the publish.
    522 *        field_error event.name MISSING
    523 *        Your event must have a name to be published.
    524 *        field_error event.start MISSING
    525 *        Your event must have a start date to be published.
    526 *        field_error event.end MISSING
    527 *        Your event must have an end date to be published.
    528 *        field_error event.start.timezone MISSING
    529 *        Your event start and end dates must have matching time zones to be published.
    530 *        field_error event.organizer MISSING
    531 *        Your event must have an organizer to be published.
    532 *        field_error event.currency MISSING
    533 *        Your event must have a currency to be published.
    534 *        field_error event.currency INVALID
    535 *        Your event must have a valid currency to be published.
    536 *        field_error event.tickets MISSING
    537 *        Your event must have at least one ticket to be published.
    538 *        field_error event.tickets.N.name MISSING
    539 *        All tickets must have names in order for your event to be published. The N will be the ticket class ID with the
    540 *        error.
    541 *        field_error event.tickets.N.quantity_total MISSING
    542 *        All non-donation tickets must have an available quantity value in order for your event to be published. The N
    543 *        will be the ticket class ID with the error.
    544 *        field_error event.tickets.N.cost MISSING
    545 *        All non-donation tickets must have a cost (which can be ``0.00`` for free tickets) in order for your event to
    546 *        be published. The N will be the ticket class ID with the error.
    547 *        .. _unpublish-series-by-id:
    548 */
    549 public function post_series_publish($id, $data=array()) {
    550     return $this->post(sprintf("/series/%s/publish/", $id), $data=$data);
    551 }
    552 
    553 
    554 /**
    555 * post_series_unpublish
    556 * POST /series/:id/unpublish/
    557 *        Unpublishes a repeating event series and all of its occurrences that are not already completed, canceled, or deleted. In
    558 *        order for a free series to be unpublished, it must not have any pending or completed orders for any dates, even past
    559 *        dates. In order for a paid series to be unpublished, it must not have any pending or completed orders for any dates,
    560 *        except that completed orders for past dates that have been completed and paid out do not prevent an unpublish. Returns
    561 *        a boolean indicating success or failure of the unpublish.
    562 *        .. _cancel-series-by-id:
    563 */
    564 public function post_series_unpublish($id, $data=array()) {
    565     return $this->post(sprintf("/series/%s/unpublish/", $id), $data=$data);
    566 }
    567 
    568 
    569 /**
    570 * post_series_cancel
    571 * POST /series/:id/cancel/
    572 *        Cancels a repeating event series and all of its occurrences that are not already canceled or deleted. In order for
    573 *        cancel to be permitted, there must be no pending or completed orders for any dates in the series. Returns a boolean
    574 *        indicating success or failure of the cancel.
    575 *        .. _delete-series-by-id:
    576 */
    577 public function post_series_cancel($id, $data=array()) {
    578     return $this->post(sprintf("/series/%s/cancel/", $id), $data=$data);
    579 }
    580 
    581 
    582 /**
    583 * delete_one_series
    584 * DELETE /series/:id/
    585 *        Deletes a repeating event series and all of its occurrences if the delete is permitted. In order for a delete to be
    586 *        permitted, there must be no pending or completed orders for any dates in the series. Returns a boolean indicating
    587 *        success or failure of the delete.
    588 *        .. _get-series-events:
    589 */
    590 public function delete_one_series($id, $data=array()) {
    591     return $this->delete(sprintf("/series/%s/", $id), $data=$data);
    592 }
    593 
    594 
    595 /**
    596 * get_series_events
    597 * GET /series/:id/events/
    598 *        Returns all of the events that belong to this repeating event series.
    599 *        .. _post-series-dates:
    600 */
    601 public function get_series_events($id, $expand=array(), $query_params=array()) {
    602     return $this->get(sprintf("/series/%s/events/", $id), $expand=$expand, $query_params=$query_params);
    603 }
    604 
    605 
    606 /**
    607 * post_series_events
    608 * POST /series/:id/events/
    609 *        Creates more event dates or updates or deletes existing event dates in a repeating event series. In order for a series
    610 *        date to be deleted or updated, there must be no pending or completed orders for that date.
    611 */
    612 public function post_series_events($id, $data=array()) {
    613     return $this->post(sprintf("/series/%s/events/", $id), $data=$data);
    614 }
    615 
    616 
    617 /**
    618 * get_formatss
    619 * GET /formats/
    620 *        Returns a list of :format:`format` as ``formats``.
    621 */
    622 public function get_formatss($expand=array(), $query_params=array()) {
    623     return $this->get(sprintf("/formats/"), $expand=$expand, $query_params=$query_params);
    624 }
    625 
    626 
    627 /**
    628 * get_formats
    629 * GET /formats/:id/
    630 *        Gets a :format:`format` by ID as ``format``.*/
    631 public function get_formats($id, $expand=array(), $query_params=array()) {
    632     return $this->get(sprintf("/formats/%s/", $id), $expand=$expand, $query_params=$query_params);
    633 }
    634 
    635 
    636 /**
    637 * get_media
    638 * GET /media/:id/
    639 *        Return an :format:`image` for a given id.
    640 *        .. _get-media-upload:
    641 */
    642 public function get_media($id, $expand=array(), $query_params=array()) {
    643     return $this->get(sprintf("/media/%s/", $id), $expand=$expand, $query_params=$query_params);
    644 }
    645 
    646 
    647 /**
    648 * get_media_upload
    649 * GET /media/upload/
    650 *        See :ref:`media-uploads`.
    651 *        .. _post-media-upload:
    652 */
    653 public function get_media_upload($expand=array(), $query_params=array()) {
    654     return $this->get(sprintf("/media/upload/"), $expand=$expand, $query_params=$query_params);
    655 }
    656 
    657 
    658 /**
    659 * post_media_upload
    660 * POST /media/upload/
    661 *        See :ref:`media-uploads`.*/
    662 public function post_media_upload($data=array()) {
    663     return $this->post(sprintf("/media/upload/"), $data=$data);
    664 }
    665 
    666 
    667 /**
    668 * get_order
    669 * GET /orders/:id/
    670 *        Gets an :format:`order` by ID as the key ``order``.
    671 */
    672 public function get_order($id, $expand=array(), $query_params=array()) {
    673     return $this->get(sprintf("/orders/%s/", $id), $expand=$expand, $query_params=$query_params);
    674 }
    675 
    676 
    677 /**
    678 * post_organizers
    679 * POST /organizers/
    680 *        Makes a new organizer. Returns an :format:`organizer` as ``organizer``.
    681 *        field_error organizer.name DUPLICATE
    682 *        You already have another organizer with this name.
    683 *        field_error organizer.short_name UNAVAILABLE
    684 *        There is already another organizer or event with this short name.
    685 *        field_error organizer.logo_id INVALID
    686 *        This is not a valid image.
    687 *        field_error organizer.facebook INVALID
    688 *        This is not a valid Facebook profile URL.
    689 *        field_error organizer.facebook NO_GROUP_PAGES
    690 *        The Facebook URL cannot be a group page.
    691 */
    692 public function post_organizers($data=array()) {
    693     return $this->post(sprintf("/organizers/"), $data=$data);
    694 }
    695 
    696 
    697 /**
    698 * get_organizer
    699 * GET /organizers/:id/
    700 *        Gets an :format:`organizer` by ID as ``organizer``.
    701 */
    702 public function get_organizer($id, $expand=array(), $query_params=array()) {
    703     return $this->get(sprintf("/organizers/%s/", $id), $expand=$expand, $query_params=$query_params);
    704 }
    705 
    706 
    707 /**
    708 * post_organizer
    709 * POST /organizers/:id/
    710 *        Updates an :format:`organizer` and returns it as as ``organizer``.
    711 *        field_error organizer.name DUPLICATE
    712 *        You already have another organizer with this name.
    713 *        field_error organizer.short_name UNAVAILABLE
    714 *        There is already another organizer or event with this short name.
    715 *        field_error organizer.logo_id INVALID
    716 *        This is not a valid image.
    717 *        field_error organizer.facebook INVALID
    718 *        This is not a valid Facebook profile URL.
    719 *        field_error organizer.facebook NO_GROUP_PAGES
    720 *        The Facebook URL cannot be a group page.
    721 */
    722 public function post_organizer($id, $data=array()) {
    723     return $this->post(sprintf("/organizers/%s/", $id), $data=$data);
    724 }
    725 
    726 
    727 /**
    728 * get_organizers_events
    729 * GET /organizers/:id/events/
    730 *        Gets events of the :format:`organizer`.
    731 */
    732 public function get_organizers_events($id, $expand=array(), $query_params=array()) {
    733     return $this->get(sprintf("/organizers/%s/events/", $id), $expand=$expand, $query_params=$query_params);
    734 }
    735 
    736 
    737 /**
    738 * get_refund_request
    739 * GET /refund_requests/:id/
    740 *        Gets a :format:`refund-request` for the specified refund request.
    741 *        error NOT_AUTHORIZED
    742 *        Only the order's buyer can create a refund request
    743 *        error FIELD_UNKNOWN
    744 *        The refund request id provided is unknown
    745 */
    746 public function get_refund_request($id, $expand=array(), $query_params=array()) {
    747     return $this->get(sprintf("/refund_requests/%s/", $id), $expand=$expand, $query_params=$query_params);
    748 }
    749 
    750 
    751 /**
    752 * post_refund_request
    753 * POST /refund_requests/:id/
    754 *        Update a :format:`refund-request` for a specific order. Each element in items is a :format:`refund-item`
    755 *        error NOT_AUTHORIZED
    756 *        Only the order's buyer can create a refund request
    757 *        error FIELD_UNKNOWN
    758 *        The refund request id provided is unknown
    759 *        error INVALID_REFUND_REQUEST_STATUS
    760 *        The refund request is not the correct status for the change
    761 */
    762 public function post_refund_request($id, $data=array()) {
    763     return $this->post(sprintf("/refund_requests/%s/", $id), $data=$data);
    764 }
    765 
    766 
    767 /**
    768 * post_refund_requests
    769 * POST /refund_requests/
    770 *        Creates a :format:`refund-request` for a specific order. Each element in items is a :format:`refund-item`
    771 *        error NOT_AUTHORIZED
    772 *        Only the order's buyer can create a refund request
    773 *        error FIELD_UNKNOWN
    774 *        The order id provided is unknown
    775 *        error EVENT_DOES_NOT_ALLOW_REFUND_REQUESTS
    776 *        According to organizer definition, the event does not allow the creation of refund requests.
    777 *        error EXISTING_REFUND_REQUEST_FOR_ORDER
    778 *        The order already has a refund request
    779 *        error INVALID_ORDER_STATE
    780 *        The order status is not allowed to request a refund. It must be placed.*/
    781 public function post_refund_requests($data=array()) {
    782     return $this->post(sprintf("/refund_requests/"), $data=$data);
    783 }
    784 
    785 
    786 /**
    787 * get_reports_sales
    788 * GET /reports/sales/
    789 *        Returns a response of the aggregate sales data.
    790 */
    791 public function get_reports_sales($expand=array(), $query_params=array()) {
    792     return $this->get(sprintf("/reports/sales/"), $expand=$expand, $query_params=$query_params);
    793 }
    794 
    795 
    796 /**
    797 * get_reports_attendees
    798 * GET /reports/attendees/
    799 *        Returns a response of the aggregate attendees data.
    800 */
    801 public function get_reports_attendees($expand=array(), $query_params=array()) {
    802     return $this->get(sprintf("/reports/attendees/"), $expand=$expand, $query_params=$query_params);
    803 }
    804 
    805 
    806 /**
    807 * get_system_timezones
    808 * GET /system/timezones/
    809 *        Returns a :ref:`paginated <pagination>` response with a key of ``timezones``,
    810 *        containing a list of :format:`timezones <timezone>`.
    811 */
    812 public function get_system_timezones($expand=array(), $query_params=array()) {
    813     return $this->get(sprintf("/system/timezones/"), $expand=$expand, $query_params=$query_params);
    814 }
    815 
    816 
    817 /**
    818 * get_system_regions
    819 * GET /system/regions/
    820 *        Returns a single page response with a key of ``regions``,
    821 *        containing a list of :format:`regions`.
    822 */
    823 public function get_system_regions($expand=array(), $query_params=array()) {
    824     return $this->get(sprintf("/system/regions/"), $expand=$expand, $query_params=$query_params);
    825 }
    826 
    827 
    828 /**
    829 * get_system_countries
    830 * GET /system/countries/
    831 *        Returns a single page response with a key of ``countries``,
    832 *        containing a list of :format:`countries`.
    833 */
    834 public function get_system_countries($expand=array(), $query_params=array()) {
    835     return $this->get(sprintf("/system/countries/"), $expand=$expand, $query_params=$query_params);
    836 }
    837 
    838 
    839 /**
    840 * post_tracking_beacons
    841 * POST /tracking_beacons/
    842 *        Makes a new tracking beacon. Returns an :format:`tracking_beacon` as ``tracking_beacon``. Either ``event_id`` or ``user_id`` is required for each tracking beacon. If the ``event_id`` is provided, the tracking pixel will fire only for that event. If the ``user_id`` is provided, the tracking pixel will fire for all events organized by that user.
    843 *        field_error tracking_beacon.event_id INVALID
    844 *        This is not a valid event.
    845 *        field_error tracking_beacon.user_id INVALID
    846 *        This is not a valid user.
    847 */
    848 public function post_tracking_beacons($data=array()) {
    849     return $this->post(sprintf("/tracking_beacons/"), $data=$data);
    850 }
    851 
    852 
    853 /**
    854 * get_tracking_beacon
    855 * GET /tracking_beacons/:tracking_beacons_id/
    856 *        Returns the :format:`tracking_beacon` with the specified :tracking_beacons_id.
    857 */
    858 public function get_tracking_beacon($tracking_beacons_id, $expand=array(), $query_params=array()) {
    859     return $this->get(sprintf("/tracking_beacons/%s/", $tracking_beacons_id), $expand=$expand, $query_params=$query_params);
    860 }
    861 
    862 
    863 /**
    864 * post_tracking_beacon
    865 * POST /tracking_beacons/:tracking_beacons_id/
    866 *        Updates the :format:`tracking_beacons` with the specified :tracking_beacons_id. Though ``event_id`` and ``user_id`` are not individually required, it is a requirement to have a tracking beacon where either one must exist. Returns an :format:`tracking_beacon` as ``tracking_beacon``.
    867 */
    868 public function post_tracking_beacon($tracking_beacons_id, $data=array()) {
    869     return $this->post(sprintf("/tracking_beacons/%s/", $tracking_beacons_id), $data=$data);
    870 }
    871 
    872 
    873 /**
    874 * delete_tracking_beacon
    875 * DELETE /tracking_beacons/:tracking_beacons_id/
    876 *        Delete the :format:`tracking_beacons` with the specified :tracking_beacons_id.
    877 */
    878 public function delete_tracking_beacon($tracking_beacons_id, $data=array()) {
    879     return $this->delete(sprintf("/tracking_beacons/%s/", $tracking_beacons_id), $data=$data);
    880 }
    881 
    882 
    883 /**
    884 * get_event_tracking_beacons
    885 * GET /events/:event_id/tracking_beacons/
    886 *        Returns the list of :format:`tracking_beacon` for the event :event_id
    887 */
    888 public function get_event_tracking_beacons($event_id, $expand=array(), $query_params=array()) {
    889     return $this->get(sprintf("/events/%s/tracking_beacons/", $event_id), $expand=$expand, $query_params=$query_params);
    890 }
    891 
    892 
    893 /**
    894 * get_user_tracking_beacons
    895 * GET /users/:user_id/tracking_beacons/
    896 *        Returns the list of :format:`tracking_beacon` for the user :user_id
    897 */
    898 public function get_user_tracking_beacons($user_id, $expand=array(), $query_params=array()) {
    899     return $this->get(sprintf("/users/%s/tracking_beacons/", $user_id), $expand=$expand, $query_params=$query_params);
    900 }
    901 
    902 
    903 /**
    904 * get_user
    905 * GET /users/:id/
    906 *        Returns a :format:`user` for the specified user as ``user``. If you want to get details about the currently authenticated user, use ``/users/me/``.
    907 */
    908 public function get_user($id, $expand=array(), $query_params=array()) {
    909     return $this->get(sprintf("/users/%s/", $id), $expand=$expand, $query_params=$query_params);
    910 }
    911 
    912 
    913 /**
    914 * get_user_orders
    915 * GET /users/:id/orders/
    916 *        Returns a :ref:`paginated <pagination>` response of :format:`orders <order>`, under the key ``orders``, of all orders the user has placed (i.e. where the user was the person buying the tickets).
    917 *        :param int id: The id assigned to a user.
    918 *        :param datetime changed_since: (optional) Only return attendees changed on or after the time given.
    919 *        .. note:: A datetime represented as a string in ISO8601 combined date and time format, always in UTC.
    920 */
    921 public function get_user_orders($id, $expand=array(), $query_params=array()) {
    922     return $this->get(sprintf("/users/%s/orders/", $id), $expand=$expand, $query_params=$query_params);
    923 }
    924 
    925 
    926 /**
    927 * get_user_organizers
    928 * GET /users/:id/organizers/
    929 *        Returns a :ref:`paginated <pagination>` response of :format:`organizer` objects that are owned by the user.
    930 */
    931 public function get_user_organizers($id, $expand=array(), $query_params=array()) {
    932     return $this->get(sprintf("/users/%s/organizers/", $id), $expand=$expand, $query_params=$query_params);
    933 }
    934 
    935 
    936 /**
    937 * get_user_owned_events
    938 * GET /users/:id/owned_events/
    939 *        Returns a :ref:`paginated <pagination>` response of :format:`events <event>`, under
    940 *        the key ``events``, of all events the user owns (i.e. events they are organising)
    941 */
    942 public function get_user_owned_events($id, $expand=array(), $query_params=array()) {
    943     return $this->get(sprintf("/organizations/%s/events/", $id), $expand=$expand, $query_params=$query_params);
    944 }
    945 
    946 public function get_user_organizations($id, $expand=array(), $query_params=array()) {
    947     return $this->get(sprintf("/users/me/organizations/", $id), $expand=$expand, $query_params=$query_params);
    948 }
    949 
    950 /**
    951 * get_user_events
    952 * GET /users/:id/events/
    953 *        Returns a :ref:`paginated <pagination>` response of :format:`events <event>`, under the key ``events``, of all events the user has access to
    954 */
    955 public function get_user_events($id, $expand=array(), $query_params=array()) {
    956     return $this->get(sprintf("/users/%s/events/", $id), $expand=$expand, $query_params=$query_params);
    957 }
    958 
    959 
    960 /**
    961 * get_user_venues
    962 * GET /users/:id/venues/
    963 *        Returns a paginated response of :format:`venue` objects that are owned by the user.
    964 */
    965 public function get_user_venues($id, $expand=array(), $query_params=array()) {
    966     return $this->get(sprintf("/users/%s/venues/", $id), $expand=$expand, $query_params=$query_params);
    967 }
    968 
    969 
    970 /**
    971 * get_user_owned_event_attendees
    972 * GET /users/:id/owned_event_attendees/
    973 *        Returns a :ref:`paginated <pagination>` response of :format:`attendees <attendee>`,
    974 *        under the key ``attendees``, of attendees visiting any of the events the user owns
    975 *        (events that would be returned from ``/users/:id/owned_events/``)
    976 */
    977 public function get_user_owned_event_attendees($id, $expand=array(), $query_params=array()) {
    978     return $this->get(sprintf("/users/%s/owned_event_attendees/", $id), $expand=$expand, $query_params=$query_params);
    979 }
    980 
    981 
    982 /**
    983 * get_user_owned_event_orders
    984 * GET /users/:id/owned_event_orders/
    985 *        Returns a :ref:`paginated <pagination>` response of :format:`orders <order>`,
    986 *        under the key ``orders``, of orders placed against any of the events the user owns
    987 *        (events that would be returned from ``/users/:id/owned_events/``)
    988 */
    989 public function get_user_owned_event_orders($id, $expand=array(), $query_params=array()) {
    990     return $this->get(sprintf("/users/%s/owned_event_orders/", $id), $expand=$expand, $query_params=$query_params);
    991 }
    992 
    993 
    994 /**
    995 * get_user_contact_lists
    996 * GET /users/:id/contact_lists/
    997 *        Returns a list of :format:`contact_list` that the user owns as the key
    998 *        ``contact_lists``.
    999 */
    1000 public function get_user_contact_lists($id, $expand=array(), $query_params=array()) {
    1001     return $this->get(sprintf("/users/%s/contact_lists/", $id), $expand=$expand, $query_params=$query_params);
    1002 }
    1003 
    1004 
    1005 /**
    1006 * post_user_contact_lists
    1007 * POST /users/:id/contact_lists/
    1008 *        Makes a new :format:`contact_list` for the user and returns it as
    1009 *        ``contact_list``.
    1010 */
    1011 public function post_user_contact_lists($id, $data=array()) {
    1012     return $this->post(sprintf("/users/%s/contact_lists/", $id), $data=$data);
    1013 }
    1014 
    1015 
    1016 /**
    1017 * get_user_contact_list
    1018 * GET /users/:id/contact_lists/:contact_list_id/
    1019 *        Gets a user's :format:`contact_list` by ID as ``contact_list``.
    1020 */
    1021 public function get_user_contact_list($id, $contact_list_id, $expand=array(), $query_params=array()) {
    1022     return $this->get(sprintf("/users/%s/contact_lists/%s/", $id, $contact_list_id), $expand=$expand, $query_params=$query_params);
    1023 }
    1024 
    1025 
    1026 /**
    1027 * post_user_contact_list
    1028 * POST /users/:id/contact_lists/:contact_list_id/
    1029 *        Updates the :format:`contact_list` and returns it as ``contact_list``.
    1030 */
    1031 public function post_user_contact_list($id, $contact_list_id, $data=array()) {
    1032     return $this->post(sprintf("/users/%s/contact_lists/%s/", $id, $contact_list_id), $data=$data);
    1033 }
    1034 
    1035 
    1036 /**
    1037 * delete_user_contact_list
    1038 * DELETE /users/:id/contact_lists/:contact_list_id/
    1039 *        Deletes the contact list. Returns ``{"deleted": true}``.
    1040 */
    1041 public function delete_user_contact_list($id, $contact_list_id, $data=array()) {
    1042     return $this->delete(sprintf("/users/%s/contact_lists/%s/", $id, $contact_list_id), $data=$data);
    1043 }
    1044 
    1045 
    1046 /**
    1047 * get_user_contact_lists_contacts
    1048 * GET /users/:id/contact_lists/:contact_list_id/contacts/
    1049 *        Returns the :format:`contacts <contact>` on the contact list
    1050 *        as ``contacts``.
    1051 */
    1052 public function get_user_contact_lists_contacts($id, $contact_list_id, $expand=array(), $query_params=array()) {
    1053     return $this->get(sprintf("/users/%s/contact_lists/%s/contacts/", $id, $contact_list_id), $expand=$expand, $query_params=$query_params);
    1054 }
    1055 
    1056 
    1057 /**
    1058 * post_user_contact_lists_contacts
    1059 * POST /users/:id/contact_lists/:contact_list_id/contacts/
    1060 *        Adds a new contact to the contact list. Returns ``{"created": true}``.
    1061 *        There is no way to update entries in the list; just delete the old one
    1062 *        and add the updated version.
    1063 */
    1064 public function post_user_contact_lists_contacts($id, $contact_list_id, $data=array()) {
    1065     return $this->post(sprintf("/users/%s/contact_lists/%s/contacts/", $id, $contact_list_id), $data=$data);
    1066 }
    1067 
    1068 
    1069 /**
    1070 * delete_user_contact_lists_contacts
    1071 * DELETE /users/:id/contact_lists/:contact_list_id/contacts/
    1072 *        Deletes the specified contact from the contact list.
    1073 *        Returns ``{"deleted": true}``.
    1074 =======
    1075 */
    1076 public function delete_user_contact_lists_contacts($id, $contact_list_id, $data=array()) {
    1077     return $this->delete(sprintf("/users/%s/contact_lists/%s/contacts/", $id, $contact_list_id), $data=$data);
    1078 }
    1079 
    1080 
    1081 /**
    1082 * get_user_bookmarks
    1083 * GET /users/:id/bookmarks/
    1084 *        Gets all the user's saved events.
    1085 *        In order to update the saved events list, the user must unsave or save each event.
    1086 *        A user is authorized to only see his/her saved events.
    1087 */
    1088 public function get_user_bookmarks($id, $expand=array(), $query_params=array()) {
    1089     return $this->get(sprintf("/users/%s/bookmarks/", $id), $expand=$expand, $query_params=$query_params);
    1090 }
    1091 
    1092 
    1093 /**
    1094 * post_user_bookmarks_save
    1095 * POST /users/:id/bookmarks/save/
    1096 *        Adds a new bookmark for the user. Returns ``{"created": true}``.
    1097 *        A user is only authorized to save his/her own events.
    1098 */
    1099 public function post_user_bookmarks_save($id, $data=array()) {
    1100     return $this->post(sprintf("/users/%s/bookmarks/save/", $id), $data=$data);
    1101 }
    1102 
    1103 
    1104 /**
    1105 * post_user_bookmarks_unsave
    1106 * POST /users/:id/bookmarks/unsave/
    1107 *        Removes the specified bookmark from the event for the user. Returns ``{"deleted": true}``.
    1108 *        A user is only authorized to unsave his/her own events.
    1109 *        error NOT_AUTHORIZED
    1110 *        You are not authorized to unsave an event for this user.
    1111 *        error ARGUMENTS_ERROR
    1112 *        There are errors with your arguments.
    1113 */
    1114 public function post_user_bookmarks_unsave($id, $data=array()) {
    1115     return $this->post(sprintf("/users/%s/bookmarks/unsave/", $id), $data=$data);
    1116 }
    1117 
    1118 
    1119 /**
    1120 * get_venue
    1121 * GET /venues/:id/
    1122 *        Returns a :format:`venue` object.
    1123 */
    1124 public function get_venue($id, $expand=array(), $query_params=array()) {
    1125     return $this->get(sprintf("/venues/%s/", $id), $expand=$expand, $query_params=$query_params);
    1126 }
    1127 
    1128 
    1129 /**
    1130 * post_venue
    1131 * POST /venues/:id/
    1132 *        Updates a :format:`venue` and returns it as an object.
    1133 */
    1134 public function post_venue($id, $data=array()) {
    1135     return $this->post(sprintf("/venues/%s/", $id), $data=$data);
    1136 }
    1137 
    1138 
    1139 /**
    1140 * post_venues
    1141 * POST /venues/
    1142 *        Creates a new :format:`venue` with associated :format:`address`.
    1143 *        ..start-internal
    1144 */
    1145 public function post_venues($data=array()) {
    1146     return $this->post(sprintf("/venues/"), $data=$data);
    1147 }
    1148 
    1149 
    1150 /**
    1151 * get_venues_search
    1152 * GET /venues/search/
    1153 *        Search for venues. Returns a list of venue objects.
    1154 *        ..end-internal
    1155 */
    1156 public function get_venues_search($expand=array(), $query_params=array()) {
    1157     return $this->get(sprintf("/venues/search/"), $expand=$expand, $query_params=$query_params);
    1158 }
    1159 
    1160 
    1161 /**
    1162 * get_venues_events
    1163 * GET /venues/:id/events/
    1164 *        Returns events of a given :format:`venue`.
    1165 */
    1166 public function get_venues_events($id, $expand=array(), $query_params=array()) {
    1167     return $this->get(sprintf("/venues/%s/events/", $id), $expand=$expand, $query_params=$query_params);
    1168 }
    1169 
    1170 
    1171 /**
    1172 * get_webhook
    1173 * GET /webhooks/:id/
    1174 *        Returns a :format:`webhook` for the specified webhook as ``webhook``.
    1175 */
    1176 public function get_webhook($id, $expand=array(), $query_params=array()) {
    1177     return $this->get(sprintf("/webhooks/%s/", $id), $expand=$expand, $query_params=$query_params);
    1178 }
    1179 
    1180 
    1181 /**
    1182 * delete_webhook
    1183 * DELETE /webhooks/:id/
    1184 *        Deletes the specified :format:`webhook` object.
    1185 */
    1186 public function delete_webhook($id, $data=array()) {
    1187     return $this->delete(sprintf("/webhooks/%s/", $id), $data=$data);
    1188 }
    1189 
    1190 
    1191 /**
    1192 * get_webhooks
    1193 * GET /webhooks/
    1194 *        Returns the list of :format:`webhook` objects that belong to the authenticated user.
    1195 */
    1196 public function get_webhooks($expand=array(), $query_params=array()) {
    1197     return $this->get(sprintf("/webhooks/"), $expand=$expand, $query_params=$query_params);
    1198 }
    1199 
    1200 
    1201 /**
    1202 * post_webhooks
    1203 * POST /webhooks/
    1204 *        Creates a :format:`webhook` for the authenticated user.
    1205 *        The ``actions`` parameter accepts a comma-separated value that can include any or all of the following:
    1206 *        * ``attendee.checked_in`` - Triggered when an attendee's barcode is scanned in.
    1207 *        * ``attendee.checked_out`` - Triggered when an attendee's barcode is scanned out.
    1208 *        * ``attendee.updated`` - Triggered when attendee data is updated.
    1209 *        * ``event.created`` - Triggered when an event is initially created.
    1210 *        * ``event.published`` - Triggered when an event is published and made live.
    1211 *        * ``event.updated`` - Triggered when event data is updated.
    1212 *        * ``event.unpublished`` - Triggered when an event is unpublished.
    1213 *        * ``order.placed`` - Triggers when an order is placed for an event. Generated Webhook's API endpoint is to the Order endpoint.
    1214 *        * ``order.refunded`` - Triggers when an order is refunded for an event.
    1215 *        * ``order.updated`` - Triggers when order data is updated for an event.
    1216 *        * ``organizer.updated`` - Triggers when organizer data is updated.
    1217 *        * ``ticket_class.created`` - Triggers when a ticket class is created.
    1218 *        * ``ticket_class.deleted`` - Triggers when a ticket class is deleted.
    1219 *        * ``ticket_class.updated`` - Triggers when a ticket class is updated.
    1220 *        * ``venue.updated`` - Triggers when venue data is updated.*/
    1221 public function post_webhooks($data=array()) {
    1222     return $this->post(sprintf("/webhooks/"), $data=$data);
    1223 }
    1224 
    1225 
    1226 }
    1227 ?>
Note: See TracChangeset for help on using the changeset viewer.