Skip to main content

Official Eventbrite SDK for Python

Project description

https://badge.fury.io/py/eventbrite.png https://travis-ci.org/eventbrite/eventbrite-sdk-python.svg?branch=master https://pypip.in/d/eventbrite/badge.png

Installation from PyPI

$ pip install eventbrite

If you need to, you can also use easy_install:

$ easy_install eventbrite

Usage

The Eventbrite Python SDK makes it trivial to interact with the Eventbrite API:

>>> from eventbrite import Eventbrite
>>> eventbrite = Eventbrite('my-oauth-token')
>>> user = eventbrite.get_user()  # Not passing an argument returns yourself
>>> user['id']
1234567890
>>> user['name']
Daniel Roy Greenfeld

You can also specify API endpoints manually:

>>> user = eventbrite.get('/users/me')
>>> user['id']
1234567890
>>> user['name']
Daniel Roy Greenfeld

Expansions can be included in a returned GET resource by simply adding the expand keyword to the calling method:

>>> event = eventbrite.get_event('my-event-id')
>>> 'ticket_classes' in evbobject
False
>>> event = eventbrite.get_event('my-event-id', expand='ticket_classes')
>>> 'ticket_classes' in evbobject
True

Usage with Frameworks

When using Flask, you can convert incoming webhook requests into Eventbrite API objects using the webhook_to_object() method:

@app.route('/webhook', methods=['POST'])
def webhook():


    # Use the API client to convert from a webhook to an API object
    api_object = eventbrite.webhook_to_object(request)

    # Process the API object
    if api_object.type == 'User':
        do_user_process(api_object)

    if api_object.type == 'Event':
        do_event_process(api_object)

    return ""

Versioning

Because this client interacts with Eventbrite’s third API (a.k.a. APIv3), we are tying our release numbers against it in a modified-semantic system:

  • 3.x.x where ‘3’ matches the API version. This will not change until Eventbrite releases a new API version.

  • x.0.x where ‘0’ is increased any time there is a significant change to the API that possibly breaks backwards compatibility

  • x.x.1 where ‘1’ is increased on any release that does not break backwards comptability (small, new features, enhancements, bugfixes)

History

3.2.1 (2015-08-10)

  • Enabled webhooks

  • Fixed ticket definitions in Event creation test

  • Set input variable using input argument thanks to Bill So (#27).

3.2.0 (2015-07-07)

  • Added new publish and unpublish methods thanks to Ryan Bagwell.

  • Eventbrite client now accepts an eventbrite_api_url argument.

3.1.0 (2015-05-11)

3.0.5 (2015-04-24)

  • Removed ‘content-type’ header from all GET requests. Thank you @xxv for identifying the problem and contributing code.

3.0.4 (2015-03-12)

  • Resolved the search result response problem where filtering did not work.

3.0.3 (2015-03-02)

  • Fixed import issue with __version__. Thank you @meshy and @longjos for identifying the problem.

3.0.2 (2015-01-30)

  • Event creation now working.

  • Added feature allowing the use of Eventbrite API url at test servers. Should expedite development of tricky post actions.

3.0.1 (2015-01-30)

  • Added reverse mapping for get_event_ticket_class() method.

  • Added events mapping to provide GET access to the Event endpoint.

  • Removed several deprecated JSON mappings.

3.0.0 (2015-01-28)

  • Initial release of 3.0.0 client

3.0.0-alpha (2014-12-05)

  • Inception

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

eventbrite-3.2.1.tar.gz (27.8 kB view details)

Uploaded Source

Built Distribution

eventbrite-3.2.1-py2.py3-none-any.whl (16.3 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file eventbrite-3.2.1.tar.gz.

File metadata

  • Download URL: eventbrite-3.2.1.tar.gz
  • Upload date:
  • Size: 27.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for eventbrite-3.2.1.tar.gz
Algorithm Hash digest
SHA256 df253d3853d1f01e993b36ac121eb408c54effed06b486037bc207d6e2856c53
MD5 b34e0f54fb6a0f4af2a5f16a16a4e54a
BLAKE2b-256 3107dd56dedb8ae7e930f6de8cfa4faba4a2f3aa9f4acce268666bc4f54f70e8

See more details on using hashes here.

File details

Details for the file eventbrite-3.2.1-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for eventbrite-3.2.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 9892cd02820818ac944982bf13014ba52bcc8b97ba106cdb8cf4cbba7f141a6a
MD5 a9751c49788d533010d5272942965dbe
BLAKE2b-256 230e13c7b194b36a59981834a7939aa197a48d9f531595a1f6b7112fece38b58

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page